LED bar indicator - Designs of medium complexity - Schemes for beginners. Correct connection of LEDs Connecting the LED scale


LED scales are often used to monitor voltage.
Let's consider several ways to construct such schemes.
Passive scales are powered by a signal source and have the simplest circuit.


This could be a car voltmeter. Then VD8 should be selected for 12 volts, since it sets the illumination voltage of the first LED on the scale. The following LEDs VD2 - VD4 are connected via diode junctions VD5-VD7. The drop across each diode averages 0.7 volts. As the voltage increases, the LEDs will turn on one by one.
If you put two or three diodes in each arm, the voltage scale will stretch the corresponding number of times.


According to this scheme, a battery indicator from 3V to 24V is built

Another way to build a line of diodes.


In this circuit, the LEDs light up in pairs, the switching step is 2.5 volts (depending on the type of LED).
All of the above circuits have one drawback - very smooth illumination of the LEDs as the voltage increases. For sharper switching, transistors are added to such circuits in each arm.

Now let's look at the active scales.
There are specialized microcircuits for this purpose, but we will consider more affordable elements that most people have on hand. Below is a diagram of logical repeaters. Logic chips 74ls244, 74ls245 for 8 channels are suitable here. Don’t forget to supply +5 volt power to the microcircuit itself (not indicated on the diagram).


Response threshold of the first element DD1
equal to the logical level for a given series of chips.

If we use inverters of the type K155LN1, K155LN2, 7405, 7406 in such a circuit. The connection will be as follows:


The advantage is that in such a circuit the output works with an open collector, this allows the use of ULN2003 and the like in the assembly circuit.
And lastly, this is the implementation of a running point on logical elements 4i-not.

The logic works in such a way that each element, when turned on, prohibits the operation of all elements of the lowest number. K155LA6 microcircuits are used in this circuit. The last two elements DD3 and DD4, as can be seen from the diagram, can have two inputs, for example: K155LA3, K155LA8.
For battery devices, it is advisable to use low-power analogues from the 176 and 561 series of microcircuits.

The problem is that this set They have already stopped producing them, so you will have to improvise and purchase spare parts separately. It is worth especially noting that the basis of the circuit is the UAA180 chip or the domestic analogue 1003PP1. Knowing now this will not be difficult for you assemble with your own hands devices with LED scale for your car.

Purpose of the microcircuit pins:
1 – earth;
18 – power supply up to +18 Volts;
17 – input for measured voltage;
16 – reference lower level of measured voltage;
3 – reference top level;
2 – LED brightness control;
4..15 – outputs for controlling the inclusion of LEDs.

The microcircuit divides the voltage difference between the 3rd and 16th legs into 12 ranges, and if the voltage on the 17th leg falls into one of these ranges, the corresponding LED lights up. However, there are restrictions: the voltage at the measuring terminals cannot be more than 6 Volts.
To limit the measured voltage, we assemble a measuring chain of a zener diode and two resistors. Let V be the voltage in the on-board network. In a chain of zener diode VD1 and resistances R1, R2, the voltage on the zener diode will be constant 9 Volts (approximately), and on the bridge R1, R2 it will be equal to (V-9). With equal resistances R1=R2, the voltage across resistance R2 will be equal to half (V-9), i.e. if the network voltage V changes from 10 to 15 Volts, then the voltage at the point between R1 and R2 will change from (10-9)/2 =0.5 to (15-9)/2 =3 Volts.
The chain R3, R4, R5 and the zener diode VD2 set the reference minimum and maximum voltage. Minimum zero, because 16th foot on the ground. The maximum is set by a trimming resistor at about 3 Volts. With this setting, it is possible to measure the voltage of the on-board network in the range from 9 to 15 Volts in increments of 0.5 Volts per LED.
The R6, R7 chain simply sets the brightness of the diodes. At R6=50K the brightness is greater, at 100K it is less.

The variants of circuits with a “running dot” and “luminous pillar” scale differ only in the connection of LEDs to the microcircuit. The measuring circuits remain the same.

