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

nRF52382 not connect to j-link(EDU)

I have connecting problem.

My setting...

1. OS : win10 x64

    emulator : J-link(EDU)

2. installed

    1) nRF5x-Command-Line-Tools_9_7_3_Installer.exe

    2) nrfgostudio_win-64_1.21.2_installer.msi

    3) J-Link driver(6.32d) , I already tried 6.22g.

3. Test board : "nRF52832 Bluefruit feather"

    link : https://cdn-learn.adafruit.com/downloads/pdf/bluefruit-nrf52-feather-learning-guide.pdf

4. J-Link command message

====================================================================================================

SEGGER J-Link Commander V6.32d (Compiled May 25 2018 17:03:32)
DLL version V6.32d, compiled May 25 2018 17:03:12

Connecting to J-Link via USB...O.K.
Firmware: J-Link V10 compiled Apr 20 2018 16:47:09
Hardware version: V10.10
S/N: 2--------
License(s): FlashBP, GDB
OEM: SEGGER-EDU
VTref=3.339V


Type "connect" to establish a target connection, '?' for help
J-Link>connect
Please specify device / core. <Default>: NRF52832_XXAA
Type '?' for selection dialog
Device>
Please specify target interface:
  J) JTAG (Default)
  S) SWD
TIF>S
Specify target interface speed [kHz]. <Default>: 4000 kHz
Speed>10
Device "NRF52832_XXAA" selected.


Connecting to target via SWD
Cannot connect to target.
J-Link>

====================================================================================================

5. .log file of "nrfjprog.exe"

====================================================================================================

