RP2040/RP2350: Migrate variants to new structure (#7345)

This commit is contained in:
Austin 2025-07-20 07:20:57 -04:00 committed by GitHub
parent 44518fea14
commit 9313d04726
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
25 changed files with 68 additions and 64 deletions

View File

@ -2,13 +2,13 @@
extends = rp2040_base extends = rp2040_base
board = rpipico board = rpipico
upload_protocol = picotool upload_protocol = picotool
build_flags =
build_flags = ${rp2040_base.build_flags} ${rp2040_base.build_flags}
-DRPI_PICO -D RPI_PICO
-Ivariants/ec_catsniffer -I variants/rp2040/ec_catsniffer
-DDEBUG_RP2040_PORT=Serial -D DEBUG_RP2040_PORT=Serial
# -DHW_SPI1_DEVICE ; -D HW_SPI1_DEVICE
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags}, -g debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap debug_tool = cmsis-dap

View File

@ -2,14 +2,14 @@
extends = rp2040_base extends = rp2040_base
board = adafruit_feather board = adafruit_feather
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
-DRP2040_FEATHER_RFM95 ${rp2040_base.build_flags}
-Ivariants/feather_rp2040_rfm95 -D RP2040_FEATHER_RFM95
-DDEBUG_RP2040_PORT=Serial -I variants/rp2040/feather_rp2040_rfm95
-DHW_SPI1_DEVICE -D DEBUG_RP2040_PORT=Serial
-D HW_SPI1_DEVICE
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags} debug_build_flags = ${rp2040_base.build_flags}
debug_tool = cmsis-dap ; for e.g. Picotool debug_tool = cmsis-dap ; for e.g. Picotool

View File

@ -3,14 +3,14 @@ extends = rp2040_base
board = rpipico board = rpipico
board_level = extra board_level = extra
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
-DPRIVATE_HW ${rp2040_base.build_flags}
-Ivariants/nibble_rp2040 -D PRIVATE_HW
-DDEBUG_RP2040_PORT=Serial -I variants/rp2040/nibble_rp2040
-DHW_SPI1_DEVICE -D DEBUG_RP2040_PORT=Serial
-D HW_SPI1_DEVICE
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags}, -g debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool debug_tool = cmsis-dap ; for e.g. Picotool

View File

@ -2,18 +2,18 @@
extends = rp2040_base extends = rp2040_base
board = rakwireless_rak11300 board = rakwireless_rak11300
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
-DRAK11310 ${rp2040_base.build_flags}
-Ivariants/rak11310 -D RAK11310
-DDEBUG_RP2040_PORT=Serial -I variants/rp2040/rak11310
-DRV3028_RTC=0x52 -D DEBUG_RP2040_PORT=Serial
build_src_filter = ${rp2040_base.build_src_filter} +<../variants/rak11310> +<mesh/eth/> +<mesh/api/> +<mqtt/> -D RV3028_RTC=0x52
build_src_filter = ${rp2040_base.build_src_filter} +<../variants/rp2040/rak11310> +<mesh/eth/> +<mesh/api/> +<mqtt/>
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
${networking_base.lib_deps} ${networking_base.lib_deps}
melopero/Melopero RV3028@^1.1.0 melopero/Melopero RV3028@^1.1.0
https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip https://github.com/RAKWireless/RAK13800-W5100S/archive/1.0.2.zip
debug_build_flags = ${rp2040_base.build_flags}, -g debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool debug_tool = cmsis-dap ; for e.g. Picotool

View File

@ -2,14 +2,14 @@
extends = rp2040_base extends = rp2040_base
board = rpipico board = rpipico
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
-DRP2040_LORA ${rp2040_base.build_flags}
-Ivariants/rp2040-lora -D RP2040_LORA
-DDEBUG_RP2040_PORT=Serial -I variants/rp2040/rp2040-lora
-DHW_SPI1_DEVICE -D DEBUG_RP2040_PORT=Serial
-D HW_SPI1_DEVICE
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags}, -g debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool debug_tool = cmsis-dap ; for e.g. Picotool

View File

