How to Make Two Blinking LED Eyes With Your Arduino Uno

1,477

9

1

I'm going to show you how to make two blinking LED eyes.

Step 1: Connect the Hardware

You will need:
- Arduino Uno.
- 4 Jumper Wires.
- 2 LEDs (I used red ones)
- 1 330ohm resistor.

Now follow this schematic to connect the hardware.

Step 2: Load the Program

Open the Arduino software and copy and paste this:

// the setup function runs once when you press reset or power the board
void setup() {

// initialize digital pin 13 as an output.

pinMode(13, OUTPUT); }

// the loop function runs over and over again forever

void loop() {

digitalWrite(13, HIGH); // turn the LED on (HIGH is the voltage level)

delay(4000); // wait for a second

digitalWrite(13, LOW); // turn the LED off by making the voltage LOW

delay(200); // wait for a second }

OR you can go to File>Examples>Basics>Blink.

When that's open, Change the first delay to 4000 and the second delay to 200. (It'll make it blink more like eyes)

Step 3: Upload the Program to Your Arduino

Now click Verify then Upload (Make sure your Arduino is plugged in)

Have Fun!

Arduino All The Things! Contest

Participated in the
Arduino All The Things! Contest

Share

    Recommendations

    • Paint Challenge

      Paint Challenge
    • Stone Concrete and Cement Contest

      Stone Concrete and Cement Contest
    • Growing Beyond Earth Maker Contest

      Growing Beyond Earth Maker Contest

    Discussions

    0
    None
    Jed C

    3 years ago

    Please comment if you need help.