mirror of
https://github.com/dalathegreat/Battery-Emulator.git
synced 2025-10-03 17:59:27 +02:00
Remove old method to disable webserver to save flash
This commit is contained in:
parent
e11843e4a0
commit
79964a0601
3 changed files with 5 additions and 16 deletions
|
@ -86,9 +86,7 @@ void connectivity_loop(void*) {
|
|||
// Init wifi
|
||||
init_WiFi();
|
||||
|
||||
if (webserver_enabled) {
|
||||
init_webserver();
|
||||
}
|
||||
|
||||
if (mdns_enabled) {
|
||||
init_mDNS();
|
||||
|
@ -98,9 +96,7 @@ void connectivity_loop(void*) {
|
|||
START_TIME_MEASUREMENT(wifi);
|
||||
wifi_monitor();
|
||||
|
||||
if (webserver_enabled) {
|
||||
ota_monitor();
|
||||
}
|
||||
|
||||
END_TIME_MEASUREMENT_MAX(wifi, datalayer.system.status.wifi_task_10s_max_us);
|
||||
|
||||
|
@ -388,11 +384,9 @@ void core_loop(void*) {
|
|||
|
||||
END_TIME_MEASUREMENT_MAX(comm, datalayer.system.status.time_comm_us);
|
||||
|
||||
if (webserver_enabled) {
|
||||
START_TIME_MEASUREMENT(ota);
|
||||
ElegantOTA.loop();
|
||||
END_TIME_MEASUREMENT_MAX(ota, datalayer.system.status.time_ota_us);
|
||||
}
|
||||
|
||||
// Process
|
||||
currentMillis = millis();
|
||||
|
|
|
@ -23,9 +23,6 @@
|
|||
extern std::string http_username;
|
||||
extern std::string http_password;
|
||||
|
||||
bool webserver_enabled =
|
||||
true; // Global flag to enable or disable the webserver //Old method to disable was with #ifdef WEBSERVER
|
||||
|
||||
bool webserver_auth = false;
|
||||
|
||||
// Create AsyncWebServer object on port 80
|
||||
|
|
|
@ -7,8 +7,6 @@
|
|||
#include "../../lib/ayushsharma82-ElegantOTA/src/ElegantOTA.h"
|
||||
#include "../../lib/mathieucarbou-AsyncTCPSock/src/AsyncTCP.h"
|
||||
|
||||
extern bool webserver_enabled;
|
||||
|
||||
extern const char* version_number; // The current software version, shown on webserver
|
||||
|
||||
// Common charger parameters
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue