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

Create boot settings for nRF51822 using SDK_11.0.0

We would like to create the boot settings page and merge it with the application and flash the merged hex file using J-Link and nrfjprog.exe in production.

Currently in production we program the nRF51822 with softdevice S130 and a boot-loader using J-link.  Then we program the application using the boot-loader.  Our production time would be significantly reduced if we could initially program the application directly.  We don't have direct access to the nRF51822 UART pins as they are connected to another microcontroller.

We are able to create the boot-setting page and flash the merged hex file for nRF52832 and SDK 15.3.0 with SoftDevice S132.  The process is well documented by Nordic

However there is not much documentation on how to do this for nRF51822 and SDK 11.0.0 with SoftDevice S130.  I have tried to adapt the process used for nRF52832.  However the boot-loader fails to start the application.  We see that the memory layout is different, and we think this may be the problem.

When we use the boot-loader to flash the application in nRF51822 it looks like the boot-setting page is created by the boot-loader at 0x0003FC00.  Our nrfutil creates a boot setting page also at this address.

Any suggestions on how to use nrfutil to create the boot-settings page would be greatly appreciated.

Parents Reply
  • This is how I did it:

    rem Program the application, without boot settings
    nrfjprog --program nrf51822_xxac_s130.hex --family NRF51 --sectorerase

    rem Erase boot settings page
    nrfjprog --erasepage 0x03FC00

    rem Program the BOOT_VALID-APP field in boot settings
    nrfjprog --memwr 0x03FC00 --val 0x00000001

    nrfjprog --reset

    Initially the nRF51822 contains only a softdevice and bootloader (programmed previously with nrfjprog). The application is flashed with the above commands using nrfjprog over J-link.  The boot-loader remains in place and can be used for subsequent application DFU over serial

    Thanks Vidar, your help is greatly appreciated.

Children
No Data
Related