# switch on delay not working (capacitor, transistor)

I built a switch on delay with a 2n2222 npn transistor and a capacitor.

(I left out the base resistor (2k ohms) and the resistor for the led (330 ohms) in this simulation, but in real I added them for sure. The resistor before the capacitor is 1M ohm)

In theory, my 5V power supply should charge the capacitor slowly (because of the big 1M ohm resistor before the capacitor) and if the voltages reachs around 0.8V the transistor should switch on the led. Why is my circuit not working? I guess I forgot something since I have never seen such a small switch on delay on the Internet before. Or is the 1M ohm resistor in front of the capacitor too small to see a delay between plugging in my power supply and seeing the led going on? What is my mistake?

• How about a schematic and not a cartoon? Oct 4, 2020 at 13:35
• You have supplied a wiring diagram of your circuit. I recommend that you provide a schematic instead. This will reveal the schema of your circuit and the problems will be obvious if you've drawn it out properly. You can add one in using the CircuitLab button on the editor toolbar. Double-click a component to edit its properties. 'R' = rotate, 'H' = horizontal flip. 'V' = vertical flip. Note that when you use the CircuitLab button on the editor toolbar and "Save and Insert" on the editor an editable schematic is saved in your post. You don't need a CircuitLab account. Oct 4, 2020 at 13:36
• "(I left out the base resistor (2k ohms) and the resistor for the led (330 ohms) in this simulation, but in real I added them for sure." Don't do that. Show the circuit that we're trying to fix - not something a bit like it. Oct 4, 2020 at 13:38
• Also you have shown a 2K resistor where you claim the 1Meg resistor is. Also, how did you calculate the base current to supply enough collector current for the LED? Oct 4, 2020 at 13:52
• Please show the circuit diagram with the exact component value, data provided creating confusion. Oct 4, 2020 at 13:58