Really simple battery charge indictator

Thread Starter

james211

Joined May 29, 2012
275
Does anyone know of a really simple method for showing battery charge? Even as simple as a red, yellow, green led? Or if there is a simple LED of some sort that would show it as a percentage.

I built a battery powered USB hub and I need to know how much charge the battery has. If I have a battery die while transferring data from one or two hard drives it could make for a bit of a mess.
 

shteii01

Joined Feb 19, 2010
4,644
I can only think of building some kind of comparator circuit.

I have only done comparators using op-amps, but if you have op-amp, you need an external power supply to power it. Which, in turn, means that you don't really need a battery in the first place.
 

bountyhunter

Joined Sep 7, 2009
2,512
Does anyone know of a really simple method for showing battery charge? Even as simple as a red, yellow, green led? Or if there is a simple LED of some sort that would show it as a percentage.

I built a battery powered USB hub and I need to know how much charge the battery has. If I have a battery die while transferring data from one or two hard drives it could make for a bit of a mess.
Comparators sense voltage levels, battery charge is usually not accurately indicated by voltage alone.
 

ronv

Joined Nov 12, 2008
3,770
What kind of batteries, and how low can they go before you have trouble? Is the load constant or can it be one drive running or two running at the same time.
 

THE_RB

Joined Feb 11, 2008
5,438
Comparators sense voltage levels, battery charge is usually not accurately indicated by voltage alone.
Voltage can be a pretty good indicator though, especially if the appliance uses a fairly constant amount of current, which a lot do.

3 light and 1 light battery level indicators are common in appliances and usually just sense battery voltage.
 

bountyhunter

Joined Sep 7, 2009
2,512
If done at a constant load and corrected for temperature, voltage can be a crude method of estimating charge but it is not very accurate.

http://batteryuniversity.com/learn/article/how_to_measure_state_of_charge

Measuring state-of-charge by voltage is the simplest method, but it can be inaccurate. Cell types have dissimilar chemical compositions that deliver varied voltage profiles. Temperature also plays a role. Higher temperature raises the open-circuit voltage, a lower temperature lowers it, and this phenomenon applies to all chemistries in varying degrees.

The most blatant error of voltage-based SoC occurs when disturbing the battery with a charge or discharge. This agitation distorts the voltage and no longer represents the true state-of-charge. To get accurate measurements, the battery needs to rest for at least four hours to attain equilibrium; battery manufacturers recommend 24 hours. Adding the element of time to neutralize voltage polarization does not sit well with batteries in active duty. One can see that this method is ill suited for fuel gauging.
 

wayneh

Joined Sep 9, 2010
17,152
You may like an LM3914 circuit. It's just a bunch (10 I think) of purpose-built comparators for making a bargraph or dot display of a voltage range, which you can control. So if you can define what the top and bottom voltage should be, the single IC will do the rest. Much easier than making your own.
 

ian field

Joined Oct 27, 2012
6,539
Does anyone know of a really simple method for showing battery charge? Even as simple as a red, yellow, green led? Or if there is a simple LED of some sort that would show it as a percentage.

I built a battery powered USB hub and I need to know how much charge the battery has. If I have a battery die while transferring data from one or two hard drives it could make for a bit of a mess.
Usually a simple window comparator made with a couple of op-amps, or you can be really flash and use an LM3914 which has enough comparators for 10 LEDs, it also has a dot/bar mode select pin.

Some really cheap wall-wart battery chargers just use a LED & zener with a current limiting resistor - nothing happens until the terminal voltage exceeds Vz, then the LED comes on dim and brightens up as the battery gets to full charge.
 
Top