• 0
dry

JtagHs1 cable not detected by Digilent Linux driver

Question

Hello,

I got an old but good Digilent' Spartan-3 starter board, with the Hs1 JTAG calbe - all bought from Digilent at some stage.

I've installed latest ISE from Xilinx - ISE 14.7, Linux version. I also downloaded & installed latest Digilent cable drivers or plug-ins for the ISE to find JTAG and connect to the board. I see that it appears to get loaded correctly, and I get a trace in the log Digilent driver version xx.xxx loaded.

But, it's always says , no JTAG found !  I've spent hours, hours & hours trying to see why not, reinstalling drivers, examining udev hotplug rules, etc etc ..

The device is recognized by the Linux kernel as a USB dev, and sees it as the FTDI chip, and then triggers the ftdi_sio driver. Which is then looks like to trigger some digilent special app, which is called, but it's silent, no output, I have no idea if it succeeds. But there are two /dev/ttyUSBx devs that get created - is there any other chip that's suppose to be recognized there ?? I don't see anything but USB to Serial on this cable.

Another weird thing is, if I start & run the command line tool XMD from ISE (don't ask, I accidentally found it.. I 'm new to this), and , in it's shell, I ran this:

connect mb mdm

Then it prints a list of available devices which are actually on that board, device id and IDe code, and Part name - and the part names match what should be on that board...

So this tool somehow finds something connected on the cable, yet, that Digilent plug-in for the ISE always says no JTAG.

Digilent: please help ?

Share this post


Link to post
Share on other sites

19 answers to this question

Recommended Posts

  • 0

Hi @dry,

Welcome to the Digilent Forums. 

1) Please download the Adept 2

2) Use Adept 2 from the command line with the command "djtgcfg enum" . What is the terminal text response?

3) Here is the reference manual for the spartan 3. What mode is the Spartan 3 set to?

4) Here is the resource center for the Spartan 3

5) If Adept 2 can see the Spartan 3 please load the attached bit file to verify that the Spartan 3 is working.

best regards,

Jon

 

 

s3demo.bit

Share this post


Link to post
Share on other sites
  • 0
8 hours ago, jpeyron said:

Hi @dry,

Welcome to the Digilent Forums. 

..

Hello jpeyron,

Yes, forgot to mention that I did install the Adept2 already before posting. 

I've collected this for you:

From kernel log when cable plugged:

  613.777226] usb 1-1: new high-speed USB device number 2 using xhci_hcd
[  614.015915] usb 1-1: New USB device found, idVendor=0403, idProduct=6010, bcdDevice= 7.00
[  614.015918] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[  614.015920] usb 1-1: Product: Digilent Adept USB Device
[  614.015922] usb 1-1: Manufacturer: Digilent
[  614.015923] usb 1-1: SerialNumber: 210205333638
[  614.049606] usbcore: registered new interface driver ftdi_sio
[  614.049622] usbserial: USB Serial support registered for FTDI USB Serial Device
[  614.049646] ftdi_sio 1-1:1.0: FTDI USB Serial Device converter detected
[  614.049707] usb 1-1: Detected FT2232H
[  614.051292] usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB0
[  614.051358] ftdi_sio 1-1:1.1: FTDI USB Serial Device converter detected
[  614.051375] usb 1-1: Detected FT2232H
[  614.052516] usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB1

XMD:

 xmd
Xilinx Microprocessor Debugger (XMD) Engine
Xilinx EDK 14.7 Build EDK_P.20131013
Copyright (c) 1995-2012 Xilinx, Inc.  All rights reserved.

XMD% 
XMD% connect mb mdm

JTAG chain configuration
--------------------------------------------------
Device   ID Code        IR Length    Part Name
 1       01414093           6        XC3S200
 2       d5045093           8        XCF02S
ERROR: Could not detect MDM peripheral on hardware. Please check:
    1. If FPGA is configured correctly
    2. MDM Core is instantiated in the design
    3. If the correct FPGA is referred, in case of multiple FPGAs
    4. If the correct MDM is referred, in case of a multiple MDM system

XMD% 

As you can see I highlighted in red, those parts are what's on that board.

But, 

djtgcfg enum
No devices found

 

... why?

