Hey you all I’m new to working with neopixels or fastLED for that matter, but for a project I’m trying to make snake with ws2812b LED-strips (it’s 285 LED’s big), I was wondering is there any way to have a expandable trail on fastLED?
Thanks in advance
marmil
(Marc Miller)
January 10, 2018, 9:10am
2
Do you mean something similar to the cylon example but with a longer trail?
#include <FastLED.h>
// How many leds in your strip?
#define NUM_LEDS 64
// For led chips like Neopixels, which have a data line, ground, and power, you just
// need to define DATA_PIN. For led chipsets that are SPI based (four wires - data, clock,
// ground, and power), like the LPD8806, define both DATA_PIN and CLOCK_PIN
#define DATA_PIN 2
#define CLOCK_PIN 13
// Define the array of leds
CRGB leds[NUM_LEDS];
void setup() {
Serial.begin(57600);
Serial.println("resetting");
LEDS.addLeds<WS2812,DATA_PIN,RGB>(leds,NUM_LEDS);
LEDS.setBrightness(84);
}
This file has been truncated. show original
Experiment with changing the 250 at the end of line 22 to vary the tail length.
@marmil yes, I was looking for something like that, thanks