From e821e51bce69bfab4c939e2379cd4480d727e754 Mon Sep 17 00:00:00 2001 From: Matthias Prinke Date: Wed, 14 Feb 2024 21:27:01 +0100 Subject: [PATCH 1/6] feat: Rename Firebeetle ESP32 board definition --- boards.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/boards.txt b/boards.txt index a07902bf749..2da4dcd6515 100644 --- a/boards.txt +++ b/boards.txt @@ -9996,7 +9996,7 @@ firebeetle32.build.target=esp32 firebeetle32.build.mcu=esp32 firebeetle32.build.core=esp32 firebeetle32.build.variant=firebeetle32 -firebeetle32.build.board=ESP32_DEV +firebeetle32.build.board=DFROBOT_FIREBEETLE_ESP32 firebeetle32.build.f_cpu=240000000L firebeetle32.build.flash_mode=dio From 1c0dcd421c2d0eed61fe73b2f86e74a1af0c2152 Mon Sep 17 00:00:00 2001 From: Matthias Prinke Date: Fri, 16 Feb 2024 08:04:45 +0100 Subject: [PATCH 2/6] feat: Add board support for ThingPulse ePulse Feather --- boards.txt | 127 ++++++++++++++++++ .../thingpulse_epulse_feather/pins_arduino.h | 48 +++++++ 2 files changed, 175 insertions(+) create mode 100644 variants/thingpulse_epulse_feather/pins_arduino.h diff --git a/boards.txt b/boards.txt index 2da4dcd6515..68940e2b39e 100644 --- a/boards.txt +++ b/boards.txt @@ -33620,3 +33620,130 @@ makergo_c3_supermini.menu.EraseFlash.all=Enabled makergo_c3_supermini.menu.EraseFlash.all.upload.erase_cmd=-e ############################################################## +# ThingPulse ePulse Feather + +epulse_feather.name=ThingPulse ePulse Feather + +epulse_feather.bootloader.tool=esptool_py +epulse_feather.bootloader.tool.default=esptool_py + +epulse_feather.upload.tool=esptool_py +epulse_feather.upload.tool.default=esptool_py +epulse_feather.upload.tool.network=esp_ota + +epulse_feather.upload.maximum_size=1310720 +epulse_feather.upload.maximum_data_size=327680 +epulse_feather.upload.flags= +epulse_feather.upload.extra_flags= + +epulse_feather.serial.disableDTR=true +epulse_feather.serial.disableRTS=true + +epulse_feather.build.tarch=xtensa +epulse_feather.build.bootloader_addr=0x1000 +epulse_feather.build.target=esp32 +epulse_feather.build.mcu=esp32 +epulse_feather.build.core=esp32 +epulse_feather.build.variant=thingpulse_epulse_feather +epulse_feather.build.board=THINGPULSE_EPULSE_FEATHER + +epulse_feather.build.f_cpu=240000000L +epulse_feather.build.flash_size=8MB +epulse_feather.build.flash_freq=80m +epulse_feather.build.flash_mode=dio +epulse_feather.build.boot=dio +epulse_feather.build.partitions=default_8MB +epulse_feather.build.defines= +epulse_feather.build.loop_core= +epulse_feather.build.event_core= +epulse_feather.build.psram_type=qspi +epulse_feather.build.memory_type={build.flash_type}_{build.psram_type} + +epulse_feather.menu.PSRAM.disabled=Disabled +epulse_feather.menu.PSRAM.disabled.build.defines= +epulse_feather.menu.PSRAM.disabled.build.psram_type=qspi +epulse_feather.menu.PSRAM.enabled=QSPI PSRAM +epulse_feather.menu.PSRAM.enabled.build.defines=-DBOARD_HAS_PSRAM +epulse_feather.menu.PSRAM.enabled.build.psram_type=qspi + +epulse_feather.menu.LoopCore.1=Core 1 +epulse_feather.menu.LoopCore.1.build.loop_core=-DARDUINO_RUNNING_CORE=1 +epulse_feather.menu.LoopCore.0=Core 0 +epulse_feather.menu.LoopCore.0.build.loop_core=-DARDUINO_RUNNING_CORE=0 + +epulse_feather.menu.EventsCore.1=Core 1 +epulse_feather.menu.EventsCore.1.build.event_core=-DARDUINO_EVENT_RUNNING_CORE=1 +epulse_feather.menu.EventsCore.0=Core 0 +epulse_feather.menu.EventsCore.0.build.event_core=-DARDUINO_EVENT_RUNNING_CORE=0 + +epulse_feather.menu.PartitionScheme.default_8MB=8M with spiffs (3MB APP/1.5MB SPIFFS) +epulse_feather.menu.PartitionScheme.default_8MB.build.partitions=default_8MB +epulse_feather.menu.PartitionScheme.default_8MB.upload.maximum_size=3342336 +epulse_feather.menu.PartitionScheme.default_ffat_8MB=8M with ffat (3MB APP/1.5MB FATFS) +epulse_feather.menu.PartitionScheme.default_ffat_8MB.build.partitions=default_ffat_8MB +epulse_feather.menu.PartitionScheme.default_ffat_8MB.upload.maximum_size=3342336 +epulse_feather.menu.PartitionScheme.large_spiffs_8MB=Large SPIFFS (1.2MB APP/5.3MB SPIFFS) +epulse_feather.menu.PartitionScheme.large_spiffs_8MB.build.partitions=large_spiffs_8MB +epulse_feather.menu.PartitionScheme.large_spiffs_8MB.upload.maximum_size=1310720 +epulse_feather.menu.PartitionScheme.large_ffat_8MB=Large FFAT (1.2MB APP/5.3MB FATFS) +epulse_feather.menu.PartitionScheme.large_ffat_8MB.build.partitions=large_ffat_8MB +epulse_feather.menu.PartitionScheme.large_ffat_8MB.upload.maximum_size=1310720 +epulse_feather.menu.PartitionScheme.max_app_8MB=Maximum APP (7.9MB APP No OTA/No FS) +epulse_feather.menu.PartitionScheme.max_app_8MB.build.partitions=max_app_8MB +epulse_feather.menu.PartitionScheme.max_app_8MB.upload.maximum_size=8257536 + +epulse_feather.menu.CPUFreq.240=240MHz (WiFi/BT) +epulse_feather.menu.CPUFreq.240.build.f_cpu=240000000L +epulse_feather.menu.CPUFreq.160=160MHz (WiFi/BT) +epulse_feather.menu.CPUFreq.160.build.f_cpu=160000000L +epulse_feather.menu.CPUFreq.80=80MHz (WiFi/BT) +epulse_feather.menu.CPUFreq.80.build.f_cpu=80000000L +epulse_feather.menu.CPUFreq.40=40MHz +epulse_feather.menu.CPUFreq.40.build.f_cpu=40000000L +epulse_feather.menu.CPUFreq.20=20MHz +epulse_feather.menu.CPUFreq.20.build.f_cpu=20000000L +epulse_feather.menu.CPUFreq.10=10MHz +epulse_feather.menu.CPUFreq.10.build.f_cpu=10000000L + +epulse_feather.menu.FlashFreq.80=80MHz +epulse_feather.menu.FlashFreq.80.build.flash_freq=80m +epulse_feather.menu.FlashFreq.40=40MHz +epulse_feather.menu.FlashFreq.40.build.flash_freq=40m + +epulse_feather.menu.FlashSize.8M=8MB (64Mb) +epulse_feather.menu.FlashSize.8M.build.flash_size=8MB + +epulse_feather.menu.UploadSpeed.921600=921600 +epulse_feather.menu.UploadSpeed.921600.upload.speed=921600 +epulse_feather.menu.UploadSpeed.115200=115200 +epulse_feather.menu.UploadSpeed.115200.upload.speed=115200 +epulse_feather.menu.UploadSpeed.256000.windows=256000 +epulse_feather.menu.UploadSpeed.256000.upload.speed=256000 +epulse_feather.menu.UploadSpeed.230400.windows.upload.speed=256000 +epulse_feather.menu.UploadSpeed.230400=230400 +epulse_feather.menu.UploadSpeed.230400.upload.speed=230400 +epulse_feather.menu.UploadSpeed.460800.linux=460800 +epulse_feather.menu.UploadSpeed.460800.macosx=460800 +epulse_feather.menu.UploadSpeed.460800.upload.speed=460800 +epulse_feather.menu.UploadSpeed.512000.windows=512000 +epulse_feather.menu.UploadSpeed.512000.upload.speed=512000 + +epulse_feather.menu.DebugLevel.none=None +epulse_feather.menu.DebugLevel.none.build.code_debug=0 +epulse_feather.menu.DebugLevel.error=Error +epulse_feather.menu.DebugLevel.error.build.code_debug=1 +epulse_feather.menu.DebugLevel.warn=Warn +epulse_feather.menu.DebugLevel.warn.build.code_debug=2 +epulse_feather.menu.DebugLevel.info=Info +epulse_feather.menu.DebugLevel.info.build.code_debug=3 +epulse_feather.menu.DebugLevel.debug=Debug +epulse_feather.menu.DebugLevel.debug.build.code_debug=4 +epulse_feather.menu.DebugLevel.verbose=Verbose +epulse_feather.menu.DebugLevel.verbose.build.code_debug=5 + +epulse_feather.menu.EraseFlash.none=Disabled +epulse_feather.menu.EraseFlash.none.upload.erase_cmd= +epulse_feather.menu.EraseFlash.all=Enabled +epulse_feather.menu.EraseFlash.all.upload.erase_cmd=-e + +############################################################## diff --git a/variants/thingpulse_epulse_feather/pins_arduino.h b/variants/thingpulse_epulse_feather/pins_arduino.h new file mode 100644 index 00000000000..181354dc365 --- /dev/null +++ b/variants/thingpulse_epulse_feather/pins_arduino.h @@ -0,0 +1,48 @@ +#ifndef Pins_Arduino_h +#define Pins_Arduino_h + +#include + +static const uint8_t SDA = 23; +static const uint8_t SCL = 22; + +static const uint8_t MOSI = 18; +static const uint8_t MISO = 19; +static const uint8_t SCK = 5; + +// mapping to match other feathers and also in order +static const uint8_t A0 = 26; +static const uint8_t A1 = 25; +static const uint8_t A2 = 34; +static const uint8_t A3 = 39; +static const uint8_t A4 = 36; +static const uint8_t A5 = 4; +static const uint8_t A6 = 14; +static const uint8_t A7 = 32; +static const uint8_t A8 = 15; +static const uint8_t A9 = 33; +static const uint8_t A10 = 27; +static const uint8_t A11 = 12; +static const uint8_t A12 = 13; + +// vbat measure +static const uint8_t BATT_MONITOR = 35; // Note: voltage divider 2.2M/4.7M +static const uint8_t A13 = 35; +//static const uint8_t Ax = 0; // not used/available +//static const uint8_t Ax = 2; // not used/available? GPIO02 is available! + +// touch inputs +static const uint8_t T0 = 4; +static const uint8_t T2 = 2; +static const uint8_t T3 = 15; +static const uint8_t T4 = 13; +static const uint8_t T5 = 12; +static const uint8_t T6 = 14; +static const uint8_t T7 = 27; +static const uint8_t T8 = 33; +static const uint8_t T9 = 32; + +static const uint8_t DAC1 = 25; +static const uint8_t DAC2 = 26; + +#endif /* Pins_Arduino_h */ \ No newline at end of file From c070961a16a427100427916d8e77d872c1a675ed Mon Sep 17 00:00:00 2001 From: Matthias Prinke Date: Fri, 16 Feb 2024 17:21:42 +0100 Subject: [PATCH 3/6] Added missing flash_type, removed unavailable partition schemes --- boards.txt | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/boards.txt b/boards.txt index 68940e2b39e..837542676f4 100644 --- a/boards.txt +++ b/boards.txt @@ -33651,6 +33651,7 @@ epulse_feather.build.f_cpu=240000000L epulse_feather.build.flash_size=8MB epulse_feather.build.flash_freq=80m epulse_feather.build.flash_mode=dio +epulse_feather.build.flash_type=qio epulse_feather.build.boot=dio epulse_feather.build.partitions=default_8MB epulse_feather.build.defines= @@ -33679,15 +33680,6 @@ epulse_feather.menu.EventsCore.0.build.event_core=-DARDUINO_EVENT_RUNNING_CORE=0 epulse_feather.menu.PartitionScheme.default_8MB=8M with spiffs (3MB APP/1.5MB SPIFFS) epulse_feather.menu.PartitionScheme.default_8MB.build.partitions=default_8MB epulse_feather.menu.PartitionScheme.default_8MB.upload.maximum_size=3342336 -epulse_feather.menu.PartitionScheme.default_ffat_8MB=8M with ffat (3MB APP/1.5MB FATFS) -epulse_feather.menu.PartitionScheme.default_ffat_8MB.build.partitions=default_ffat_8MB -epulse_feather.menu.PartitionScheme.default_ffat_8MB.upload.maximum_size=3342336 -epulse_feather.menu.PartitionScheme.large_spiffs_8MB=Large SPIFFS (1.2MB APP/5.3MB SPIFFS) -epulse_feather.menu.PartitionScheme.large_spiffs_8MB.build.partitions=large_spiffs_8MB -epulse_feather.menu.PartitionScheme.large_spiffs_8MB.upload.maximum_size=1310720 -epulse_feather.menu.PartitionScheme.large_ffat_8MB=Large FFAT (1.2MB APP/5.3MB FATFS) -epulse_feather.menu.PartitionScheme.large_ffat_8MB.build.partitions=large_ffat_8MB -epulse_feather.menu.PartitionScheme.large_ffat_8MB.upload.maximum_size=1310720 epulse_feather.menu.PartitionScheme.max_app_8MB=Maximum APP (7.9MB APP No OTA/No FS) epulse_feather.menu.PartitionScheme.max_app_8MB.build.partitions=max_app_8MB epulse_feather.menu.PartitionScheme.max_app_8MB.upload.maximum_size=8257536 @@ -33710,9 +33702,6 @@ epulse_feather.menu.FlashFreq.80.build.flash_freq=80m epulse_feather.menu.FlashFreq.40=40MHz epulse_feather.menu.FlashFreq.40.build.flash_freq=40m -epulse_feather.menu.FlashSize.8M=8MB (64Mb) -epulse_feather.menu.FlashSize.8M.build.flash_size=8MB - epulse_feather.menu.UploadSpeed.921600=921600 epulse_feather.menu.UploadSpeed.921600.upload.speed=921600 epulse_feather.menu.UploadSpeed.115200=115200 From 784ba99660965e2ed1ec3d11eb6355a6ae9df150 Mon Sep 17 00:00:00 2001 From: Matthias Prinke Date: Fri, 16 Feb 2024 17:22:16 +0100 Subject: [PATCH 4/6] Set some unspecified pins to -1 --- variants/thingpulse_epulse_feather/pins_arduino.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/variants/thingpulse_epulse_feather/pins_arduino.h b/variants/thingpulse_epulse_feather/pins_arduino.h index 181354dc365..3538c84128a 100644 --- a/variants/thingpulse_epulse_feather/pins_arduino.h +++ b/variants/thingpulse_epulse_feather/pins_arduino.h @@ -3,12 +3,17 @@ #include +static const uint8_t LED_BUILTIN = -1; +#define BUILTIN_LED LED_BUILTIN // backward compatibility +#define LED_BUILTIN LED_BUILTIN // allow testing #ifdef LED_BUILTIN + static const uint8_t SDA = 23; static const uint8_t SCL = 22; static const uint8_t MOSI = 18; static const uint8_t MISO = 19; static const uint8_t SCK = 5; +static const uint8_t SS = -1; // mapping to match other feathers and also in order static const uint8_t A0 = 26; From 02ee163c95f07836acc66e2ef73c50f1c50086c6 Mon Sep 17 00:00:00 2001 From: Matthias Prinke Date: Mon, 19 Feb 2024 17:56:29 +0100 Subject: [PATCH 5/6] epulse_feather: Modified PSRAM definitions --- boards.txt | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/boards.txt b/boards.txt index 837542676f4..d47cb4b7f79 100644 --- a/boards.txt +++ b/boards.txt @@ -33657,15 +33657,11 @@ epulse_feather.build.partitions=default_8MB epulse_feather.build.defines= epulse_feather.build.loop_core= epulse_feather.build.event_core= -epulse_feather.build.psram_type=qspi -epulse_feather.build.memory_type={build.flash_type}_{build.psram_type} +epulse_feather.menu.PSRAM.enabled=Enabled +epulse_feather.menu.PSRAM.enabled.build.defines=-DBOARD_HAS_PSRAM epulse_feather.menu.PSRAM.disabled=Disabled epulse_feather.menu.PSRAM.disabled.build.defines= -epulse_feather.menu.PSRAM.disabled.build.psram_type=qspi -epulse_feather.menu.PSRAM.enabled=QSPI PSRAM -epulse_feather.menu.PSRAM.enabled.build.defines=-DBOARD_HAS_PSRAM -epulse_feather.menu.PSRAM.enabled.build.psram_type=qspi epulse_feather.menu.LoopCore.1=Core 1 epulse_feather.menu.LoopCore.1.build.loop_core=-DARDUINO_RUNNING_CORE=1 From 019a212be6b26b5645e4231c18b008e57b4bc48b Mon Sep 17 00:00:00 2001 From: Matthias Prinke <83612361+matthias-bs@users.noreply.github.com> Date: Tue, 20 Feb 2024 14:18:18 +0100 Subject: [PATCH 6/6] Update boards.txt --- boards.txt | 1 - 1 file changed, 1 deletion(-) diff --git a/boards.txt b/boards.txt index d47cb4b7f79..169887e5e5f 100644 --- a/boards.txt +++ b/boards.txt @@ -33651,7 +33651,6 @@ epulse_feather.build.f_cpu=240000000L epulse_feather.build.flash_size=8MB epulse_feather.build.flash_freq=80m epulse_feather.build.flash_mode=dio -epulse_feather.build.flash_type=qio epulse_feather.build.boot=dio epulse_feather.build.partitions=default_8MB epulse_feather.build.defines=