Sam Duff

imx28 USB OTG, are the drivers fully implemented?!

Discussion created by Sam Duff on Jan 17, 2012

I'm developing a device which needs to have an USB OTG port, which can switch between host or device  on the fly.  At the moment I can only get the USB0 port to operate as a host or device, not both.  I can't find any examples of anyone actually getting this to work.

I think I've narrowed the problem down to the usb device driver fsl-usb2-udc (drivers/usb/gadget/fsl_udc_core.c), which when configured as OTG does not ever detect being connected to a host.  If I configure that driver as device only, it works ok, although it still doesn't actually detect the connect/disconnect.

Chris Sawran mentions here that vbus sensing is not actually implemented.

I've had to modify mxs-usbphy.c to be able to load both fsl-usb2-udc and ehci-hcd at the same time - previously it caused crashes or one of the initialisations would fail.

Has anyone been able to get USB OTG working properly?