Error in my LED output

I am new to Arduino development, I tried learning the push button, and when I ran my simulation, my output LED was already coming on, even without me pushing the button. I tried cross checking my connection and everything, it was the same with the tutorial videos, but I was getting the same outcome.
What's the problem?

Welcome to the forum

Please post your sketch and a schematic of your project. A photo of a hand drawn circuit i good enough

Using this official Arduino schematic with a sketch waiting for a pushbutton to pass a LOW to the sensing pin would cause an LED to be ON always because the drawing uses a pulldown resistor, causing the sensing pin to sense LOW until the button is pressed.


Use this schematic and adjust the sketch to wait for HIGH or adjust the hardware to use a pullup resistor to Vcc to hold the sensing pin high, and wait for the pin to sense a LOW .


I'm sorry about my camera quality

There's a white wire connecting the LED to pin 13

Why did you use camera? Why not take screen grab?

1 Like

Don't use white wires on a white breadboard on a white background! Pick a contrasting colour.

I didn't think of that.
I just did the first thing that came to my mind

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.