Jump to content
  • 0

Ubuntu contention between FTDI D2XX and VCP Drivers


ArdRhi

Question

I recently let my Ubuntu machine update, and following the update, Waveforms stopped working with my Analog Discovery 2.

From what I gather, the latest kernel contains the FTDI VCP driver internally. The AD2 conflicts with the VCP driver, trying to call up the D2XX driver.

If I issue the following terminal commands with the AD2 disconnected, then connect the AD2 and bring up Waveforms, the AD2 is detected and works.

sudo rmmod ftdi_sio
sudo rmmod usbserial

If I try to do the following: 

  • Connect the BNC board
  • Connect 5vdc via the coaxial jack

The USB serial connection is dropped and Waveforms ceases to recognize the device. I need to rerun the above commands to get the AD2 discoverable again. However, the 5vdc coaxial power input cannot be connected at all, or it is not discovered regardless of driver commands.

I'm thinking I need a UDEV rule set. I don't think it was installed on my machine automatically during setup. I'm contemplating the procedure detailed here: https://github.com/cambridgehackers/connectal/blob/master/etc/udev/rules.d/52-digilent-usb.rules to try and generate the appropriate file, but I'm uncertain it is the correct UDEV ruleset.

Here's some data on the system I'm using, named Ishmael.

Ubuntu 16.04 LTS
Memory: 7.3 GiB
Processor: AMD A6-3420M APU with Radeon(tm) HD Graphics × 4
Graphics: AMD SUMO (DRM 2.43.0 / 4.4.0-121-generic, LLVM 5.0.0)
OS Type: 64-bit
Disk: 730.3 GB

gwen@Ishmael:~$ dmesg |tail
[ 5699.276932] usb 1-1: Product: Digilent USB Device
[ 5699.276938] usb 1-1: Manufacturer: Digilent
[ 5699.276943] usb 1-1: SerialNumber: 210321A19115
[ 5699.280365] ftdi_sio 1-1:1.0: FTDI USB Serial Device converter detected
[ 5699.280451] usb 1-1: Detected FT232H
[ 5699.280870] usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB0

Waveforms worked fine at this point. But causing the port to reset by doing anything like connect the BNC board or power connector does this:
[ 5699.303650] ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
[ 5699.303697] ftdi_sio 1-1:1.0: device disconnected
[ 5844.335465] usb 1-1: USB disconnect, device number 60

If you back out and reset the USB drivers, and make sure you have 5vdc already connected to the AD2, then connect the USB cable to the AD2, the LED in the AD2 does NOT light, and it is NOT detectable by Waveforms.


The below is a piece of the dmesg file not run through tail. It's a bit more detailed.

At this point, I run the two commands to deregister the FTDI D2XX and VCP drivers.
[ 5582.335208] usbserial: USB Serial deregistering driver FTDI USB Serial Device
[ 5582.335266] usbcore: deregistering interface driver ftdi_sio
[ 5584.856875] usbserial: USB Serial deregistering driver generic
[ 5584.856972] usbcore: deregistering interface driver usbserial_generic
[ 5584.857010] usbcore: deregistering interface driver usbserial

Here is where I reconnected the AD2, with the BNC board attached but no coaxial power.
[ 5592.140062] usb 1-1: new high-speed USB device number 59 using ehci-pci
[ 5592.277952] usb 1-1: New USB device found, idVendor=0403, idProduct=6014
[ 5592.277966] usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 5592.277974] usb 1-1: Product: Digilent USB Device
[ 5592.277980] usb 1-1: Manufacturer: Digilent
[ 5592.277985] usb 1-1: SerialNumber: 210321A19115
[ 5593.327414] usbcore: registered new interface driver usbserial
[ 5593.327471] usbcore: registered new interface driver usbserial_generic
[ 5593.327516] usbserial: USB Serial support registered for generic
[ 5593.333592] usbcore: registered new interface driver ftdi_sio
[ 5593.333622] usbserial: USB Serial support registered for FTDI USB Serial Device
[ 5593.333767] ftdi_sio 1-1:1.0: FTDI USB Serial Device converter detected
[ 5593.333832] usb 1-1: Detected FT232H
[ 5593.336598] usb 1-1: FTDI USB Serial Device converter now attached to ttyUSB0

At this point, Waveforms will detect the AD2 and work properly, until I connected the 5vdc coaxial power input, at which point the following occurred:
[ 5608.403140] ftdi_sio ttyUSB0: FTDI USB Serial Device converter now disconnected from ttyUSB0
[ 5608.403163] ftdi_sio 1-1:1.0: device disconnected
[ 5684.633066] usb 1-1: USB disconnect, device number 59
 

Waveforms no longer can detect the AD2, as the VCP and D2XX drivers are once again in contention. I've tried the usual stuff: connecting directly to the machine, using a short cable, trying a different cable, using a powered hub instead of unpowered, etc., etc...

Please let me know if there is something I can try at this point. A UDEV ruleset would be nice.

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

Archived

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

×
×
  • Create New...