diff --git a/README.md b/README.md index 2c3743db..853ab20d 100644 --- a/README.md +++ b/README.md @@ -27,10 +27,15 @@ void setup() { } ``` -## Plugin methods +## Plugin properties -The plugin provides the `LEDBreatheEffect` object, which has no public methods or -properties, outside of those provided by all LED modes. +The plugin provides the `LEDBreatheEffect` object, which has a single property: + +### `.hue` + +> The hue of the breathe effect. +> +> Defaults to 170. ## Dependencies diff --git a/src/Kaleidoscope-LEDEffect-Breathe.cpp b/src/Kaleidoscope-LEDEffect-Breathe.cpp index 6551bfbb..d7c9484c 100644 --- a/src/Kaleidoscope-LEDEffect-Breathe.cpp +++ b/src/Kaleidoscope-LEDEffect-Breathe.cpp @@ -2,7 +2,7 @@ namespace kaleidoscope { void LEDBreatheEffect::update(void) { - cRGB color = breath_compute(); + cRGB color = breath_compute(hue); ::LEDControl.set_all_leds_to(color); } } diff --git a/src/Kaleidoscope-LEDEffect-Breathe.h b/src/Kaleidoscope-LEDEffect-Breathe.h index b9cad307..715bd819 100644 --- a/src/Kaleidoscope-LEDEffect-Breathe.h +++ b/src/Kaleidoscope-LEDEffect-Breathe.h @@ -8,6 +8,8 @@ class LEDBreatheEffect : public LEDMode { public: LEDBreatheEffect(void) {} + uint8_t hue = 170; + protected: void update(void) final; };