 
 class SystemState : public CrcableData {
 public:
+  float displayedInternalTemperature = -100;
+  float displayedInternalHumidity = -100;
   bool externalDataValid = false;
   float lastExternalTemperature = 0;
   float lastExternalHumidity = 0;

void updateDisplay(TH *local, TH *external)
{
  unsigned long totalOnMillis = systemState.accumulatedSystemMillis + (millis() - systemStart);
  display.displayValues(local, 1, totalOnMillis);
  display.displayValues(external, 2, totalOnMillis - systemState.lastExternalValuesMillis);

  // TODO consider age of shown data vs tempUpdateThreshold

  display.updatePartOrFull();

  bool shouldSleepNow = millis() - systemStart > systemAwakeSeconds * 1000;

  if (shouldSleepNow && !displayUpdated) {
    boolean internalIsToBeShown = systemState.displayedInternalTemperature == -100;

    if (!internalIsToBeShown) {
      TH lastInternalData;
      lastInternalData.temperature = systemState.displayedInternalTemperature;
      lastInternalData.humidity = systemState.displayedInternalHumidity;
      updateVaporPressure(&lastInternalData);

      if (abs(systemState.displayedInternalTemperature - localData.temperature) > 0.2
          || abs(lastInternalData.vaporPressure - localData.vaporPressure) > 0.29) {
          internalIsToBeShown = true;

          Serial.print("Updating because of difference ");
          Serial.println(abs(systemState.displayedInternalTemperature - localData.temperature));
      } else {
        Serial.println("No update. No external data and no internal change.");
        // NOTE the "update at least every X tries" is handled indirectly by the external source
      }
    }

    if (internalIsToBeShown) {
      if (systemState.externalDataValid) {
        externalData.dataValid = true;
        externalData.temperature = systemState.lastExternalTemperature;
        externalData.humidity = systemState.lastExternalHumidity;
        updateVaporPressure(&externalData);
      }
      
      updateDisplay(&localData, &externalData);
    }
  }

  unsigned long loopEnd = millis();
