Custom Teensy LC -- Selecting an appropriate crystal oscillator

Status
Not open for further replies.

yeahtuna

Well-known member
Hi,

I'd like to say thank-you for all the help I've gotten from the community here. Constantin and others have been so kind as to guide me along though the world of building custom Teensy devices. So far I've taken shipment of two custom Teensy 3.2 devices, and now I'm focusing on a third device based on the Teensy LC. Like the LC, I'm trying to make this custom device a low cost solution.

My fab recommends using a crystal that's produced locally and for which they can get a good price, but I have no idea how to determine if it is suitable. I know there are specs like the stability to consider, but I have no idea of how it affects the operation of the MCU. Can anyone enlighten me?

The crystal they are recommending is a CXA-016000-2ECC40. I have built a working prototype using that crystal, so it seems fine, but I don't know how I should be testing it, and I need more information to feel confident that issues won't arise long term.

Thanks in advance for any insight you have to offer,
Rob
 
Not an expert on the topic, but my understanding with the crystals is first that they have the right impedance to match your driver, which appears to be the case and second that they may have different temperature stability in terms of frequency. You probably should compare the data sheets, but a sanity test if you have a working prototype is to run some code that measures time as seen by the CPU (say toggling pin 13 every 100ms) and then put it in a box that you can heat/cool across the worst case temperature range for your product and use the best precision time measurement you can from outside the box to see how much the clock drifts, and if at some point the code actually halts.

Once you have some actual numbers you can think about what your device does and how much your worst case clock errors actually mean (audio sampling rates, data clocks, USB coms etc). Obviously this is only one data point but will at least tell you if your read the data sheet right.

You may also find the spread of frequencies a large sample of these good price crystals is broad. The above thought process will also tell you how much a worst case crystal will throw your code out by, and possibly any QC steps you need to identify the outliers and bin them. There is also some clock trimming registers that may give you an option to either use a temp sensor to adjust on the fly, or just to tweak any edge case crystals at build to run at your target frequency if you find problems with your prototype.
 
Hi,

Thank-you so much. That's exactly what I was after. Your post really got me thinking in the right way. Spot on. Cheers.

Rob
 
Status
Not open for further replies.
Back
Top