RCKit
|
Setter class that sets its value to an analog output pin. More...
#include <DigitalSetter.h>
Public Member Functions | |
DigitalSetter (uint8_t pin) | |
void | setPin (uint8_t pin) |
virtual void | input (int value) |
virtual void | failsafe () |
Called when the source of input data is lost, and the Setter is required to fail in a safe way. | |
Public Member Functions inherited from Setter | |
Setter () | |
Constructor. More... | |
Setter (Setter *target) | |
Constructor with setting the target. | |
virtual void | setTarget (Setter *target) |
void | setFailsafeValue (int failsafeValue) |
Sets the failsafeValue. | |
int | failsafeValue () |
Additional Inherited Members | |
Protected Attributes inherited from Setter | |
Setter * | _target |
This is the instance of Setter that will be given the transfotmed output value. | |
int | _failsafeValue |
Setter class that sets its value to an analog output pin.
DigitalSetter::DigitalSetter | ( | uint8_t | pin | ) |
[in] | pin | The pin number of the digital output to set Caller is expected to have set it as an output already |
References setPin().
|
virtual |
Input the value to be used to set the analog output Digital outputs are 0 or 1 Inout 0 produces digital output of 0. All other values produce output of 1
[in] | value | The input 0 for off, all other values for on |
Reimplemented from Setter.
Referenced by failsafe().
void DigitalSetter::setPin | ( | uint8_t | pin | ) |
Set or change the output pin
[in] | pin | The Arduino pin to use for output |
Referenced by DigitalSetter().