This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

for merge hex files

Hi. I'm using nRF51822AC, SDK12.2.0, S130 v2.0.1 as central.

I'm using mergehex for merging hex files. It's mergehex --merge s130_nrf51_2.0.1_softdevice.hex nrf51422_xxac.hex --output out.hex It has worked well.

But after I added bootloader_secure as below

mergehex --merge s130_nrf51_2.0.1_softdevice.hex nrf51422_xxac.hex bootloader_secure.hex --output out.hex

I faced a problem. I can download merged file to J-flash, but it can't download file to target.

I think it's memory map problem.

I'm using memory map as below.

App : IROM1 : Start :0x1B000 Size : 0x1FC00

Boot: IROM1 : Start :0x3AC00 Size : 0x5000

Is it right?

I need your help.

Ps. When I compile and execute bootloader, I can see the keil message as below.

No Algorithm found for: 10001014H - 10001017H Partial Erase Done (areas with no algorithms skipped!) No Algorithm found for: 10001014H - 10001017H Partial Programming Done (areas with no algorithms skipped!) Partial Verify OK (areas with no algorithms skipped!) Application running ...

I didn't care because code was running well.

  • No I'm not. How can I use? What is the output file from nrfjprog? Can I also merge boot, app, softdevice? I must have just 1 file including boot, app, softdevice. Because there is no computer in my company's plant. They are using Flasher Portable. That's why I should make them 1 file.

    I hope your reply.

  • What I was asking was if you were using nrfjprog to flash the combined hex file to your nrf51822 device. nrfjprog(used to program nRF5x devices) and mergehex(used to merge hexfile for the nRF5x) are a part of the nRF5x Commandline tools. Can you try to flash the combined image using nrfjprog? If it fails can you post the error message. Can you also tell me the ROM and RAM settings for you bootloader and application?

  • I can see it is OK as below.

    F:\02 Nordic\02 Tool\Flasher\Hex_multi>nrfjprog --eraseall Erasing code and UICR flash areas. Applying system reset.

    F:\02 Nordic\02 Tool\Flasher\Hex_multi>nrfjprog --program out.hex Parsing hex file. Reading flash area to program to guarantee it is erased. Checking that the area to write is not protected. Programing device.

    And the flashing using J-flash is also OK.

    But I still don't know what was problem.

    I need your help.

  • It could be that you did not erase the chip prior to programming the combined hex. If your going to use nrjfprog then I suggest that you add the --chiperase option to erase the entire chip before flashing the combined hex, i.e.

    nrfjprog --program out.hex --chiperase
    
  • How can I use nrfjprog without PC? I have to consider our manufacturer lines. There is no PC. I think I have to check if J-flash has the function for erasing UICR area.

Related