33#ifndef _BUTTONTOSWITCH_ESP32_H_
34#define _BUTTONTOSWITCH_ESP32_H_
39#define _HwMinDbncTime 20
40#define _StdPollDelay 10
41#define _MinSrvcTime 100
42#define _InvalidPinNum GPIO_NUM_NC
43#define _maxValidPinNum GPIO_NUM_MAX-1
46const uint8_t IsOnBitPos {0};
47const uint8_t IsEnabledBitPos{1};
48const uint8_t PilotOnBitPos{2};
49const uint8_t WrnngOnBitPos{3};
50const uint8_t IsVoidedBitPos{4};
51const uint8_t IsOnScndryBitPos{5};
52const uint8_t OtptCurValBitPos{16};
75typedef void (*fncPtrType)();
76typedef fncPtrType (*ptrToTrnFnc)();
105 const unsigned long int _stdMinDbncTime {_HwMinDbncTime};
110 unsigned long int _dbncTimeOrigSett{};
112 unsigned long int _dbncRlsTimerStrt{0};
113 unsigned long int _dbncRlsTimeTempSett{0};
114 unsigned long int _dbncTimerStrt{0};
115 unsigned long int _dbncTimeTempSett{0};
116 fncPtrType _fnWhnTrnOff{
nullptr};
117 fncPtrType _fnWhnTrnOn{
nullptr};
118 bool _isEnabled{
true};
119 volatile bool _isOn{
false};
120 bool _isOnDisabled{
false};
121 volatile bool _isPressed{
false};
122 fdaDmpbStts _mpbFdaState {stOffNotVPP};
123 TimerHandle_t _mpbPollTmrHndl {NULL};
124 String _mpbPollTmrName {
""};
125 bool _outputsChange {
false};
126 uint32_t _outputsChangeCnt{0};
127 bool _outputsChngTskTrggr{
false};
128 bool _prssRlsCcl{
false};
129 unsigned long int _strtDelay {0};
130 bool _sttChng {
true};
131 TaskHandle_t _taskToNotifyHndl {NULL};
132 TaskHandle_t _taskWhileOnHndl{NULL};
133 volatile bool _validDisablePend{
false};
134 volatile bool _validEnablePend{
false};
135 volatile bool _validPressPend{
false};
136 volatile bool _validReleasePend{
false};
139 const bool getIsPressed()
const;
140 static void mpbPollCallback(TimerHandle_t mpbTmrCbArg);
141 virtual uint32_t _otptsSttsPkg(uint32_t prevVal = 0);
142 void _setIsEnabled(
const bool &newEnabledValue);
146 virtual void updFdaState();
148 virtual bool updValidPressesStatus();
149 const bool getOutputsChngTskTrggr()
const;
150 void resetOutputsChngTskTrggr();
167 DbncdMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0);
184 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
351 bool init(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0);
401 bool setDbncTime(
const unsigned long int &newDbncTime);
495 DbncdDlydMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
504 bool init(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
514 void setStrtDelay(
const unsigned long int &newStrtDelay);
549 bool _isLatched{
false};
550 fdaLmpbStts _mpbFdaState {stOffNotVPP};
551 bool _trnOffASAP{
true};
552 volatile bool _validUnlatchPend{
false};
553 volatile bool _validUnlatchRlsPend{
false};
555 static void mpbPollCallback(TimerHandle_t mpbTmrCbArg);
557 virtual void stDisabled_In(){};
558 virtual void stDisabled_Out(){};
559 virtual void stLtchNVUP_Do(){};
560 virtual void stOffNotVPP_In(){};
561 virtual void stOffNotVPP_Out(){};
562 virtual void stOffNVURP_Do(){};
563 virtual void stOffVPP_Out(){};
564 virtual void stOffVURP_Out(){};
565 virtual void stOnNVRP_Do(){};
566 virtual void updFdaState();
567 virtual void updValidUnlatchStatus() = 0;
578 LtchMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
582 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
674 virtual void stOffNVURP_Do();
675 virtual void updValidUnlatchStatus();
687 TgglLtchMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
703 bool _tmRstbl {
true};
704 unsigned long int _srvcTime {};
705 unsigned long int _srvcTimerStrt{0};
707 virtual void stOffNotVPP_Out();
708 virtual void stOffVPP_Out();
709 virtual void updValidUnlatchStatus();
723 TmLtchMPBttn(
const int8_t &mpbttnPin,
const unsigned long int &svcTime,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
744 bool setSrvcTime(
const unsigned long int &newSrvcTime);
769 void (*_fnWhnTrnOffPilot)() {
nullptr};
770 void (*_fnWhnTrnOffWrnng)() {
nullptr};
771 void (*_fnWhnTrnOnPilot)() {
nullptr};
772 void (*_fnWhnTrnOnWrnng)() {
nullptr};
773 bool _keepPilot{
false};
774 volatile bool _pilotOn{
false};
775 unsigned long int _wrnngMs{0};
776 volatile bool _wrnngOn {
false};
777 unsigned int _wrnngPrctg {0};
779 bool _validWrnngSetPend{
false};
780 bool _validWrnngResetPend{
false};
781 bool _validPilotSetPend{
false};
782 bool _validPilotResetPend{
false};
784 static void mpbPollCallback(TimerHandle_t mpbTmrCbArg);
785 virtual uint32_t _otptsSttsPkg(uint32_t prevVal = 0);
786 virtual void stDisabled_In();
787 virtual void stLtchNVUP_Do();
788 virtual void stOffNotVPP_In();
789 virtual void stOffVPP_Out();
790 virtual void stOnNVRP_Do();
791 void _turnOffPilot();
792 void _turnOffWrnng();
810 HntdTmLtchMPBttn(
const int8_t &mpbttnPin,
const unsigned long int &svcTime,
const unsigned int &wrnngPrctg = 0,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
814 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
928 bool setSrvcTime(
const unsigned long int &newSvcTime);
956 bool _xtrnUnltchPRlsCcl {
false};
958 virtual void stOffNVURP_Do();
959 virtual void updValidUnlatchStatus();
980 const bool &pulledUp,
const bool &typeNO,
const unsigned long int &dbncTimeOrigSett,
const unsigned long int &strtDelay);
989 const bool &pulledUp,
const bool &typeNO,
const unsigned long int &dbncTimeOrigSett,
const unsigned long int &strtDelay);
994 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
1042 volatile bool _isOnScndry{
false};
1043 fdaDALmpbStts _mpbFdaState {stOffNotVPP};
1044 unsigned long _scndModActvDly {2000};
1045 unsigned long _scndModTmrStrt {0};
1046 bool _validScndModPend{
false};
1048 void (*_fnWhnTrnOffScndry)() {
nullptr};
1049 void (*_fnWhnTrnOnScndry)() {
nullptr};
1050 TaskHandle_t _taskWhileOnScndryHndl{NULL};
1052 static void mpbPollCallback(TimerHandle_t mpbTmrCbArg);
1053 virtual uint32_t _otptsSttsPkg(uint32_t prevVal = 0);
1054 virtual void stDisabled_In(){};
1055 virtual void stOnEndScndMod_Out(){};
1056 virtual void stOnScndMod_Do() = 0;
1057 virtual void stOnStrtScndMod_In(){};
1058 virtual void _turnOffScndry();
1059 virtual void _turnOnScndry();
1060 virtual void updFdaState();
1061 virtual bool updValidPressesStatus();
1062 virtual void updValidUnlatchStatus();
1075 DblActnLtchMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
1084 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
1198 virtual void stOnEndScndMod_Out();
1199 virtual void stOnScndMod_Do();
1200 virtual void stOnStrtScndMod_In();
1212 DDlydDALtchMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
1245 bool _autoSwpDirOnEnd{
true};
1246 bool _autoSwpDirOnPrss{
false};
1247 bool _curSldrDirUp{
true};
1248 uint16_t _initOtptCurVal{};
1249 uint16_t _otptCurVal{};
1250 unsigned long _otptSldrSpd{1};
1251 uint16_t _otptSldrStpSize{0x01};
1252 uint16_t _otptValMax{0xFFFF};
1253 uint16_t _otptValMin{0x0000};
1255 virtual uint32_t _otptsSttsPkg(uint32_t prevVal = 0);
1256 bool _setSldrDir(
const bool &newVal);
1257 void stOnEndScndMod_Out();
1258 virtual void stOnScndMod_Do();
1259 virtual void stOnStrtScndMod_In();
1273 SldrDALtchMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0,
const uint16_t initVal = 0xFFFF);
1504 void setFrcdOtptWhnVdd(
const bool &newVal);
1505 void setStOnWhnOtpFrcd(
const bool &newVal);
1524 fdaVmpbStts _mpbFdaState {stOffNotVPP};
1526 void (*_fnWhnTrnOffVdd)() {
nullptr};
1527 void (*_fnWhnTrnOnVdd)() {
nullptr};
1528 bool _frcOtptLvlWhnVdd {
true};
1529 bool _isVoided{
false};
1530 bool _stOnWhnOtptFrcd{
false};
1531 bool _validVoidPend{
false};
1532 bool _validUnvoidPend{
false};
1534 static void mpbPollCallback(TimerHandle_t mpbTmrCb);
1535 virtual uint32_t _otptsSttsPkg(uint32_t prevVal = 0);
1536 bool setVoided(
const bool &newVoidValue);
1537 virtual void stDisabled_In();
1538 virtual void stDisabled_Out();
1539 virtual void stOffNotVPP_In(){};
1540 virtual void stOffVddNVUP_Do(){};
1541 virtual void stOffVPP_Do(){};
1544 virtual void updFdaState();
1545 virtual bool updVoidStatus() = 0;
1558 VdblMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0,
const bool &isOnDisabled =
false);
1664 unsigned long int _voidTime;
1665 unsigned long int _voidTmrStrt{0};
1667 virtual void stOffNotVPP_In();
1668 virtual void stOffVddNVUP_Do();
1669 virtual void stOffVPP_Do();
1670 bool updIsPressed();
1671 virtual bool updVoidStatus();
1684 TmVdblMPBttn(
const int8_t &mpbttnPin,
unsigned long int voidTime,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0,
const bool &isOnDisabled =
false);
1692 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
1715 bool setVoidTime(
const unsigned long int &newVoidTime);
1738 virtual void stOffVddNVUP_Do();
1739 virtual bool updVoidStatus();
1751 SnglSrvcVdblMPBttn(
const int8_t &mpbttnPin,
const bool &pulledUp =
true,
const bool &typeNO =
true,
const unsigned long int &dbncTimeOrigSett = 0,
const unsigned long int &strtDelay = 0);
1759 virtual bool begin(
const unsigned long int &pollDelayMs = _StdPollDelay);
Models a Debounced Delayed Double Action Latched MPB combo switch (Debounced Delayed DALDD-MPB - DD-D...
Definition ButtonToSwitch_ESP32.h:1196
void clrStatus(bool clrIsOn=true)
See DbncddMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:2209
~DDlydDALtchMPBttn()
Class virtual destructor.
Definition ButtonToSwitch_ESP32.cpp:2205
DDlydDALtchMPBttn()
Default class constructor.
Definition ButtonToSwitch_ESP32.cpp:2196
Abstract class, base to model Double Action LDD-MPBs (DALDD-MPBs).
Definition ButtonToSwitch_ESP32.h:1027
bool setScndModActvDly(const unsigned long &newVal)
Sets a new value for the scndModActvDly class attribute.
Definition ButtonToSwitch_ESP32.cpp:1889
void setFnWhnTrnOnScndryPtr(void(*newFnWhnTrnOn)())
Sets the function that will be called to execute every time the object enters the Secondary On State.
Definition ButtonToSwitch_ESP32.cpp:1878
const TaskHandle_t getTaskWhileOnScndry()
Returns the task to be run while the object is in the Secondary On state.
Definition ButtonToSwitch_ESP32.cpp:1823
fncPtrType getFnWhnTrnOnScndry()
Returns the function that is set to execute every time the object enters the Secondary On State.
Definition ButtonToSwitch_ESP32.cpp:1808
void clrStatus(bool clrIsOn=true)
See DbncddMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:1789
bool getIsOnScndry()
Returns the current value of the isOnScndry attribute flag.
Definition ButtonToSwitch_ESP32.cpp:1813
DblActnLtchMPBttn()
Abstract Class default constructor.
Definition ButtonToSwitch_ESP32.cpp:1752
void setTaskWhileOnScndry(const TaskHandle_t &newTaskHandle)
Sets the task to be run while the object is in the On state.
Definition ButtonToSwitch_ESP32.cpp:1905
unsigned long getScndModActvDly()
Returns the current value of the scndModActvDly class attribute.
Definition ButtonToSwitch_ESP32.cpp:1818
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
See DbncdMPBttn::begin(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:1765
void setFnWhnTrnOffScndryPtr(void(*newFnWhnTrnOff)())
Sets the function that will be called to execute every time the object enters the Secondary Off State...
Definition ButtonToSwitch_ESP32.cpp:1868
fncPtrType getFnWhnTrnOffScndry()
returns the function that is set to execute every time the object enters the Secondary Off State.
Definition ButtonToSwitch_ESP32.cpp:1803
~DblActnLtchMPBttn()
Virtual destructor.
Definition ButtonToSwitch_ESP32.cpp:1761
Models a Debounced Delayed MPB (DD-MPB).
Definition ButtonToSwitch_ESP32.h:479
DbncdDlydMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:752
void setStrtDelay(const unsigned long int &newStrtDelay)
Sets a new value to the "Start Delay" strtDelay attribute.
Definition ButtonToSwitch_ESP32.cpp:773
bool init(const int8_t &mpbttnPin, const bool &pulledUp=true, const bool &typeNO=true, const unsigned long int &dbncTimeOrigSett=0, const unsigned long int &strtDelay=0)
see DbncdMPBttn::init(const int8_t, const bool, const bool, const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:763
Base class, models a Debounced Momentary Push Button (D-MPB).
Definition ButtonToSwitch_ESP32.h:96
void setFnWhnTrnOffPtr(fncPtrType newFnWhnTrnOff)
Sets the function that will be called to execute every time the object enters the Off State.
Definition ButtonToSwitch_ESP32.cpp:375
fncPtrType getFnWhnTrnOn()
Returns the function that is set to execute every time the object enters the On State.
Definition ButtonToSwitch_ESP32.cpp:159
void resetFda()
Resets the MPB behavior automaton to it's Initial or Start State
Definition ButtonToSwitch_ESP32.cpp:325
void clrStatus(bool clrIsOn=true)
Clears and resets flags, timers and counters modified through the object's signals processing.
Definition ButtonToSwitch_ESP32.cpp:93
const unsigned long int getCurDbncTime() const
Returns the current debounce period time set for the object.
Definition ButtonToSwitch_ESP32.cpp:149
const TaskHandle_t getTaskWhileOn()
Returns the task to be run (resumed) while the object is in the On state.
Definition ButtonToSwitch_ESP32.cpp:210
void enable()
Enables the input signal processing.
Definition ButtonToSwitch_ESP32.cpp:126
bool pause()
Pauses the software timer updating the computation of the object's internal flags value.
Definition ButtonToSwitch_ESP32.cpp:301
const TaskHandle_t getTaskToNotify() const
Returns the task to be notified by the object when its output flags changes.
Definition ButtonToSwitch_ESP32.cpp:204
virtual ~DbncdMPBttn()
Default virtual destructor.
Definition ButtonToSwitch_ESP32.cpp:64
virtual void setTaskWhileOn(const TaskHandle_t &newTaskHandle)
Sets the task to be run while the object is in the On state.
Definition ButtonToSwitch_ESP32.cpp:495
void setIsOnDisabled(const bool &newIsOnDisabled)
Sets the value of the isOnDisabled attribute flag.
Definition ButtonToSwitch_ESP32.cpp:420
bool end()
Detaches the object from the timer that monitors the input pins, compute and updates the object's sta...
Definition ButtonToSwitch_ESP32.cpp:131
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
Attaches the instantiated object to a timer that monitors the input pins and updates the object statu...
Definition ButtonToSwitch_ESP32.cpp:69
void resetDbncTime()
Resets the debounce process time of the object to the value used at instantiation.
Definition ButtonToSwitch_ESP32.cpp:319
DbncdMPBttn()
Default class constructor.
Definition ButtonToSwitch_ESP32.cpp:38
void disable()
Disables the input signal processing, ignoring the changes of its values.
Definition ButtonToSwitch_ESP32.cpp:121
bool resume()
Resets the outputs change task unblocking trigger (outputsChngTskTrggr) attribute flag.
Definition ButtonToSwitch_ESP32.cpp:343
const bool getIsEnabled() const
Returns the value of the isEnabled attribute flag, indicating the Enabled or Disabled status of the o...
Definition ButtonToSwitch_ESP32.cpp:164
const bool getIsOnDisabled() const
Returns the value of the isOnDisabled attribute flag.
Definition ButtonToSwitch_ESP32.cpp:174
bool init(const int8_t &mpbttnPin, const bool &pulledUp=true, const bool &typeNO=true, const unsigned long int &dbncTimeOrigSett=0)
Initializes an object instantiated by the default constructor.
Definition ButtonToSwitch_ESP32.cpp:215
void setTaskToNotify(const TaskHandle_t &newTaskHandle)
Sets the handle to the task to be notified by the object when its output attribute flags changes.
Definition ButtonToSwitch_ESP32.cpp:472
const bool getOutputsChange() const
Returns the value of the outputsChange attribute flag.
Definition ButtonToSwitch_ESP32.cpp:189
const bool getIsOn() const
Returns the value of the isOn attribute flag.
Definition ButtonToSwitch_ESP32.cpp:169
unsigned long int getStrtDelay()
Returns the current value of the outputs change task unblocking trigger (outputsChngTskTrggr) attribu...
Definition ButtonToSwitch_ESP32.cpp:194
const uint32_t getOtptsSttsPkgd()
Returns the relevant attribute flags values for the object state encoded as a 32 bits value,...
Definition ButtonToSwitch_ESP32.cpp:184
void setFnWhnTrnOnPtr(fncPtrType newFnWhnTrnOn)
Sets the function that will be called to execute every time the object enters the On State.
Definition ButtonToSwitch_ESP32.cpp:387
fncPtrType getFnWhnTrnOff()
Returns the function that is set to execute every time the object enters the Off State.
Definition ButtonToSwitch_ESP32.cpp:154
void setOutputsChange(bool newOutputsChange)
Sets the value of the attribute flag indicating if a change took place in any of the output attribute...
Definition ButtonToSwitch_ESP32.cpp:440
bool setDbncTime(const unsigned long int &newDbncTime)
Sets the debounce process time.
Definition ButtonToSwitch_ESP32.cpp:359
Models a Hinted Timer Latch DD-MPB, a.k.a. Staircase Switch (HTiLDD-MPB).
Definition ButtonToSwitch_ESP32.h:767
bool setSrvcTime(const unsigned long int &newSvcTime)
See TmLtchMPBttn::setSrvcTime(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:1441
fncPtrType getFnWhnTrnOnPilot()
Returns the function that is set to execute every time the object's Pilot attribute flag enters the O...
Definition ButtonToSwitch_ESP32.cpp:1319
void setFnWhnTrnOffWrnngPtr(void(*newFnWhnTrnOff)())
Sets the function that will be called to execute every time the object's Warning is reset.
Definition ButtonToSwitch_ESP32.cpp:1397
fncPtrType getFnWhnTrnOffWrnng()
Returns the function that is set to execute every time the object's Warning attribute flag enters the...
Definition ButtonToSwitch_ESP32.cpp:1314
const bool getWrnngOn() const
Returns the current value of the warningOn attribute flag.
Definition ButtonToSwitch_ESP32.cpp:1334
void setFnWhnTrnOnPilotPtr(void(*newFnWhnTrnOn)())
Sets the function that will be called to execute every time the object's Pilot is set.
Definition ButtonToSwitch_ESP32.cpp:1408
const bool getPilotOn() const
Returns the current value of the pilotOn attribute flag.
Definition ButtonToSwitch_ESP32.cpp:1329
void clrStatus(bool clrIsOn=true)
see DbncdMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:1289
fncPtrType getFnWhnTrnOffPilot()
Returns the function that is set to execute every time the object's Pilot attribute flag enters the O...
Definition ButtonToSwitch_ESP32.cpp:1309
HntdTmLtchMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:1255
void setFnWhnTrnOnWrnngPtr(void(*newFnWhnTrnOn)())
Sets the function that will be called to execute every time the object's Wrnng is set.
Definition ButtonToSwitch_ESP32.cpp:1419
bool setWrnngPrctg(const unsigned int &newWrnngPrctg)
Sets the value for the percentage of service time for calculating the warningOn flag value.
Definition ButtonToSwitch_ESP32.cpp:1456
fncPtrType getFnWhnTrnOnWrnng()
Returns the function that is set to execute every time the object's Warning attribute flag enters the...
Definition ButtonToSwitch_ESP32.cpp:1324
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
See DbncdMPBttn::begin(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:1265
void setFnWhnTrnOffPilotPtr(void(*newFnWhnTrnOff)())
Sets the function that will be called to execute every time the object's Pilot is reset.
Definition ButtonToSwitch_ESP32.cpp:1386
void setKeepPilot(const bool &newKeepPilot)
Sets the configuration of the keepPilot service attribute.
Definition ButtonToSwitch_ESP32.cpp:1430
Abstract class, base to model Latched Debounced Delayed MPBs (LDD-MPB).
Definition ButtonToSwitch_ESP32.h:535
const bool getIsLatched() const
Returns the value of the isLatched attribute flag, indicating the Latched or Unlatched condition of t...
Definition ButtonToSwitch_ESP32.cpp:832
bool unlatch()
Sets the values of the flags needed to unlatch a latched MPB.
Definition ButtonToSwitch_ESP32.cpp:919
const bool getUnlatchRlsPend() const
Returns the value of the "Valid Unlatch Release Pending" attribute.
Definition ButtonToSwitch_ESP32.cpp:847
const bool getUnlatchPend() const
Returns the value of the "Valid Unlatch Pending" attribute.
Definition ButtonToSwitch_ESP32.cpp:842
void setUnlatchPend(const bool &newVal)
Sets the value of the "Valid Unlatch Pending" attribute.
Definition ButtonToSwitch_ESP32.cpp:897
void setTrnOffASAP(const bool &newVal)
Sets the value of the trnOffASAP attribute.
Definition ButtonToSwitch_ESP32.cpp:886
bool getTrnOffASAP()
Returns the value of the trnOffASAP attribute flag.
Definition ButtonToSwitch_ESP32.cpp:837
void setUnlatchRlsPend(const bool &newVal)
Sets the value of the "Valid Unlatch Release Pending" attribute.
Definition ButtonToSwitch_ESP32.cpp:908
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
See DbncdMPBttn::begin(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:795
void clrStatus(bool clrIsOn=true)
See DbncdMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:819
LtchMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:786
Models a Slider Double Action LDD-MPB combo switch, a.k.a. off/on/dimmer, a.k.a. off/on/volume radio ...
Definition ButtonToSwitch_ESP32.h:1242
void clrStatus(bool clrIsOn=true)
Definition ButtonToSwitch_ESP32.cpp:2257
bool setOtptSldrSpd(const uint16_t &newVal)
Sets the output slider speed (otptSldrSpd) attribute.
Definition ButtonToSwitch_ESP32.cpp:2333
uint16_t getOtptValMax()
Returns the top output current value register setting.
Definition ButtonToSwitch_ESP32.cpp:2295
bool getOtptCurValIsMin()
Returns the result of comparing the Output Current Value to the Minimum value setting
Definition ButtonToSwitch_ESP32.cpp:2280
bool setSldrDirDn()
Sets the value of the curSldrDirUp attribute to false.
Definition ButtonToSwitch_ESP32.cpp:2431
bool setOtptValMax(const uint16_t &newVal)
Sets the output current value register maximum value attribute (otptValMax attribute).
Definition ButtonToSwitch_ESP32.cpp:2365
bool swapSldrDir()
Inverts the current curSldrDirUp attribute value.
Definition ButtonToSwitch_ESP32.cpp:2528
~SldrDALtchMPBttn()
Virtual class destructor.
Definition ButtonToSwitch_ESP32.cpp:2253
bool setOtptCurVal(const uint16_t &newVal)
Sets the output current value register.
Definition ButtonToSwitch_ESP32.cpp:2317
uint16_t getOtptCurVal()
Returns the Output Current Value (otpCurVal) attribute.
Definition ButtonToSwitch_ESP32.cpp:2270
bool setSldrDirUp()
Sets the value of the curSldrDirUp attribute to true.
Definition ButtonToSwitch_ESP32.cpp:2436
SldrDALtchMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:2243
bool getSldrDirUp()
Returns the value of the curSldrDirUp attribute.
Definition ButtonToSwitch_ESP32.cpp:2305
bool setOtptSldrStpSize(const uint16_t &newVal)
Sets the output slider step size (otptSldrStpSize) attribute value.
Definition ButtonToSwitch_ESP32.cpp:2349
bool getOtptCurValIsMax()
Returns a boolean value indicating if the "Output Current Value" equals the maximum limit.
Definition ButtonToSwitch_ESP32.cpp:2275
void setSwpDirOnPrss(const bool &newVal)
Sets the value of the "Auto-Swap Direction On Press" (autoSwpDirOnPrss) attribute.
Definition ButtonToSwitch_ESP32.cpp:2448
bool setOtptValMin(const uint16_t &newVal)
Sets the output current value register minimum value attribute (otptValMin attribute).
Definition ButtonToSwitch_ESP32.cpp:2387
uint16_t getOtptValMin()
Returns the bottom output current value register setting.
Definition ButtonToSwitch_ESP32.cpp:2300
unsigned long getOtptSldrSpd()
Returns the current setting for the Output Slider Speed value.
Definition ButtonToSwitch_ESP32.cpp:2285
uint16_t getOtptSldrStpSize()
Returns the current setting for the Output Slider Step Size value.
Definition ButtonToSwitch_ESP32.cpp:2290
void setSwpDirOnEnd(const bool &newVal)
Sets the value of the "Auto-Swap Direction on Ends" (autoSwpDirOnEnd) attribute.
Definition ButtonToSwitch_ESP32.cpp:2441
Models a Single Service Voidable DD-MPB a.k.a. Trigger switch (SSVDD-MPB)
Definition ButtonToSwitch_ESP32.h:1735
virtual void setTaskWhileOn(const TaskHandle_t &newTaskHandle)
Sets the task to be run while the object is in the On state.
Definition ButtonToSwitch_ESP32.cpp:3085
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
See DbncdMPBttn::begin(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:3063
virtual ~SnglSrvcVdblMPBttn()
Class virtual destructor.
Definition ButtonToSwitch_ESP32.cpp:3059
SnglSrvcVdblMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:3047
Models a Toggle Latch DD-MPB, a.k.a. a Toggle Switch (ToLDD-MPB).
Definition ButtonToSwitch_ESP32.h:672
TgglLtchMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:1127
Models a Timer Latch DD-MPB, a.k.a. Timer Switch (TiLDD-MPB).
Definition ButtonToSwitch_ESP32.h:701
TmLtchMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:1169
const unsigned long int getSrvcTime() const
Returns the configured Service Time.
Definition ButtonToSwitch_ESP32.cpp:1192
void setTmerRstbl(const bool &newIsRstbl)
Configures the timer for the Service Time to be reseted before it reaches unlatching time.
Definition ButtonToSwitch_ESP32.cpp:1213
bool setSrvcTime(const unsigned long int &newSrvcTime)
Sets a new value to the Service Time attribute.
Definition ButtonToSwitch_ESP32.cpp:1197
void clrStatus(bool clrIsOn=true)
see DbncdMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:1181
Models a Time Voidable DD-MPB, a.k.a. Anti-tampering switch (TVDD-MPB)
Definition ButtonToSwitch_ESP32.h:1662
TmVdblMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:2939
virtual ~TmVdblMPBttn()
Class virtual destructor.
Definition ButtonToSwitch_ESP32.cpp:2948
void clrStatus()
See DbncdMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:2974
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
See DbncdMPBttn::begin(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:2952
const unsigned long int getVoidTime() const
Returns the voidTime attribute current value.
Definition ButtonToSwitch_ESP32.cpp:2985
bool setVoidTime(const unsigned long int &newVoidTime)
Sets a new value to the Void Time attribute.
Definition ButtonToSwitch_ESP32.cpp:2990
Abstract class, base to model Voidable DD-MPBs (VDD-MPB).
Definition ButtonToSwitch_ESP32.h:1502
bool setIsVoided()
Sets the value of the isVoided attribute flag to true.
Definition ButtonToSwitch_ESP32.cpp:2667
const bool getIsVoided() const
Returns the current value of the isVoided attribute flag.
Definition ButtonToSwitch_ESP32.cpp:2576
fncPtrType getFnWhnTrnOnVdd()
Returns the function that is set to execute every time the object enters the Voided or "Voided On" St...
Definition ButtonToSwitch_ESP32.cpp:2566
void clrStatus(bool clrIsOn=true)
See DbncdMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:2549
void setFnWhnTrnOnVddPtr(void(*newFnWhnTrnOn)())
Sets the function that will be called to execute every time the object's isVoided attribute flag is s...
Definition ButtonToSwitch_ESP32.cpp:2640
virtual ~VdblMPBttn()
Default virtual destructor.
Definition ButtonToSwitch_ESP32.cpp:2545
VdblMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:2535
fncPtrType getFnWhnTrnOffVdd()
Returns the function that is set to execute every time the object exits the Voided State.
Definition ButtonToSwitch_ESP32.cpp:2561
void setFnWhnTrnOffVddPtr(void(*newFnWhnTrnOff)())
Sets the function that will be called to execute every time the object's isVoided attribute flag is r...
Definition ButtonToSwitch_ESP32.cpp:2628
bool getFrcOtptLvlWhnVdd()
Returns the value of the frcOtptLvlWhnVdd attribute.
Definition ButtonToSwitch_ESP32.cpp:2571
bool getStOnWhnOtpFrcd()
Returns the value of the frcOtptLvlWhnVdd attribute.
Definition ButtonToSwitch_ESP32.cpp:2581
bool setIsNotVoided()
Sets the value of the isVoided attribute flag to false.
Definition ButtonToSwitch_ESP32.cpp:2662
Models an External Unlatch LDD-MPB, a.k.a. Emergency Latched Switch (XULDD-MPB)
Definition ButtonToSwitch_ESP32.h:953
void clrStatus(bool clrIsOn=true)
See DbncdMPBttn::clrStatus(bool)
Definition ButtonToSwitch_ESP32.cpp:1705
XtrnUnltchMPBttn()
Default constructor.
Definition ButtonToSwitch_ESP32.cpp:1661
virtual bool begin(const unsigned long int &pollDelayMs=_StdPollDelay)
See DbncdMPBttn::begin(const unsigned long int)
Definition ButtonToSwitch_ESP32.cpp:1677
Type to hold the complete set of output attribute flags from any DbncdMPBttn class and subclasses obj...
Definition ButtonToSwitch_ESP32.h:62