Go Down

Topic: Don't have /dev/ttyUSB* (Read 5176 times) previous topic - next topic

Chris_Goodwin

Jun 23, 2011, 05:08 am Last Edit: Jun 23, 2011, 05:24 am by Chris Goodwin Reason: 1
Hello all,

When I plug the cable into my Arduino Duemilanove and my computer, I don't get /dev/ttyUSB0 or /dev/ttyUSB anything.  There is no change at all in the /dev directory.  Also, when I run the Arduino IDE as a regular user, the Serial Port entry under Tools is greyed out.  

I have tried two different cables, and neither of them works.  The behavior is the same whether it is on USB power or a wall wart.  

I have connected it to my wife's Windows XP box and it does work; I can upload sketches to it.  If it matters, I can't seem to get any output from the serial monitor in the Arduino software, though.  

It has never worked when connected to my computer.  Also, when I connected it for the first time, LED L was blinking in a pattern of 4 blinks, pause, 4 blinks, pause, etc.  I uploaded the blink sketch to it from my wife's computer, which worked (in that it blinked 1 second on, 1 second off), and I've been able to upload others to it, also from my wife's computer, which have worked.  

The output of dmesg is as follows:
[font=Courier]
[78841.684055] usb 2-8: new full speed USB device using ohci_hcd and address 7
[78841.902080] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
[78841.902089] usb 2-8: invalid descriptor for config index 0: type = 0x0, length = 0
[78841.902096] usb 2-8: can't read configurations, error -22
[78842.080044] usb 2-8: new full speed USB device using ohci_hcd and address 8
[78842.294089] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
[78842.294098] usb 2-8: invalid descriptor for config index 0: type = 0x0, length = 0
[78842.294106] usb 2-8: can't read configurations, error -22
[78842.472258] usb 2-8: new full speed USB device using ohci_hcd and address 9
[78842.519074] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
[78842.519083] usb 2-8: invalid descriptor for config index 0: type = 0x0, length = 0
[78842.519087] usb 2-8: can't read configurations, error -22
[78842.696043] usb 2-8: new full speed USB device using ohci_hcd and address 10
[78842.742087] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
[78842.742096] usb 2-8: invalid descriptor for config index 0: type = 0x0, length = 0
[78842.742104] usb 2-8: can't read configurations, error -22
[78842.744108] hub 2-0:1.0: unable to enumerate USB device on port 8
[/font]

My system:

* Debian squeeze.  Output of uname -a is as follows:  [font=Courier]Linux river 2.6.32-5-vserver-686-bigmem #1 SMP Wed May 18 09:17:18 UTC 2011 i686 GNU/Linux[/font]
* AMD Athlon64 3800+
* 4GB of RAM
* Arduino Duemilanove with Atmega328 and FT232RL chip.
* Arduino 0022 software

Edit: I figured out why the serial port was greyed out. For some reason, my preferences.txt file had the serial port as COM1. I don't know where that came from. When I change it to /dev/ttyS0 it is no longer greyed out, but I still can't upload (ttyS0 is not the USB serial converter).

sharamun

#1
Jun 23, 2011, 06:43 am Last Edit: Jun 23, 2011, 07:08 am by sharamun Reason: 1
On both Debian 5.0.6 (lenny) and 6.0.1a (squeeze) the Arduino Uno has instantiated on /dev/ttyACM0 so you may want to look for that after plugging it in to your USB port, however the errors you reported may indicate a bad USB port so try another if you have one.

I noticed from the uname output you posted, it shows "2.6.32-5-vserver-686-bigmem" which does not show on my system. Does "vserver" indicate a virtual server instance and "bigmem" a 64-bit instance? If so, I'm guessing but there may be device driver issues with these OS versions.

For reference, here is a successful recognition of an Arduino Uno from my Debian 6.0.1a system:

/var/log/messages excerpt:

Jun 19 15:00:19 spectre kernel: [  165.972078] usb 2-2: new full speed USB device using uhci_hcd and address 2
Jun 19 15:00:19 spectre kernel: [  166.169115] usb 2-2: New USB device found, idVendor=2341, idProduct=0001
Jun 19 15:00:19 spectre kernel: [  166.169122] usb 2-2: New USB device strings: Mfr=1, Product=2, SerialNumber=220
Jun 19 15:00:19 spectre kernel: [  166.169128] usb 2-2: Product: Arduino Uno
Jun 19 15:00:19 spectre kernel: [  166.169133] usb 2-2: Manufacturer: Arduino (www.arduino.cc)
Jun 19 15:00:19 spectre kernel: [  166.169138] usb 2-2: SerialNumber: 6493534323335171F111
Jun 19 15:00:19 spectre kernel: [  166.169304] usb 2-2: configuration #1 chosen from 1 choice
Jun 19 15:00:19 spectre kernel: [  166.254896] cdc_acm 2-2:1.0: ttyACM0: USB ACM device
Jun 19 15:00:19 spectre kernel: [  166.257238] usbcore: registered new interface driver cdc_acm
Jun 19 15:00:19 spectre kernel: [  166.257245] cdc_acm: v0.26:USB Abstract Control Model driver for USB modems and ISDN adapters

