This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Does the SDK 5.2 bootloader support 128kb devices?

At work we are primarily interested in using the 128kb nRF51822 devices. I am able to get a softdevice and bootloader onto a 256kb device just fine. When I attempt to do the same for a 128kb device, nRFgo studio complains: "Failed: invalid parameter error"

The project has IROM1 from 0x3C800 with size 0x3400 and IRAM1 from 0x20002000 with size 0x2000 I copied the device_firmware_updates project into my own Boards/ folder. nRFgo Studio reports Region 0 with size 80kB filled with a softdevice and region 1 of size 48kB addr 0x14000

I can program and run firmware normally but I need to get a bootloader on the 128kB devices eventually.

Parents
  • It is possible to use DFU with our 128kB devices, however it leaves very little application space, at least with you want to use dual bank update.

    The bootloader in the SDK is to be used with the 256kB devices. To use it with a 128kB device, open the bootloader project and do the following:

    -In dfu_types.h: Change BOOTLOADER_REGION_START from 0x0003C800 to 0x0001C800.

    -In dfu_types.h: Change BOOTLOADER_SETTINGS_ADDRESS from 0x0003FC00 to 0x0001FC00.

    -In Target Options: Change the start of IROM1 from 0x3C800 to 0x1C800.

    To do the actual DFU:

    -Erase the chip with nrfjprog. Open cmd.exe and type nrfjprog --eraseall. Select the SEGGER serial number of your device.

    -Flash the SoftDevice using nRFgo Studio(I used S110 6.0.0)

    -Flash the edited bootloader project using Keil. Select the SEGGER serial number of your device.

    -Compile the project you want to update your device with, you should find a hex file in the _build folder. I used the iBeacon project, since it is small.

    -Open Master Control Panel 3.6.0 as administrator, find your device, select it.

    -Bond with it, do service discovery, click the DFU button and select the hex file.

    Your device, with updated application should then be discovered.

Reply
  • It is possible to use DFU with our 128kB devices, however it leaves very little application space, at least with you want to use dual bank update.

    The bootloader in the SDK is to be used with the 256kB devices. To use it with a 128kB device, open the bootloader project and do the following:

    -In dfu_types.h: Change BOOTLOADER_REGION_START from 0x0003C800 to 0x0001C800.

    -In dfu_types.h: Change BOOTLOADER_SETTINGS_ADDRESS from 0x0003FC00 to 0x0001FC00.

    -In Target Options: Change the start of IROM1 from 0x3C800 to 0x1C800.

    To do the actual DFU:

    -Erase the chip with nrfjprog. Open cmd.exe and type nrfjprog --eraseall. Select the SEGGER serial number of your device.

    -Flash the SoftDevice using nRFgo Studio(I used S110 6.0.0)

    -Flash the edited bootloader project using Keil. Select the SEGGER serial number of your device.

    -Compile the project you want to update your device with, you should find a hex file in the _build folder. I used the iBeacon project, since it is small.

    -Open Master Control Panel 3.6.0 as administrator, find your device, select it.

    -Bond with it, do service discovery, click the DFU button and select the hex file.

    Your device, with updated application should then be discovered.

Children
No Data
Related