Beginner question: Arduino & External Power Supply

This is probably an easy question to answer, but I've having some problems powering my circuit properly.

I'm using an Arduino pin to use a transistor as a switch, to turn on an array of LEDs. The array of LEDs is currently being powered by the 5V pin out of the Arduino. All is well. But it's a limited number of LEDs (4, and I want to add more) and I imagine that the current limit will soon be reached.

So I tried using an external, variable-voltage power supply (wallwart) -- two of them, actually, set to 5V -- instead of "5V out" on the Arduino, but I can't get it to work. The LEDs are very very dim. The "current output" on one of the wallwarts is 300mA, and the other 500mA. Neither seem to be giving it enough power.

I also tried using one of those modified ATX power supplies and that works just fine. But 450 watts is a little overkill for my application.

Can someone help me understand what's going on with those wallwarts? I'm assuming that it's not enough current, but since I only have 4 LEDs in parallel (so -- I think -- 80mA to 100mA), I'm confused.

Thanks in advance!

Tie all your grounds together. If the Ardiuino and the transistors grounds aren't tied together you don't know what voltage/current the transistors are seeing (and it can change randomly).

Without a good ground reference things won't work reliably.

Your LEDs are connected like this?

kf2qd:
Tie all your grounds together. If the Ardiuino and the transistors grounds aren't tied together you don't know what voltage/current the transistors are seeing (and it can change randomly).

Without a good ground reference things won't work reliably.

Well, that did it!

As soon as I tied the Arduino GND to the negative rail of my breadboard, it came alive again. Thanks so much!

CrossRoads:
Your LEDs are connected like this?

Thanks for your reply.

Yes, like the third circuit, except the resistor is outside of the group of LEDs (i.e. the resistor is in series with the group of parallel LEDs). But I think kf2qd has traced where I was going wrong.

Can either of you point me in the direction of supplying power to both the Arduino and the LED "path" using the same wallwart? I'm currently powering the Arduino through USB and the LED path using the wallwart (thanks!). I want to do this because the circuit I have in mind would exceed the current output of the Arduino (if I were to use the 5V line).

Can I just split the power supply, one line to the Arduino and the other the LED path? Thanks again for your help.

Supplying power to both the Arduino and the LED "path" using the same wallwart:
Just split the power supply, one line to the Arduino and the other the LED path.

CrossRoads:
Supplying power to both the Arduino and the LED "path" using the same wallwart:
Just split the power supply, one line to the Arduino and the other the LED path.

Okay, great. And in the future I'll refrain from asking silly questions without trying them out first.

Thanks again!

Doesn't hurt to ask. Little time to ask & confirm beats smoking something & losing a lot of time getting replacement parts.

CrossRoads:
Doesn't hurt to ask. Little time to ask & confirm beats smoking something & losing a lot of time getting replacement parts.

Cheers :slight_smile:

Yes, like the third circuit, except the resistor is outside of the group of LEDs (i.e. the resistor is in series with the group of parallel LEDs).

Don't you think you should have one resistor in series for EACH LED? One resistor for several LED's in parallel is not generally a good idea. :slight_smile:

bibre:
Don't you think you should have one resistor in series for EACH LED? One resistor for several LED's in parallel is not generally a good idea. :slight_smile:

Correct me if I'm wrong (and there's a good chance), but doesn't it add up to the same thing?

Oh wait, would this be exceeding the 1/4 watt max for the resistor..?

No, the difference is LEDs can have different current draws, or one can fail open and then the allowed current goes to the other 2 and takes them out.

Your mileage may vary - I have 8 digits wired up with 3 LEDs in parallel being driven by a MAX7221, has been working great for a year+ now.
These were made from superbright LEDs, and I have the current set lower as otherwise it was waaaay too bright.

Here it is photographed from ~30 feet way. Haven't figured out the camera settings needed for capturing multiplexed LEDs.

scoring_machine_front.jpg

CrossRoads:
No, the difference is LEDs can have different current draws, or one can fail open and then the allowed current goes to the other 2 and takes them out.

Your mileage may vary - I have 8 digits wired up with 3 LEDs in parallel being driven by a MAX7221, has been working great for a year+ now.
These were made from superbright LEDs, and I have the current set lower as otherwise it was waaaay too bright.

Here it is photographed from ~30 feet way. Haven't figured out the camera settings needed for capturing multiplexed LEDs.

Ah yes, I can see your point there -- if one fails it will be overloaded (or "underloaded", as it were).

And I was looking at LED drivers, but I was hoping I could get away without one. I don't have a good reason for this mind you (except for the cost and having to wait for the mail to arrive); do you think it would be advisable?

The end project I have in mind is for some translucent kitchen cabinets. All four cabinets would have a string of four or five LEDs which would react to various sensors (cabinet open, darkness, etc.).

