#include "Freenove_WS2812_Lib_for_ESP32.h"
#define LEDS_COUNT 32
#define LEDS_PIN 2
#define CHANNEL 0
Freenove_ESP32_WS2812 strip = Freenove_ESP32_WS2812(LEDS_COUNT, LEDS_PIN, CHANNEL, TYPE_GRB);
Freenove_ESP32_WS2812 strip_2 = Freenove_ESP32_WS2812(32, 4, 1, TYPE_GRB);
uint8_t m_color[5][3] = { {255, 0, 0}, {0, 255, 0}, {0, 0, 255}, {255, 255, 255}, {0, 0, 0} };
int delayval = 100;
int color=0;
int myWheel=0;
void setup() {
strip.begin();
strip_2.begin();
strip.setBrightness(100);
strip_2.setBrightness(100);
}
void loop() {
for (int j = 0; j < 5; j++) {
for (int i = 0; i < LEDS_COUNT; i++) {
strip.setLedColorData(i, m_color[color][0], m_color[color][1], m_color[color][2]);
//strip_2.setLedColorData(i, m_color[color][0], m_color[color][1], m_color[color][2]);
strip_2.setLedColorData(i,strip_2.Wheel(myWheel));
strip.show();
strip_2.show();
delay(delayval);
if (myWheel < 255)
myWheel = myWheel + 1;
else
myWheel=0;
}
delay(50);
if (color < 5)
color++;
else
color=0;
}
}