File tree 2 files changed +8
-1
lines changed
2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -654,13 +654,15 @@ uint8_t WiFiManager::connectWifi(String ssid, String pass) {
654
654
655
655
DEBUG_WM (DEBUG_VERBOSE,F (" Connection result:" ),getWLStatusString (connRes));
656
656
657
+ #ifdef NO_EXTRA_4K_HEAP
657
658
// do WPS, if WPS options enabled and not connected and no password was supplied
658
659
// @todo this seems like wrong place for this, is it a fallback or option?
659
660
if (_tryWPS && connRes != WL_CONNECTED && pass == " " ) {
660
661
startWPS ();
661
662
// should be connected at the end of WPS
662
663
connRes = waitForConnectResult ();
663
664
}
665
+ #endif
664
666
665
667
if (connRes != WL_SCAN_COMPLETED){
666
668
updateConxResult (connRes);
@@ -782,6 +784,7 @@ uint8_t WiFiManager::waitForConnectResult(uint16_t timeout) {
782
784
return status;
783
785
}
784
786
787
+ #ifdef NO_EXTRA_4K_HEAP
785
788
void WiFiManager::startWPS () {
786
789
DEBUG_WM (F (" START WPS" ));
787
790
#ifdef ESP8266
@@ -791,7 +794,7 @@ void WiFiManager::startWPS() {
791
794
#endif
792
795
DEBUG_WM (F (" END WPS" ));
793
796
}
794
-
797
+ # endif
795
798
796
799
String WiFiManager::getHTTPHead (String title){
797
800
String page;
Original file line number Diff line number Diff line change @@ -290,7 +290,9 @@ class WiFiManager
290
290
int _staShowDns = 0 ; // ternary always show dns, only if not set in code, never(cannot change dns via web!)
291
291
boolean _removeDuplicateAPs = true ; // remove dup aps from wifiscan
292
292
boolean _shouldBreakAfterConfig = false ; // stop configportal on save failure
293
+ #ifdef NO_EXTRA_4K_HEAP
293
294
boolean _tryWPS = false ; // try WPS on save failure, unsupported
295
+ #endif
294
296
boolean _configPortalIsBlocking = true ; // configportal enters blocking loop
295
297
boolean _enableCaptivePortal = true ; // enable captive portal redirection
296
298
boolean _userpersistent = true ; // users preffered persistence to restore
@@ -316,7 +318,9 @@ class WiFiManager
316
318
void _end ();
317
319
318
320
void setupConfigPortal ();
321
+ #ifdef NO_EXTRA_4K_HEAP
319
322
void startWPS ();
323
+ #endif
320
324
bool startAP ();
321
325
322
326
uint8_t connectWifi (String ssid, String pass);
You can’t perform that action at this time.
0 commit comments