How to continuously monitor the voltage of a 12v battery without draining it
william chan
Posts: 1,326
Here is a difficult problem.
How to continuously monitor the voltage of a 12v battery while draining as little current as possible?
If your ADC's range is only 0-5v, you would need a voltage divider to reduce the battery voltage.
Unfortunately, the voltage divider itself would unnecessarily drain the battery.
How now?
How to continuously monitor the voltage of a 12v battery while draining as little current as possible?
If your ADC's range is only 0-5v, you would need a voltage divider to reduce the battery voltage.
Unfortunately, the voltage divider itself would unnecessarily drain the battery.
How now?
Comments
If your voltage divider is made of resistors in the megaohm range then the current draw will be down to micro amps.
You will of course need a high impedance on your ADC input. Which they generally are.
I suspect that you or your battery might die of old age before the battery gets discharged.
Then the question is, where does the power com from for that ADC and whatever is connected to it?
You say "continuously monitor" while draining as little current as possible. Where are your actual parameters? If the battery is supplying a lot of current it might pay to continuously monitor it every minute or even maybe every 10 seconds, not "continuously". If the battery is supplying a lot of current then why can't the monitoring micro draw a measly 20ma? If the battery is not supplying any current then why continuously monitor it?
On the other hand, if it's a tank battery I would not worry
I currently use the Propeller's sigma delta ADC which seems to have around 100k impedance,
so the voltage divider's impedance had to be much lower than that.
So when the Propeller chip goes into hibernation, the voltage divider will continue to drain the battery.
At this rate, I estimated the lithium polymer battery would be over-discharged within 3 weeks. ( which is a bad thing )
Get yourself a 24 volt supply.
Make a potential divider from that 24v to ground with a pot and a resistor.
Arrange to measure the voltage at the center point of the divider.
Connect the center point of the divider to the battery with a moving coil amp (micro-amp) meter.
Arrange to have the pot adjust to keep the meter reading zero all the time.
In that balance condition the voltage you are now measuring is the voltage of the battery. But there is no current flow!
Of course when we did this the divider was a meter length of resistance wire with a sliding contact on it. There was no voltage meter, just work out the voltage from the slider position. The moving coil meter was a tiny coil suspended between magnets with tiny mirror attached. A laser bounced off that mirror indicated any current flow in the coil down to pico amps!
I know. Overkill. But fun. Just rambling on old times again...
Thanks a lot.
One just made for that , use a 100K pull-up resistor.
http://www.mouser.com/ds/2/308/NTJD1155L-D-223159.pdf
though any dual mosfet will work, example
lhttp://www.mouser.com/ProductDetail/Fairchild-Semiconductor/FDG6320C/?qs=/ha2pyFadujhT0V6uAIHGKOI0FdjFoQRkSRBoJ5kg90=
btw, a 2 cell lithium is not a "12v" battery. Having the proper details up front helps us help you better.
That is no longer the same wording, and thus a different problem.
Again, more changes in design brief, and you need numbers to define what is tolerable to you.
That is what design is all about.
As you allude, any voltage divider has some current cost associated. True Zero is not possible.
However, microamps are possible, so you need to define how many microamps constitute "unnecessarily drain the battery."
You can add a series switch, to time multiplex a divider if you are forced to use a high-drain divider, but remember that timing/switch action, also has a current budget.
Numbers also define what you need.
eg you can buy 10M resistors, to 0.1% precision, which will load a 10V battery to 1uA, but they are not cheap.
You may be able to tolerate lower R, or relaxed precision.
5% come for well under 1c in modest volumes.
1%, ±100ppm/°C are around 2c in modest volumes
0.5%, ±50ppm/°C are ~ 4c in modest volumes
..and so the design process goes, matching what you can get, at a price you can tolerate, for what you need to do.
-Phil
Do you mean that if the Sigma-Delta input and feedback resistors are of very high resistance, there is no need for a voltage divider?
Meaning the Sigma-Delta circuit can directly measure the voltage of a 12v battery?
The two resistors are connected in serial. Depending on the compensation output the common signal is Vss or Vss, do the voltage at tapping point is above or below the threshold voltage of the comparator input (~ 1.4V). The point is: the capacitors voltage is kept constant ( +- few mV) when balanced. So the current from the input and the current to the compensation pin are equal (in average). As those currents are proportional to the voltages applied, the resistor value determines the scaling of the input. If you increase the inpedance of the input network (say 100K->1M), you have to reduce the balancing cap from nF to .1nF. It's all about the relation of the components, not actual values. You onlay have to take into account, that higher impedance is more susceptible to noise, leakage current, and my reduce frequency response, all aspects of no relevance when measuring battery voltage.
After the reading is taken, either leave the pin as an input, or make it a high output. That has the effect of channeling the leakage current (a few microamps) back to the power supply, so it helps to power your propeller and is not "wasted". The resistor has to be a high ohms value, because it should never supply more current than can be used by the circuit if for example it goes into a sleep mode, drawing only microamps.
The RCTIME method works, but it is fussy due to the need for calibration, and the Prop threshold drifts a bit with temperature.
Any ADC using Prop1 (Sigma-Delta or RC time) will need calibration, as they inherently have the Prop threshold as a variable.
You can run a second channel, with a voltage reference (which can be a good regulator) to give run-time tracking and auto-calibrate action.
When using this, Vref needs to be >> vth, and if you are using high value resistors, I'd suggest using the same parts for both feed values, for better tracking, and extract the zero correction in code.
eg if we assume 1.65V vth, and 16.5V full scale ADC, a 12V reading is 69.69% and a 3v3 Vref gives 11.11%
You have presented the most simple and elegant solution to the problem which i was struggling with for years.
Your father had taught you well. I am surprised you haven't won the Noble Prize yet.
Your auto-calibrate scheme seems very interesting.
Does it require a switching mechanism to connect the RCTime circuit to either the Vref or the Battery?
As the RCTime charging curve is not a straight line ( linear ), wouldn't it be difficult extrapolate the voltage of a 8v battery based on a 3.3v reference?
Parts from the same tape/reel, as well as adjacent pins, tend to track, which is why I suggested that.
If you want to eliminate tracking errors, then yes, you can use single divider parts, and switch the voltage.
That is more parts and more cost.
What precision do you actually need for this ?
'difficult' has many degrees
The curve shape is known, so you can calculate any voltage.
Sigma-Delta is charge balancing, so it is linear and needs no curve correction.
The primary purpose of the Vref is to more accurately define the P1 pin thresholds.
There are also some cases where you only want charge setpoints, not a human display, and for those you can use compile-time calculations.