#include"Arduino.h"#include<FastLED.h>// How many leds in your strip?
#define NUM_LEDS 1
#define DATA_PIN 27
// Define the array of leds
CRGB leds[NUM_LEDS];
/* After STAMP-PICO is started or reset
the program in the setUp () function will be run, and this part will only be run once.
*/voidsetup() {
FastLED.addLeds<SK6812, DATA_PIN, RGB>(leds, NUM_LEDS); // GRB ordering is typical
}
/* After the program in setup() runs, it runs the program in loop()
The loop() function is an infinite loop in which the program runs repeatedly
*/voidloop() {
// Turn the LED on, then pause
leds[0] =0xf00000;
FastLED.show();
delay(500);
// Now turn the LED off, then pause
leds[0] =0x00f000;
FastLED.show();
delay(500);
// Now turn the LED off, then pause
leds[0] =0x0000f0;
FastLED.show();
delay(500);
}