August 17, 1998
Spice model makes it easy to design with PWM amplifiers
High-efficiency PWM amplifiers are displacing linear designs in many
applications. You can design a constant-current or a constant-voltage PWM amplifier with
the aid of a simple yet versatile Spice model.
Yu Jen Wong, Apex Microtechnology Corp
The recent availability of high-voltage and high-current PWM amplifiers in hybrid
packages has attracted the interest of many designers who traditionally use linear
amplifiers. The advantage of PWM amplifiers is obvious: efficiency of 70 to 97%. High
efficiency translates to lower internal power loss, smaller heat sinks, and reduced
overall physical size.
To make it easier to design with these amplifiers, a simple and versatile generic PWM
Spice model lets you check out PWM waveforms without the fear of blowing up the amplifiers
or getting shocked by high voltages. The methodology behind generating such a model
applies not only to hybrid PWM amplifiers, but also to monolithic and discrete PWM
amplifiers. The inputs to the model come from the PWM amplifier's data sheet, and you can
run the model on any commercial Spice program.
Even though a PWM amplifier offers analog signals in and analog signals out, its
circuit functionality is entirely different from a linear amplifier's. A PWM amplifier
modulates a pulse train in the time domain and uses LC filtering to extract the
analog-signal output. You can use PWM amplifiers to emulate linear constant-voltage
amplifiers or linear constant-current amplifiers, both at much higher levels of
efficiency.
If you're unfamiliar with how a PWM amplifier works, you're not alone. Just like op
amps, PWM amplifiers come in many sizes and flavors, some with fancy bells and whistles.
Fortunately, the amplifiers all operate under the same principle.
A PWM amplifier converts an analog signal into a pulse train of variable duty cycle.
The analog input controls the duty cycle of the output pulse train, which switches on and
off once during each cycle. When a high output is necessary, the pulse train switches on
most of the time and vice versa.
Figure 1a shows a basic PWM amplifier. Vin is the analog
input of 1 to 8V dc. AOUT is a pulse train, and BOUT is its inverse. The PWM oscillator
determines the frequency of the pulse train, and some PWM amplifiers allow you to put in
your own PWM oscillator. As Vin changes from its minimum to its maximum value, the duty
cycle of AOUT changes from 0 to 100%, and the duty cycle of BOUT changes from 100 to 0%.
The difference voltage of AOUT-BOUT has the same pulse train as AOUT but with double the
amplitude of 23Vs p-p (Figure 1b).
If you connect a dc brush-type motor across AOUT and BOUT, you can control the motor
speed with Vin. When you set Vin in the middle of its range, for 50% duty cycle at AOUT
and BOUT, the motor stands still. With Vin at its maximum, the motor turns at maximum rpm;
with Vin at its minimum, the motor reverses direction of rotation and turns at maximum rpm
again. You can directly connect AOUT and BOUT to a motor because the winding inductance of
the motor turns the pulsed voltage into a rippled dc current whose magnitude controls the
motor speed and whose polarity controls the clockwise or counterclockwise direction of the
motor. As Figure 1a indicates, most other applications need
LC filters to filter out the PWM pulse train to ensure that an analog signal appears at
the load.
Use a generic Spice model
Figure 2 shows the generic Spice subcircuit model of a PWM
amplifier. V1 is a ramp of fixed frequency. E1 serves as a comparator that converts the
PWM ramp as it crosses Vin into a variable-duty-cycle pulse train (Figure 3). S5, V5, S6, and V6 limit the amplitude of the pulse
train to ±5V. S1/R1, S2/R2, S3/R3, and S4/R4 represent the four MOSFET drivers for which
R1, R2, R3, and R4 are the respective on-resistances. The four MOSFETs always turn on and
off in diagonal sets, that is, when S1 and S4 are on, S2 and S3 are off and vice versa.
The inverter X1 provides the diagonal switching control. ISENSE A and ISENSE B are
current-sensing terminals, usually available at two output pins for current-feedback
control circuitry. For open-loop operation or for voltage-feedback control, just connect
ISENSE A and ISENSE B to ground.
When an external load connects between AOUT and BOUT, current flows from Vs to ground
through one of two routes: Vs to S1/R1, to an externally connected load between AOUT and
BOUT, to S4/R4, and then to ground or Vs to S3/R3, to the external load, to S2/R2, and
finally to ground. The voltage across the load actually doubles the Vs voltage. For
example, when Vs=100V, the voltage across the load is 200V p-p. This voltage-doubling
feature is another advantage PWM amplifiers offer for high-voltage applications. To double
voltage using linear amplifiers you must use two linear amplifiers in a bridge-mode
configuration.
Design example: constant-current amplifier
You commonly use constant-current amplifiers for applications such as motor-torque
control and battery chargers. You can use the model and the specifications of a commercial
PWM amplifierin this case, the Apex (www.apexmicrotech.com)
SA50to design a constant-current amplifier (also called a voltage-to-current
converter). You start out with the following specifications from the SA50 data sheet:
Analog input voltage/output duty cycles:
Vin=4V; AOUT=0% and BOUT=100%
Vin=6V; AOUT=50% and BOUT=50%
Vin=8V; AOUT=100% and BOUT=0%
switching frequency: 45 kHz
MOSFET on-resistance: 0.5 Ohm total or 0.25 Ohm each
The analog input voltage range of 4 to 8V dc and the switching frequency of 45 kHz
determine the waveform of the PWM ramp (Figure 4), which V1
in Figure 2 produces. You can describe this waveform as a
constant-voltage source in any commercial Spice program, such as Intusoft's (www.intusoft.com) Model ICAP/4Rx V8.8.1. You enter V1's
parameters as manual-driven inputs, and this Spice program automatically generates the
following statement for V1: V1 12 0 PULSE 4 8 0 11.1E-6 11.1E-6 1E-12 22.2E-6, where
"12 0'' designates the two nodes for V1.
The MOSFET on-resistance of 0.25 Ohm determines the values of R1, R2, R3, and R4. The
addition of Rq=600 Ohm and Vcc=12V model the SA50 amplifier's quiescent current and the
low-voltage power supply necessary to power the H-bridge drive circuitry.
Figure 5 shows the complete Spice subcircuit for the SA50.
This basic SA50 can drive a bidirectional motor for which Vin controls the motor speed and
direction of rotation. You can add LC filters that let you drive other loads. Even when
driving a motor, LC filters next to the amplifier module are useful for EMI and EMC
purposes. Without filters, the long cables to the motor carry high-voltage switching
pulses and act as antennas. Because the waveform across AOUT and BOUT is a pulse train of
variable duty cycle and because Vin, the analog input signal, controls the pulse train's
duty cycle or pulse width, you must first filter the PWM pulse train to extract the analog
output signal.
In Figure 5, the load comprises Rload and Lload. L1, C4,
L3, and C5 form a lowpass filter with a cutoff frequency (Fc) of 4.5 kHz to filter out the
SA50 amplifier's 45-kHz PWM pulse train. A rule of thumb is to set the LC filter's corner
frequency one decade below the PWM frequency. Of course, you can push the corner frequency
higher by using multiple-pole LC filters. The equations to calculate filter LC values are
as follows:

