Created
February 27, 2022 22:33
-
-
Save fredowsley/7250f348728117021ab1939a2400b9d3 to your computer and use it in GitHub Desktop.
FastLED Ukraine Flag colors blink
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <FastLED.h> | |
| #define NUM_LEDS 160 | |
| #define DATA_PIN 6 | |
| // Define the array of leds | |
| CRGB leds[NUM_LEDS]; | |
| void setup() { | |
| FastLED.addLeds<WS2812B, DATA_PIN, RGB>(leds, NUM_LEDS); | |
| } | |
| void loop() { | |
| for(int i = 0; i < NUM_LEDS; i++ ) { | |
| leds[i] = CRGB::Yellow; | |
| } | |
| FastLED.show(); | |
| delay(500); | |
| for(int i = 0; i < NUM_LEDS; i++ ) { | |
| leds[i] = CRGB::Blue; | |
| } | |
| FastLED.show(); | |
| delay(500); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment