Crystal External Capacitor Value with XMega

Discussion in 'Embedded Systems and Microcontrollers' started by klangst, Feb 20, 2015.

  1. klangst

    Thread Starter Member

    Jul 5, 2013
    I am learning to use the ATXMega128A4U and would like to use the internal 32MHz oscillator with an external 32.768kHz crystal. Per the Xmega datasheet:

    The Low-frequency Crystal Oscillator is optimized for use with a 32.768 kHz watch crystal. When selecting crystals, load capacitance and crystal’s Equivalent SeriesResistance, ESR must be taken into consideration. Both values are specified by the crystal vendor.
    XMEGA oscillator is optimized for very low power consumption, and thus when selecting crystals, see Table 4-3 for maximum ESR recommendations on 9 pF and 12.5 pF crystals.
    The Low-frequency Crystal Oscillator provides an internal load capacitance of typical 8.0 pF. Crystals with recommended 8.0 pF load capacitance can be without external capacitors as shown in Figure 4-3.
    Crystals specifying load capacitance (CL) higher than 8.0 pF, require external capacitors applied as described in Figure 4-4.

    Since my crystal is listed with a Load Capacitance of 20pF, is that the value of capacitors I should use on TOSC1 and TOSC2 pins?
  2. shteii01

    AAC Fanatic!

    Feb 19, 2010
    According to that the crystal will see the Input Capacitance (CI) and Parasitic Capacitance (CP). Those two start at about 5 pF, but we live in imperfect world, so they are likely a little more than that... say... 8 pF. So. Since you already have about 8 pF, you don't need Load Capacitors (CL).

    I would say try both cases. Since your frequency is so small. Try it without CL and try it with CL. If you find that the device works well without CL, then you just got two caps in your tool box. Some day you will likely do something that has MHz range frequency and you will need those caps, anyway.
  3. klangst

    Thread Starter Member

    Jul 5, 2013
    Thank you, that article gives a great explanation. Just what I needed.