I addition, I don't trust that dftdrvdtch works  .  And, it is a silent app, which prints nothing, and seems accepts no flags, so I can't troubleshoot it.  The only thing as you see below, it seems fails to run:

Mar 20 14:25:17 esembbox systemd-udevd[1832]: Process '/usr/local/sbin/dftdrvdtch  ' failed with exit code 1.
Mar 20 14:25:17 esembbox systemd-udevd[1830]: Process '/usr/local/sbin/dftdrvdtch  ' failed with exit code 1.

 

If that's the cause of the issue, do you have a debug version which could be helpful to understand why  it's failing? 

 

Share this post


Link to post
Share on other sites
  • 0
Quote

3) Here is the reference manual for the spartan 3. What mode is the Spartan 3 set to?

Ok, thanks for that. So it was in all DEFAULT mode as shipped.  

I have tried switchting it to the JTAG / 1:0:1 mode, with no particular success. Still same thing. Except that the board has all  LEDs on steady instead of the numbers running on the 7sd.

Also,  I observe from the log that the cable connect/plug-in disconnect/plug-out is not always behaving the same. The initial log snipped you have above, that's fresh boot.

Then, I tried to connect/disconnect while connected to the board:

ar 20 14:48:28 esembbox kernel: usb 1-1: USB disconnect, device number 3
Mar 20 14:48:34 esembbox kernel: usb 1-1: new high-speed USB device number 4 using xhci_hcd
Mar 20 14:48:34 esembbox kernel: usb 1-1: New USB device found, idVendor=0403, idProduct=6010, bcdDevice= 7.00
Mar 20 14:48:34 esembbox kernel: usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Mar 20 14:48:34 esembbox kernel: usb 1-1: Product: Digilent Adept USB Device
Mar 20 14:48:34 esembbox kernel: usb 1-1: Manufacturer: Digilent
Mar 20 14:48:34 esembbox kernel: usb 1-1: SerialNumber: 210205333638
Mar 20 14:48:34 esembbox kernel: ftdi_sio 1-1:1.0: FTDI USB Serial Device converter detected
Mar 20 14:48:34 esembbox kernel: usb 1-1: Detected FT2232H
Mar 20 14:48:34 esembbox kernel: usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB0
Mar 20 14:48:34 esembbox kernel: ftdi_sio 1-1:1.1: FTDI USB Serial Device converter detected
Mar 20 14:48:34 esembbox kernel: usb 1-1: Detected FT2232H
Mar 20 14:48:34 esembbox kernel: usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB1
Mar 20 14:48:34 esembbox kernel: ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
Mar 20 14:48:34 esembbox kernel: ftdi_sio 1-1:1.0: device disconnected
Mar 20 14:48:34 esembbox kernel: ftdi_sio ttyUSB1: FTDI USB Serial Device converter now disconnected from ttyUSB1
Mar 20 14:48:34 esembbox kernel: ftdi_sio 1-1:1.1: device disconnected
Mar 20 14:48:34 esembbox systemd-udevd[2026]: Process '/usr/local/sbin/dftdrvdtch  ' failed with exit code 1.
Mar 20 14:48:34 esembbox systemd-udevd[2029]: Process '/usr/local/sbin/dftdrvdtch  ' failed with exit code 1.

 

It may seem that, your dftddrvtch did something - I don't know if it stands for Ditch FTD Driver? - did something, and on this attempt there is no more ttyUSBx devices that got created with the plugin.

However, no effect on the result - still no JTAG/ cable found.

After that, I have disconnected the cable from the board, and  un/plugged again, and got result which _may_ look different again:

Mar 20 14:49:28 esembbox kernel: usb 1-1: USB disconnect, device number 4
Mar 20 14:50:11 esembbox kernel: usb 1-1: new high-speed USB device number 5 using xhci_hcd
Mar 20 14:50:11 esembbox kernel: usb 1-1: New USB device found, idVendor=0403, idProduct=6010, bcdDevice= 7.00
Mar 20 14:50:11 esembbox kernel: usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Mar 20 14:50:11 esembbox kernel: usb 1-1: Product: USB <-> Serial Cable
Mar 20 14:50:11 esembbox kernel: usb 1-1: Manufacturer: FTDI
Mar 20 14:50:11 esembbox kernel: usb 1-1: SerialNumber: FTY6W40L
Mar 20 14:50:11 esembbox kernel: ftdi_sio 1-1:1.0: FTDI USB Serial Device converter detected
Mar 20 14:50:11 esembbox kernel: usb 1-1: Detected FT2232H
Mar 20 14:50:11 esembbox kernel: usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB0
Mar 20 14:50:11 esembbox kernel: ftdi_sio 1-1:1.1: FTDI USB Serial Device converter detected
Mar 20 14:50:11 esembbox kernel: usb 1-1: Detected FT2232H
Mar 20 14:50:11 esembbox kernel: usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB1

 

