I want to turn a white LED on and off via my microcontroller GPIO. The ESP-01S board that I have uses an ESP8266 chip, which has a limit of 12 mA GPIO output current. However, I want to drive this LED with about 25 mA.
The transistor I have is a S8050C NPN transistor. I'm using resistor R1 to limit current for the LED and resistor R2 to limit current for the GPIO pin.
Edit here: https://www.circuit-diagram.org/circuits/8a2aa3cfd1e04356b4099cee6f851846
I know that I will have to scale R2 according to the value given for minimal current gain in the S8050C datasheet, so the current for the LED is high enough.
However, what I'm still unsure about, are the voltages: The supply voltage for the LED is 5 V. My microcontroller uses 3.3 V. Let's say the LED becomes defective and behaves like a wire - will the GPIO pin see the 5 V? Or will the transistor from collector to base function as a diode? So as long as 5 V is below the breakdown voltage, the pin is fine?