8 LED Sweep

8 LED Sweep © GPL3+

This was my first project with Arduino Uno. I started with simple one LED blink code. It's easy to understand. Code repeats itself.

  • 8 views
  • 0 comments
  • 0 respects

Components and supplies

Apps and online services

About this project

This was my first project with Arduino Uno. I started with simple one LED blink code. It's easy to understand it. Code repeats itself. All you need is build the project as seen on image. Upload the code to Arduino and watch the LEDs blink one after another.

Code

8 Led Sweep With LedblinkArduino
8 LEd Sweep left to right than back
int ledPin = 13;
int ledPin1 = 12;
int ledPin2 = 11;
int ledPin3 = 10;
int ledPin4 = 9;
int ledPin5 = 8;
int ledPin6 = 7;
int ledPin7 = 6;
/*

*/

void setup() {
  pinMode(ledPin, OUTPUT);
  pinMode(ledPin1, OUTPUT);
  pinMode(ledPin2, OUTPUT);
  pinMode(ledPin3, OUTPUT);
  pinMode(ledPin4, OUTPUT);
  pinMode(ledPin5, OUTPUT);
  pinMode(ledPin6, OUTPUT);
  pinMode(ledPin7, OUTPUT);
}

void loop() {
  digitalWrite(ledPin, HIGH);
  delay(50);
  digitalWrite(ledPin, LOW);
  delay(50);
  digitalWrite(ledPin1, HIGH);
  delay(50);
  digitalWrite(ledPin1, LOW);
  delay(50);
  digitalWrite(ledPin2, HIGH);
  delay(50);
  digitalWrite(ledPin2, LOW);
  delay(50);
  digitalWrite(ledPin3, HIGH);
  delay(50);
  digitalWrite(ledPin3, LOW);
  delay(50);
  digitalWrite(ledPin4, HIGH);
  delay(50);
  digitalWrite(ledPin4, LOW);
  delay(50);
  digitalWrite(ledPin5, HIGH);
  delay(50);
  digitalWrite(ledPin5, LOW);
  delay(50);
  digitalWrite(ledPin6, HIGH);
  delay(50);
  digitalWrite(ledPin6, LOW);
  delay(50);
  digitalWrite(ledPin7, HIGH);
  delay(50);
  digitalWrite(ledPin7, LOW);
  delay(50);
  digitalWrite(ledPin7, HIGH);
  delay(50);
  digitalWrite(ledPin7, LOW);
  delay(50);
  digitalWrite(ledPin6, HIGH);
  delay(50);
  digitalWrite(ledPin6, LOW);
  delay(50);
  digitalWrite(ledPin5, HIGH);
  delay(50);
  digitalWrite(ledPin5, LOW);
  delay(50);
  digitalWrite(ledPin4, HIGH);
  delay(50);
  digitalWrite(ledPin4, LOW);
  delay(50);
  digitalWrite(ledPin3, HIGH);
  delay(50);
  digitalWrite(ledPin3, LOW);
  delay(50);
  digitalWrite(ledPin2, HIGH);
  delay(50);
  digitalWrite(ledPin2, LOW);
  delay(50);
  digitalWrite(ledPin1, HIGH);
  delay(50);
  digitalWrite(ledPin1, LOW);
  delay(50);
  digitalWrite(ledPin, HIGH);
  delay(50);
  digitalWrite(ledPin, LOW);
  delay(50);
  
}

Schematics

8 Led Sweep With Ledblink
8 led sweep schem z2tp9ah1ly

Comments

Similar projects you might like

Bluetooth control led with lcd led status display real time.

Project tutorial by Youssef Sabaa

  • 18,759 views
  • 4 comments
  • 37 respects

LED Emergency Lights using WS2812 RGB LED Module

Project tutorial by bigboystoys13

  • 10,671 views
  • 7 comments
  • 27 respects

Ambient Light Sensor Using Photo Resistor and LED Lights!

Project tutorial by DCamino

  • 3,679 views
  • 4 comments
  • 18 respects

LED Blink Pattern

Project tutorial by Matt Arnold

  • 33,327 views
  • 15 comments
  • 95 respects
Add projectSign up / Login