   tft.println(cfg.dim);
 
   WiFi.mode(WIFI_STA);
+  WiFi.hostname(cfg.hostname);
   WiFi.begin(cfg.ssid, cfg.password);
   while (WiFi.status() != WL_CONNECTED) {
     delay(500);

  tft.println();
  tft.println(WiFi.localIP());

  if (mdns.begin(cfg.hostname, WiFi.localIP()))
    out.println("MDNS started");
  
  ArduinoOTA.setHostname(cfg.hostname);
  ArduinoOTA.onStart([]() {


  ArduinoOTA.handle();
  server.handleClient();
  mdns.update();

  uint32_t now = millis();
  bool swtch = !digitalRead(SWITCH);
