start adding action reply handler for MPSoC
This commit is contained in:
parent
9e87142324
commit
2b26f1b106
@ -42,6 +42,8 @@ def handle_action_reply(
|
||||
return handle_core_ctrl_action_replies(action_id, printer, custom_data)
|
||||
elif object_id.as_bytes == STAR_TRACKER_ID:
|
||||
return handle_startracker_replies(action_id, printer, custom_data)
|
||||
elif object_id.as_bytes == PLOC_MPSOC_ID:
|
||||
return handle_mpsoc_data_reply(action_id, printer, custom_data)
|
||||
elif object_id.as_bytes in [
|
||||
ACU_HANDLER_ID,
|
||||
PDU_1_HANDLER_ID,
|
||||
|
@ -233,15 +233,17 @@ def pack_ploc_mpsoc_commands(p: ServiceProviderParams):
|
||||
data = object_id.as_bytes + struct.pack("!I", ActionId.TC_DOWNLINK_PWR_OFF)
|
||||
q.add_pus_tc(PusTelecommand(service=8, subservice=128, app_data=data))
|
||||
if op_code == OpCode.FLASH_GET_DIR_CONTENT:
|
||||
q.add_log_cmd(f"{prefix}: {OpCode.FLASH_GET_DIR_CONTENT}")
|
||||
dir_name = input("Please specify MPSoC directory name to get information for")
|
||||
q.add_log_cmd(f"{prefix}: {Info.FLASH_GET_DIR_CONTENT}")
|
||||
dir_name = input("Please specify MPSoC directory name to get information for: ")
|
||||
dir_name = bytearray(dir_name.encode("utf-8"))
|
||||
dir_name.append(0)
|
||||
return create_action_cmd(
|
||||
q.add_pus_tc(
|
||||
create_action_cmd(
|
||||
object_id=object_id.as_bytes,
|
||||
action_id=ActionId.TC_FLASH_DIR_GET_CONTENT,
|
||||
user_data=dir_name,
|
||||
)
|
||||
)
|
||||
if op_code == OpCode.REPLAY_WRITE_SEQ:
|
||||
q.add_log_cmd(f"{prefix}: {Info.REPLAY_WRITE_SEQ}")
|
||||
data = prepare_replay_write_sequence_cmd(object_id.as_bytes)
|
||||
@ -612,3 +614,10 @@ def handle_ploc_mpsoc_hk_data(printer: FsfwTmTcPrinter, hk_data: bytes, set_id:
|
||||
else:
|
||||
_LOGGER.warning(f"Unknown set ID {set_id} for MPSoC HK")
|
||||
pass
|
||||
|
||||
|
||||
def handle_mpsoc_data_reply(
|
||||
action_id: int, printer: FsfwTmTcPrinter, custom_data: bytes
|
||||
):
|
||||
print(f"Received MPSoC data reply with action ID {action_id}")
|
||||
pass
|
||||
|
Loading…
Reference in New Issue
Block a user