Вы находитесь на странице: 1из 7

Home Sign Up!

Browse Community Submit


All Art Craft Food Games Green Home Kids Life Music Offbeat Outdoors Pets Photo Ride Science Tech

Arduino mood lighting


by sapc on November 22, 2010

Table of Contents

Arduino mood lighting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1

Intro: Arduino mood lighting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Step 1: Parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2

Step 2: The circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

Step 3: Program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

File Downloads . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Step 4: Add-Ons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Related Instructables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Comments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

http://www.instructables.com/id/Arduino-mood-lighting/
Intro: Arduino mood lighting
This instructable will show you who to build a rgb lighting system with an arduino. You can also control it with an ipod/iphone/ipad using touchOSC. In my previous
instructable I showed how to control one rgb led in this you can control heaps with a single chip the ULN2003A.

Step 1: Parts
You will need

Arduino
ULN2003A ic or equivilent
common cathode RGB LED's(- + - -)
jumper wires
breadboard or perfboard
Resistors based on your led(I used one per channel)
Cable for linking RGB LED's around your home(optional)

Image Notes
1. arduino
2. resistors I used 100R
3. ULN2003A IC
4. RGB LED's
5. jumper wires
6. breadboard

http://www.instructables.com/id/Arduino-mood-lighting/
Step 2: The circuit
Red to pin 9
green to pin 10
blue to pin 11

http://www.instructables.com/id/Arduino-mood-lighting/
http://www.instructables.com/id/Arduino-mood-lighting/
http://www.instructables.com/id/Arduino-mood-lighting/
Step 3: Program
Use the code below for your system

There are two sets of code bellow one is a simple flash red, flash green, flash blue and is my code.The other is ipod controlled with aduino IDE and processing code it
requires the oscpc5 processing library and is ipod/iphone/ipad controlled using touchOSC.

File Downloads

Processing osc_rgb.pde (7 KB)


[NOTE: When saving, if you see .tmp as the file ext, rename it to 'Processing osc_rgb.pde']

arduino_osc.pde (763 bytes)


[NOTE: When saving, if you see .tmp as the file ext, rename it to 'arduino_osc.pde']

oscP5-0.9.6.zip (279 KB)


[NOTE: When saving, if you see .tmp as the file ext, rename it to 'oscP5-0.9.6.zip']
Step 4: Add-Ons
This was a brief instructable showing you how to build an arduino mood lighting system. You could add switches to each channel or add activity lights to each channel or
add more channels. There is the new ULN2803 which is 8 channel not seven but is use this chip because you can have several channels and a common anode or
cathode and have it run down 8-core wire.

Related Instructables

Skyline RGB Arduino Lilypad


Assembling the LED Lamp Interactive LED Mood Jar!
Mini Mood Light RGB LED by joejoerowley
(video) by Moodlight in 10 Passion Interactive,
v1 Kit by earthshine Sensing Scarf Open Source
minutes! by
robert.fitzsimons by ArduinoFun Mood Light by
WattSekunde
mortaldoom780

http://www.instructables.com/id/Arduino-mood-lighting/
Comments
5 comments Add Comment

d77uk says: Jan 30, 2011. 12:01 PM REPLY


Just wondering what the purpose of the IC is? Can't you just do this with PWM direct from the arduino?

sapc says: Feb 8, 2011. 2:01 AM REPLY


the chip is used for driving heaps of leds for large scale purposes if you aren't using to many led's you can just use the pins straight off.

hightekrednek2396 says: Dec 15, 2010. 8:44 PM REPLY


whats the maximum amount of leds you can control with the 1 chip

sapc says: Jan 12, 2011. 5:59 PM REPLY


i am not quite sure but i can control 25 rgb leds without any problems:)

hightekrednek2396 says: Jan 12, 2011. 6:17 PM REPLY


thanks

http://www.instructables.com/id/Arduino-mood-lighting/

Вам также может понравиться