Note the serial number: I think its different from first initial after boot trace , where it was [  614.015922] usb 1-1: Manufacturer: Digilent
[  614.015923] usb 1-1: SerialNumber: 210205333638

So what is going on there....   

Help is much appreciated.

Share this post


Link to post
Share on other sites
  • 0
28 minutes ago, jpeyron said:

Hi @dry,

Are you using a Virtual box to run your linux OS? 

And to verify,  this version of the ISE 14.7 you are using.

thank you,

Jon

Hello Jon,

Yes ISE 14.7

Yes VirtualBox 5.2.xx

Share this post


Link to post
Share on other sites
  • 0

Hi @dry,

1) Just making sure you are not using the Window 10 updated ISE 14.7 here since it only works with Spartan 6 FPGA's.

2) Here is a link to USB basics and troubleshooting through Virtual Box that might be helpful as well. 

3) What is the main OS on your PC?

best regards,

Jon

Share this post


Link to post
Share on other sites
  • 0
Posted (edited)
28 minutes ago, jpeyron said:

Hi @dry,

1) Just making sure you are not using the Window 10 updated ISE 14.7 here since it only works with Spartan 6 FPGA's.

2) Here is a link to USB basics and troubleshooting through Virtual Box that might be helpful as well. 

3) What is the main OS on your PC?

best regards,

Jon

Hey Jon,

Well if I'm running it inside Linux, then I think it's safe to say it is not Windows 10 version?  Or is it mono type binaries.. ( not that I saw, it was all C++ apps & libraries).

No, so I 'm on 14.7 for Linux, x86_64 and, I did read that Spartan 3 is only supported upto 14.7 non Windows 10 versions. So I should be safe on that.

Main OS:  Windows 10 x86_64. 

Do you have a debug version of that udev triggered binary, which is suppose to do something after the Digilent HS1 USB is plugged in? What does it do?

Also,

Quote

2) Here is a link to USB basics and troubleshooting through Virtual Box that might be helpful as well. 

 

Thing is, I don't believe it's USB problem in VirtualBox, as, I have other JTAG units I forward to VBox with no problem.  Also, as you saw from my traces, the Hs1 cable is forwarded, and it is recognized as device, and the serial to usb controller.  Is there another controller that is not recognized?

Edited by dry

Share this post


Link to post
Share on other sites
  • 0

Hi @dry,

I'm not intending to take over this thread, but I'm hoping you could clarify which OS you were using. My confusion comes from this two statements:

12 minutes ago, dry said:

Well if I'm running it inside Linux, then I think it's safe to say it is not Windows 10 version?  Or is it mono type binaries.. ( not that I saw, it was all C++ apps & libraries).

 

13 minutes ago, dry said:

Main OS:  Windows 10 x86_64.

Which of those statements is accurate?

Thanks,
JColvin

Share this post


Link to post
Share on other sites
  • 0
4 minutes ago, JColvin said:

Hi @dry,

I'm not intending to take over this thread, but I'm hoping you could clarify which OS you were using. My confusion comes from this two statements:

 

Which of those statements is accurate?

Thanks,
JColvin

 

The virtual host is Windows 10. The virtual guest is Linux. The ISE 14.7 is a Linux version. Digilent drivers and Adept 2 used are thus also for Linux.

Share this post


Link to post
Share on other sites
  • 0

Hi @dry,

I am thinking this issue is with either ISE 14.7's configuration or the  configuration of the VB in regards to the USB.

To eliminate the Spartan 3 as a reason for these issues: 

1) Please download Adept 2 in you main OS (windows 10).

2) Does Adept 2 recognize the Spartan 3? 

3) Are you able to configure the Spartan 3 with the attached s3demo.bit file?

best regards,

Jon

s3demo.bit

Share this post


