Full day Sun simulation

I’m looking to use 2 LED strips at 400 LEDs each to simulate the sun from sunrise to sunset over my slot car track, and darkness. All 24 hours crammed into 24 minutes. Ideally I’d like to be able to adjust the color of some of these LEDs as the sun is orange when it’s low. Is this feasible or am I just insane? Also, I’m putting in the ceiling so all options are on the table.

Thanks in advance.

Welcome to the forum

What you describe sounds quite feasible using individually addressable LEDs such as WS2812 . Be aware that you will need a power supply that is able to provide the required current to drive the LEDs

Any suggestions as to which board I’ll need to use? I’m totally clueless on this programming part.

Personally I would use an ESP32 because it opens the possibility of WiFi or Bluetooth remote control and has plenty of memory

You can use just about any of the Arduino boards to accomplish what you want. Consider as UKHeliBob suggested use one of the ESP devices if you plan on WiFi or Bluetooth in the future.

The processing power required is minimal, but the memory required for 800 LEDs would rule out many Arduino boards as each one requires 3 bytes of memory

1 Like

If ws2811 strips powered with 12V supply were used, this would still allow colour and brightness to be adjusted for different LEDs. Not for each LED individually, only for groups if 3 LEDs, but that should still be good enough for sunrise/sunset effects.

With this type of strip, even the most basic types of Arduino like Uno/Nano could be used because less dynamic memory is required. Also the current required for the strips would be lower, making wiring the strips somewhat easier.

1 Like

How far away is the ceiling from the race track?
What are the dimensions of the race track?
How did you determine that 800 LED would be adequate?

1 Like

I was originally told that the Uno R3 would be at its limit with 600 LEDs.

That is why I did not suggest using a Uno

1 Like

The track is on a 10ft x 20ft table. Two rows of 22ft to allow for shadows to form at “twilight.”
At 60 LEDs/m I’ll have 804 LEDs. I can drop those 4 LEDs and be fine.

Is there a board with an SD slot?

You can add an SD card module to any Arduino that has SPI and I think they all do.

What is the SD card for?

If you were thinking to increase the memory of the Arduino to deal with more LEDs, sorry, wrong kind of memory.

Although many kinds of Arduino can use an SD card, this also consumes a significant amount of dynamic memory, leaving even less available for LEDs.

That is the limit for ws2812 LEDs.

With ws2811, 12V LED strip, the limit would be 3 times higher (because LEDs are not individually controlled, only groups of 3 LEDs are controlled).

I found the Uno/Nano memory limit with Ws2812to be 622. I am not an expert, so you may do better.

See post #11 reference to WS2811:

I searched "colors of sunrise" and picked one of thousands... I would make the number of colors a multiple of 24. Here is an 888 hexcode:

0. Black: 0x00, 0x00, 0x00
1. Purple: 0x80, 0x00, 0x80
2. Blue: 0x00, 0x00, 0xf0
3. Light blue: 0x00, 0xc0, 0xf0
4. Yellow: 0xf0, 0xf0, 0x00
5. Orange: 0xf0, 0xb0, 0x00
6. Red: 0xf0, 0x00, 0x00
7. White: 0xf0, 0xf0, 0xf0

Sunset is reversed order.

  • Imagine these 16 steps with midnight (step #0) at the center pixels with the next step (or two steps, or more) at the "horizon."
  • At 1/24th of the "day", change each section of pixels to the next step.

For smoother result:

  1. use more in-between colors in your color palette (a finer step)
  2. "fade" from one color (step) to the next by individually stepping each section from "old R" to "new R" hexcode (same with G and B) during 1/24 of the day
1 Like

The SD slot was for memory expansion.
It’s looking like I need groups of 3 on my LED strip instead of individual.

Your idea is feasible but you are going the wrong way about it with addressable LEDs for two reasons:

  1. You have no need to control individual LEDs, only a couple groups of them.
  2. RGB LEDs have very low CRI (Color Rendering Index), which will make your scene appear darker and have bad color rendering.

The sunlight CCT (correlated color temperature) typically varies from about 2000-3000K to about 5600K at noon and then goes back down to 2000-3000K.
At the very least, you may be able to accomplish your goal with just two groups of LEDs - the warm white (2700K) and the cold white (6400K). Those are the most frequently used and available LEDs on the market, so finding them would be no problem.

There are LED modules containing warm and cool white LEDs, I'm not sure about indivudal warm/cool combo LEDs though they likely exist.

If you want to go to a more orangish end of the sunlight spectrum, there are LEDs specified at CCT of 2000-2200K.

As for Arduino implementation, literally any MCU with a DAC or PWM output will do - all you would need are two outputs connected to a MOSFET which runs the LEDs.
You would need to intertwine LEDs, placing them in alternating single lines of warm white and cool white LEDs, and then place a transparent white cover so that the individual color shaddows are not visible on lit objects.

If you need more details about the implementation (electronics wise), let me know, though I can't promise I will be able to answer quickly.

As long as all the strips are to show the same colour (or a matrix with a colour sequence where all strips have the same sequence, such as for a sunset simulation) you can run a bunch of shorter strips in parallel instead.

True, but using 800 separate addressable LEDs would offer the greatest flexibility