Hi peej, :slight_smile:

The following quote is from the URL link further below. It is for regular diodes but this should also apply to LED's. Current will always 'seek' the least resistance path and since it is hard to find identical diodes (or LED's) it will choose one of them and start the following process.

It works like an endless cycle which ends up with only one diode conducting or broken down. The more current, the more heat; the more HEAT, the more CURRENT, and so on. If you get lucky with well matched LED's and nothing happens, you will at least have one LED brighter than the others.

Maybe this explains the problem a little bit better.

Can you put two diodes in parallel in order to obtain the double load?

Answer:
Improve
As a rule, NO!

The main reason is thermal runaway:
When you warm up a diode, its "conductance" at any particular voltage increases.
(The Shockley diode equation gives the exact equation).
Even with two identical diodes in parallel, if the temperature of one diode was even slightly hotter than the other diode, more of the current would go through the hotter one. The one with more current would heat up more rapidly, lowering its conductance even more, and after a short time the hotter diode is hogging most of the current.

The final effect is that a diode will carry almost all the current, while the other stays almost unused.

There are a variety of things that cause two diodes to not be identical, which only speeds up the thermal runaway.
*the unavoidable imbalance between the two diodes voltage drops.
*(with an AC signal): the diode with slightly faster turn-on time will absorb more turn-on loss
*(with an AC signal): the diode with slightly slower turn-off time will absorb more turn-off loss

There is an obvious exception: use identical diodes, with exactly the same electrical and themal chracteristics. Individually selected diodes with voltage drop matched to less that one mV, and carefully assembled for thermal matching, may carry the same current, so effectively double the rating.
It is a very unstable condition, like keeping a coin vertical on a table.
Another arrangement is to add current sharing resistors in series to each diode, at least 0.3/0.4 V of additional voltage drop is required, so is a very unefficient solution.
Considering high frequency signals (as in switching power supply) adds even more problems, so the answer is always: use just one diode, leave the task of paralleling only to very skilled people dealing with such high currents that no single diode in the market can withstand.

Read more: Can you put two diodes in parallel in order to obtain the double load? - Answers

Ah, that's a lot simpler.
You can buy LED strips that are powered from 12V, with built in resistor & everything.
All you need is a buffer chip like ULN2803 to control the ground to turn them on & off.

Hey Robert,

Those LED's are great!

What I'm using for my model R.R. signal LED's are up to 6 of these 330 ohm bussed wired resistors in a 16-pin DIP package. Pin 16 is common to 15 resistors and I connect them to either +5 or 0. Of course I must use all pins in a DIP as either pulldup or pulldown.

MOLDED DIP,16PIN,BUSSED,330,2%,LOW,BULK,HAZMAT

https://www.jameco.com/webapp/wcs/stores/servlet/ProductDisplay?storeId=10001&langId=-1&catalogId=10001&productId=1159558

Yes, folks have found all kinds of neat uses for the LED strip, including as the elements of 7 segment displays.
These LED strips are controlled by TPIC6B595 on an arduino-based board I designed.
http://swimmeetkeeper.com/id2.html
This one has 4 digits.


This one will do 96 segments (thinking 12 digits)

bibre:
Hi peej, :slight_smile:

The following quote is from the URL link further below. It is for regular diodes but this should also apply to LED's. Current will always 'seek' the least resistance path and since it is hard to find identical diodes (or LED's) it will choose one of them and start the following process.

It works like an endless cycle which ends up with only one diode conducting or broken down. The more current, the more heat; the more HEAT, the more CURRENT, and so on. If you get lucky with well matched LED's and nothing happens, you will at least have one LED brighter than the others.

Interesting. That's something I would never have figured out on my own, but I'll be sure to keep it in mind. Thanks!

CrossRoads:
Ah, that's a lot simpler.
You can buy LED strips that are powered from 12V, with built in resistor & everything.
All you need is a buffer chip like ULN2803 to control the ground to turn them on & off.

Warm white LED weatherproof flexi-strip 60 LED : ID 357 : $124.75 : Adafruit Industries, Unique & fun DIY electronics and kits

Ah yes, I was considering the strip as well. I will probably start to look at those if I get more advanced; I'm really interested now in learning the basics of electronics without relying too much on ICs to do the work for me (even though I'm sure they're easier and designed for the task). This was, for example, my first transistor use. :slight_smile:

Sometimes a single transistor or two (and associated resistors) is all you need.
For example, on this board (in various stages of construction) I used 4 transistors and 11 resistors to control 4 strings of 5 LEDs each, 1 string of 3 LEDs, 1 LED, and to invert a signal.
A ULN2003 or 7406 with 4 resistors would have done the same. I've had the transistors since 1983 or '84, little drawerful of them, and decided I was finally going to use them for something, so I did.