Also for the record, the output from "uname -a":

Linux spectre 2.6.32-5-686 #1 SMP Wed May 18 07:08:50 UTC 2011 i686 GNU/Linux

You will likely need to use the device from a non-root account and if so, set the ownership/permission accordingly and/or add the user to the group the device is owned by.

If you are using a local build of the rxtx Java/Linux libs directly (rather than via Arduino 0022), make sure RXTXCommDriver.java includes ttyACM or it will never find the device. See http://rxtx.qbang.org/wiki/index.php/Installation_on_Linux for reference.

Chris_Goodwin

The vserver kernel apparently includes support for virtualization.  I'm not sure why it's installed.  The bigmem kernel indicates that it's compiled to support from 4-64GB of RAM.  I'm switching out to the non-vserver kernel and will see if that makes any difference. 

I have the Debian rxtx libs (2.2pre2-2) installed. 

I did forget to mention that I've tried it in every USB port on my system, as well as on a 4-port NEC USB add-in card, with identical results. 

I also don't have /dev/ttyACM*.  I went ahead and installed the cdc-acm module via modprobe and that hasn't changed anything.

sharamun

Have you been able to successfully use another USB device (such as a flash drive) on any of your USB ports?

After plugging in the Arduino device, as root please post the output from:

/var/log/messages

lsusb -v

With the Arduino device plugged in, as root you could try removing and reloading the ohci_hcd module:

modprobe -r ohci_hcd
modprobe ohci_hcd

...and post the output from /var/log/messages

Chris_Goodwin

#4
Jun 24, 2011, 11:52 pm Last Edit: Jun 24, 2011, 11:55 pm by Chris Goodwin Reason: 1
I have successfully used many USB devices; several flash drives, a joystick, and my USB trackball.

/var/log/messages output:

[font=Courier]
Jun 24 14:40:53 river kernel: [107732.904053] usb 2-8: new full speed USB device using ohci_hcd and address 11
Jun 24 14:40:53 river kernel: [107733.122818] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
Jun 24 14:40:54 river kernel: [107733.300038] usb 2-8: new full speed USB device using ohci_hcd and address 12
Jun 24 14:40:54 river kernel: [107733.518819] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
Jun 24 14:40:54 river kernel: [107733.696040] usb 2-8: new full speed USB device using ohci_hcd and address 13
Jun 24 14:40:54 river kernel: [107733.742816] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
Jun 24 14:40:54 river kernel: [107733.920041] usb 2-8: new full speed USB device using ohci_hcd and address 14
Jun 24 14:40:54 river kernel: [107733.966822] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
[/font]

The output of lsusb -v is in the attached file lsusbv.txt

Output from /var/log/messages after removing and reloading ohci_hcd:

[font=Courier]

