LED Control

41

Posted in TechnologyArduino

Introduction: LED Control

This project will utilize the Arduino Uno micro controller, breadboard, LED's, resistors, and a potentiometer to create a sequence in which the potentiometer controls which LED's are on. As the potentiometer is turned clockwise, the "on" LED shifts to the right and as the potentiometer is turned counter-clockwise, the "on" LED shifts to the left.

What you will need:

- Arduino Uno

- Breadboard

- 5 LED's

- 5 220 Ohm resistors

- Rotary Potentiometer

- Wires

Step 1: Connect LED's

Insert 5 LED's into the breadboard, all aligned next to each other, one after the other. Use wires to ground the Led's and insert a 220 resistor to each LED. Next, use wires to connect the LED's to the Arduino. Connect the LED's to the pins as followed (You may use whatever color LED's as you wish, just connect them the same way I have in the diagram).

From left to right:

- First Red LED to Digital 12

- Yellow LED to Digital 11

- Green LED to Digital 10

- Blue LED to Digital 9

- Second Red Led to Digital 8

Step 2: Connect Potentiometer

Insert a rotary potentiometer into the breadboard. Wire the potentiometer to GND and 5V as the diagram shows. Then wire the potentiometer to Analog 2 as shown.

Step 3: The Code

Share

    Recommendations

    • Spotless Contest

      Spotless Contest
    • Science of Cooking

      Science of Cooking
    • Space Challenge

      Space Challenge
    user

    We have a be nice policy.
    Please be positive and constructive.

    Tips

    Questions

    Comments