Well when you are reading a sensor, but that sensor, has some kind of craziness, We can built a Adaptative Filter like the next program. The proyect and the source code are on that, but you remember this equiation:The famous linear regression equation...