Inverting pin signal for bi-color led

Status
Not open for further replies.
With a 150R current limiter resistor between 2 GPIO pins. Drive one high, the second low (always with digitalWrite()) = one color. Drive the first low, the second high = other color. Both high or both low = LED off.
 
You can also use the method described in THIS POST to drive your Bicolor LED, from only a single pin.
This can give you Red Green or Yellow.

EDIT: Actually, Never Mind... this won't work because you can't tie in between the two LEDs on a two pin device.
Theremingenieur's method is the way to go. Note that you can also get yellow by toggling between the two states very rapidly.
 
Status
Not open for further replies.
Back
Top