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

◆ setup()

void setup ( )

Definition at line 62 of file FxNoiseRing.ino.

62 {
63 Serial.begin(115200);
64 // ScreenMap is purely something that is needed for the sketch to correctly
65 // show on the web display. For deployements to real devices, this essentially
66 // becomes a no-op.
68 controller = &FastLED.addLeds<WS2811, DATA_PIN, COLOR_ORDER>(leds, NUM_LEDS)
69 .setCorrection(TypicalLEDStrip)
70 .setDither(DISABLE_DITHER)
71 .setScreenMap(xyMap);
72 FastLED.setBrightness(brightness);
73 pir.activate(fl::millis()); // Activate the PIR sensor on startup.
74}
#define COLOR_ORDER
fl::XYMap xyMap
#define NUM_LEDS
fl::CRGB leds[NUM_LEDS]
fl::UISlider brightness("Brightness", BRIGHTNESS, 0, 255)
#define DATA_PIN
Definition ClientReal.h:82
FL_DISABLE_WARNING_PUSH FL_DISABLE_WARNING_GLOBAL_CONSTRUCTORS CFastLED FastLED
Global LED strip management instance.
CLEDController * controller
fl::Pir pir(PIN_PIR, PIR_LATCH_MS, PIR_RISING_TIME, PIR_FALLING_TIME)
static ScreenMap Circle(int numLeds, float cm_between_leds=1.5f, float cm_led_diameter=0.5f, float completion=1.0f) FL_NOEXCEPT
#define DISABLE_DITHER
Disable dithering.
Definition dither_mode.h:10
@ TypicalLEDStrip
Typical values for SMD5050 LEDs.
Definition color.h:15
fl::u32 millis()
Universal millisecond timer - returns milliseconds since system startup.
#define Serial
Definition serial.h:304

References brightness, fl::ScreenMap::Circle(), COLOR_ORDER, controller, DATA_PIN, DISABLE_DITHER, FastLED, leds, fl::millis(), NUM_LEDS, pir, Serial, TypicalLEDStrip, and xyMap.

+ Here is the call graph for this function: