Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Example 1-1
int i = 1000;
void setup()
{
pinMode(3, OUTPUT); // sets digital pin 3 to an output
pinMode(6, OUTPUT); // sets digital pin 6 to an output
}
void loop()
{
digitalWrite(3, HIGH); // turns on digital pin 3
digitalWrite(6, LOW); // turns off digital pin 6
delay(i); // wait one second
digitalWrite(3, LOW); // turns off digital pin 3
digitalWrite(6, HIGH); // turns on digital pin 6
delay(i);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.