.... > > a(n) =3D {a(n-1) * param + ADC} / {param + 1} > > That's the standard digital signal processing single pole low pass filter > formula, although cleverly obfuscated. .... > =A0FILT <-- FILT + FF(NEW - FILT) > > And voila, we have the basic standard digital low pass filter algorithm All (almost)good stuff. Work through that and it should be pretty clear. But for the uninitiated it may get a bit head spinning along the way, even though every step is simple. Another way of expressing the same result is New value =3D ( Latest_sample x n%) + (Old_Value x (100-n)%) for 0 < n < 100 Here n/100 =3D =3D Olins filter fraction. ie The 100% of the new value is made up of: n% of the new sample, with the balance of 100% being made up of (100-n)% of the old value. Which may be as clear or unclear as how Olin expressed it :-) (Identical statement, different words) Russell McMahon --=20 http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .