Jump to content
  • 0

djtgcfg enum not recognizing Anvyl board


grf

Question

I have a weird error with latest djtgcfg on ubuntu (linux 4.2 ubuntu Wily) 

I have three devel boards (Basys2, Nexys3 and Anvyl).  

djtgcfg enum recognizes the Basys2 and Nexys3 boards, but not the Anvyl 

I note that lsusb reports the Anvyl board as  ...

Bus 001 Device 013: ID 0403:6010 Future Technology Devices International, Ltd FT2232C Dual USB-UART/FIFO IC

Curiously/previously I was able to use all three devices when I run Webpack ISE and djtgfg on ubuntu under 'parallels VM' on my Mac Book Pro.  

I am happy to hack/help diagnose. 

And yes I did change install.sh to recognize kernel 4.2

Any help would be appreciated.  I have an Anvyl project I want to complete. 

Thanks in advance. 

Link to comment
Share on other sites

11 answers to this question

Recommended Posts

OK I finally did resolve this.

In the end I just gave up and reinstalled ubuntu 15.10

Before doing anything  (no WebISE install)  I pulled the *.deb verision of adept 2 packages

Previously I had always used the .zip files from the adept2 website,  hacked the install.sh scripts (when necessary) installed libusb and then run the install.sh scripts.

This time I tried the *.deb packages. 

wget http://cloud.digilentinc.com/Software/Adept2/digilent.adept.runtime_2.16.1-2_amd64.deb

wget http://cloud.digilentinc.com/Software/Adept2/digilent.adept.utilities_2.2.1-i386.deb

sudo dpkg -i *.deb

 
I was able to move bit files to my Anvyl and Basys2 boards using this!
 
So, I guess my advice is to use the deb packages.
 
Thanks for all the responses.  You can close this as an issue. 
 
Gary
 
 

 

 

Link to comment
Share on other sites

Yes I have the latest versions.

I had to changed the install scripta to accept the latest linux kernel (4.xx) as the install script was only expecting <4.0.

I can confirm that when the FTDI/Anvyl board is plugged in, udev rules correctly route to the /usr/sbin/dftdrvdtch

I proved this by replacing /usr/sbin/dftdrvdtch with my own executable which logs the args to a file.

dftdrvdtch does seem to detach usb device (I can see the logged messages in  dmesg)

As I mentioned I can run on a ubuntu VM running in parallels from my mac. 

I just ran 'strace -v -f on djtgcfg enum' on my mac and will compare it with that from ubuntu running on bare metal.

I am happy to help debug. 

It is weird.

Gary 

 

 

Link to comment
Share on other sites

More debugging 

I pulled the ftd2xxx drivers from the web again and installed ftd2xx drivers,  utilities and runtime again (is there a clean way to uninstall?) 

After a reboot and following some of the debug suggestions in the ftd2xx driver README

sudo lsmod | grep ftdi_sio

sudo sudo rmmod ftdi_sio

sudo rmmod usbserial

sudo udevadm control --reload-rules

sudo udevadm trigger

I finally saw 

$ djtgcfg enum
Found 1 device(s)

Device: Anvyl
    Product Name:   Digilent Anvyl
    User Name:      Anvyl
    Serial Number:  210258477713

I really though I was there. 

When I tried to prog with 

djtgcfg prog -i 0 -d Anvyl -f hexpad.bit

djtgcfg just hung

When I traced with 

strace -f -v prog -i 0 -d Anvyl -f hexpad.bit >log 2>&1

I see that the file is full of 

