I am trying to make a simple switch with the 2N2222, so i can send 5 volts from a 3.3 V output pin on an arduino/raspberry pi.
I have constructed the circuit in the simulator, and it works.
In the real circuit, instead of VM1, I have placed a LED where the positive is after the diode and the negative is connected to ground.
So i was expecting, when i close the switch then the led should close instead of this the real circuit keeps the led on and the voltage is the same.
What do i miss here? Probably it is something very easy but i can not figure it out.