Because of the filter's differential configuration, these equations include a 30.5
factor for L1 and L3 and a 32 factor for C4 and C5. In this example, Rload=16 Ohm, and
Fc=4.5 kHz, so L1=L3=400 mH, and C4=C5=3.1 mF. Because the load for this example is
inductive, adding the matching network of R17 and C8 creates a combined load of 16 Ohm.
The equations for R17 and C8 are as follows:

In this example, Lload=1 mH, and Rload=16 Ohm, so C8=3.9 mF, and R17=16 Ohm. Similarly,
if you have a capacitive load, you can use a LC matching network to make the combined load
resistive, for which

Figure 6 shows the frequency response of the filter with
and without the matching network. Ignoring the feedback circuitry of X3 and X4, a 1-kHz
3.5V p-p sine wave with 6V- dc offset at Vin produces a 120V p-p sine wave across the load
(Figure 7).
To complete the design of a constant-current amplifier, you must have some means of
sensing the load current and provide feedback control in case of a load change. Ra and Rb
are the two current-sensing resistors. Op amp X4 and its associated components serve two
purposes: first, as a difference amplifier with a gain of 20 that converts the current
difference between Ra and Rb into a voltage output of -0.5A/V and, second, as a lowpass
filter comprising C1, C2, C6, and C7 that filters the ripple currents in Ra and Rb with a
corner frequency of 4.5 kHz. The design equations are as follows:

