Added /reset_wlan REST webservice command.
This commit is contained in:
parent
c1c82222b5
commit
608057b098
1 changed files with 8 additions and 0 deletions
|
@ -217,6 +217,14 @@ void setup() {
|
||||||
ESP.restart();
|
ESP.restart();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
server.on("/reset_wlan", []() {
|
||||||
|
DBG_OUTPUT_PORT.printf("/reset_wlan:\n");
|
||||||
|
server.send(200, "text/plain", "Resetting WLAN and restarting..." );
|
||||||
|
WiFiManager wifiManager;
|
||||||
|
wifiManager.resetSettings();
|
||||||
|
ESP.restart();
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
// ***************************************************************************
|
// ***************************************************************************
|
||||||
// Setup: SPIFFS Webserver handler
|
// Setup: SPIFFS Webserver handler
|
||||||
|
|
Loading…
Reference in a new issue