Flash error sometime

Some time i got this error msg

error] [ Client] - Encountered error -105: Command connect_to_emu_with_snr executed for 40 milliseconds with result -105
ERROR: Unable to connect to a debugger.
[error] [ Worker] - JLinkARM.dll Open returned error 'Cannot connect to J-Link.'
ERROR: The JLinkARM DLL timed out while communicating to the J-Link probe.
ERROR: If the error condition persists, run the same command again with
ERROR: argument -- log, contact Nordic Semiconductor and provide the generated
ERROR: log.log file to them.
NOTE: For additional output, try running again with logging enabled (--log).
NOTE: Any generated log error messages will be displayed.
FATAL ERROR: command exited with status 35: nrfjprog --program .....edge/build_1/zephyr/merged.hex --sectoranduicrerase --verify -f NRF52 --snr 1050250697

[error] [ Client] - Encountered error -160: Command verify_file executed for 318 milliseconds with result -160
[error] [ nRF52] - Failed while performing 'Verify' operation on target address 0x00000000.
-160: Data does not match in address range [0x00000000 - 0x000088BD] (Flash)
Expected byte value 0xC0 but read 0x80 at address 0x00001448.
[error] [ nRF52] - Failed while verifying device. -160: Data does not match in address range [0x00000000 - 0x000088BD] (Flash)
Expected byte value 0xC0 but read 0x80 at address 0x00001448.
[error] [ Worker] - Data does not match in address range [0x00000000 - 0x000088BD] (Flash)
Expected byte value 0xC0 but read 0x80 at address 0x00001448.
ERROR: Write verify failed.
NOTE: For additional output, try running again with logging enabled (--log).
NOTE: Any generated log error messages will be displayed.

a recover or earease all helps but not garanteed.

  • Hello,

    Which application you are working on? Is this you custom board or nordic DK?

  • Which application?

     "JLinkARM.dll Open returned error 'Cannot connect to J-Link.'" shows that the system is unable to establish a connection with the J-Link debugger. It could be something wrong with powering the target board. How have you powered the board? 

  • Yes the first is clear, but why this happen. 

    The second message make me more worry. 

    Flashing build_release to 1050250697
    west flash -d git/trailpulse-edge/build_release --skip-rebuild --dev-id 1050250697
    
    -- west flash: using runner nrfjprog
    -- runners.nrfjprog: reset after flashing requested
    -- runners.nrfjprog: Flashing file: git/trailpulse-edge/build_release/zephyr/merged.hex
    [ #################### ] 9.216s | Erase file - Done erasing
    [error] [ Client] - Encountered error -102: Command program_file executed for 6820 milliseconds with result -102
    [error] [ nRF52] - The write access failed, but no cause could be determined.
    [error] [ nRF52] - It may be due to an unaligned access, accessing a nonexistent memory, or a communication issue.
    [error] [ nRF52] - Failed while performing 'Write' operation on target address 0x0000C000.
    -102: An unknown error.
    [error] [ nRF52] - Failed while reading device information.
    [error] [ Worker] - An unknown error.
    ERROR: JLinkARM DLL reported an error. Try again. If error condition
    ERROR: persists, run the same command again with argument --log, contact Nordic
    ERROR: Semiconductor and provide the generated log.log file to them.
    NOTE: For additional output, try running again with logging enabled (--log).
    NOTE: Any generated log error messages will be displayed.
    FATAL ERROR: command exited with status 33: nrfjprog --program git/trailpulse-edge/build_release/zephyr/merged.hex --sectoranduicrerase --verify -f NRF52 --snr 1050250697

    Coding with 2.6.1 and 2.7.0, zephry vs code programming over dk to a RAK4631 SWD.
    Board is powered by battery, ground is also over the swd. with ppk it's the same as power source

    Happend after enable pm!

  • Hello,

    ''Coding with 2.6.1 and 2.7.0, zephry vs code programming over dk to a RAK4631 SWD.
    Board is powered by battery, ground is also over the swd.''

    So, the RAK4631 module is programmed by our nRF52840DK. How the DK is powered? when you programmed your module by DK, both should have same power level. have you checked the battery power is same as DK power source? If not change the battery.

    ''The voltage supported by external debugging/programming is VDD voltage. Normally, this is 3 V when running from USB. But if the onboard nRF52840 SoC is supplied from either USB or lithium-ion (Li-ion) and the nRF power source switch (SW9) is in either Li-Po or USB position, then the VDD can be set by the nRF52840 firmware. Make sure the voltage level of the external board matches the VDD of the nRF52840 DK''. spurce: https://docs.nordicsemi.com/bundle/ug_nrf52840_dk/page/UG/dk/hw_debug_out.html 

     ''zephry vs code programming '' - I am not sure which application you meant here. Buy you can try with a simple application from our samples and check.

    Recovering the board would be one option. So, try to use nrfjprog --recover command before flashing.

Related