Jun 24 14:45:03 river kernel: [107982.895049] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
Jun 24 14:45:03 river kernel: [107982.895096] ehci_hcd 0000:00:02.1: PCI INT B -> Link[APCL] -> GSI 23 (level, low) -> IRQ 23
Jun 24 14:45:03 river kernel: [107982.895144] ehci_hcd 0000:00:02.1: EHCI Host Controller
Jun 24 14:45:03 river kernel: [107982.895184] ehci_hcd 0000:00:02.1: new USB bus registered, assigned bus number 1
Jun 24 14:45:03 river kernel: [107982.895316] ehci_hcd 0000:00:02.1: debug port 1
Jun 24 14:45:03 river kernel: [107982.895339] ehci_hcd 0000:00:02.1: irq 23, io mem 0xfe02e000
Jun 24 14:45:03 river kernel: [107982.904034] ehci_hcd 0000:00:02.1: USB 2.0 started, EHCI 1.00
Jun 24 14:45:03 river kernel: [107982.904089] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
Jun 24 14:45:03 river kernel: [107982.904096] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
Jun 24 14:45:03 river kernel: [107982.904103] usb usb1: Product: EHCI Host Controller
Jun 24 14:45:03 river kernel: [107982.904107] usb usb1: Manufacturer: Linux 2.6.32-5-686-bigmem ehci_hcd
Jun 24 14:45:03 river kernel: [107982.904113] usb usb1: SerialNumber: 0000:00:02.1
Jun 24 14:45:03 river kernel: [107982.905094] usb usb1: configuration #1 chosen from 1 choice
Jun 24 14:45:03 river kernel: [107982.905227] hub 1-0:1.0: USB hub found
Jun 24 14:45:03 river kernel: [107982.905244] hub 1-0:1.0: 10 ports detected
Jun 24 14:45:03 river kernel: [107982.937976] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
Jun 24 14:45:03 river kernel: [107982.938022] ohci_hcd 0000:00:02.0: PCI INT A -> Link[APCF] -> GSI 20 (level, low) -> IRQ 20
Jun 24 14:45:03 river kernel: [107982.938073] ohci_hcd 0000:00:02.0: OHCI Host Controller
Jun 24 14:45:03 river kernel: [107982.938099] ohci_hcd 0000:00:02.0: new USB bus registered, assigned bus number 2
Jun 24 14:45:03 river kernel: [107982.938351] ohci_hcd 0000:00:02.0: irq 20, io mem 0xfe02f000
Jun 24 14:45:03 river kernel: [107982.994054] usb usb2: New USB device found, idVendor=1d6b, idProduct=0001
Jun 24 14:45:03 river kernel: [107982.994063] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
Jun 24 14:45:03 river kernel: [107982.994070] usb usb2: Product: OHCI Host Controller
Jun 24 14:45:03 river kernel: [107982.994075] usb usb2: Manufacturer: Linux 2.6.32-5-686-bigmem ohci_hcd
Jun 24 14:45:03 river kernel: [107982.994080] usb usb2: SerialNumber: 0000:00:02.0
Jun 24 14:45:03 river kernel: [107982.995067] usb usb2: configuration #1 chosen from 1 choice
Jun 24 14:45:03 river kernel: [107982.995200] hub 2-0:1.0: USB hub found
Jun 24 14:45:03 river kernel: [107982.995217] hub 2-0:1.0: 10 ports detected
Jun 24 14:45:04 river kernel: [107983.576033] usb 2-1: new low speed USB device using ohci_hcd and address 2
Jun 24 14:45:04 river kernel: [107983.790058] usb 2-1: New USB device found, idVendor=046d, idProduct=c404
Jun 24 14:45:04 river kernel: [107983.790067] usb 2-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
Jun 24 14:45:04 river kernel: [107983.790073] usb 2-1: Product: Trackball
Jun 24 14:45:04 river kernel: [107983.790078] usb 2-1: Manufacturer: Logitech
Jun 24 14:45:04 river kernel: [107983.790255] usb 2-1: configuration #1 chosen from 1 choice
Jun 24 14:45:04 river kernel: [107983.802862] input: Logitech Trackball as /devices/pci0000:00/0000:00:02.0/usb2/2-1/2-1:1.0/input/input6
Jun 24 14:45:04 river kernel: [107983.803060] generic-usb 0003:046D:C404.0003: input,hidraw0: USB HID v1.10 Mouse [Logitech Trackball] on usb-0000:00:02.0-1/input0
Jun 24 14:45:04 river kernel: [107984.112032] usb 2-8: new full speed USB device using ohci_hcd and address 3
Jun 24 14:45:05 river kernel: [107984.330053] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
Jun 24 14:45:05 river kernel: [107984.508044] usb 2-8: new full speed USB device using ohci_hcd and address 4
Jun 24 14:45:05 river kernel: [107984.726058] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
Jun 24 14:45:05 river kernel: [107984.904042] usb 2-8: new full speed USB device using ohci_hcd and address 5
Jun 24 14:45:05 river kernel: [107984.950053] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
Jun 24 14:45:05 river kernel: [107985.128038] usb 2-8: new full speed USB device using ohci_hcd and address 6
Jun 24 14:45:05 river kernel: [107985.174053] usb 2-8: config index 0 descriptor too short (expected 32, got 0)
[/font]

The "config index 0 descriptor too short" implies to me that there's something on the FTDI chip that the USB driver is looking for and not finding.  Vendor and product ID, maybe?  Is there any way to write those to the FTDI chip?  Edit: Actually I found them in the dump of the FTDI EEPROM. 

Chris_Goodwin

#5
Jun 25, 2011, 12:47 am Last Edit: Jun 26, 2011, 11:40 pm by Chris Goodwin Reason: 1
If it matters, here is the dump from my FTDI:

Removed.  This is actually incorrect.  I don't know where it came from but it wasn't from my Arduino. 

sharamun

After some thinking and research on this issue, here are some other comments:

1. From what I've read on the web, a number of people have had similar problems with USB devices on Debian/Ubuntu 64-bit as all the kinks haven't been worked out of the USB drivers (as I suspected)
2. Try removing all USB devices from your system (including the trackball), reboot the system, connect the Arduino as the only USB device and test it
3. Try connecting the Arduino device to your computer through a low-speed USB hub as the only USB device and test it
4. Try running the OS in 32-bit mode, connect the Arduino as the only USB device and test it

If you try any of the above, I would be interested to know what you find so please post the results when you get the chance. Thanks.

Chris_Goodwin

I am running on 32-bit.

I've all of those things and still get the same result. Some of the documentation on the FTDI site implies that if it is simply unable to enumerate, there's a hardware problem. I'm not 100% sure this is the case, because it does work on Windows. Still, it's odd that I can't get any other message nor any actual connection out of it.

Go Up