Video:
Pictures:
Code: (Thanks to 30 Arduino Projects for the Evil Genius)
int ledPin = 10;
void setup()
{
pinMode(ledPin,OUTPUT);
}
void loop()
{
flash(200); flash(200); flash(200);
delay(300);
flash(500);flash(500);flash(500);
delay(300);
flash(200); flash(200); flash(200);
delay(1000);
}
void flash(int duration)
{
digitalWrite(ledPin , HIGH);
delay(duration);
digitalWrite(ledPin,LOW);
delay(duration);
}
No comments:
Post a Comment