# How to Calculate Appropriate R-2R D/A Converter Resistor Values?

I am trying to make a 4-bit R-2R D/A Converter where a +5V signal on D3 would output -5V, a +5V on D2 would output -2.5V, etc. How would the resistor values for R/2R be calculated? • awww.. come on?? is your google-fu broken ? skillbank.co.uk/SignalConversion/dac.htm#r2r Mar 4 '14 at 5:41
• The point of my comment is 2-fold.. simply from the equation, the R and 2R can be anything, it doesn't matter, and you usually want to choose them to be high value so as not to load the source too much. Often times the source input D0-D3 is buffered anyways. 2nd... If you see on the link I gave you, there is a formula for Vout. Using that formula, if your feedback resistor is also 2R as you have drawn it, then Vout is not at all dependent on any particular value of R or 2R. Mar 4 '14 at 5:51

To a first approximation, the resistance R cancels out, however things are not so simple.

One factor that needs to be considered is the performance of the switches. If they are CMOS outputs they will have a substantial resistance, it will be different between switches, it will be different for "high" vs. "low" and the resistance will vary with temperature.

Take, for example, a CMOS buffer such as the CD4050. From the linked data sheet, we can see the output characteristics. Let's assume 10V (+/-5V operation).  The sourcing resistance is about 220 ohms, and the sinking resistance about 55 ohms maximum. It will increase by perhaps 40-50% at 125°C from the 25°C values in the graphs.

So, even if we reduce the 2R resistors by some average value of the switch resistance, there will be errors. If you want the error due to switch resistance to be much less than one LSB on your 4-bit DAC, you can calculate a minimum value for 2R. Say we choose something like 100K.

The maximum value of R will be limited by input bias current of your amplifier and noise, and also by parasitic capacitance if you expect the DAC to have good high frequency performance. For example, an amplifier with 200nA of input bias current and with R=100K would have an output voltage error of $2 R \cdot 0.2\mu A$ or 40mV.

That could be reduced in cases where the offset current is much less than the bias current by placing a matching resistor on the non-inverting input of $2 \over 3$ $\cdot R$ since the ladder has a constant impedance looking into the summing node of R.

It's pretty easy to achieve sub-LSB errors with a 4-bit DAC, but the difficulty increases rapidly as the number of bits increases. simulate this circuit – Schematic created using CircuitLab

• I liked your answer. It's definitely important to consider the errors caused by everything in the circuit, including Vos, Ib, Ios and voltage drops across the impedance R caused by those opamp parameters. I didn't consider the AC performance as you did because I would not pick a discrete R2R for AC, but it's useful for setting a DC voltage and I also would use a good DC op-amp. For an AC DAC I would use a packaged solution. Cheers! Mar 4 '14 at 8:17

The R and $2$R can be anything, it doesn't matter, and you usually want to choose them to be high value so as not to load the source too much. Often times the source input D$0$-D$3$ is buffered anyways.

If you see on the link I gave you (http://www.skillbank.co.uk/SignalConversion/dac.htm#r2r), there is a formula for Vout. Using that formula, if your feedback resistor Vf is also $2$R as you have drawn it, then Vout is not at all dependent on any particular value of R or $2$R.

However, the value you choose will add to the load on the power supply. That is why you will often want to choose a high-valued resistor, say $100$k and $200$k, to minimize the load on the power supply.

Also note that the output of an R-R$2$ ladder is always a fixed impedance R. This is the Thevinen equivalent impedance at the -ve input of the op-amp, and what the op-amp sees as it's source impedance. High source impedances to op-amp inputs cause increased thermal noise. Lower source impedances lower this thermal noise. So if you were going for a highly accurate $16$ bit R-$2$R ladder DAC, I would use lower valued resistors like $10$k or $1$k... for fewer numbers of bits the higher valued resistors will be fine. Lower valued resistors will increase current draw and thus power dissipation. This is the trade-off to make.