I have ESP32 with one pin with 3.3 V High level and 0 V low level. I want to control red and green led from this pin:
- I want to power leds from 12 V power source.
- The red led is 2 V 20 mA, green is 3 V, 20 mA.
- I want to lit red led if pin is low (0 V), green is off and the red is off and green lit when pin is High.
I can use NPN transistor to lit green when is Hi and turn off when pin is low, but I don't know how to lit red when pin is low and turn off when pin is Hi.
