Maker Pro
Maker Pro

LED Arduino Control

k12lit

May 18, 2023
1
Joined
May 18, 2023
Messages
1
Hello. I am a complete novice looking to build a 30" led strip with knobs I can control on-the-fly (color, brightness, length of movement, and speed of light moving back and forth). Looks like the Arduino R3 is the right controller with potentiometers as the knobs. Are there people on this forum that will help me design this and find the right components and housing for the R3 and knobs? I have someone local that can check the project when it is complete to verify that it will be safe, but he is really busy, and I don't want to bother him until I have all of the components ready to build.
 

bidrohini

Feb 1, 2023
164
Joined
Feb 1, 2023
Messages
164
You can get an idea from this tutorial:
This video uses Slide POT instead of a knob system. But the basic principle will be the same.
If you ever wish to make something more aesthetic, you can make an LED strip connector for LED fireworks like this:

 

iouae

May 14, 2023
24
Joined
May 14, 2023
Messages
24
Hello. I am a complete novice looking to build a 30" led strip with knobs I can control on-the-fly (color, brightness, length of movement, and speed of light moving back and forth). Looks like the Arduino R3 is the right controller with potentiometers as the knobs. Are there people on this forum that will help me design this and find the right components and housing for the R3 and knobs? I have someone local that can check the project when it is complete to verify that it will be safe, but he is really busy, and I don't want to bother him until I have all of the components ready to build.
Hi

You do know that you can buy multicolour LED strips with a remote for less than the price of the Arduino?
I take it therefore that this is purely a learning experience?

Where are you going to get the multicolour strip, and does it come with instructions on how to control colour and brightness etc?
 

iouae

May 14, 2023
24
Joined
May 14, 2023
Messages
24
I asked Shako.ai…



“You asked:

Arduino R3 multicolour LED strip controller program



Shako.ai replied

Here is an example of a program for controlling a multicolour LED strip using an Arduino R3 board:





C:
#include <Adafruit_NeoPixel.h>

2
3const int LED_PIN = 8; // Pin the LED strip is connected to
4const int NUM_LEDS = 8 * 64; // Number of LEDs in the strip
5const int STRIP_WS2812 = 5; // Pin the WS2812 chip is connected to
6
7Adafruit_NeoPixel strip = Adafruit_NeoPixel(NUM_LEDS, LED_PIN, NEO_GRB + NEO_KHZ800);
8
9void setup() {
10  strip.begin();
11  pinMode(LED_PIN, OUTPUT);
12}
13
14void loop() {
15  strip.setPixelColor(0, 0, 255, 0); // Set the first LED to red
16  strip.setPixelColor(1, 0, 0, 255); // Set the second LED to green
17  strip.setPixelColor(2, 0, 0, 0); // Set the third LED to blue
18  strip.show();
19  delay(1000);
20}
21
[mod edit: put the code in a code box for better readability]

This program uses the Adafruit NeoPixel library to control an 8x64 LED strip connected to the Arduino R3 board. The `strip` object is initialized with the number of LEDs in the strip, the pin the LED strip is connected to, and the color order (GRB).

In the `loop()` function, the first three LEDs are set to red, green, and blue, respectively, and the `strip.show()` function is called to turn on all the LEDs. A delay of 1000 milliseconds is added to allow the colors to fade smoothly.

This is just a simple example, and the colors and timing can be adjusted to create different effects. It is also possible to use the `strip.setPixelColor()` function to individually control the color of each LED in the strip.

It is important to note that the LED strip should be connected to a power supply that can provide enough current to drive all the LEDs, and to properly bias the LED strip to ensure stable operation.
 
Last edited by a moderator:

Harald Kapp

Moderator
Moderator
Nov 17, 2011
13,632
Joined
Nov 17, 2011
Messages
13,632
You may want to check out the WLED project.
It is not primarily for an Arduino, instead it works with an ESP32, for example. It has WiFi control (e.g. via your smartphone) and is customizable to different lengths of LED strips. It also comes with loads of build-in effects.
 
Top