Skip to content

Commit

Permalink
Cleanup NRF s140 Softdevice variants (#4252)
Browse files Browse the repository at this point in the history
Note: This idea is originally from @caveman99 and should be
credited as such. Submitting as a separate PR so the work in
#4148 can be a bit cleaner and Seeed boards
can build while that work is ongoing.

The nrf52 boards that depend on the v7 softdevice all use the same
code and linker files. Rather than duplicate the code, keep it
all together with the platform.
  • Loading branch information
fifieldt authored Jul 8, 2024
1 parent e1bf4c3 commit deb7c27
Show file tree
Hide file tree
Showing 25 changed files with 10 additions and 86 deletions.
2 changes: 1 addition & 1 deletion boards/wio-tracker-wm1110.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,6 @@
"require_upload_port": true,
"wait_for_upload_port": true
},
"url": "https://www.seeedstudio.com/Wio-WM1110-Dev-Kit-p-5677.html",
"url": "https://www.seeedstudio.com/Wio-Tracker-1110-Dev-Board-p-5799.html",
"vendor": "Seeed Studio"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ the start of the SoftDevice (without MBR)*/
* Add @ref MBR_SIZE to find the first available flash address when the SoftDevice is installed
* just above the MBR (the usual case).
*/
#define SD_FLASH_SIZE 0x26000
#define SD_FLASH_SIZE 0x27000

/** @brief Defines a macro for retrieving the actual FWID value from a given base address. Use
* @ref MBR_SIZE as the argument when the SoftDevice is installed just above the MBR (the usual
Expand Down
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions variants/wio-sdk-wm1110/platformio.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
; The very slick RAK wireless RAK 4631 / 4630 board - Unified firmware for 5005/19003, with or without OLED RAK 1921
; The black Wio-WM1110 Dev Kit with sensors and the WM1110 module
[env:wio-sdk-wm1110]
extends = nrf52840_base
board = wio-sdk-wm1110
Expand All @@ -8,10 +8,10 @@ build_unflags = ${nrf52840_base:build_unflags} -DUSBCON -DUSE_TINYUSB

board_level = extra
; platform = https://github.com/maxgerhardt/platform-nordicnrf52#cac6fcf943a41accd2aeb4f3659ae297a73f422e
build_flags = ${nrf52840_base.build_flags} -Ivariants/wio-sdk-wm1110 -DWIO_WM1110
build_flags = ${nrf52840_base.build_flags} -Ivariants/wio-sdk-wm1110 -Isrc/platform/nrf52/softdevice -Isrc/platform/nrf52/softdevice/nrf52 -DWIO_WM1110
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m4/fpv4-sp-d16-hard"
-DGPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.
board_build.ldscript = variants/wio-sdk-wm1110/nrf52840_s140_v7.ld
board_build.ldscript = src/platform/nrf52/nrf52840_s140_v7.ld
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/wio-sdk-wm1110>
lib_deps =
${nrf52840_base.lib_deps}
Expand Down
38 changes: 0 additions & 38 deletions variants/wio-tracker-wm1110/nrf52840_s140_v7.ld

This file was deleted.

6 changes: 3 additions & 3 deletions variants/wio-tracker-wm1110/platformio.ini
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
; The very slick RAK wireless RAK 4631 / 4630 board - Unified firmware for 5005/19003, with or without OLED RAK 1921
; The red tracker Dev Board with the WM1110 module
[env:wio-tracker-wm1110]
extends = nrf52840_base
board = wio-tracker-wm1110
; platform = https://github.com/maxgerhardt/platform-nordicnrf52#cac6fcf943a41accd2aeb4f3659ae297a73f422e
build_flags = ${nrf52840_base.build_flags} -Ivariants/wio-tracker-wm1110 -DWIO_WM1110
build_flags = ${nrf52840_base.build_flags} -Ivariants/wio-tracker-wm1110 -Isrc/platform/nrf52/softdevice -Isrc/platform/nrf52/softdevice/nrf52 -DWIO_WM1110
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m4/fpv4-sp-d16-hard"
-DGPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely.
board_build.ldscript = variants/wio-tracker-wm1110/nrf52840_s140_v7.ld
board_build.ldscript = src/platform/nrf52/nrf52840_s140_v7.ld
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/wio-tracker-wm1110>
lib_deps =
${nrf52840_base.lib_deps}
Expand Down
38 changes: 0 additions & 38 deletions variants/xiao_ble/nrf52840_s140_v7.ld

This file was deleted.

4 changes: 2 additions & 2 deletions variants/xiao_ble/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
extends = nrf52840_base
board = xiao_ble_sense
board_level = extra
build_flags = ${nrf52840_base.build_flags} -Ivariants/xiao_ble -Ivariants/xiao_ble/softdevice -Ivariants/xiao_ble/softdevice/nrf52 -DEBYTE_E22 -DEBYTE_E22_900M30S -DPRIVATE_HW
build_flags = ${nrf52840_base.build_flags} -Ivariants/xiao_ble -Isrc/platform/nrf52/softdevice -Isrc/platform/nrf52/softdevice/nrf52 -D EBYTE_E22 -DEBYTE_E22_900M30S -DPRIVATE_HW
-L "${platformio.libdeps_dir}/${this.__env__}/bsec2/src/cortex-m4/fpv4-sp-d16-hard"
board_build.ldscript = variants/xiao_ble/nrf52840_s140_v7.ld
board_build.ldscript = src/platform/nrf52/nrf52840_s140_v7.ld
build_src_filter = ${nrf52_base.build_src_filter} +<../variants/xiao_ble>
lib_deps =
${nrf52840_base.lib_deps}
Expand Down

0 comments on commit deb7c27

Please sign in to comment.