From 258fb327226bfb2ccfc85c02ea2767de53991d86 Mon Sep 17 00:00:00 2001 From: Hieromon Ikasamo Date: Fri, 21 Dec 2018 19:26:51 +0900 Subject: [PATCH] Supports AutoConnectAux --- src/AutoConnect.cpp | 1 - src/AutoConnect.h | 1 + src/AutoConnectAux.cpp | 97 ++++++++++++++++++++++++++++++++++++++--- src/AutoConnectAux.h | 3 ++ src/AutoConnectPage.cpp | 2 + 5 files changed, 96 insertions(+), 8 deletions(-) diff --git a/src/AutoConnect.cpp b/src/AutoConnect.cpp index e65b850..ff597b2 100644 --- a/src/AutoConnect.cpp +++ b/src/AutoConnect.cpp @@ -602,7 +602,6 @@ String AutoConnect::_induceConnect(PageArgument& args) { // Read from EEPROM AutoConnectCredential credential(_apConfig.boundaryOffset); struct station_config entry; -// AC_DBG("Load credential:%s\n", args.arg(AUTOCONNECT_PARAMID_CRED).c_str()); credential.load(args.arg(AUTOCONNECT_PARAMID_CRED).c_str(), &entry); strncpy(reinterpret_cast(_credential.ssid), reinterpret_cast(entry.ssid), sizeof(_credential.ssid)); strncpy(reinterpret_cast(_credential.password), reinterpret_cast(entry.password), sizeof(_credential.password)); diff --git a/src/AutoConnect.h b/src/AutoConnect.h index f6b568b..2e66135 100644 --- a/src/AutoConnect.h +++ b/src/AutoConnect.h @@ -231,6 +231,7 @@ class AutoConnect { /** Extended pages made up with AutoConnectAux */ std::unique_ptr _aux; + String _auxLastUri; /** Saved configurations */ AutoConnectConfig _apConfig; diff --git a/src/AutoConnectAux.cpp b/src/AutoConnectAux.cpp index 96ca874..ba35df0 100644 --- a/src/AutoConnectAux.cpp +++ b/src/AutoConnectAux.cpp @@ -51,6 +51,11 @@ const char AutoConnectAux::_PAGE_AUX[] PROGMEM = { "" "