Digital Voltmeters – The Fundamental Device for Measurement Engineering – and the Modern World.

Analogue-to-digital Converter types.

Analogue-to-digital Conversion

In one of the earliest articles from this series, we briefly looked at Galvanometers and discussed how they formed the core of many electrical sensors of their day. Today, we’re looking at the device that replaced them.

In its purest sense, a digital voltmeter is not a transducer, whereas a galvanometer converts current into force, and therefore electrical energy into mechanical work, a digital voltmeter turns voltage into more voltage, just in different bits of a silicon chip. However, I get to decide what we write articles about, and I think they’re interesting, so here we go anyway.

Many of us have used a digital voltmeter, either in science classes at school or using a multi-meter for DIY projects or at our jobs. How many of you realised at the end of the day a multi-meter is really just one sensor?

Modern multimeters can measure current, potential difference (voltage), resistance, continuity, and often more, all based on an analogue to digital converter, or, a digital voltmeter.

The analogue to digital converter, known as an A to D, is one of the most fundamental devices in the modern world, but what does it actually do? When we hear the word analogue, we think of mechanical clocks, we think of old TVs, radios, amplifiers, but what do we actually mean?

Here, we’re getting a bit into signal theory, which is fine, I think signal theory is interesting too! Fear not dear reader, I’ll keep it brief.

Let’s take the example of a radio signal. We all know that there’s digital radio and analogue radio. How exactly FM and AM analogue work isn’t important, but what they do is create a signal that is directly analogous to the sound they are transmitting. The sound waves, through some clever circuitry, are converted continuously into radio waves. Digital radio, on the other hand, ‘quantises’ the signal, it looks at the signal over a tiny time frame and measures how intense the sound is, and then transmits that information digitally, I.e. as a discrete number for each little bit of time. I am glossing over a whole bunch of complexity with sample rate and the like, but that is essentially the difference.

An A to D converter does exactly what it says on the tin. Analogue signals are continuous, like a stream of water pouring over a waterfall. But computers don’t work in analogue, they work in digital, data that comes in discretised bits. Continuing the water analogy, it would be like moving water with buckets, each bit would be how full the bucket is. If we want to record and process an analogue signal digitally, we need that analogue signal in digital form.

Digital processing on semiconductors is conducted using voltage. Operations at the level of the ‘gate’ where the Boolean operations actually take place, are done, typically, by comparing voltages with semi-conductors rather than by current comparison. Therefore an analogue to digital converter is, in essence, quite simple; compare the voltage level and record it. However, gates have a threshold, they are either open or closed, on or off, 1 or 0. We could have a gate that opens at 5v for example, but that would only allow us to tell if the signal is above or below 5 volts. It’s not a particularly great conversion to digital.

Analogue (Original Sine Wave), High Bit Depth, (4 bits) and Low Bith Depth Signal Comparison

So instead we need a way to encode voltages across a range, typically just with comparator gates (open when higher than, lower than, or equal depending on configuration). There are several techniques to do this that are split into two broad types, high bit depth, and low bit depth. High-bit depth ADC’s attempt to convert the signal directly into a representative value encoded to a set digital number, be that 8, 16, or 32 bits in one sample, typically just above the Nyquist frequency of the signal we are trying to capture. The other approach, low bit depth, instead attempts to produce intermediate encoding, typically just with one bit, that can then be summed to encode the whole signal. To do this the ADC samples far above the Nyquist frequency, normally at least 64 times higher. Naturally, like nearly anything in engineering, the types have both advantages and disadvantages. Luckily for us, both approaches are quite interesting and worth looking into!

There is a lot of variation within the high-bit depth types. One of the earliest was invented by Denys Wilkinson. This used a capacitor with a known capacitance that was charged from a voltage signal. A comparator opened when the voltage across the capacitor matched that of the measured signal. By counting the number of clock counts as the capacitor was discharged the voltage of the input could be calculated.

There are many variants of A to D that are ‘descendants’ of this type, based around ramps, a single comparator, and clock ticks. They are relatively accurate, especially if the clock ticks at a high rate. Resolution can be exchanged for sample rate, as the resolution of voltage level is determined by how many clock ticks are between samples. If you have 1000 clock ticks a second (in reality they are millions of times faster), and want to measure a voltage range between 0 and 10 volts. Your resolution is 0.01 volt, if the ramp takes 542 ticks to fire, that means it’s 10.00 – 5.42 volts or 4.58. That assumes it’s all nice and linear, but for this example, let’s make just that assumption. If you need to sample at 10hz your resolution drops to 0.1 volt, at 100hz down to 1 volt of resolution. This is the challenge of instrumentation and test, the trade-off between sample rate and resolution drives equipment selection and cost. Accuracy over a long period is easy, very high sample rates are easy, both together is hard. Hard in engineering is essentially a byword for expensive.

Another approach is called successive approximation. Here a single comparator is used as before, keeping the lithography relatively simple. However, rather than being coupled with a capacitor or some other ramp generator, it is paired with the opposite of an analogue-to-digital converter, the digital-to-analogue converter. The successive approximation approach finds the value of each bit, going bit by bit until the set precision is reached.

