Skip to content

Commit d41fd63

Browse files
committed
Update bootloader options to allow for softdevices/adafruit stock bootloader
1 parent 1e75b69 commit d41fd63

11 files changed

+50
-6
lines changed

boards.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,12 @@ Generic_nRF52832.menu.cppDbgLvl.debug.build.cpp_debug=4
7777
Generic_nRF52832.menu.bootloader.none=No bootloader
7878
Generic_nRF52832.menu.bootloader.none.bootloader.flags=
7979
Generic_nRF52832.menu.bootloader.none.build.bootloader.file=tools/none_bootloader.hex
80+
Generic_nRF52832.menu.bootloader.serial=Serial
81+
Generic_nRF52832.menu.bootloader.serial.bootloader.flags=-DUSE_ADA_BL
82+
Generic_nRF52832.menu.bootloader.serial.build.bootloader.file=tools/serial_bootloader.hex
83+
Generic_nRF52832.menu.bootloader.s132=S132 SoftDevice
84+
Generic_nRF52832.menu.bootloader.s132.bootloader.flags=-DUSE_ADA_BL
85+
Generic_nRF52832.menu.bootloader.s132.build.bootloader.file=tools/s132_bootloader.hex
8086

8187

8288
nRF52DK.name=Nordic nRF52832DK (PCA10040)
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/* Linker script to configure memory regions. */
2+
3+
SEARCH_DIR(.)
4+
GROUP(-lgcc -lc -lnosys)
5+
6+
MEMORY
7+
{
8+
FLASH (rx) : ORIGIN = 0x26000, LENGTH = 0x74000 - 0x26000 - 0x4000
9+
USER_STORE (rw) : ORIGIN = 0x74000 - 0x4000, LENGTH = 0x2000
10+
BOND_STORE (rw) : ORIGIN = 0x74000 - 0x2000, LENGTH = 0x2000
11+
RAM (rwx) : ORIGIN = 0x20003600, LENGTH = 0x20010000 - 0x20003600
12+
}

cores/nRF5/nordic/linker/nrf52832_xxaa.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ GROUP(-lgcc -lc -lnosys)
55

66
MEMORY
77
{
8-
FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x7C000
8+
FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x80000 - 0x4000
99
USER_STORE (rw) : ORIGIN = 0x7C000, LENGTH = 0x2000
1010
BOND_STORE (rw) : ORIGIN = 0x7E000, LENGTH = 0x2000
1111
RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x10000

cores/nRF5/nordic/linker/nrf52_xxaa_adabl.ld renamed to cores/nRF5/nordic/linker/nrf52832_xxaa_serial_adabl.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ GROUP(-lgcc -lc -lnosys)
55

66
MEMORY
77
{
8-
FLASH (rx) : ORIGIN = 0x00001000, LENGTH = 0x6F000
8+
FLASH (rx) : ORIGIN = 0x00001000, LENGTH = 0x74000 - 0x1000 - 0x4000
99
USER_STORE (rw) : ORIGIN = 0x70000, LENGTH = 0x2000
1010
BOND_STORE (rw) : ORIGIN = 0x72000, LENGTH = 0x2000
1111
RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 0xFFF8
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/* Linker script to configure memory regions. */
2+
3+
SEARCH_DIR(.)
4+
GROUP(-lgcc -lc -lnosys)
5+
6+
MEMORY
7+
{
8+
FLASH (rx) : ORIGIN = 0x26000, LENGTH = 0x74000 - 0x26000 - 0x4000
9+
USER_STORE (rw) : ORIGIN = 0x74000 - 0x4000, LENGTH = 0x2000
10+
BOND_STORE (rw) : ORIGIN = 0x74000 - 0x2000, LENGTH = 0x2000
11+
RAM (rwx) : ORIGIN = 0x20006000, LENGTH = 0x20020000 - 0x20006000
12+
}

cores/nRF5/nordic/linker/nrf52833_xxaa.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ GROUP(-lgcc -lc -lnosys)
55

66
MEMORY
77
{
8-
FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x7C000
8+
FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x80000 - 0x4000
99
USER_STORE (rw) : ORIGIN = 0x7C000, LENGTH = 0x2000
1010
BOND_STORE (rw) : ORIGIN = 0x7E000, LENGTH = 0x2000
1111
RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 0x20000

cores/nRF5/nordic/linker/nrf52833_xxaa_adabl.ld renamed to cores/nRF5/nordic/linker/nrf52833_xxaa_serial_adabl.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ GROUP(-lgcc -lc -lnosys)
55

66
MEMORY
77
{
8-
FLASH (rx) : ORIGIN = 0x00001000, LENGTH = 0x6F000
8+
FLASH (rx) : ORIGIN = 0x00001000, LENGTH = 0x74000 - 0x1000 - 0x4000
99
USER_STORE (rw) : ORIGIN = 0x70000, LENGTH = 0x2000
1010
BOND_STORE (rw) : ORIGIN = 0x72000, LENGTH = 0x2000
1111
RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 0x1FFF8
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/* Linker script to configure memory regions. */
2+
3+
SEARCH_DIR(.)
4+
GROUP(-lgcc -lc -lnosys)
5+
6+
MEMORY
7+
{
8+
FLASH (rx) : ORIGIN = 0x26000, LENGTH = 0xF4000 - 0x26000 - 0x4000
9+
USER_STORE (rw) : ORIGIN = 0xF4000 - 0x4000, LENGTH = 0x2000
10+
BOND_STORE (rw) : ORIGIN = 0xF4000 - 0x2000, LENGTH = 0x2000
11+
RAM (rwx) : ORIGIN = 0x20006000, LENGTH = 0x20040000 - 0x20006000
12+
}
13+
14+
INCLUDE "nrf52_common.ld"

cores/nRF5/nordic/linker/nrf52840_xxaa.ld

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ GROUP(-lgcc -lc -lnosys)
55

66
MEMORY
77
{
8-
FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0xFC0000
8+
FLASH (rx) : ORIGIN = 0x00000000, LENGTH = 0x100000 - 0x4000
99
USER_STORE (rw) : ORIGIN = 0xFC000, LENGTH = 0x2000
1010
BOND_STORE (rw) : ORIGIN = 0xFE000, LENGTH = 0x2000
1111
EXTFLASH (rx) : ORIGIN = 0x12000000, LENGTH = 0x8000000

0 commit comments

Comments
 (0)