Hello,
Issue with host mode on USB OTG controller
I am running Linux on a AM3352 and the USB controller is supposed to be a OTG. However, I only have the USB running as peripheral so far.
I followed the kernel configuration on the "AM335X USB Driver User Guide".
However checking the files "/proc/driver/musb_hdrc.X" does not seem to be promising
# cat /proc/driver/musb_hdrc.0
Status: MHDRC, Mode=Peripheral (Power=e0, DevCtl=80)
OTG state: b_idle; inactive
Options: ?dma?, otg (peripheral+host), [eps=16]
...
# cat /proc/driver/musb_hdrc.1
Status: MHDRC, Mode=Peripheral (Power=60, DevCtl=5d)
OTG state: a_idle; inactive
Options: ?dma?, otg (peripheral+host), [eps=16]
...
Since the "state" changes (it did switch to UNDEFINED or "b_idle" but never shows "b_host" or so), I guess that the "mode" should show something like "OTG".
Plugging in a thumb drive does not show show up in the message buffer at all. We are using a special USB Mini-B cable for OTG and I checked that pins 4 and 5 are short-circuited.
While writing this post, I've just found out that there is a "mode" setting in quite a few source files which probably should be set to MUSB_OTG in our case.
Unfortunately I am not yet sure about which files are relevant for our hardware environment, but I've seen that some do have "MUSB_PERIPHERAL" set. I will update the post as soon as I know more.
In case the source files are correct - could it also be a hardware issue that causes the mode is displayed as "peripheral"?
OTG and switching between host/peripheral
In this thread (well the hyperlink here gets transformed to a picture tha I can't remove anymore...) I have seen there seems to be a difference between running the USB controller as "OTG" and as "switching between peripheral/host".
Could you please tell me the difference? For me that was the same so far...OTG is supposed to switch between states "peripheral" and "host".
Thanks four your help in advance!