OpenCV application with beagleboard and iRobot... USB problem

Hi,

I currently have an OpenCV program to run on the beagleboard, which
connects to an iRobot Create. I have the program on the beagleboard
ready to run, but the only problem comes when I have to pass an
argument in when I go to run the program.

When running it on the laptop, it is a simple matter of doing ./
program /dev/ttyUSB0... however on the beagleboard there is no option
for ttyUSBx...

I have a camera and the serial communication from the robot connected
to a USB hub which I then connect to the beagleboard. I just need to
know how to communicate with the robot from the beagleboard, when no
ttyUSBx exists.

There are other usb options when I do ls /dev, but none of them work
either.

Can anyone help?

Thank you!

Did you load usbserial? Otherwise you should do...

Sascha

Hi Gordon,

Have you tried using lsusb to ensure the system sees your USB devices?

Cheers,

Aaron

Which microcontroller do you use? If your microcontroller contains FTDI chip, then you should load “libftdi1” library in order to see ttyUSBx.

Which microcontroller do you use? If your microcontroller contains FTDI chip, then you should load "libftdi1" library in order to see ttyUSBx.

if it was ftdi, load the ftdi driver, ie. modprobe ftdi_sio

I am not sure if you have usbfs built-into your kernel. If you do,
mount the usbfs to /proc/bus/usb

mount -t usbfs none /proc/bus/usb

Next, send us the output of your usb devices and we may be able to help.

cat /proc/bus/usb/devices

-toan

Sorry for the late response.

Thanks for all of the replies, I will try all of this when I get to my
workstation today, and let you know what happens.

>Which microcontroller do you use? If your microcontroller contains FTDI chip, then you should load "libftdi1" library in order to see ttyUSBx.

if it was ftdi, load the ftdi driver, ie. modprobe ftdi_sio

I am not sure if you have usbfs built-into your kernel. If you do,
mount the usbfs to /proc/bus/usb

mount -t usbfs none /proc/bus/usb

Next, send us the output of your usb devices and we may be able to help.

cat /proc/bus/usb/devices

-toan

root@beagleboard:/# mount -t usbfs none /proc/bus/
usb
mount: none already mounted or /proc/bus/usb
busy
mount: according to mtab, usbfs is already mounted on /proc/bus/usb

The following is the output of lsusb and then cat /proc/bus/usb/
devices

lsusb:

cat /proc/bus/usb/devices:

T: Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh=
1
B: Alloc= 0/800 us ( 0%), #Int= 0, #Iso=
0
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs=
1
P: Vendor=1d6b ProdID=0002 Rev=
2.06
S: Manufacturer=Linux 2.6.28-omap1 musb-
hcd
S: Product=MUSB HDRC host
driver
S:
SerialNumber=musb_hdrc
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=
0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00
Driver=hub
E: Ad=81(I) Atr=03(Int.) MxPS= 4
Ivl=256ms

T: Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#= 1 Spd=480 MxCh=
3
B: Alloc= 0/800 us ( 0%), #Int= 2, #Iso=
0
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=00 MxPS=64 #Cfgs=
1
P: Vendor=1d6b ProdID=0002 Rev=
2.06
S: Manufacturer=Linux 2.6.28-omap1
ehci_hcd
S: Product=OMAP-EHCI Host
Controller
S: SerialNumber=ehci-omap.
0
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=
0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00
Driver=hub
E: Ad=81(I) Atr=03(Int.) MxPS= 4
Ivl=256ms

T: Bus=01 Lev=01 Prnt=01 Port=01 Cnt=01 Dev#= 2 Spd=480 MxCh=
4
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=01 MxPS=64 #Cfgs=
1
P: Vendor=05e3 ProdID=0608 Rev=
9.01
S: Product=USB2.0
Hub
C:* #Ifs= 1 Cfg#= 1 Atr=e0
MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00
Driver=hub
E: Ad=81(I) Atr=03(Int.) MxPS= 1
Ivl=256ms

T: Bus=01 Lev=02 Prnt=02 Port=02 Cnt=01 Dev#= 3 Spd=480 MxCh=
4
D: Ver= 2.00 Cls=09(hub ) Sub=00 Prot=01 MxPS=64 #Cfgs=
1
P: Vendor=05e3 ProdID=0608 Rev=
9.01
S: Product=USB2.0
Hub
C:* #Ifs= 1 Cfg#= 1 Atr=e0
MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub ) Sub=00 Prot=00
Driver=hub
E: Ad=81(I) Atr=03(Int.) MxPS= 1
Ivl=256ms

