I was looking around for the best way of measuring 12v from car battery (actually, an onboard caravan battery) for a monitoring box I'm working on. The majority of the advice out there is a voltage divider. Acknowledging it's the easiest and cheapest way to do it, I don't like it due to few reasons:
- Resistors, even 1%, are not very accurate, meaning the reading is not very accurate.
- The reading will change due to different temps inside the caravan
- The battery will be in the range of 10v to 15V (actually the range is narrower, but I'm going crazy here), so why wasting huge range of low reading which will never be used?
So, my idea is to build a subtraction circuit taking the 12V, subtract 10V with zener and push the output to Arduino. I just wanted to run my idea with you guys and see if I'm missing anything.
By using LM324 (op amp) in in the following setup:
Where R3 and R1 are the same (so no amplifying), and V2 is 10v zener between 12v and 0v, will allow me to get a 0v to 5v when V2 is 10v - 15v.
(credit to this article: http://www.electronics-tutorials.ws/opamp/opamp_5.html)