#define REDPIN 5
#define GREENPIN 6
#define BLUEPIN 3
void showAnalogRGB(
const CRGB& rgb)
{
analogWrite(REDPIN, rgb.
r );
analogWrite(GREENPIN, rgb.
g );
analogWrite(BLUEPIN, rgb.
b );
}
void colorBars()
{
}
void loop()
{
static uint8_t hue;
hue = hue + 1;
showAnalogRGB(
CHSV( hue, 255, 255) );
delay(20);
}
void setup() {
pinMode(REDPIN, OUTPUT);
pinMode(GREENPIN, OUTPUT);
pinMode(BLUEPIN, OUTPUT);
colorBars();
}
central include file for FastLED, defines the CFastLED class/object
uint8_t r
Red channel value.
uint8_t g
Green channel value.
uint8_t b
Blue channel value.
Representation of an HSV pixel (hue, saturation, value (aka brightness)).
Representation of an RGB pixel (Red, Green, Blue)