Back to Parent

int ledPin1 = D1; int ledPin2 =D2;

void setup()
{
    // We want to tell the Argon that we'll use
    // D1 and D2 as an output pin.
    pinMode( ledPin1, OUTPUT );
    pinMode( ledPin2, OUTPUT );
    
}

void loop()
{
    // First... On
    digitalWrite( ledPin1, HIGH ); // Turn ON D1 LED pins
    delay( 1000 );                 // Wait for 1000mS = 1 second
    digitalWrite( ledPin1, LOW );  // Turn OFF D1 LED pins
    digitalWrite( ledPin2, HIGH ); // Turn ON D2 LED pins
    delay( 1000 );                 // Wait for 1000mS = 1 second
    digitalWrite( ledPin2, LOW );  // Turn OFF D2 LED pins
    // rinse + repeat 
}
Click to Expand

Content Rating

Is this a good/useful/informative piece of content to include in the project? Have your say!

0