top of page

Code:


const int LED1= 2;
const int LED2= 3;

void setup()
  {
   pinMode(LED1, OUTPUT); 
   pinMode(LED2, 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)
  }

Case 1.gif

This is a simple introductory Arduino project to power up the LEDs.

MATERIALS :

1. Arduino UNO R3

2. LED x 2

3. 220 Ohm resistor x 2

Output

bottom of page