Forgive me if I missed a post about this, I've been using all my google skills for the last 2 weeks trying to figure this out, but have come up surprisingly empty (I'm surprised there doesn't seem to be a more obvious information base for ways to power advanced projects off a single plug to make more professional finished products). However, I'm also new to Arduino, so I might be missing something obvious to steely veterans.
I'm working on a project to make a "wake up" light for my toddler. Basically it's an alarm clock where you let your kid no if it's OK to wake up their parents by turning some lights on, or changing light color. So in the diagrams I've managed to put together, I need an Uno, an RTC, a LCD and Keypad (To set alarm time etc), and then 10-20 neopixels. However, I don't want thins thing running on batteries I constantly need to change, and I don't want two power plugs coming out of it (If it was just for me I'd deal with it, but I might try to sell some, and two plugs for one light seems like a tough sell).
If I'm understanding everything in my 2 weeks of trying to figure this out, the LEDs need 5V (and something like an Amp or so, depending on LED count), which is more than the Uno will give me off the board, so that means using a 5V 2A wall plug. The barrel plug needs 7-12V, so that's out. The USB though only needs 5V. Could I wire the adapter with one leg to the LEDs (With a capacitor as the Neopixel uberguide recommends), and another leg going to a USB plug, and use that to power and ground the arduino, with I THINK, an additional ground plug to bridge the two circuits when I have the Board powered by the PC during programming and initial testing? Is it a problem to have a 2A supply pushing to an Arduino that wants max 500mA, and LEDs that want 1 Amp? I'm attaching my first ugly wiring sketch below. ANY feedback is appreciated!!!
The LED and the UNO will draw what current they require. Using a 2 Amp supply will NOT push 2 Amps into the device. It is the voltage that you need to look at when powering devices and then decide if the Power supply can deliver the required current that the device will draw. The current listed on the power supply is what it can safely deliver in this case - 2 Amps. If you draw more than that it will run hot and most likely fail.
For powering the UNO you need a power supply that can provide 7 - 12V with a minimum of 500mA capacity. You can use a 12V 100Amp supply if you want but it will only supply 500mA as this is what the UNO uses
In your case I would use a 12V 2Amp Adaptor to power the UNO and use a Step Down regulator to 5V with a 2 Amp capacity to power the LED's
Read up on Ohms Law and hopefully this will become clear
So, not knowing 100% how this works, would I also just drop a line from the 5V power supply to the RTC and LCD shield, which were originally going to draw from the 5V pin that I would then be using as an input?
If the 5V regulator has enough current capacity you can power as many 5V devices as you want as long as it doesn't draw more than the 12V adaptor can provide. Just connect all of the GND's together at a single point
Is there a reason you would go with a 12V to the Arduino, and StepDown to the rest over a 5V to everything (The arduino via the 5V Pin) as mentioned above?
There is a posibilty of damaging the UNO if powering by the 5V pin as it bypasses the built in regulator. Quote from the UNO page
"5V.This pin outputs a regulated 5V from the regulator on the board. The board can be supplied with power either from the DC power jack (7 - 12V), the USB connector (5V), or the VIN pin of the board (7-12V). Supplying voltage via the 5V or 3.3V pins bypasses the regulator, and can damage your board. We don't advise it."
I agree with the comments above, use the inbuilt regulator and supply a slightly higher voltage of maybe 9v or 12v. You’d then need another high current 5v regulator to supply the led units. Probably a 2a 5v buck regulator.
In addition to the advice above, if the large led units that you are using don’t have bypass capacitors on board, then put a reasonably large electrolytic (220u or possibly more) and a small film capacitor between the voltage input pin and ground as close as possible to the LED module.
These caps will help prevent spikes that could crash the arduino or cause interference.
MarkDerbyshire:
There is a posibilty of damaging the UNO if powering by the 5V pin as it bypasses the built in regulator. Quote from the UNO page
"5V.This pin outputs a regulated 5V from the regulator on the board. The board can be supplied with power either from the DC power jack (7 - 12V), the USB connector (5V), or the VIN pin of the board (7-12V). Supplying voltage via the 5V or 3.3V pins bypasses the regulator, and can damage your board. We don't advise it."
Hi,
If the UNO uses the NCP1117, there is no problem with applying 5V to its input.
Look at this suggested circuit for a backup battery supply, both 1117's have their outputs in parallel.
In normal mode, both 1117 are working, the top is 300mV higher than the lower so current only comes from the top 1117.
If the main supply fails, the top 1117 powers down and the output of the second 1117 takes over, 5V being applied to the top 1117 input.
So it is allowable, the 1117 has some protection diodes internally.
Unfortunately not all UNOs use NCP1117, so Idon't know about the clones.
OK, so I THINK I got everything in my updated schematic. 9-12V to the arduino, splitting off to a buck for the LEDS, capacitor before the LEDs to buffer there, Resistor on the data line to buffer there. A ground from the LEDs to the Arduino (Would this be needed if I never would power the LEDs when the arduino is under USB power, just curious).
Yes with the gnd unless the buck you are using specifies not to but usually the GND is passed through from input to output. Always create a common reference for the ground by connecting them together - preferably at a single point to prevent ground loops
I would also be tempted to power the RTC from the 5V Buck and not the Arduino
Yep. You can remove the gnd wire from the RTC to the shield and the UNO as the Buck converter most likely has the gnd connected across input and output - check tho by looking at the traces
I use these from Technobots in the UK - manufactured by Pololu
I'm really new to all this, and can't quite follow the technical side of this conversation, so this may be a really naive question - but what is wrong with powering the arduino through the existing barrel plug and then using the 5v pin from the arduino to power the LED? I thought that pin was a regulated 5v. I happen to have set it up this way and it's working at the moment. Maybe I'm a moment away from burning out the neopixels, so wondering if I've got this wrong.
Hi,
When you use the barrel socket and then run the LEDS from the 5V pin, you are using the onboard 5V regulator.
The regulator is a linear device, not a switch mode device, it is relatively inefficient, the more current you draw from it the more energy is lost in the regulator. This loss is heat and overheating will cause the regulator to shutdown or fail.
Also the 5V is what is powering your controller and circuitry on the PCB, so if you load up the 5V with too much external load, such as LED arrays, you will possibly cause the controller IC to intermittently RESET.
The 5V pins can power some sensors, and the odd 4 or 5 individual LED, but LED arrays is not advisable.
I've also seen in this discussion somethings about using the VIN vs 5V pins for the power connection from a separate supply. Love any clarifications on this as well as I'm not following that distinction either.
I've also seen in this discussion somethings about using the VIN vs 5V pins for the power connection
Same thing, the Vin goes through the onboard regulator. The only difference between Vin and the power jack is that the current passes through a diode first for reverse polarity protection.