[uClinux-dev] Can't get Gadget Serial driver to start on Windows XP Pro

Robert S. Grimes rsg at alum.mit.edu
Tue Feb 20 19:25:10 EST 2007


Hi,

I'm developing a uClinux-based device based on the Freescale MCF532x, 
which has integral USB device peripheral.  The device will interface 
with a host computer via USB.  The communications protocol is quite 
simple, and for ease of use from the host computer's viewpoint, it would 
be great if my device looks like a serial port.  It would be really 
fantastic if it looked like a USB/serial port adapter, such that the 
host computer (Windoze, Linux, Mac, whatever) could "borrow" a suitable 
driver, at least initially. 

So I found the Gadget Serial (see 
linux-2.6.x/Documentation/usb/gadget_serial.txt) and am attempting to 
use it.  I am currently using the M5329EVB board from Freescale/LogicPD, 
uClinux-dist-20070130.tar.bz2 with some patches from a Freescale AppNote 
(AN3408.pdf).  I _think_ I've got the configuration for the kernel 
correct, and everything builds okay.  Here is part of the console output:

    USB-MCF532x: (HOST module) EHCI device is registered
    USB-MCF532x: (OTG module) EHCI device is registered
    USB-MCF532x: (OTG module) UDC device is registered
    SCSI subsystem initialized
    usbcore: registered new driver usbfs
    usbcore: registered new driver hub
    ...
    usbmon: debugfs is not available
    MCF532x USB EHCI: is found. ID=0x5 Rev=0x41
    ehci ehci.1: EHCI Host Controller
    ehci ehci.1: new USB bus registered, assigned bus number 1
    ehci ehci.1: irq 176, io mem 0xfc0b4000
    ehci ehci.1: USB 0.0 started, EHCI 1.00, driver 10 Dec 2004
    usb usb1: Product: EHCI Host Controller
    usb usb1: Manufacturer: uClinux 2.6.17.1 ehci_hcd
    usb usb1: SerialNumber: ehci.1
    usb usb1: configuration #1 chosen from 1 choice
    hub 1-0:1.0: USB hub found
    hub 1-0:1.0: 1 port detected
    MCF532x USB EHCI: is found. ID=0x5 Rev=0x41
    ehci ehci.0: EHCI Host Controller
    ehci ehci.0: new USB bus registered, assigned bus number 2
    ehci ehci.0: irq 175, io mem 0xfc0b0000
    ehci ehci.0: USB 0.0 started, EHCI 1.00, driver 10 Dec 2004
    usb usb2: Product: EHCI Host Controller
    usb usb2: Manufacturer: uClinux 2.6.17.1 ehci_hcd
    usb usb2: SerialNumber: ehci.0
    usb usb2: configuration #1 chosen from 1 choice
    hub 2-0:1.0: USB hub found
    hub 2-0:1.0: 1 port detected
    ehci-mcf532x: No external transceiver!
    Initializing USB Mass Storage driver...
    usbcore: registered new driver usb-storage
    USB Mass Storage support registered.
    udc: Freescale MCF532x UDC driver version 27 October 2006 init
    udc: No external transceiver!
    udc: MCF532x USB Device is found. ID=0x5 Rev=0x41
    gs_bind: Gadget Serial v2.0 bound
    udc: mcf532x_udc: mcf532x_udc bind to driver g_serial
    gs_module_init: Gadget Serial v2.0 loaded
    ...
    Sash command shell (version 1.1.1)
    /> <4> ehci.0: Unlink after no-IRQ?  Controller is probably using
    the wrong IRQ.

When I connect the M5329EVB to my Windows XP host computer, the latter 
detects the "Gadget Serial" device, and installs the driver.  Note that 
in order to get this far, I had to change the following lines in the 
.inf file from the documentation from:

    [GSerialDeviceList]
    %GSERIAL%=GSerialInstall, USB\VID_0525&PID_A4A7

to

    [GSerialDeviceList]
    %GSERIAL%=GSerialInstall, USB\VID_0525&PID_A4A6

Anyway, the following is output on the uClinux console:

    gs_disconnect: Gadget Serial disconnected
    gs_disconnect: Gadget Serial disconnected
    gs_set_config: Gadget Serial configured, full speed BULK config

Which seems it is happy.  However, on the Windows host I get an error, 
stating that "This device cannot start. (Code 10)".  I seem to be so 
close, but I'm not sure where to go from here.  Any ideas?!

Thanks,
-Bob


More information about the uClinux-dev mailing list