Mesh 5.0.0 Nrf52 17.0.0 MERGE firmware

Hi.

I'm using MESH 5.0.0 + nRF5_SDK_17.0.2 + nrf52840

We have implemented Mesh + reading sensor + DFU update by mesh + eeprom.

We want to MERGE all in one .HEX file (softdevice + bootloader + program + page), but I didnt know how to do it.

To load the firmware to MCU we do 4 step with the nrfjprog, there are the follow:

1.- nrfjprog --program s140_nrf52_7.2.0_softdevice.hex --verify
 
2.- nrfjprog --program mesh_bootloader_serial_gccarmemb_nrf52840_xxAA.hex --verify
 
3.- nrfjprog --program nrf52840_mesh_Node_V1.hex --verify
 
4.- nrfjprog --program device_page_nrf52840_xxAA_s140_7.2.0.hex --verify
 
5.- nrfjprog --reset
We have tried to download the HEX from the programmer application, using the button "SAVE AS FILE",  show the next screenshot.
with this procedure, we get the HEX MERGED, all in one file.
We can upload the HEX to the MCU fine. when we checked the block memory usage in the NEW MCU, it has the same pattern as the original MCU.
But when the MCU start send an error, I copied the error.
This is the Error when the firmware start. 
And here is how the node works with the original procedure (using nrfjprog )
Could you give us some  hint or if there some guide to merge all the files?
thanks.
Ricardo
  • Hi,

    For merging files, you can use mergehex, which is part of nRF Command Line Tools.

    One reason why it may fail when using the method you are using, is that there may be some values in UICR which are not part of save file from the nRF Connect for Desktop Programmer App. Typically UICR is used for storing the bootloader address, metadata pages, etc. which is required for the operation of the device. You should therefore always use tools such as mergehex for merging hex files, and not rely on writing to and reading from a device.

    Regards,
    Terje

Related