EEVblog #204 – Designing a Li-Ion Battery Gauge with the LM3914Posted on September 29th, 2011 33 comments
How to design, prototype and test a two cell 18650 Lithium Ion battery pack level gauge using the classic LM3914 dot/bargraph display driver chip.
A favorite from Dave’s youth!
Dave gives you all you need to know to implement a simple expanded scale voltmeter with the LM3914, without adjustment pots to tweak.
This one works from 6V to 8.4V – the usable capacity of a two 2 cell 4.2V Li-Ion batttery pack.
Hi, I’m from Mexico. Recently I found your Blog an it’s very interesting. congratulations. It is nice to “remenber” old circuits I liked to “play” when I was a teen. Do you know (I’m sure) that it’s posible to make an osciloscope with NS3914 and it has good bandwith.
Do you know these oscillosocope ?http://www.gabotronics.com/development-boards/xmega-xprotolab.htm
Thaks Dave and if you come to Mexico (I do not for what ) let me know.
My english is not so good but I hope I can comunicate.
Maybe this is a stupid question, but why not take a tap off one cell for your signal instead of using a voltage divider to divide the voltage from both? They should keep even charge between them and you could eliminate two resistors from your circuit. Am I missing some fundamental?
There are battery packs that will allow you to pull current from either one or two of the cells, aren’t there?
I laughed when you mentioned the foolishness of using a microcontroller for this kind of thing.
I immediately though of how a software engineer might do this if he’s new to analog electonics…
* 1x Arduino Mega (with dedicated 9v battery)
* 1x 14 bit ADC
* 1x opto-coupler
* 2x 74hc595 shift register
* 10x Super-mega-insane brightness purple LEDs
* assorted 0.5% tolerance resistors
* 1x very large oversize project box
great episode, more of these, now I know how to design electronic equipment
greetings from Poland
looks like I want to try this
Thanks for taking us through the design process from beginning to end. I don’t know of any other site doing this and it has been really helpful to me.
Nice video as always! Have to get some LM3914:s for play.
Resistors & Breadboard:
Instead of peeling off and cutting one should cut them off straight from the roll saves the trouble of cleaning the floor/bench afterwards.
Are you still selling your μCurrent adapter?
Hi there, my comments were made in a light hearted mood, and I am also a beginner myself (I’m technically a Windows/Linux programmer as my full time job). I was merely using my own “trajectory” into electronics as a way to get a cheap laugh about how sometimes people with a certain background would likely make too much work for themselves – instead of an old-hand at electronics that might make the cost effective design from the outset.
Actually, contrary to my joke, there’s really nothing “wrong” with using a microcontroller to monitor a battery’s capacity. There are certainly many applications where this would be a valid approach, but the thing about a microcontroller is that it’s a complex part. Microcontrollers tend to be used at the centre of a design instead of at the periphery. In a world where the selection of integrated circuits is so rich, chances are that you’ll be able to find a low-cost part that does exactly what you want without resorting to a microcontroller.
In most cases it’s not cost effective to use a microcontroller when a targeted IC exists. And lets not forget that microcontrollers need firmware – which means paying someone $$$ per hour to write it!
But that’s thinking commercially – if you’re hobbyist then there absolutely no reason not to use a microcontroller if you have one handy.
You’ll always learn something by having a go. But that tends to be expensive too, so it’s “horses for courses” – as a certain blogger might put it.
Aye, this is what I signed up for. I like a bunch of the ‘other stuff,’ but the walk-through process is intellectually gratifying, and, of all things, useful. Thanks.
Thanks much again Dave for some fantastic information!
I’ve been looking at 18650 Li-Ion’s for a project and these seem to be the way to go for future portable designs.
I really get the point of your tutorial, and although sadly the design will use more current than a micro which say ‘wakes up’ every minute – (my project will use a micro) – your ideas, calculations and design for this are great!
BTW, I’ve been given a near-new cordless drill
with blown nicads (no temp monitoring) and
was going to power this with Li-Po’s but
the danger factor makes me think it better to get some ‘protected’ 18650 batteries instead.
I used this chip about 15 years ago. Rather than LEDs, outputs where grouped using OR gates to power on different system components depending on the power levels available.
Hey Dave, Awesome video.
I am wondering, while you had the issue of the LED turning off with that multimeter, did you have the same issue with the fluke?
I’ve measured resistor divider directly between pins 4 and 6 and it is 11k4 or 11k6. This could be probably used in formula instead of nominal value.
this gauge works well on my 2w incadescent light powered by 2li-ion 3.6Ah pack.
I really like the “How to design this product” style and the walkthrough nature of it. Please make more videos like this! Ps. i tried to make a 12v car battery monitor for my father in law using the exact same chip but gave up on the resistor divider stuff. Now i see how i should have been done
Thank you Dave!
Hmm… I’d better spell check prior to clicking Submit Comment next time.
Awesome! This is what I’m talking about! Instructional and fun. Thanks Dave.
Was there a spaghetti monster (FSM) in there?
Anyway, great show, thanks — Pontus
Thanks, Dave. This was really good. I too would like to see more tutorials like this one.
Hi Dave –
Thanks, nice tutorial! I bet you have driven NS / Mouses sale of LM3914 to new heights!
A bloody ripper tutorial Dave, keep ‘em coming!
The LM3914… oh the memories! (circa 1981 for me). Only addition I would make is a momentary switch to keep the circuit powered down until a reading is desired. Beauty Dave!
Im am trying to use an LM3914 and 10 segment LED display by kingsbright. I loved the video, however, I think Im gonna need your help on this one.
My Rhi is 9.44 volts and Rlo is 7.75 volts…however, as you mentioned the LM3914 will never get to the highs on my display, so you have to use a voltage divider off of pin 5. If I do that my new voltage ranges are from 4.72 to 3.875 volts for my Rhi and Rlow respectively…This puts it well outside the 1.25 voltage reference source…I was wondering if it would work to put another voltage divider at pin 8 (Reference Adj) so that the voltage measured across pin 7 and pin 8 would only read .0625 volts as well as continueing to use the voltage divider circuit accross pin 5? If this wont work, how the heck do I do this?
Hi…I made this circuit…But I have come across a problem….only my 9th led, led at pin 11 is glowing and none else….do u know what might be the reason
voltage divider resistors= 15K n 5K…tried both
C= 10 uf
1 Trackbacks / Pingbacks
[...] simple chip that does exactly what I want. A great resource to know how to configure this device is this video by Dave [...]
Leave a reply