   if (hm.state.UpdateUtc != 0)
   {
     struct tm* ltime;
-    ltime = localtime(&hm.state.UpdateUtc);
+    // time_t is defined as "long" on ESP32 and our time is signed 32-bit UNIX epoch
+    const time_t utime = hm.state.UpdateUtc;
+    ltime = localtime(&utime);
     bool pm = ltime->tm_hour > 11;
     if (ltime->tm_hour > 12)
       ltime->tm_hour -= 12;


static void proxy_onWifiConnect()
{
  Serial.println(F("onWifiConnect"));
}

static void proxy_onWifiDisconnect()

  drawOutput(); yield();
  drawTime(); yield();

  Serial.print(F("updateDisplay "));
  Serial.print(millis() - start, DEC);
  Serial.println(F("ms"));
}

static void drawBackground()
