RevC USB Host port randomly disconnects

Hi,

I've been playing around with Sakoman's precompiled kernel and rootfs
and it all works fine. However, when I try to copy a lot of data from
a usb key or through the network, the beagleboard randomly disconnects
the USB. I haven't been able to copy a single file on the Beagleboard
(I tried some 16MB mp4 files and some larger files) but it doesn't
work at all.

I power the beagleboard using the iPod charger and tried several
(higher specced) psu's as well. I've tried to connect different hub's
as well, with no luck either.

Somebody said that it could be a bug in the kernel (2.6.29-omap1) and
that there might be a workaround. Can somebody help me with this
problem?

Kind regards,

Eelco

What about the angstrom rootfs and kernels? I have no problems with big USB transfers there. The 2.6.29 OE builds is working quite well, but it heavily patches usb.

regards,

Koen

Let me see if I can copy large files within the SD. Yup, that works
ok...so it is something with the USB port.

Any clues?

regards,

Eelco

What hw rev do you have? What port do you use?

I had the same problems with the OTG port with 2.6.28.
As far as I know there is no fix yet.
With the EHCI port on C2 hw I haven't seen the problem yet.

Frans

Hi,

I've been playing around with Sakoman's precompiled kernel and rootfs
and it all works fine. However, when I try to copy a lot of data from
a usb key or through the network, the beagleboard randomly disconnects
the USB. I haven't been able to copy a single file on the Beagleboard
(I tried some 16MB mp4 files and some larger files) but it doesn't
work at all.

I don't see this on my rev C Beagleboard or on my Overo when
transferring a 64MB mp4 file:

root@beagleboard:~# cp /bbb.mp4 /media/sda1/test/
root@beagleboard:~# ls -l /media/sda1/test/
total 63144
-rwxr-xr-x 1 root root 64657027 Apr 19 22:10 bbb.mp4

root@overo:~# cp /bbb.mp4 /media/sda1/test/
root@overo:~# ls -l /media/sda1/test/
total 63144
-rwxr-xr-x 1 root root 64657027 Apr 20 07:38 bbb.mp4

Can you give us a little more info on which of my builds you are using
and what type of USB data storage device you are using?

I did my test using my most recent build, the EHCI port, a Cyberpower
powered hub and a Lexar 4GB flash drive.

Steve

From the thread title it appears he is using ehci, so I don't think
that the musb patches matter in this case :slight_smile:

I too see no issues with large file transfers, so something else is
going on here.

Steve

Eelco:

Your symptoms sound very much like insufficent USB power to your
device. I had similar problems with my B4 until I hooked up an
external power supply to my hub.

Have you tried using a self-powered USB hub, i.e., one with an
external power supply? According to the Rev C2.2 BeagleBoard system
reference manual (http://beagleboard.org/static/BBSRM_latest.pdf) the
Host-only port should be able to deliver 500 mA. However, I think
this is only if you have a 5V regulated supply connected through the
power jack. According to section 7.2 of the system reference manual,
"if the board is powered from the OTG connector, then the power from
this port [i.e., host-only USB] is extremely limited and will not be
able to provide sufficient power to run most USB devices".

Hope this helps,
John

Thank you all for your replies. I was also thinking about an
insufficient powersupply. However, I use an iPod charger as power
supply and not a powered hub. I read something in the irc logs
regarding someone who had the same problems. I will try and see
whether I am able to increase the power using a DC adapter. How about
the MUSB patches? How do I apply these?

Kind regards, Eelco

If you use openembedded they'll get applied for you. If not using openembedded: 'man patch'

regards,

Koen

did Steve also use these patches in his kernel builds? I'm currently
using 2.6.29-omap1 as kernel version. I will look into the power
issue. I hope I will get the DC in to work, as I have done something
really stupid and plugged 5v the wrong way in. There hasn't been any
smoke and the board still works on the OTG power. It should however be
explained more explicit in de SRM (they do mention a lot about exactly
5 volts, but nothing about the pinout).

So I hope to supply the board with more amps to get sufficient power.
Can the power to OTG port be more when you use a separate USB power
supply?

Kind regards, Eelco

The pinout is clearly defined in section 9.1 of the System Reference Manual. There is even a big picture.

Gerald

Thank you, I have been stuck on page 24 and 16 I think. Both mention
the power connector, but do not supply the correct schematics...
Thankfully the power port hasn't been broken. I still have a fine
board, now trying to see whether I am able to do my transfers.

kind regards, Eelco

Okay,

I've connected the beagleboard to a 5V 2A max power supply using the
DC in connector. I've tried to copy stuff, but it still gets stuck
after copying approx 10-15MB. It completely disables the USB EHCI
port. I use a powered logitech USB hub. The board does not crash, only
the USB gets disconnected and only a reset solves the problem.

Kind regards, Eelco

Hi,

Just captured the post-mortem on the serial console, during the USB
disconnect. Somehow it is not able to regain control.

Kind regards, Eelco

capture of the serial console

hub 2-0:1.0: port 2 disabled by hub (EMI?), re-enabling...
usb 2-2: USB disconnect, address 2
usb 2-2.1: USB disconnect, address 3
hub 2-2:1.0: cannot reset port 1 (err = -71)
hub 2-2:1.0: cannot reset port 1 (err = -19)
hub 2-2:1.0: cannot disable port 1 (err = -19)
hub 2-2:1.0: cannot disable port 1 (err = -19)
sd 0:0:0:0: [sda] Unhandled error code
sd 0:0:0:0: [sda] Result: hostbyte=0x07 driverbyte=0x00
end_request: I/O error, dev sda, sector 313311
sd 0:0:0:0: [sda] Unhandled error code
sd 0:0:0:0: [sda] Result: hostbyte=0x01 driverbyte=0x00
end_request: I/O error, dev sda, sector 313551
FAT: FAT read failed (blocknr 4018)
FAT: FAT read failed (blocknr 4018)
usb 2-2.2: USB disconnect, address 4

And the kernel version reported by the board during startup is:

Angstrom/2.6.29-rcfinal+r2+git90

It is a precompiled binary by Steve.

Kind regards, Eelco

Eelco,

Another thing to check is all the USB cables between Beagle and your
device(s). 480 Mb/s high-speed USB requires high quality cables,
preferably very short. The USB hardware and software should be able
to recover seamlessly from an occasional data error, but the software
may not be completely robust at this time.

Now that you have +5V regulated power for the BeagleBoard power jack
and a powered hub, you might also try using the OTG port to talk to
your hub. It supports all three USB 2.0 speeds. See the BeagleBoard
wiki and FAQ for common problems.

Hope this helps,
John

I have a feeling that you're right, although I use high quality cables
it is worth a try. Can you see anything based on the output I mailed
earlier? I am also trying to compile a new kernel, to see whether that
has some success.

Thank you very much!

Eelco

Hmmm it even gets stranger. When I run Chameleon man for a longer
period (more than 1 minute) USB also shuts down...very strange... I
think it must be some kind of software problem...

Hmmm it even gets stranger. When I run Chameleon man for a longer
period (more than 1 minute) USB also shuts down...very strange... I
think it must be some kind of software problem...

I don't think it is a sw issue. As I mentioned earlier today, I do
not see the issues you describe when using those images on my rev C
beagle or my overo. I just ran ChameleonMan for an hour and
experienced no loss of USB.

You definitely seem to have an problem, but I don't think it is a
fundamental sw issue. I suspect something in your hardware setup.

Steve

Steve,

Installing the rootfs, u-boot and uImage should be enough? You also
put a modules.tgz file on the site. Do I need to do something with
this file as well? I don't see any moduls errors during startup.

regards, Eelco