|
@ -36,11 +36,7 @@ class AhoyWifiAp { |
|
|
|
|
|
|
|
|
ah::welcome(mIp.toString(), String(F("Password: ") + String(mCfg->apPwd))); |
|
|
ah::welcome(mIp.toString(), String(F("Password: ") + String(mCfg->apPwd))); |
|
|
|
|
|
|
|
|
#if defined(ETHERNET) |
|
|
|
|
|
WiFi.mode(WIFI_AP); |
|
|
|
|
|
#else |
|
|
|
|
|
WiFi.mode(WIFI_AP_STA); |
|
|
WiFi.mode(WIFI_AP_STA); |
|
|
#endif |
|
|
|
|
|
WiFi.softAPConfig(mIp, mIp, IPAddress(255, 255, 255, 0)); |
|
|
WiFi.softAPConfig(mIp, mIp, IPAddress(255, 255, 255, 0)); |
|
|
WiFi.softAP(WIFI_AP_SSID, mCfg->apPwd); |
|
|
WiFi.softAP(WIFI_AP_SSID, mCfg->apPwd); |
|
|
|
|
|
|
|
@ -60,12 +56,7 @@ class AhoyWifiAp { |
|
|
|
|
|
|
|
|
mDns.stop(); |
|
|
mDns.stop(); |
|
|
WiFi.softAPdisconnect(); |
|
|
WiFi.softAPdisconnect(); |
|
|
#if defined(ETHERNET) |
|
|
|
|
|
WiFi.mode(WIFI_OFF); |
|
|
|
|
|
#else |
|
|
|
|
|
WiFi.scanDelete(); |
|
|
|
|
|
WiFi.mode(WIFI_STA); |
|
|
WiFi.mode(WIFI_STA); |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
mEnabled = false; |
|
|
mEnabled = false; |
|
|
} |
|
|
} |
|
|