1 #ifndef LIBR2C2_SENSOR_H_
2 #define LIBR2C2_SENSOR_H_
4 #include <sigc++/signal.h>
5 #include <msp/time/timedelta.h>
12 class Sensor: public sigc::trackable
23 sigc::signal<void, State> signal_state_changed;
29 Msp::Time::TimeDelta state_confirm_timeout;
35 unsigned get_address() const { return address; }
36 State get_state() const { return state; }
37 virtual Block *get_block() const { return 0; }
39 void tick(const Msp::Time::TimeDelta &);
42 void event(unsigned, bool);