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

proprietary OTA

I am working on a bootloader for a client. I’ve been looking at the DFU example that Nordic has. The BLE version of the DFU needs to have the special format using the “nrfutil dfu genpkg” command. The customer has their own proprietary OTA system to transfer a firmware image. The whole firmware image will be saved onto external flash. My thought was to write my own bootloader which takes the firmware image from the external flash and loads it into internal flash. If we do this can we use the base addresses (SoftDevice and application) and use that as the start positions for erasing and writing to internal flash? Also would we still need to modify the original application hex file using the “nrfutil dfu genpkg” command?

Parents
  • Yes, this is possible. The size of the softdevice is hardcoded in an info structure at 0x3000, see SD_SIZE_GET() macro in nrf_sdm.h.

    You do not need generate the application firmware packet using nrfutil, as the information in the firmware packet is only used to initiate the DFU process. The hexfile it self is not altered.

    You will have decide if you want to use the SoftDevice Flash API or use the NVMC(Non-volatile Memory controller) directly when writing to flash.

    If you want to do the latter, then I recommend that you take a look at this post, where you'll find a softdevice independent flash library(nrf_flash) written by a colleague of mine.

    Bjørn

Reply
  • Yes, this is possible. The size of the softdevice is hardcoded in an info structure at 0x3000, see SD_SIZE_GET() macro in nrf_sdm.h.

    You do not need generate the application firmware packet using nrfutil, as the information in the firmware packet is only used to initiate the DFU process. The hexfile it self is not altered.

    You will have decide if you want to use the SoftDevice Flash API or use the NVMC(Non-volatile Memory controller) directly when writing to flash.

    If you want to do the latter, then I recommend that you take a look at this post, where you'll find a softdevice independent flash library(nrf_flash) written by a colleague of mine.

    Bjørn

Children
No Data
Related