X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibr2c2%2Fsensor.h;h=24f0fff401184c471186a33b146b5bdcce78897a;hb=3dd660ffad729fbd6e75e6401f5c7f27b9013faf;hp=849f899a9687d1be8d3e6a3f12992753917e8c08;hpb=59bae8acd679127602cf35d22bcd37e316a5a056;p=r2c2.git diff --git a/source/libr2c2/sensor.h b/source/libr2c2/sensor.h index 849f899..24f0fff 100644 --- a/source/libr2c2/sensor.h +++ b/source/libr2c2/sensor.h @@ -6,6 +6,7 @@ namespace R2C2 { +class Block; class Layout; class Sensor: public sigc::trackable @@ -24,6 +25,8 @@ public: protected: Layout &layout; unsigned address; + unsigned id; + bool invert; State state; Msp::Time::TimeDelta state_confirm_timeout; @@ -31,8 +34,10 @@ protected: public: virtual ~Sensor(); + virtual void set_address(unsigned); unsigned get_address() const { return address; } State get_state() const { return state; } + virtual Block *get_block() const { return 0; } void tick(const Msp::Time::TimeDelta &);