Home >> NEWS >> News >> What is a crystal oscillator? How to layout a crystal oscillator on a PCB board?
What is a crystal oscillator? How to layout a crystal oscillator on a PCB board?
Release time: 2022-02-14
Crystal oscillator is a key element in digital circuit design. Usually, in circuit design, crystal oscillator is regarded as the heart part of digital circuits. All the work of digital circuits cannot be separated from clock signals, and crystal oscillator happens to be the key button that directly controls the normal startup of the entire system. It can be said that if there is a digital circuit design, crystal oscillator can be seen.
1、 Definition of crystal oscillator
Crystal oscillator generally refers to two types: quartz crystal oscillator and quartz crystal resonator, and can also be directly called crystal oscillator. They are all made using the piezoelectric effect of quartz crystals.
Its working principle is as follows: when an electric field is applied to the two electrodes of a crystal, the crystal will undergo mechanical deformation. Conversely, if mechanical pressure is applied to both ends of the crystal, the crystal will generate an electric field again. This phenomenon is reversible, so by utilizing the characteristic of crystals and applying an alternating voltage at both ends of the crystal, the chip will produce mechanical vibration and an alternating electric field. However, the vibrations and electric fields generated by crystals are generally small, but at a specific frequency, the amplitude will significantly increase, similar to the LC circuit resonance that circuit designers often see.
2、 Classification of crystal oscillators
① Passive crystal oscillator
Passive crystal oscillators are crystals, usually 2-pin non-polar devices (some passive crystal oscillators have fixed pins without polarity).
Passive crystal oscillators generally require clock circuits formed by load capacitors to generate oscillation signals (sine wave signals).
② Active crystal oscillator
An active crystal oscillator is an oscillator, typically consisting of 4 pins. Active crystal oscillators do not require an internal oscillator of the CPU and generate square wave signals. An active crystal oscillator can generate a clock signal when powered.
Active crystal oscillators have stable signals, good quality, and relatively simple connection methods. They have smaller accuracy errors and are more expensive than passive crystal oscillators.
3、 Equivalent circuit of crystal oscillator
In fact, the function of a crystal oscillator is like a series RLC circuit.
The equivalent circuit of the crystal oscillator shows a series RLC circuit, representing the mechanical vibration of the crystal oscillator, and parallel connection with a capacitor represents the electrical connection with the crystal oscillator, and the crystal oscillator operates towards series resonance.
Among them, R is the ESR equivalent series resistance, L and C are the equivalent inductance and capacitance, respectively, and Cp is the parasitic capacitance.
4、 Basic parameters of crystal oscillator
The basic parameters of a general crystal oscillator include operating temperature, precision value, matching capacitance, packaging form, core frequency, etc.
The core frequency of a crystal oscillator: The choice of crystal oscillator frequency generally depends on the requirements of the frequency components, such as MCU, which is generally within a range, mostly ranging from 4M to tens of M.
The accuracy of crystal oscillators: The accuracy of crystal oscillators is generally within ± 5PPM, ± 10PPM, ± 20PPM, ± 50PPM, etc. High precision clock chips are generally within ± 5PPM, and generally around ± 20PPM is selected for use.
Matching capacitance of crystal oscillator: Usually, the core frequency of the crystal oscillator can be changed by adjusting the value of the matching capacitance. Currently, this method is used to adjust high-precision crystal oscillators.
5、 Design layout of crystal oscillator on PCB board
As the heart of digital circuits, crystal oscillators affect the stability of the entire system, and the choice of crystal oscillators determines the success or failure of digital circuits.
Due to the presence of quartz crystals inside the crystal oscillator, external impacts and other factors can cause crystal breakage, which can easily lead to the oscillator not oscillating. Therefore, in circuit design, reliable installation of the crystal oscillator should be considered, and its position should not be close to the board edge, equipment casing, or other places as much as possible. When PCB is used for crystal oscillator layout, the following points are usually noted:
① The crystal oscillator should not be too close to the edge of the board, and the outer shell of the crystal oscillator must be grounded, otherwise it may cause radiation noise from the crystal oscillator.
This is particularly important when designing the board. Grounding the casing can prevent the crystal oscillator from radiating outward and also shield the interference of external signals on the crystal oscillator. If it must be arranged at the edge of the PCB, an additional GND line can be placed on the printed line edge of the crystal oscillator, and a through-hole can be drilled at a certain distance on the grounding line to surround the crystal oscillator.
② Signal lines should not be placed below the crystal oscillator, otherwise it may cause harmonic noise coupling between the signal lines and the crystal oscillator.
Ensure complete flooring and avoid wiring within the 300mil range of the crystal oscillator to prevent interference with the performance of other wiring, components, and layers.
③ If the filtering component is placed below the crystal oscillator and the filtering capacitor and matching resistor are not arranged according to the signal flow direction, it will deteriorate the filtering effect of the filter.
The coupling capacitor should be placed as close as possible to the power pin of the crystal oscillator, in the direction of power flow, and in the order of capacitance value from large to small.
④ The routing of clock signals should be as short as possible, with a wider line width, and a balance should be found between the length of the wiring and the distance from the heat source.
Taking the following layout as an example, the layout of the crystal oscillator will be relatively better:
① The filtering capacitor and matching circuit of the crystal oscillator are located near the MCU chip and away from the board edge.
② The filtering capacitor and matching resistor of the crystal oscillator are arranged according to the signal flow direction, neatly and compactly placed near the crystal oscillator.
③ The crystal oscillator should be placed close to the chip, and the wiring to the chip should be as short and straight as possible.
In the circuit system, the high-speed clock signal line has the highest priority. The clock line is a sensitive signal, and the higher the frequency, the shorter the wiring should be to ensure that the signal distortion is minimized.
Because in many circuits nowadays, the clock frequency of the system crystal oscillator is very high, the energy generated by interference harmonics is also strong. Harmonics not only lead out from the input and output lines, but also radiate out from space. This also leads to strong stray radiation problems if the layout of the crystal oscillator in the PCB is not reasonable enough. Once it occurs, it is difficult to solve it through other methods. Therefore, it is very important to layout the crystal oscillator and CLK signal lines in the PCB board layout.
1、 Definition of crystal oscillator
Crystal oscillator generally refers to two types: quartz crystal oscillator and quartz crystal resonator, and can also be directly called crystal oscillator. They are all made using the piezoelectric effect of quartz crystals.
Its working principle is as follows: when an electric field is applied to the two electrodes of a crystal, the crystal will undergo mechanical deformation. Conversely, if mechanical pressure is applied to both ends of the crystal, the crystal will generate an electric field again. This phenomenon is reversible, so by utilizing the characteristic of crystals and applying an alternating voltage at both ends of the crystal, the chip will produce mechanical vibration and an alternating electric field. However, the vibrations and electric fields generated by crystals are generally small, but at a specific frequency, the amplitude will significantly increase, similar to the LC circuit resonance that circuit designers often see.
2、 Classification of crystal oscillators
① Passive crystal oscillator
Passive crystal oscillators are crystals, usually 2-pin non-polar devices (some passive crystal oscillators have fixed pins without polarity).
Passive crystal oscillators generally require clock circuits formed by load capacitors to generate oscillation signals (sine wave signals).
② Active crystal oscillator
An active crystal oscillator is an oscillator, typically consisting of 4 pins. Active crystal oscillators do not require an internal oscillator of the CPU and generate square wave signals. An active crystal oscillator can generate a clock signal when powered.
Active crystal oscillators have stable signals, good quality, and relatively simple connection methods. They have smaller accuracy errors and are more expensive than passive crystal oscillators.
3、 Equivalent circuit of crystal oscillator
In fact, the function of a crystal oscillator is like a series RLC circuit.
The equivalent circuit of the crystal oscillator shows a series RLC circuit, representing the mechanical vibration of the crystal oscillator, and parallel connection with a capacitor represents the electrical connection with the crystal oscillator, and the crystal oscillator operates towards series resonance.
Among them, R is the ESR equivalent series resistance, L and C are the equivalent inductance and capacitance, respectively, and Cp is the parasitic capacitance.
4、 Basic parameters of crystal oscillator
The basic parameters of a general crystal oscillator include operating temperature, precision value, matching capacitance, packaging form, core frequency, etc.
The core frequency of a crystal oscillator: The choice of crystal oscillator frequency generally depends on the requirements of the frequency components, such as MCU, which is generally within a range, mostly ranging from 4M to tens of M.
The accuracy of crystal oscillators: The accuracy of crystal oscillators is generally within ± 5PPM, ± 10PPM, ± 20PPM, ± 50PPM, etc. High precision clock chips are generally within ± 5PPM, and generally around ± 20PPM is selected for use.
Matching capacitance of crystal oscillator: Usually, the core frequency of the crystal oscillator can be changed by adjusting the value of the matching capacitance. Currently, this method is used to adjust high-precision crystal oscillators.
5、 Design layout of crystal oscillator on PCB board
As the heart of digital circuits, crystal oscillators affect the stability of the entire system, and the choice of crystal oscillators determines the success or failure of digital circuits.
Due to the presence of quartz crystals inside the crystal oscillator, external impacts and other factors can cause crystal breakage, which can easily lead to the oscillator not oscillating. Therefore, in circuit design, reliable installation of the crystal oscillator should be considered, and its position should not be close to the board edge, equipment casing, or other places as much as possible. When PCB is used for crystal oscillator layout, the following points are usually noted:
① The crystal oscillator should not be too close to the edge of the board, and the outer shell of the crystal oscillator must be grounded, otherwise it may cause radiation noise from the crystal oscillator.
This is particularly important when designing the board. Grounding the casing can prevent the crystal oscillator from radiating outward and also shield the interference of external signals on the crystal oscillator. If it must be arranged at the edge of the PCB, an additional GND line can be placed on the printed line edge of the crystal oscillator, and a through-hole can be drilled at a certain distance on the grounding line to surround the crystal oscillator.
② Signal lines should not be placed below the crystal oscillator, otherwise it may cause harmonic noise coupling between the signal lines and the crystal oscillator.
Ensure complete flooring and avoid wiring within the 300mil range of the crystal oscillator to prevent interference with the performance of other wiring, components, and layers.
③ If the filtering component is placed below the crystal oscillator and the filtering capacitor and matching resistor are not arranged according to the signal flow direction, it will deteriorate the filtering effect of the filter.
The coupling capacitor should be placed as close as possible to the power pin of the crystal oscillator, in the direction of power flow, and in the order of capacitance value from large to small.
④ The routing of clock signals should be as short as possible, with a wider line width, and a balance should be found between the length of the wiring and the distance from the heat source.
Taking the following layout as an example, the layout of the crystal oscillator will be relatively better:
① The filtering capacitor and matching circuit of the crystal oscillator are located near the MCU chip and away from the board edge.
② The filtering capacitor and matching resistor of the crystal oscillator are arranged according to the signal flow direction, neatly and compactly placed near the crystal oscillator.
③ The crystal oscillator should be placed close to the chip, and the wiring to the chip should be as short and straight as possible.
In the circuit system, the high-speed clock signal line has the highest priority. The clock line is a sensitive signal, and the higher the frequency, the shorter the wiring should be to ensure that the signal distortion is minimized.
Because in many circuits nowadays, the clock frequency of the system crystal oscillator is very high, the energy generated by interference harmonics is also strong. Harmonics not only lead out from the input and output lines, but also radiate out from space. This also leads to strong stray radiation problems if the layout of the crystal oscillator in the PCB is not reasonable enough. Once it occurs, it is difficult to solve it through other methods. Therefore, it is very important to layout the crystal oscillator and CLK signal lines in the PCB board layout.
Previous article: Precautions for using crystal oscillator
Next article: Difficulties in the treatment of microplastic wastewater
Next article: Difficulties in the treatment of microplastic wastewater