nanosleep({0, 1000}, NULL)  = 0
[pid  4672] nanosleep({0, 1000}, NULL)  = 0
[pid  4672] nanosleep({0, 1000}, NULL)  = 0
[pid  4672] nanosleep({0, 1000},  <unfinished ...>
[pid  4666] <... poll resumed> )        = 1 ([{fd=18, revents=POLLOUT}])
[pid  4666] ioctl(18, USBDEVFS_REAPURBNDELAY, 0x7fcf9a29de40) = 0
[pid  4672] <... nanosleep resumed> NULL) = 0
[pid  4666] ioctl(18, USBDEVFS_DISCARDURB <unfinished ...>
[pid  4672] nanosleep({0, 1000},  <unfinished ...>
[pid  4666] <... ioctl resumed> , 0x7fcf88000b58) = -1 EINVAL (Invalid argument)
[pid  4666] ioctl(18, USBDEVFS_DISCARDURB, 0x7fcf88000b20) = -1 EINVAL (Invalid argument)
[pid  4666] ioctl(18, USBDEVFS_DISCARDURB <unfinished ...>
[pid  4672] <... nanosleep resumed> NULL) = 0
[pid  4666] <... ioctl resumed> , 0x7fcf88000ae8) = -1 EINVAL (Invalid argument)
[pid  4672] nanosleep({0, 1000},  <unfinished ...>
[pid  4666] poll([{fd=13, events=POLLIN}, {fd=18, events=POLLOUT}], 2, 100) = 1 ([{fd=18, revents=POLLOUT}])
[pid  4666] ioctl(18, USBDEVFS_REAPURBNDELAY <unfinished ...>
[pid  4672] <... nanosleep resumed> NULL) = 0
[pid  4666] <... ioctl resumed> , 0x7fcf9a29de40) = 0

looping repeatedly. 

 

I was suprised to see around 8 processes in this trace.

Gary 

 

 

 

 

Link to comment
Share on other sites

Hi all,

I have a similar problem with adept and a JTAG HS2. I installed 64bits adept runtime 2.16.1 and utilites 2.2.1 from the .tar.gz provided here and libftd2x 64bits 1.3.6 from here.

I'm running the control computers under linux debian 8 (stable) for some or linux debian testing for others.

In the past djtgcfg was running fine:

$ djtgcfg enum

Found 1 device(s)

Device: JtagHs2
    Product Name:   Digilent JTAG-HS2
    User Name:      JtagHs2
    Serial Number:  210249854746

$ djtgcfg init -d JtagHs2
Initializing scan chain...
Found Device ID: 06e59093
Found Device ID: 06e59093
Found Device ID: 84250093

Found 3 device(s):
    Device 0: XC6VLX240T
    Device 1: XC2C64A
    Device 2: XC2C64A

Since an unknown date (unfortunately I can't say if it's since an update in debian or since I upgraded the version of adept runtime / utilities / libftd2xx), djtgcfg fails in the following way:

$ djtgcfg enum
Found 1 device(s)

Device: JtagHs2
    Product Name:   Digilent JTAG-HS2
    User Name:      JtagHs2
    Serial Number:  210249854746
$ djtgcfg init -d JtagHs2
ERROR: failed to enable JTAG, erc = 3077
^C

(i need to kill it because it blocks forever)

According to grf's suggestion, I tried with the debian packages instead of the tgz and indeed it fixes the issue.

I had a look at the content of the tgz versus the content of the deb and noticed several differences: the deb contains many more libraries and the libraries or executable binaries differ. I'm quite surprised, except for some packaging details / directory layout differences, there should be no differences between binaries in tgz and deb of the same version of adept runtime / utilities? Could you check that there was no packaging issue with these versions of adept?

If you wonder why I don't install from deb on a debian system, the reason is that I need to integrate adept2 in a custom toolchain which is then deployed on a set of several control nodes (40) of an experimental facility, thus I don't want to install in default locations nor run the installation as root.

best,

Matthieu

Link to comment
Share on other sites

Hi all,

Gary's solution works in my case. 

I am running ubuntu 16.04 LTS and working with USB-JTAG on the Zedboard.

Previously, I had installed Digilent runtime and utilities by running install.sh in *.gz files. 

djtgcfg enum worked, but djtgcfg init -d Zed  prompted  ERROR: failed to enable JTAG, erc = 3

Then, I uninstalled both runtime and utilities and tried to install them with debian package, like Gary did. And it worked! 

Thank you!

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...