Make the hue configurable

Fixes #3.

Signed-off-by: Gergely Nagy <algernon@keyboard.io>
pull/365/head
Gergely Nagy 6 years ago
parent 75cb920de6
commit 9592ef1ae8

@ -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

@ -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);
}
}

@ -8,6 +8,8 @@ class LEDBreatheEffect : public LEDMode {
public:
LEDBreatheEffect(void) {}
uint8_t hue = 170;
protected:
void update(void) final;
};

Loading…
Cancel
Save