J-Link connection lost after a few seconds

I have been learning to use the nrf52840DK for some time now, though I would consider myself still a beginner. Anyway, something has gone wrong with the kit and I am not sure what. It does not seem to be able to connect with the J-link I've been always using.

Two days ago, I was able to connect it to my PC and download and debug code naturally. I was even able to use the J-Link EDU kit normally, with both the 19-pin and the 9-pin Cortex-M adaptors. Yesterday, I plugged the kit in my PC, as always through the USB. LED5 is on, as always, and the kit is recognized as a J-Link driver. I thought that everything was OK, but in SES, the connect J-Link command returned the "Failed to connect to target" error. The J-Link EDU kit's light was orange. Something has gone terribly wrong. I have tried resetting the kit and downloading the J-Link OB file in the Bootloader, but that does not change anything.

The first time I connected the DK to my PC today, it acted normally and I was even able to connect the J-Link, though LED2 and LED3 were on unexpectedly. I downloaded an example just to see that it works, and at first it worked. After a few seconds the kit was no longer available for J-Link connection in SES (although visible as a J-Link Driver in MyComputer) and the program had stopped its execution (the LEDs were blinking no more). After disconnecting and reconnecting the kit, LED5 is just on, but nothing changed. The downloaded program is not being executed and the J-Link connection is not possible.

Do you know how I could fix this issue?

Thank you in advance!

Parents
  • Hi there,

    If you use nRF Command Line Tools, and run:

    nrfjprog --ids

    Is the kit listed? If not, what error is returned by the program?


    Could run the command again with the log attached?

    nrfjprog --ids --log

    Can you share the log?

    Also, could you go through the steps listed in this thread and verify that none of the suggestions mitigated your issue?

    regards

    Jared

  • This is very strange. RESET should be pulled high, if it's low then the nRF52840 is kept in RESET state. Can you try to pull it high by connecting VDD to RESET and see if it "wakes up" the board.

    So, something pretty strange is going on. I am listing the voltage measurements I made:

    VDD-GND = 2.98V

    RESET-GND = 0

    VDD-RESET = 0 (I don't know how the last 3 can be possible at the same time)

    5V-GND=5.01V

    5V-RESET=1.61V (So reset is definitely at high)

    5V-VDD=2.01V

    All the above seem chaotic. I also tried to connect the VDD with RESET and nothing happened.

  • Hi,

    Maybe the pin RESET feature isn't activated in your project. In that case, the pin would just act as a normal GPIO, which would explain your measurements. 

    Have you modified any of the solder bridges on your DK and can you list the state of the following switches:

    • SW10
    • SW9
    • SW6
    • SW8
    Two days ago, I was able to connect it to my PC and download and debug code naturally. I was even able to use the J-Link EDU kit normally, with both the 19-pin and the 9-pin Cortex-M adaptors.

    Can you elaborate on this? Are you using a stand alone debugger? How have you connected the DK to your computer?

    regards

    Jared 

  • Hello again.

    SW10: OFF

    SW8: ON

    SW9: VDD

    SW6: DEFAULT

    I believe that reset is activated, since I can put the kit in bootloader mode with IF BOOT/RESET button.

    Can you elaborate on this? Are you using a stand alone debugger?

    Normally, I use the DK with a USB. Recently, I was provided with Segger's J-Link EDU module to check its debugging capabilities. Now the DK doesn't work either with the USB or with the module. There aren't any problems with the debug probe, since my other DK has worked perfectly with it. Could the problem have been caused by a forced PC reboot that happened while the DK was connected to the PC?

  • Hi,

    I'm not sure what is causing this. How have you supplied the board earlier? Was it always through the J2 USB header?

    If you want, I can take a look at your board if you want to send it to us.

    regards

    Jared 

  • Hey Jared!

    Thank you for all the help. Problem solved. I connected the DK to another PC and everything seems to work just fine now. I thought that the PC played no role in the matter, since my other DK worked just fine with the same PC.

    Anyway, thanks again,

    Kostas

Reply Children
  • Hi,

    kostathan said:
    Thank you for all the help. Problem solved. I connected the DK to another PC and everything seems to work just fine now. I thought that the PC played no role in the matter, since my other DK worked just fine with the same PC.

    I'm very happy that you were able to solve the problem, also note that testing on another computer is step 3 in the thread I shared earlier Slight smile

    I'll close this case then,

    Have a good weekend!

    regards

    Jared 

Related