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

Not able to flash nRF5340 PDK anymore

Hey guys, 

All of a sudden, I'm not able to flash my nRF board anymore. I get the following message when I try to connect to the board using segger IDE.

And when I try west flash, I get the following:

As per that message, when I try "west flash --log", I get unknow command error.

Any help would be appreciated. 

Other info:

I'm pretty sure that it isn't a problem with the code I'm trying to flash or even anything on the PC because I have another one of the same board which works without any problem.

  • May you use the nrf connect or nrf studio go tools? It can erase all the protection , and you may flash the SOC normally.

  • Hi, 

    Can you try to run the following two commands:

    nrfjprog.exe --coprocessor CP_NETWORK --recover
    nrfjprog.exe --coprocessor CP_APPLICATION --recover

    Does that help? Or do you get an error in this case as well?

    -Amanda H.

  • I tried both the solutions mentioned but still no luck, both gave me error as shown below:

    Nrfjprog and the nrf connect had been updated prior to executing the commands.

    Disappointed

  • Please try the latest version of the nRF-Command-Line-Tools. If it still cannot fix the issue, run the following commands, and provide the logs. 

     

    nrfjprog.exe --coprocessor CP_NETWORK --recover --log NETWORK.log
    nrfjprog.exe --coprocessor CP_APPLICATION --recover --log APPLICATION.log

    -Amanda H.

  • Hey Amanda, 

    Here is the outcome of the commands you requested

    APPLICATION.log

    NETWORK.log

    [2020-Nov-15 14:51:01] [ info] --------------------------------------------------------------------------------
    [2020-Nov-15 14:51:01] [ info] C:\Program Files\Nordic Semiconductor\nrf-command-line-tools\bin\nrfjprog.exe --coprocessor CP_APPLICATION --recover --log APPLICATION_2.log 
    [2020-Nov-15 14:51:01] [ info] nrfjprog version 10.11.1 
    [2020-Nov-15 14:51:01] [ info] --------------------------------------------------------------------------------
    [2020-Nov-15 14:51:01] [debug] [ nRF0x0] - open_dll
    [2020-Nov-15 14:51:01] [ info] [ nRF0x0] - Load library at C:\Program Files\Nordic Semiconductor\nrf-command-line-tools\bin\JLINKARM_UNKNOWN_NRFJPROG.dll.
    [2020-Nov-15 14:51:01] [ info] [ nRF0x0] - Library loaded, loading member functions.
    [2020-Nov-15 14:51:01] [ info] [ nRF0x0] - Member functions succesfully loaded.
    [2020-Nov-15 14:51:01] [ info] [Backend] - Logger callback at 0x7ff70efa4b40 registered in Segger backend logger.
    [2020-Nov-15 14:51:01] [ info] [  JLink] - [Debug   ] [JLink     ] Logger callback at 0x7ff70efa4b40 registered in JLink logger.
    [2020-Nov-15 14:51:01] [debug] [nRFUnknown] - Just_open_dll_tagged_callback
    [2020-Nov-15 14:51:01] [debug] [Backend] - open_dll
    [2020-Nov-15 14:51:01] [ info] [Backend] - No J-Link DLL path was provided. Attempting to auto detect.
    [2020-Nov-15 14:51:01] [ info] [Backend] - Load library at C:\Program Files (x86)\SEGGER\JLink\JLink_x64.dll.
    [2020-Nov-15 14:51:01] [ info] [Backend] - Library loaded, loading member functions.
    [2020-Nov-15 14:51:01] [ info] [Backend] - Member functions succesfully loaded.
    [2020-Nov-15 14:51:01] [debug] [Backend] - dll_version
    [2020-Nov-15 14:51:01] [ info] [Backend] - Segger dll version 6.86.f loaded.
    [2020-Nov-15 14:51:01] [debug] [Backend] - set_core_data
    [2020-Nov-15 14:51:01] [debug] [ nRF0x0] - enum_emu_snr
    [2020-Nov-15 14:51:01] [debug] [nRFUnknown] - Just_enum_emu_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - enum_emu_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_enum_emu_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_get_num_emus
    [2020-Nov-15 14:51:01] [debug] [ nRF0x0] - connect_to_emu_with_snr
    [2020-Nov-15 14:51:01] [debug] [nRFUnknown] - Just_connect_to_emu_with_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - connect_to_emu_with_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_enum_emu_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_get_num_emus
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_connect_to_emu_with_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_connect_to_emu_without_snr
    [2020-Nov-15 14:51:01] [ info] [Backend] - Segger logging enabled.
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_load_core_data
    [2020-Nov-15 14:51:01] [ info] [  JLink] - [Debug   ] [JLink     ] Device "CORTEX-M4" selected.
    [2020-Nov-15 14:51:01] [debug] [ nRF0x0] - read_connected_emu_snr
    [2020-Nov-15 14:51:01] [debug] [nRFUnknown] - Just_read_connected_emu_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - read_connected_emu_snr
    [2020-Nov-15 14:51:01] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:51:01] [debug] [ nRF0x0] - read_device_family
    [2020-Nov-15 14:51:01] [debug] [nRFUnknown] - Just_read_device_family
    [2020-Nov-15 14:51:01] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:51:01] [debug] [Backend] - read_debug_port_idr
    [2020-Nov-15 14:51:01] [debug] [Backend] - read_debug_port_register
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_read_debug_port_register
    [2020-Nov-15 14:51:01] [debug] [Backend] - coresight_configure
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_select_debug_port_register
    [2020-Nov-15 14:51:01] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2020-Nov-15 14:51:01] [error] [  JLink] - [Debug   ] [JLink     ] Not supported by current CPU + target interface combination.
    [2020-Nov-15 14:51:01] [ info] [Backend] - JLinkARM.dll reported "-2", an unknown error.
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_abort_debug_action
    [2020-Nov-15 14:51:01] [ info] [Backend] - Attempting to clear any configuration errors in debug port before closing connection. 
    [2020-Nov-15 14:51:01] [debug] [ nRF0x0] - close_dll
    [2020-Nov-15 14:51:01] [debug] [nRFUnknown] - Just_close_dll
    [2020-Nov-15 14:51:01] [debug] [Backend] - close
    [2020-Nov-15 14:51:01] [debug] [Backend] - disconnect_from_emu
    [2020-Nov-15 14:51:01] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_disconnect_from_emu
    [2020-Nov-15 14:51:01] [debug] [Backend] - is_connected_to_device
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_is_debug_region_powered
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_read_debug_port_register
    [2020-Nov-15 14:51:01] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_select_debug_port_register
    [2020-Nov-15 14:51:01] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2020-Nov-15 14:51:01] [error] [  JLink] - [Debug   ] [JLink     ] Not supported by current CPU + target interface combination.
    [2020-Nov-15 14:51:01] [ info] [Backend] - JLinkARM.dll reported "-2", an unknown error.
    [2020-Nov-15 14:51:01] [debug] [Backend] - ---just_abort_debug_action
    [2020-Nov-15 14:51:01] [ info] [Backend] - Attempting to clear any configuration errors in debug port before closing connection. 
    [2020-Nov-15 14:51:01] [debug] [Backend] - Segger Backend closed.
    

    [2020-Nov-15 14:52:03] [ info] --------------------------------------------------------------------------------
    [2020-Nov-15 14:52:03] [ info] C:\Program Files\Nordic Semiconductor\nrf-command-line-tools\bin\nrfjprog.exe --coprocessor CP_NETWORK --recover --log NETWORK_2.log 
    [2020-Nov-15 14:52:03] [ info] nrfjprog version 10.11.1 
    [2020-Nov-15 14:52:03] [ info] --------------------------------------------------------------------------------
    [2020-Nov-15 14:52:03] [debug] [ nRF0x0] - open_dll
    [2020-Nov-15 14:52:03] [ info] [ nRF0x0] - Load library at C:\Program Files\Nordic Semiconductor\nrf-command-line-tools\bin\JLINKARM_UNKNOWN_NRFJPROG.dll.
    [2020-Nov-15 14:52:03] [ info] [ nRF0x0] - Library loaded, loading member functions.
    [2020-Nov-15 14:52:03] [ info] [ nRF0x0] - Member functions succesfully loaded.
    [2020-Nov-15 14:52:03] [ info] [Backend] - Logger callback at 0x7ff70efa4b40 registered in Segger backend logger.
    [2020-Nov-15 14:52:03] [ info] [  JLink] - [Debug   ] [JLink     ] Logger callback at 0x7ff70efa4b40 registered in JLink logger.
    [2020-Nov-15 14:52:03] [debug] [nRFUnknown] - Just_open_dll_tagged_callback
    [2020-Nov-15 14:52:03] [debug] [Backend] - open_dll
    [2020-Nov-15 14:52:03] [ info] [Backend] - No J-Link DLL path was provided. Attempting to auto detect.
    [2020-Nov-15 14:52:03] [ info] [Backend] - Load library at C:\Program Files (x86)\SEGGER\JLink\JLink_x64.dll.
    [2020-Nov-15 14:52:03] [ info] [Backend] - Library loaded, loading member functions.
    [2020-Nov-15 14:52:03] [ info] [Backend] - Member functions succesfully loaded.
    [2020-Nov-15 14:52:03] [debug] [Backend] - dll_version
    [2020-Nov-15 14:52:03] [ info] [Backend] - Segger dll version 6.86.f loaded.
    [2020-Nov-15 14:52:03] [debug] [Backend] - set_core_data
    [2020-Nov-15 14:52:03] [debug] [ nRF0x0] - enum_emu_snr
    [2020-Nov-15 14:52:03] [debug] [nRFUnknown] - Just_enum_emu_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - enum_emu_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_enum_emu_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_get_num_emus
    [2020-Nov-15 14:52:03] [debug] [ nRF0x0] - connect_to_emu_with_snr
    [2020-Nov-15 14:52:03] [debug] [nRFUnknown] - Just_connect_to_emu_with_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - connect_to_emu_with_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_enum_emu_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_get_num_emus
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_connect_to_emu_with_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_connect_to_emu_without_snr
    [2020-Nov-15 14:52:03] [ info] [Backend] - Segger logging enabled.
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_load_core_data
    [2020-Nov-15 14:52:03] [ info] [  JLink] - [Debug   ] [JLink     ] Device "CORTEX-M4" selected.
    [2020-Nov-15 14:52:03] [debug] [ nRF0x0] - read_connected_emu_snr
    [2020-Nov-15 14:52:03] [debug] [nRFUnknown] - Just_read_connected_emu_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - read_connected_emu_snr
    [2020-Nov-15 14:52:03] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:52:03] [debug] [ nRF0x0] - read_device_family
    [2020-Nov-15 14:52:03] [debug] [nRFUnknown] - Just_read_device_family
    [2020-Nov-15 14:52:03] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:52:03] [debug] [Backend] - read_debug_port_idr
    [2020-Nov-15 14:52:03] [debug] [Backend] - read_debug_port_register
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_read_debug_port_register
    [2020-Nov-15 14:52:03] [debug] [Backend] - coresight_configure
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_select_debug_port_register
    [2020-Nov-15 14:52:03] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2020-Nov-15 14:52:03] [error] [  JLink] - [Debug   ] [JLink     ] Not supported by current CPU + target interface combination.
    [2020-Nov-15 14:52:03] [ info] [Backend] - JLinkARM.dll reported "-2", an unknown error.
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_abort_debug_action
    [2020-Nov-15 14:52:03] [ info] [Backend] - Attempting to clear any configuration errors in debug port before closing connection. 
    [2020-Nov-15 14:52:03] [debug] [ nRF0x0] - close_dll
    [2020-Nov-15 14:52:03] [debug] [nRFUnknown] - Just_close_dll
    [2020-Nov-15 14:52:03] [debug] [Backend] - close
    [2020-Nov-15 14:52:03] [debug] [Backend] - disconnect_from_emu
    [2020-Nov-15 14:52:03] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_disconnect_from_emu
    [2020-Nov-15 14:52:03] [debug] [Backend] - is_connected_to_device
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_is_debug_region_powered
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_read_debug_port_register
    [2020-Nov-15 14:52:03] [debug] [Backend] - is_connected_to_emu
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_select_debug_port_register
    [2020-Nov-15 14:52:03] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2020-Nov-15 14:52:03] [error] [  JLink] - [Debug   ] [JLink     ] Not supported by current CPU + target interface combination.
    [2020-Nov-15 14:52:03] [ info] [Backend] - JLinkARM.dll reported "-2", an unknown error.
    [2020-Nov-15 14:52:03] [debug] [Backend] - ---just_abort_debug_action
    [2020-Nov-15 14:52:03] [ info] [Backend] - Attempting to clear any configuration errors in debug port before closing connection. 
    [2020-Nov-15 14:52:03] [debug] [Backend] - Segger Backend closed.
    

    Also, this was printed out on the command line for both commands:

    ERROR: nrfjprog could not identify the target device. This may be due to an
    ERROR: invalid family argument, a problem with your device, or nrfjprog may
    ERROR: not yet support your device.
    ERROR: Please check the family argument passed, or upgrade nrfjprog to a more
    ERROR: recent version.

    At this point, I think the chip is dead.

Related