Apparently, the dfu bootloader example in nrf51 SDK 8.1 is not working on PCA10031 type(16K RAM devices). In my case, the device is RedBearLab BLE Nano and nrf51822. Can anybody help?
Apparently, the dfu bootloader example in nrf51 SDK 8.1 is not working on PCA10031 type(16K RAM devices). In my case, the device is RedBearLab BLE Nano and nrf51822. Can anybody help?
You need to change the linker settings of the bootloader project, taking into account that you have 0x4000 byte less RAM.
If you use Keil you need to go to Project -> Options for Target ... -> Target. Then in the lower right half of the pane you have a section called "Read/Write Memory Areas". There you should update the following:
If you use GCC you would have to change the linker script (examples/dfu/bootloader/dfu_gcc_nrf51.ld) in the same way:
RAM
LENGTH
to 0x1380 (line 17)NOINIT
ORIGIN
to 0x20003F80 (line 22)You need to change the linker settings of the bootloader project, taking into account that you have 0x4000 byte less RAM.
If you use Keil you need to go to Project -> Options for Target ... -> Target. Then in the lower right half of the pane you have a section called "Read/Write Memory Areas". There you should update the following:
If you use GCC you would have to change the linker script (examples/dfu/bootloader/dfu_gcc_nrf51.ld) in the same way:
RAM
LENGTH
to 0x1380 (line 17)NOINIT
ORIGIN
to 0x20003F80 (line 22)For the SDK12.1, nrf51 and the bootloader_secure example this wont compile.
Can we lower the start address 0x20002C00? How is this derived? Thanks!
Is the start address of IRAM1 (0x20002C00) common for all soft devices? Can it be set to 0x20002000 for s110 (same as in the application) ?
The S110 version 8 require 8 kB RAM (0x2000 bytes). This means that the applications IRAM1 start address must be 0x20002000 and the size 0x6000 or 0x2000, depending on whether you have a part with 16 kB or 32 kB RAM.
The RAM usage of the SoftDevice, which dictate the RAM start address for the application, is different for all SoftDevice versions. For the more recent SoftDevices the RAM requirement also depend on the bandwidth configuration, but this is not the case for the S110. You can find the correct number for each version of the S110 in the SoftDevice specification.