ArduinoBasicIO
1.0
Make basic operations with Arduino easier
|
#include <KnockSwitch.h>
Public Member Functions | |
void | init (uint8_t switchPin, bool switchOnLevel, uint8_t relayPin, bool relayOnLevel) |
bool | update () |
void | setOnKnocks (uint8_t knocks) |
void | setOffKnocks (uint8_t knocks) |
void | setKnocks (uint8_t knocks) |
void | setKnocks (uint8_t onKnocks, uint8_t offKnocks) |
bool | isOn () |
Additional Inherited Members | |
![]() | |
void | setExpectedPulses (uint8_t pulses) |
void | setDelays (unsigned int minDelay, unsigned int maxDelay) |
void | initDetector (uint8_t pulsePin, uint8_t pulseOnLevel) |
boolean | pulseTrainDetected () |
![]() | |
DigitalActuator () | |
DigitalActuator (uint8_t pin, uint8_t onLevel=true) | |
void | initActuator (uint8_t pin, uint8_t onLevel=true) |
virtual void | on () |
virtual void | off () |
virtual bool | isOn () |
virtual bool | isOff () |
Pulse train based switch.
|
inline |
Inits switch. Say pins and ON levels.
|
inline |
Check if it's on
|
inline |
Sets the the same number of knock to turn on/off.
|
inline |
Sets the the number of knock to turn on/off.
|
inline |
Sets the number of pulses to turn off the switch
|
inline |
Sets the number of pulses to turn on the switch
|
inline |
Upadates state.