5V led strip powered from barrel connector?

Hi,
I'd like to connect a WS2812 8 LED strip light to the arduino. I just need to flicker it on and off.

I'll also need to power a piezo buzzer and the UNO board, obviously.

Can I just use, say, a 9V AC-DC power supply plugged into the barrel connector? Then can I draw voltage from the 5V pin to power the LED strip?

Or do I have to use the VIN and an external power supply? And in that case, how do I actually connect the VIN to power from the wall?

Pardon my ignorance.

Samantha

Maximum current is:

60mA(per pixel, for the colour white) * 8(pixels) = 480mA

If you were to draw the full 480mA the UNO might be damaged.

You might be okay if you limit intensity to 1/2 brightness.

Thanks. Actually... I only need to run ordinary old LEDs like this ebay.com.au/itm/20x-5mm-WARM-WHITE-LED-Clear-Light-Emitting-Diode-Pack-AUS-STOCK/180876304882

and they only draw 20mA so that's not a big deal is it? And I could get the LED array out of a torch right?
A mini torch has 9 LEDs so that's still only 180mA.

At 12,000 mcd they will be ‘extremely’ bright with 20mA.

Do you need to run them at full brightness?

“ And I could get the LED array out of a torch right”

If you use one LED (with dropping resistor) per Arduino output, yes.

Tell us what you are making.

I am making an Alzheimer's therapy doohickey for my mother.
Here's an example. He uses a strip of LEDS How to build your own Alzheimer’s light treatment relay with Arduino/Espruino | by Christopher Cinq-Mars Jarvis | Cinq-Mars Media

Basically I need a light to switch on and off 40 times a second. I don't know how bright it needs to be, but bright enough that you'd be aware of it. Could I try it with 1 LED and add more until I think its bright enough?
I want it to be neatly contained in a box with an AC/DC power supply or a USB cable plugged into a wall charger.

I also want to add a piezo buzzer going on and off at 40Hz, like the lights. In the experiments with mice, there was a greater effect when sound and light were combined.

Sorry, what a horrible disease. :frowning:

You could miniaturize it by using a 5volt Arduino ProMini ~ $6.00 (buy several for future projects).

You will need a FTDI programmer too, ~ $10.00

Other options are an Arduino NANO or MICRO. (no programmer needed).

The LEDs you linked to can be driven with a MOSFET driver.

A Piezo might not be loud enough, maybe earphones with volume control?

Thanks for that. It looks a bit complicated for poor old me.

But then I discovered this ... Arduino and 3W LED Module - Getting Started with Arduino and Keyestudios 37 Sensor Kit - YouTube

how is it possible for her to power a 3w led from the arduino 5V pin??

I'm confused!

Indeed you are confused, and it is most unfortunate.

chibi-arduino:
Can I just use, say, a 9V AC-DC power supply plugged into the barrel connector? Then can I draw voltage from the 5V pin to power the LED strip?

No. You can't. :astonished:

chibi-arduino:
Or do I have to use the VIN and an external power supply? And in that case, how do I actually connect the VIN to power from the wall?

Equally bad. :cold_sweat:

The "barrel connector" and "Vin" feed the regulator on board the UNO. This regulator - with virtually no heatsink - is more-or-less capable of powering the two processors on the board. Perhaps a few LEDs requiring 20 mA each. But that's it. You do not use it as a means to power 5 V devices which draw any significant current; it will overheat and shut down (hopefully reversibly :roll_eyes: ).

In the video you cite, the UNO variant is powered from the USB connector which is capable of providing something like 500 mA through to the "5V" pin. It is limited by a "polyfuse" to a nominal 500 mA but will generally tolerate a little more. The 3 W LED would presumably draw 700 mA or more (if actually powered to 3 W which it most probably is not) and your 8 NeoPixels up to 480 mA.

chibi-arduino:
Basically I need a light to switch on and off 40 times a second. I don't know how bright it needs to be, but bright enough that you'd be aware of it.

At 40 times per second, the flicker is usually not able to be discerned. So it appears continuous.

If it appears continuous, then that means the signal from the eye to the optic nerve is itself continuous, so there is no reason to suspect it would have any other effect on the brain than - a continuous light. Note that televisions traditionally flickered at 50 or 60 Hz, and I'm not sure whether anyone ever determined a benefit to cognition from watching them. :grinning:

The 3W LEDs are very very bright.

current = 3w/3v(Vf) =~1A <———<<<<< She is over taxing the Arduino!!!

“ how is it possible for her to power a 3w led from the arduino 5V pin??“
It appears each module has a MOSFET transistor on the PCB to drive the high wattage LED.

Suggest you experiment with 20mA regular LEDs before tackling the 3W versions.

Paul__B:
At 40 times per second, the flicker is usually not able to be discerned. So it appears continuous.

If it appears continuous, then that means the signal from the eye to the optic nerve is itself continuous, so there is no reason to suspect it would have any other effect on the brain than - a continuous light. Note that televisions traditionally flickered at 50 or 60 Hz, and I'm not sure whether anyone ever determined a benefit to cognition from watching them. :grinning:

The therapeutic effects of 40Hz flicker on mouse brains was reported in Nature, more than once. They found that 40Hz, and only 40Hz, produced a significant reduction (more than 50%) of amyloid plaque. They also measured the stimulation of 40Hz gamma waves when the brain was stimulated in that way. Most of the plaque reduction was in the visual cortex. Even the researchers were very surprised.

Sometimes what seems logical and rational is not the same as science.

larryd:
Suggest you experiment with 20mA regular LEDs before tackling the 3W versions.

OK. Thanks. So I could do this right?


Except I think the capacitor is supposed to be 1000uF, not mF.

Yes we are using 5v in the schematic, however, you could just as easily use 12v too (the resistors would have to be increased in value).

The MOSFET controls the ‘current’ that flows through the LEDs.

8 LEDs are in parallel each with ~20mA, gives a total of 160mA current to the MOSFET.

The MOSFET can ‘easily’ handle 160mA, in fact, it can handle many amps.

In this case a simple 5VDC cell phone charger could be used.

OK. Thanks. So I could do this right?

Except I think the capacitor is supposed to be 1000uF, not mF.

Yes, this would be WS2812B LED strip.

Disconnect the external power supply and pixel strip when uploading sketches to the UNO.

Thanks! I think I can see myself doing this now! Thank you for your help. Hopefully I won't fry my arduino!

Show us a good image of your wiring before you power things up :wink:

Good luck with Mom.

larryd:
Except I think the capacitor is supposed to be 1000µF, not mF.

Yes, in fact a one mF capacitor. :grinning:

larryd:
It appears each module has a MOSFET transistor on the PCB to drive the high wattage LED.

Yes, but how is it controlling the current?