Electronic – How to replace a green LED with a red one in a simple transistor switch

bjtled

I am designing four traffic lights that I can control with a single digital switch. When the signal is 1, two traffic lights should be green, and the other two red, and they should reverse when the digital signal is 0. I'm using a simple transistor switch to achieve this:

enter image description here

This one works in the simulation, but I tried it on the breadboard, and it won't work properly unless I swap the green LED with the red one and vice versa.
Otherwise, the red LED stays on regardless of the applied base voltage, while the green one stays off.

Moreover, the whole implementation doesn't work in the simulation. Only the first and the third gates switch properly. The second and the fourth ones have the above-mentioned issue:

enter image description here

Now, I'm aware that the red and green LEDs have different forward voltages (1.7V for red and 2.2V for green), but I don't know how to fix this problem.

Best Answer

Using both NPN and PNP transistors is probably your best bet.

schematic

simulate this circuit – Schematic created using CircuitLab

Or this way is more elegant.

schematic

simulate this circuit

ADDITION

If you must drive this with a single pole switch, you should probably make the signal more active.

schematic

simulate this circuit