Hi Kevin,
> When I call the ADC_ReadAllChannels() routine once per second in my
> application, the voltages I read are unstable. They are all over the place. I
> may get one or two readings in a row that are about what I expect. Other
> times
> they can be negative or up to 4V.
Could you test one thing;
1. back-to-back reads of the same channel, with no channel change
in between
versus
2. sequential reads of channels.
If you find that 1 is stable, and 2 is not, then I suspect your
channels are not being driven by low-enough impedance.
Without looking at the A/D data sheet, I am assuming you have
one ADC with multiple inputs. When you read say channel 1,
the sample-and-hold capacitor will store the voltage of
channel 1 until its sampled. Then when you switch to channel
2, the sample-and-hold needs to slew to the voltage on that
input. If the input impedance is not low, or somehow creates
a resonant circuit, then the voltage you read when sequentially
going between channels can be bogus. The reading can settle down
after multiple reads, since the sample-and-hold is being
activated on the same channel.
If you probe the ADC inputs, you should be able to see
glitching.
Of course, this is only one of many things that can be wrong,
but no one has suggested it, so I figured it was worth
making you aware of this possibility.
I've had this problem in SPI ADCs, so it definitely occurs
in practice. The solution was to drive the ADC with an
op-amp. If that's what you need to do, then there is a
very nice app note from Ron Mancini at TI that tells you
everything you will ever need. Let me know if you want it,
and I'll track down the reference; 'op-amps for everyone'
is the title.
Cheers
Dave
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/ts-7000/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/ts-7000/join
(Yahoo! ID required)
<*> To change settings via email:
<*> To unsubscribe from this group, send an email to:
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|