Difference between revisions of "Cylon LEDs"

From LVL1
Jump to navigation Jump to search
Line 29: Line 29:
  
 
==Troubleshooting==
 
==Troubleshooting==
 +
Probably the easiest way to troubleshoot LEDs is to power them.  Take the wire that goes to the arduino output pin and touch it to 5V to see that the LED lights up.  If it does not, turn the LED around and try again.  LEDs are pretty hearty as long as you have a 1K resistor in series with them.

Revision as of 16:02, 7 February 2011

Introduction

Cylon LEDs In this experiment, we will create a Cylon (Battlestar Galactica) effect with LEDs. I get this request quite a lot when people are first starting to program arduinos.


Components Needed

  • Freeduino or Arduino or clone
  • USB cable for Freeduino
  • Freeduino development software - download here!
  • Solderless Breadboard
  • Hookup wire 22gauge solid
  • 8 LEDs -same color is preferable
  • 8 1K resistors

How to

  • See the fritzing diagram

Schematic

Cylon schem.jpg

Fritzing

Cylon bb.jpg

Code


Troubleshooting

Probably the easiest way to troubleshoot LEDs is to power them. Take the wire that goes to the arduino output pin and touch it to 5V to see that the LED lights up. If it does not, turn the LED around and try again. LEDs are pretty hearty as long as you have a 1K resistor in series with them.