I've just begun programming my set of WS2815 LEDs and am unsure how to send individual "pulses" (like a chunk of LEDs n-wide) down the led strip on command. I am not setting the LED values based on an audio input like other programmers who are then able to just shift every array value down one. This ideally would be a command like sendPulse(); which would be able to send a pulse even if there is one already on the strip, preferably with the option to change speeds so that some pulses would be faster than others. Does anyone know how to do this? I'm using the adafruit library but that shouldn't be too relevant. I've taken my university's intro to computer science course but remain unsure.
Here's my code that I have for sending multiple pulses rn. (strip.fill() works as strip.fill(enter color you want, where to start on the strip, how many leds after that you want to fill)
// Sends a beat of light down the strip. Width is the width of the
// block of light and spacing is the space between the blocks of
// active LEDs
void sendBeats(uint32_t color, int width, int numBeats, int spacing) {
// first for-loop sets the time for the entire function
for(int a=0; a<300 + numBeats*(spacing + width); a++) {
// second for-loop sends out each beat
for(int num=0; num<numBeats; num++) {
strip.fill(color, a - num*(spacing + width), width);
}
strip.show();
delay(2);
strip.clear();
}
}