3 blinking lights - shaneno12/MTEC2280 GitHub Wiki

https://www.youtube.com/watch?v=np6fUScWXuo&feature=youtu.be

CODE:

int LED0 = 13; int LED1 = 12; int LED2 = 11;

int delaytime = 500;

// the setup function runs once when you press reset or power the board void setup() { // initialize digital pin 13 as an output. pinMode(LED0, OUTPUT); pinMode(LED1, OUTPUT); pinMode(LED2, OUTPUT); }

// the loop function runs over and over again forever void loop() { digitalWrite(LED0, HIGH);
delay(delaytime);
digitalWrite(LED0, LOW);
delay(delaytime);

digitalWrite(LED1, HIGH); delay(delaytime); digitalWrite(LED1, LOW); delay(delaytime);

digitalWrite(LED2, HIGH);
delay(delaytime);
digitalWrite(LED2, LOW);
delay(delaytime);

}