FastLED 3.9.15
Loading...
Searching...
No Matches

◆ loop()

void loop ( )

Definition at line 46 of file DemoReel100.ino.

47{
48 // Call the current pattern function once, updating the 'leds' array
50
51 // send the 'leds' array out to the actual LED strip
52 FastLED.show();
53 // insert a delay to keep the framerate modest
54 FastLED.delay(1000/FRAMES_PER_SECOND);
55
56 // do some periodic updates
57 EVERY_N_MILLISECONDS( 20 ) { gHue++; } // slowly cycle the "base color" through the rainbow
58 EVERY_N_SECONDS( 10 ) { nextPattern(); } // change patterns periodically
59}
void nextPattern()
uint8_t gCurrentPatternNumber
#define FRAMES_PER_SECOND
uint8_t gHue
SimplePatternList gPatterns
CFastLED FastLED
Global LED strip management instance.
Definition FastLED.cpp:58
#define EVERY_N_MILLISECONDS(N)
Alias for EVERY_N_MILLIS.
Definition lib8tion.h:1359
#define EVERY_N_SECONDS(N)
Checks whether to execute a block of code every N seconds.
Definition lib8tion.h:1324

References EVERY_N_MILLISECONDS, EVERY_N_SECONDS, FastLED, FRAMES_PER_SECOND, gCurrentPatternNumber, gHue, gPatterns, and nextPattern().

+ Here is the call graph for this function: