🧪 Goal: Turn an LED on and off using a simple push button.
✅ Components:
LED
220Ω resistor
Push button
10kΩ resistor (for pull-down)
Battery
Breadboard
🧰 Wiring:
- Connect the push button between the positive rail and a node leading to the LED.
- Connect the 10kΩ resistor between the other leg of the button and ground (this is the pull-down resistor).
- Connect the 220Ω resistor to the LED’s negative leg, then to ground.
💡 Why the Pull-down?
When the button isn’t pressed, without a pull-down resistor, the signal line “floats” and might behave erratically. The resistor ensures a stable LOW signal.
🔁 Press the button = LED turns on
Release the button = LED turns off