using transistors to turn LED s on and off with the ground leg of the LED.

dbcjr0675

New Member
Hi all.
I am trying to desing and build an automated model railroad led signal control system using transistors.
Each signal stand has 3 LEDs red, yellow , green.
The three LEDs in each signal stand are wired in parallel to the anode with a common resistor.
This wiring is to accommodate existing model railroad signal controls (mostly manual) which ground the incandescent bulbs in the signal stand, long before LEDs existed.

I have read a number of articles about turning transistors on and off but they do not explain or show circuit diagrams where the led is powered and turned on when one leg of the transistor is grounded and off when the leg is open.
I may be missing something or not understanding the explanation.

My expeirance with electronics is as an electro mechanical diagnostic and repair technican. There is much more to the control system I want to design but I need a transistor circuit diagram controlling the ground side of the led to start with.

Any help will be greatly appicatated.
If anyone is interested in what I am tring to design let me know.
Bruce
 
A simple common-emitter switch will work to ground the LED. Emitter to ground collector to the LED + resistor, base via a resistor to the control signal (high = ON).

Example from the Sparkfun site:

 
If your control signal in any case "floats", nether grounds or supplies turn on V
to transistor, you should use a 19K R from base to ground as well That absorbs
leakage and noise pickup (potentially) if switch source disconnects from driving R1,


Regards, Dana.
 
All transistors can be used as inverting switches with the base current about 5% of the collector load current from the same R voltage drop about 20x bigger R value is optimal.
High hFE transistors are preferred like the PN2222A and twisted magnet wire may be used or CAT3, 4, 5 cable.

100 Ohms in the collector to 5V will result in different currents for each colour of LED would be the maximum for 20~30mA LEDs. Increase all values to reduce brightness. @ 20 mA, R/Y ~ 2.1V and G ~ 3.3 V +/- 0.x

Thus if the input is high (5V) the base is ~ 0.7V and collector is from 0.1 to 0.7 (avg=0.4), then the currents for R/Y would be (5-2.1-0.4)=2.5V across R =100(=0.1k) is 2.5/0.1k = 25 mA.

For Grn , (5-3.3 -0.4)=1.3 or 13 mA so you would want twice the brightness for the green LED at 525 nm since it only gets half the current.


The choice of LED brightness (=Iv [mcd] can significantly affect the result due to the quality and size of the internal chip as well, a 3mm or 5mm lens will magnify brightness. [degrees]
 
Last edited:
100 Ohms in the collector to 5V will result in different currents for each colour of LED would be the maximum for 20~30mA LEDs. Increase all values to reduce brightness. @ 20 mA, R/Y ~ 2.1V and G ~ 3.3 V +/- 0.x

Please read questions, you keep getting carries away!

The OP is using ready-made? model railway signals that already include the LEDs and resistors.
Possibly something like these???
https://www.ebay.co.uk/itm/154455567830


He asked for the transistor equivalent of a switch to ground; that is all the example is for, an illustration of that equivalence - the LED and resistor in it are placeholders to show the signal assembly, not parts of the actual end circuit.

---------

As Dandak notes, the transistor should also have a base to emitter resistor, eg. 10K, if the "control" signal could be floating rather than actively held low when off. That's just a convenient graphic I found for the general principle.
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…