Merge branch 'master' into MQTT-Testament-Messages
This commit is contained in:
commit
66953310ad
|
|
@ -15,6 +15,6 @@
|
||||||
#define WATCHDOG_SLEEP_FURTHER 8
|
#define WATCHDOG_SLEEP_FURTHER 8
|
||||||
|
|
||||||
// define wether to use a DHT-Sensor or not
|
// define wether to use a DHT-Sensor or not
|
||||||
bool USE_DHT_SENSOR = true;
|
#define USE_DHT_SENSOR true
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -68,7 +68,7 @@ void setup()
|
||||||
pinMode(SOIL_PIN, INPUT);
|
pinMode(SOIL_PIN, INPUT);
|
||||||
|
|
||||||
// init the DHT22
|
// init the DHT22
|
||||||
if (USE_DHT_SENSOR == 1)
|
if (USE_DHT_SENSOR)
|
||||||
{
|
{
|
||||||
dht_init(&dht, DHT_PIN);
|
dht_init(&dht, DHT_PIN);
|
||||||
}
|
}
|
||||||
|
|
@ -115,7 +115,7 @@ void loop()
|
||||||
memcpy(&rh_buf[1], &battery, 4);
|
memcpy(&rh_buf[1], &battery, 4);
|
||||||
rh_send(rh_buf,RH_BUF_LEN);
|
rh_send(rh_buf,RH_BUF_LEN);
|
||||||
}
|
}
|
||||||
else if (USE_DHT_SENSOR == 1)
|
else if (USE_DHT_SENSOR)
|
||||||
{
|
{
|
||||||
if (dht_read_data(&dht, &t, &h) == 1)
|
if (dht_read_data(&dht, &t, &h) == 1)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue