Bob Axtell wrote: > Averaging is really the best way to get better A/D.. > > I average 4 samples, once per second. The structure is a bucket > with a hole in it; when the new sample goes into the bucket, the > oldest drops out. I then shift twice to get the average. Averaging is one way to get more resolution from multiple readings of a continuous stream, but rarely the best. Note that the average you describe is really a box filter, which is a sinc function in frequency space. I usually use a 1 or 2 pole low pass filter, which is very easy to compute and requires less state than an average. ***************************************************************** Embed Inc, embedded system specialists in Littleton Massachusetts (978) 742-9014, http://www.embedinc.com -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu