ADC problem resolution

Following up on this, as I sat and thought through the problem (different calibration slopes between positive and negative trending values) I figured it out. The filter on the ADC monitor was at fault, it was doing a divide by 16 with integer math, so as soon as you got within 16 of the target, it stopped approaching. Which means that the same voltage going up and coming down could be represented by a value up to
32 counts apart. I could have applied an adaptive filter so as you approach the target, the filtering gets less, but I have only just now thought of that.

Instead I implemented an average (box filter) of the last 8 readings, I think 16 would be better, but the buffer wouldn't fit on these tiny controllers. As it is there is very little "wiggle" and the two slopes are the same, it's measuring very dependably within 0.1v and usually within about 0.03v or so. I claimed this as finished and soldered in the controllers. There are no onboard provisions to reprogram them so I needed to get it right.

Subject: