Data Gator
Hardware and software documentation for the Data Gator project.
Loading...
Searching...
No Matches
BLESensor.hpp
Go to the documentation of this file.
1
14#ifndef BLESENSOR_H
15#define BLESENSOR_H
16
20class BLESensor {
21public:
22 std::string name;
23 std::string mac_address;
24
33 virtual std::string toJSON(double temp, double humidity) = 0;
34
40 virtual std::string getSensorType() = 0;
41};
42
43#endif
Defines a bluetooth low energy (BLE) interface for integrating new sensors into the DG firmware.
Definition BLESensor.hpp:20
std::string name
Name of the sensor... not unique, generally something generic such as brand and model.
Definition BLESensor.hpp:22
virtual std::string toJSON(double temp, double humidity)=0
convert data values to JSON string object
std::string mac_address
Mac address of sensor BLE for unique ID.
Definition BLESensor.hpp:23
virtual std::string getSensorType()=0
get the sensor type as a string