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

◆ updateLEDs()

void updateLEDs ( )

Definition at line 54 of file Loopback.ino.

54 {
55 switch (state) {
56 case SERVER_STARTING:
57 // Blue pulse while server initializes
59 break;
60
62 case TESTS_RUNNING:
63 // Yellow during test execution
64 fill_solid(leds, NUM_LEDS, fl::CRGB(64, 64, 0));
65 break;
66
67 case ALL_PASSED:
68 // Green when all tests pass
69 fill_solid(leds, NUM_LEDS, fl::CRGB(0, 64, 0));
70 break;
71
72 case FAILED:
73 // Red when tests fail
74 fill_solid(leds, NUM_LEDS, fl::CRGB(64, 0, 0));
75 break;
76 }
77}
#define NUM_LEDS
fl::CRGB leds[NUM_LEDS]
@ SERVER_STARTING
TestState state
@ WAITING_FOR_TESTS
Definition Loopback.ino:44
@ TESTS_RUNNING
Definition Loopback.ino:45
void fill_solid(CRGB *targetArray, int numToFill, const CRGB &color) FL_NOEXCEPT
Fill a range of LEDs with a solid color.
Definition fill.cpp.hpp:9
LIB8STATIC u8 beatsin8(accum88 beats_per_minute, u8 lowest=0, u8 highest=255, u32 timebase=0, u8 phase_offset=0) FL_NOEXCEPT
Generates an 8-bit sine wave at a given BPM that oscillates within a given range.
Definition beat.h:105
Representation of an 8-bit RGB pixel (Red, Green, Blue)
Definition crgb.h:38

References ALL_PASSED, beatsin8(), FAILED, fill_solid(), leds, NUM_LEDS, SERVER_STARTING, state, TESTS_RUNNING, and WAITING_FOR_TESTS.

Referenced by loop(), and setup().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: