This project demonstrates how to control six LEDs using two three-terminal switches on an Arduino Uno. The code and circuit diagram are provided in this repository.
To follow along with this project, you will need the following hardware:
- Arduino Uno board
- Six LEDs
- Two three-terminal switches
- Breadboard
- Jumper wires
- Resistor (220 Ohm)
- Clone this repository to your local machine using Git or download the ZIP file.
- Connect the components as shown in the circuit diagram.
- Open the arduino-led-control-with-switches.ino file in the Arduino IDE.
- Upload the sketch to the Arduino board.
- Connect the power supply to the Arduino board.
- Flip the first switch to turn on the first three LEDs and the second switch to turn on the remaining three LEDs.
- Flip the switches again to turn off the LEDs.
- You can view a live simulaton of the project through the following link on Tinkercad
The circuit diagram for this project is provided in the circuit_diagram.png file in this repository.
You can also go to the following video to view the sequence of the project.
If you find an issue with the code or have an improvement to suggest, feel free to open an issue or pull request.
This project is licensed under the MIT License ↗. Feel free to use the code in this repository for your own projects.