The scheme is configured as follows. The voltmeter must be connected to a reference source of 14.7 V, turn the trimmer so that the column of 11 LEDs lights up, then slowly turn the trimmer to reverse side until the 11th LED goes out and only 10 LEDs remain on in the column.
It is assumed that the scale has a scale of 2 LEDs per 1 Volt, and turning on the 11th LED corresponds to the measured voltage reaching a level of 14.7V as shown in the figure below.

Above the LEDs in the front panel of the voltmeter there are color markings of voltage ranges:
up to 11.6V - red, battery charge less than 50%;
11.6-12.6V - red dotted line, battery charge 50-100%;
12.6V - green dot, charge 100%;
13.7-14.7V - green, generator voltage is normal;
more than 14.7V - red, overcharge.

The circuit was soldered in the “luminous pillar” version. In the picture below general form what happened. I made the lighting with one baseless 12V car light bulb.

Everything was assembled approximately as in the picture below.

Board drawing. Made in a mirror image to transfer the print onto the foil for etching. If you print at a density of 300 dpi, you get an image on a scale of 1:1.

Placement of parts. View from the side of installation of radio components. The tracks are actually on the other side of the board, but here they are drawn visible, as if the board were transparent.

While operating the device on the vehicle, a flaw was discovered.

Due to the discreteness of the scale, the last LED in the luminous column often operates in flickering mode. Not always, but often. At first, the blinking distracts attention, but then you get used to it, and the blinking is perceived as an attempt by the device to depict half a division of a discrete scale.

Fuel level indicator

The fuel gauge is actually an ohmmeter and measures the resistance of the rheostat sensor. If you connect a variable solenoid to the pointer, then its readings should correspond to the following:
0 Ohm – the arrow lies on the left edge of the scale;
15 Ohm – arrow on the border of the red and white zones;
45 Ohm – arrow on line 1/2;
90 Ohm – arrow on line 1;
when the arrow breaks, the pointer is on the right edge of the scale;

From the previous diagram it turns out quite simple circuit fuel level indicator, because a voltmeter can be used as an ohmmeter, which measures the voltage across a resistance through which a stabilized current flows.

With this connection, the 78L03 stabilizer operates as a 30 mA current source. A 3V zener diode is needed to protect the measuring input of the microcircuit from overvoltage in the event of a “break” in the sensor wire. If the sensor short-circuits, the readings should be the same as for an empty tank.
Chain R3, C3 slows down the change in voltage at measuring input 17 of the UAA180 microcircuit. The chain time constant is about 2 seconds. Such a slowdown should prevent jumps in the readings of the device when the sensor float fluctuates along with the gasoline level while driving.
To configure the device, instead of a rheostat sensor, you need to connect a 90 Ohm resistance and, by rotating the trimming resistor, find the moment when the full luminous column turns on.
The picture below shows the front panel of the pointer.

After installing the devices on the car, a flaw in the operation of the fuel remaining indicator was noticed.
When the tank is full, everything is fine, but when the tank becomes more than half empty, then while driving (in turns, or when accelerating/braking), the readings can change by 3 divisions (and this is a quarter of the scale!), for example, from 1 to 4 LEDs. Obviously, this is due to the pouring of gasoline over a horizontally located tank under the influence of inertial forces. How to deal with this is not yet very clear.

Board drawing.

Placement of parts.

Thermometer

In the books they write that the dependence of the resistance of a working TM-100A sensor (standard sensor on UZAM) on temperature should be as follows:

Degrees – Ohms 40 – 400...530 80 – 130...160 100 – 80...95 120 – 50...65

The relationship is inverse, and not linear. But the sensor is ratiometric type. Such a sensor ensures a change in the current in the pointer winding in proportion to the measured value. An interesting thing turns out: if such a sensor is connected in series with a correctly selected additional resistance (equal to the resistance of the meter winding), a stabilized voltage is applied to this chain, then the voltage at this additional resistance will be proportional to the temperature. This additional resistance is approximately 150 ohms. Due to the fact that the temperature sensor must be installed on ground, the circuit did not turn out to be simple. What happened is shown in the figure.

