Op Amp and Transistor-Based Analog Square Wave Generator Design
Op Amp and Transistor-Based Analog Square Wave Generator Design
Op Amp and Transistor-Based Analog Square Wave Generator Design
Figure 1. Single op-amp astable multivibrator oscillator for generating a square wave.
negative input, V , you might recognize the rest of this circuit as a Schmitt
c
trigger with hysteresis. The Schmitt trigger has positive feedback and only two
stable operating points (V = V or V = V ). As we will explain, the astable
OUT DD OUT SS
Now, let’s assume that V is driven to the positive rail (V ) at the start. At this
OUT DD
point, V will begin to charge through the resistor, R , and the voltage at V can
c 3 p
threshold voltage at V . At this point, V will pull down to the negative rail
p OUT
With the new value for V equal to V , we also have a new threshold voltage:
OUT SS
V . Then, the output will be driven back to the positive supply rail, V . This
p DD
R = R = 10 kΩ
1 2
R = 1 kΩ
3
C = 1 uF
V = +5 V
DD
V = -5 V
SS
Figure 2. Op-amp astable multivibrator square wave oscillator simulation. Top: VOUT (green).
Bottom: Vc (blue) and Vp (red)
As we can see, V charges and discharges to the trip points defined earlier by
c
double the time to account for charge and discharge, we obtain the output
period:
T = 2t = − 2 τ ⋅ l n (VDD − V up VDD − Vl ow ) = − 2R C ⋅ l n (V
This equation shows that the RC time constant dominates, while the values of
R and R have a weak relationship to the period because they change the trip
1 2
This circuit is simple, effective, and supports both low and high frequencies,
limited by the op-amp’s slew rate driving the output during the switching
events. The downside is that the output swing cannot be made smaller,
thereby setting a hard limit on the frequency as the output must swing from
rail to rail.
To build this circuit with a single supply op-amp that swings from the ground
(0 V) to V , the ground nodes connected to the capacitor and resistor R must
DD 1
Upon startup of this circuit, one transistor, let’s assume Q2, will go into the
“cut-off” region, where it conducts no current. This will cause the collector
node (top of Q2) to charge up to V . DD
Meanwhile, Q1 will be saturated and thus conducting current. This will cause
the node of C connected to the base of Q2 to charge up through R until Q2
1 3
is pushed into saturation. Upon being pushed to saturation, the sharp voltage
drop on the right side of C causes a heavy negative response at the base of
2
T = t1 + t2 �=�1+�2
t1 = 0.69R3 C 1 �1=0.69�3�1
t2 = 0.69R2 C 2 �2=0.69�2�2
In the transient waveforms, t is the pulse width of the output at collector Q1,
1
while t is the pulse width at collector Q2. As one can see in the equations,
2
Figure 4. Bipolar transistor astable multivibrator output with symmetric outputs.
The components values for this simulation are:
R = R = 1 kΩ
1 4
R = R = 100 kΩ
2 3
C = C = 10 nF
1 2
The BJTs are standard 2N2222 NPNs. Therefore our expected time constants
from our basic equation are:
The simulation result for this circuit after the change is shown in Figure 5.
Figure 5. Bipolar transistor astable multivibrator output with nonsymmetric outputs.
equations.
Overall, the BJT-based astable multivibrator has much more flexibility when
compared to the op-amp oscillator. While slightly more complex in structure,
it does not require a negative power supply and produces both the output
and its complement. It also gives the ability to form generic rectangular waves
of variable frequency and duty cycle instead of pure square waves of variable
frequency.