Mario Simaremare
/
g3_waterplay
Salinity and temperature sensors are implemented in classes.
Thermostat.h
- Committer:
- mariosimaremare
- Date:
- 2016-06-22
- Revision:
- 12:7a48b90b493e
- Parent:
- 5:4cbe44452889
File content as of revision 12:7a48b90b493e:
/* * G3: WATERPLAY */ #ifndef THERMOSTAT_H #define THERMOSTAT_H #include "Printer.h" #include "mbed.h" class Thermostat { public: Thermostat( Printer &printer, PinName pin, PinName led_pin ); static const int STATUS_ON = 1; static const int STATUS_OFF = 0; int on(); int off(); int react(double temperature); char* getStrStatus(); private: Printer &_printer; DigitalOut _analog_out; DigitalOut _led; int _status; char* _strStatus; int update(); }; #endif