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

Error with nrf52DK and mac OS HS

Hello I'm using a macbookPro 2016 which only has usb-c and I can only connect the dk through a usb hub.

I have already installed the nrf5x-Command Line Tools for OSX but when I make the command nrfjprog --recover --log it gives me the error of:

BUG: 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.

Here is the generated log, can you help me? Thank you

--------------------------------------------------------------------------------
/Users/navarrocantero/Downloads/nRF5x-Command-Line-Tools_9_7_3_OSX/nrfjprog/nrfjprog --recover --log
nrfjprog version 9.7.3
--------------------------------------------------------------------------------
nRF_open_dll
. nRFXX_open_dll
. . nRFXX_dll_version
nRF_enum_emu_snr
. nRFXX_enum_emu_snr
nRF_enum_emu_snr
. nRFXX_enum_emu_snr
nRF_connect_to_emu_with_snr
. nRFXX_connect_to_emu_with_snr
. . nRFXX_is_connected_to_emu
. . nRFXX_connect_to_emu_without_snr
. . . nRFXX_is_connected_to_emu
. . . nRFXX_enum_emu_snr
. . nRFXX_connect_to_emu_without_snr: JLink: Firmware: J-Link OB-SAM3U128-V2-NordicSemi compiled Jan 12 2018 16:05:20
. . nRFXX_connect_to_emu_without_snr: JLink: Hardware: V1.00
. . nRFXX_connect_to_emu_without_snr: JLink: S/N: 682438930
. . nRFXX_connect_to_emu_without_snr: JLink: TELNET listener socket opened on port 19021
. . nRFXX_connect_to_emu_without_snr: JLink: WEBSRV Starting webserver
. . nRFXX_connect_to_emu_without_snr: JLink: (0017ms, 0021ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:006
. . nRFXX_connect_to_emu_without_snr: JLink: WEBSRV Webserver running on local port 19080
. . nRFXX_connect_to_emu_without_snr: JLink: (0017ms, 0021ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:006
. . nRFXX_connect_to_emu_without_snr: JLink: returns O.K.
. . nRFXX_connect_to_emu_without_snr: JLink: (0018ms, 0022ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:024
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_GetHWStatus(...)
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x00
. . nRFXX_connect_to_emu_without_snr: JLink: (0002ms, 0024ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:026
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("Device = NRF52832_xxAA", ...).
. . nRFXX_connect_to_emu_without_snr: JLink: XML file found at: /Applications/SEGGER/JLink/JLinkDevices.xml
. . nRFXX_connect_to_emu_without_snr: JLink: (0231ms, 0256ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:027
. . nRFXX_connect_to_emu_without_snr: JLink: /Applications/SEGGER/JLink/JLinkDevices.xml evaluated successfully.
. . nRFXX_connect_to_emu_without_snr: JLink: Device "NRF52832_XXAA" selected.
. . nRFXX_connect_to_emu_without_snr: JLink: Device "NRF52832_XXAA" selected.
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x00
. . nRFXX_connect_to_emu_without_snr: JLink: (0265ms, 0290ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:292
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("SetRestartOnClose = 0", ...).
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x01
. . nRFXX_connect_to_emu_without_snr: JLink: (0001ms, 0291ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:293
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("DisableFlashDL", ...).
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x00
. . nRFXX_connect_to_emu_without_snr: JLink: (0000ms, 0291ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:293
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("SetDbgPowerDownOnClose = 1", ...).
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x01
. . nRFXX_connect_to_emu_without_snr: JLink: (0000ms, 0291ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:293
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("ExcludeFlashCacheRange 0x0-0xFFFFFFFF", ...).
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x00
. . nRFXX_connect_to_emu_without_snr: JLink: (0000ms, 0292ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:294
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_TIF_Select(JLINKARM_TIF_SWD)
. . nRFXX_connect_to_emu_without_snr: JLink: returns 0x00
. . nRFXX_connect_to_emu_without_snr: JLink: (0003ms, 0295ms total)
. . nRFXX_connect_to_emu_without_snr: JLink: T93684380 000:298
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_SetSpeed(2000)
. . nRFXX_connect_to_emu_without_snr: JLink: (0000ms, 0296ms total)
nRF_read_connected_emu_snr
. nRFXX_read_connected_emu_snr
. . nRFXX_is_connected_to_emu
. . nRFXX_is_connected_to_emu: JLink: T93684380 000:299
. . nRFXX_is_connected_to_emu: JLink: JLINK_IsOpen()
. . nRFXX_is_connected_to_emu: JLink: returns 0x01
. . nRFXX_is_connected_to_emu: JLink: (0000ms, 0296ms total)
nRF_read_device_family
. nRFXX_read_device_family
. . nRFXX_is_connected_to_emu
. . nRFXX_is_connected_to_emu: JLink: T93684380 000:299
. . nRFXX_is_connected_to_emu: JLink: JLINK_IsOpen()
. . nRFXX_is_connected_to_emu: JLink: returns 0x01
. . nRFXX_is_connected_to_emu: JLink: (0000ms, 0296ms total)
. . nRFXX_read_access_port_register
. . . nRFXX_coresight_configure
. . . nRFXX_coresight_configure: JLink: T93684380 000:300
. . . nRFXX_coresight_configure: JLink: JLINK_CORESIGHT_Configure()
. . . nRFXX_coresight_configure: JLink: returns 0
. . . nRFXX_coresight_configure: JLink: (0102ms, 0398ms total)
. . . nRFXX_power_debug_and_system_regions
. . . . nRFXX_write_debug_port_register
. . . . nRFXX_write_debug_port_register: JLink: T93684380 000:403
. . . . nRFXX_write_debug_port_register: JLink: JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)
. . . . nRFXX_write_debug_port_register: JLink: returns -1
. . . . nRFXX_write_debug_port_register: JLink: (0001ms, 0400ms total)
. . . . nRFXX_write_debug_port_register: JLinkARM.dll CORESIGHT_WriteAPDPReg returned error -1.

. . . nRFXX_power_debug_and_system_regions: JLinkARM.dll CORESIGHT_WriteAPDPReg returned error -102.

nRF_close_dll
. nRFXX_close_dll
. . nRFXX_is_connected_to_emu
. . nRFXX_is_connected_to_emu: JLink: T93684380 000:405
. . nRFXX_is_connected_to_emu: JLink: JLINK_IsOpen()
. . nRFXX_is_connected_to_emu: JLink: returns 0x01
. . nRFXX_is_connected_to_emu: JLink: (0000ms, 0400ms total)
. . nRFXX_disconnect_from_emu
. . nRFXX_disconnect_from_emu: JLink: T93684380 000:414
. . nRFXX_disconnect_from_emu: JLink: JLINK_Close()

  • Tested, and again the same result :( 

    I have alredy tested in three diferents computers, precisely for that, to narrow the error. 

    Can the nrf58323 be broken or blocked? In that case, how could you prove it convincingly?

    Thanks again !

  • Could you try this last thing?

    could you do the following and attach both the resulting nRFJProg and Segger log files?

    1. Open J-Link Commander.
    2. Right click the small green J-Link icon in the task bar and press Open.
    3. Under Settings->Log File, tick the "Override" box, and specify a log file path for the Segger log.
    4. Close Control Panel, but leave J-Link Commander open.
    5. Run nrfjprog -f NRF52 --recover --log

    After you're finished, you may want to the log file setting as Segger will remember it between sessions. This can be done by removing the "Override" check mark. in the Control panel.

  • Here are the both logs Martin : 

    J-link commander : 


    SEGGER J-Link V6.32d Log File
    DLL Compiled: May 25 2018 17:03:12
    Logging started @ 2018-06-08 08:41

    T15A4 000:000 JLINK_GetDLLVersion() returns 63204 (0001ms, 0001ms total)
    T15A4 000:001 JLINK_EMU_GetNumDevices() returns 0x01 (0003ms, 0004ms total)
    T15A4 000:006 JLINK_EMU_GetNumDevices() returns 0x01 (0000ms, 0004ms total)
    T15A4 000:006 JLINK_EMU_GetList(InterfaceMask = 0x00000001, MaxInfos = 0x00000001) [0]: USB, S/N: 682438930 returns 0x01 (0003ms, 0007ms total)
    T15A4 000:010 JLINK_IsOpen() returns 0x00 (0000ms, 0007ms total)
    T15A4 000:011 JLINK_EMU_GetNumDevices() returns 0x01 (0001ms, 0008ms total)
    T15A4 000:012 JLINK_EMU_SelectByUSBSN(SerialNo = 682438930) returns 0x00 (0003ms, 0011ms total)
    T15A4 000:015 JLINK_OpenEx(...)
    Firmware: J-Link OB-SAM3U128-V2-NordicSemi compiled Jan 12 2018 16:05:20
    Hardware: V1.00
    S/N: 682438930
    TELNET listener socket opened on port 19021WEBSRV
    Starting webserver (0023ms, 0034ms total)
    T15A4 000:015 WEBSRV Webserver running on local port 19081 (0023ms, 0034ms total)
    T15A4 000:015 returns O.K. (0023ms, 0034ms total)
    T15A4 000:039 JLINK_GetHWStatus(...) returns 0x00 (0004ms, 0038ms total)
    T15A4 000:044 JLINK_ExecCommand("Device = NRF52832_xxAA", ...). XML file found at: C:\Program Files (x86)\SEGGER\JLink_V632d\JLinkDevices.xml (0131ms, 0170ms total)
    T15A4 000:044 C:\Program Files (x86)\SEGGER\JLink_V632d\JLinkDevices.xml evaluated successfully.Device "NRF52832_XXAA" selected. returns 0x00 (0182ms, 0221ms total)
    T15A4 000:226 JLINK_ExecCommand("SetRestartOnClose = 0", ...). returns 0x01 (0000ms, 0222ms total)
    T15A4 000:227 JLINK_ExecCommand("DisableFlashDL", ...). returns 0x00 (0001ms, 0223ms total)
    T15A4 000:228 JLINK_ExecCommand("SetDbgPowerDownOnClose = 1", ...). returns 0x01 (0000ms, 0223ms total)
    T15A4 000:229 JLINK_ExecCommand("ExcludeFlashCacheRange 0x0-0xFFFFFFFF", ...). returns 0x00 (0000ms, 0224ms total)
    T15A4 000:229 JLINK_TIF_Select(JLINKARM_TIF_SWD) returns 0x00 (0004ms, 0228ms total)
    T15A4 000:234 JLINK_SetSpeed(2000) (0001ms, 0230ms total)
    T15A4 000:241 JLINK_IsOpen() returns 0x01 (0000ms, 0230ms total)
    T15A4 000:242 JLINK_IsConnected() returns FALSE (0000ms, 0230ms total)
    T15A4 000:242 JLINK_CORESIGHT_Configure() returns 0 (0103ms, 0333ms total)
    T15A4 000:346 JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000) returns -1 (0003ms, 0336ms total)
    T15A4 000:349 JLINK_IsOpen() returns 0x01 (0002ms, 0338ms total)
    T15A4 000:351 JLINK_IsConnected() returns FALSE (0000ms, 0338ms total)
    T15A4 000:364 JLINK_Close() (0005ms, 0343ms total)
    T15A4 000:364 (0007ms, 0345ms total)
    T15A4 000:364 Closed (0007ms, 0345ms total)

    And here the nrfjprog -f NRF52 --recover log :

    C:\Program Files (x86)\Nordic Semiconductor\nrf5x\bin\nrfjprog.exe -f NRF52 --recover --log
    nrfjprog version 9.7.3
    --------------------------------------------------------------------------------
    nRF_open_dll
    . nRF52_open_dll
    . . nRF52_dll_version
    nRF_enum_emu_snr
    . nRF52_enum_emu_snr
    . . nRF52_enum_emu_snr
    nRF_enum_emu_snr
    . nRF52_enum_emu_snr
    . . nRF52_enum_emu_snr
    nRF_connect_to_emu_with_snr
    . nRF52_connect_to_emu_with_snr
    . . nRF52_is_connected_to_emu
    . . nRF52_enum_emu_snr
    . . nRF52_connect_to_emu_with_snr
    . . . nRF52_connect_to_emu_without_snr
    . . . nRF52_connect_to_emu_without_snr: JLink: Firmware: J-Link OB-SAM3U128-V2-NordicSemi compiled Jan 12 2018 16:05:20
    . . . nRF52_connect_to_emu_without_snr: JLink: Hardware: V1.00
    . . . nRF52_connect_to_emu_without_snr: JLink: S/N: 682438930
    . . . nRF52_connect_to_emu_without_snr: JLink: TELNET listener socket opened on port 19021
    . . . nRF52_connect_to_emu_without_snr: JLink: WEBSRV Starting webserver
    . . . nRF52_connect_to_emu_without_snr: JLink: (0026ms, 0038ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: WEBSRV Webserver running on local port 19081
    . . . nRF52_connect_to_emu_without_snr: JLink: (0026ms, 0038ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: returns O.K.
    . . . nRF52_connect_to_emu_without_snr: JLink: (0027ms, 0039ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_GetHWStatus(...)
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x00
    . . . nRF52_connect_to_emu_without_snr: JLink: (0003ms, 0042ms total)
    . . . nRF52_connect_to_emu_without_snr: There is no generic nRF52 device in J-Link, so we select NRF52832_xxAA.

    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("Device = NRF52832_xxAA", ...).
    . . . nRF52_connect_to_emu_without_snr: JLink: XML file found at: C:\Program Files (x86)\SEGGER\JLink_V632d\JLinkDevices.xml
    . . . nRF52_connect_to_emu_without_snr: JLink: (0149ms, 0192ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: C:\Program Files (x86)\SEGGER\JLink_V632d\JLinkDevices.xml evaluated successfully.
    . . . nRF52_connect_to_emu_without_snr: JLink: Device "NRF52832_XXAA" selected.
    . . . nRF52_connect_to_emu_without_snr: JLink: Device "NRF52832_XXAA" selected.
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x00
    . . . nRF52_connect_to_emu_without_snr: JLink: (0200ms, 0243ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("SetRestartOnClose = 0", ...).
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x01
    . . . nRF52_connect_to_emu_without_snr: JLink: (0001ms, 0244ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("DisableFlashDL", ...).
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x00
    . . . nRF52_connect_to_emu_without_snr: JLink: (0000ms, 0244ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("SetDbgPowerDownOnClose = 1", ...).
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x01
    . . . nRF52_connect_to_emu_without_snr: JLink: (0001ms, 0245ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("ExcludeFlashCacheRange 0x0-0xFFFFFFFF", ...).
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x00
    . . . nRF52_connect_to_emu_without_snr: JLink: (0000ms, 0245ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_TIF_Select(JLINKARM_TIF_SWD)
    . . . nRF52_connect_to_emu_without_snr: JLink: returns 0x00
    . . . nRF52_connect_to_emu_without_snr: JLink: (0003ms, 0249ms total)
    . . . nRF52_connect_to_emu_without_snr: JLink: JLINK_SetSpeed(2000)
    . . . nRF52_connect_to_emu_without_snr: JLink: (0000ms, 0251ms total)
    nRF_recover

    . nRF52_recover
    . . nRF52_is_connected_to_emu
    . . nRF52_is_connected_to_emu: JLink: JLINK_IsOpen()
    . . nRF52_is_connected_to_emu: JLink: returns 0x01
    . . nRF52_is_connected_to_emu: JLink: (0001ms, 0252ms total)
    . . nRF52_is_connected_to_device
    . . nRF52_is_connected_to_device: JLink: JLINK_IsConnected()
    . . nRF52_is_connected_to_device: JLink: returns FALSE
    . . nRF52_is_connected_to_device: JLink: (0001ms, 0253ms total)
    . . nRF52_readback_status
    . . . nRF52_is_ctrl_ap_available
    . . . . nRF52_read_access_port_register
    . . . . . nRF52_coresight_configure
    . . . . . nRF52_coresight_configure: JLink: JLINK_CORESIGHT_Configure()
    . . . . . nRF52_coresight_configure: JLink: returns 0
    . . . . . nRF52_coresight_configure: JLink: (0104ms, 0357ms total)
    . . . . . nRF52_power_debug_and_system_regions
    . . . . . . nRF52_write_debug_port_register
    . . . . . . nRF52_write_debug_port_register: JLink: JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)
    . . . . . . nRF52_write_debug_port_register: JLink: returns -1
    . . . . . . nRF52_write_debug_port_register: JLink: (0002ms, 0360ms total)
    . . . . . . nRF52_write_debug_port_register: JLinkARM.dll CORESIGHT_WriteAPDPReg returned error -1.

    . . . . . nRF52_power_debug_and_system_regions: JLinkARM.dll CORESIGHT_WriteAPDPReg returned error -102.

    nRF_close_dll
    . nRF52_close_dll
    . . nRF52_is_connected_to_emu
    . . nRF52_is_connected_to_emu: JLink: JLINK_IsOpen()
    . . nRF52_is_connected_to_emu: JLink: returns 0x01
    . . nRF52_is_connected_to_emu: JLink: (0001ms, 0361ms total)
    . . nRF52_disconnect_from_emu
    . . . nRF52_is_connected_to_device
    . . . nRF52_is_connected_to_device: JLink: JLINK_IsConnected()
    . . . nRF52_is_connected_to_device: JLink: returns FALSE
    . . . nRF52_is_connected_to_device: JLink: (0001ms, 0362ms total)
    . . . nRF52_unpower_debug_and_system_regions
    . . nRF52_disconnect_from_emu: JLink: JLINK_Close()

  • From your logs it basically looks like the board is not connected.

    - How do you supply the board? (in similar cases the board has been powered from a battery)

    - What card is it? (information on the sticker)

    Do you know if it already has FW on it?

  • Yes, the behavior of the board is as if it were not connected.

    I feed it using usb, as I said in a macbook pro with a usb hub but I have also tested in two other computers directly to the usb port and it is the same behavior.

    The board is a PCA10040 V1.1.0 of 2016.16

    The FW does not know what it takes, I only know that the bootloader is updated to the latest version.


    Some time ago the nrf current measurement pins failed me and I had to solder them, can that be something to do?

    thank you very much !

Related