#include <modm/ui/animation/indicator.hpp>
|  | 
|  | Indicator (Animation< T > &animator) | 
|  | constructs an indicator with a period of 1s 
 | 
|  | 
| void | setPeriod (TimeType period, uint8_t dutyCycle=50) | 
|  | 
| void | setFadeTimes (TimeType onFade, TimeType offFade) | 
|  | 
| void | setRange (T minValue, T maxValue) | 
|  | 
| void | start (uint8_t repeat=0) | 
|  | start indicating for ever 
 | 
|  | 
| void | stop () | 
|  | 
| bool | isAnimating () const | 
|  | 
| void | update () | 
|  | Must be called at least every ms. 
 | 
|  | 
template<typename T = uint8_t>
class modm::ui::Indicator< T >
This class provided smooth on and off phases, much like a blinker/indicator on cars.
 |-------------- period -|
 |- duty cycle -|
  ______________          _____
_/              \________/      ...
 ^ onFade       ^ offFade
- Author
- Niklas Hauser 
template<typename T  = uint8_t> 
  
  | 
        
          | void modm::ui::Indicator< T >::setFadeTimes | ( | TimeType | onFade, |  
          |  |  | TimeType | offFade |  
          |  | ) |  |  |  | inline | 
 
- Parameters
- 
  
    | onFade | the time is takes to turn on in ms |  | offFade | the time is takes to turn off in ms |  
 
 
 
template<typename T  = uint8_t> 
  
  | 
        
          | void modm::ui::Indicator< T >::setPeriod | ( | TimeType | period, |  
          |  |  | uint8_t | dutyCycle = 50 |  
          |  | ) |  |  |  | inline | 
 
- Parameters
- 
  
    | period | in ms |  | dutyCycle | in percent <= 100 |  
 
 
 
The documentation for this class was generated from the following file: