>
section 5 of 116 min read

5. Voltage Time-Base Generators

A time-base generator produces a precisely linear ramp voltage over time: a sawtooth waveform with a slow, linear sweep up and a fast retrace down to zero. These are the heart of cathode-ray-tube oscilloscopes (where the ramp deflects the electron beam horizontally to draw the time axis), single-slope and dual-slope ADCs (where the ramp is compared against an input to time how long it takes to match), PWM modulators, and many other ramp-based circuits.

5.1 What we want and what's hard about it

The ideal time base:

  1. Sweep linearly from 0 to some maximum voltage over a precisely controlled time.
  2. Retrace fast. Return to 0 quickly so you can start the next sweep.
  3. Trigger on demand. Start the sweep at exactly the right moment.
  4. Adjustable sweep rate.

The challenge: the simplest charge-a-cap-through-a-resistor circuit gives an exponential, not a linear ramp. The cap voltage is VC(t)=VCC(1et/RC)V_C(t) = V_{CC}(1 - e^{-t/RC}), which is approximately linear only for small tt (where VCVCCV_C \ll V_{CC}) and curves over noticeably as VCV_C approaches VCCV_{CC}.

To quantify the nonlinearity: define the sweep error at the end of the sweep as

ϵ=Videal  at  endVactual  at  endVideal  at  end\epsilon = \frac{V_{ideal\;at\;end} - V_{actual\;at\;end}}{V_{ideal\;at\;end}}

For an exponential sweep ending at VC=VCC/2V_C = V_{CC}/2, the error is about 25%, way too much for a usable scope. We need cleverer circuits.

5.2 Constant-current charging

The fundamental trick: instead of charging the cap through a resistor, charge it with a constant-current source. A current source delivers constant II regardless of voltage, so dV/dt=I/CdV/dt = I/C is constant. The output is a perfectly linear ramp.

plaintext
   I (constant)
   |
   * ── output (linear ramp)
   |
   C
   |
  GND
   
   At the end of sweep: switch closes, dumps cap to 0 through low-R path, then opens.

Constant-current sources are easily made with a current mirror or a JFET in saturation. The linearity is now limited by how good the current source is, typically <1% over a useful voltage range.

5.3 The Miller integrator sweep

The Miller integrator uses an op-amp (or a transistor approximation) with a feedback capacitor. From Chapter 5: the op-amp integrator with input VinV_{in} outputs

Vout(t)=1RCVindtV_{out}(t) = -\frac{1}{RC}\int V_{in}\,dt

If VinV_{in} is a constant DC voltage VRV_R, the output is a perfectly linear ramp Vout=VRt/(RC)V_{out} = -V_R t / (RC). At the end of the sweep, briefly close a switch across C to reset to zero, then resume.

Miller sweep circuits achieve linearity better than 0.1% across a multi-volt swing. They were the standard inside CRT scopes in the analog era.

5.4 The bootstrap sweep

The bootstrap is a clever positive-feedback trick that turns a simple RC charging circuit into a near-ideal current source.

plaintext
            Vcc
             |
            [R]
             |
             *───── output (ramp)
             |
            [C_out]   (a large coupling cap, the "bootstrap cap")
             |
             *────── back to top of R
             
   The big cap C_out follows the output exactly, so the
   voltage across R stays constant, even as the output rises.

Setup: a resistor R from Vcc to the timing cap C, a buffer (emitter follower or source follower) from the output to a "bootstrap" point, and a large cap from the buffer's output back to the top of R.

In ordinary RC charging, as the cap voltage rises, the voltage across R falls (since the supply is fixed), so the charging current falls. That is why the response is exponential. In the bootstrap, the buffer's output rises in lockstep with the cap voltage. The bootstrap cap (which is much larger than the timing cap) holds the voltage from the buffer to the top of R nearly constant during the sweep. Result: the voltage across R stays constant, the current stays constant, and the timing cap charges linearly.

The math: define VoV_o = output voltage, VbV_b = bootstrap cap's left-side voltage. The buffer enforces Vb=Vo+VbootstrapV_b = V_o + V_{bootstrap} where VbootstrapV_{bootstrap} is approximately constant (the cap's stored voltage, which can't change quickly because the cap is so large). The current through R is (VbVo)/R=Vbootstrap/R(V_b - V_o)/R = V_{bootstrap}/R, perfectly constant. The cap charges at rate I/C=Vbootstrap/(RC)I/C = V_{bootstrap}/(RC), perfectly linear.

Linearity better than 1% is routine. Used in instruments where you can't afford an op-amp (in older or simpler designs).

5.5 UJT relaxation oscillator

A unijunction transistor (UJT) is a three-terminal negative-resistance device. Once turned on, its internal resistance drops dramatically, dumping current. Connect a UJT across a charging cap and you get a sawtooth: the cap charges through R toward Vcc, eventually triggering the UJT's negative-resistance breakdown, which dumps the cap quickly to near zero. Repeat. The result is a self-resetting sawtooth oscillator.

The UJT is largely obsolete now (replaced by the 555 and dedicated VCO chips), but it shows up in old SCR firing circuits and as the simplest possible sawtooth oscillator.

5.6 Methods of improving sweep linearity

Summary of techniques:

  • Constant-current source charging. As above. Linearity is set by the current source's output impedance.
  • Miller integrator. Linearity set by op-amp gain and feedback.
  • Bootstrap. Linearity set by buffer and bootstrap cap quality.
  • Compensation network. Add a small voltage that pre-distorts the input to cancel the exponential, used in some old TV horizontal sweep circuits.
  • Linearity correction in software. Modern digital scopes don't bother making the analog ramp linear; they sample digitally and correct mathematically.

5.7 Where time-base generators show up

  • CRT oscilloscopes. Horizontal time base, classic application. Largely obsolete (analog scopes are now collector's items), but the principle survives.
  • CRT TVs. Horizontal scan (~ 15 kHz) and vertical scan (~ 60 Hz) used bootstrap and Miller-style sweeps. The "horizontal output transformer" in old CRT TVs was both the deflection driver and the high-voltage source for the screen.
  • Single-slope and dual-slope ADCs. A ramp is compared against the input; the time to match is digitized. Slow but very accurate.
  • PWM generation. Compare a ramp against the desired duty-cycle signal; the ramp generator's linearity directly affects PWM accuracy.
  • Function generators. Generate triangle waves (which are exactly the time base's output), then waveshape into sine and square.