Explanation for those who want to understand the circuit.
The diagram is made inside out. Imagine a watch in which the hour hand always points up and the dial rotates under the hand. The 17th leg, which should be connected to the measured voltage, is connected to a stabilized 3 Volts. Difference of measured min. and max. The voltage between the 16th and 3rd legs is also stabilized, about 3 Volts, but the voltages on the 16th and 3rd legs change synchronously, “floating” around the voltage on the 17th leg. In general, the circuit works in such a way that the LED scale readings correspond to the voltage across resistor R3. Bridges with zener diodes are needed to maintain the voltage boundaries of the measured range.

However, it turned out that in the thermometer circuit it is possible to do without stabilization at all. Below is a much simpler diagram. It is based on the fact that no matter how the supply voltage of the circuit changes at a constant temperature, the proportion of voltages at the inputs of the microcircuit U16:U17:U3 will remain constant. The absolute values ​​will change, but their relationship to each other will not.

Bridge R4-R5-R6 sets the boundaries of the measured range. Trimmer R1 allows you to shift the readings up or down. Resistance R3 is necessary to lower the supply voltage to a level at which the voltage at the DA1 inputs will not exceed the maximum permissible 6V.

This scheme can only be used in the luminous dot mode. The fact is that at a minimum temperature the voltage measured in this circuit is maximum. As the temperature increases, the voltage decreases to a minimum. In order for the luminous point to move along the scale from left to right with increasing temperature, and not vice versa, it is enough to arrange the LEDs on the indicator in the reverse order. But this is only possible for a luminous point. The luminous pillar does not light up in reverse order.

To “flip” the voltage relative to the middle of the measured range, you can add an operational amplifier inverter to the circuit.

The resistance values ​​that set the voltages at inputs 3 and 16 are selected in such a way that the full scale of 12 LEDs corresponds to a range of 80°C.

The circuit is configured as follows. You can lower the temperature sensor into boiling water, or instead of the sensor, connect a resistance of 91 Ohms to the circuit and use a trimming resistor to find the moment when the glowing column switches from 10 to 11 LEDs, which should correspond to the boiling point of water - 100 ° C.

In general, the resistance values ​​and settings should correspond to the front panel of the thermometer like this.

The thermometer had such a flaw.

Because The scale was calculated on a scale of 3 LEDs at 20°C, then one diode covers a range of approximately 7 degrees. If 10 diodes light up on the scale while driving, then the temperature can be from 93 to 100 ° C, but it is impossible to say exactly how much. At the same time, a car thermometer does not need an extended left part of the scale for low temperatures. Therefore, when repeating the design, it would be better to make a thermometer with a scale of 5°C per diode, for example, from 50 to 110°C, as in the figure below.

Board drawing.

Today there are hundreds of varieties of LEDs, differing appearance, glow color and electrical parameters. But they are all united by a common principle of operation, and therefore connection diagrams to electrical circuit are also based on general principles. It is enough to understand how to connect one indicator LED and then learn how to create and calculate any circuits.

LED pinout

Before we consider how to properly connect an LED, you need to learn how to determine its polarity. Most often, indicator LEDs have two terminals: anode and cathode. Much less often, in a case with a diameter of 5 mm, there are specimens that have 3 or 4 terminals for connection. But it’s also not difficult to figure out their pinouts.

SMD LEDs can have 4 outputs (2 anodes and 2 cathodes), which is due to their production technology. The third and fourth pins can be electrically unused, but used as an additional heat sink. The pinout shown is not standard. To calculate the polarity, it is better to first look at the datasheet and then confirm what you see with a multimeter. You can visually determine the polarity of an SMD LED with two terminals by looking at the cut. The cut (key) in one of the corners of the housing is always located closer to the cathode (minus).

The simplest LED connection diagram

There is nothing easier than connecting an LED to a low-voltage DC source. This could be a battery, accumulator or low-power power supply. It is better if the voltage is at least 5 V and no more than 24 V. Such a connection will be safe, and to implement it you will only need 1 additional element - a low-power resistor. Its task is to limit the current flowing through the p-n junction at a level not higher than the nominal value. To do this, the resistor is always installed in series with the emitting diode.

