mirror of
https://github.com/dalathegreat/Battery-Emulator.git
synced 2025-10-03 17:59:27 +02:00
Restored functinality to disable WIFI AP mode with at runtime with a setting.
Restored ifdefs for double battery and charger.
This commit is contained in:
parent
ce93284b51
commit
573658e573
4 changed files with 14 additions and 20 deletions
|
@ -38,11 +38,15 @@ unsigned long last_wifi_attempt_time = millis(); //init millis so wifi monitor
|
|||
void init_webserver() {
|
||||
// Configure WiFi
|
||||
#ifdef WIFIAP
|
||||
WiFi.mode(WIFI_AP_STA); // Simultaneous WiFi AP and Router connection
|
||||
init_WiFi_AP();
|
||||
if (AccessPointEnabled) {
|
||||
WiFi.mode(WIFI_AP_STA); // Simultaneous WiFi AP and Router connection
|
||||
init_WiFi_AP();
|
||||
} else {
|
||||
WiFi.mode(WIFI_STA); // Only Router connection
|
||||
}
|
||||
#else
|
||||
WiFi.mode(WIFI_STA); // Only Router connection
|
||||
#endif
|
||||
#endif // WIFIAP
|
||||
init_WiFi_STA(ssid.c_str(), password.c_str(), wifi_channel);
|
||||
|
||||
String content = index_html;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue