I am having a crystal issue with my microcontroller which is an ATmega32U4. Also if you are wondering why I don't just use the internal oscillator, it is because I need to track times with this PCB as I am trying to make a watch for running.

Either way, I am using an 8 MHz crystal for my PCB, but I believe the crystal isn't working because it wouldn't progress any cycles until I messed with the crystal pins with a multimeter. I believe it has something to do with the capacitors I have hooked up to it and I want to confirm it.

I was using 22pF capacitors on my previous versions, but after looking into more math I believe that 43pF capacitors would be a better choice. Here is the crystal I am using (datasheet).

On a previous PCB I was using a 16MHZ capacitor(link) with a 9pF load capacitance with 22pF capacitors and it ran fine. The current PCB has a 8MHZ capacitor with a 20pF load capacitance and 22pF capacitors as well, but it doesn't run. Another difference was the fact that I was using a SMD crystal instead of a through hole, but I wanted to solder the crystal in so I swapped to a through hole design. The PCB I am working on right now is also a really dense compared to my previous project which had plenty of space to spare.

Here is also a basic picture of the PCB layout:enter image description here

  • \$\begingroup\$ What does your physical layout look like? Not a breadboard I hope ... ? \$\endgroup\$
    – brhans
    Commented Apr 25, 2021 at 1:54
  • \$\begingroup\$ I am using a PCB if that answers anything? \$\endgroup\$
    – user29946
    Commented Apr 25, 2021 at 1:55
  • \$\begingroup\$ @user29946 - Hi, Can you edit the question to add some photos of the actual hardware and the PCB layout in the relevant areas, as that might allow members to see something that isn't obvious from the text description alone? If the previous version worked, then what has changed between the two versions? Only the crystal? Or PCB layout too? Anything else? \$\endgroup\$
    – SamGibson
    Commented Apr 25, 2021 at 2:06
  • \$\begingroup\$ Ok made the changes to the post, hopefully it helps! \$\endgroup\$
    – user29946
    Commented Apr 25, 2021 at 2:12
  • 2
    \$\begingroup\$ @user29946 - Thanks. To be honest with (it looks like) all layers visible, I'm struggling to follow the tracks to the xtal. It looks like C1 & C2 are the load caps, and you seem to have other traces close to, and under, the xtal, which concerns me. But as I said, some layers e.g. the silkscreen and outline layers, are making it difficult to see the tracks. Perhaps other people have better eyesight and can eliminate the layout as a problem. When you get a chance, it may help if you can update the question about "what changed" between the old, working & the newer, non-working designs. Thanks \$\endgroup\$
    – SamGibson
    Commented Apr 25, 2021 at 2:23

1 Answer 1


Those are 20pF load crystals so you would typically use something like 33pF or 36pF assuming a stray capacitance of a few pF, however Atmel/Microchip does not recommend more than 22pF (or less than 12pF) capacitance so you should choose a crystal with a lower load capacitance (eg. 7pF).

However, with your existing crystal it should start and run okay with 22pF capacitors, but run a bit faster than nominal. If it is not, probably something else is wrong.

  • \$\begingroup\$ My current crystal is not running with 22pF capacitors, so it might be something else. However, on a previous PCB I made I put in a 16MHZ crystal with a load capacitance of 9pF and that board ran fine, so it might be the higher load capacitance. \$\endgroup\$
    – user29946
    Commented Apr 25, 2021 at 2:05
  • \$\begingroup\$ Is it many samples or is it possible you have a damaged crystal (or MCU)? \$\endgroup\$ Commented Apr 25, 2021 at 2:15
  • 1
    \$\begingroup\$ It has been through many samples of my PCB, so probably a design issue \$\endgroup\$
    – user29946
    Commented Apr 25, 2021 at 2:17
  • \$\begingroup\$ If you don’t know how to design and layout a crystal oscillator with stray and input caps and want accuracy, then specify the max error per year,month,day or in ppm with temp range or use a TCXO with <=2ppm \$\endgroup\$ Commented Apr 25, 2021 at 2:40
  • \$\begingroup\$ Is this a TCXO?(link) I used this in a previous design and it ran fine with 22pF capacitors, but I am running on 3.3V now so I have to use 8MHZ \$\endgroup\$
    – user29946
    Commented Apr 25, 2021 at 2:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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