Powering more components

This has probably been answered a million times but I'm unable to find an answer

How would I go about powering more components? For example if I had 20 LEDs obviously the 5v from the arduino isn't enough voltage and current to fully power all 20

How would I be able to control each of them and power them at the same time? How would that wiring go?

You use an external power supply with the correct current rating. Connect the Arduino Gnd to the external power Gnd. One option to drive LEDs is to use ULN2803 integrated circuit. You can also use a serial to parallel method which ay be a bit more complicated.

If you are running out of pins, consider shift registers. Standard ones often recommended here are 74HC595 http://arduino.cc/en/tutorial/ShiftOut

I also like TPIC6B595 or similar (they can sink quite a bit more current than 74HC595). You control them the same way.

The arduino has plenty enough voltage, it lacks current.

If you go to Google and type in "driving multiple leds with Arduino", you will find loads of results. Have fun. :)

http://www.gammon.com.au/forum/?id=11518

AppleAssassin: This has probably been answered a million times but I'm unable to find an answer

How would I go about powering more components? For example if I had 20 LEDs obviously the 5v from the arduino isn't enough voltage and current to fully power all 20

How would I be able to control each of them and power them at the same time? How would that wiring go?

The microcontroller on the Arduino has both a per-pin current limit, and a per-port current limit and also a total current limit for its supply pins too.

So even if the supply could handle the current (USB gives 500mA) the chip can't handle 20 LEDs at 20mA, since IIRC 150mA is the limit from Vcc or GND.

There are chips that do constant-current drive for 16 LEDs, although they are all surface mount packages, there is probably a breakout for one of them somewhere.

The 74HC595 is a commonly used option for driving 8 LEDs, it is a latched shift register, very similar to the constant-current LED drivers except you need to add a resistor per LED to limit the current to what the chip and LED can handle. Its available in DIP package (breadboard friendly).

Whenever switching lots of LEDs be sure to use plenty of decoupling for the chips doing the switching.

AppleAssassin: How would I go about powering more components?

http://www.ebay.com/sch/i.html?_nkw=5v+regulated+power+supply

Or get a USB phone charger and chop up a USB cable to get at the 5V output.

AppleAssassin: How would that wiring go?

Connect "V-" on that to GND on the Arduino. Make sure the connection is SOLID. If you just poke a wire into "GND" and it falls out you can be in big trouble. Me? I usually solder a wire to the top of the Arduino's USB connector (the metal box).

The "V+" on that is now available to power your external components. Do not connect it directly to V+ on the Arduino if the Arduino is connected to another power supply (eg. USB).

When you're finished developing you can use that to power your Arduino, too.