Library for my home monitoring classes and serial communication protocol. It monitors temperature and movement on the mbed application board.
Temperature/Temperature.h
- Committer:
- groletter
- Date:
- 2013-09-01
- Revision:
- 0:3f846fc933a2
- Child:
- 2:84432add9142
File content as of revision 0:3f846fc933a2:
#ifndef TEMPERATURE_H #define TEMPERATURE_H #include <vector> #include <string> class Temperature { private: double max_temp_limit, min_temp_limit, period_limit, max_samples_limit; double min_temp; double max_temp; double temp_sample_period; int max_samples; int sample_ptr; bool wrapped_once; std::vector<std::string> temp_samples; public: Temperature(); double get_min(); double get_max(); double get_period(); bool set_min(double); bool set_max(double); bool set_period(double); void add_sample(double temp_sample); bool change_max_samples(int); int get_max_samples(); const std::vector<std::string> &get_samples(); }; #endif