Led with push button arduino

broken image

Otherwise, the digital reading value is 0. In this case, the value is 1 when the push buttons are pressed. After, The D2 pin is then connected to a GND via a 10K resistor from the connection point.

broken image

STEP # 1 ( Make Push Button Connections ).It can be connected with a pull-up resistor to 5volts, to the ground and in between depending on the state you want to use. The push-button is a device that connects two points in a circuit when pressed which is the way to turn on an Led. Once you created the code to switch on and off an Led, you can write a code to turn anything on and off. Turning an Led on and off with the help of push-button using an Arduino is a similar method of turning any device on and off.

broken image
broken image

This project is the basic step and it has numerous other applications and it is used in almost every project as an indication of errors or power failures so it’s a good way, to begin with.

broken image