semf
digitalin.h
Go to the documentation of this file.
1
10#ifndef SEMF_APP_INPUT_DIGITALIN_DIGITALIN_H_
11#define SEMF_APP_INPUT_DIGITALIN_DIGITALIN_H_
12
14
15namespace semf
16{
17namespace app
18{
35{
36public:
38 enum State : bool
39 {
40 Low = false,
41 High = true
42 };
43
44 virtual ~DigitalIn() = default;
45
50 virtual bool isInverted() const = 0;
55 virtual void setInverted(bool inverted) = 0;
61 virtual State state() const = 0;
62
67};
68} /* namespace app */
69} /* namespace semf */
70#endif /* SEMF_APP_INPUT_DIGITALIN_DIGITALIN_H_ */
Signal for lightweight signal/slot implementation. One signal can be connected to multiple slots and ...
Definition: signal.h:41
Interfaces for having access to the level state of a digital input.
Definition: digitalin.h:35
virtual void setInverted(bool inverted)=0
Configures the inversion of the input reading.
virtual State state() const =0
Returns the level status of the hardware pin.
virtual bool isInverted() const =0
Returns of the pin level logic is inverted.
virtual ~DigitalIn()=default