How to set up clock for crystal-less USB on MK20DX128VFM5 ?

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

How to set up clock for crystal-less USB on MK20DX128VFM5 ?

Jump to solution
883 Views
bsder
Contributor I

I've been trying to create a non-OS (barebones) crystal-less USB CDC echo example for the K20 series.  None of the pre-made demo projects seem to do that (if there is one that I missed--please ship me a pointer as it will save me a lot of grief).

I can't seem to find the right magic combination of system clock and USB clock configuration options in order to make Processor Expert in the Kinetis Design Studio happy.

Does anybody have some pointers or suggestions?

Thanks.

Keywords: crystal-less crystalless MK20DX128

0 Kudos
1 Solution
605 Views
BlackNight
NXP Employee
NXP Employee

Hi Andrew,

the K20 is not made for crystal-less USB operations. I doubt it will work. And if it works, then only for low speed, and probably not reliable at all. It will greatly depend on your room temperature, as the internal clock is not accurate enough.

Anyway, if you want to try it out: I have a pointer for you how to do it with crystal: http://mcuoneclipse.com/2012/10/07/tutorial-usb-cdc-with-the-kl25z-freedom-board/

For crystal-less operation use the internal clock (FLL mode) and get a FLL clock as close as possible to 48 MHz, then route this to the USB module (same as above example which uses the PLL).

Good luck!

Erich

View solution in original post

0 Kudos
4 Replies
606 Views
BlackNight
NXP Employee
NXP Employee

Hi Andrew,

the K20 is not made for crystal-less USB operations. I doubt it will work. And if it works, then only for low speed, and probably not reliable at all. It will greatly depend on your room temperature, as the internal clock is not accurate enough.

Anyway, if you want to try it out: I have a pointer for you how to do it with crystal: http://mcuoneclipse.com/2012/10/07/tutorial-usb-cdc-with-the-kl25z-freedom-board/

For crystal-less operation use the internal clock (FLL mode) and get a FLL clock as close as possible to 48 MHz, then route this to the USB module (same as above example which uses the PLL).

Good luck!

Erich

0 Kudos
605 Views
bsder
Contributor I

Oh, that's just lovely.  The marketing materials or product selector tool could do with pointing out that only specific K2x lines run crystal-less.  Looks like I'm haywiring a crystal.

So, I can get USB crystal-less operation on a Kinetis that I can only use when I already have room for a crystal since the chip itself takes up a huge chunk of board area.  However, the pin constrained, small form factor package requires a crystal for USB.

That's kinda bass-ackwards.

Anyway, sorry for the rant and thanks for tolerating the n00b.  Also, thanks for the answer.  Again.

0 Kudos
605 Views
BlackNight
NXP Employee
NXP Employee

Hi Andrew,

there are now new crystal-less devices from Freescale available, see http://blogs.freescale.com/mcus/2014/10/crystal-clear-benefits-of-crystal-less-usb-mcus/

But that only applies to some new devices.

Erich

0 Kudos
605 Views
bsder
Contributor I

Unfortunately, all those devices are very large in terms of package (64-TQFP or bigger).

The K22_100 is a 64-QFP (quad flat pack) at smallest.  The K24_100 is a 100-QFP at smallest.  The K63 is 144-QFP and the K64 is 100-QFP.

The K20 I was using was a 32-pin QFN, and I barely had room for that.  I'll figure out a place to tuck a crystal, somewhere.  That will still be far smaller than jumping to a TQFP-64.

0 Kudos