Hello, i recently purchased the LM3914 dot/bar graph ics. I have gotten this basic circuit from Battery Level Indicator Circuit using LM3914 that i will attach below to work with a 12v battery and i am trying to better understand how it works down to each component. I have looked at the LM3914 datasheet which was a bit confusing
but here's what I'm pretty sure i know about this chip.
The chip takes an analog voltage and proportionally drives 10 LEDs to show the battery level. If i am at a full 12v then all 10 leds would be on. Now from what i understand from this circuit, it actually measures from 1.2v to 12v ( giving you 10 steps or LEDS). Now from what i have seen from other circuits you can actually offset the voltage to measure from 3v to 4.2v for lets say a 18650, but because the Adjust pin is connected to ground so it measures from 0v all the way to 12v.
I think with resistors you can set brightness, the low-end voltage and high-end voltage to set your required voltage range
Can someone give an easy to understand a simple explanation of how this chips pins work and maybe show the math if i wanted to set the voltage range from 3v to 4.2 ( If thats not too much to ask for).
Look at the diagram on page 8 of the datasheet.
You see a voltage divider (string of 1k resistors) inside the chip.
One end of the string is connected to a reference voltage, and the other end (normally) to ground.
Wawa:
Look at the diagram on page 8 of the datasheet.
You see a voltage divider (string of 1k resistors) inside the chip.
One end of the string is connected to a reference voltage, and the other end (normally) to ground.
Reference voltage is divided equally over the string of 1k resistors.
10% on the first tap, 20% on the next tap, 30% on the next, etc.
The comparators each compare input voltage (the battery) to the voltage on their tap.
If a comparator senses that input voltage is higher than their tap voltage, the corresponding LED is turned on.
It should be clear that the comparator with the lowest tap voltage is the first to turn on when input voltage rises.
Think old fashioned balance scales.
You put a calibrated weight on one side (the reference) and the product on the other side.
When it tips, then you know the product is heavier than the reference.
Leo..
Wawa:
Reference voltage is divided equally over the string of 1k resistors.
10% on the first tap, 20% on the next tap, 30% on the next, etc.
The comparators each compare input voltage (the battery) to the voltage on their tap.
If a comparator senses that input voltage is higher than their tap voltage, the corresponding LED is turned on.
It should be clear that the comparator with the lowest tap voltage is the first to turn on when input voltage rises.
There is already a 1k resistor between the string and RLo (pin4).
Adding 18k between Rlow and ground will turn that 1k resistor into a 19k resistor.
Think old fashioned balance scales.
You put a calibrated weight on one side (the reference) and the product on the other side.
When it tips, then you know the product is heavier than the reference.
Leo..
Where did u find out the values of the resistors to get a range of 0-5 v? The schematic i showed is meant for 12v, but if you go to the site that i linked it says it will work with 1-12v which i weird because 12v batteries voltage drops off sharply when it is near discharged. So i am guessing that all at once the leds would turn off instead of one by one. Let me know if you get how the math works because i was not able to figure it out.
Again they work with 0V-5V and explain how to set lower and upper voltages but I have not been able to calculate the resistor values needed for this. Quite new to electronics, so still learning many things.
I have found that the LED's turn off anything below 2,6V anyway. Regardless, MC's does not seem to like voltage below 3.1V so for all practical purposes, I want to consider voltage below 3.1V to be 'depleted'. Hence my need for a custom range of 3V to 4.2V
Customer request if we can provide all the answer their questions. Basically they are asking asking what MUST the configuration of pins 6, 7, and 8 in a cascading circuit be different chip to chip andwhat is the correct way to do it for 4 chips where Vref needs to be able to range from below 1.25V to above 1.25V (say, 0.25V to 3V)?
For the first question, yes you can connect pins 4 and 6 to an external power supply or voltage divider, pin 6 connected to pin 7 is because it can use the internal voltage source, but this connection is not necessary if you connect 4 and 6 to an external power supply.
In the 2 cascading chip circuit diagram, they show Pin 8 connected to ground on the first chip and Pin 8 connected to pin2 on the next chip, because pin 8 is connected to ground in the first chip, and pin2 also need to connect to ground, so the 1st pin8 can connect to 2nd pin2, why it is confusing? Connect pin8 to ground.
You can just connect Pin 8 to ground and connect Pin 7 to ground through a resistor or potentiometer to vary the current, with a second resistor inline to make sure the current maximum is not exceeded
The LM3914 and LM3916 are a two ICs in a series of monolithic, analog-controlled LED drivers. With these chips, all it takes is a single, analog signal to drive a string of 10+ LEDs, which can be configured into either bar mode (where all LEDs below a certain point turn on) or dot mode (with only a single LED on at a time). Hook them up properly, and you can create all sorts of nifty multi-LED displays, like an audio-visualizing VU meter.
These two ICs are similar in pin-out and interface. They differ in how they map an analog signal to output LED. The LM3914 uses a linear output scale while the LM3916 uses a more logarithmic VU (volume unit) scale, which makes it well-suited to audio applications.
In this tutorial we'll dig into the datasheet of these LED drivers to find out what makes them tick, and take a close look at the pinout of the 18-pin DIP chips. Finally, we'll show a pair of example circuits that show a simple hookup and a more advanced, cascaded hookup.
That may seem a daunting list of pins and reference voltages to supply, but in reality it can be very simple. Many of those pins can either be tied to ground, VCC, or even left floating. Other pins may require a resistor or two to set constant current or voltage values.
The LED outputs are all open-collectors, so they sink current. Connect the cathode of an LED to these pins and tie the other pin of the LED -- the anode -- to your voltage supply. There is no need for current limiting resistors, as the chip takes care of current regulation.
The Mode pin allows you to select between "bar" mode and "dot" mode. In bar mode, all LEDs sequentially turn on. So, if the signal voltage is near max, all LEDs should be on. In "dot" mode just a single LED is on at any time. Connect mode directly to the power source for bar mode, and leave it floating for dot mode.
If you have a more complex circuit connected to this pin, remember that the voltage between Ref Out and Ref Adj pin (pin 8) should be 1.25V. And the LED current is equal to 10 times the current coming out of Ref Out.
Note: It's not critical to understand how these chips work, but it is a neat study into the internals of an integrated circuit. Feel free to skip to the next page, if this looks a little too much like a Circuits I class.
To turn an LED on -- meaning the comparator's output is 0 -- the analog signal voltage must be greater than the divided input on a comparator. So a smaller signal voltage is required to turn on the first LED in comparison to any of the following.
The voltage between the RHI and RLO pins can be anything between 0V (thought, that wouldn't be too useful) and 1.5V below the supply voltage. So, if you're powering the chip at 5V, it'll only be able to map voltages between 0V and 3.5V.
Here are a pair of diagrams that detail this simple layout. We'll assume the circuit is powered by 5V. If your supply voltage is different, some resistor values may need to change (see further below).
The analog input in this example is a potentiometer, which is good for testing, but boring otherwise. Feel free to substitute that for any analog sensor, or even an audio signal from a microphone or stereo.
The switch can be used to swap between dot or bar mode. If the mode pin is pulled high, the IC will be in bar mode. If that pin is left floating, the display works in dot mode.
Finally, the LEDs. Pick any combination of color or size that you like. These 10-output LED drivers are perfect for the 10-Segment Bar Graph LEDs. Or you can choose a combination of any other LEDs you might have handy. 5mm LEDs are a bit too big to fit perfectly into this breadboard hookup, so you may have to creatively bend them to make them fit:
There are a variety of options available for powering the display. In the example above we used a 5V Wall Wart plugged into a Barrel Jack Adapter, with a pair of wires flowing from there to the breadboard. If you are using a breadboard, the 5V/3.3V Breadboard Power Supply might make your life easier.
The mode pins are permanently tied to the 5V supply, which forces the displays into bar mode. A bit of extra wiring is required to get cascaded LM3914/6's into a proper dot mode. Check out the datasheet (page 11) for help with that.
In this example, we use the bar graph LEDs, which seem to be made for the LM3914/6. Make sure you connect the anodes of the LEDs to your supply voltage, and the cathode pins can be connected directly to the output pins on the driver.
The key to cascading is linking the RLO and RHI pins properly. RLO (pin 4) of the lowest IC in the chain should be connected to ground, and RHI (pin 6) of the highest IC in the chain should be connected to the maximum voltage in your sensing range. Between those two points, RHI of one IC should be connected to RLO of the next. This will chain each of those resistor strings inside the ICs together, to create a large set of highly sensitive voltage dividers inside the chips.
64591212e2