Assignment #1 - blinking LED breadboard

Description

I had my LED have a shorter delay (1/2 a second) between blinks for a more "urgent" display.

Components Used

  • Light Emitting Diode (LED)
  • Resistor

Arduino Code

/*
Blink - DR modified

Turns on an LED on for one second, then off for one second, repeatedly.

The circuit:
* LED connected from digital pin 13 to ground.

Created 4 September 2009
By David Rolnitzky

based on an orginal by H. Barragan for the Wiring i/o board
and original "blink" example here: http://arduino.cc/en/Tutorial/Blink

*/

int ledPin = 13; // LED connected to digital pin 13

// The setup() method runs once, when the sketch starts

void setup() {
// initialize the digital pin as an output:
pinMode(ledPin, OUTPUT);
}

// the loop() method runs over and over again,
// as long as the Arduino has power

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