Compare commits
@@ -36,6 +36,8 @@ See https://arduino-pico.readthedocs.io/en/latest/ along with the examples for m
|
||||
* SparkFun Thing Plus RP2040
|
||||
* uPesy RP2040 DevKit
|
||||
* WIZnet W5100S-EVB-Pico
|
||||
* WIZnet W5500-EVB-Pico
|
||||
* WIZnet WizFi360-EVB-Pico
|
||||
* Generic (configurable flash, I/O pins)
|
||||
|
||||
# Installing via Arduino Boards Manager
|
||||
|
||||
+1644
-14
File diff suppressed because it is too large
Load Diff
+31
-27
@@ -120,49 +120,49 @@ int __USBGetMouseReportID() {
|
||||
return __USBInstallKeyboard ? 2 : 1;
|
||||
}
|
||||
|
||||
static int __hid_report_len = 0;
|
||||
static uint8_t *__hid_report = nullptr;
|
||||
|
||||
static uint8_t *GetDescHIDReport(int *len) {
|
||||
static uint8_t *report = nullptr;
|
||||
int report_len = 0;
|
||||
|
||||
if (report) {
|
||||
free(report);
|
||||
report = nullptr;
|
||||
if (len) {
|
||||
*len = __hid_report_len;
|
||||
}
|
||||
return __hid_report;
|
||||
}
|
||||
|
||||
static void __SetupDescHIDReport() {
|
||||
if (__USBInstallKeyboard && __USBInstallMouse) {
|
||||
uint8_t desc_hid_report[] = {
|
||||
TUD_HID_REPORT_DESC_KEYBOARD(HID_REPORT_ID(1)),
|
||||
TUD_HID_REPORT_DESC_MOUSE(HID_REPORT_ID(2))
|
||||
};
|
||||
report_len = sizeof(desc_hid_report);
|
||||
report = (uint8_t *)malloc(report_len);
|
||||
if (report) {
|
||||
memcpy(report, desc_hid_report, report_len);
|
||||
__hid_report = (uint8_t *)malloc(sizeof(desc_hid_report));
|
||||
if (__hid_report) {
|
||||
__hid_report_len = sizeof(desc_hid_report);
|
||||
memcpy(__hid_report, desc_hid_report, __hid_report_len);
|
||||
}
|
||||
} else if (__USBInstallKeyboard && ! __USBInstallMouse) {
|
||||
uint8_t desc_hid_report[] = {
|
||||
TUD_HID_REPORT_DESC_KEYBOARD(HID_REPORT_ID(1))
|
||||
};
|
||||
report_len = sizeof(desc_hid_report);
|
||||
report = (uint8_t *)malloc(report_len);
|
||||
if (report) {
|
||||
memcpy(report, desc_hid_report, report_len);
|
||||
__hid_report = (uint8_t *)malloc(sizeof(desc_hid_report));
|
||||
if (__hid_report) {
|
||||
__hid_report_len = sizeof(desc_hid_report);
|
||||
memcpy(__hid_report, desc_hid_report, __hid_report_len);
|
||||
}
|
||||
} else { // if (!__USBInstallKeyboard && __USBInstallMouse) {
|
||||
} else if (! __USBInstallKeyboard && __USBInstallMouse) {
|
||||
uint8_t desc_hid_report[] = {
|
||||
TUD_HID_REPORT_DESC_MOUSE(HID_REPORT_ID(1))
|
||||
};
|
||||
report_len = sizeof(desc_hid_report);
|
||||
report = (uint8_t *)malloc(report_len);
|
||||
if (report) {
|
||||
memcpy(report, desc_hid_report, report_len);
|
||||
__hid_report = (uint8_t *)malloc(sizeof(desc_hid_report));
|
||||
if (__hid_report) {
|
||||
__hid_report_len = sizeof(desc_hid_report);
|
||||
memcpy(__hid_report, desc_hid_report, __hid_report_len);
|
||||
}
|
||||
} else {
|
||||
__hid_report = nullptr;
|
||||
__hid_report_len = 0;
|
||||
}
|
||||
|
||||
if (len) {
|
||||
*len = report_len;
|
||||
}
|
||||
return report;
|
||||
}
|
||||
|
||||
// Invoked when received GET HID REPORT DESCRIPTOR
|
||||
@@ -173,11 +173,13 @@ uint8_t const * tud_hid_descriptor_report_cb(uint8_t instance) {
|
||||
return GetDescHIDReport(nullptr);
|
||||
}
|
||||
|
||||
|
||||
static uint8_t *usbd_desc_cfg = nullptr;
|
||||
const uint8_t *tud_descriptor_configuration_cb(uint8_t index) {
|
||||
(void)index;
|
||||
static uint8_t *usbd_desc_cfg = nullptr;
|
||||
return usbd_desc_cfg;
|
||||
}
|
||||
|
||||
static void __SetupUSBDescriptor() {
|
||||
if (!usbd_desc_cfg) {
|
||||
bool hasHID = __USBInstallKeyboard || __USBInstallMouse;
|
||||
|
||||
@@ -229,7 +231,6 @@ const uint8_t *tud_descriptor_configuration_cb(uint8_t index) {
|
||||
}
|
||||
}
|
||||
}
|
||||
return usbd_desc_cfg;
|
||||
}
|
||||
|
||||
const uint16_t *tud_descriptor_string_cb(uint8_t index, uint16_t langid) {
|
||||
@@ -295,6 +296,9 @@ void __USBStart() {
|
||||
return;
|
||||
}
|
||||
|
||||
__SetupDescHIDReport();
|
||||
__SetupUSBDescriptor();
|
||||
|
||||
mutex_init(&__usb_mutex);
|
||||
|
||||
tusb_init();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#define ARDUINO_PICO_MAJOR 2
|
||||
#define ARDUINO_PICO_MINOR 0
|
||||
#define ARDUINO_PICO_REVISION 2
|
||||
#define ARDUINO_PICO_VERSION_STR "2.0.2"
|
||||
#define ARDUINO_PICO_MINOR 1
|
||||
#define ARDUINO_PICO_REVISION 1
|
||||
#define ARDUINO_PICO_VERSION_STR "2.1.1"
|
||||
|
||||
@@ -257,8 +257,23 @@ void SerialPIO::end() {
|
||||
if (!_running) {
|
||||
return;
|
||||
}
|
||||
// TODO: Deallocate PIO resources, stop them
|
||||
_pioSP[pio_get_index(_rxPIO)][_rxSM] = nullptr;
|
||||
if (_tx != NOPIN) {
|
||||
pio_sm_set_enabled(_txPIO, _txSM, false);
|
||||
}
|
||||
if (_rx != NOPIN) {
|
||||
pio_sm_set_enabled(_rxPIO, _rxSM, false);
|
||||
_pioSP[pio_get_index(_rxPIO)][_rxSM] = nullptr;
|
||||
// If no more active, disable the IRQ
|
||||
auto pioNum = pio_get_index(_rxPIO);
|
||||
bool used = false;
|
||||
for (int i = 0; i < 4; i++) {
|
||||
used = used || !!_pioSP[pioNum][i];
|
||||
}
|
||||
if (!used) {
|
||||
auto irqno = pioNum == 0 ? PIO0_IRQ_0 : PIO1_IRQ_0;
|
||||
irq_set_enabled(irqno, false);
|
||||
}
|
||||
}
|
||||
_running = false;
|
||||
}
|
||||
|
||||
|
||||
+30
-14
@@ -350,18 +350,6 @@ SerialUART::operator bool() {
|
||||
return _running;
|
||||
}
|
||||
|
||||
#if defined(PIN_SERIAL1_RTS)
|
||||
SerialUART Serial1(uart0, PIN_SERIAL1_TX, PIN_SERIAL1_RX, PIN_SERIAL1_RTS, PIN_SERIAL1_CTS);
|
||||
#else
|
||||
SerialUART Serial1(uart0, PIN_SERIAL1_TX, PIN_SERIAL1_RX);
|
||||
#endif
|
||||
|
||||
#if defined(PIN_SERIAL2_RTS)
|
||||
SerialUART Serial2(uart1, PIN_SERIAL2_TX, PIN_SERIAL2_RX, PIN_SERIAL2_RTS, PIN_SERIAL2_CTS);
|
||||
#else
|
||||
SerialUART Serial2(uart1, PIN_SERIAL2_TX, PIN_SERIAL2_RX);
|
||||
#endif
|
||||
|
||||
void arduino::serialEvent1Run(void) {
|
||||
if (serialEvent1 && Serial1.available()) {
|
||||
serialEvent1();
|
||||
@@ -406,10 +394,38 @@ void __not_in_flash_func(SerialUART::_handleIRQ)(bool inIRQ) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef __SERIAL1_DEVICE
|
||||
#define __SERIAL1_DEVICE uart0
|
||||
#endif
|
||||
#ifndef __SERIAL2_DEVICE
|
||||
#define __SERIAL2_DEVICE uart1
|
||||
#endif
|
||||
|
||||
#if defined(PIN_SERIAL1_RTS)
|
||||
SerialUART Serial1(__SERIAL1_DEVICE, PIN_SERIAL1_TX, PIN_SERIAL1_RX, PIN_SERIAL1_RTS, PIN_SERIAL1_CTS);
|
||||
#else
|
||||
SerialUART Serial1(__SERIAL1_DEVICE, PIN_SERIAL1_TX, PIN_SERIAL1_RX);
|
||||
#endif
|
||||
|
||||
#if defined(PIN_SERIAL2_RTS)
|
||||
SerialUART Serial2(__SERIAL2_DEVICE, PIN_SERIAL2_TX, PIN_SERIAL2_RX, PIN_SERIAL2_RTS, PIN_SERIAL2_CTS);
|
||||
#else
|
||||
SerialUART Serial2(__SERIAL2_DEVICE, PIN_SERIAL2_TX, PIN_SERIAL2_RX);
|
||||
#endif
|
||||
|
||||
|
||||
static void __not_in_flash_func(_uart0IRQ)() {
|
||||
Serial1._handleIRQ();
|
||||
if (__SERIAL1_DEVICE == uart0) {
|
||||
Serial1._handleIRQ();
|
||||
} else {
|
||||
Serial2._handleIRQ();
|
||||
}
|
||||
}
|
||||
|
||||
static void __not_in_flash_func(_uart1IRQ)() {
|
||||
Serial2._handleIRQ();
|
||||
if (__SERIAL2_DEVICE == uart1) {
|
||||
Serial2._handleIRQ();
|
||||
} else {
|
||||
Serial1._handleIRQ();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -45,26 +45,40 @@ extern "C" void noInterrupts() {
|
||||
// Only 1 GPIO IRQ callback for all pins, so we need to look at the pin it's for and
|
||||
// dispatch to the real callback manually
|
||||
auto_init_mutex(_irqMutex);
|
||||
static std::map<pin_size_t, voidFuncPtr> _map;
|
||||
class CBInfo {
|
||||
public:
|
||||
CBInfo(voidFuncPtr cb) : _cb(cb), _useParam(false), _param(nullptr) { };
|
||||
CBInfo(voidFuncPtrParam cbParam, void *param) : _cbParam(cbParam), _useParam(true), _param(param) { };
|
||||
void callback() {
|
||||
if (_useParam && _cbParam) {
|
||||
_cbParam(_param);
|
||||
} else if (_cb) {
|
||||
_cb();
|
||||
}
|
||||
}
|
||||
private:
|
||||
union {
|
||||
voidFuncPtr _cb;
|
||||
voidFuncPtrParam _cbParam;
|
||||
};
|
||||
bool _useParam;
|
||||
void *_param;
|
||||
};
|
||||
|
||||
|
||||
static std::map<pin_size_t, CBInfo> _map;
|
||||
|
||||
void _gpioInterruptDispatcher(uint gpio, uint32_t events) {
|
||||
(void) events;
|
||||
// Only need to lock around the std::map check, not the whole IRQ callback
|
||||
voidFuncPtr cb = nullptr;
|
||||
{
|
||||
CoreMutex m(&_irqMutex);
|
||||
if (m) {
|
||||
auto irq = _map.find(gpio);
|
||||
if (irq != _map.end()) {
|
||||
cb = irq->second;
|
||||
}
|
||||
CoreMutex m(&_irqMutex);
|
||||
if (m) {
|
||||
auto irq = _map.find(gpio);
|
||||
if (irq != _map.end()) {
|
||||
auto cb = irq->second;
|
||||
cb.callback();
|
||||
}
|
||||
}
|
||||
if (cb) {
|
||||
cb(); // Do the callback
|
||||
} else {
|
||||
// ERROR, but we're in an IRQ so do nothing
|
||||
}
|
||||
}
|
||||
|
||||
extern "C" void attachInterrupt(pin_size_t pin, voidFuncPtr callback, PinStatus mode) {
|
||||
@@ -84,7 +98,31 @@ extern "C" void attachInterrupt(pin_size_t pin, voidFuncPtr callback, PinStatus
|
||||
}
|
||||
noInterrupts();
|
||||
detachInterrupt(pin);
|
||||
_map.insert({pin, callback});
|
||||
CBInfo cb(callback);
|
||||
_map.insert({pin, cb});
|
||||
gpio_set_irq_enabled_with_callback(pin, events, true, _gpioInterruptDispatcher);
|
||||
interrupts();
|
||||
}
|
||||
|
||||
void attachInterruptParam(pin_size_t pin, voidFuncPtrParam callback, PinStatus mode, void *param) {
|
||||
CoreMutex m(&_irqMutex);
|
||||
if (!m) {
|
||||
return;
|
||||
}
|
||||
|
||||
uint32_t events;
|
||||
switch (mode) {
|
||||
case LOW: events = 1; break;
|
||||
case HIGH: events = 2; break;
|
||||
case FALLING: events = 4; break;
|
||||
case RISING: events = 8; break;
|
||||
case CHANGE: events = 4 | 8; break;
|
||||
default: return; // ERROR
|
||||
}
|
||||
noInterrupts();
|
||||
detachInterrupt(pin);
|
||||
CBInfo cb(callback, param);
|
||||
_map.insert({pin, cb});
|
||||
gpio_set_irq_enabled_with_callback(pin, events, true, _gpioInterruptDispatcher);
|
||||
interrupts();
|
||||
}
|
||||
|
||||
+2
-2
@@ -3,8 +3,8 @@
|
||||
|
||||
Equivalent to the Arduino SoftwareSerial library, an emulated UART using
|
||||
one or two PIO state machines is included in the Arduino-Pico core. This
|
||||
allows for up to 8 additional serial ports to be run from the RP2040 without
|
||||
requiring additional CPU resources.
|
||||
allows for up to 4 bidirectional or up to 8 unidirectional serial ports to
|
||||
be run from the RP2040 without requiring additional CPU resources.
|
||||
|
||||
Instantiate a ``SerialPIO(txpin, rxpin, fifosize)`` object in your sketch and then
|
||||
use it the same as any other serial port. Even, odd, and no parity modes
|
||||
|
||||
Binary file not shown.
@@ -1,8 +1,5 @@
|
||||
-iwithprefixbefore/cores/rp2040/api/deprecated-avr-comp/
|
||||
-iwithprefixbefore/lib/pico_base/
|
||||
-iwithprefixbefore/pico-extras/src/common/pico_audio/include
|
||||
-iwithprefixbefore/pico-extras/src/common/pico_util_buffer/include
|
||||
-iwithprefixbefore/pico-extras/src/rp2_common/pico_audio_i2s/include
|
||||
-iwithprefixbefore/pico-sdk/lib/tinyusb/src/
|
||||
-iwithprefixbefore/pico-sdk/src/boards/include
|
||||
-iwithprefixbefore/pico-sdk/src/common/pico_base/include
|
||||
|
||||
@@ -127,6 +127,7 @@
|
||||
-Wl,--wrap=powf
|
||||
-Wl,--wrap=powint
|
||||
-Wl,--wrap=powintf
|
||||
-Wl,--wrap=realloc
|
||||
-Wl,--wrap=remainder
|
||||
-Wl,--wrap=remainderf
|
||||
-Wl,--wrap=remquo
|
||||
|
||||
@@ -307,5 +307,12 @@ void SPIClassRP2040::setClockDivider(uint8_t uc_div) {
|
||||
(void) uc_div; // no-op
|
||||
}
|
||||
|
||||
SPIClassRP2040 SPI(spi0, PIN_SPI0_MISO, PIN_SPI0_SS, PIN_SPI0_SCK, PIN_SPI0_MOSI);
|
||||
SPIClassRP2040 SPI1(spi1, PIN_SPI1_MISO, PIN_SPI1_SS, PIN_SPI1_SCK, PIN_SPI1_MOSI);
|
||||
#ifndef __SPI0_DEVICE
|
||||
#define __SPI0_DEVICE spi0
|
||||
#endif
|
||||
#ifndef __SPI1_DEVICE
|
||||
#define __SPI1_DEVICE spi1
|
||||
#endif
|
||||
|
||||
SPIClassRP2040 SPI(__SPI0_DEVICE, PIN_SPI0_MISO, PIN_SPI0_SS, PIN_SPI0_SCK, PIN_SPI0_MOSI);
|
||||
SPIClassRP2040 SPI1(__SPI1_DEVICE, PIN_SPI1_MISO, PIN_SPI1_SS, PIN_SPI1_SCK, PIN_SPI1_MOSI);
|
||||
@@ -132,7 +132,6 @@ void TwoWire::begin(uint8_t addr) {
|
||||
irq_set_exclusive_handler(irqNo, i2c_hw_index(_i2c) == 0 ? _handler0 : _handler1);
|
||||
irq_set_enabled(irqNo, true);
|
||||
|
||||
|
||||
gpio_set_function(_sda, GPIO_FUNC_I2C);
|
||||
gpio_pull_up(_sda);
|
||||
gpio_set_function(_scl, GPIO_FUNC_I2C);
|
||||
@@ -192,7 +191,15 @@ void TwoWire::end() {
|
||||
// ERROR
|
||||
return;
|
||||
}
|
||||
|
||||
if (_slave) {
|
||||
int irqNo = I2C0_IRQ + i2c_hw_index(_i2c);
|
||||
irq_remove_handler(irqNo, i2c_hw_index(_i2c) == 0 ? _handler0 : _handler1);
|
||||
irq_set_enabled(irqNo, false);
|
||||
}
|
||||
|
||||
i2c_deinit(_i2c);
|
||||
|
||||
pinMode(_sda, INPUT);
|
||||
pinMode(_scl, INPUT);
|
||||
_running = false;
|
||||
@@ -216,7 +223,7 @@ size_t TwoWire::requestFrom(uint8_t address, size_t quantity, bool stopBit) {
|
||||
}
|
||||
|
||||
_buffLen = i2c_read_blocking_until(_i2c, address, _buff, quantity, !stopBit, make_timeout_time_ms(_timeout));
|
||||
if (_buffLen == PICO_ERROR_GENERIC) {
|
||||
if ((_buffLen == PICO_ERROR_GENERIC) || (_buffLen == PICO_ERROR_TIMEOUT)) {
|
||||
_buffLen = 0;
|
||||
}
|
||||
_buffOff = 0;
|
||||
@@ -377,5 +384,12 @@ void TwoWire::onRequest(void(*function)(void)) {
|
||||
_onRequestCallback = function;
|
||||
}
|
||||
|
||||
TwoWire Wire(i2c0, PIN_WIRE0_SDA, PIN_WIRE0_SCL);
|
||||
TwoWire Wire1(i2c1, PIN_WIRE1_SDA, PIN_WIRE1_SCL);
|
||||
#ifndef __WIRE0_DEVICE
|
||||
#define __WIRE0_DEVICE i2c0
|
||||
#endif
|
||||
#ifndef __WIRE1_DEVICE
|
||||
#define __WIRE1_DEVICE i2c1
|
||||
#endif
|
||||
|
||||
TwoWire Wire(__WIRE0_DEVICE, PIN_WIRE0_SDA, PIN_WIRE0_SCL);
|
||||
TwoWire Wire1(__WIRE1_DEVICE, PIN_WIRE1_SDA, PIN_WIRE1_SCL);
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "framework-arduinopico",
|
||||
"version": "1.20002.0",
|
||||
"version": "1.20101.0",
|
||||
"description": "Arduino Wiring-based Framework (RPi Pico RP2040)",
|
||||
"keywords": [
|
||||
"framework",
|
||||
|
||||
@@ -116,16 +116,6 @@ sed "s/version=.*/version=$ver/g" |\
|
||||
sed -E "s/name=([a-zA-Z0-9\ -]+).*/name=\1($ver)/g"\
|
||||
> $outdir/platform.txt
|
||||
|
||||
# Put core version and short hash of git version into core_version.h
|
||||
ver_define=`echo $plain_ver | tr "[:lower:].\055" "[:upper:]_"`
|
||||
echo Ver define: $ver_define
|
||||
echo \#define ARDUINO_RP2040_GIT_VER 0x`git rev-parse --short=8 HEAD 2>/dev/null` >$outdir/cores/rp2040/core_version.h
|
||||
echo \#define ARDUINO_RP2040_GIT_DESC `git describe --tags 2>/dev/null` >>$outdir/cores/rp2040/core_version.h
|
||||
echo \#define ARDUINO_RP2040_RELEASE_$ver_define >>$outdir/cores/rp2040/core_version.h
|
||||
echo \#define ARDUINO_RP2040_RELEASE \"$ver_define\" >>$outdir/cores/rp2040/core_version.h
|
||||
|
||||
sed -i 's/"version": .*/"version": "'$visible_ver'"/' $outdir/package.json
|
||||
|
||||
# Zip the package
|
||||
pushd package/versions/$visible_ver
|
||||
echo "Making $package_name.zip"
|
||||
|
||||
@@ -95,6 +95,12 @@
|
||||
{
|
||||
"name": "WIZnet W5100S-EVB-Pico"
|
||||
},
|
||||
{
|
||||
"name": "WIZnet 5500-EVB-Pico"
|
||||
},
|
||||
{
|
||||
"name": "WIZnet WizFi360-EVB-Pico"
|
||||
},
|
||||
{
|
||||
"name": "Generic RP2040 Module"
|
||||
}
|
||||
@@ -102,22 +108,22 @@
|
||||
"toolsDependencies": [
|
||||
{
|
||||
"packager": "rp2040",
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-gcc"
|
||||
},
|
||||
{
|
||||
"packager": "rp2040",
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-mklittlefs"
|
||||
},
|
||||
{
|
||||
"packager": "rp2040",
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-elf2uf2"
|
||||
},
|
||||
{
|
||||
"packager": "rp2040",
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-pioasm"
|
||||
},
|
||||
{
|
||||
@@ -127,7 +133,7 @@
|
||||
},
|
||||
{
|
||||
"packager": "rp2040",
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-openocd"
|
||||
}
|
||||
],
|
||||
@@ -138,56 +144,56 @@
|
||||
],
|
||||
"tools": [
|
||||
{
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-openocd",
|
||||
"systems": [
|
||||
{
|
||||
"host": "aarch64-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/aarch64-linux-gnu.openocd-e3428fadb.220212.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.openocd-e3428fadb.220212.tar.gz",
|
||||
"checksum": "SHA-256:d1d95978101c69c3bc777e61ba70077bf9dc4b3245aa7dd93171acaec4d29fb1",
|
||||
"size": "5607214"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/aarch64-linux-gnu.openocd-e3428fadb.220607.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.openocd-e3428fadb.220607.tar.gz",
|
||||
"checksum": "SHA-256:e796e6d2eac20cf90be4e61fc0a5ed16d1d26269cf749ec7829650d2595810b2",
|
||||
"size": "5607245"
|
||||
},
|
||||
{
|
||||
"host": "arm-linux-gnueabihf",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/arm-linux-gnueabihf.openocd-e3428fadb.220212.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.openocd-e3428fadb.220212.tar.gz",
|
||||
"checksum": "SHA-256:81373c1e12a88e382a587688343c2e2f2f1f999d38334b7b6ded174929cc9b88",
|
||||
"size": "5344032"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/arm-linux-gnueabihf.openocd-e3428fadb.220607.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.openocd-e3428fadb.220607.tar.gz",
|
||||
"checksum": "SHA-256:bbb9b2b1504555b1804538786074e776ebc4b2dded36f12f85a72ad6ba67f402",
|
||||
"size": "5344211"
|
||||
},
|
||||
{
|
||||
"host": "i686-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-linux-gnu.openocd-e3428fadb.220212.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.openocd-e3428fadb.220212.tar.gz",
|
||||
"checksum": "SHA-256:6a4dd98422a187c7725fc349b045b55e4742166c65461847d1bd59537242b0be",
|
||||
"size": "5168258"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-linux-gnu.openocd-e3428fadb.220607.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.openocd-e3428fadb.220607.tar.gz",
|
||||
"checksum": "SHA-256:7162ff1807748f11bb711b33c64139eae37b05d03458d9b0ac9a8e0d36aeb1a9",
|
||||
"size": "5168326"
|
||||
},
|
||||
{
|
||||
"host": "i686-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-w64-mingw32.openocd-e3428fadb.220212.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.openocd-e3428fadb.220212.zip",
|
||||
"checksum": "SHA-256:0643903fcd887a8423cb4ba5329565b499c206921f77ad2e59ae32c472a26dd7",
|
||||
"size": "2156820"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-w64-mingw32.openocd-e3428fadb.220607.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.openocd-e3428fadb.220607.zip",
|
||||
"checksum": "SHA-256:3cbdcd63ca2084c9b479c781f8efefdec1481917c1fc3fe33d230ea38464e624",
|
||||
"size": "2156819"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-apple-darwin",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-apple-darwin14.openocd-e3428fadb.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.openocd-e3428fadb.220212.tar.gz",
|
||||
"checksum": "SHA-256:913b65baeeef1b60caf202e69cde4cd5a3ba0ed2f75f2600adfb3dcf4b3899ef",
|
||||
"size": "2002482"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-apple-darwin14.openocd-e3428fadb.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.openocd-e3428fadb.220607.tar.gz",
|
||||
"checksum": "SHA-256:1159ad88b998e040c2f33d8ce83e5e0130c4cf73c05320efe70ffdd1f6a52055",
|
||||
"size": "2002498"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-linux-gnu.openocd-e3428fadb.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.openocd-e3428fadb.220212.tar.gz",
|
||||
"checksum": "SHA-256:63b2be48c1438d2a09f4ed65d89e555176f18753886555cf48f861e9288d7dc1",
|
||||
"size": "5540524"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-linux-gnu.openocd-e3428fadb.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.openocd-e3428fadb.220607.tar.gz",
|
||||
"checksum": "SHA-256:388d53ab399bbac0c1ed097fc1bfe08788e765ee78faf970c6e06b1eeb88bdac",
|
||||
"size": "5540543"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-w64-mingw32.openocd-e3428fadb.220212.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.openocd-e3428fadb.220212.zip",
|
||||
"checksum": "SHA-256:0643903fcd887a8423cb4ba5329565b499c206921f77ad2e59ae32c472a26dd7",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-w64-mingw32.openocd-e3428fadb.220607.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.openocd-e3428fadb.220607.zip",
|
||||
"checksum": "SHA-256:df3b5ed63c93f24a49ade6ecd1ec5bf84eb97677b7f3bd66e302b7871f20c2ed",
|
||||
"size": "2156820"
|
||||
}
|
||||
]
|
||||
@@ -255,226 +261,226 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-gcc",
|
||||
"systems": [
|
||||
{
|
||||
"host": "aarch64-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/aarch64-linux-gnu.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"checksum": "SHA-256:7773b43b9c0bf5b7cdb2299e9d1b151df97e0a2ded4428809ec68264ac9818a9",
|
||||
"size": "102741416"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/aarch64-linux-gnu.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"checksum": "SHA-256:ec0bbb010f8acbcddcb4671a98eada560d6dd9ea2bc8c6a2247198eaa8b15be0",
|
||||
"size": "78042296"
|
||||
},
|
||||
{
|
||||
"host": "arm-linux-gnueabihf",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/arm-linux-gnueabihf.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"checksum": "SHA-256:c422910ef0e29528939e037ea3c518a532726111604b85b27f3f245820680ccb",
|
||||
"size": "95383443"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/arm-linux-gnueabihf.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"checksum": "SHA-256:c18839a74fe1ec1b449d80e6b7de358bd1d9444ff454edaf57d79fe2f734d60e",
|
||||
"size": "73499374"
|
||||
},
|
||||
{
|
||||
"host": "i686-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-linux-gnu.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"checksum": "SHA-256:6306791b43de955c4a4d0a1b8972e0f696206591a810eefc16b906b157322bd3",
|
||||
"size": "105350371"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-linux-gnu.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"checksum": "SHA-256:e6546899155267e5539889764610439fdbeba38df0e498a9fd643aad13ba49f0",
|
||||
"size": "79642507"
|
||||
},
|
||||
{
|
||||
"host": "i686-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-w64-mingw32.arm-none-eabi-ed6d983.220212.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.arm-none-eabi-ed6d983.220212.zip",
|
||||
"checksum": "SHA-256:b00aa3594d1911bea07c1dbf31b9a63430f4dcb91c7b3b1341f8551d361d405f",
|
||||
"size": "105568357"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-w64-mingw32.arm-none-eabi-5dd03b9.220607.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.arm-none-eabi-5dd03b9.220607.zip",
|
||||
"checksum": "SHA-256:867c4bc810db9388fe0d814fc21ac81479a1e2be1c45f8e150981bb33846e04d",
|
||||
"size": "82878616"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-apple-darwin",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-apple-darwin14.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"checksum": "SHA-256:e93b967d1fb6ed0fc7cf6a5161e22a597dd05080c1353ac74e2a42ddf8dfe98d",
|
||||
"size": "107429038"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-apple-darwin14.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"checksum": "SHA-256:ef91ab4e0d7a66b3ae683d6d4b5ca8526eab7a7572a3aec60dd6a04795061bbe",
|
||||
"size": "82271912"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-linux-gnu.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.arm-none-eabi-ed6d983.220212.tar.gz",
|
||||
"checksum": "SHA-256:047c4d482cf77e09bd8069fc9d5b28b1e0c76440ad81583a0fc3a8e809959bb8",
|
||||
"size": "106740897"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-linux-gnu.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.arm-none-eabi-5dd03b9.220607.tar.gz",
|
||||
"checksum": "SHA-256:59d16d192b8f623261f2c0605164da24e9257b1de210c367ea872131ef4d9f45",
|
||||
"size": "80508303"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-w64-mingw32.arm-none-eabi-ed6d983.220212.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.arm-none-eabi-ed6d983.220212.zip",
|
||||
"checksum": "SHA-256:5c15725628a3dbd47a8fa8f9a9aab7a2221815ec9bf85dc2080ce19166316ae6",
|
||||
"size": "110420777"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-w64-mingw32.arm-none-eabi-5dd03b9.220607.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.arm-none-eabi-5dd03b9.220607.zip",
|
||||
"checksum": "SHA-256:b140ec4e5986b73249a6350a53d9826ad5d74a8a2af12adf3d6c13bebc720c88",
|
||||
"size": "86320223"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-elf2uf2",
|
||||
"systems": [
|
||||
{
|
||||
"host": "aarch64-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/aarch64-linux-gnu.elf2uf2-2062372.220212.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.elf2uf2-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:8cb7ce703b0fa6f2fce6b124ae6f34ad0b866aa4a58096f22b66b1251c1b11c0",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/aarch64-linux-gnu.elf2uf2-2062372.220607.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.elf2uf2-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:a98b46d71e837927867789810b8577dcbc8f53c618adb9bb4083c1e2fa1cf483",
|
||||
"size": "79853"
|
||||
},
|
||||
{
|
||||
"host": "arm-linux-gnueabihf",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/arm-linux-gnueabihf.elf2uf2-2062372.220212.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.elf2uf2-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:790d46b411c16a4a210a91436eb4bdc81fb34f0119148a8f9c4b09489489a54d",
|
||||
"size": "54244"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/arm-linux-gnueabihf.elf2uf2-2062372.220607.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.elf2uf2-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:64df2a9dbc6b5546a07bd15c26c4b6e0310d0b937e5d921f83b0f51ef02f1734",
|
||||
"size": "54249"
|
||||
},
|
||||
{
|
||||
"host": "i686-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-linux-gnu.elf2uf2-2062372.220212.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.elf2uf2-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:7c05c70f761bb6caa986d24ac1065367fe906ff7f0434cf4b0112ace331f74bc",
|
||||
"size": "87891"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-linux-gnu.elf2uf2-2062372.220607.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.elf2uf2-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:1b877ef797c281b5dd2f4d98409ba83db120e528aac94f4a9a34effa2262eaa7",
|
||||
"size": "87893"
|
||||
},
|
||||
{
|
||||
"host": "i686-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-w64-mingw32.elf2uf2-2062372.220212.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.elf2uf2-2062372.220212.zip",
|
||||
"checksum": "SHA-256:e6f0578ea781b160390994d3e95bedfec01e212d47243b1adb84f910a06bcba4",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-w64-mingw32.elf2uf2-2062372.220607.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.elf2uf2-2062372.220607.zip",
|
||||
"checksum": "SHA-256:eed4693771f27851092d182e8477eee9c393cce7ddffde18d7492e78bd65140c",
|
||||
"size": "70405"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-apple-darwin",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-apple-darwin14.elf2uf2-2062372.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.elf2uf2-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:d65de7218eaf01c9bf58fa22bd9e1e7c10c054213948b4b62f648a058d09b4de",
|
||||
"size": "81981"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-apple-darwin14.elf2uf2-2062372.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.elf2uf2-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:af65feef470ce6b4b48102ea996703890f8d8d9604207f0781022b7912ce2cbd",
|
||||
"size": "81982"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-linux-gnu.elf2uf2-2062372.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.elf2uf2-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:ba7795ed49c54f3f52caee675b0fd078f6fb8498a47bf7e5d7457065271df338",
|
||||
"size": "79585"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-linux-gnu.elf2uf2-2062372.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.elf2uf2-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:968240efe170187c4ece497c7abbb81bca274b6484f0df28e2b7a12e1c088f5f",
|
||||
"size": "79588"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-w64-mingw32.elf2uf2-2062372.220212.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.elf2uf2-2062372.220212.zip",
|
||||
"checksum": "SHA-256:02c7684ed1aea4e18216ec6bbbcedeb482c5f23ad7d5eb9dcb942b8ae6cad5ae",
|
||||
"size": "78279"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-w64-mingw32.elf2uf2-2062372.220607.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.elf2uf2-2062372.220607.zip",
|
||||
"checksum": "SHA-256:04b85b5b515ec620a5b4106fb1025485de0b3d36482aab7024088e618e605e9d",
|
||||
"size": "78280"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-pioasm",
|
||||
"systems": [
|
||||
{
|
||||
"host": "aarch64-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/aarch64-linux-gnu.pioasm-2062372.220212.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.pioasm-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:9ea17ecf0e492bc6a971f6a78780c3b3c6ee644d52e056cba08a708ac225add2",
|
||||
"size": "453558"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/aarch64-linux-gnu.pioasm-2062372.220607.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.pioasm-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:d08d22b2eecbf17a8afd199eb4ce89c0f6fe2ffa90408d7762d4de7f91c88e13",
|
||||
"size": "453559"
|
||||
},
|
||||
{
|
||||
"host": "arm-linux-gnueabihf",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/arm-linux-gnueabihf.pioasm-2062372.220212.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.pioasm-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:c7af69227a3b3c54ccf87122b18842460a263bd711abf93336794ce5f905c284",
|
||||
"size": "360559"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/arm-linux-gnueabihf.pioasm-2062372.220607.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.pioasm-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:7bc20faea8b8d115fec189248b3dd3470128d0f7da855a61cb8a1fb6d4955450",
|
||||
"size": "360566"
|
||||
},
|
||||
{
|
||||
"host": "i686-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-linux-gnu.pioasm-2062372.220212.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.pioasm-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:f66b9bde3d6859d43049b019fb639dd0bfafcd43f1389ffc499d18949bcf1808",
|
||||
"size": "511397"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-linux-gnu.pioasm-2062372.220607.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.pioasm-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:b8d26abd632e9599bc82c67619debac45fca0e5dd0daabe5a0ecad4cfd11183e",
|
||||
"size": "511402"
|
||||
},
|
||||
{
|
||||
"host": "i686-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-w64-mingw32.pioasm-2062372.220212.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.pioasm-2062372.220212.zip",
|
||||
"checksum": "SHA-256:89cfa44101dade30000cfaa5985de7f0e7aba93d03dc45ba962f97226ae4e41f",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-w64-mingw32.pioasm-2062372.220607.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.pioasm-2062372.220607.zip",
|
||||
"checksum": "SHA-256:ab52ae2fd59fe3093060a238297f88d50645dca02cd12f59e882ce7cb4533b25",
|
||||
"size": "385748"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-apple-darwin",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-apple-darwin14.pioasm-2062372.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.pioasm-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:d531c911e6eba0333379af04dd807917659bd4d34be9f4bd6792aeff55ab15a9",
|
||||
"size": "480495"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-apple-darwin14.pioasm-2062372.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.pioasm-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:fb22e0c5d6b3e681a8518992a8183b277ebeb5a3876b1c98a247dda4e2c495e7",
|
||||
"size": "480494"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-linux-gnu.pioasm-2062372.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.pioasm-2062372.220212.tar.gz",
|
||||
"checksum": "SHA-256:2cd4aa8af98558461cb7b85b21830ea854a430a3e57668d618c5f1cd5e389809",
|
||||
"size": "458730"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-linux-gnu.pioasm-2062372.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.pioasm-2062372.220607.tar.gz",
|
||||
"checksum": "SHA-256:f5ea7d22357db358c7185896858463d63310391678bf7425f203cc2baf35789d",
|
||||
"size": "458726"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-w64-mingw32.pioasm-2062372.220212.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.pioasm-2062372.220212.zip",
|
||||
"checksum": "SHA-256:ba586e67f4b309690a51fca70fdd26f38b68951b0fee4dc8333183ef6429833a",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-w64-mingw32.pioasm-2062372.220607.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.pioasm-2062372.220607.zip",
|
||||
"checksum": "SHA-256:5b63d07bb53ec4e25817d3a1195cd03f156c47dc00c5fdaf4921edb1baa9da9c",
|
||||
"size": "408649"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"version": "1.3.3-a-ed6d983",
|
||||
"version": "1.3.4-c-5dd03b9",
|
||||
"name": "pqt-mklittlefs",
|
||||
"systems": [
|
||||
{
|
||||
"host": "aarch64-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/aarch64-linux-gnu.mklittlefs-affa497.220212.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.mklittlefs-affa497.220212.tar.gz",
|
||||
"checksum": "SHA-256:2455f5ca6cb1f7b73ed1cb55d4d2261d249c1b24915bd4e66e28f037a0a13116",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/aarch64-linux-gnu.mklittlefs-affa497.220607.tar.gz",
|
||||
"archiveFileName": "aarch64-linux-gnu.mklittlefs-affa497.220607.tar.gz",
|
||||
"checksum": "SHA-256:46a2ee723b6dcad3f229aa6f97a8efd55224f7aafea77ac5c232aa5261720589",
|
||||
"size": "47271"
|
||||
},
|
||||
{
|
||||
"host": "arm-linux-gnueabihf",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/arm-linux-gnueabihf.mklittlefs-affa497.220212.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.mklittlefs-affa497.220212.tar.gz",
|
||||
"checksum": "SHA-256:f4b71138f1469e4b9ce82b3b21252aca265a88d56a5d48513dbb5c6d58b19841",
|
||||
"size": "40807"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/arm-linux-gnueabihf.mklittlefs-affa497.220607.tar.gz",
|
||||
"archiveFileName": "arm-linux-gnueabihf.mklittlefs-affa497.220607.tar.gz",
|
||||
"checksum": "SHA-256:39462b3b88b614484c9fbfd7617af17440f9de4ddeb17bdb62b7bc615cae3a18",
|
||||
"size": "40810"
|
||||
},
|
||||
{
|
||||
"host": "i686-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-linux-gnu.mklittlefs-affa497.220212.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.mklittlefs-affa497.220212.tar.gz",
|
||||
"checksum": "SHA-256:ed1011230c75447dad3d912b7b5607ddcc59e093ee7ebd653fb05274bc876f4c",
|
||||
"size": "50909"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-linux-gnu.mklittlefs-affa497.220607.tar.gz",
|
||||
"archiveFileName": "i686-linux-gnu.mklittlefs-affa497.220607.tar.gz",
|
||||
"checksum": "SHA-256:c8eb593e6fc8bdc386566a72dd9a75f970a9a71fd4e069c0dca217cbe4b22060",
|
||||
"size": "50913"
|
||||
},
|
||||
{
|
||||
"host": "i686-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/i686-w64-mingw32.mklittlefs-affa497.220212.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.mklittlefs-affa497.220212.zip",
|
||||
"checksum": "SHA-256:1289f51c674ebdc568843b82c88db21eb4c295f3b15c26398d31266b9da63b4c",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/i686-w64-mingw32.mklittlefs-affa497.220607.zip",
|
||||
"archiveFileName": "i686-w64-mingw32.mklittlefs-affa497.220607.zip",
|
||||
"checksum": "SHA-256:6fc3c989850ab4acf00509b86c77edf1cdd2f38ec95c3614ed633f8131d3f86d",
|
||||
"size": "334050"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-apple-darwin",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-apple-darwin14.mklittlefs-affa497.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.mklittlefs-affa497.220212.tar.gz",
|
||||
"checksum": "SHA-256:0c0d7d8c80739ed79bc5a41e831d0229b6378e87f4c58f148d884814f1ad46d2",
|
||||
"size": "365757"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-apple-darwin14.mklittlefs-affa497.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-apple-darwin14.mklittlefs-affa497.220607.tar.gz",
|
||||
"checksum": "SHA-256:a949b054259cea773779305f60b2748b51e1f40c53fe7c00ae3959d6688ce754",
|
||||
"size": "365751"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-pc-linux-gnu",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-linux-gnu.mklittlefs-affa497.220212.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.mklittlefs-affa497.220212.tar.gz",
|
||||
"checksum": "SHA-256:c504429c24cfea9bf841cbf0caa29bbe0115e72c94c18f949451ffa540d6cacc",
|
||||
"size": "49766"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-linux-gnu.mklittlefs-affa497.220607.tar.gz",
|
||||
"archiveFileName": "x86_64-linux-gnu.mklittlefs-affa497.220607.tar.gz",
|
||||
"checksum": "SHA-256:d1910196398bdeffae320cb69b1df79126ea086688d9e36a078dd0816f88dace",
|
||||
"size": "49774"
|
||||
},
|
||||
{
|
||||
"host": "x86_64-mingw32",
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.3-a/x86_64-w64-mingw32.mklittlefs-affa497.220212.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.mklittlefs-affa497.220212.zip",
|
||||
"checksum": "SHA-256:4ada867888513596fa51bf78c98d9e970de9b8f1eec4f88d85e6e7621704fb91",
|
||||
"size": "347602"
|
||||
"url": "https://github.com/earlephilhower/pico-quick-toolchain/releases/download/1.3.4-c/x86_64-w64-mingw32.mklittlefs-affa497.220607.zip",
|
||||
"archiveFileName": "x86_64-w64-mingw32.mklittlefs-affa497.220607.zip",
|
||||
"checksum": "SHA-256:8be0f754073e036dc9a144fd3cf62a46fbd6d215cad179c2ba17e598848a1b57",
|
||||
"size": "347601"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
+6
-4
@@ -20,7 +20,7 @@
|
||||
# https://github.com/arduino/Arduino/wiki/Arduino-IDE-1.5---3rd-party-Hardware-specification
|
||||
|
||||
name=Raspberry Pi RP2040 Boards
|
||||
version=2.0.2
|
||||
version=2.1.1
|
||||
|
||||
runtime.tools.pqt-gcc.path={runtime.platform.path}/system/arm-none-eabi
|
||||
runtime.tools.pqt-python3.path={runtime.platform.path}/system/python3
|
||||
@@ -43,10 +43,9 @@ compiler.warning_flags.all=-Wall -Wextra -Werror=return-type -Wno-ignored-qualif
|
||||
|
||||
compiler.defines={build.led} {build.usbstack_flags} -DCFG_TUSB_MCU=OPT_MCU_RP2040 -DUSB_VID={build.vid} -DUSB_PID={build.pid} '-DUSB_MANUFACTURER={build.usb_manufacturer}' '-DUSB_PRODUCT={build.usb_product}'
|
||||
compiler.includes="-iprefix{runtime.platform.path}/" "@{runtime.platform.path}/lib/platform_inc.txt"
|
||||
compiler.flags=-march=armv6-m -mcpu=cortex-m0plus -mthumb -ffunction-sections -fdata-sections -fno-exceptions
|
||||
compiler.flags=-march=armv6-m -mcpu=cortex-m0plus -mthumb -ffunction-sections -fdata-sections {build.flags.exceptions} {build.flags.stackprotect}
|
||||
compiler.wrap="@{runtime.platform.path}/lib/platform_wrap.txt"
|
||||
compiler.libpico="{runtime.platform.path}/lib/libpico.a"
|
||||
compiler.libstdcpp="-lstdc++"
|
||||
|
||||
compiler.c.cmd=arm-none-eabi-gcc
|
||||
compiler.c.flags=-c {compiler.warning_flags} {compiler.defines} {compiler.flags} {compiler.includes} -std=gnu17 -g
|
||||
@@ -88,6 +87,9 @@ build.flags.rtti=-fno-rtti
|
||||
build.fs_start=
|
||||
build.fs_end=
|
||||
build.usbstack_flags=
|
||||
build.flags.libstdcpp=-lstdc++
|
||||
build.flags.exceptions=-fno-exceptions
|
||||
build.flags.stackprotect=
|
||||
|
||||
build.boot2=boot2_generic_03h_4_padded_checksum
|
||||
|
||||
@@ -119,7 +121,7 @@ recipe.hooks.linking.prelink.1.pattern="{runtime.tools.pqt-python3.path}/python3
|
||||
recipe.hooks.linking.prelink.2.pattern="{compiler.path}{compiler.S.cmd}" {compiler.c.elf.flags} {compiler.c.elf.extra_flags} -c "{runtime.platform.path}/boot2/{build.boot2}.S" "-I{runtime.platform.path}/pico-sdk/src/rp2040/hardware_regs/include/" "-I{runtime.platform.path}/pico-sdk/src/common/pico_binary_info/include" -o "{build.path}/boot2.o"
|
||||
|
||||
## Combine gc-sections, archives, and objects
|
||||
recipe.c.combine.pattern="{compiler.path}{compiler.c.elf.cmd}" "-L{build.path}" {compiler.c.elf.flags} {compiler.c.elf.extra_flags} {compiler.ldflags} "-Wl,--script={build.path}/memmap_default.ld" "-Wl,-Map,{build.path}/{build.project_name}.map" -o "{build.path}/{build.project_name}.elf" -Wl,--start-group {object_files} "{build.path}/{archive_file}" "{build.path}/boot2.o" {compiler.libraries.ldflags} {compiler.libpico} -lm -lc {compiler.libstdcpp} -lc -Wl,--end-group
|
||||
recipe.c.combine.pattern="{compiler.path}{compiler.c.elf.cmd}" "-L{build.path}" {compiler.c.elf.flags} {compiler.c.elf.extra_flags} {compiler.ldflags} "-Wl,--script={build.path}/memmap_default.ld" "-Wl,-Map,{build.path}/{build.project_name}.map" -o "{build.path}/{build.project_name}.elf" -Wl,--start-group {object_files} "{build.path}/{archive_file}" "{build.path}/boot2.o" {compiler.libraries.ldflags} {compiler.libpico} -lm -lc {build.flags.libstdcpp} -lc -Wl,--end-group
|
||||
|
||||
## Create output (UF2 file)
|
||||
recipe.objcopy.uf2.pattern="{runtime.tools.pqt-elf2uf2.path}/elf2uf2" "{build.path}/{build.project_name}.elf" "{build.path}/{build.project_name}.uf2"
|
||||
|
||||
+1
-1
@@ -212,7 +212,7 @@ function install_ide()
|
||||
cat rp2040/platform.local.txt
|
||||
echo -e "\n----\n"
|
||||
cd rp2040/tools
|
||||
python3 get.py -q
|
||||
python3 get.py
|
||||
if [ "$WINDOWS" = "1" ]; then
|
||||
# Because the symlinks don't work well under Win32, we need to add the path to this copy, not the original...
|
||||
relbin=$(realpath $PWD/../system/arm-none-eabi/bin)
|
||||
|
||||
+1
-12
@@ -15,8 +15,6 @@ import tarfile
|
||||
import zipfile
|
||||
import re
|
||||
|
||||
verbose = True
|
||||
|
||||
if sys.version_info[0] == 3:
|
||||
from urllib.request import urlretrieve
|
||||
else:
|
||||
@@ -40,8 +38,7 @@ def mkdir_p(path):
|
||||
raise
|
||||
|
||||
def report_progress(count, blockSize, totalSize):
|
||||
global verbose
|
||||
if verbose:
|
||||
if sys.stdout.isatty():
|
||||
percent = int(count*blockSize*100/totalSize)
|
||||
percent = min(100, percent)
|
||||
sys.stdout.write("\r%d%%" % percent)
|
||||
@@ -121,14 +118,6 @@ def identify_platform():
|
||||
return arduino_platform_names[sys_name][bits]
|
||||
|
||||
def main():
|
||||
global verbose
|
||||
# Support optional "-q" quiet mode simply
|
||||
if len(sys.argv) == 2:
|
||||
if sys.argv[1] == "-q":
|
||||
verbose = False
|
||||
# Remove a symlink generated in 2.6.3 which causes later issues since the tarball can't properly overwrite it
|
||||
if (os.path.exists('python3/python3')):
|
||||
os.unlink('python3/python3')
|
||||
print('Platform: {0}'.format(identify_platform()))
|
||||
tools_to_download = load_tools_list('../package/package_pico_index.template.json', identify_platform())
|
||||
mkdir_p(dist_dir)
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
"variant": "challenger_2040_wifi_ble",
|
||||
"boot2_source": "boot2_w25q080_2_padded_checksum.S",
|
||||
"usb_vid": "0x2e8a",
|
||||
"usb_pid": "0x1101",
|
||||
"usb_pid": "0x102C",
|
||||
"usb_manufacturer": "iLabs",
|
||||
"usb_product": "Challenger 2040 WiFi/BLE"
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
"variant": "wiznet_5100s_evb_pico",
|
||||
"boot2_source": "boot2_w25q080_2_padded_checksum.S",
|
||||
"usb_vid": "0x2e8a",
|
||||
"usb_pid": "0x1008",
|
||||
"usb_pid": "0x1027",
|
||||
"usb_manufacturer": "WIZnet",
|
||||
"usb_product": "W5100S-EVB-Pico"
|
||||
}
|
||||
|
||||
@@ -0,0 +1,52 @@
|
||||
{
|
||||
"build": {
|
||||
"core": "earlephilhower",
|
||||
"cpu": "cortex-m0plus",
|
||||
"extra_flags": "-D ARDUINO_WIZNET_5500_EVB_PICO -DARDUINO_ARCH_RP2040 -DUSBD_MAX_POWER_MA=250",
|
||||
"f_cpu": "133000000L",
|
||||
"hwids": [
|
||||
[
|
||||
"0x2E8A",
|
||||
"0x00C0"
|
||||
]
|
||||
],
|
||||
"mcu": "rp2040",
|
||||
"arduino": {
|
||||
"earlephilhower": {
|
||||
"variant": "wiznet_5500_evb_pico",
|
||||
"boot2_source": "boot2_w25q080_2_padded_checksum.S",
|
||||
"usb_vid": "0x2e8a",
|
||||
"usb_pid": "0x1029",
|
||||
"usb_manufacturer": "WIZnet",
|
||||
"usb_product": "W5500-EVB-Pico"
|
||||
}
|
||||
}
|
||||
},
|
||||
"debug": {
|
||||
"jlink_device": "RP2040_M0_0",
|
||||
"openocd_target": "rp2040.cfg",
|
||||
"svd_path": "rp2040.svd"
|
||||
},
|
||||
"frameworks": [
|
||||
"arduino"
|
||||
],
|
||||
"name": "W5500-EVB-Pico",
|
||||
"upload": {
|
||||
"maximum_ram_size": 270336,
|
||||
"maximum_size": 2097152,
|
||||
"require_upload_port": true,
|
||||
"native_usb": true,
|
||||
"use_1200bps_touch": true,
|
||||
"wait_for_upload_port": false,
|
||||
"protocol": "picotool",
|
||||
"protocols": [
|
||||
"cmsis-dap",
|
||||
"jlink",
|
||||
"raspberrypi-swd",
|
||||
"picotool",
|
||||
"picoprobe"
|
||||
]
|
||||
},
|
||||
"url": "https://www.raspberrypi.org/products/raspberry-pi-pico/",
|
||||
"vendor": "WIZnet"
|
||||
}
|
||||
@@ -0,0 +1,52 @@
|
||||
{
|
||||
"build": {
|
||||
"core": "earlephilhower",
|
||||
"cpu": "cortex-m0plus",
|
||||
"extra_flags": "-D ARDUINO_WIZNET_WIZFI360_EVB_PICO -DARDUINO_ARCH_RP2040 -DUSBD_MAX_POWER_MA=250",
|
||||
"f_cpu": "133000000L",
|
||||
"hwids": [
|
||||
[
|
||||
"0x2E8A",
|
||||
"0x00C0"
|
||||
]
|
||||
],
|
||||
"mcu": "rp2040",
|
||||
"arduino": {
|
||||
"earlephilhower": {
|
||||
"variant": "wiznet_wizfi360_evb_pico",
|
||||
"boot2_source": "boot2_w25q080_2_padded_checksum.S",
|
||||
"usb_vid": "0x2e8a",
|
||||
"usb_pid": "0x1028",
|
||||
"usb_manufacturer": "WIZnet",
|
||||
"usb_product": "WizFi360-EVB-Pico"
|
||||
}
|
||||
}
|
||||
},
|
||||
"debug": {
|
||||
"jlink_device": "RP2040_M0_0",
|
||||
"openocd_target": "rp2040.cfg",
|
||||
"svd_path": "rp2040.svd"
|
||||
},
|
||||
"frameworks": [
|
||||
"arduino"
|
||||
],
|
||||
"name": "WizFi360-EVB-Pico",
|
||||
"upload": {
|
||||
"maximum_ram_size": 270336,
|
||||
"maximum_size": 2097152,
|
||||
"require_upload_port": true,
|
||||
"native_usb": true,
|
||||
"use_1200bps_touch": true,
|
||||
"wait_for_upload_port": false,
|
||||
"protocol": "picotool",
|
||||
"protocols": [
|
||||
"cmsis-dap",
|
||||
"jlink",
|
||||
"raspberrypi-swd",
|
||||
"picotool",
|
||||
"picoprobe"
|
||||
]
|
||||
},
|
||||
"url": "https://www.raspberrypi.org/products/raspberry-pi-pico/",
|
||||
"vendor": "WIZnet"
|
||||
}
|
||||
@@ -21,6 +21,7 @@ target_compile_definitions(pico PUBLIC
|
||||
|
||||
target_compile_options(pico PUBLIC
|
||||
-fno-exceptions
|
||||
-Os
|
||||
$<$<COMPILE_LANGUAGE:CXX>:-fno-rtti>
|
||||
)
|
||||
|
||||
|
||||
@@ -73,7 +73,7 @@
|
||||
#define CFG_TUD_HID (2)
|
||||
#define CFG_TUD_CDC (1)
|
||||
#define CFG_TUD_MSC (0)
|
||||
#define CFG_TUD_MIDI (1)
|
||||
#define CFG_TUD_MIDI (0)
|
||||
#define CFG_TUD_VENDOR (0)
|
||||
|
||||
#define CFG_TUD_CDC_RX_BUFSIZE (256)
|
||||
|
||||
+22
-2
@@ -50,6 +50,20 @@ def BuildRTTI(name):
|
||||
print("%s.menu.rtti.Enabled=Enabled" % (name))
|
||||
print("%s.menu.rtti.Enabled.build.flags.rtti=" % (name))
|
||||
|
||||
def BuildStackProtect(name):
|
||||
print("%s.menu.stackprotect.Disabled=Disabled" % (name))
|
||||
print("%s.menu.stackprotect.Disabled.build.flags.stackprotect=" % (name))
|
||||
print("%s.menu.stackprotect.Enabled=Enabled" % (name))
|
||||
print("%s.menu.stackprotect.Enabled.build.flags.stackprotect=-fstack-protector" % (name))
|
||||
|
||||
def BuildExceptions(name):
|
||||
print("%s.menu.exceptions.Disabled=Disabled" % (name))
|
||||
print("%s.menu.exceptions.Disabled.build.flags.exceptions=-fno-exceptions" % (name))
|
||||
print("%s.menu.exceptions.Disabled.build.flags.libstdcpp=-lstdc++" % (name))
|
||||
print("%s.menu.exceptions.Enabled=Enabled" % (name))
|
||||
print("%s.menu.exceptions.Enabled.build.flags.exceptions=-fexceptions" % (name))
|
||||
print("%s.menu.exceptions.Enabled.build.flags.libstdcpp=-lstdc++-exc" % (name))
|
||||
|
||||
def BuildBoot(name):
|
||||
for l in [ ("Generic SPI /2", "boot2_generic_03h_2_padded_checksum"), ("Generic SPI /4", "boot2_generic_03h_4_padded_checksum"),
|
||||
("IS25LP080 QSPI /2", "boot2_is25lp080_2_padded_checksum"), ("IS25LP080 QSPI /4", "boot2_is25lp080_4_padded_checksum"),
|
||||
@@ -112,6 +126,8 @@ def BuildGlobalMenuList():
|
||||
print("menu.freq=CPU Speed")
|
||||
print("menu.opt=Optimize")
|
||||
print("menu.rtti=RTTI")
|
||||
print("menu.stackprotect=Stack Protector")
|
||||
print("menu.exceptions=C++ Exceptions")
|
||||
print("menu.dbgport=Debug Port")
|
||||
print("menu.dbglvl=Debug Level")
|
||||
print("menu.boot2=Boot Stage 2")
|
||||
@@ -146,6 +162,8 @@ def MakeBoard(name, vendor_name, product_name, vid, pid, pwr, boarddefine, flash
|
||||
BuildFreq(n)
|
||||
BuildOptimize(n)
|
||||
BuildRTTI(n)
|
||||
BuildStackProtect(n)
|
||||
BuildExceptions(n)
|
||||
BuildDebugPort(n)
|
||||
BuildDebugLevel(n)
|
||||
if a == "picodebug":
|
||||
@@ -251,7 +269,7 @@ MakeBoard("dfrobot_beetle_rp2040", "DFRobot", "Beetle RP2040", "0x3343", "0x4253
|
||||
MakeBoard("challenger_2040_lora", "iLabs", "Challenger 2040 LoRa", "0x2e8a", "0x1023", 250, "CHALLENGER_2040_LORA_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("challenger_2040_wifi", "iLabs", "Challenger 2040 WiFi", "0x2e8a", "0x1006", 250, "CHALLENGER_2040_WIFI_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("challenger_2040_lte", "iLabs", "Challenger 2040 LTE", "0x2e8a", "0x100b", 500, "CHALLENGER_2040_LTE_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("challenger_2040_wifi_ble", "iLabs", "Challenger 2040 WiFi/BLE", "0x2e8a", "0x1101", 500, "CHALLENGER_2040_WIFI_BLE_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("challenger_2040_wifi_ble", "iLabs", "Challenger 2040 WiFi/BLE", "0x2e8a", "0x102C", 500, "CHALLENGER_2040_WIFI_BLE_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("challenger_nb_2040_wifi", "iLabs", "Challenger NB 2040 WiFi", "0x2e8a", "0x100b", 500, "CHALLENGER_NB_2040_WIFI_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("ilabs_rpico32", "iLabs", "RPICO32", "0x2e8a", "0x1010", 250, "ILABS_2040_RPICO32_RP2040", 8, "boot2_w25q080_2_padded_checksum")
|
||||
|
||||
@@ -272,7 +290,9 @@ MakeBoard("upesy_rp2040_devkit", "uPesy", "RP2040 DevKit", "0x2e8a", "0x1007", 2
|
||||
MakeBoard("seeed_xiao_rp2040", "Seeed", "XAIO RP2040", "0x2e8a", "0x000a", 250, "SEEED_XAIO_RP2040", 2, "boot2_w25q080_2_padded_checksum")
|
||||
|
||||
# WIZnet
|
||||
MakeBoard("wiznet_5100s_evb_pico", "WIZnet", "W5100S-EVB-Pico", "0x2e8a", "0x1008", 250, "WIZNET_5100S_EVB_PICO", 2, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("wiznet_5100s_evb_pico", "WIZnet", "W5100S-EVB-Pico", "0x2e8a", "0x1027", 250, "WIZNET_5100S_EVB_PICO", 2, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("wiznet_wizfi360_evb_pico", "WIZnet", "WizFi360-EVB-Pico", "0x2e8a", "0x1028", 250, "WIZNET_WIZFI360_EVB_PICO", 2, "boot2_w25q080_2_padded_checksum")
|
||||
MakeBoard("wiznet_5500_evb_pico", "WIZnet", "W5500-EVB-Pico", "0x2e8a", "0x1029", 250, "WIZNET_5500_EVB_PICO", 2, "boot2_w25q080_2_padded_checksum")
|
||||
|
||||
# Generic
|
||||
MakeBoard("generic", "Generic", "RP2040", "0x2e8a", "0xf00a", 250, "GENERIC_RP2040", 16, "boot2_generic_03h_4_padded_checksum")
|
||||
|
||||
@@ -27,6 +27,21 @@ ram_size = 256 * 1024 # not the 264K, which is 256K SRAM + 2*4K SCRATCH(X/Y).
|
||||
FRAMEWORK_DIR = platform.get_package_dir("framework-arduinopico")
|
||||
assert os.path.isdir(FRAMEWORK_DIR)
|
||||
|
||||
# read includes from this file to add them into CPPPATH later
|
||||
includes_file = os.path.join(FRAMEWORK_DIR, "lib", "platform_inc.txt")
|
||||
file_lines = []
|
||||
includes = []
|
||||
with open(includes_file, "r") as fp:
|
||||
file_lines = fp.readlines()
|
||||
for l in file_lines:
|
||||
path = l.strip().replace("-iwithprefixbefore/", "").replace("/", os.sep)
|
||||
# emulate -iprefix <framework path>.
|
||||
path = os.path.join(FRAMEWORK_DIR, path)
|
||||
# prevent non-existent paths from being added
|
||||
# looking at you here, pico-extras/src/common/pico_audio and co.
|
||||
if os.path.isdir(path):
|
||||
includes.append(path)
|
||||
|
||||
# update progsize expression to also check for bootloader.
|
||||
env.Replace(
|
||||
SIZEPROGREGEXP=r"^(?:\.boot2|\.text|\.data|\.rodata|\.text.align|\.ARM.exidx)\s+(\d+).*"
|
||||
@@ -36,14 +51,17 @@ env.Append(
|
||||
ASFLAGS=env.get("CCFLAGS", [])[:],
|
||||
|
||||
CCFLAGS=[
|
||||
"-Os", # Optimize for size by default
|
||||
"-Werror=return-type",
|
||||
"-march=armv6-m",
|
||||
"-mcpu=cortex-m0plus",
|
||||
"-mthumb",
|
||||
"-ffunction-sections",
|
||||
"-fdata-sections",
|
||||
"-iprefix" + os.path.join(FRAMEWORK_DIR),
|
||||
"@%s" % os.path.join(FRAMEWORK_DIR, "lib", "platform_inc.txt")
|
||||
# use explicit include (-I) paths, otherwise it's
|
||||
# not visible in the IDE's intellisense.
|
||||
#"-iprefix" + os.path.join(FRAMEWORK_DIR),
|
||||
#"@%s" % os.path.join(FRAMEWORK_DIR, "lib", "platform_inc.txt")
|
||||
],
|
||||
|
||||
CFLAGS=[
|
||||
@@ -98,7 +116,8 @@ env.Append(
|
||||
File(os.path.join(FRAMEWORK_DIR, "lib", "libpico.a")),
|
||||
"m", "c", "stdc++", "c"]
|
||||
)
|
||||
|
||||
# expand with read includes
|
||||
env.Append(CPPPATH=includes)
|
||||
|
||||
def configure_usb_flags(cpp_defines):
|
||||
global ram_size
|
||||
|
||||
+21
-30
@@ -262,6 +262,21 @@ def get_drives():
|
||||
for d in os.listdir(rootpath):
|
||||
drives.append(os.path.join(rootpath, d))
|
||||
|
||||
if (len(drives) == 0) and (sys.platform == "linux"):
|
||||
globexpr = "/dev/disk/by-id/usb-RPI_RP2*-part1"
|
||||
rpidisk = glob.glob(globexpr)
|
||||
if len(rpidisk) > 0:
|
||||
try:
|
||||
cmd = ["udisksctl", "mount", "--block-device", os.path.realpath(rpidisk[0])]
|
||||
proc_out = subprocess.run(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
if proc_out.returncode == 0:
|
||||
stdoutput = proc_out.stdout.decode("UTF-8")
|
||||
match = re.search(r'Mounted\s+.*\s+at\s+([^\.\r\n]*)', stdoutput)
|
||||
if match:
|
||||
drives = [match.group(1)]
|
||||
except Exception as ex:
|
||||
print("Exception executing udisksctl. Exception: {}".format(ex))
|
||||
# If it fails, no problem since it was a heroic attempt
|
||||
|
||||
def has_info(d):
|
||||
try:
|
||||
@@ -335,9 +350,7 @@ def main():
|
||||
ser = serial.Serial(args.serial, 1200)
|
||||
ser.dtr = False
|
||||
except:
|
||||
print("Caught exception during reset!")
|
||||
# Probably should be smart and check for device appearance or something
|
||||
time.sleep(10)
|
||||
pass # Ignore error in the case it is already in upload mode
|
||||
except:
|
||||
pass
|
||||
if args.list:
|
||||
@@ -368,33 +381,11 @@ def main():
|
||||
if args.output == None:
|
||||
args.output = "flash." + ext
|
||||
else:
|
||||
drives = get_drives()
|
||||
if (len(drives) == 0) and (sys.platform == "linux"):
|
||||
globexpr = "/dev/disk/by-id/usb-RPI_RP2*-part1"
|
||||
rpidisk = glob.glob(globexpr)
|
||||
if len(rpidisk) == 0:
|
||||
print("Unable to find disk by ID using expression: {}".format(globexpr))
|
||||
else:
|
||||
try:
|
||||
cmd = ["udisksctl", "mount", "--block-device", os.path.realpath(rpidisk[0])]
|
||||
proc_out = subprocess.run(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
if proc_out.returncode == 0:
|
||||
stdoutput = proc_out.stdout.decode("UTF-8")
|
||||
match = re.search(r'Mounted\s+.*\s+at\s+([^\.\r\n]*)', stdoutput)
|
||||
if match is None:
|
||||
print("Warn: {} did not print mount point. Attempting to locate mounted drive in file system. StdOut={}".format(cmd[0], stdoutput))
|
||||
drives = get_drives()
|
||||
else:
|
||||
drives = [match.group(1)]
|
||||
else:
|
||||
print("Error executing command {}. Return Code: {} Std Output: {} StdError: {}".format(" ".join(cmd),
|
||||
proc_out.returncode,
|
||||
proc_out.stdout.decode("UTF-8"),
|
||||
proc_out.stderr.decode("UTF-8")))
|
||||
|
||||
except Exception as ex:
|
||||
print("Exception executing udisksctl. Exception: {}".format(ex))
|
||||
# If it fails, no problem since it was a heroic attempt
|
||||
now = time.time()
|
||||
drives = []
|
||||
while (time.time() - now < 10.0) and (len(drives) == 0):
|
||||
time.sleep(0.5) # Avoid 100% CPU use while waiting for drive to appear
|
||||
drives = get_drives()
|
||||
|
||||
if args.output:
|
||||
write_file(args.output, outbuf)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
ESP8285 helper class for the Challenger RP2040 WiFi boards
|
||||
ESP8285/ESP32C3 helper class for the Challenger RP2040 WiFi enabled boards
|
||||
|
||||
Copyright (c) 2021 P. Oldberg <pontus@ilabs.se>
|
||||
Copyright (c) 2021,2022 P. Oldberg <pontus@ilabs.se>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
@@ -21,31 +21,33 @@
|
||||
#include <Arduino.h>
|
||||
#include <ChallengerWiFi.h>
|
||||
|
||||
Challenger2040WiFiClass::Challenger2040WiFiClass() {
|
||||
pinMode(PIN_ESP8285_RST, OUTPUT);
|
||||
digitalWrite(PIN_ESP8285_RST, LOW); // Hold ESP8285 in reset
|
||||
pinMode(PIN_ESP8285_MODE, OUTPUT);
|
||||
digitalWrite(PIN_ESP8285_MODE, HIGH); // Prepare for normal start
|
||||
Challenger2040WiFiClass::Challenger2040WiFiClass(HardwareSerial* serial) {
|
||||
_serial = serial;
|
||||
|
||||
pinMode(PIN_ESP_RST, OUTPUT);
|
||||
digitalWrite(PIN_ESP_RST, LOW); // Hold ESP in reset
|
||||
pinMode(PIN_ESP_MODE, OUTPUT);
|
||||
digitalWrite(PIN_ESP_MODE, HIGH); // Prepare for normal start
|
||||
}
|
||||
|
||||
// Do a HW reset by applying a low pulse to the reset line for 1mSec
|
||||
void Challenger2040WiFiClass::doHWReset() {
|
||||
digitalWrite(PIN_ESP8285_RST, LOW); // Hold ESP8285 in reset
|
||||
digitalWrite(PIN_ESP_RST, LOW); // Hold ESP in reset
|
||||
delay(1);
|
||||
digitalWrite(PIN_ESP8285_RST, HIGH); // Release ESP8285 reset
|
||||
digitalWrite(PIN_ESP_RST, HIGH); // Release ESP reset
|
||||
}
|
||||
|
||||
// Set the mode flag high to indicate normal run operation and do a HW
|
||||
// reset.
|
||||
void Challenger2040WiFiClass::runReset() { // Prepare ESP8285 for normal op
|
||||
digitalWrite(PIN_ESP8285_MODE, HIGH); // Prepare for normal start
|
||||
void Challenger2040WiFiClass::runReset() { // Prepare ESP for normal op
|
||||
digitalWrite(PIN_ESP_MODE, HIGH); // Prepare for normal start
|
||||
doHWReset();
|
||||
}
|
||||
|
||||
// Set the mode flag low to indicate flash operation and do a HW
|
||||
// reset.
|
||||
void Challenger2040WiFiClass::flashReset() { // Prepare ESP8285 for flashing
|
||||
digitalWrite(PIN_ESP8285_MODE, LOW); // Prepare for normal start
|
||||
void Challenger2040WiFiClass::flashReset() { // Prepare ESP for flashing
|
||||
digitalWrite(PIN_ESP_MODE, LOW); // Prepare for normal start
|
||||
doHWReset();
|
||||
}
|
||||
|
||||
@@ -55,53 +57,82 @@ void Challenger2040WiFiClass::flashReset() { // Prepare ESP8285 for flashing
|
||||
bool Challenger2040WiFiClass::waitForReady() {
|
||||
int timeout = 20; // Aprox max 2 sec
|
||||
|
||||
Serial2.begin(DEFAULT_ESP8285_BAUDRATE);
|
||||
Serial2.setTimeout(100);
|
||||
String rdy = Serial2.readStringUntil('\n');
|
||||
_serial->setTimeout(100);
|
||||
String rdy = _serial->readStringUntil('\n');
|
||||
while(!rdy.startsWith("ready") && timeout--) {
|
||||
rdy = Serial2.readStringUntil('\n');
|
||||
rdy = _serial->readStringUntil('\n');
|
||||
}
|
||||
Serial2.setTimeout(1000); // Reset default timeout to 1000
|
||||
_serial->setTimeout(1000); // Reset default timeout to 1000
|
||||
if (timeout)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
// Reset the ESP8285 and wait for the "ready" prompt to be returned.
|
||||
// Reset the ESP and wait for the "ready" prompt to be returned.
|
||||
bool Challenger2040WiFiClass::reset() {
|
||||
runReset();
|
||||
_serial->begin(DEFAULT_ESP_BAUDRATE);
|
||||
return waitForReady();
|
||||
}
|
||||
|
||||
// Checks to see if the modem responds to the "AT" poll command.
|
||||
bool Challenger2040WiFiClass::isAlive() {
|
||||
int timeout = 5;
|
||||
int timeout = 100;
|
||||
|
||||
Serial2.setTimeout(250);
|
||||
Serial2.println(F("AT"));
|
||||
String rdy = Serial2.readStringUntil('\n');
|
||||
_serial->setTimeout(250);
|
||||
_serial->println(F("AT"));
|
||||
String rdy = _serial->readStringUntil('\n');
|
||||
while(!rdy.startsWith(F("OK")) && timeout--) {
|
||||
rdy = Serial2.readStringUntil('\n');
|
||||
_serial->println(F("AT"));
|
||||
rdy = _serial->readStringUntil('\n');
|
||||
}
|
||||
Serial2.setTimeout(1000);
|
||||
_serial->setTimeout(1000);
|
||||
|
||||
if (timeout)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
// Change the baud rate of the ESP8285 as well as the local UART.
|
||||
// Change the baud rate of the ESP device as well as the local UART.
|
||||
// No checking is done on the input baud rate so the user must know what
|
||||
// baud rates are valid. The function ends by checking if the ESP8285 is
|
||||
// baud rates are valid. The function ends by checking if the ESP is
|
||||
// reachable by doing an "AT" poll.
|
||||
bool Challenger2040WiFiClass::changeBaudRate(int baud) {
|
||||
Serial2.print(F("AT+UART_CUR="));
|
||||
Serial2.print(baud);
|
||||
Serial2.println(F(",8,1,0,0"));
|
||||
_serial->print(F("AT+UART_CUR="));
|
||||
_serial->print(baud);
|
||||
_serial->println(F(",8,1,0,0"));
|
||||
delay(100);
|
||||
Serial2.end();
|
||||
Serial2.begin(baud);
|
||||
_serial->end();
|
||||
_serial->begin(baud);
|
||||
return isAlive();
|
||||
}
|
||||
|
||||
// This method should be called id the builtin object isn't needed any more
|
||||
// It basically just releases the UART pins for other use.
|
||||
void Challenger2040WiFiClass::release() {
|
||||
_serial->end();
|
||||
}
|
||||
|
||||
// We can assign a new hardware serial port to accommodate the ESP device here.
|
||||
// The function will release the previously used serial port and assign the
|
||||
// new port. The ESP will be left in a reset state ready to start normal
|
||||
// operation when exiting the function.
|
||||
// This function is useful for when using the PIO serial ports to communicate
|
||||
// with the ESP instead of the built in hardware serial port.
|
||||
void Challenger2040WiFiClass::setSerial(HardwareSerial* serial) {
|
||||
|
||||
release();
|
||||
_serial = serial;
|
||||
|
||||
pinMode(PIN_ESP_RST, OUTPUT);
|
||||
digitalWrite(PIN_ESP_RST, LOW); // Hold ESP in reset
|
||||
pinMode(PIN_ESP_MODE, OUTPUT);
|
||||
digitalWrite(PIN_ESP_MODE, HIGH); // Prepare for normal start
|
||||
}
|
||||
|
||||
// Return the current serial object
|
||||
HardwareSerial* Challenger2040WiFiClass::getSerial() {
|
||||
return _serial;
|
||||
}
|
||||
|
||||
Challenger2040WiFiClass Challenger2040WiFi;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
ESP8285 helper class for the Challenger RP2040 WiFi boards
|
||||
ESP8285/ESP32C3 helper class for the Challenger RP2040 WiFi enabled boards
|
||||
|
||||
Copyright (c) 2021 P. Oldberg <pontus@ilabs.se>
|
||||
Copyright (c) 2021,2022 P. Oldberg <pontus@ilabs.se>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
@@ -17,20 +17,27 @@
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#define DEFAULT_ESP8285_BAUDRATE 115200
|
||||
#define DEFAULT_ESP32_BAUDRATE 115200
|
||||
#define DEFAULT_ESP_BAUDRATE DEFAULT_ESP32_BAUDRATE
|
||||
|
||||
class Challenger2040WiFiClass {
|
||||
public:
|
||||
Challenger2040WiFiClass();
|
||||
Challenger2040WiFiClass(HardwareSerial* = &ESP_SERIAL_PORT);
|
||||
void doHWReset();
|
||||
void runReset();
|
||||
void flashReset();
|
||||
bool waitForReady();
|
||||
bool reset();
|
||||
bool isAlive();
|
||||
bool changeBaudRate(int baud);
|
||||
bool changeBaudRate(int);
|
||||
void release();
|
||||
void setSerial(HardwareSerial*);
|
||||
HardwareSerial* getSerial();
|
||||
private:
|
||||
HardwareSerial* _serial;
|
||||
};
|
||||
|
||||
extern Challenger2040WiFiClass Challenger2040WiFi;
|
||||
|
||||
@@ -18,6 +18,13 @@
|
||||
#define PIN_SERIAL2_RX (5u)
|
||||
#define PIN_ESP8285_RST (19u)
|
||||
#define PIN_ESP8285_MODE (13u)
|
||||
#define ESP8285_SERIAL Serial2
|
||||
// Uart define esp serial abstraction pins
|
||||
#define PIN_ESP_TX PIN_SERIAL2_TX
|
||||
#define PIN_ESP_RX PIN_SERIAL2_RX
|
||||
#define PIN_ESP_RST PIN_ESP8285_RST
|
||||
#define PIN_ESP_MODE PIN_ESP8285_MODE
|
||||
#define ESP_SERIAL_PORT ESP8285_SERIAL
|
||||
|
||||
// SPI
|
||||
#define PIN_SPI0_MISO (24u)
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
ESP32 helper class for the Challenger RP2040 WiFi boards
|
||||
ESP8285/ESP32C3 helper class for the Challenger RP2040 WiFi enabled boards
|
||||
|
||||
Copyright (c) 2021 P. Oldberg <pontus@ilabs.se>
|
||||
Copyright (c) 2021,2022 P. Oldberg <pontus@ilabs.se>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
@@ -21,31 +21,33 @@
|
||||
#include <Arduino.h>
|
||||
#include <ChallengerWiFi.h>
|
||||
|
||||
Challenger2040WiFiClass::Challenger2040WiFiClass() {
|
||||
pinMode(PIN_ESP32_RST, OUTPUT);
|
||||
digitalWrite(PIN_ESP32_RST, LOW); // Hold ESP32 in reset
|
||||
pinMode(PIN_ESP32_MODE, OUTPUT);
|
||||
digitalWrite(PIN_ESP32_MODE, HIGH); // Prepare for normal start
|
||||
Challenger2040WiFiClass::Challenger2040WiFiClass(HardwareSerial* serial) {
|
||||
_serial = serial;
|
||||
|
||||
pinMode(PIN_ESP_RST, OUTPUT);
|
||||
digitalWrite(PIN_ESP_RST, LOW); // Hold ESP in reset
|
||||
pinMode(PIN_ESP_MODE, OUTPUT);
|
||||
digitalWrite(PIN_ESP_MODE, HIGH); // Prepare for normal start
|
||||
}
|
||||
|
||||
// Do a HW reset by applying a low pulse to the reset line for 1mSec
|
||||
void Challenger2040WiFiClass::doHWReset() {
|
||||
digitalWrite(PIN_ESP32_RST, LOW); // Hold ESP32 in reset
|
||||
digitalWrite(PIN_ESP_RST, LOW); // Hold ESP in reset
|
||||
delay(1);
|
||||
digitalWrite(PIN_ESP32_RST, HIGH); // Release ESP32 reset
|
||||
digitalWrite(PIN_ESP_RST, HIGH); // Release ESP reset
|
||||
}
|
||||
|
||||
// Set the mode flag high to indicate normal run operation and do a HW
|
||||
// reset.
|
||||
void Challenger2040WiFiClass::runReset() { // Prepare ESP32 for normal op
|
||||
digitalWrite(PIN_ESP32_MODE, HIGH); // Prepare for normal start
|
||||
void Challenger2040WiFiClass::runReset() { // Prepare ESP for normal op
|
||||
digitalWrite(PIN_ESP_MODE, HIGH); // Prepare for normal start
|
||||
doHWReset();
|
||||
}
|
||||
|
||||
// Set the mode flag low to indicate flash operation and do a HW
|
||||
// reset.
|
||||
void Challenger2040WiFiClass::flashReset() { // Prepare ESP32 for flashing
|
||||
digitalWrite(PIN_ESP32_MODE, LOW); // Prepare for normal start
|
||||
void Challenger2040WiFiClass::flashReset() { // Prepare ESP for flashing
|
||||
digitalWrite(PIN_ESP_MODE, LOW); // Prepare for normal start
|
||||
doHWReset();
|
||||
}
|
||||
|
||||
@@ -55,53 +57,82 @@ void Challenger2040WiFiClass::flashReset() { // Prepare ESP32 for flashing
|
||||
bool Challenger2040WiFiClass::waitForReady() {
|
||||
int timeout = 20; // Aprox max 2 sec
|
||||
|
||||
Serial2.begin(DEFAULT_ESP32_BAUDRATE);
|
||||
Serial2.setTimeout(100);
|
||||
String rdy = Serial2.readStringUntil('\n');
|
||||
_serial->setTimeout(100);
|
||||
String rdy = _serial->readStringUntil('\n');
|
||||
while(!rdy.startsWith("ready") && timeout--) {
|
||||
rdy = Serial2.readStringUntil('\n');
|
||||
rdy = _serial->readStringUntil('\n');
|
||||
}
|
||||
Serial2.setTimeout(1000); // Reset default timeout to 1000
|
||||
_serial->setTimeout(1000); // Reset default timeout to 1000
|
||||
if (timeout)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
// Reset the ESP32 and wait for the "ready" prompt to be returned.
|
||||
// Reset the ESP and wait for the "ready" prompt to be returned.
|
||||
bool Challenger2040WiFiClass::reset() {
|
||||
runReset();
|
||||
_serial->begin(DEFAULT_ESP_BAUDRATE);
|
||||
return waitForReady();
|
||||
}
|
||||
|
||||
// Checks to see if the modem responds to the "AT" poll command.
|
||||
bool Challenger2040WiFiClass::isAlive() {
|
||||
int timeout = 5;
|
||||
int timeout = 100;
|
||||
|
||||
Serial2.setTimeout(250);
|
||||
Serial2.println(F("AT"));
|
||||
String rdy = Serial2.readStringUntil('\n');
|
||||
_serial->setTimeout(250);
|
||||
_serial->println(F("AT"));
|
||||
String rdy = _serial->readStringUntil('\n');
|
||||
while(!rdy.startsWith(F("OK")) && timeout--) {
|
||||
rdy = Serial2.readStringUntil('\n');
|
||||
_serial->println(F("AT"));
|
||||
rdy = _serial->readStringUntil('\n');
|
||||
}
|
||||
Serial2.setTimeout(1000);
|
||||
_serial->setTimeout(1000);
|
||||
|
||||
if (timeout)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
// Change the baud rate of the ESP32 as well as the local UART.
|
||||
// Change the baud rate of the ESP device as well as the local UART.
|
||||
// No checking is done on the input baud rate so the user must know what
|
||||
// baud rates are valid. The function ends by checking if the ESP32 is
|
||||
// baud rates are valid. The function ends by checking if the ESP is
|
||||
// reachable by doing an "AT" poll.
|
||||
bool Challenger2040WiFiClass::changeBaudRate(int baud) {
|
||||
Serial2.print(F("AT+UART_CUR="));
|
||||
Serial2.print(baud);
|
||||
Serial2.println(F(",8,1,0,0"));
|
||||
_serial->print(F("AT+UART_CUR="));
|
||||
_serial->print(baud);
|
||||
_serial->println(F(",8,1,0,0"));
|
||||
delay(100);
|
||||
Serial2.end();
|
||||
Serial2.begin(baud);
|
||||
_serial->end();
|
||||
_serial->begin(baud);
|
||||
return isAlive();
|
||||
}
|
||||
|
||||
// This method should be called id the builtin object isn't needed any more
|
||||
// It basically just releases the UART pins for other use.
|
||||
void Challenger2040WiFiClass::release() {
|
||||
_serial->end();
|
||||
}
|
||||
|
||||
// We can assign a new hardware serial port to accommodate the ESP device here.
|
||||
// The function will release the previously used serial port and assign the
|
||||
// new port. The ESP will be left in a reset state ready to start normal
|
||||
// operation when exiting the function.
|
||||
// This function is useful for when using the PIO serial ports to communicate
|
||||
// with the ESP instead of the built in hardware serial port.
|
||||
void Challenger2040WiFiClass::setSerial(HardwareSerial* serial) {
|
||||
|
||||
release();
|
||||
_serial = serial;
|
||||
|
||||
pinMode(PIN_ESP_RST, OUTPUT);
|
||||
digitalWrite(PIN_ESP_RST, LOW); // Hold ESP in reset
|
||||
pinMode(PIN_ESP_MODE, OUTPUT);
|
||||
digitalWrite(PIN_ESP_MODE, HIGH); // Prepare for normal start
|
||||
}
|
||||
|
||||
// Return the current serial object
|
||||
HardwareSerial* Challenger2040WiFiClass::getSerial() {
|
||||
return _serial;
|
||||
}
|
||||
|
||||
Challenger2040WiFiClass Challenger2040WiFi;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
ESP8285 helper class for the Challenger RP2040 WiFi boards
|
||||
ESP8285/ESP32C3 helper class for the Challenger RP2040 WiFi enabled boards
|
||||
|
||||
Copyright (c) 2021 P. Oldberg <pontus@ilabs.se>
|
||||
Copyright (c) 2021,2022 P. Oldberg <pontus@ilabs.se>
|
||||
|
||||
This library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
@@ -17,20 +17,27 @@
|
||||
License along with this library; if not, write to the Free Software
|
||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#define DEFAULT_ESP32_BAUDRATE 115200
|
||||
#define DEFAULT_ESP_BAUDRATE DEFAULT_ESP32_BAUDRATE
|
||||
|
||||
class Challenger2040WiFiClass {
|
||||
public:
|
||||
Challenger2040WiFiClass();
|
||||
Challenger2040WiFiClass(HardwareSerial* = &ESP_SERIAL_PORT);
|
||||
void doHWReset();
|
||||
void runReset();
|
||||
void flashReset();
|
||||
bool waitForReady();
|
||||
bool reset();
|
||||
bool isAlive();
|
||||
bool changeBaudRate(int baud);
|
||||
bool changeBaudRate(int);
|
||||
void release();
|
||||
void setSerial(HardwareSerial*);
|
||||
HardwareSerial* getSerial();
|
||||
private:
|
||||
HardwareSerial* _serial;
|
||||
};
|
||||
|
||||
extern Challenger2040WiFiClass Challenger2040WiFi;
|
||||
|
||||
@@ -18,7 +18,13 @@
|
||||
#define PIN_SERIAL2_RX (5u)
|
||||
#define PIN_ESP32_RST (19u)
|
||||
#define PIN_ESP32_MODE (24u)
|
||||
#define ESP32_SERIAL 1
|
||||
#define ESP32_SERIAL Serial2
|
||||
// Uart define esp serial abstraction pins
|
||||
#define PIN_ESP_TX PIN_SERIAL2_TX
|
||||
#define PIN_ESP_RX PIN_SERIAL2_RX
|
||||
#define PIN_ESP_RST PIN_ESP32_RST
|
||||
#define PIN_ESP_MODE PIN_ESP32_MODE
|
||||
#define ESP_SERIAL_PORT ESP32_SERIAL
|
||||
|
||||
// SPI
|
||||
#define PIN_SPI0_MISO (24u)
|
||||
@@ -33,7 +39,7 @@
|
||||
#define PIN_SPI1_SS (13u)
|
||||
// Handshake signal from ESP32C3
|
||||
#define ESP32_HS (18u)
|
||||
#define ESP32_SPI 1
|
||||
#define ESP32_SPI SPI1
|
||||
|
||||
// Wire
|
||||
#define PIN_WIRE0_SDA (0u)
|
||||
|
||||
@@ -37,7 +37,4 @@
|
||||
#define SPI_HOWMANY (1u)
|
||||
#define WIRE_HOWMANY (2u)
|
||||
|
||||
#define __PIN_A0 (31u)
|
||||
#define __PIN_A1 (31u)
|
||||
|
||||
#include "../generic/common.h"
|
||||
|
||||
@@ -8,6 +8,27 @@
|
||||
#define PIN_LED_R (17u)
|
||||
#define PIN_LED_G (16u)
|
||||
#define PIN_LED_B (25u)
|
||||
#define LED_BUILTIN PIN_LED
|
||||
|
||||
// Digital pins
|
||||
static const uint8_t D0 = (26u);
|
||||
static const uint8_t D1 = (27u);
|
||||
static const uint8_t D2 = (28u);
|
||||
static const uint8_t D3 = (29u);
|
||||
static const uint8_t D4 = (6u);
|
||||
static const uint8_t D5 = (7u);
|
||||
static const uint8_t D6 = (0u);
|
||||
static const uint8_t D7 = (1u);
|
||||
static const uint8_t D8 = (2u);
|
||||
static const uint8_t D9 = (4u);
|
||||
static const uint8_t D10 = (3u);
|
||||
|
||||
// Analog pins
|
||||
static const uint8_t A0 = (26u);
|
||||
static const uint8_t A1 = (27u);
|
||||
static const uint8_t A2 = (28u);
|
||||
static const uint8_t A3 = (29u);
|
||||
#define ADC_RESOLUTION 12
|
||||
|
||||
// NeoPixel
|
||||
#define PIN_NEOPIXEL (12u)
|
||||
@@ -26,23 +47,34 @@
|
||||
#define PIN_SPI0_MOSI (3u)
|
||||
#define PIN_SPI0_SCK (2u)
|
||||
#define PIN_SPI0_SS (31u) // not pinned out
|
||||
static const uint8_t SS = PIN_SPI0_SS; // SPI Slave SS not used. Set here only for reference.
|
||||
static const uint8_t MOSI = PIN_SPI0_MOSI;
|
||||
static const uint8_t MISO = PIN_SPI0_MISO;
|
||||
static const uint8_t SCK = PIN_SPI0_SCK;
|
||||
|
||||
// Not pinned out
|
||||
#define PIN_SPI1_MISO (31u)
|
||||
#define PIN_SPI1_MOSI (31u)
|
||||
#define PIN_SPI1_SCK (31u)
|
||||
#define PIN_SPI1_SS (31u)
|
||||
#define SPI_MISO (PIN_SPI1_MISO)
|
||||
#define SPI_MOSI (PIN_SPI1_MOSI)
|
||||
#define SPI_SCK (PIN_SPI1_SCK)
|
||||
|
||||
// Wire
|
||||
#define __WIRE0_DEVICE (i2c1)
|
||||
#define PIN_WIRE0_SDA (6u)
|
||||
#define PIN_WIRE0_SCL (7u)
|
||||
#define SDA PIN_WIRE0_SDA
|
||||
#define SCL PIN_WIRE0_SCL
|
||||
#define I2C_SDA (SDA)
|
||||
#define I2C_SCL (SCL)
|
||||
|
||||
// Wire1 not pinned out
|
||||
#define __WIRE1_DEVICE (i2c0)
|
||||
#define PIN_WIRE1_SDA (31u)
|
||||
#define PIN_WIRE1_SCL (31u)
|
||||
|
||||
#define SERIAL_HOWMANY (2u)
|
||||
#define SERIAL_HOWMANY (1u)
|
||||
#define SPI_HOWMANY (1u)
|
||||
#define WIRE_HOWMANY (1u)
|
||||
|
||||
#include "../generic/common.h"
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
#include "../generic/pins_arduino.h"
|
||||
@@ -0,0 +1,41 @@
|
||||
#pragma once
|
||||
|
||||
// LEDs
|
||||
#define PIN_LED (25u)
|
||||
|
||||
// Serial
|
||||
#define PIN_SERIAL1_TX (0u)
|
||||
#define PIN_SERIAL1_RX (1u)
|
||||
|
||||
// Slight difference to generic RP2040
|
||||
// PIN_SERIAL2_TX + PIN_SERIAL2_RX are
|
||||
// switched with PIN_WIRE0_SDA + PIN_WIRE0_SCL
|
||||
#define PIN_SERIAL2_TX (4u)
|
||||
#define PIN_SERIAL2_RX (5u)
|
||||
|
||||
// SPI
|
||||
#define PIN_SPI0_MISO (16u)
|
||||
#define PIN_SPI0_MOSI (19u)
|
||||
#define PIN_SPI0_SCK (18u)
|
||||
#define PIN_SPI0_SS (17u)
|
||||
|
||||
#define PIN_SPI1_MISO (12u)
|
||||
#define PIN_SPI1_MOSI (15u)
|
||||
#define PIN_SPI1_SCK (14u)
|
||||
#define PIN_SPI1_SS (13u)
|
||||
|
||||
// Wire
|
||||
// Slight difference to generic RP2040
|
||||
// PIN_SERIAL2_TX + PIN_SERIAL2_RX are
|
||||
// switched with PIN_WIRE0_SDA + PIN_WIRE0_SCL
|
||||
#define PIN_WIRE0_SDA (8u)
|
||||
#define PIN_WIRE0_SCL (9u)
|
||||
|
||||
#define PIN_WIRE1_SDA (26u)
|
||||
#define PIN_WIRE1_SCL (27u)
|
||||
|
||||
#define SERIAL_HOWMANY (3u)
|
||||
#define SPI_HOWMANY (2u)
|
||||
#define WIRE_HOWMANY (2u)
|
||||
|
||||
#include "../generic/common.h"
|
||||
Reference in New Issue
Block a user