Always maintain correct polarity when connecting an LED to a constant voltage (current) source.

If a resistor is excluded from the circuit, then the current in the circuit will be limited only by the internal resistance of the EMF source, which is very small. The result of such a connection will be instant failure of the emitting crystal.

Calculation of the limiting resistor

Looking at the current-voltage characteristic of the LED, it becomes clear how important it is not to make a mistake when calculating the limiting resistor. Even a slight increase in the rated current will lead to overheating of the crystal and, as a result, to a decrease in operating life. The choice of resistor is made according to two parameters: resistance and power. Resistance is calculated using the formula:

  • U – supply voltage, V;
  • U LED – forward voltage drop across the LED (nameplate value), V;
  • I – rated current (certificate value), A.

The result obtained should be rounded up to the nearest value from the E24 series, and then calculate the power that the resistor will have to dissipate:

R – resistance of the resistor accepted for installation, Ohm.

More detailed information about settlements with practical examples can be found in the article. And those who do not want to dive into the nuances can quickly calculate the resistor parameters using an online calculator.

Turning on the LEDs from the power supply

We will talk about power supplies (PSUs) operating from a 220 V AC network. But even they can differ greatly in output parameters. It can be:

  • sources AC voltage, inside of which there is only a step-down transformer;
  • unstabilized direct voltage sources (DCS);
  • stabilized PPI;
  • stabilized direct current sources (LED drivers).

You can connect an LED to any of them by adding the necessary radio elements to the circuit. Most often, stabilized power supply voltages of 5 V or 12 V are used as a power supply. This type The power supply means that with possible fluctuations in the network voltage, as well as with changes in the load current within a given range, the output voltage will not change. This advantage allows you to connect LEDs to the power supply using only resistors. And it is precisely this connection principle that is implemented in circuits with indicator LEDs.
Connection powerful LEDs and must be done through a current stabilizer (driver). Despite their higher cost, this is the only way to guarantee stable brightness and long-term operation, as well as to eliminate premature replacement of an expensive light-emitting element. This connection does not require an additional resistor, and the LED is connected directly to the driver output subject to the following conditions:

  • Driver I - driver current according to the passport, A;
  • I LED - rated current of the LED, A.

If the condition is not met, the connected LED will burn out due to overcurrent.

Serial connection

Assembling a working circuit using one LED is not difficult. It's another matter when there are several of them. How to correctly connect 2, 3... N LEDs? To do this you need to learn to calculate more complex circuits inclusions. The series connection circuit is a chain of several LEDs, in which the cathode of the first LED is connected to the anode of the second, the cathode of the second to the anode of the third, and so on. A current of the same magnitude flows through all elements of the circuit:

And the voltage drops are summed up:

Based on this, we can draw conclusions:

  • It is advisable to combine only LEDs with the same operating current into a series circuit;
  • if one LED fails, the circuit will open;
  • The number of LEDs is limited by the power supply voltage.

Parallel connection

If you need to light several LEDs from a power supply with a voltage of, for example, 5 V, then they will have to be connected in parallel. In this case, a resistor must be placed in series with each LED. Formulas for calculating currents and voltages will take the following form:

Thus, the sum of the currents in each branch should not exceed the maximum permissible current of the power supply unit. When connecting LEDs of the same type in parallel, it is enough to calculate the parameters of one resistor, and the rest will be of the same value.

All rules for serial and parallel connection, illustrative examples, as well as information on how not to turn on LEDs can be found in.

Mixed inclusion

Having understood the serial and parallel connection circuits, it's time to combine. One of the options for combined LED connection is shown in the figure.

By the way, this is exactly how every LED strip is designed.

Connection to AC mains

Connecting LEDs from a power supply is not always advisable. Especially when it comes to the need to backlight a switch or indicate the presence of voltage in the power strip. For such purposes, it will be enough to assemble one of the simple ones. For example, a circuit with a current-limiting resistor and a rectifying diode that protects the LED from reverse voltage. The resistance and power of the resistor are calculated using a simplified formula, neglecting the voltage drop across the LED and diode, since it is 2 orders of magnitude less than the mains voltage:

