Introduction - Facstaff Bucknell

advertisement
ELEC 350L
Electronics I Laboratory
Fall 2005
Lab #4: D/A Converter Based on Summing Amplifier
Introduction
Digital-to-analog (D/A) converters are widely used in many modern communications and
instrumentation systems, and they serve as the key element of all musical compact disk playback
units. A summing amplifier based on an op-amp is a good choice for this type of circuit because
the voltage gains from the various input ports to the output port are set simply by adjusting
resistor ratios. This eases the tasks of controlling the conversion process and of scaling the
various binary input voltages to produce an appropriate output voltage. In this lab experiment
you will build a D/A converter based on the summing amplifier circuit.
Theoretical Background
The basic function of the D/A converter is to translate (convert) a number represented in binary
form to an analog voltage value that corresponds to that number. For example, a 3-bit D/A
converter might be designed to produce the output voltages shown in Table 1 for the eight
possible binary numbers that can be represented by three binary digits.
Table 1. Output voltages of a 3-bit D/A converter for all possible inputs.
Binary Decimal
Output
Number Number Voltage (V)
000
0
0.0
001
1
0.2
010
2
0.4
011
3
0.6
100
4
0.8
101
5
1.0
110
6
1.2
111
7
1.4
Although the output voltages shown in Table 1 range from zero to 1.4 V, a D/A converter can be
designed to provide any desired range of output voltages. Most D/A converters are designed to
produce equal-sized increments (steps) from one voltage level to the next. In the example shown
in Table 1, the step size is 0.2 V. If smaller step sizes are desired for a given output voltage
range (that is, if greater resolution is needed), then a larger number of bits must be used to
represent the voltage values.
1
A 3-bit D/A converter can be built easily using a summing amplifier. A typical circuit is shown
below in Figure 1.
v0
Ro
v1
R1
Rf
R2
v2
+15 V
−
+5 V
vout
+
1-k
pull-down
resistors
−15 V
SPDT
switches
Figure 1. 3-bit D/A converter based on a summing amplifier. The 3-bit binary
input signal is simulated using single-pole double-throw (SPDT) switches and
pull-down resistors, which make v0 through v2 equal to either 0 V or +5 V. With
the switches in the positions shown, the input value is binary 101.
It is easy to show that the output voltage is given by
vout  
Rf
R0
v0 
Rf
R1
v1 
Rf
R2
v2 .
Note that the subscript of v0 is a zero, not to be confused with the letter “O,” which is often used
to indicate “output;” in this example an output quantity is identified specifically by the subscript
“out.” In the D/A converter circuit the input voltages are interpreted as representing the three
bits of a binary number. A binary 0 is usually represented by 0 V, and a binary 1 is usually
represented by some particular nonzero (typically positive) voltage value. Input voltage v0
represents the least significant bit (LSB), v1 the second bit, and v2 the most significant bit (MSB).
The input resistors R0 through R2 must be chosen so that a change in state in the bit applied to a
given input causes an appropriate corresponding change in the output voltage. For example, for
a converter circuit designed to produce the outputs given in Table 1, if v0 changes from 0 to 1,
the output voltage must rise by 0.2 V. Likewise, if v1 changes from 0 to 1, the output voltage
must rise by 0.4 V; and if v2 changes, the output must change by 0.8 V. Note that the voltage
increments are related to each other by powers of 2. The value of Rf sets the overall output
voltage range obtained for the full range of input binary numbers between 000 and 111.
2
There is one other important issue to consider when using a summing amplifier as a D/A
converter. The binary digit 1 is usually represented in digital circuits by a positive voltage value
(+5 V is commonly used). However, if positive voltages are applied to the inputs of the
summing amplifier, the resulting output voltage will be negative. Often this is not a problem, but
if it is, then appropriate steps must be taken to convert the output voltage from negative to
positive.
Experimental Procedure
Design a 3-bit D/A converter using the summer circuit shown in Figure 1. Use values roughly in
the 10 k to 100 k range for the input resistors R0 through R2. Choose the value of the
feedback resistor Rf of the summing amplifier so that the binary number 111 produces an output
voltage of –1.4 V. The output voltage increment will therefore be 0.2 V with eight output
voltage values ranging from 0 to −1.4 V. Note that, since you must use standard values for all of
the resistors in your circuit, you might not be able to create the exact resistor ratios that you
want. Try to get as close as possible to your design values, but don’t spend too much time
working out a solution. After all, the resistors available in the lab don’t have very tight
tolerances. Also, remember that you can always combine resistors in series and/or parallel to
obtain non-standard values, but for practical reasons you should limit such combinations to no
more than two resistors. Record all details of your design in your notebook, and then complete
the following tasks and/or answer the following questions:

A binary input value of 0 is implemented in the circuit shown in Figure 1 by moving the
appropriate SPDT switch to its lower position. This effectively adds 1 k of resistance in
series with its associated input resistor. For example, if the middle switch in Figure 1 is in its
lower position, 1 k is added to R1. Briefly explain why the addition of 1 k to the input
resistors in the 0 state will not affect the operation of the circuit.

Suppose that you would prefer the analog output voltage vout to range from 0 to +1.4 V
instead of 0 to −1.4 V. How could you modify the circuit shown in Figure 1 to accomplish
this?

Construct a D/A converter with an output that ranges from 0 to +1.4 V, and create a truth
table like the one shown in Table 1 for your circuit by measuring the actual output voltages
obtained for the various input combinations. Use the 0-6 V section of the bench-top power
supply to create the +5 V needed to represent binary 1. (Be sure that all power supplies used
have a common ground.) Create a logical 0 state at an input by moving its associated SPDT
switch to the lower position, and create a logical 1 by moving the switch to the upper
position. Measure the output voltage using the bench-top voltmeter instead of the
oscilloscope, since the former does a better job of measuring DC voltages. Also, the
voltmeter will allow you to measure voltages to at least three digits of accuracy.

Compare the output voltages you measure to the intended (desired) output voltage values for
each input state. Explain any significant discrepancies.
3
Download