Author Topic: Device failed enumeration on certain PC chipsets?  (Read 4916 times)

Cheshyr

  • Member
  • ***
  • Posts: 5
Device failed enumeration on certain PC chipsets?
« on: July 06, 2017, 12:39:38 am »
I have an embedded MCU (freescale K70) operating in device mode as a CDC interface. It works fine on most PCs and every embedded target I've tried. However, it appears specific chipsets (Intel 6 C200 for example) don't request the initial descriptor properly, unless I pass it through a hub first.

We're adding a hub to our device, but has anyone seen this? Would really prefer not to add the cost and complexity, and I'm not certain how to go about troubleshooting this.

bpaddock

  • Frequent Contributor
  • ****
  • Posts: 66
Re: Device failed enumeration on certain PC chipsets?
« Reply #1 on: July 06, 2017, 07:41:30 am »
Quote
freescale K70) operating in device mode as a CDC interface.

Which specific stack are you using?  The one released with KDS 3.2 seems to have the fewest bugs.

There is also: https://www.nxp.com/webapp/sps/download/license.jsp?colCode=USB_STACK_V5.0&appType=file1&location=null&DOWNLOAD_ID=null

I'm in the process of writing my own bare metal version for the KL25/26/27 to get away from the Freescale/NXP issues.
I expect the K70 still uses the same ColdFire V1 based core as the above.

I have experienced problems where embedded device would work fine with a Intel hub in a PC and would not work with an NEC hub chipset in the same PC. :-(


Cheshyr

  • Member
  • ***
  • Posts: 5
Re: Device failed enumeration on certain PC chipsets?
« Reply #2 on: July 06, 2017, 07:59:18 am »
MQX 4.2 in the Codewarrior environment, specifically because we're using PEG. Migrating to KDS would be a bit troublesome.

We've used the ColdFire 52259  with no issue, but that's a V2 core. Didn't realize the first round Kinetis chips were using V1.

I'll post a set of traces shortly. It's like the K70 doesn't recognize the attach.

Cheshyr

  • Member
  • ***
  • Posts: 5
Re: Device failed enumeration on certain PC chipsets?
« Reply #3 on: July 06, 2017, 09:40:24 am »
I've attached a connection trace. The K70 is powered on at the start. I attach to a Intel 6 C200 PC at around 2 seconds. I see the initial attempt to set up, but after 4 retries (Tra 3-5, 95-97, 183-185, 276-278), it stops trying.  I unplug, then reattach to the same USB port on the samePC, this time through a cheap unpowered hub.  Immediate, correct enumeration and driver install.

The problem is, I also get immediate correct enumeration on others PCs without the hub.  It's only these earlier Intel 6 and Intel 7 chipsets that cause problems.  If I could force the K70 to push out the descriptor data, or something...  I don't mind a sloppy polling method at this point. Just want it to work without extra hardware.  Unfortunately, the K70 USB module doesn't give you many levers to adjust; you're just expected to respond to the hardware events.  If it can't see the hardware events, I'm at a loss.

ftp://ftp.neutronicsinc.com/usb_problem.jpg
ftp://ftp.neutronicsinc.com/usb_problem2.jpg

edit:  The PC sees the attach, and attempts to talk ot the K70, but for whatever reason, the K70 doesn't see the attempt, and doesn't respond. Any ideas on how to trick the K70 into responding?
« Last Edit: July 06, 2017, 09:52:53 am by Cheshyr »

bpaddock

  • Frequent Contributor
  • ****
  • Posts: 66
Re: Device failed enumeration on certain PC chipsets?
« Reply #4 on: July 06, 2017, 10:57:09 am »
What is the actual clock source for the USB module?

Many of the Freescale/NXP parts fail the USB  jitter certification from PLL phase noise.

Perhaps the C200 is more sensitive and the external hub cleans that up?

Are the USB error interrupts enabled that might shed some light?


Cheshyr

  • Member
  • ***
  • Posts: 5
Re: Device failed enumeration on certain PC chipsets?
« Reply #5 on: July 06, 2017, 11:17:33 am »
I did think about clock, so we tried 4 different crystals and clocks at various PPM.  None made a difference, so we're back to a 50MHz 50PPM oscillator driving a 120MHz part.

The USB Error interrupts are enabled; I'll see if anything turns up there.

bpaddock

  • Frequent Contributor
  • ****
  • Posts: 66
Re: Device failed enumeration on certain PC chipsets?
« Reply #6 on: July 06, 2017, 01:27:55 pm »
Would not happen to have a 48 MHz part rather than 50?
It is a multiple of 12.

Cheshyr

  • Member
  • ***
  • Posts: 5
Re: Device failed enumeration on certain PC chipsets?
« Reply #7 on: July 06, 2017, 02:11:06 pm »
Reference design was also 50MHz, internally divided to the appropriate values, but I can pick up a 48Mhz, and adjust all the internal clocks. I'm dubious, since it appears to be an MCU receive problem, not a PC receive problem, but anything is worth a shot.
« Last Edit: July 06, 2017, 02:16:10 pm by Cheshyr »