Due to the high power dissipation (2–5 W), the resistor is often replaced with a non-polar capacitor. Working for alternating current, it seems to “extinguish” excess voltage and almost does not heat up.

Connecting flashing and multi-color LEDs

Externally, flashing LEDs are no different from conventional analogues and can flash in one, two or three colors according to the algorithm specified by the manufacturer. The internal difference is the presence of another substrate under the housing, on which the integrated pulse generator is located. The rated operating current, as a rule, does not exceed 20 mA, and the voltage drop can vary from 3 to 14 V. Therefore, before connecting a flashing LED, you need to familiarize yourself with its characteristics. If they are not there, then you can find out the parameters experimentally by connecting to an adjustable power supply at 5–15 V through a resistor with a resistance of 51–100 Ohms.

The multi-color case contains 3 independent crystals of green, red and blue. Therefore, when calculating resistor values, you need to remember that each glow color has its own voltage drop.

Once again about three important points

  1. Direct rated current is the main parameter of any LED. By lowering it, we lose brightness, and by overestimating it, we sharply reduce the service life. Therefore, the best power source is an LED driver; when connected to it, a constant current of the required value will always flow through the LED.
  2. The voltage given in the datasheet for the LED is not decisive and only indicates how many volts will drop at the p-n junction when the rated current flows. Its value must be known in order to correctly calculate the resistor resistance if the LED will be powered by a conventional power supply.
  3. To connect high-power LEDs, it is important not only to have a reliable power supply, but also to have a high-quality cooling system. Installing LEDs with a power consumption of more than 0.5 W on the radiator will guarantee their stable and long-term operation.

Read also

The design of LED indicators is somewhat more complicated. Of course, when using a special control chip it can be simplified to the limit, but there is a small nuisance lurking here. Most of these microcircuits develop an output current of no more than 10 mA and the brightness of the LEDs in a car may not be sufficient. In addition, the most common microcircuits have outputs for 5 LEDs, and this is only a “minimum program”. Therefore, for our conditions, a circuit based on discrete elements is preferable; it can be expanded without much effort. The simplest LED indicator (Fig. 4) does not contain active elements and does not require power.

Connection - to the radio according to the "mixed mono" scheme or with an isolation capacitor, to the amplifier - "mixed mono" or directly. The scheme is extremely simple and does not require setup. The only procedure is to select resistor R7. The diagram shows the rating for working with the built-in amplifiers of the head unit. When working with an amplifier with a power of 40...50 W, the resistance of this resistor should be 270...470 Ohms. Diodes VD1...VD7 - any silicon with a forward voltage drop of 0.7... 1 V and a permissible current of at least 300 mA. Any LEDs, but of the same type and color with an operating current of 10..15 mA. Since the LEDs are “powered” from the output stage of the amplifier, their number and operating current cannot be increased in this circuit. Therefore, you will have to choose “bright” LEDs or find a place for the indicator where it will be protected from direct light. Another drawback simplest design- small dynamic range. To improve performance, an indicator with a control circuit is needed. In addition to greater freedom in choosing LEDs, you can by simple means create a scale of any type - from linear to logarithmic, or “stretch” only one section. The diagram of an indicator with a logarithmic scale is shown in Fig. 5.

