     }
 }
 
+void doReportIfTime() {
+    static unsigned long lastReportMillis = 0;
+    unsigned long now = millis();
+
+    if ((now - lastReportMillis) >= SENSOR_REPORT_MS) {
+        Serial.println("Reporting sensor data to server");
+        
+        // TODO: implement
+        
+        lastReportMillis = now;
+    }
+}
+
 void setup() {
     Serial.begin(9600);
 


#include "Adafruit_DHT/Adafruit_DHT.h"

#define DHT_PIN         D2
#define DHT_TYPE        DHT22

#define BUTTON_PIN      D1
#define BUTTON_PRESS_MS 50

#define LED_PIN         D7

unsigned long reportIntervalMillis = 2000;
bool isReporting = true;

volatile unsigned long buttonPressMillis = 0;
volatile unsigned long buttonReleaseMillis = 0;


    }
}

void doMonitorIfTime() {
    static unsigned long lastReadingMillis = 0;
    unsigned long now = millis();

    if ((now - lastReadingMillis) >= SENSOR_CHECK_MS) {
        float h = dht.getHumidity();
        float f = dht.getTempFarenheit();

