PLOC SUPV TM handling #293

Merged
meggert merged 3 commits from ploc-supv-tm-handling into main 2024-04-29 11:44:21 +02:00
Showing only changes of commit 342a3bbcc9 - Show all commits

View File

@ -753,8 +753,10 @@ def get_event_buffer_path() -> str:
class SocState(enum.IntEnum): class SocState(enum.IntEnum):
OFF = 0 OFF = 0
BOOTING = 1 BOOTING = 1
OPERATIONAL = 2 UPDATE = 2
SHUTDOWN = 3 OPERATIONAL = 3
RESET = 4
FAULTY = 5
def handle_supv_hk_data(set_id: int, hk_data: bytes, pw: PrintWrapper): def handle_supv_hk_data(set_id: int, hk_data: bytes, pw: PrintWrapper):
@ -792,7 +794,10 @@ def handle_hk_report(hk_data: bytes, pw: PrintWrapper):
pw.dlog(f"Temp PS {temp_ps} C | Temp PL {temp_pl} C | Temp SUP {temp_sup} C") pw.dlog(f"Temp PS {temp_ps} C | Temp PL {temp_pl} C | Temp SUP {temp_sup} C")
pw.dlog(f"Uptime {uptime} | CPU Load {cpu_load} | Avail Heap {avail_heap}") pw.dlog(f"Uptime {uptime} | CPU Load {cpu_load} | Avail Heap {avail_heap}")
pw.dlog(f"Number TCs {num_tcs} | Number TMs {num_tms}") pw.dlog(f"Number TCs {num_tcs} | Number TMs {num_tms}")
pw.dlog(f"SOC state {SocState(soc_state)}") try:
pw.dlog(f"SOC state {SocState(soc_state)}")
except ValueError:
pw.dlog(f"Invalid SOC state {soc_state}")
pw.dlog(f"NVM 01 State {nvm_0_1_state}") pw.dlog(f"NVM 01 State {nvm_0_1_state}")
pw.dlog(f"NVM 3 State {nvm_3_state}") pw.dlog(f"NVM 3 State {nvm_3_state}")
pw.dlog(f"Mission IO state {mission_io_state}") pw.dlog(f"Mission IO state {mission_io_state}")