refactor(ota): implement polling-based update system and fix API typo
Test project compilation / test (push) Successful in 3m52s

- Fix typo in OTA update status API endpoint (/ota_udpate_status → /ota_update_status)
- Replace WebSocket-based update progress with polling mechanism
- Add OTA lifecycle callbacks (started, finished, progress, error)
- Implement check_update_task with internet connectivity verification
- Add LittleFS/SPIFFS update support
- Simplify update progress page to use 90-second delay and polling instead of real-time WebSocket updates

This refactor improves reliability by checking internet connectivity before attempting updates and simplifies the frontend by removing WebSocket complexity in favor of a timeout-based polling approach.
This commit is contained in:
2026-05-12 19:09:05 +02:00
parent d337784faa
commit 8fbbfc90cd
12 changed files with 263 additions and 285 deletions
+1 -1
View File
@@ -49,7 +49,7 @@ function fetchWaterData(gauge) {
}
function fetchUpdateData(gauge) {
const apiUrl = '/ota_udpate_status';
const apiUrl = '/ota_update_status';
// Fetching data from the API
fetch(apiUrl)
.then(response => response.json())