Possible to use the FLL for USB on the K22F in a pinch?

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

Possible to use the FLL for USB on the K22F in a pinch?

1,064 Views
scottm
Senior Contributor II

I'm using the MK22FN1M0AVLH12, which doesn't have the cystal-less IRC48M option the MK22FN512 does.  (NXP folks: I'd have gone with the newer part if I'd known it was the newer part, but the selection guides don't cover that.)  I know that the FLL is not capable of meeting the USB certification specs for jitter, but my question is whether it can be used successfully with at least a fair degree of reliability.

The target application sometimes takes a lot of physical abuse and occasionally crystals fail.  Occasionally most of the parts can fail, but there's a fair amount of fault-tolerance built in and it'll keep limping along as best it's able.  The crystal is an exception, though, and currently a dead crystal means a dead device.  I've already written code for a semi-related project on a K02 that detects a failed crystal and switches to a trimmed internal clock, but the complication with this one is USB.

It's questionable whether the frequency accuracy of the trimmed internal reference will be good enough if it works at all, and the clock configuration tools won't even allow you to select the FLL as the USB clock source, but I'm not asking if it's a good idea, just if it's likely to have a 50% chance or better of working long enough to get a replacement in place.

Has anyone tried this?  What were your results?

Thanks,

Scott

Labels (1)
0 Kudos
Reply
5 Replies

906 Views
bobpaddock
Senior Contributor III

We switched to MEMs based oscillators to get around the dead crystal problem.
Just don't rely on them anyplace where there is a lot of Helium, which is generally not a problem.

0 Kudos
Reply

906 Views
mjbcswitzerland
Specialist V

Hello Scott

As you are aware the only method to clock the USB in your particular case without an external crystal/oscillator is to use the 32kHz IRC as reference to the FLL and set the FLL factor to give a suitable frequency (eg. 47.972352 is fairly close with a FLL multiplication factor of 1464).
The 32kHz IRC is however not particularly accurate with trimming step, voltage and temperature tolerance meaning that it will generally be (way)out of specification for the USB frequency as well as the USB jitter.

My experience with K22 is:
- 8MHz 120MHz PLL = good USB device
- Part with 48MHz IRC and crystal-less USB device = good USB device
- Part without 48MHz IRC run at 47.97MHz from FLL from 32kHz IRC = NO USB operation (enumeration failure)

However I have "heard" that in some cases FLL from IRC does work but I expect it has a lot to do with luck (voltage, temperature trimming accuracy) but I don't have any idea about the % chance of it working in emergency.

Regards

Mark


Complete Kinetis solutions, training and support: http://www.utasker.com/kinetis.html
Kinetis K22:
- http://www.utasker.com/kinetis/FRDM-K22F.html
- http://www.utasker.com/kinetis/TWR-K22F120M.html
- http://www.utasker.com/kinetis/BLAZE_K22.html
- http://www.utasker.com/kinetis/tinyK22.html

0 Kudos
Reply

906 Views
myke_predko
Senior Contributor III

Hi Mark,

I want to use the MK22 in a USB application and going with the the IRC without a 32.768kHz crystal would be interesting and help maintain the physical robustness of the product.  This would mean IRC for the low speed clock and an 8MHz crystal for the high speed (USB driver).  

Would this be acceptable?  

myke

0 Kudos
Reply

906 Views
mjbcswitzerland
Specialist V

Hi Myke

For USB operation you need to be able to generate a stable and accurate 48MHz clock.
Also, the system clock must be at least 20MHz.

If you can ensure the two then it will be OK.

Regards

Mark

Complete Kinetis solutions for faster/more efficient professional needs, training and support: http://www.utasker.com/kinetis.html
i.MX RT project compatibility: http://www.utasker.com/iMX.html
Including FreeRTOS integration for all Kinetis parts

Kinetis K22:
- http://www.utasker.com/kinetis/FRDM-K22F.html
- http://www.utasker.com/kinetis/TWR-K22F120M.html
- http://www.utasker.com/kinetis/BLAZE_K22.html
- http://www.utasker.com/kinetis/tinyK22.html


uTasker: supporting >1'000 registered Kinetis users get products faster and cheaper to market

Request Free emergency remote desk-top consulting at http://www.utasker.com/services.html

Open Source version at https://github.com/uTasker/uTasker-Kinetis

https://community.nxp.com/thread/512558
https://community.nxp.com/thread/352862
https://community.nxp.com/thread/498809

0 Kudos
Reply

906 Views
scottm
Senior Contributor II

Yeah, I know it's likely to be a stretch to get it to work, but I thought it might be worth a shot.  I think I'll probably just have it ignore USB for now and at least display an error signal, and try its best to keep doing what it's supposed to do.

Thanks,

Scott

0 Kudos
Reply