the October 6, 2008 "Tips from Titus" column I made an error that
would confuse readers. There are two ways to correct the error, which occurs in
the section about using a 16-bit converter.
First: Substitute an 8-bit ADC for the 16-bit ADC
used as an example in the column. An 8-bit ADC has about a 48 dB dynamic range.
Thanks to Dr. Carl Dreher at Samsung Telecommunications America for pointing
out this solution.
Read the revised column below that uses a 12-bit ADC in the example and
includes comments from Hans Weedon of Analogic:
In my previous Tips column (Sept. 22,
2008), I noted my rule of thumb for sampling at five to 10 times a signal's
bandwidth. That range provides a good starting point, but you can better
determine a sample rate for given signal conditions. To start, assume you have
a signal that includes unwanted harmonics, noise or other signals of no
interest. To remove these signals you use an anti-alias filter - usually a
low-pass filter - so your analog-to-digital converter (ADC) "sees" only the
signals of interest.
Unfortunately, you cannot make a
"brick-wall" filter that, at a specific frequency, instantly goes from passing
all signals to blocking all signals. Filters have a characteristic roll-off
that attenuates signals at different rates. The roll-off varies by filter type
and the number of filter stages or poles. A 2-pole low-pass Butterworth filter,
for example, provides a shallow attenuation with frequency whereas an 8-pole
Chebychev low-pass filter offers a steep attenuation. Filters also have a
characteristic cut-off frequency (fc), specified as the point at which filter
attenuation drops to and stays below -3 dB.
I'll use a 5-pole Butterworth filter as
an example and you can see its response in the graph, below. This filter starts
to roll off at about 650 Hz, the highest frequency component I want to examine
in my unknown signal. This low-pass filter reduces the signal power by half (-3 dB) at 1
KHz, and by 1000 fold (-30 dB) at 2 KHz.
the original column, I erroneously calculated a 48 dB dynamic range for a
16-bit ADC. Hans Weedon of Analogic in Peabody, MA said, "What a minute,
you got it wrong. The dynamic range for a 16-bit ADC is more like 96 dB, or
even 98 dB for a sine wave." He's
right and I apologize for leading readers astray with my poor attention to math
details. Dynamic range = 20 * log (2n), where n represents the
resolution in bits. In my haste, I used
a factor of 10 (which works for power) rather than 20, which applies to
voltages (amplitudes). I have reworked
the example with a 12-bit ADC and the revised information follows:
Assume I plan to use a 12-bit ADC to
digitize my signals. That converter has a dynamic range of 1 part in 4096, or
about 72 dB. Dynamic range = 20 * log (212) = 20 * log (4096). Look
at the filter graph and you'll find the -72 dB point at about 5,280 Hz. So,
even though I use a filter to try to remove signals above 650 Hz, my ADC must
digitize signals out to 5,280 Hz. As a
result, I need to set the ADC to sample at more than 10,560 samples/sec or my
digitized data will include aliased signals. So, even though I want to digitize
a 650 Hz signal, with this filter configuration I must oversample at more than
about 16 times the frequency of the signal I want to measure.
You can change filter characteristics
to obtain a sharper attenuation. An 8-pole Butterworth filter with an fc equal
to 880 Hz, for example, reaches the -72 dB point at 2,785 Hz. So you would
sample at more than 5,570 samples/sec, or over eight times the 650 Hz signal
frequency. Both sample rates in these examples come close to my rule of thumb.
(In a conversation with Hans Weedon, he recommended sampling at a rate at least
four times the Nyquist rate.) If I had a higher-resolution ADC, it would offer
a higher dynamic range, so the sample rate would have to increase accordingly.
And other considerations become more important at higher resolutions. So, keep
in mind there's more to sampling than
just the Nyquist criterion.
There are other reasons to oversample a
signal and I'll cover them in another column. If you want to experiment with
filter characteristics and anti-alias filters, I recommend the free FilterLab
software from Microchip Technology.
Hans Weedon also added some additional
helpful information in a second email message:
There is one statement, however, where,
although completely correct, there is a point of possible confusion. You state
that 30 dB is a factor of 1000 reduction. In power that is correct, but as far
as signal integrity that is only a factor of 31.6, not at all much to talk
Consider for instance the case of audio
digitizing. A normal listening environment require about 50 mW of power from
the amplifier, yet we use power amplifiers with 100W maximum output power. That
is only 33 dB above 50 mW. Music easily has 20 dB of dynamic range, so an
amplifier that normally outputs 50 mW must be able to output at least 5W to
cover the dynamic range of the audio program.
Where I want to go with this is that as
far as normal audio digitizing is concerned much more than 30 dB is required,
actually 30dB is less than the instantaneous dynamic range of a listener with
about a 40 dB range. A typical audio digitizer requires about 50 dB
instantaneous dynamic range.
As far as instrumentation is concerned,
30dB may not be good enough either. Distortion of 0.5% could be considered
reasonable in a digitized signal system and 0.5% distortion is 46 dB down from
the signal. Still more than the 30 dB.
We live in a world with requirements of
about 1000 to 1 dynamic range in the signal domain, which in the power-domain
is 1,000,000 to 1.
This whole story basically states that
to accurately digitize a signal we really need very aggressive anti-aliasing
filters. These filters are hard to build and require expensive capacitors and
inductors to work well. Active filters are not that much simpler than passive
Thirty years ago, when accurate A/D
converters cost more than $100, spending $50 on an anti-aliasing filter was not
that outrageous, but today with A/D converters costing less than $5, spending
$50 on anti-aliasing filters is uneconomical. The A/D converter technologies
has reduced the cost of a unit by a factor of 100, whereas the cost of a
(passive) filter has not changed. We must work smarter, not harder.
The much smarter way of digitizing a
signal is to over-digitize by a large amount and do the anti-aliasing filter
digitally. A sigma-delta converter does exactly that. A sigma-delta converter
may over-digitize the signal by 256 times and only require a signal anti-aliasing
filter with two poles. A 128-tap digital filter can easily compute a 64 pole
filter, something that inductors and capacitors could never do.
A sigma-delta converter that does this
can be had for less than $5. In other words, to digitize a single signal, a
sigma-delta converter would be the preferred choice.
The high speed A/D converter is much
better suited for use in a multiplexed situation, where many signals should be
digitized in a sequential manner. Take for instance a CT (Computed Tomography)
scanner where you may have 16,000 channels to digitize at a readout rate of
2500 readings per second.. In this case, the multiple multiplexed A/D
converters may be the most economical approach. You would design a very
inexpensive front end amplifier with some anti-aliasing properties followed by
a one A/D converter servicing maybe 128 or 256 front end circuits. The A/D
conversion function then becomes a few pennies per channel.
I have been designing this type of
systems for the last 35 years, and the choice of a few high-speed A/D
converters multiplexed versus a converter per channel is always a design choice
mostly governed by the economics of the situation. The multiplexed A/D
converter may suffer some signal integrity issues, but the alternative approach
of using a converter per channel becomes prohibitively expensive. -- Hans J.