I set up a circuit with LEDs for my car, however when turning them off the LED does not go out completely leaving a residual shine. What could be happening and how to solve it?
The residual glow indicates that current is flowing through the LED. This leakage current can have different origins, for example, the switches that in a hostile environment such as the car where there may be humidity, even when open, still allow a certain current to pass through, enough to turn on the LEDs. There are two ways to correct the problem. Avoiding the problem in the switch itself connecting between its output (wire between it and the powered circuit) a resistor from 2k2 to 4k7 to deflect the residual current so that it falls below the threshold that lights up the LED or connect this resistor in parallel with the LED.