#include <FastLED.h>
#define LED_PIN 5
#define NUM_LEDS 80
CRGB leds[NUM_LEDS];
void setup() {
FastLED.addLeds<NEOPIXEL, LED_PIN>(leds, NUM_LEDS);
}
void loop() {
// Pattern 1: Color wipe
for(int i = 0; i < NUM_LEDS; i++) {
leds[i] = CRGB::Red;
FastLED.show();
delay(50);
}
for(int i = 0; i < NUM_LEDS; i++) {
leds[i] = CRGB::Green;
FastLED.show();
delay(50);
}
for(int i = 0; i < NUM_LEDS; i++) {
leds[i] = CRGB::Blue;
FastLED.show();
delay(50);
}
// Pattern 2: Rainbow
for(int i = 0; i < 256; i++) {
for(int j = 0; j < NUM_LEDS; j++) {
leds[j] = CHSV(i, 255, 255);
}
FastLED.show();
delay(10);
}
}