Domotique/WifiControlSensor/GPIOSensor.h
2016-11-20 23:58:45 +01:00

18 lines
333 B
C++

#pragma once
#include "Arduino.h"
class GPIOSensor{
public:
char *sensorName;
char *measureName;
uint8_t gpio;
bool isAnalog;
int8_t powerGpio;
int lastMeasure;
GPIOSensor(char *sensorName, char *measureName, uint8_t gpio, bool isAnalog=false, int8_t powerGpio = -1);
int getMeasure(int &level);
int getLastMeasure();
};