--------------------------------------------------------------------------------
nrfjprog -e -f nrf52 --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 V10 compiled Apr 20 2018 16:47:09
. . . nRF52_connect_to_emu_without_snr: JLink:  Hardware: V10.10
. . . nRF52_connect_to_emu_without_snr: JLink:  S/N: 2--------
. . . nRF52_connect_to_emu_without_snr: JLink:  OEM: SEGGER-EDU
. . . nRF52_connect_to_emu_without_snr: JLink:  Feature(s): FlashBP, GDB
. . . 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:  (0038ms, 0047ms total) 
. . . nRF52_connect_to_emu_without_snr: JLink: WEBSRV Webserver running on local port 19080
. . . nRF52_connect_to_emu_without_snr: JLink:  (0045ms, 0054ms total) 
. . . nRF52_connect_to_emu_without_snr: JLink:   returns O.K.
. . . nRF52_connect_to_emu_without_snr: JLink:  (0053ms, 0062ms 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:  (0008ms, 0075ms 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:  (0103ms, 0193ms 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:  (0169ms, 0259ms 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:  (0004ms, 0270ms 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:  (0004ms, 0281ms 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:  (0003ms, 0290ms 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:  (0003ms, 0299ms 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:  (0007ms, 0309ms total) 
. . . nRF52_connect_to_emu_without_snr: JLink: JLINK_SetSpeed(2000)
. . . nRF52_connect_to_emu_without_snr: JLink:  (0003ms, 0316ms total) 
nRF_read_device_version
. nRF52_read_device_version
. . 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:  (0012ms, 0331ms 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:  (0007ms, 0341ms 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:  (0117ms, 0461ms 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:  (0007ms, 0479ms 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:  (0007ms, 0490ms 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:  (0006ms, 0499ms total) 
. . . nRF52_unpower_debug_and_system_regions
. . nRF52_disconnect_from_emu: JLink: JLINK_Close()
--------------------------------------------------------------------------------
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 V10 compiled Apr 20 2018 16:47:09
. . nRFXX_connect_to_emu_without_snr: JLink:  Hardware: V10.10
. . nRFXX_connect_to_emu_without_snr: JLink:  S/N: 2--------
. . nRFXX_connect_to_emu_without_snr: JLink:  OEM: SEGGER-EDU
. . nRFXX_connect_to_emu_without_snr: JLink:  Feature(s): FlashBP, GDB
. . 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:  (0040ms, 0047ms total) 
. . nRFXX_connect_to_emu_without_snr: JLink: WEBSRV Webserver running on local port 19080
. . nRFXX_connect_to_emu_without_snr: JLink:  (0050ms, 0057ms total) 
. . nRFXX_connect_to_emu_without_snr: JLink:   returns O.K.
. . nRFXX_connect_to_emu_without_snr: JLink:  (0058ms, 0065ms total) 
. . 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:  (0007ms, 0076ms total) 
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_ExecCommand("Device = NRF52832_xxAA", ...).
. . nRFXX_connect_to_emu_without_snr: JLink: XML file found at: C:\Program Files (x86)\SEGGER\JLink_V632d\JLinkDevices.xml
. . nRFXX_connect_to_emu_without_snr: JLink:  (0105ms, 0188ms total) 
. . nRFXX_connect_to_emu_without_snr: JLink: C:\Program Files (x86)\SEGGER\JLink_V632d\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:  (0171ms, 0254ms total) 
. . 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:  (0004ms, 0266ms total) 
. . 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:  (0004ms, 0278ms total) 
. . 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:  (0003ms, 0287ms total) 
. . 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:  (0003ms, 0296ms total) 
. . 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:  (0007ms, 0307ms total) 
. . nRFXX_connect_to_emu_without_snr: JLink: JLINK_SetSpeed(2000)
. . nRFXX_connect_to_emu_without_snr: JLink:  (0003ms, 0314ms total) 
nRF_read_connected_emu_snr
. nRFXX_read_connected_emu_snr
. . nRFXX_is_connected_to_emu
. . nRFXX_is_connected_to_emu: JLink: JLINK_IsOpen()
. . nRFXX_is_connected_to_emu: JLink:   returns 0x01
. . nRFXX_is_connected_to_emu: JLink:  (0007ms, 0325ms total) 
nRF_read_device_family
. nRFXX_read_device_family
. . nRFXX_is_connected_to_emu
. . nRFXX_is_connected_to_emu: JLink: JLINK_IsOpen()
. . nRFXX_is_connected_to_emu: JLink:   returns 0x01
. . nRFXX_is_connected_to_emu: JLink:  (0006ms, 0335ms total) 
. . nRFXX_read_access_port_register
. . . nRFXX_coresight_configure
. . . nRFXX_coresight_configure: JLink: JLINK_CORESIGHT_Configure()
. . . nRFXX_coresight_configure: JLink:   returns 0
. . . nRFXX_coresight_configure: JLink:  (0116ms, 0454ms total) 
. . . nRFXX_power_debug_and_system_regions
. . . . nRFXX_write_debug_port_register
. . . . 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:  (0016ms, 0481ms 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: JLINK_IsOpen()
. . nRFXX_is_connected_to_emu: JLink:   returns 0x01
. . nRFXX_is_connected_to_emu: JLink:  (0007ms, 0492ms total) 
. . nRFXX_disconnect_from_emu
. . nRFXX_disconnect_from_emu: JLink: JLINK_Close()

===================================================================================================

5. My cortex-M3 board connected to same J-link(SWD), but nrf52382 not connect.

6. Also, my other laptop same.

Please advise. Thanks!

  • Hi,

     

    Are you using the 2x5 pin header on the feather-board to connect your debugger or are you connecting the debugger in another way?

    VDD seems to be sampled correctly (~3.3V), so your board is powered within a valid level for both debugger and nRF. Do you have a picture of your setup?

     

    Best regards,

    Håkon

  • Hi, Håkon

    1. I use 2x5 pin header on theh feather-board.

       Also I tried connection with jumper cable(http://warefab.com/product/53/)

      J-Link Edu --- feather-board

         1 - VTarget --- Vcc

         4 - GND --- GND

         7 - TMS --- SWDIO

         9 - TCK --- SWCLK

    2. this is a picture of my setup

    Thanks

    kic84

  • Hi,

     

    Thanks for the picture of the setup. Everything looks connected correctly.

    Have you at some point been able to program this board? 

    Do you have other boards that behave equally?

    By looking at the logs, both JLinkCommander and nrfjprog is not able to contact the nRF.

     

    Best regards,

    Håkon

  • Hi, Håkon

    Thanks for your Replys.

    1. I have not ever been success to connect nRF52 and j-link.

        Thus, I have not ever program to these boards.

         but feader-board is normal.

         beacause I did scan BLE-signal using my smart-phone when the feader-board be turn on.

    2. I have one more "feader-board", but it's same state.

        thus I did order "nRF52-DK" last week.

    I do not find my mistake point.

    Also, I am considering to order j-link base version.

    But I am afraid that the problem will be solved.

    Because the price of J-link base version is very high....

    Thanks!!

    kic84

  • Hi,

     

    The JLink EDU shall be close to equal to the JLink Base, just with a more limited license targeted for education purposes only.

    I assume this board has been pre-programmed with an example application during the production stages. Even if readback protection has been enabled, you should be able to recover the board using "nrfjprog --recover".

    Unfortunately, I do not have a feather board, so I cannot check this, but this seems very strange. As long as the SWD header is present, your process should work without any issues.

     

    Have you tried this on another computer, in case there are some PC software related issues causing this behavior?

     

    Best regards,

    Håkon

Related