From 516f11a351d756f54b742490a84c61feb61f3bfd Mon Sep 17 00:00:00 2001 From: Niel Nielsen Date: Thu, 3 Sep 2026 09:33:29 +0200 Subject: [PATCH] Trigger reboot after successful OTA end Added reboot call after successful OTA finalization. Signed-off-by: Niel Nielsen --- armsrc/appmain.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/armsrc/appmain.c b/armsrc/appmain.c index a6ec9bfbe..63f95740c 100644 --- a/armsrc/appmain.c +++ b/armsrc/appmain.c @@ -3958,6 +3958,13 @@ static void PacketReceived(PacketCommandNG *packet) { break; case BWM_OTA_ACTION_END: res = bwm_esp_ota_end(); + if (res == PM3_SUCCESS) { + // Finalize succeeded and the new partition is now marked + // bootable; the ESP won't switch to it on its own, so + // kick the reboot here (DEV.md 12.8). Best-effort: don't + // fail the whole OTA over a lost reboot ack. + (void)bwm_esp_reboot(); + } break; default: res = PM3_EINVARG;