Link to post
Share on other sites
  • 0
10 minutes ago, jpeyron said:

Hi @dry,

2) Does Adept 2 recognize the Spartan 3? 

3) Are you able to configure the Spartan 3 with the attached s3demo.bit file?

s3demo.bit 127.95 kB · 0 downloads

 

Ok,  see pic attached.

Does this count as 'recognize the Spartan 3' ?

But please note: that is exactly same information ISE's x XMD tool prints for me inside Vbox's Linux i'm running, exactly same devices, IDs, and names.

So why does XMD see them, and not Digilent cable/driver ..?

Programming:  Yes I could upload your .bit file.

digi_spartan3.png

Share this post


Link to post
Share on other sites
  • 0

Ah ok, I think I'm mostly , found the issue:   I'm the 'monkey' .

A quick strace showed I haven't installed the libftd2 from ISE, that Digilent is looking for.

I hope for smooth sailing now .. lets see.

Share this post


Link to post
Share on other sites
  • 0

Ok, Now I'm having problems with programming the device from within ISE iMPACT.

See below log from iMPACT output. 

 

INFO:iMPACT - Digilent Plugin: Plugin Version: 2.5.2
INFO:iMPACT - Digilent Plugin: found 1 device(s).
INFO:iMPACT - Digilent Plugin: opening device: "JtagHs1", SN:210205333638
INFO:iMPACT - Digilent Plugin: User Name: JtagHs1
INFO:iMPACT - Digilent Plugin: Product Name: Digilent JTAG-HS1
INFO:iMPACT - Digilent Plugin: Serial Number: 210205333638
INFO:iMPACT - Digilent Plugin: Product ID: 30700150
INFO:iMPACT - Digilent Plugin: Firmware Version: 010A
INFO:iMPACT - Digilent Plugin: JTAG Port Number: 0
INFO:iMPACT - Digilent Plugin: JTAG Clock Frequency: 10000000 Hz
INFO:iMPACT - Digilent Plugin: Plugin Version: 2.5.2
INFO:iMPACT - Digilent Plugin: Opening device : "SN:210205333638".
INFO:iMPACT - Digilent Plugin: User Name: JtagHs1
INFO:iMPACT - Digilent Plugin: Product Name: Digilent JTAG-HS1
INFO:iMPACT - Digilent Plugin: Serial Number: 210205333638
INFO:iMPACT - Digilent Plugin: Product ID: 30700150
INFO:iMPACT - Digilent Plugin: Firmware Version: 010A
INFO:iMPACT - Digilent Plugin: JTAG Port Number: 0
INFO:iMPACT - Digilent Plugin: JTAG Clock Frequency: 10000000 Hz
Attempting to identify devices in the boundary-scan chain configuration...
INFO:iMPACT - Current time: 3/21/19 10:49 AM
PROGRESS_START - Starting Operation.
Identifying chain contents...'0': : Manufacturer's ID = Xilinx xcf02s, Version : 13
INFO:iMPACT:1777 - 
Reading /devel/xilinx/ise_ds_14_7/14.7/ISE_DS/ISE/xcf/data/xcf02s.bsd...
INFO:iMPACT:501 - '1': Added Device xcf02s successfully.
----------------------------------------------------------------------
----------------------------------------------------------------------
'1': : Manufacturer's ID = Xilinx xc3s200, Version : 0
INFO:iMPACT:1777 - 
Reading /home/esembdev/ISE/eecs_x4972/xc3s200.bsd...
INFO:iMPACT:501 - '1': Added Device xc3s200 successfully.
----------------------------------------------------------------------
----------------------------------------------------------------------
WARNING:iMPACT:1774 - Can't find such instruction IDCODE
INFO:iMPACT:2488 - The operation did not complete successfully.
PROGRESS_END - End Operation.
Elapsed time =      0 sec.
'1': Loading file '/media/sf_dloads/tmp/s3demo.bit' ...
done.
----------------------------------------------------------------------
INFO:iMPACT:501 - '1': Added Device xc3s200 successfully.
----------------------------------------------------------------------
----------------------------------------------------------------------
Setting Target Device to Mode:BS, Device position 0.
INFO:iMPACT - Current time: 3/21/19 10:50 AM
PROGRESS_START - Starting Operation.
Warning: Chain frequency (6000000) is less than the current cable speed (10000000).
 Adjust to cable speed (6000000).
