Add ESP32 OTA firmware update with rollback confirmation.
Stream application binaries to the inactive OTA slot via POST /api/system/ota, validate the esp_app_desc project name in core, and cancel rollback after a healthy network boot through OtaService::confirmBoot(). Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -45,6 +45,10 @@ namespace integration {
|
||||
class IntegrationService;
|
||||
} // namespace integration
|
||||
|
||||
namespace ota {
|
||||
class OtaService;
|
||||
} // namespace ota
|
||||
|
||||
namespace tuner {
|
||||
class TunerService;
|
||||
} // namespace tuner
|
||||
@@ -74,6 +78,7 @@ public:
|
||||
* @param bluetooth Bluetooth pairing service for REST routes.
|
||||
* @param stations Station preset service for REST routes.
|
||||
* @param integration Application orchestration for preset recall.
|
||||
* @param ota Firmware OTA service for POST /api/system/ota.
|
||||
* @param companionChips Boot flags exposed on GET /api/health.
|
||||
* @param deviceIdentity EEPROM-derived SSID, hostname, and serial.
|
||||
* @return NetBootstrap on success, or a NetError.
|
||||
@@ -87,6 +92,7 @@ public:
|
||||
audio::AudioService& audio, bluetooth::BluetoothService& bluetooth,
|
||||
station::StationService& stations,
|
||||
integration::IntegrationService& integration,
|
||||
ota::OtaService& ota,
|
||||
core::CompanionChipStatus companionChips,
|
||||
const core::DeviceIdentity& deviceIdentity);
|
||||
|
||||
|
||||
@@ -43,6 +43,10 @@ namespace integration {
|
||||
class IntegrationService;
|
||||
} // namespace integration
|
||||
|
||||
namespace ota {
|
||||
class OtaService;
|
||||
} // namespace ota
|
||||
|
||||
namespace tuner {
|
||||
class TunerService;
|
||||
} // namespace tuner
|
||||
@@ -69,6 +73,7 @@ struct HttpRouteContext {
|
||||
bluetooth::BluetoothService* bluetooth; ///< Bluetooth pairing REST routes.
|
||||
station::StationService* stations; ///< Preset list REST routes.
|
||||
integration::IntegrationService* integration; ///< Preset recall orchestration.
|
||||
ota::OtaService* ota; ///< Firmware OTA streaming.
|
||||
core::CompanionChipStatus companionChips; ///< Boot flags for /api/health.
|
||||
core::DeviceIdentity deviceIdentity; ///< EEPROM-derived unit identity.
|
||||
};
|
||||
@@ -147,6 +152,7 @@ public:
|
||||
* @param bluetooth Bluetooth service for pairing REST routes.
|
||||
* @param stations Station preset service for list REST routes.
|
||||
* @param integration Application orchestration for preset recall.
|
||||
* @param ota Firmware OTA service for POST /api/system/ota.
|
||||
* @param companionChips Boot flags for GET /api/health.
|
||||
* @param deviceIdentity Unit identity for /api/health serialNumber.
|
||||
* @return Ok on success, or NetError::HttpServerStartFailed.
|
||||
@@ -161,6 +167,7 @@ public:
|
||||
bluetooth::BluetoothService& bluetooth,
|
||||
station::StationService& stations,
|
||||
integration::IntegrationService& integration,
|
||||
ota::OtaService& ota,
|
||||
core::CompanionChipStatus companionChips,
|
||||
const core::DeviceIdentity& deviceIdentity);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user