2003 Microchip Technology Inc.
DS11195C-page 15
MCP41XXX/42XXX
4.2
Typical Applications
4.2.1
PROGRAMMABLE SINGLE-ENDED
AMPLIFIERS
Potentiometers are often used to adjust system refer-
ence levels or gain. Programmable gain circuits using
digital potentiometers can be realized in a number of
different ways. An example of a single-supply, inverting
gain amplifier is shown in
Figure 4-4. Due to the high
input impedance of the amplifier, the wiper resistance
is not included in the transfer function. For a single-sup-
ply, non-inverting gain configuration, the circuit in
.
FIGURE 4-4:
Single-supply,
programmable, inverting gain amplifier using a
digital potentiometer.
FIGURE 4-5:
Single-supply,
programmable, non-inverting gain amplifier.
In order for these circuits to work properly, care must be
taken in a few areas. For linear operation, the analog
input and output signals must be in the range of VSS to
VDD for the potentiometer and input and output rails of
the op-amp. The circuit in
Figure 4-4 requires a virtual
ground or reference input to the non-inverting input of
the amplifier. Refer to Application Note 682, “Using
Single-Supply Operational Amplifiers in Embedded
Systems” (DS00682), for more details. At power-up or
reset (RS), the resistance is set to mid-scale, with RA
and RB matching. Based on the transfer function for the
circuit, the gain is -1 V/V. As the code is increased and
the wiper moves towards the A terminal, the gain
increases. Conversely, when the wiper is moved
towards the B terminal, the gain decreases.
Figure 4-6shows this relationship. Notice the pseudo-logarithmic
gain around decimal code 128. As the wiper
approaches either terminal, the step size in the gain
calculation increases dramatically. Due to the
mismatched ratio of RA and RB at the extreme high and
low codes, small increments in wiper position can
recommended gains lie between 0.1 and 10 V/V.
FIGURE 4-6:
Gain vs. Code for inverting
and differential amplifier circuits.
4.2.2
PROGRAMMABLE DIFFERENTIAL
AMPLIFIER
An example of a differential input amplifier using digital
potentiometers is shown in
Figure 4-7. For the transfer
function to hold, both pots must be programmed to the
same code. The resistor-matching from channel-to-
channel within a dual device can be used as an advan-
tage in this circuit. This circuit will also show stable
operation over temperature due to the low potentiome-
ter temperature coefficient.
Figure 4-6 also shows the
relationship between gain and code for this circuit. As
the wiper approaches either terminal, the step size in
the gain calculation increases dramatically. This circuit
is recommended for gains between 0.1 and 10 V/V.
MCP606
VIN
VSS
-IN
+IN
VOUT
B
A
W
MCP41010
Where:
VREF
+
-
VDD
VOUT
VIN
RB
RA
-------
V
REF 1
RB
RA
-------
+
+
–
=
RA
RAB 256 Dn
–
()
256
---------------------------------------
=
RB
RABDn
256
------------------
=
RAB
Total Resistance of pot
=
Dn
Wiper setting forDn 0 to 255
=
MCP606
VIN
VSS
VDD
+IN
-IN
VOUT
RB
RA
W
MCP41010
+
-
Where:
RA
RAB 256 Dn
–
()
256
---------------------------------------
=
RB
RABDn
256
------------------
=
RAB
Total Resistance of pot
=
Dn
Wiper setting forDn 0 to 255
=
VOUT
VIN 1
RB
RA
-------
+
=
0.1
1
10
0
64
128
192
256
Decimal code (0-255)
Absolute
Gain
(V/V)