SES 2.20, 3.10b on Linux cannot find attached J-Link device

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

  • SES 2.20, 3.10b on Linux cannot find attached J-Link device

    In a small classroom environment I am attempting to develop under Linux for the STM32F429 discovery board. I have 10 sets of equipment c/o a 32Gb SanDisk Cruzer Guide with a full install of Ubuntu 16.0.04 (so, NOT running as a Live CD), mini-USB cable, and STM32F429 Discovery Board. The ST-Link software on the STM32 has been replaced with the J-Link software. All of the flash drives are bit-level clones of a single source drive. On each drive, SES has been installed from the segger_embedded_studio_220_linux_x64 package and I have run the jlink_6.0.7_x86_64.deb USB driver install package (after the cloning). On eight of the drives, I can build a project and program the STM32 just fine. On the last two, I cannot select the attached STM32 as the target debugger under `J-Link Options-> Connection`, the drop-down menu is completely empty. If I manually add in the serial number of the attached STM32, I get a connection error. The dmesg output from attaching the board is:

    Source Code

    1. [ 2963.904902] usb 1-1.2: new full-speed USB device number 6 using ehci-pci
    2. [ 2963.976905] usb 1-1.2: device descriptor read/64, error -32
    3. [ 2964.156891] usb 1-1.2: device descriptor read/64, error -32
    4. [ 2964.332881] usb 1-1.2: new full-speed USB device number 7 using ehci-pci
    5. [ 2964.427711] usb 1-1.2: New USB device found, idVendor=1366, idProduct=0105
    6. [ 2964.427716] usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
    7. [ 2964.427728] usb 1-1.2: Product: J-Link
    8. [ 2964.427730] usb 1-1.2: Manufacturer: SEGGER
    9. [ 2964.427732] usb 1-1.2: SerialNumber: 000772488962
    10. [ 2964.428482] cdc_acm 1-1.2:1.0: ttyACM0: USB ACM device


    Note that if I run the separate JLinkExe utility from the command line, it says it can connect to the board (`Cortex M4 detected`). There is also some kind of issue with running the jlink_6.0.7_x86_64.deb driver, nearly every time after Ubuntu completes the install, the option button for the driver still says `Install` instead of changing to `Remove`, but despite this, the install appears to work since I can connect on these other machines. Since I have 10 sets that are managed as identically as humanly possible, I'm at a loss to explain why everything works except for 2 of the sets.

    EDIT: Although a USB error appears in the dmesg list, this same error happens on systems where everything is working. I have also tested with an actual J-Link device, and it still does not appear in the drop-down menu.

    The post was edited 5 times, last by Eqqman ().

  • Hi,

    Since all your environments should be identical, I would expect the same behavior on all of them.

    Did you try with an STM32 which has proved to be working on one of the other machines?
    What happens when you simply select "USB" without a serial number as the connection?

    Best regards
    Johannes
    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.
  • Hello-

    We were able to resolve the issue, so I am giving an update here to help future users.

    On systems where the device can't be detected on SES, the drop-down menu to select the J-Link is completely blank. You can manually type in `USB` or `USB0` into the selection box, but the device still won't connect. After a phone call with the Segger office in the U.S., I was able to track down the issue to the jlink_6.0.7_x86_64.deb driver. On our Ubuntu 16.0.04 systems, trying to run the driver takes you to a GUI interface that gives you a selection button labeled `Install` to try and load the driver. On some systems, after running the install, the button changes from `Install` to `Remove`, but on some systems, it could still say `Install`. In these cases, the J-Link may or may not be detected by SES. After experimentation I discovered that the J-Link device must be attached and powered in order for the USB driver to install correctly. This is in marked contrast to Windows-based systems where it is generally advised that the USB device NOT be attached while the driver is installed. I have no longer had these connection issues on machines where the driver installed with the J-Link attached, and incidentally, the SES interface lists the device as `USB0` in the drop-down instead of listing the serial number.