The LEDs in this circuit are controlled by switches on transistors VT1.VT2. The switch thresholds are set by diodes VD3...VD9. By selecting their number, you can change the dynamic range and scale type. The overall sensitivity of the indicator is determined by the resistors at the input. The figure shows approximate response thresholds for two circuit options - with single and “dual” diodes. In the basic version, the measurement range is up to 30 W at a 4 Ohm load, with single diodes - up to 18 W. LED HL1 lights up constantly, it indicates the beginning of the scale, HL6 is an overload indicator. Capacitor C4 delays the extinguishing of the LED by 0.3...0.5 seconds, which allows you to notice even a short-term overload. Storage capacitor C3 determines the reverse time. By the way, it depends on the number of glowing LEDs - the “column” from the maximum begins to fall quickly, and then “slows down.” Capacitors C1 and C2 at the input of the device are needed only when working with the built-in amplifier of the radio. When working with a “normal” amplifier, they are excluded. The number of input signals can be increased by adding a chain of a resistor and a diode. The number of indication cells can be increased by simple “cloning”, the main limitation is that there must be no more than 10 “threshold” diodes and there must be at least one diode between the bases of adjacent transistors. use any depending on the requirements - from single LEDs to LED assemblies and panels of increased brightness. Therefore, the diagram shows the values ​​of current-limiting resistors for different operating currents. There are no special requirements for other parts; almost any transistors can be used. structures p-p-p with a power dissipation on the collector of at least 150 mW and a double margin to the collector flow. The base current transfer coefficient of these transistors must be at least 50, and better, more than 100. This circuit can be somewhat simplified, and as a side effect, new properties appear that are very useful for our purposes (Fig. 6).

Unlike the previous circuit, where the transistor cells were connected in parallel, a series connection in a “column” mode is used here. The threshold elements are the transistors themselves and they open one by one - “from bottom to top”. But in this case, the response threshold depends on the supply voltage. The figure shows approximate thresholds for the indicator to operate at a supply voltage of 11 V (left border of the rectangles) and 15 V (right border). It can be seen that as the supply voltage increases, the maximum power indication boundary shifts the most. If you are using an amplifier whose power depends on the battery voltage (and there are many of them), such “auto-calibration” can be beneficial. However, the price for this is an increased load on the transistors. The current of all LEDs flows through the lower transistor in the circuit, so when using indicators with a current of more than 10 mA, the transistors will also require the appropriate power. “Cloning” cells further increases the unevenness of the scale. Therefore, 6-7 cells is the limit. The purpose of the remaining elements and the requirements for them are the same as in the previous diagram. Slightly modernizing this scheme, we obtain other properties (Fig. 7).

In this circuit, unlike those previously discussed, there is no luminous “ruler”. At each moment of time, only one LED lights up, simulating the movement of a needle along a scale. Therefore, energy consumption is minimal and low-power transistors can be used in this circuit. Otherwise, the scheme does not differ from those discussed earlier. Threshold diodes VD1 ... VD6 are designed to reliably turn off idle LEDs, so if weak illumination of excess segments is observed, it is necessary to use diodes with a high forward voltage.

Radio amateur No. 6 2005

LED scale driver chip LM3914.

Based on this chip, LED indicators with a linear scale can be designed. The LM3914 chip is based on 10 comparators.

The input signal through the operational amplifier is supplied to the inverse inputs of the LM3914 comparators, and their direct inputs are connected to a resistor voltage divider. LEDs are connected to ten outputs of the comparators.

The microcircuit has a choice of display mode, column or dot mode, that is, as the signal level changes, moving along the ruler, only one LED lights up.

LM3914N pins:

10…18 - outputs.

2 - minus power.

3 - plus power supply from 3...18 volts.

4 - on this conclusion voltage is supplied, the value of which determines the lower indication level. Acceptable level from 0 to Upit.

5 - an input signal is supplied to this pin.

6 - voltage is applied to this pin, the value of which determines the upper level of indication. Acceptable level from 0 to Upit.

7, 8 - terminals for regulating the current flowing through the LEDs.

9 - pin is responsible for the display operating mode (“dot” or “column”)

The LED switching threshold is calculated automatically by the microcircuit using the formula Uv. – Un.)/10

Operation of the indicator on the LM3914N chip

While on the leg Uin. the signal is lower than the voltage at the Un pin, the LEDs do not light up. As soon as the input signal equals Un. – LED HL1 will light up. With a subsequent increase in the signal, in the “dot” mode, HL1 turns off and HL2 lights up at the same time. If the LM3914 operates in the “column” mode, then when HL2 is turned on, HL1 does not go out. To select one of the two operating modes, do the following:

  • “Point” mode - connect pin 9 to the power supply minus or leave it unconnected.
  • Column mode - connect pin 9 to the positive power supply of the microcircuit.