Go Down

Topic: WS2812B to stairs project (Read 1 time) previous topic - next topic

0vereem

Hello
Im wondering what is the best and easiest way to made stairs project on WS2812B,
like this https://www.youtube.com/watch?v=hD9OyGGNjqg&t=11s
I have 17 stars, each 1.1m so I need 1122 LED (60 led per meter).
I thought about Arduino Mega with 8kb of RAM.
What is the best device to do this project? Maybe someone made project like that already?
Thank You for help
Regards!

septillion

#1
Mar 16, 2018, 10:14 am Last Edit: Mar 16, 2018, 10:16 am by septillion
If you want to do this all on a single Arduino you indeed already need 3366 bytes to store the led info. So a Mega would suit that. You could also use a ESP8266. But it will even be possible on an Arduino Uno (/Pro Mini / Nano) with some memory tricks. Because (at least in the video) once the animation is finished all stairs display the same. So with 2 (stairs) x 66 (leds) x 3 = 396 bytes it possible. But indeed, the full 3366 bytes will ive you more option for animation.

But the  hard part isn't the Arduino but the power management. Every stairs can draw up to 4A with a total of 68A! That is A LOT! That would require around 17mm2 :D Or, what I would do, use 2,5mm2 per two stairs and group all of them at the power supply with multiple lower fuses (like 10A car fuses) in line.

And for the data lines, Don't forget to add a resistor in line with the data line between each stairs. The WS2812B is prone to break when the voltage on the data line is higher then the supply (which can happen because of the multiple voltage lines).
Use fricking code tags!!!!
I want x => I would like x, I need help => I would like help, Need fast => Go and pay someone to do the job...

NEW Library to make fading leds a piece of cake
https://github.com/septillion-git/FadeLed

0vereem

Thank You for reply  ;)

So firstly WS2812B will fully work with Arduino Mega? Im asking because most project with WS2812B are on Uno and ws2812b and mega is not so popular on the internet.

Second thing, I made a quick drawing. Apologize for quality  :-X

I tried to draw how it should be done according to You  8)
Post Your opinion and say what is wrong to fix it  :smiley-red:

Thank You so much
Regards!

Grumpy_Mike

Quote
So firstly WS2812B will fully work with Arduino Mega?
Yes, a Mega is better than a Uno because it has more memory. You need 3 bytes for each led,so for you that will be 1122 x 3 =  3366 bytes, this is more than the total amount of memory that the Uno has, but just less than half that the Mega has.

Your diagram is unclear to me, but join all the grounds and don't connect the 5V lines together.

0vereem

Thank You for help  ;)
To be clear, between data and 1 stair 470ohm resistor and betwen 1st stair data and 2nd stair data resistor as well and until 17th stair etc?
Regards

PaulRB


septillion

Almost, just don't daisy chain the power, feed all strips from a single side directly from the thicker wire. You could connect both ends of the strip to the tick wire but you only have runs of 1,1m so one side should be fine. But what you want to prevent is all power for 5m of strips connected to a single point. So the only thing that daisy chains all the strips (snaking it's way up) is the data with indeed a resistor in line between stairs.

And depending on how many sets/stairs you hook to a single power cable you have to use thicker wire. I would go for something like 1,5mm2 a 2,5mm2 per two stairs. Yes, that is highl on the save side but you have to remeber you only have 5V to start with.

And yeah, you could use multiple smaller PSU's but you could also use a single heavier PSU and just run multiple wires al joining at the PSU. If you want t use multiple PSU's, DON'T connect together all the V+ (5V) connections, only the V- (GND). And I would use a star patern for that. Aka, separate cables (V- and V+) to the strips from the PSU's (assumed to be next to each other) and just loops between the V- connections of all the PSU and the Mega (GND). Nowhere else connect the GND together.
Use fricking code tags!!!!
I want x => I would like x, I need help => I would like help, Need fast => Go and pay someone to do the job...

NEW Library to make fading leds a piece of cake
https://github.com/septillion-git/FadeLed

dave-in-nj

I think in modules.    it comes from my manufacturing background

one module per stair, think of a stair as 1 shift register. or node.
one NANO per stair, one power supply per stair,
two RJ45 connectors to pass the master signals.

If your power supply can do more than one stair, then you can have a 2-stair module, or a 3-stair module....

of course, you would also need line voltage to each power supply, so that big adds complexity.

now you can do 3 stairs or 33 or 333
your master only has to send -  start and end.

or get fancy and have pre-sets and call out
pre-set1   it may have all the lights on dim and slowly light
pre-set2   stair one goes off, then back on after 1/10 second    chase up or down staircase


This means the master does the timing for each stair to start and if you use pre-sets, it picks which to use.

IMHO, you can make one stair module and get it to work, then make copies,  the only difference is the address.
the master only needs to know how many stair modules.

since the cost of a NANO in the clown market is so cheap, you have to weigh your time vs purchases.



PaulRB

since the cost of a NANO in the clown market is so cheap
Don't forget to pick up a red nose and an enourmously long pair of squeeky shoes while you're there!

dave-in-nj

Don't forget to pick up a red nose and an enourmously long pair of squeeky shoes while you're there!
It's the enormously long shoes that are the keys on stairs.....
A NANO clone would be useful. but a NANO clown... that is particularly scary

kolk123

did you work it out? i have a stair with 16 steps. u use 36 leds ea step. so a total of 576. i use a arduino uno rev3 with a 5v 40ah power supply. but if got the codes from https://www.instructables.com/id/LED-Stair-Lighting/  but when i insert al my leds it doesnt work anymore. when i use 548 it works. can u share your code with me? maybe that works. or maybe you know a solution?

Barcors

#11
Jun 07, 2019, 01:57 pm Last Edit: Jun 07, 2019, 02:07 pm by Barcors
Kolk123 you need modify the code.

Go Up