To minimize power losses, you should choose Ra and Rb values of 0.01 to 0.1 Ohm. In
this example, Fc=4.5 kHz. R8=R9=10 kOhm. To minimize loading effects, these resistors must
be much greater than R13=R15=100 Ohm. Substituting these values into Equation 7 and
Equation 8, C6=C7=0.35 mF, and C1=C2=180 pF. Choosing R10=200 kOhm, Equation 6 yields a
gain of -0.5 A/V.
X3 is an integrator that compares the error voltage from X4 with the input voltage Ein
and provides the correct input voltage for the SA50 amplifier to close the feedback loop.
The design equations for the integrator are as follows:

You can complete the design by choosing R12=R14=10 kOhm and C3=71 nF (Figure 6).
You can now run the Spice program. The load current waveforms (Figure
8) are as expected. Note that there is a small error between the Spice output and the
expected value. For example, with Ein=10V, the expected output current should be -5A, but Figure 8 shows -4.8A. This difference is because of the loss
resulting from the 0.25 Ohm MOSFET's on-resistance. If you set the on-resistance to zero,
you get exactly -5A. Listing 1 is the complete Spice
circuit description for the constant-current amplifier.
Constant-voltage amplifier
In applications such as audio-speaker drivers, motor-speed control, and power
inverters, you need a constant voltage amplifier. You can use the Apex SA02 to design a
high-efficiency, high-power PWM audio-speaker driver. The SA02 data sheet lists the
following specifications:
Analog input voltage/output duty cycles:
Vin=1.25V; AOUT=0%, BOUT=100%
Vin=2.50V; AOUT=50%, BOUT=50%
Vin=3.75V; AOUT=100%, BOUT=0%
switching frequency: 250-kHz
MOSFET on-resistance: 0.42 Ohm total or 0.21 Ohm each.
The LC filter design is similar to that of the constant-current amplifier except the LC
filter requires no matching network because of the 8 Ohm resistive load (Figure 9a). The SA02 amplifier's PWM frequency is 250 kHz, so
the design sets the LC filter's corner frequency to 25 kHz. The design of the difference
amplifier (X4) is somewhat different, however. This constant-voltage amplifier
configuration senses the output voltage, not the output current. The voltage at AOUT and
BOUT is much higher than the voltage across the current-sensing resistors in the previous
example. Instead of boosting the gain, resistor dividers lower the sense voltage to levels
that a small signal amplifier can handle. The integrator's (X3) time constant is faster to
provide the frequency response necessary for audio applications. The SA02 audio-speaker
driver has a -10V/V voltage gain and a 10-kHz power bandwidth. Figure 9b shows the circuit's input and output waveforms.
Note that it takes about 50 msec for the output's sinewave to stabilize.
The SA02 has many bells and whistles, such as thermal sensing and external-logic
shutdown, that the generic model does not implement. A design engineer can easily analyze
these independent features with a paper and pencil. However, this simple yet versatile
model makes it easy to model the main PWM function when manual analysis of this
feedback-control circuit becomes unmanageable. |