瀏覽代碼

add hostname

Anton Van Gorp 10 月之前
父節點
當前提交
051f1ef7fa
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/powerbox.cpp

+ 2 - 0
src/powerbox.cpp

@@ -384,7 +384,9 @@ void setupWifi()
   WiFi.softAPConfig(wifiConfig.getSoftAPIPAddress(), wifiConfig.getSoftAPGateway(), wifiConfig.getSoftAPSubnet());
   WiFi.softAP(wifiConfig.getSoftAPSsid().c_str(), wifiConfig.getSoftAPPassword().c_str());
 
+
   // Connect to WiFi
+  WiFi.hostname("avg_powerbox");
   WiFi.begin(wifiConfig.getWifiNetworkSsid().c_str(), wifiConfig.getWifiNetworkPassword().c_str());
 
   if (WiFi.waitForConnectResult() != WL_CONNECTED)