I generally average 6-10 samples when the input is noisy. If the noise is predominately 60 Hz, then you should average the samples across 16.6 ms (one cycle), Something like -
Code:ADCSUM = 0 For X = 1 to 10 ADCIN 1,ADCVAR ADCSUM = ADCSUM + ADCVAR PAUSEUS 960 ; Depending on device one Convert + add takes about 700uSec Next X ADRESULT = ADSUM/10
Bookmarks