The short answer
A phase-locked loop (PLL) is a feedback control circuit that keeps an output signal in a fixed phase relationship with a reference signal. Because phase and frequency are linked, a locked PLL also keeps its output at a fixed frequency relationship to the reference. In many designs that relationship is a whole-number multiple.
The four building blocks
- Phase detector: compares the reference signal with a feedback signal and outputs a voltage (or pulses) that is proportional to the phase difference.
- Loop filter: usually a low-pass filter. It smooths the detector output into a steady control voltage and removes most of the ripple.
- Voltage-controlled oscillator (VCO): an oscillator whose frequency rises or falls with its control voltage.
- Feedback divider (optional): divides the VCO output before it returns to the detector. If the divider ratio is N, the locked VCO runs at N times the reference frequency.
How locking works
- The VCO starts at some frequency, probably not the reference frequency.
- The phase detector sees the difference and produces an error voltage.
- The loop filter turns that error into a steady control voltage, which pushes the VCO frequency toward the reference.
- When the frequency error reaches zero, the phase difference holds steady. The loop is then locked.
If the reference changes, the loop moves the VCO to match again. How quickly it does so depends on the loop’s bandwidth and filter design.
Locked and unlocked states
In the locked state, the output frequency and phase track the reference. Before that, while the loop is still pulling in, it is unlocked. A loop can also lose lock if the reference moves outside the VCO’s tuning range, or if the loop filter is poorly designed.
Where PLLs are used
- Frequency synthesis: creating many output frequencies from one stable reference crystal, as in radios and phone transceivers.
- Clock generation: multiplying a lower-frequency crystal up to the clock rate a processor or FPGA needs.
- FM demodulation: a PLL can follow the instantaneous frequency of an FM signal, and its control voltage carries the audio.
- Clock and data recovery: pulling a clock signal out of a serial data stream.
Analog and digital PLLs
Analog PLLs use an analog phase detector and an analog VCO. Digital PLLs (DPLL) and all-digital PLLs (ADPLL) do the same job with digital circuits, which suits many modern chips. Fractional-N PLLs allow output frequencies that are non-integer multiples of the reference.
Getting started with a PLL at home
- The classic NE565 is a PLL chip often used in teaching. The 566 is a separate VCO chip. The PLL and 566 VCO article explains how the two relate.
- Start with the block diagram and loop filter design in the datasheet. Check the supply range and whether the part is still in production, since many classic chips are obsolete or have newer equivalents.