From fc58c866c67bac7ec0310343feb3486e734e7337 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Thu, 31 Jul 2025 19:43:21 -0700 Subject: [PATCH] AGNOS power monitoring watchdog (#35860) * AGNOS power monitoring watchdog * manager should do this --- system/manager/manager.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/system/manager/manager.py b/system/manager/manager.py index 91916f708e..bd8e552dd3 100755 --- a/system/manager/manager.py +++ b/system/manager/manager.py @@ -3,6 +3,7 @@ import datetime import os import signal import sys +import time import traceback from cereal import log @@ -160,6 +161,14 @@ def manager_thread() -> None: msg.managerState.processes = [p.get_process_state_msg() for p in managed_processes.values()] pm.send('managerState', msg) + # kick AGNOS power monitoring watchdog + try: + if sm.all_checks(['deviceState']): + with open("/var/tmp/power_watchdog", "w") as f: + f.write(str(time.monotonic())) + except Exception: + pass + # Exit main loop when uninstall/shutdown/reboot is needed shutdown = False for param in ("DoUninstall", "DoShutdown", "DoReboot"):