Oscillators
Learning Objectives
- Define an oscillator and state the Barkhausen criterion for sustained oscillation
- Identify the three essential building blocks of a feedback oscillator: amplifier, feedback network, frequency-determining element
- Compare RC, LC, and crystal oscillator topologies and explain when each is used
- Describe relaxation oscillators and how they differ from sinusoidal (feedback) oscillators
- Calculate the oscillation frequency for a simple RC phase-shift and an LC tank circuit
- Recognize practical concerns: frequency stability, amplitude stability, and startup
Quick Answer
An oscillator is a circuit that generates a repeating waveform — sine, square, or sawtooth — with no external input signal, converting DC power into a continuously repeating AC output at a specific frequency. It does this by taking a small amount of its own output, feeding it back to the input in phase (positive feedback) with exactly the right gain to sustain oscillation indefinitely. Oscillators are the "clock" and "carrier wave" generators behind virtually every electronic system: microcontroller clocks, radio transmitters, function generators, and even the tone generator in a musical synthesizer all rely on oscillator circuits.
The Barkhausen Criterion: Why Oscillators Oscillate
An oscillator is really a feedback amplifier deliberately made unstable in a controlled way. Three pieces work together:
For oscillation to start and sustain itself at a specific frequency, two conditions — together called the Barkhausen criterion — must both hold at that frequency:
- Loop gain magnitude = 1 (Aβ = 1): the amplifier's gain exactly compensates for the feedback network's attenuation, so the signal neither grows unboundedly nor dies out.
- Loop phase shift = 0° (or 360°, an integer multiple of a full cycle): the fed-back signal arrives back at the input perfectly in phase with the original, reinforcing rather than canceling it — this is why oscillators need positive, not negative, feedback.
In practice, the loop gain is designed slightly greater than 1 at startup (so random noise gets amplified into a growing oscillation), and some nonlinearity in the amplifier (saturation, or an automatic gain control circuit) naturally settles the gain back to exactly 1 once a stable amplitude is reached — this prevents the oscillation from growing forever or dying out.
The frequency-determining element — typically a resistor-capacitor network, an inductor-capacitor "tank," or a piezoelectric crystal — sets the one frequency at which the phase-shift condition is satisfied, so that's the only frequency where sustained oscillation is possible.
RC Oscillators
RC oscillators use resistor-capacitor networks to create the necessary phase shift. A classic example is the RC phase-shift oscillator, which cascades three RC sections, each contributing 60° of phase shift, for a total of 180° — combined with an inverting amplifier stage (which itself provides another 180°), the total loop phase shift is 360°, satisfying Barkhausen's phase condition.
180° from
inverting amp
┌──────┐ ┌──────┐ ┌──────┐
│ RC 60°│──▶│ RC 60°│──▶│ RC 60°│──▶ feedback into
└──────┘ └──────┘ └──────┘ inverting amplifier
For three identical RC sections, the oscillation frequency is:
f = 1 / (2π RC √6)
RC oscillators are simple and inexpensive but have only moderate frequency stability and are mainly used for audio-frequency applications (up to a few hundred kHz), since practical component values become impractically small at higher frequencies.
LC Oscillators
LC oscillators use an inductor-capacitor tank circuit as the frequency-determining element. Energy sloshes back and forth between the capacitor's electric field and the inductor's magnetic field, naturally resonating at:
f = 1 / (2π √(LC))
An amplifier (often a single BJT or FET stage) replenishes the small energy lost to resistance each cycle, sustaining the oscillation. Common LC topologies include the Colpitts oscillator (capacitive voltage divider sets the feedback fraction) and the Hartley oscillator (inductive divider instead). LC oscillators offer better frequency stability than RC types and are the standard choice for radio-frequency (RF) applications — local oscillators in radio receivers, RF signal generators — typically from hundreds of kHz up into the GHz range.
Worked example: An LC tank with L = 10 µH and C = 100 pF resonates at f = 1/(2π√(10×10⁻⁶ × 100×10⁻¹²)) = 1/(2π√(10⁻¹⁵)) ≈ 5.03 MHz — right in the shortwave radio band, a typical LC oscillator application.
Crystal Oscillators
A quartz crystal exploits the piezoelectric effect: mechanical stress generates a voltage, and an applied voltage causes mechanical deformation. A properly cut quartz crystal behaves electrically almost exactly like a very high-Q LC tank circuit, but with far greater frequency stability — because the resonance depends on the crystal's precise mechanical dimensions rather than on temperature- and tolerance-sensitive discrete inductors and capacitors.
Crystal oscillators achieve frequency stability of a few parts per million (ppm), versus roughly 1% (10,000 ppm) for a typical LC oscillator — this is why every digital clock, wristwatch, and microcontroller uses a crystal oscillator rather than an LC circuit for its timing reference.
Relaxation Oscillators
Unlike the sinusoidal oscillators above (which rely on the Barkhausen criterion and a resonant/phase-shifting network), relaxation oscillators generate non-sinusoidal waveforms — square, triangular, or sawtooth — by repeatedly charging and discharging a capacitor between two threshold voltages, using a comparator or Schmitt trigger to flip the charging direction at each threshold.
A classic example is the astable multivibrator built from a 555 timer IC: the timer's internal comparators charge and discharge a timing capacitor through resistors, producing a square wave whose frequency is set by RC time constants:
f ≈ 1.44 / [(R1 + 2R2) × C]
Relaxation oscillators are simple, work down to very low frequencies, and easily produce non-sinusoidal waveforms — ideal for clock signals, PWM generation, and simple timer circuits — but have poorer frequency stability than crystal oscillators.
Why It Matters
Every clock signal in a digital system, every carrier wave in a radio transmitter, and every tone in a musical synthesizer originates from an oscillator. Choosing the right oscillator type is a real engineering tradeoff: RC oscillators are cheap and simple for audio-range applications; LC oscillators dominate RF applications; crystal oscillators are essential wherever long-term frequency accuracy matters (clocks, communication systems); and relaxation oscillators are the go-to choice for simple, low-cost square-wave or timing applications.
Common Mistakes
Misconception 1: "Oscillators need negative feedback, just like amplifiers, to work properly and stay stable." Why it's wrong: This confuses stability of amplification (negative feedback) with the entirely different goal of sustained self-generated oscillation. Negative feedback opposes and damps out changes, which would prevent oscillation from starting or sustaining. Correct understanding: Sinusoidal oscillators require positive feedback with the loop phase shift totaling 0°/360° and loop gain of exactly 1 at the oscillation frequency (the Barkhausen criterion) — the opposite of the negative feedback used to stabilize amplifiers.
Misconception 2: "A higher loop gain always produces a stronger, better oscillation." Why it's wrong: If loop gain stays above 1 indefinitely, the oscillation amplitude grows until the amplifier saturates, causing severe waveform distortion (a sine wave oscillator would start producing a clipped, near-square output). Correct understanding: Loop gain should be slightly above 1 only at startup (to overcome losses and let a random noise seed grow), then some amplitude-limiting mechanism (natural saturation or an automatic gain control loop) settles the loop gain to exactly 1 for a stable, undistorted sine wave.
Misconception 3: "LC and crystal oscillators are basically interchangeable — the crystal is just a fancier inductor-capacitor pair." Why it's wrong: While a crystal does behave electrically similarly to an LC tank, its extremely high Q factor (quality factor, often tens of thousands vs. under 100 for a typical LC tank) and its mechanical (rather than purely electrical) resonance mechanism give it dramatically better frequency stability and much lower sensitivity to temperature and component tolerance. Correct understanding: Crystals are chosen specifically when frequency accuracy and stability over time and temperature are critical (clocks, communication carriers); LC tanks are chosen when some tunability and lower cost matter more than absolute precision.
Comparison and Connections
| Oscillator Type | Frequency Range | Stability | Typical Use |
|---|---|---|---|
| RC (phase-shift) | Audio (Hz–hundreds of kHz) | Moderate | Audio tone generation, simple test signals |
| LC (Colpitts/Hartley) | RF (hundreds of kHz–GHz) | Good | Radio local oscillators, RF signal sources |
| Crystal | kHz–hundreds of MHz | Excellent (ppm-level) | Digital clocks, communication carrier references |
| Relaxation (555, multivibrator) | Sub-Hz to MHz | Poor to moderate | Square-wave clocks, PWM, simple timers |
| Feature | Sinusoidal Oscillator | Relaxation Oscillator |
|---|---|---|
| Waveform | Sine wave | Square, triangular, or sawtooth |
| Mechanism | Barkhausen loop (amplifier + frequency-selective feedback) | Repeated capacitor charge/discharge with a threshold switch |
| Typical circuit | RC phase-shift, Colpitts, Hartley | 555 astable, op-amp/comparator multivibrator |
Practice Questions
Recall 1: State the two conditions of the Barkhausen criterion for sustained oscillation. Answer guidance: Loop gain magnitude equals 1 (Aβ = 1), and total loop phase shift equals 0° (or an integer multiple of 360°) at the oscillation frequency.
Recall 2: Name the three essential functional blocks present in every feedback (sinusoidal) oscillator. Answer guidance: An amplifier, a feedback network, and a frequency-determining element.
Understanding 1: Explain why an oscillator requires positive feedback rather than negative feedback, in contrast to a typical amplifier stage. Answer guidance: Positive feedback reinforces the signal in phase each cycle, allowing a small disturbance to grow into and sustain oscillation; negative feedback opposes changes and drives disturbances toward zero, which would suppress rather than sustain oscillation.
Understanding 2: Why does a crystal oscillator achieve much better frequency stability than an LC oscillator? Answer guidance: The crystal's resonance depends on its precise mechanical dimensions and material properties (which barely change with temperature or aging) and it has a very high Q factor, whereas an LC tank's resonance depends on discrete inductor and capacitor values that are more sensitive to temperature drift and component tolerance.
Application 1: Calculate the resonant frequency of an LC tank with L = 47 µH and C = 220 pF. Answer guidance: f = 1/(2π√(LC)) = 1/(2π√(47×10⁻⁶ × 220×10⁻¹²)) ≈ 1.56 MHz.
Application 2: You need a low-cost square wave generator for a blinking LED circuit at roughly 1 Hz. Which oscillator type is most appropriate, and why? Answer guidance: A relaxation oscillator, such as a 555 timer astable circuit — it's simple, inexpensive, naturally produces a square wave, and easily reaches low frequencies like 1 Hz with practical RC values, where crystal or LC oscillators would be unnecessarily complex or impractical at that frequency.
Analysis 1: A student builds an RC phase-shift oscillator but the circuit fails to start oscillating even though the RC network provides the correct 180° phase shift. Suggest the likely cause based on the Barkhausen criterion. Answer guidance: The loop gain condition (Aβ ≥ 1, especially at startup) is likely not satisfied — the amplifier's gain may be too low to compensate for the attenuation introduced by the three RC sections, so even though the phase condition is met, oscillation cannot build up from noise.
Analysis 2: Compare an LC oscillator and a crystal oscillator for use as the reference clock in a wristwatch, and explain which is preferred and why long-term accuracy matters here. Answer guidance: A crystal oscillator is strongly preferred because a wristwatch must keep accurate time over months and years; an LC oscillator's frequency would drift enough with temperature and component aging to make the watch noticeably inaccurate, while a quartz crystal's few-ppm stability keeps the watch accurate to within seconds per month.
FAQ
Q1: Why do sinusoidal oscillators need "positive feedback" — isn't feedback usually meant to reduce distortion? A: Negative feedback (used in amplifiers) reduces distortion and stabilizes gain by opposing changes. Oscillators intentionally use positive feedback instead, because the goal is to reinforce and sustain a signal indefinitely, not stabilize it toward zero change.
Q2: How does an oscillator "start" if there's no input signal to begin with? A: Every real circuit has some tiny random noise or a power-on transient. With loop gain slightly above 1 at startup, this noise gets amplified cycle after cycle at the frequency where the phase condition is satisfied, growing into a full-amplitude oscillation within a few cycles.
Q3: What does "Q factor" mean for an oscillator's frequency-determining element? A: Q (quality factor) measures how sharply peaked a resonant circuit's response is around its resonant frequency. Higher Q means a narrower, more sharply defined resonance, which translates to better frequency stability and purity (less phase noise) — this is why crystals (very high Q) beat LC tanks (moderate Q) for stability.
Q4: Can a single oscillator circuit generate multiple frequencies at once? A: A single sinusoidal (Barkhausen-type) oscillator generates essentially one frequency, set by its frequency-determining network. Relaxation oscillators can produce a fundamental frequency plus harmonics (since square/sawtooth waves aren't pure sine waves), and voltage-controlled oscillators (VCOs) can be tuned to different frequencies over time by varying a control voltage.
Q5: Why do RC oscillators become impractical at high (RF) frequencies? A: Achieving a high enough frequency with an RC network requires impractically small resistor and capacitor values, at which point stray circuit capacitance and parasitic effects dominate and swamp the intended RC time constant — LC or crystal circuits handle high frequencies far more predictably.
Quick Revision
- Oscillator = self-sustaining signal generator, no external input needed once running.
- Barkhausen criterion: loop gain = 1 and loop phase shift = 0°/360° at the oscillation frequency.
- Oscillators use positive feedback (reinforcing); amplifiers typically use negative feedback (stabilizing).
- Three blocks: amplifier, feedback network, frequency-determining element.
- RC phase-shift oscillator: f = 1/(2πRC√6) for three identical 60°-shift RC sections; good for audio range.
- LC tank oscillator: f = 1/(2π√(LC)); good for RF applications (Colpitts, Hartley topologies).
- Crystal oscillator: piezoelectric resonance, very high Q, ppm-level stability; used for clocks and carriers.
- Relaxation oscillator (e.g., 555 astable): repeated capacitor charge/discharge produces square/sawtooth waves.
- Startup requires loop gain slightly above 1; amplitude then self-limits via saturation or AGC to hold gain at 1.
- Higher Q factor in the frequency-determining element means better frequency stability and purity.
Related Topics
Prerequisites: Operational Amplifiers, Filters and Amplifiers, Feedback Systems
Related: Feedback Systems, Analog Communication Systems
Next: Signal Conditioning, Analog Communication Systems