Class eva::CountdownIndicator¶
ClassList > eva > CountdownIndicator
Indicator that blinks a specified number of times then notifies listener.More...
#include <evaCountdownIndicator.h>
Inherits the following classes: eva::BlinkingIndicator
Public Functions¶
| Type | Name |
|---|---|
| void | on (unsigned short period, unsigned char dutycyclePercent, unsigned char count) Starts countdown blinking. |
| void | on (unsigned short period, unsigned char dutycyclePercent, unsigned char count, IHandler * listener) Starts countdown blinking. |
| void | on () Turns on the indicator continuously. |
| void | on (unsigned short period, unsigned char dutycyclePercent) Turns on the indicator with blinking pattern. |
| CountdownIndicator * | setListener (IHandler * listener) Assigns or changes the event listener. |
Public Functions inherited from eva::BlinkingIndicator¶
| Type | Name |
|---|---|
| Indicator (unsigned pin, int activationLevel=HIGH) Constructor. |
|
| void | off () Turns off the indicator. |
| void | on () Turns on the indicator continuously. |
| void | on (unsigned short period, unsigned char dutycyclePercent) Turns on the indicator with blinking pattern. |
Public Functions inherited from eva::Indicator¶
See eva::Indicator
| Type | Name |
|---|---|
| Indicator (unsigned pin, int activationLevel=HIGH) Constructor. |
|
| void | off () Turns the indicator off. |
| void | on () Turns the indicator on. |
Public Functions inherited from eva::IHandler¶
See eva::IHandler
| Type | Name |
|---|---|
| virtual void | invoke (void * msgSender, CallbackInfo cbInfo) = 0 |
Protected Attributes inherited from eva::BlinkingIndicator¶
| Type | Name |
|---|---|
| unsigned char | dutycyclePercent |
| DelayTimer | dutycycleTimer |
| DelayTimer | heartbeatTimer |
| unsigned short | period |
Protected Functions inherited from eva::BlinkingIndicator¶
| Type | Name |
|---|---|
| void | startCycle () |
Detailed Description¶
Note: This class serves as a demonstration of library concepts and is intentionally kept simple for clarity. Performance optimization was not the primary focus. It is recommended for prototyping stages to validate your application logic. For production use with strict timing requirements, consider implementing a custom solution based on your specific needs.
Public Functions Documentation¶
function on [1/4]¶
Starts countdown blinking.
void eva::CountdownIndicator::on (
unsigned short period,
unsigned char dutycyclePercent,
unsigned char count
)
Parameters:
periodBlinking period in millisecondsdutycyclePercentOn-time percentagecountNumber of blinks before stopping
function on [2/4]¶
Starts countdown blinking.
void eva::CountdownIndicator::on (
unsigned short period,
unsigned char dutycyclePercent,
unsigned char count,
IHandler * listener
)
Parameters:
periodBlinking period in millisecondsdutycyclePercentOn-time percentagecountNumber of blinks before stoppinglistenerHandler to notify when countdown completes
function on [3/4]¶
Turns on the indicator continuously.
void eva::CountdownIndicator::on ()
function on [4/4]¶
Turns on the indicator with blinking pattern.
void eva::CountdownIndicator::on (
unsigned short period,
unsigned char dutycyclePercent
)
Parameters:
periodBlinking period in millisecondsdutycyclePercentOn-time percentage (0-100)
function setListener¶
Assigns or changes the event listener.
CountdownIndicator * eva::CountdownIndicator::setListener (
IHandler * listener
)
Parameters:
listenerPointer to IHandler implementation that will receive timer events
Returns:
Pointer to this DelayTimer instance for method chaining
The documentation for this class was generated from the following file src/evaCountdownIndicator.h