LEDs and Multiplexing
making interactive LED strips
Topic: making interactive LED strips
(Read 771 times)
making interactive LED strips
Dec 04, 2012, 10:17 pm
I am currently making an interactive light sculpture. I have some knowledge of how to make this project work but can only find answers to what appear to be more complicated questions than I need, which is only complicating matters!!
Please see my requirements below and perhaps someone may be able to help me?
I would like to use four ultra sonic sensors to control two seperate circuits of one colour LED tape.
When my viewer is far away from my work it will not be lit, as they they move closer to it, the LEDs in the first circuit will fade in depending on the readings from the sensors. When the viewer reaches another stage of closeness to the sculpture the second set of LEDs will start to fade in keeping the first circuit on also, and getting to their brightest when the person is closest.
I would like some help with A, the electronics and circuit side of things and B, the programming code if possible.
I have an arduino mega board am I right in thinking that I can power my ultrasonic sensors from my arduino's power? plugging them to the power and also to ports 1,2,3,4?
Then two circuits of LEDs, both will run on external power supplies of 12v. What I do not know is how to wire up the LEDs so that they can be controlled by the arduino board.
How do I wire up the LEDs to the arduino so that they can be controlled using reading from the sensors?
Is there something that I have to do to protect my arduino board from getting fried?
When I know how it works can I then attach them to ports 5 and 6?
Then for the programming, in normal speech:
When ports numbers 1,2,3 and 4 read values between 100-50 (or furthest away value to mid range value) turn on circuit in port 5.
Not only do I want to be able to turn on circuit in port 5 but I need to tell the arduino depending on the values between 100-50 start 100 being the least voltage and 50 being the brightest - so that the lights will fade in.
I then need to tell the arduino, when ports 1,2,3 and 4 read the between 50 - 0 (mid range to closest) keep circuit 1 on (port 5) but also keep on circuit 2, (port 6). Exactly the same as with the other circuit I need the lights to fade in 50 being the lightest and 0 being the brightest.
Can anyone help me with my questions please?
Unlimited Eagle board sizes available.
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
Re: making interactive LED strips
Dec 05, 2012, 07:58 am
Read up on Ping Sensor, that will do the distances.
Use a ULN2003A to sink the current from the - termimal of the LED strips, + of the strip goes to +12V. Arduino high output to the ULN2003 makes it output go low to turn the strip on.
Designing & building electrical circuits for over 25 years. Screw Shield for Mega/Due/Uno, Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at my website.