Assignment 1: Blinking LED - S.O.S.

Assignment: Introduction to Arduino and Physical Computing

Collaborators:

Assignment: Introduction to Arduino and Physical Computing
Collaborators:

Assignment: Introduction to Arduino and Physical Computing
Collaborators:

I made the LED blink 3 times in rapid succession and then 3 times more slowly (morse code for S.O.S.) on a continuous loop.

 

 


 

void loop()                    
{
digitalWrite(ledPin, HIGH);   // set the LED on
delay(1000);                  // wait for a second
digitalWrite(ledPin, LOW);    // set the LED off
delay(1000);                  // wait for a second

digitalWrite(ledPin, HIGH);   // set the LED on
delay(1000);                  // wait for a second
digitalWrite(ledPin, LOW);    // set the LED off
delay(1000);                  // wait for a second

digitalWrite(ledPin, HIGH);   // set the LED on
delay(1000);                  // wait for a second
digitalWrite(ledPin, LOW);    // set the LED off
delay(1000);                  // wait for a second

digitalWrite(ledPin, HIGH);   // set the LED on
delay(300);                  // wait for a second
digitalWrite(ledPin, LOW);    // set the LED off
delay(300);                  // wait for a second

digitalWrite(ledPin, HIGH);   // set the LED on
delay(300);                  // wait for a second
digitalWrite(ledPin, LOW);    // set the LED off
delay(300);                  // wait for a second

digitalWrite(ledPin, HIGH);   // set the LED on
delay(300);                  // wait for a second
digitalWrite(ledPin, LOW);    // set the LED off
delay(1000);                  // wait for a second
}