I'm trying to make a very simple circuit to switch an led using a transistor. My supply voltage is 16v, my control signal is 3.3v from an esp8266 GPIO, and my transistor is a 2222a NPN.
My led has a Vf of 3-3.2v and If of 20 mA. So I've worked out the led resistor value to be
(16 - 3) / 0.02 = 650 ohms
I then worked out the base resistor for the transistor to be
Ib = 5(0.02 / 100) = 0.001
Rb = (3.3 - 0.7) / 0.001 = 2600 ohms
I've tried base resistors from 500 ohms all the way to 13k and none get my led to full brightness. I am now very confused. This seems so simple.
Now when I go to hook it all up and measure the voltage across the led with my multimeter, it is 1.9 V, visibly dimmer that it should be. I know my led is OK because I measured the voltage of that same bulb with a direct connection, no transistor, and the voltage was 3.1 V and bright.