Measuring voltage window with ADC

adcmeasurementvoltage

I'm working on my own SLA charger that has MCU onboard, can regulate switching DC/DC converter to charge 12V battery in 3 stages and can do temperature correction.

Everything is fine except that I want to improve on battery voltage measurement.

Currently, I use simple voltage divider to reduce battery voltage range into MCU's ADC range of 0-1.8V. The thing is I don't care of battery voltage (let's say) less than 10V because that is a bad battery and I don't want to charge it at all. I would like to map 10-16V into 0-1.8V instead of 0-16V into 0-1.8V so ADC measurement could be done more precise:

enter image description here
What can be used to archive such mapping (price does not matter)?

Best Answer

A simple but crude method would be to subtract 10V from the measured signal using a zener diode: -

enter image description here

So, if Vin is 16V, Vout will be 6V if the zener diode voltage is 10V. If instead of a single 10k resistor you used a potential divider, the 6V can be "tapped" to give 1.8 volts.

In case you've never used a zener, they have a defined reverse breakdown voltage like this: -

enter image description here

The part of the curve to the right is the "normal" forward conduction operation of any diode - just think about the left hand side.

You can also use a more accurate op-amp subtractor: -

enter image description here

Just set a 10V steady voltage at V1 (maybe with a voltage reference) and the output will be R2/R1 *(V2-10V). You can also "ratio" R2 and R1 to give you the required voltage range of 0V to 1.8 volts. Use a rail-to-rail op-amp for this but be aware that the bottom 20 mV to 50 mV range of the op-amp's output will fixed because although a rail-to-rail device is good it aint that good!