mirror of
https://github.com/justcallmekoko/ESP32Marauder.git
synced 2025-12-12 07:40:58 -08:00
Ensure async wardrive
This commit is contained in:
@@ -2499,6 +2499,7 @@ void WiFiScan::StopScan(uint8_t scan_mode)
|
||||
#endif
|
||||
|
||||
this->shutdownBLE();
|
||||
this->ble_scanning = false;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -4426,7 +4427,12 @@ void WiFiScan::executeWarDrive() {
|
||||
return;
|
||||
}
|
||||
else if (scan_status == WIFI_SCAN_FAILED) {
|
||||
Serial.println("WiFi scan failed to start");
|
||||
Serial.println("WiFi scan failed to start. Restarting...");
|
||||
this->wifi_initialized = true;
|
||||
this->shutdownWiFi();
|
||||
this->startWardriverWiFi();
|
||||
this->wifi_initialized = true;
|
||||
delay(100);
|
||||
}
|
||||
|
||||
/*#ifndef HAS_DUAL_BAND
|
||||
@@ -4507,15 +4513,15 @@ void WiFiScan::executeWarDrive() {
|
||||
buffer_obj.append(wardrive_line);
|
||||
}
|
||||
}
|
||||
|
||||
// Free up that memory, you sexy devil
|
||||
WiFi.scanDelete();
|
||||
}
|
||||
|
||||
/*#ifndef HAS_DUAL_BAND
|
||||
this->channelHop();
|
||||
#endif*/
|
||||
|
||||
// Free up that memory, you sexy devil
|
||||
WiFi.scanDelete();
|
||||
|
||||
if (!this->ble_scanning)
|
||||
WiFi.scanNetworks(true, true, false, 80);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user