Results 1 to 10 of 18
Arduino Uno Rainbow Light Setup for GUY MANUEL Helmet16th Oct 2010, 01:28 #1
After searching every possible keyword I could think of I still couldn't find anything that could help my case. I've studied every picture of DIY GUY MANUEL helmets, including Volpin and countless others.
I'm using the Arduino Starter Kit, with the Arduino Uno. With Conor1148's Arduino code for Guy Manuel Helmet on this thread: http://www.thedaftclub.com/showthrea...t=arduino+code )
My problem is that I know little about electricity, but I know a 9v won't do me any good with 48 LEDs (8 Channels, Two Sides, 6 leds on each channel).
Can someone point me in the right direction of how i can solve this?
I have six 330 ohms Resistors. But i doubt we will need them?[wrong ohms I'm thinkin]
I just ordered some 3.2-3.4v 20mA LEDS, and only after ordering I'm speculating if these will work in the end so i might need to return and order others.
If someone could PLEASE help me out, that would be great! Any info highly appreciated!
Sorry if I missed anything here on the forum, if so please redirect me.
16th Oct 2010, 05:09 #3
The thing is, the arduino can only drive 5v and 40ma per input/output pin. On top of that, there is a maximum overall current limit for the arduino, before you heat it up to the point were stuff starts to fry. I can't remember this off the top of my head, but each LED is about 10-20ma, plus the wattage that is dissipated in the resistor. 48 on at the same time could be close to an amp, which would scare me a lot.
So normally this is done by using the 'logic level' output from an arduino (3.3v to 5v typically) to drive a transistor of some sort. Technically a transistor is a current amplifier, but it can be used as a glorified digitally controlled switch, much like how a relay works.
A transistor will allow you the ability to 'divorce' your voltage and current requirements away from the arduino pins and instead onto the transistor. This can allow you to use the common practice of 3 LEDs and a resistor driven at 12V. You then use two of the 3 series LEDs circuit run in parallel off a single transistor on the given channel. An example of a 12V setup is here.
Make sure you understand how to wire up the transistor as well.
16th Oct 2010, 07:43 #4
So basically each row needs to look like this [schematic], with a transistor on each one?
Also, I think this is the main piece divorcing the the voltage and adding an extra battery?
What parts would be need to assemble these?
-Resistors [I know he uses 220 for his LEDs], but the main (guess ill call it) "divorcer" has Different Resistors,
-Transistors [is there certain type i need?]
17th Oct 2010, 03:25 #5
Most any NPN transistor will do. You did not specify which arduino kit you got (there are at least dozens out there), so I do not know if you have one in your kit or not. This one can be used. Make sure to read the spec sheet for voltage and current rating. The transistor link gives a diagram of how to arrange the components in the circuit.
17th Oct 2010, 08:56 #6
Alright, Thanks!! Starting to get a hang of it.
Yea I bought like the crappiest starter kit haha http://www.amazon.com/Arduino-Duemil...7302049&sr=8-3
it does not have a transistor.
So with the resistance formula I calculated that I need 285ohms resistor or higher.
So then would I need 16 Transistors? If so, do I connect the Transistor to the channel wire and then have that go to the LEDs?
Will a 9v battery be able to pull 48 x 20mA LED setup?
17th Oct 2010, 16:55 #7
The transistor I noted is 200mA. Since you're running 6 LEDs per channel (120mA), you should be fine with one per channel (8).
Did you do your calculations with 9v or 12v?
A 9v inside is really a bunch of tiny AAAA batteries (smaller diameter than a AAA) wired in series. A 9v normally has around 400mAh of power in it. Your minimum run time would therefore be about 2.4 hours, but it will be far less than that because 9v are not designed for high current. They last the longest in their intended design of smoke alarms and clocks that pull microamps. Generally it's a good idea to go with more substantial batteries like AA or bigger. 8 AA's will give you 12v.
17th Oct 2010, 22:25 #8
yea I calculated with the 9v. so now i redid it with 12v (8AA's would be good?)
(12-3.3) / .02= 435 ohms resistance need
so I'm guessing I'm going to need a 470 on each light.
I need 8 x 200mA TRANSISTORS [connected to the channels] with 48 x 470 ohms resitors [on each light]?
Does each transistor need a resistor between itself and the channel?
17th Oct 2010, 22:38 #9
ok, so I'm lookin at some parts online.
Transistors [buy 8]: http://www.amazon.com/gp/product/B00...=AXD1XSTLKIQ6F
Resistors[buy 48, but comes in bags of 25]: http://www.amazon.com/KOA-Speer-Thru...7351331&sr=8-6
I'm thinkin these will do the job?
17th Oct 2010, 22:38 #10
so that gives you the option of either 100R or 120R.
back calculating, 120 would give a current of17.5mA, and 100R would give 0.21. That's a slightly over rated current, but I would still go with 120R because a current of 17.5 vs 20mA will hardly affect brightness.
You will only need 1 resistor for every 3 leds, so 16 total.
The resistor between the arduino and the transistor is another current limiting one. Because each arduino pin can source up to 40mA, it is a good idea to put in a limiting resistor to prevent that full 40mA going to the transistor.
A transistor is a 'dumb' component that will draw as much current as it can from the arduino pin, when it only needs a few mA to 'fully turn on.' Thus you typically put a 1K resistor to act as a limiter. This reduces the current coming from the arduino, while not affecting the 'signal' voltage in any way. The biggest advantage of limiting the current is that your arduino will not get as hot, since that 40mA no longer needs to flow through the internal circuitry.