FastLED 3.9.15
Loading...
Searching...
No Matches
WS2816.ino
Go to the documentation of this file.
1
7
8#include <FastLED.h>
9
10// How many leds in your strip?
11#define NUM_LEDS 1
12
13
14#define DATA_PIN 3
15
16
17// Define the array of leds
19
20void setup() {
21 // Uncomment/edit one of the following lines for your leds arrangement.
22 // ## Clockless types ##
23 FastLED.addLeds<WS2816, DATA_PIN>(leds, NUM_LEDS); // GRB ordering is assumed
24}
25
26void loop() {
27 // Turn the LED on, then pause
28 leds[0] = CRGB::Red;
29 FastLED.show();
30 delay(500);
31 // Now turn the LED off, then pause
32 leds[0] = CRGB::Black;
33 FastLED.show();
34 delay(500);
35}
void setup()
void loop()
CRGB leds[NUM_LEDS]
Definition Apa102.ino:11
#define NUM_LEDS
Definition Apa102.ino:6
CFastLED FastLED
Global LED strip management instance.
Definition FastLED.cpp:58
central include file for FastLED, defines the CFastLED class/object
WS2816 controller class.
Definition FastLED.h:201
@ Red
<div style='background:#FF0000;width:4em;height:4em;'></div>
Definition crgb.h:611
@ Black
<div style='background:#000000;width:4em;height:4em;'></div>
Definition crgb.h:499
Representation of an RGB pixel (Red, Green, Blue)
Definition crgb.h:54