Back to Pretty OTA
This commit is contained in:
@@ -12,8 +12,7 @@
|
||||
#include <esp_now.h>
|
||||
#include <esp_wifi.h>
|
||||
|
||||
|
||||
|
||||
#include <battery.h>
|
||||
#include <communication.h>
|
||||
#include <databasebackend.h>
|
||||
#include <debug.h>
|
||||
@@ -22,8 +21,6 @@
|
||||
#include <timesync.h>
|
||||
#include <webserverrouter.h>
|
||||
#include <wificlass.h>
|
||||
#include <battery.h>
|
||||
|
||||
|
||||
const char *firmwareversion = "1.0.0"; // Version der Firmware
|
||||
|
||||
@@ -300,15 +297,14 @@ void setup() {
|
||||
setupWebSocket();
|
||||
setupLED();
|
||||
setupMqttServer(); // MQTT Server initialisieren
|
||||
//setupBattery();
|
||||
//setupRFID();
|
||||
// setupBattery();
|
||||
// setupRFID();
|
||||
}
|
||||
|
||||
void loop() {
|
||||
loopOTA(); // OTA Loop aufrufen
|
||||
checkAutoReset();
|
||||
loopMqttServer(); // MQTT Server in der Loop aufrufen
|
||||
loopWebSocket();
|
||||
//loopBattery(); // Batterie-Loop aufrufen
|
||||
//loopRFID(); // RFID Loop aufrufen
|
||||
// loopBattery(); // Batterie-Loop aufrufen
|
||||
// loopRFID(); // RFID Loop aufrufen
|
||||
}
|
||||
|
||||
@@ -6,12 +6,15 @@
|
||||
#include <esp_wifi.h>
|
||||
#include <ElegantOTA.h> // OTA Updates
|
||||
|
||||
#include <PrettyOTA.h>
|
||||
|
||||
#include "licenceing.h"
|
||||
#include "master.h"
|
||||
#include "timesync.h"
|
||||
|
||||
String uniqueSSID;
|
||||
|
||||
PrettyOTA OTAUpdates;
|
||||
|
||||
String getUniqueSSID();
|
||||
bool isInternetAvailable();
|
||||
@@ -78,25 +81,20 @@ void setupWifi() {
|
||||
void setupOTA(AsyncWebServer *server) {
|
||||
// Initialize PrettyOTA
|
||||
|
||||
ElegantOTA.begin(server);
|
||||
//ElegantOTA.begin(server);
|
||||
|
||||
//OTAUpdates.Begin(server);
|
||||
OTAUpdates.Begin(server);
|
||||
|
||||
// Set unique Hardware-ID for your hardware/board
|
||||
//OTAUpdates.SetHardwareID("AquaCross-Master");
|
||||
OTAUpdates.SetHardwareID("AquaCross-Master");
|
||||
|
||||
// Set firmware version to 1.0.0
|
||||
//OTAUpdates.SetAppVersion(firmwareversion);
|
||||
OTAUpdates.SetAppVersion(firmwareversion);
|
||||
|
||||
// Set current build time and date
|
||||
//PRETTY_OTA_SET_CURRENT_BUILD_TIME_AND_DATE();
|
||||
PRETTY_OTA_SET_CURRENT_BUILD_TIME_AND_DATE();
|
||||
}
|
||||
|
||||
void loopOTA(){
|
||||
|
||||
ElegantOTA.loop();
|
||||
|
||||
}
|
||||
|
||||
// Generiert eine eindeutige SSID auf Basis der MAC-Adresse.
|
||||
String getUniqueSSID() {
|
||||
|
||||
Reference in New Issue
Block a user