0% found this document useful (0 votes)
8 views

Computacion Codigo

This code defines three LED pins, sets them to output mode in setup, and blinks each one on and off with a 1 second delay in the loop function.

Uploaded by

mortemon2011
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Computacion Codigo

This code defines three LED pins, sets them to output mode in setup, and blinks each one on and off with a 1 second delay in the loop function.

Uploaded by

mortemon2011
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

int led1=13;

int led2=12;
int led3=11;
void setup()
{
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
pinMode(led3, OUTPUT);
}

void loop()
{
digitalWrite(led1, HIGH);
delay(1000); // Wait for 1000 millisecond(s)
digitalWrite(led1, LOW);
delay(1000); // Wait for 1000 millisecond(s)

digitalWrite(led2, HIGH);
delay(1000); // Wait for 1000 millisecond(s)
digitalWrite(led2, LOW);
delay(1000); // Wait for 1000 millisecond(s)

digitalWrite(led3, HIGH);
delay(1000); // Wait for 1000 millisecond(s)
digitalWrite(led3, LOW);
delay(1000); // Wait for 1000 millisecond(s)
}

You might also like