Moved temp sensor to seperate pin
Some checks failed
continuous-integration/drone/push Build is failing
continuous-integration/drone/pr Build is passing

This commit is contained in:
Jens True 2019-11-27 10:10:01 +01:00
parent e5a64c13ed
commit a8a5eb66a2

@ -6,6 +6,7 @@ const int TEMPERATURE_INTERVAL = 60;
unsigned long lastTemperatureSent = 0; unsigned long lastTemperatureSent = 0;
const int PIN_RELAY = D1; const int PIN_RELAY = D1;
const int PIN_DHT11 = D2;
#define OUTPUT_SET(x) digitalWrite(PIN_RELAY, x ? LOW : HIGH) #define OUTPUT_SET(x) digitalWrite(PIN_RELAY, x ? LOW : HIGH)
unsigned int timer = 0; unsigned int timer = 0;
unsigned int next_timer_update = 0; unsigned int next_timer_update = 0;
@ -50,7 +51,7 @@ void setupHandler() {
powerNode.setProperty("timer").send("0"); powerNode.setProperty("timer").send("0");
dht.setup(D1, DHTesp::DHT11); // Connect DHT sensor to GPIO 17 dht.setup(PIN_DHT11, DHTesp::DHT11); // Connect DHT sensor to GPIO 17
} }
void loopHandler() { void loopHandler() {