Shopping


List All Products


Advanced Search





Lost Password?
Forgot your username?
No account yet? Register

View Cart/Checkout
Your Cart is currently empty.

Newest Products!

Current Sensor 30 Amp
Current Sensor 30 Amp
$8.95


Arduino Pro
Arduino Pro
$19.95


Seeeduino Mega
Seeeduino Mega
$43.00


Arduino: Getting Started
Digg!

Del.icio.us!

Arduino - Getting Started (Flash the LED)

Arduino is a microcontroller board that is developed as an open source project. It is becoming very popular around the world as both a platform for beginners getting started with embedded computing, and for experienced developers who want to quickly prototype a project. There are several versions of the board. We feature the most popular version, the Arduino Duemilanove, in this How-to.
Anyone who has worked with microcontroller projects can tell you that the hardest part of working with a new platform is the first step of getting a basic setup of hardware and software to work. "Get the LED to flash", is the first thing you should do with a new platform. Once you have done that, everything else gets easier. This task of "blinking the LED" is what we cover here with the Arduino board. (You can purchase the Arduino here)
Thinks you will need:
  • An Arduino board (Diecimila, Duemilanove, Mega, etc)
  • USB Cable
  • PC or Mac computer (for writing the program)
  • 1 LED
  • 1 Resistor
  • 2 wire jumpers
  • Solderless breadboard
Hardware Setup:
Connect the LED to the Arduino board:
Connect pin 13 on the Arduino board to the positive lead (anode) of the LED. The anode is the longer of the LED two leads. Connect the negative lead (cathode) of the LED to one of the leads of the resistor. Connect the other lead of the resistor to the ground pin of the Arduino.
See our LED resistor calculator tool to get the correct value for the resistor. In this case we are using a red LED with a typical forward voltage of 2.3v and 20mA. Using the 5v rail of the Arduino, we need a resistor of at least 135 Ohm. The closest typical resistor value above this is 150 Ohm.
Arduino, LED, and resistor connections:
 
LED Blink LED Blink Arduino Connections
 
Software Setup:
Download and install the free Arduino development software, available here.
Follow the specific installation instructions for Linux (hard-core),  OSX (cool), or Windows ("it came with the computer").

Now plug the Arduino into your computer via the USB cable.
 
Make the LED Blink!
 
The good folks at the Arduino Project have included an example program that blinks the LED. Just start the Arduino software development environment, and select: File | Sketchbook | Examples | Digital | Blink
This will load the LED blink program.
 
Select your correct Arduino board and chip version under:  Tools | Board
 
Select the correct Serial Port that the Arduino board is connected to under: Tools | Serial Port

Now upload the program to the Arduino board by clicking on the "Upload to I/O board" button.
This will upload the program to the Arduino, and execute the program.
 
You should see the LED start to blink. You are now an Arduino hacker!
 
If you have any problems with making the LED blink, do not worry, there are plenty of resources at your disposal. Check out the Arduino forums here.