1
\$\begingroup\$

Disclaimer: I am programmer and when it comes to analog circuits I have no idea what I am doing.

I have a board with STM32F103 that uses external oscillator made by crystal and two capacitors:

current schema

The crystal is CD05M008000RD1 / 49SMD-8-20-20 described as 8Mhz, 20pF, 20ppm, ESR 60Ohm.

Everything seems to be working fine, but I am trying to reduce the board size and the crystal is rather big. I am looking for either smaller crystal or a complete oscillator in small package.

I found for example this: O 8,0-JO32-B-1V3-1-T1-LF described as XTAL OSC XO 8MHZ HCMOS SMD, 50ppm.

Can I use it so that it will look like this?

enter image description here

I see that it is less precise (20ppm vs 50ppm), but for my use-case it should be well within the limit. It is still way better than the internal oscillator. Are there any other differences that I am not seeing?

\$\endgroup\$
  • 2
    \$\begingroup\$ You are asking to replace an oscillator with a CLOCK IC, not an oscillator IC. If the MCU has registers that can change the oscillator input to be a clock input then, yes. I'm not aware of any STM32F that don't but you should check since your pin names of PD0 for the clock in pin seems a bit odd. \$\endgroup\$ – DKNguyen Jan 8 at 17:11
  • 2
    \$\begingroup\$ What does the STM32F103 datasheet say about using an external oscillator instead of a crystal? \$\endgroup\$ – The Photon Jan 8 at 17:11
  • \$\begingroup\$ It says both are possible, use capacitors in range 5 to 25 pF matching the crystal's requirements, etc etc. I know I can use some external oscillator, but I wonder what to look for when picking one. \$\endgroup\$ – michalsrb Jan 8 at 17:18
  • 1
    \$\begingroup\$ @michalsrb Again, not an external oscillator. An external clock. There's a difference. An oscillator is no more a clock than an engine is a car. It is easier to pick an external clock than it is to pick an external crystal/oscillator. CMOS output should be fine. The MCU is just expecting a regular digital square wave if it is an external clock. Nothing fancy. \$\endgroup\$ – DKNguyen Jan 8 at 17:26
  • 1
    \$\begingroup\$ also, what's your application? If it's something that doesn't need a good time / frequency standard, what's stopping you from not having any oscillator or external clock at all? I think all STM32 have internal RC oscillators that you can use instead. \$\endgroup\$ – Marcus Müller Jan 8 at 17:50
3
\$\begingroup\$

From the datasheet both types can be used. Just select the type in FW.

enter image description here

enter image description here

| improve this answer | |
\$\endgroup\$
  • \$\begingroup\$ In general, the oscillators with 8 MHz output should work, as long as the output square wave fits into the specification (CMOS output) and it is fed to OSC_IN pin, and the STM32 firmware is modified to select external square wave clock input instead of the external crystal. \$\endgroup\$ – Justme Jan 8 at 20:01
1
\$\begingroup\$

You can find 3.2 x 2.5mm crystals https://www.digikey.com/products/en/crystals-oscillators-resonators/crystals/171?k=crystal&k=&pkeyword=crystal&sv=0&pv46=10964&sf=1&FV=1989%7C0%2Cmu8MHz%7C2150%2C-8%7C171%2C69%7C409393&quantity=&ColumnSort=0&page=1&stock=1&pageSize=25

Surely that and two 0402 caps are smaller than an oscillator that you also have to run power to? I stand corrected - you can find 8 MHz oscillators that are 1.6 x 1.2mm! https://www.digikey.com/products/en/crystals-oscillators-resonators/oscillators/172?k=oscillator&k=&pkeyword=oscillator&sv=0&pv46=7836&sf=1&FV=1989%7C0%2Cmu8MHz%7C2150%2C-8%7C172%2C276%7C174115&quantity=&ColumnSort=0&page=1&stock=1&pageSize=25

Are those small enough for you?

| improve this answer | |
\$\endgroup\$
  • \$\begingroup\$ Amazingly small. So those should work fine in my case as well? \$\endgroup\$ – michalsrb Jan 8 at 18:17
  • \$\begingroup\$ I would expect it to. \$\endgroup\$ – CrossRoads Jan 8 at 19:07
  • \$\begingroup\$ Small crystals tend to have larger ESR than large crystals, so you really have to look at the crystal parameters, and STM32 HSE oscillator parameters, and do the math explained in STM32 crystal application note to find out if the crystal is suitable or not. This is not a problem with the oscillators that output square wave to STM32. \$\endgroup\$ – Justme Jan 8 at 19:58
0
\$\begingroup\$

Are you prepared to learn all the details of Xtal Osc (XO) tuning and uW power limitations and Q and Xtal temperature curves ,range and PPM for temp, PPM for initial tolerance and PPM for C variations and design error?

If not use the SMD XO (Standard). It will probably be more accurate, very tiny and can be tunable(VCXO), temperature compensated (TCXO) or both (TCVCXO) or programmable, etc. and low cost but maybe not cheapest in high volume.

Your discrete design could have more tolerance stackup:

  • 20 ppm for ΔTmax=?, or more?
  • 20 ppm @ 25'C
  • 20~50ppm for C load design error & other tolerances.

Since all AT cut Xtals have different 3rd order temp curves , the ppm temp tolerance depends greatly on ΔTmax e.g. -25 ~40'C vs -40~70'C

You have a choice of temp range and ppm tolerance. vs cost vs volume.

| improve this answer | |
\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.