report interval
This commit is contained in:
parent
9bc3fc5910
commit
fa53ddbc0f
|
@ -10,6 +10,7 @@
|
||||||
* Pin Definitions *
|
* Pin Definitions *
|
||||||
***********************************************/
|
***********************************************/
|
||||||
#define TEMP_SENSOR_PIN 32
|
#define TEMP_SENSOR_PIN 32
|
||||||
|
#define TEMP_REPORT_INTERVAL_MS 5000
|
||||||
|
|
||||||
/***********************************************
|
/***********************************************
|
||||||
* Display Configuration *
|
* Display Configuration *
|
||||||
|
|
|
@ -67,7 +67,7 @@ void setup()
|
||||||
void loop()
|
void loop()
|
||||||
{
|
{
|
||||||
static uint32_t lastTempUpdate = 0;
|
static uint32_t lastTempUpdate = 0;
|
||||||
if (millis() - lastTempUpdate > 5000)
|
if (millis() - lastTempUpdate > TEMP_REPORT_INTERVAL_MS)
|
||||||
{
|
{
|
||||||
if(dht.read() != DHTLIB_OK)
|
if(dht.read() != DHTLIB_OK)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue