Jump to content
  • 0

Analog Discovery 2 - not connecting under Ubuntu


Enbyted

Question

Hi all!

I'm running Ubuntu 20.04.1 LTS on ryzen 1700 with B350 chipset. 

When running waveforms (3.14.3, adept 2.20.2) after selecting device in Device Manager the application hangs for a while and show error box

Quote

DptilIO failed ERC:2 out:8 in:28
Communication failed or image device id is wrong
ID: 0x0 Type: 0x0 Version: 0x0

The LED on AD2 doesn't start blinking. However if I use "Force programming" from context menu (whatever it does) the error message is the same, but LED starts blinking.

My Analog Discovery 2 is working perfectly fine on the same PC under Windows and on other computers under Windows (I don't heave another Linux machine available). It also was working some time ago, probably before updating from Ubuntu 19 or something like that (I'm not sure now - it was a few months ago).

I did try different USB cables, different ports (different USB controllers too) and using external power supply for AD2, though I really don't think it's hardware issue as it works on the same machine on Windows.

There are no errors in dmesg:

[ 4535.196219] usb 1-2: USB disconnect, device number 27
[ 4537.393789] usb 1-2: new high-speed USB device number 28 using xhci_hcd
[ 4537.564412] usb 1-2: New USB device found, idVendor=0403, idProduct=6014, bcdDevice= 9.00
[ 4537.564417] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 4537.564420] usb 1-2: Product: Digilent USB Device
[ 4537.564422] usb 1-2: Manufacturer: Digilent
[ 4537.564424] usb 1-2: SerialNumber: 210321AD5BE1
[ 4537.576482] ftdi_sio 1-2:1.0: FTDI USB Serial Device converter detected
[ 4537.576527] usb 1-2: Detected FT232H
[ 4537.587553] usb 1-2: FTDI USB Serial Device converter now attached to ttyUSB0
[ 4537.604594] ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
[ 4537.604617] ftdi_sio 1-2:1.0: device disconnected

Disconnect, I suspect, is because of dftdrvdtch which probably reconfigures the FTDI device thus disabling virtual serial port.

Any ideas what might be the problem here?

Link to comment
Share on other sites

10 answers to this question

Recommended Posts

4 hours ago, attila said:

Did you try reinstalling the digilent.adept.runtime ?

Yes I did, I upgraded it just before posting here (by uninstalling and installing new version)

4 hours ago, attila said:

It could also be a kernel related issue...

Possible, I'm on 5.4 right now, I'll try 5.8 since that's available from repos. If that doesn't help maybe I'll quickly build & test on some older version, like 4.19, the previous long term release. Not sure if downgrading won't mess up Ubuntu though.

I'm using a lot of FT2232H chips with libftdi on this machine and they aren't causing any problems. I did try disconnecting them all of course. Though I don't think that rules out kernel problem as libftdi is based on libusb which is userspace.

I'll report after I test 5.8, 4.19 might take more time, kernel for PC is much larger than for simple embedded system...

Link to comment
Share on other sites

Okay, so 5.8 and my graphics driver definitely aren't friends, but apart from that everything seems to work OK.

The error message and program behavior is the same. Though the LED on AD2 started blinking without using force programming option.

The 4.19 I can test next week, it's not high on my priority list - I'm working around the issue by having AD2 connected to my laptop and using remote screen in fullscreen, so it's almost like the same PC ?

Link to comment
Share on other sites

Something on my system appears to not like 4.19 kernel and it doesn't boot. If I set init to shell than yeah, I get a shell, but it isn't very helpful since it's too early in the process. I'm not going to debug the kernel issue further.

I'm open to other suggestions though, let me know if I can try anything else.

Link to comment
Share on other sites

Which Adept Runtime package do you have installed?
Which Waveforms package do you have installed?

My AD2 seems to work fine in Uubuntu 2.04.1 LTS 64-bit. I don't have any AMD hardware to test this on and am using an old core i7 2600K that I had laying around when I need to test outside of a Virtual Machine.

