Why do we need external capacitors on crystal?

Why do we need external capacitors on crystal?

Take the case of micro controller where you have option of using either external and internal crystal for clocking. We in many applications use external crystals. We might have used external capacitors for a crystal used in such an application. The below figure also shows the same.


We always follow the datasheet of micro controller to find the value of external capacitor (C1, C2 in above figure). The datasheet clearly mentions value of capacitor to be used for specific crystal frequency. 

Following are some facts about these capacitors:
  • Ceramic caps are preferred for these capacitors as they are stable (with temperature variations)
  • Even though the capacitors look like parallel connected, they are connected in series.
  • XTAL1, XTAL2 pins in above circuit are input and output pins respectively. Some controllers/processors specify them as XTALIN and XTALOUT.
  • These capacitors along with crystal form a band pass filter and are crucial in crystal performance. This filter circuit provides 180 deg phase shift.
  • These capacitors provide protection against stray signals and helps to get stabilized crystal frequency
  • There is slight variation in frequency because of this capacitors. A crystal generates gives out a frequency slight away from the specification and adding these capacitors helps getting stabilized frequency. However, in applications, that doesn't require much stability users tend to ignore this.
  • If you use a very high value of capacitor instead of specified value, response time increases for crystal.
Below is the capacitance values mentioned in a micro controller (PIC16F777) datasheet as per frequency:


If not mentioned in data sheet, you have to manually calculate the capacitance value using the below formula:

                         Load capacitance = Stray capacitance + Pin capacitance + [(C1 * C2)/(C1+C2)]

Load capacitance - You get from the crystal data sheet
Stray capacitance - PCB capacitance
Pin Capacitance - Micro controller pin capacitance
C1, C2 are connected in series, so, the parallel formula used for calculating effective capacitance

The main problem with the above formula comes only with approximation of PCB capacitance which can't be determined accurately. So, the estimation may go wrong sometimes.

Most of these CMOS digital circuits are clocked by pierce oscillator shown in the diagram below:

Post a Comment

1 Comments

  1. Hi,

    I would like to let you know that we are selling high PR Tumblr blogs.
    I think as a webmaster, you know the importance
    of having backlinks from high PR blogs. And you also know
    how costly it can be to have backlinks to this high PR blogs.


    Well I would like to inivte you and take a look at our offer.
    At very cheap price, you can have your own high PR Tumblr were you can use as
    backlinks to your site.

    If your interested, please visit: http://bit.ly/highprtumblr

    Thanks

    Feel free to visit my web site :: Cheap High PR Tumblr Blogs

    ReplyDelete