You start by encoding the first bit, the d to a is set to the half range, for a 10-volt range, that would be 5 volts, and the measurand and the comparison signal are sent to the comparator. If the measurand is higher, the first bit is encoded as a one, if lower it is encoded as a zero. The a to d then moves to the second bit. If we are measuring a signal that is 7.432 volts, we have already established that it is higher than 5 volts, the second check is if it’s above 7.5, or more specifically, if the second bit, should be 1 or 0, representing an additional 2.5v. In this case, 7.432 is lower than 7.5, and so the second bit is 0. Next, we check the third bit, 1.25, or higher than 6.25 total, which is true or 1. Then we check for 0.625, or a total of 6.835, which again is true, so 1. Now we have encoded up to 1111, we can go onward and onward approaching a value of 7.432.

A Basic Diagram of a Successive Approximation Analogue-to-digital Converter

This is a slight weakness of the successive approximation approach; it will always underestimate the measurement by some margin. However, depending on the tolerance of the comparator and the accuracy of the signal the digital-to-analogue generator can produce, successive approximation can produce incredibly high levels of accuracy. As with the clock-based approaches, the trade-off between accuracy and sample rate once again arises. There are some combinations of the ramp-based and the successive approximation approach.

There is one approach that has no trade-off between sample rate and accuracy. This is called the flash a to d and is built of many comparators, a voltage source and a bank of resistors to break down the voltage into steps. When a signal is sampled the comparator measuring against a certain step in that voltage source will fire. This means that the flash a to d can sample extremely quickly at very high accuracy at the cost of a large complexity of the circuit.

All these types have a severe limitation, they are dependent on very accurate components, either to generate very repeatable ramps or comparators that are accurate over tiny voltage differences. This is possible, but to create very accurate ADCs using this approach results in an extremely high cost.

What if we could take a different approach?

Earlier we looked at a comparator that would fire for a signal above 5 volts, this let us simply tell if a voltage was higher or lower than 5 volts. But we still can tell if the signal rounds to 0 or 10. If we were doing successive approximation, we would then use a digital-to-analogue converter to set up a new comparison and code the bits one by one in this manner seeing if the value rounds to more and more precise figures. But what if we had a way of setting up the circuitry so it would, over several samples, produce an average? If we had 9 volts for example, and we were measuring across 10 samples, or 10 clock ticks, it would fire 9 times high, and one low. Averaging to 9 volts. But how do we set this up?

There is a bit of circuitry called a delta-sigma (or sigma-delta) modulator that uses a differentiator, the delta, and an integrator (sigma or summation) that produces such an effect based on feedback. The key to the delta-sigma modulator is the integrator. An integrator essentially produces a summation of previous inputs to it. Now, this would just produce an increasing output if we fed the signal directly to it. Instead, we take the output of the integrator and feed that into the one-bit DAC that actually does the conversion, essentially a single comparator that is sampled at a given clock speed. We then feed that back to the start to a subtractor that finds the difference between the input and the output signal. If the input is still higher then the feed into the integrator is positive and the integrator continues to grow, if it’s lower, the opposite happens. Continuously repeated this means that the modulator is minimising the error between the output and the input. The output feed from this modulator is then down-sampled by averaging (typically by much more sophisticated means than block averaging) to produce our final analogue to digital conversion at high bit depth.

A Simple, 1st Order, Delta-Sigma DAC

This has huge benefits, not only can these converters work at a high sample rate with high frequency but they also have the effect of noise shaping. How exactly this happens goes beyond the scope of this article, but integrators have the effect of shifting the quantisation noise to higher frequencies. We can design this shift to move the noise to higher frequencies than the range we are interested in so we can massively improve our signal-to-noise ratio.

In the modern world, typically the choice is between Successive Approximation (also termed SAR) and Delta Sigma converters depending on the exact requirements.

Engineers and designers get the choice of exactly which ADC to use depending on the answer to several questions. What sample rate is appropriate to capture the signal? What accuracy and resolution is required? Do we just need the first order of the frequency? Or the second, and third orders as well? All of this is then balanced against budget and operating conditions. Does the ADC need to capture small variations in the output voltage of a thermocouple? Does it need to capture the voltage drop across a shunt resistor to calculate current? The tiny voltage differences across a Wheatstone bridge to capture the change in resistance of a strain gauge?

This is the key challenge in Flintmore’s work, how transducers, measurands, and requirements of the client all combine to define the problem that needs to be solved. From our extensive inventory of analogue to digital equipment we then design a system to meet those needs, supporting it across the lifecycle of the project.

Do you have a task requiring analogue to digital conversion? Contact us to discuss your needs, options, and routes forward!

Further Reading

This video, and the series it belongs to are fantastic, give it a watch if my attempted explanations have left you scratching you head!

SAR and delta-sigma: Basic operation

The Wikipedia article on analogue to digital conversion is extensive and gives background on a huge variety of types not covered here, some of the explanations are very very good, others I found a bit lacking in clarity. It’s worth a read however to expand your knowledge of converter types:

https://en.wikipedia.org/wiki/Analog-to-digital_converter

2 responses to “Digital Voltmeters – The Fundamental Device for Measurement Engineering – and the Modern World.”

  1. […] a useful temperature range. Because the effect is strong, we can use thermistors with much lower quality A to D converters, as the larger deviations in resistance are much easier to detect and the effect of lead resistance […]

  2. […] to be used on printed circuit boards alongside micro-processors. Typically these sensors have an A to D (analogue to digital converter) incorporated with them which allows them to communicate directly in […]