Example to demonstrate how to create an animation sequence for a WS2812 RGB LED strip using ALA library.
#include "AlaLedRgb.h"
AlaLedRgb rgbStrip;
AlaSeq seq[] =
{
{ ALA_OFF, 1000, 2000, alaPalNull },
{ ALA_ON, 1000, 2000, alaPalRgb },
{ ALA_SPARKLE, 1000, 9000, alaPalRgb },
{ ALA_CYCLECOLORS, 3000, 6000, alaPalRgb },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_FADECOLORSLOOP, 3000, 6000, alaPalRgb },
{ ALA_SPARKLE2, 1000, 6000, alaPalRgb },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_SPARKLE2, 1000, 6000, alaPalFire },
{ ALA_PIXELSMOOTHSHIFTRIGHT, 6000, 2000, alaPalRgb },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_MOVINGBARS, 3000, 6000, alaPalRgb },
{ ALA_COMET, 3000, 6000, alaPalRgb },
{ ALA_COMETCOL, 3000, 6000, alaPalRgb },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_GLOW, 3000, 6000, alaPalRgb },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_FIRE, 1000, 6000, alaPalFire },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_BOUNCINGBALLS, 1000, 6000, alaPalRgb },
{ ALA_OFF, 1000, 1000, alaPalNull },
{ ALA_BUBBLES, 1000, 6000, alaPalRainbow },
{ ALA_ENDSEQ }
};
void setup()
{
delay(1000);
rgbStrip.initWS2812(60, 6);
rgbStrip.setBrightness(0x444444);
rgbStrip.setAnimation(seq);
}
void loop()
{
rgbStrip.runAnimation();
}
so how do you pick just one sequence? like the comet sequence for example?
ReplyDeleteIm using this with a rgb neopixel 60 strip in a replica proton pack from the new ghostbusters movie.
it needs to constantly cycle in a clockwise pattern with a fading tail like the comet sequence.
also there needs not to be too much of a gap in between each pass around.
the proton pack synchrotron has a constant spiraling pattern that I'm trying to achieve .
tommyb345@yahoo.com
Delete the rest of the animations n remain with the comet...then u can change the speed and duration respectively ( 3000, 6000)
DeleteHow can I make the sequence run continuously? Mine runs one time and then stops.
ReplyDelete?????? How can I make the sequence run continuously? Mine runs one time and then stops.
ReplyDeleteThis comment has been removed by the author.
ReplyDeleteWhen I run this example sketch, the "Fire" pattern is green. I have had similar issues with other sketches. I think my strip is GRB rather than RGB. Is there a way to correct for this?
ReplyDelete