@ -12,11 +12,11 @@ debug_init_cmds =
$LOAD_CMDS $LOAD_CMDS
monitor init monitor init
monitor reset halt monitor reset halt
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
${rp2040_base.build_flags}
-DRPI_PICO -DRPI_PICO
-Ivariants/rpipico-slowclock -Ivariants/rp2040/rpipico-slowclock
-DDEBUG_RP2040_PORT=Serial2 -DDEBUG_RP2040_PORT=Serial2
-DHW_SPI1_DEVICE -DHW_SPI1_DEVICE
-g -g
@ -25,4 +25,4 @@ lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags} debug_build_flags = ${rp2040_base.build_flags}
-g -g
-DNO_USB -DNO_USB

View File

@ -4,12 +4,13 @@ board = rpipico
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
-DRPI_PICO ${rp2040_base.build_flags}
-Ivariants/rpipico -D RPI_PICO
-DDEBUG_RP2040_PORT=Serial -I variants/rp2040/rpipico
-DHW_SPI1_DEVICE -D DEBUG_RP2040_PORT=Serial
-D HW_SPI1_DEVICE
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}
debug_build_flags = ${rp2040_base.build_flags}, -g debug_build_flags = ${rp2040_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool debug_tool = cmsis-dap ; for e.g. Picotool

View File

@ -2,14 +2,14 @@
extends = rp2040_base extends = rp2040_base
board = rpipicow board = rpipicow
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags =
-DRPI_PICO ${rp2040_base.build_flags}
-Ivariants/rpipicow -D RPI_PICO
-DHW_SPI1_DEVICE -I variants/rp2040/rpipicow
-D HW_SPI1_DEVICE
-D HAS_UDP_MULTICAST=1
-fexceptions # for exception handling in MQTT -fexceptions # for exception handling in MQTT
-DHAS_UDP_MULTICAST=1
build_src_filter = ${rp2040_base.build_src_filter} +<mesh/wifi/> build_src_filter = ${rp2040_base.build_src_filter} +<mesh/wifi/>
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}

View File

@ -5,9 +5,9 @@ board = rpipico
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2040_base.build_flags} build_flags = ${rp2040_base.build_flags}
-DSENSELORA_RP2040 -D SENSELORA_RP2040
-Ivariants/senselora_rp2040 -I variants/rp2040/senselora_rp2040
-DDEBUG_RP2040_PORT=Serial -D DEBUG_RP2040_PORT=Serial
lib_deps = lib_deps =
${rp2040_base.lib_deps} ${rp2040_base.lib_deps}

View File

@ -6,6 +6,7 @@
#define BUTTON_NEED_PULLUP #define BUTTON_NEED_PULLUP
#define LED_PIN PIN_LED #define LED_PIN PIN_LED
#define ledOff(pin) pinMode(pin, INPUT)
#undef BATTERY_PIN #undef BATTERY_PIN
#define BATTERY_SENSE_RESOLUTION_BITS ADC_RESOLUTION #define BATTERY_SENSE_RESOLUTION_BITS ADC_RESOLUTION

View File

@ -4,12 +4,13 @@ board = rpipico2
upload_protocol = picotool upload_protocol = picotool
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2350_base.build_flags} build_flags =
-DRPI_PICO2 ${rp2350_base.build_flags}
-Ivariants/rpipico2 -D RPI_PICO2
-DDEBUG_RP2040_PORT=Serial -I variants/rp2350/rpipico2
-DHW_SPI1_DEVICE -D DEBUG_RP2040_PORT=Serial
-D HW_SPI1_DEVICE
lib_deps = lib_deps =
${rp2350_base.lib_deps} ${rp2350_base.lib_deps}
debug_build_flags = ${rp2350_base.build_flags}, -g debug_build_flags = ${rp2350_base.build_flags}, -g
debug_tool = cmsis-dap ; for e.g. Picotool debug_tool = cmsis-dap ; for e.g. Picotool

View File

@ -13,9 +13,10 @@ debug_init_cmds =
monitor reset halt monitor reset halt
# add our variants files to the include and src paths # add our variants files to the include and src paths
build_flags = ${rp2350_base.build_flags} build_flags =
${rp2350_base.build_flags}
-DRPI_PICO2 -DRPI_PICO2
-Ivariants/rpipico2w -Ivariants/rp2350/rpipico2w
# -DDEBUG_RP2040_PORT=Serial # -DDEBUG_RP2040_PORT=Serial
-DHW_SPI1_DEVICE -DHW_SPI1_DEVICE
-DARDUINO_RASPBERRY_PI_PICO_2W -DARDUINO_RASPBERRY_PI_PICO_2W