uname -a
Linux 5.4.0-53-generic #59-Ubuntu SMP Wed Oct 21 09:38:44 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

cat /etc/os-release
NAME="Ubuntu"
VERSION="20.04.1 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.1 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal

Do you have more than one version of libftd2xx installed? We include 1.4.8 (the latest FTDI release) with the Adept Runtime and have performed all testing with that version. You can use ldconfig to determine the path it has for the library as follows:

/sbin/ldconfig -p | grep libftd2xx
libftd2xx.so (libc6,x86-64) => /usr/lib64/digilent/adept/libftd2xx.so

If an older version of libftd2xx were to be loaded then that might be the source of the problem. Another possibility is that it's an issue with the version of libusb that FTDI linked into libftd2xx. I'm not sure why, but they perform static link of a library that is indlucded with virtually every Linux distribution. It would be better if they performed a dynamic link and let the version included with the distro perform the low level USB communication. Unfortunately I have no control over that since we are using FTDI's closed source driver.

Link to comment
Share on other sites

enbyted@enbyted-ubuntu:~/Pobrane$ apt-cache show digilent.adept.runtime
Package: digilent.adept.runtime
Status: install ok installed
Priority: optional
Section: misc
Installed-Size: 10000
Maintainer: Digilent inc. <support@digilentinc.com>
Architecture: amd64
Version: 2.20.2
Depends: libc6 (>= 2.5)
Conffiles:
 /etc/digilent-adept.conf 375481731471a001848f3bde9b60f9d5
 /etc/udev/rules.d/52-digilent-usb.rules f9162f3d7b0da5d479f28e04344c7482
 /etc/ld.so.conf.d/digilent-adept-libraries.conf 23ab6c254b104e729560f41e0fd9521e
Description: Digilent Adept Runtime
 The Adept Runtime consists of the shared libraries, firmware images, and
 configuration files necessary to communicate with Digilent's devices.
Description-md5: 0db1214acbc4a2516a0d04d7b7843df4

enbyted@enbyted-ubuntu:~/Pobrane$ apt-cache show digilent.waveforms
Package: digilent.waveforms
Status: install ok installed
Priority: optional
Section: misc
Installed-Size: 80000
Maintainer: Digilent inc. <waveforms@digilentinc.com>
Architecture: amd64
Version: 3.14.3
Replaces: waveforms
Depends: libc6 (>= 2.14), xdg-utils, digilent.adept.runtime (>= 2.17.1)
Pre-Depends: dpkg (>= 1.14.0)
Description: Digilent WaveForms
 Digilent WaveForms Application, Runtime and SDK.
 Support for Digilent Scope & Instruments products.
Description-md5: 05dece6af71fab4cad83915e1d98002e
Homepage: http://www.digilentinc.com/WaveForms

enbyted@enbyted-ubuntu:~/Pobrane$ sudo ldconfig -p | grep libftd2
	libftd2xx.so (libc6,x86-64) => /usr/lib64/digilent/adept/libftd2xx.so

enbyted@enbyted-ubuntu:~/Pobrane$ uname -a
Linux enbyted-ubuntu 5.4.0-56-generic #62-Ubuntu SMP Mon Nov 23 19:20:19 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

 

18 hours ago, malexander said:

other possibility is that it's an issue with the version of libusb that FTDI linked into libftd2xx.

Hmm, possible, though unlikely I think. Strange thing is that it was working on the same system, probably before some update.

18 hours ago, malexander said:

[...] when I need to test outside of a Virtual Machine

Now, that's a thought, I've quickly installed a Windows 10 in VM and AD2 has no problems working through USB redirect. That's progress, I quess, I don't need second machine now :D 

Link to comment
Share on other sites

So, I finally got around to reinstalling the Ubuntu. Now it's fresh Ubuntu 20.04 LTS and to my surprise it doesn't work. Exactly the same symptoms as before.

I tried 3.15.2 beta, but it's the same problem.

Still it works inside a Windows VM (Under Virtual box)

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...