OTAMgr: check firmware endpoint; HTTPTOFS download; optional SHA256 verify; Update.apply + reboot
This commit is contained in:
@@ -6,6 +6,9 @@
|
||||
#include "src/app/AppConfig.hpp"
|
||||
#include "src/hw/PowerMgr.hpp"
|
||||
#include "src/hw/WiFiMgr.hpp"
|
||||
#include "src/core/OTAMgr.hpp"
|
||||
|
||||
#define FW_VERSION "1.0.0"
|
||||
|
||||
static AppConfig CFG;
|
||||
|
||||
@@ -26,6 +29,8 @@ void setup() {
|
||||
NetMgr::attachAndPdp(CFG.apn.c_str());
|
||||
SmsMgr::setup();
|
||||
|
||||
OTAMgr::setCurrentVersion(FW_VERSION);
|
||||
|
||||
// 2) Identity
|
||||
CFG.imei = queryImei();
|
||||
if (CFG.imei.isEmpty()) CFG.imei = "860016049744324";
|
||||
|
||||
Reference in New Issue
Block a user