I am working on C8051F120, I am getting a problem in ADC value.
When I am working on Internal Oscillator (24.5 MHz), my PLL Setting makes SYSCLK as 98 MHZ. My Reference is provided from external source (3.0V). when I read 1.5V value on any channel, I get 2048 (which is correct). But when I change the Oscillator to an external one (25MHz), my SYSCLK becomes 100MHz. with all the same settings and no change in the code, my ADC starts reading it as 2080 instead of 2048. I had tried reducing SAR Clock value and also tried increasing the Settling time by providing a much bigger delay but the result is unchanged.
Had anybody encountered such a problem ?
A change as big as 1.5% should be easy to verify with a multimeter. No need for a calibrated multimeter with a high precision, since we are talking about a quite big relative change.
And while a multimeter is bad at handling noise, multiple ADC reads by the processor should work well to notice if the analog signal contains lots of noise - if the measured value only varies in the last big of the ADC value, there is very little noise. If the ADC value jumps many ticks up/down, then it isn't too meaningful to consider a change of the mean value. The noise problem should first be taken care of.