Issue with USB CDC using USB hub and OSX

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Issue with USB CDC using USB hub and OSX

2,855 Views
danielg14
Contributor I

Hi!

I have a K20 acting as a USB CDC device. Everything seemed to be working fine with it, until I tried connecting it to a Mac via an external USB hub. OSX (El Capitan) tries to enumerate the device but fails.

If I connect the device directly to a USB port on the Mac then everything works fine. But once I connect it to a hub, it no longer enumerates the device. I tried this will multiple hubs, connecting them to different USB ports on the MAC and it fails the same way each time.

This does not happen on a computer running Windows.

The error reported by OSX are:

6/20/16 5:39:25.000 PM kernel[0]: 016417.677052 IOUSBHostDevice@fd340000: IOUSBHostDevice::start: device descriptor request completed with 0xe00002e8 and bytesTransferred 0

6/20/16 5:39:25.000 PM kernel[0]: 016417.677259 AppleUSB20HubPort@fd340000: AppleUSB20HubPort::resetAndCreateDevice: failed to start device

6/20/16 5:39:25.000 PM kernel[0]: 016417.677262 AppleUSB20HubPort@fd340000: AppleUSB20HubPort::resetAndCreateDevice: failed to create device (0xe00002e9), disabling port

6/20/16 5:39:25.000 PM kernel[0]: 016417.677561 AppleUSB20HubPort@fd340000: AppleUSBHostPort::disconnect: persistent enumeration failures

I debugged the device and determined that the host requests the address to change, which it then does, and then it asks it for the first eight bytes of the device descriptor, which get sent. After that no more transaction between the host and the device occur.

Does anyone have any idea what might caught this strange activity?

Labels (2)
0 Kudos
3 Replies

1,042 Views
isaacavila
NXP Employee
NXP Employee

Hello,

Have you taken an USB capture using a sniffer?

It seems to be related to HUB problems on OSX rather than device's side. Have you tried connecting other USB devices (like MSD or any HID) to OSX through this same HUB?

Regards,

Isaac

0 Kudos

1,042 Views
danielg14
Contributor I

I haven't connected a sniffer, but I have run the device in debug mode with some debug code I wrote to capture all communication between the USB host and the device. It resets the device, changes the address, and then asks for 8 bytes of the device descriptor, then it never does anything after that. When I connected the device directly to a port on the Mac, it starts with those same first three events, but then continues to enumerate the device.

I have connected other devices to the hub and all of them work, I even connected a freescale dev board to the hub and that was enumerated successfully.

0 Kudos

1,042 Views
isaacavila
NXP Employee
NXP Employee

Hello Daniel,

I tested on OS X Yosemite (Version 10.10.3) by connecting a FRDM-K64F CDC device (running dev_cdc_vcom_bm_frdmk64f example from KSDK 2.0) directly and it worked well (as already tested).

Then I connected two HUBs (one High Speed and other Full Speed). In both cases device could run correctly (although in the HS HUB I had some problems to capture the enumeration process on the USB sniffer while in FS HUB, enumeration process was captured correctly)

If you have tested this same HUB and Device on a Windows PC and it worked well, then it is probably an OSX problem instead of device's.

Regards,

Isaac

0 Kudos