[SOLVED] Can't connect to target CPU with J-Link EDU mini (Redboard Artemis)

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] Can't connect to target CPU with J-Link EDU mini (Redboard Artemis)

    Hi,

    First of all, I want to mention that this is my first experience with the J-link and hardware debugger in general.
    I’ve recently purchased a J-link Edu mini, and a Redboard Artemis from Sparkfun. I wanted to be able to debug the Redboard efficiently with the J-link but I’m not able to connect the J-link to the MCU (see the picture called log_debug.png). I've followed the instructions from this link without success.

    About the hardware there are several things that might be important to consider:
    - The Redboard works well since I'm able to upload and run code on it.
    - This link mentions that the problem could be "loose connecting wire". On my end, I'm using the official SWD cable that came out with the J-Link the two boards together is the official coming with the J-Link so it shouldn't be the source of the issue.
    - The Redboard only includes a SWD footprint. Thus, I needed to solder a SWD connector to the board, and since the header and the holes are super small, I am not 100% sure of my welding. I’ve attached several photos bellow of my welding. I know that two pins are welded together but these pins are GND so that’s why I’ve let it this way. I’ve also measured if there are any short-circuit between the pins with a multimeter and AS FAR AS I KNOW, there isn’t any.
    - Since I wasn’t sure about the wiring of the J-link with the MCU, I’ve followed the picture of this link that tells me that the first pin is VCC and that it is on the side where there is an gap in the connector. I’ve then assumed that the small “1” on the Redboard corresponds to this VCC pin as well as the J-Link debugger. You can see a picture bellow of my wiring.
    - I’m not using the official cable to connect the J-link with my computer since this one was too short. However, it doesn’t seem to be related to this issue since I am able to connect my computer to the J-Link.

    About the software configuration:
    - I was trying to debug with the J-Link commander (JLink.exe) but in every case I got the error message: “Cannot connect to target”. I also checked the log file generated by the J-link and there isn’t any extra information (see the JLinkLogOverride.log)
    - A pop-up window appeared when I opened the (JlinkGDBServer.exe) which lets me upgrade the firmware of the J-Link. So, I guess that the firmware version is the latest.
    - I’ve tried several configurations for the device parameter since I wasn’t sure which one to select but according to the Datasheet of the ReadBoard, the MCU belong to the Apollo3BlueSoC family which is known as “AMA3B1KK-KBR” or “AMA3B1KK-KCR” (segger.com/supported-devices/search/apollo3%20blue). I’ve tried both of them as well as the “Cortex-M4” but they all give me the same result. This link suggests that the correct device should be “AMA3B1KK-KBR”.
    - I’ve also tried to decrease the interface speed to 100KHz according to this link but it didn’t change anything.

    I am a bit out of idea, and I don’t own an oscilloscope to check the quality of the debug signals. Do you have any idea why this is happening ?
    Images
    • IMG_2032 2 - Grande.jpeg

      298.27 kB, 960×1,280, viewed 366 times
    • IMG_2032 4 - Grande.jpeg

      298.27 kB, 960×1,280, viewed 317 times
    • IMG_2033 2 - Grande.jpeg

      255.8 kB, 960×1,280, viewed 319 times
    • IMG_2036 2 - Grande.jpeg

      207.64 kB, 1,280×960, viewed 299 times
    • IMG_2037 2 - Grande.jpeg

      292.68 kB, 1,280×960, viewed 315 times
    • IMG_2038 2 - Grande.jpeg

      293.91 kB, 1,280×960, viewed 328 times
    • IMG_2039 2 - Grande.jpeg

      321.33 kB, 1,280×960, viewed 322 times
    • log_debug.png

      303.11 kB, 1,539×946, viewed 308 times
    • IMG_2051 - Grande.jpeg

      160.27 kB, 591×1,280, viewed 344 times
    Files

    The post was edited 1 time, last by EpiX ().

  • Hi,
    Thank you for the detailed post.

    1. To be perfectly honest, the solder job looks horrible, but if you verified that all pins connect correctly andthat there are no short circuits (except for the ones between GND pins), so be it.

    2. Regarding the flat cable: You say that it was delivered with the J-Link EDU correct?
    This is a sounds a little bit odd to me. As far as I know all flat cables we deliver with our products
    - are light grey
    - have one red wire which connects both pin 1.
    On the picture however, it looks like the cable is dark grey and does not have a red colored wire.
    To verify if the cable is broken or working, I would suggest to check the connection between the pins of the J-Link & the board,
    while the cable is plugged on both.

    3. Unfortunately, it is a little bit hard to see how the cable is connected to the board.
    But it looks like the nose is pointing to the top, so with pin1 on the right top side.
    According to the board pictures on the SparkFun website, this would be correct.

    It is hard to tell what exactly is going wrong here, but I would assume that the issue is caused by a faulty physical connection between J-Link & Board.We will order a sample of this board and create a wiki page explaining how to connect it to J-Link.
    I will notify you once the article is available.

    BR
    Fabian
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Update:
    The board arrived.
    We soldered a 10 pin connector on it and hooked up the J-Link.
    It did work out of the box on my side (see below).

    We are confident that this issue is related to your setup (soldering/cable/...)

    Source Code

    1. Connecting to target via SWD
    2. Found SW-DP with ID 0x2BA01477
    3. DPIDR: 0x2BA01477
    4. CoreSight SoC-400 or earlier
    5. Scanning AP map to find all available APs
    6. AP[1]: Stopped AP scan as end of AP map has been reached
    7. AP[0]: AHB-AP (IDR: 0x24770011)
    8. Iterating through AP map to find AHB-AP to use
    9. AP[0]: Core found
    10. AP[0]: AHB-AP ROM base: 0xE00FF000
    11. CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
    12. Found Cortex-M4 r0p1, Little endian.
    13. FPUnit: 6 code (BP) slots and 2 literal slots
    14. CoreSight components:
    15. ROMTbl[0] @ E00FF000
    16. [0][0]: E000E000 CID B105E00D PID 000BB00C SCS-M7
    17. [0][1]: E0001000 CID B105E00D PID 003BB002 DWT
    18. [0][2]: E0002000 CID B105E00D PID 002BB003 FPB
    19. [0][3]: E0000000 CID B105E00D PID 003BB001 ITM
    20. [0][4]: E0040000 CID B105900D PID 000BB9A1 TPIU
    21. Memory zones:
    22. Zone: "Default" Description: Default access mode
    23. Cortex-M4 identified.
    Display All
    BR
    Fabian
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.
  • Hi Fabian,

    Regarding the flat cables, there is indeed a red wire and to be fully honnest, I hadn't noticed it until you mentioned it. I don't know about the "light grey" though. Maybe the black background made it darker than it really is.

    I've followed your advice and looked for faulty physical connection between the board and the J-Link. Once the cable plugged inton the board and the J-link, I noticed that there was no connection between the two. The issue was related to the piece of plastic from the SWD connector which prevented the pins from being plugged deep enough into the flat cable. I just removed the piece of plastic and the J-link is now able to detect the board.

    Thanks for your help,
    Best regards,