From 33a33162f58b8a7e7a2f83d4990180eef33f0793 Mon Sep 17 00:00:00 2001 From: richonguzman Date: Tue, 19 Dec 2023 00:29:32 -0300 Subject: [PATCH] new ota test1 --- platformio.ini | 8 ++++---- src/LoRa_APRS_iGate.cpp | 2 ++ src/utils.cpp | 6 +++--- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/platformio.ini b/platformio.ini index 3459e96..4fb1dea 100644 --- a/platformio.ini +++ b/platformio.ini @@ -20,7 +20,7 @@ lib_deps = sandeepmistry/LoRa@^0.8.0 adafruit/Adafruit GFX Library @ 1.11.5 adafruit/Adafruit SSD1306 @ 2.5.7 - ayushsharma82/AsyncElegantOTA@^2.2.7 + ayushsharma82/ElegantOTA@^3.1.0 ottowinter/ESPAsyncWebServer-esphome@^3.0.0 esphome/AsyncTCP-esphome@^2.0.0 mikalhart/TinyGPSPlus @ 1.0.3 @@ -30,13 +30,13 @@ lib_deps = [env:ttgo-lora32-v21] board = ttgo-lora32-v21 -build_flags = -Werror -Wall -DTTGO_T_LORA_V2_1 +build_flags = -Werror -Wall -DTTGO_T_LORA_V2_1 -DELEGANTOTA_USE_ASYNC_WEBSERVER=1 [env:heltec-lora32-v2] board = ttgo-lora32-v21 -build_flags = -Werror -Wall -DHELTEC_V2 +build_flags = -Werror -Wall -DHELTEC_V2 -DELEGANTOTA_USE_ASYNC_WEBSERVER=1 [env:heltec_wifi_kit_32_V3] board = heltec_wifi_kit_32_V3 -build_flags = -Werror -Wall -DHELTEC_V3 +build_flags = -Werror -Wall -DHELTEC_V3 -DELEGANTOTA_USE_ASYNC_WEBSERVER=1 board_build.mcu = esp32s3 \ No newline at end of file diff --git a/src/LoRa_APRS_iGate.cpp b/src/LoRa_APRS_iGate.cpp index 6a420de..74a9927 100644 --- a/src/LoRa_APRS_iGate.cpp +++ b/src/LoRa_APRS_iGate.cpp @@ -1,3 +1,4 @@ +#include #include #include #include @@ -89,4 +90,5 @@ void loop() { DIGI_Utils::loop(); } } + ElegantOTA.loop(); } \ No newline at end of file diff --git a/src/utils.cpp b/src/utils.cpp index 410da5b..83bb7b2 100644 --- a/src/utils.cpp +++ b/src/utils.cpp @@ -1,5 +1,5 @@ #include -#include +#include #include #include #include @@ -328,9 +328,9 @@ namespace Utils { }); if (Config.ota.username != "" && Config.ota.password != "") { - AsyncElegantOTA.begin(&server, Config.ota.username.c_str(), Config.ota.password.c_str()); + ElegantOTA.begin(&server, Config.ota.username.c_str(), Config.ota.password.c_str()); } else { - AsyncElegantOTA.begin(&server); + ElegantOTA.begin(&server); } server.on("/process_form.php", HTTP_POST, [](AsyncWebServerRequest *request){