ChrisKiwi
- 21st January 2011, 12:51
Hi all, Just wondering if anybody has ever come across this before.... just asking in case someone has observed this before....the work around is obvious, but I'd prefer to fix it.
I am using 2 ADC channels to take 3 samples in a loop, configuring the ADC to use the first channel, resetting the ADC, delay 10uS, then the second channel, resetting the ADC, delay 75uS then the first channel again, etc.
The code works fine except for the fact that the first conversion is always about 5 counts low. This channel is supplied by an op amp buffer (capable of supplying +/-30mA), it's input is from CVref output of the PIC. The second channel is supplied from a 10K pot on the development board, with no buffer.
If I reverse the connections to the ADC channels I still get a low first reading.
After the first conversion, every subsequent conversion is stable, regardless of which voltage source is used.
The TAD and Fosc/X are all within the allow parameters and changing them or adding extra delay before the first conversion has no effect.
It appears that after a certain time of inactivity the ADC will always return a low first conversion result. It's kind of like getting in your car on a cold morning and having to give the engine a bit of a rev to really get the car going.
Regards
Chris
I am using 2 ADC channels to take 3 samples in a loop, configuring the ADC to use the first channel, resetting the ADC, delay 10uS, then the second channel, resetting the ADC, delay 75uS then the first channel again, etc.
The code works fine except for the fact that the first conversion is always about 5 counts low. This channel is supplied by an op amp buffer (capable of supplying +/-30mA), it's input is from CVref output of the PIC. The second channel is supplied from a 10K pot on the development board, with no buffer.
If I reverse the connections to the ADC channels I still get a low first reading.
After the first conversion, every subsequent conversion is stable, regardless of which voltage source is used.
The TAD and Fosc/X are all within the allow parameters and changing them or adding extra delay before the first conversion has no effect.
It appears that after a certain time of inactivity the ADC will always return a low first conversion result. It's kind of like getting in your car on a cold morning and having to give the engine a bit of a rev to really get the car going.
Regards
Chris