T: Bus=01 Lev=03 Prnt=03 Port=02 Cnt=01 Dev#= 4 Spd=480 MxCh=
0
D: Ver= 2.00 Cls=ef(unk. ) Sub=02 Prot=01 MxPS=64 #Cfgs=
1
P: Vendor=046d ProdID=0990 Rev=
0.08
S:
SerialNumber=7485B753
C:* #Ifs= 4 Cfg#= 1 Atr=80
MxPwr=500mA
Prot=00
Prot=00
I:* If#= 0 Alt= 0 #EPs= 1 Cls=0e(video) Sub=01 Prot=00
Driver=(none)
E: Ad=87(I) Atr=03(Int.) MxPS= 16
Ivl=16ms
I:* If#= 1 Alt= 0 #EPs= 0 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
I: If#= 1 Alt= 1 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS= 192
Ivl=125us
I: If#= 1 Alt= 2 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS= 384
Ivl=125us
I: If#= 1 Alt= 3 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS= 512
Ivl=125us
I: If#= 1 Alt= 4 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS= 640
Ivl=125us
I: If#= 1 Alt= 5 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS= 800
Ivl=125us
I: If#= 1 Alt= 6 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS= 944
Ivl=125us
I: If#= 1 Alt= 7 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS=1280
Ivl=125us
I: If#= 1 Alt= 8 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS=1600
Ivl=125us
I: If#= 1 Alt= 9 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS=1984
Ivl=125us
I: If#= 1 Alt=10 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS=2688
Ivl=125us
I: If#= 1 Alt=11 #EPs= 1 Cls=0e(video) Sub=02 Prot=00
Driver=(none)
E: Ad=81(I) Atr=05(Isoc) MxPS=3060
Ivl=125us
I:* If#= 2 Alt= 0 #EPs= 0 Cls=01(audio) Sub=01 Prot=00 Driver=snd-usb-
audio
I:* If#= 3 Alt= 0 #EPs= 0 Cls=01(audio) Sub=02 Prot=00 Driver=snd-usb-
audio
I: If#= 3 Alt= 1 #EPs= 1 Cls=01(audio) Sub=02 Prot=00 Driver=snd-usb-
audio
E: Ad=86(I) Atr=05(Isoc) MxPS= 36
Ivl=1ms

T: Bus=01 Lev=03 Prnt=03 Port=03 Cnt=02 Dev#= 5 Spd=12 MxCh=
0
D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=
1
P: Vendor=067b ProdID=2303 Rev=
3.00
S: Manufacturer=Prolific Technology
Inc.
S: Product=USB-Serial
Controller
C:* #Ifs= 1 Cfg#= 1 Atr=80
MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=00 Prot=00
Driver=(none)
E: Ad=81(I) Atr=03(Int.) MxPS= 10
Ivl=1ms
E: Ad=02(O) Atr=02(Bulk) MxPS= 64
Ivl=0ms
E: Ad=83(I) Atr=02(Bulk) MxPS= 64 Ivl=0ms

Which BB are you using?

Basically if lsusb is displaying nothing, then your kernel won’t see devices and won’t load the modules. It also means the onboard USB hub isn’t getting picked up for some reason and which is why you’re having USB issues.

Are you using the OTG USB port to connect your devices?

Cheers,

Aaron

it looks like you have a prolific usb-serial device.

not sure what distribution you use, but try modprobe pl2303

if you do not get an error, you should see a usb to serial device @ /dev/ttyUSB0

if you do not have the pl2303 module, you will have to rebuild your
kernel with that supported driver.

-toan

for what it's worth, some off-the-shelf usb/serial adapters work,
and some don't. i wasted several hours once fighting with a
pl2303-based adapter and finally gave up, went back to the store and
bought a different model. that one also used the pl2303 module, and
worked flawlessly. go figure.

rday

As to which type of BB I am using, it says 'BB-MB-000 Rev C3' on the
box.

I tried modprobe pl2303 but received error message: "FATAL: Module
pl2303 not found."

I will try to rebuild the kernal with it.

This is the usb hub I am using:
http://www.google.com/products/catalog?hl=en&q=f5u700-blk&bav=on.1,or.&um=1&ie=UTF-8&cid=2537691575734236212&ei=25BhTcbzA4H68AbahemEDA&sa=X&oi=product_catalog_result&ct=result&resnum=3&ved=0CDkQ8wIwAg#

Thanks.