DAC: Non-linearity, non-monotonicity and midpoint glitches

Article By : Don Dingee

Here is a sneak peek of DAC anomalies that system designers should be aware of and what can be done to address these DAC-related issues.

Digital-to-analog converters (DACs) turn bits back into sound, images, or positions. Chipmakers work very hard to create reliable and accurate DACs. Still, sometimes there is a hiccup, putting a ripple in output waveforms. Non-linearity errors can add up, while its cousin non-monotonicity can present a bigger problem. DAC midpoint glitches also can launch sizable spikes into otherwise smooth signals.

Here’s the short version of DAC anomalies makers should look for, and what can be done about them.

No missed codes, but missing the line

In theory, a DAC doesn’t miss codes—there’s an analog output for every bit combination of inputs. Ideally, the output should produce a straight line in response to incremental bit value increases. There’s always a small bit of quantization uncertainty, usually much less than the step width. Non-linearity shows up in two forms.

Figure 1 Non-linearity shows up in the form of integral non-linearity (INL) and differential non-linearity (DNL). Source: Texas Instruments

Integral non-linearity (INL) measures how far the output strays off the ideal straight line. Differential non-linearity (DNL) measures the stability of the step width at each step across the range. In an imperfect world, DNL causes steps bigger or smaller than the desired width, and in extreme cases, contributes to non-monotonicity we’ll discuss shortly.

In lower resolution converters, INL may be significant, as much as an entire bit off. If positional accuracy is important, moving up in DAC resolution is a good choice. As resolution increases, DNL usually becomes the dominant factor, showing up as unwanted noise in the output. Parts designed for audio or video usually optimize DNL along with distortion to keep cleaner outputs.

Non-monotonicity can rub the wrong way

Monotonicity is a bad thing in a speaking voice, but a good thing in an analog output from a DAC. One would expect the output to track the input. If the digital input increases, the analog output should increase. Sometimes, depending on how the DAC does its magic and where the signal is on its transfer curve, a bit increase results in a dip in the output before resuming an increase at the next higher bit input.

Figure 2 DNL is often used to infer DAC monotonicity and to determine if the DAC has any missing codes. Source: Texas Instruments

If it shows up, non-monotonicity can be bad. Suppose the DAC output drives a motor—pushing it briefly in the wrong direction at a critical transition. It’s the scenario that drives analog control engineers slightly crazy. In some cases, a small transient error might not break through mechanical inertia and friction. Some applications may need precision DACs with more careful design and thorough calibration for guaranteed monotonic behavior.

Midpoints switch a lot of current all at once

DACs are susceptible to problems at the midpoint, where the code switches between mostly ones (say, 01111111 for an eight-bit word) and mostly zeroes (10000000 for an eight-bit word). Everything is switching inside the part with all the bits in motion, and the resulting current surge can show up as a glitch in conversion. In fact, chipmakers often test for and specify “glitch energy” describing how big and how long the effect lasts. Note this is a different effect from the DAC settling time or DNL; it’s an output change much bigger than it should be for a one-bit step.

Figure 3 Here is a conceptual time-domain view of a 16-bit DAC midpoint glitch. Source: Texas Instruments

For a DAC, low pass filtering the analog output can take out some of the glitch energy, or a more complex external sample-and-hold circuit may be needed to deglitch the output. Another tactic for mitigating glitches in DACs is avoiding the midpoint altogether, scaling and offsetting signals to use only half of the converter’s range in operation. That may need some pre-processing of the digital data before sending it to the DAC.

Oscilloscope can help makers deal with DACs

If you’re hearing popping in audio or seeing imperfections in video coming off a DAC, hunting the problem down will take more than a digital multimeter. Working with a DAC is a good reason to invest in an oscilloscope. Triggering may be a fun exercise and using a scope with deep digital storage may help in capturing the anomaly.

Where most analog-to-digital converters (ADCs) don’t need as much analog expertise to use them, DACs are easy to hook up but may require some analog care and feeding to perform well. Again, we’re at the point where chip designers have seen a lot of the potential problems and are optimizing DACs for specific applications, which helps makers choose the right parts.

This article was originally published on Planet Analog.

After spending a decade in missile guidance systems at General Dynamics, Don Dingee became an evangelist for VMEbus and single-board computer technology at Motorola. He writes about sensors, ADCs/DACs, and signal processing for Planet Analog.

 

Leave a comment