Kaleidoscope
Kaleidoscope-LEDEffect-Rainbow.h
Go to the documentation of this file.
1 #pragma once
2 
4 #include "LEDUtils.h"
5 
6 class LEDRainbowEffect_ : public LEDMode {
7  public:
8  LEDRainbowEffect_(void);
9 
10  void brightness(byte);
11  void update(void) final;
12 
13  private:
14  uint16_t rainbow_hue = 0; // stores 0 to 614
15 
16  uint8_t rainbow_steps = 1; // number of hues we skip in a 360 range per update
17  uint16_t rainbow_current_ticks = 0;
18  uint16_t rainbow_ticks = 10; // delays between update
19 
20  byte rainbow_saturation = 255;
21  byte rainbow_value = 50;
22 };
23 
25 
27  public:
29 
30  void brightness(byte);
31  void update(void) final;
32 
33  private:
34  uint16_t rainbow_hue = 0; // stores 0 to 614
35 
36  uint8_t rainbow_wave_steps = 1; // number of hues we skip in a 360 range per update
37  uint16_t rainbow_current_ticks = 0;
38  uint16_t rainbow_wave_ticks = 10; // delays between update
39 
40  byte rainbow_saturation = 255;
41  byte rainbow_value = 50;
42 };
43 
Definition: Kaleidoscope-LEDEffect-Rainbow.h:6
Definition: Kaleidoscope-LEDControl.h:11
LEDRainbowEffect_(void)
Definition: Kaleidoscope-LEDEffect-Rainbow.cpp:3
void update(void) final
Definition: Kaleidoscope-LEDEffect-Rainbow.cpp:6
Definition: Kaleidoscope-LEDEffect-Rainbow.h:26
LEDRainbowEffect_ LEDRainbowEffect
Definition: Kaleidoscope-LEDEffect-Rainbow.cpp:26
void brightness(byte)
Definition: Kaleidoscope-LEDEffect-Rainbow.cpp:22
LEDRainbowWaveEffect_ LEDRainbowWaveEffect
Definition: Kaleidoscope-LEDEffect-Rainbow.cpp:58