43#include <ESPAsyncWebServer.h>
46#include <Preferences.h>
118 AsyncWebServer server;
120 Preferences preferences;
132 class CaptiveRequestHandler :
public AsyncWebHandler {
139 CaptiveRequestHandler(
const char* html);
147 bool canHandle(AsyncWebServerRequest *request)
override;
154 void handleRequest(AsyncWebServerRequest *request)
override;
157 const char* index_html;
176 static const char* index_html;
177 static const char* success_html;
178 static const char* error_html;
Manages dynamic WiFi configuration through a captive portal.
Definition dynaconfig.h:62
String getConfigSSID()
Retrieves the stored WiFi SSID from Preferences.
Definition dynaconfig.cpp:54
void close()
Closes the Preferences storage.
Definition dynaconfig.cpp:41
bool removeCredentials()
Removes stored WiFi credentials from Preferences.
Definition dynaconfig.cpp:50
String getConfigPasskey()
Retrieves the stored WiFi password from Preferences.
Definition dynaconfig.cpp:58
void checkWiFiConfig()
Checks and manages the WiFi configuration.
Definition dynaconfig.cpp:24
bool hasCredentials()
Checks if WiFi credentials are stored in Preferences.
Definition dynaconfig.cpp:45