     Serial.println();
   #endif
 
-  if (cabinsTotal == cabinsTotalClosed) {
-    ALL_DOORS_CLOSED = true;
-  } else {
-    ALL_DOORS_CLOSED = false;
-  }
-
-  display.clearDisplay();
-  display.setCursor(0, 0);
-  display.print("Pukpukus\n");
-  display.printf("\nC1: %s %d", (CABIN_1_CLOSED) ? "CL" : "OP", CABIN_1_CLOSED_COUNTER);
-  display.printf("\nC2: %s %d", (CABIN_2_CLOSED) ? "CL" : "OP", CABIN_2_CLOSED_COUNTER);
-  if (ALL_DOORS_CLOSED) {
-    display.printf("\n\n%d occupied", cabinsTotalClosed);
-  } else {
-    display.printf("\n\n%d free", cabinsTotal - cabinsTotalClosed);
-  }
-  display.display();
-
-  if (ALL_DOORS_CLOSED) {
-    response = "occupied";
-    matrixSetColor(LED_RED);
-  } else {
-    response = "free";
-    matrixSetColor(LED_GREEN);
-  }
-
-  server.send(200, "text/plain", response);
+  switch (CABIN_TOTAL_COUNT - cabinsTotalClosed) {
+    case 0: // all closed
+      CURRENT_MATRIX_COLOR = LED_RED;
+      matrixSetColor(CURRENT_MATRIX_COLOR);
+      break;
+
+    case 1: // one opened
+      CURRENT_MATRIX_COLOR = LED_YELLOW;
+      matrixSetColor(CURRENT_MATRIX_COLOR);
+      break;
+
+    default: // otherwise
+      CURRENT_MATRIX_COLOR = LED_GREEN;
+      matrixSetColor(CURRENT_MATRIX_COLOR);
+      break;
+  }
 
   timerMatrix.enable(timerMatrixId);
   matrixLedOffXIndex = 0;
   matrixLedOffYIndex = 0;
-
-  // matrixLedLocations = {
-  //   11, 12, 13, 14, 15, 16, 17, 18,
-  //   21, 22, 23, 24, 25, 26, 27, 28,
-  //   31, 32, 33, 34, 35, 36, 37, 38,
-  //   41, 42, 43, 44, 45, 46, 47, 48,
-  //   51, 52, 53, 54, 55, 56, 57, 58,
-  //   61, 62, 63, 64, 65, 66, 67, 68,
-  //   71, 72, 73, 74, 75, 76, 77, 78,
-  //   81, 82, 83, 84, 85, 86, 87, 88
-  // };
-  // matrixLedLocationsCurrentIndex = 0;
-  // matrixLedLocations = shuffleArray(matrixLedLocations, sizeof(matrixLedLocations));
-}
-
-void handleStatus() {
-  #ifdef SERIAL_VERBOSE
-    Serial.println("handleStatus");
-  #endif
-
-  String response = (ALL_DOORS_CLOSED) ? "occupied" : "free";
+}
+
+void handleDefault() {
+  #ifdef SERIAL_VERBOSE
+    Serial.println("handleDefault");
+  #endif
+
+  String response;
   char buffer[16];
   sprintf(buffer, "\nC1: %s %d", (CABIN_1_CLOSED) ? "CL" : "OP", CABIN_1_CLOSED_COUNTER);
   response+= buffer;

    Serial.println();
  #endif

  display.print("setup done");
  display.display();
  delay(2000);
}

void setupServerHandlers() {
  server.on("/",        handleStatus);
  server.on("/devices", handleDevices);
  server.on("/update",  handleUpdate);
  server.onNotFound(handleNotFound);
}

void setupDisplay() {
  display.begin(SSD1306_SWITCHCAPVCC, 0x3C); // 0x3C or 0x3D
  display.clearDisplay();
  display.display();
}

void setupMatrix() {
   matrix.begin(0x70); // 0x70 - 0x77
   matrix.setBrightness(12); // 0 - 15, with 1 too much high freq noice from holtek
}

void matrixSelfTest() {
  matrix.clear();
  matrix.fillRect(0, 0, 8, 8, LED_GREEN);
  matrix.writeDisplay();
  delay(500);
  matrix.fillRect(0, 0, 8, 8, LED_YELLOW);
  matrix.writeDisplay();
  delay(500);
  matrix.fillRect(0, 0, 8, 8, LED_RED);
  matrix.writeDisplay();
  delay(500);
  matrix.fillRect(0, 0, 8, 8, 0);
  matrix.writeDisplay();
}

  #endif

  #ifdef SERIAL_VERBOSE
    Serial.println("Connecting to WIFI...");
  #endif

  /* Explicitly set the ESP8266 to be a WiFi-client, otherwise, it by default,
     would try to act as both a client and an access-point and could cause
     network-issues with your other WiFi-devices on your WiFi-network. */
  WiFi.disconnect();
  WiFi.setAutoConnect(true);
  WiFi.mode(WIFI_STA);
  WiFi.config(staticIp, defaultGateway, netmask);
  WiFi.begin(WLAN_SSID, WLAN_PWD);

  // IPAddress myIP = WiFi.softAPIP();
  #ifdef SERIAL_VERBOSE