Maximum TCK operating frequency for this device chain: 6000000.
Validating chain...
Boundary-scan chain validated successfully.
WARNING:iMPACT:1774 - Can't find such instruction CFG_IN
INFO:iMPACT:2488 - The operation did not complete successfully.
PROGRESS_END - End Operation.
Elapsed time =      0 sec.

 

I'm not sure if warnings are deadly, but  the end result it says,  The operation did not complete successfully :(

What am I doing wrong now ?

 

 

Screenshot from 2019-03-21 10-54-15.png

Share this post


Link to post
Share on other sites
  • 0

This works though ...

 

djtgcfg -d JtagHs1 -i 0 prog -f  /media/sf_dloads/tmp/s3demo.bit 
Programming device. Do not touch your board. This may take a few minutes...
Programming succeeded.
 

Share this post


Link to post
Share on other sites
  • 0

Hi @dry,

It looks like you need to adjust your cable speed for iMPACT to work. Here is a way to do it from the command line. Here is a forum thread that discusses how to do this in the GUI.

best regards,

Jon

Share this post


Link to post
Share on other sites
  • 0
On 3/22/2019 at 1:44 AM, jpeyron said:

Hi @dry,

It looks like you need to adjust your cable speed for iMPACT to work. Here is a way to do it from the command line. Here is a forum thread that discusses how to do this in the GUI.

best regards,

Jon

Hi Jon,

Tried different speeds of the cable,  at and above and below the device chain speed as reported, but no success - it seems always to end up in the warnings Can't find such instruction CFG_IN, followed by operation did not complete ....

Also , other operations that fail similarly :

Get Device ID, Get Device Signature/Usercode, Read Device Status, One Step SVF, Once Step, XSVF. See below

INFO:iMPACT - Digilent Plugin: JTAG Clock Frequency: 1000000 Hz
INFO:iMPACT - Current time: 3/24/19 1:00 PM
Maximum TCK operating frequency for this device chain: 6000000.
Validating chain...
Boundary-scan chain validated successfully.
WARNING:iMPACT:1774 - Can't find such instruction IDCODE
INFO:iMPACT:2488 - The operation did not complete successfully.
INFO:iMPACT - Current time: 3/24/19 1:00 PM
Maximum TCK operating frequency for this device chain: 6000000.
Validating chain...
Boundary-scan chain validated successfully.
WARNING:iMPACT:1774 - Can't find such instruction USERCODE
INFO:iMPACT:2488 - The operation did not complete successfully.
INFO:iMPACT - Current time: 3/24/19 1:00 PM
Maximum TCK operating frequency for this device chain: 6000000.
Validating chain...
Boundary-scan chain validated successfully.
WARNING:iMPACT:1774 - Can't find such instruction CFG_OUT
INFO:iMPACT:2488 - The operation did not complete successfully.
INFO:iMPACT - SVF file 'default.svf' will be generated in 'impact.ip' using preset options listed below.
INFO:iMPACT - Any pre-selected programming properties will not alter this output.
INFO:iMPACT - Current time: 3/24/19 1:00 PM
One step SVF/XSVF operation will close any existing cable connections.
 Please reconnect your cable after the completion of the one-step operation.
INFO:iMPACT - XSVF file 'default.xsvf'  will be generated in 'impact.ip' using preset options listed below.
INFO:iMPACT - Any pre-selected programming properties will not alter this output.
INFO:iMPACT - Current time: 3/24/19 1:00 PM
ERROR:iMPACT - This function requires that a target is opened first.
One step SVF/XSVF operation will close any existing cable connections.
 Please reconnect your cable after the completion of the one-step operation.

Any ideas .. ?

 

About command line / batch mode for iMACT : seems that would be no different, as I do change the cable speed from GUI as can be seen in the log.

impact_log.log

Share this post


Link to post
Share on other sites
  • 0
On 3/28/2019 at 8:34 AM, jpeyron said:

Hi @dry,

Looks like you got a response from the xilinx forums here. Did their suggestions fix your ISE errors?

best regards,

Jon

Heya Jon,

Now it seems resolved. And I can move to other questions to Digilent :) (you can see that Xilinx thread you 've referred too)

Thanks for your help on this.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now