Thingy:91X - flashing connectivity bridge with jlink reports error

I build the NCS 2.9.1 connectivity bridge with

west build -b thingy91x/nrf5340/cpuapp

when I try to flash that with jlink, I get

west flash
-- west flash: rebuilding
[0/45] Performing build step for 'ipc_radio'
ninja: no work to do.
[1/45] Performing build step for 'connectivity_bridge'
ninja: no work to do.
[5/41] Performing build step for 'mcuboot'
ninja: no work to do.
[9/40] Performing build step for 's1_image'
ninja: no work to do.
[13/34] Performing build step for 'b0'
ninja: no work to do.
[17/28] Performing build step for 'b0n'
ninja: no work to do.
[24/26] cd /home/achim/ncs/v2.9.1/nrf/applications/connectivity_bridge/build/_sysbuild && /home/achim/ncs/toolchains/b77d8c1312/usr/local/bin/cmake -E true
-- west flash: using runner nrfutil
-- runners.nrfutil: reset after flashing requested
Using board 000822000535
-- runners.nrfutil: Flashing file: /home/achim/ncs/v2.9.1/nrf/applications/connectivity_bridge/build/merged_CPUNET.hex
-- runners.nrfutil: Erasing pages touched by firmware
-- runners.nrfutil: Programming image
-- runners.nrfutil: Verifying image
-- runners.nrfutil: Reset
-- runners.nrfutil: Board with serial number 822000535 flashed successfully.
-- west flash: using runner nrfutil
-- runners.nrfutil: reset after flashing requested
Using board 000822000535
-- runners.nrfutil: Flashing file: /home/achim/ncs/v2.9.1/nrf/applications/connectivity_bridge/build/merged.hex
-- runners.nrfutil: Erasing pages touched by firmware
Error: One or more batch tasks failed:
 * 822000535: [Probe] The firmware to program contains UICR data, but your device already has data there. These memory regions are not erasable with the erase option you selected. You need to run an ERASE_ALL to erase the UICR (Generic)

FATAL ERROR: command exited with status 1: nrfutil --json device x-execute-batch --batch-path /home/achim/ncs/v2.9.1/nrf/applications/connectivity_bridge/build/generated_nrfutil_batch.json --serial-number 822000535

Parents Reply Children
  • Sorry to write that:

    You mean, the "programmer app" with the "bedeviled genuine check"?

    I complained about that for years. In the past, so many people, including me, wasted so much time with that check, that I usually don't use the "programmer app" anymore now for a year. Using that "programmer app" with the "bedeviled genuine check" caused especially with the two MCU and the modem of the Thingy a lot of pain, if you want to update all. You frequently need to close and open it again, hopefully with everything in the right mode.

    Therefore I would prefer to use west/nrfjlink to flash it, because that has worked in the past without that pain. And for now, it only fails with the communication bridge of the Thingy:91X.

  • Thanks for the feedback Achim, its good. 

    UICR can only be erased with a recovery operation, so use "west flash --erase" or "west flash --recover" instead of just west flash. This might do the trick. 

    https://hello-nrfcloud.github.io/firmware/html/troubleshooting.html here is a guide that might help. 


    I advise to use nrfutil-device 2.7.14 as i know this works, there has been som minor issues in the latest versions. 

    Regards,
    Jonathan

Related