commands to tritstate mpsoc uart tx line
This commit is contained in:
parent
e939f2b934
commit
a0b398d214
@ -541,6 +541,8 @@ def add_ploc_mpsoc_cmds(cmd_dict: ServiceOpCodeDictT):
|
||||
"14": ("Ploc MPSoC: Mode replay", {OpCodeDictKeys.TIMEOUT: 2.0}),
|
||||
"15": ("Ploc MPSoC: Mode idle", {OpCodeDictKeys.TIMEOUT: 2.0}),
|
||||
"16": ("Ploc MPSoC: Tc cam command send", {OpCodeDictKeys.TIMEOUT: 2.0}),
|
||||
"17": ("Ploc MPSoC: Set UART TX tristate" , {OpCodeDictKeys.TIMEOUT: 2.0}),
|
||||
"18": ("Ploc MPSoC: Relesase UART TX", {OpCodeDictKeys.TIMEOUT: 2.0}),
|
||||
}
|
||||
service_ploc_mpsoc_tuple = ("Ploc MPSoC", op_code_dict_srv_ploc_mpsoc)
|
||||
cmd_dict[CustomServiceList.PLOC_MPSOC.value] = service_ploc_mpsoc_tuple
|
||||
|
@ -53,6 +53,8 @@ class CommandIds(enum.IntEnum):
|
||||
TC_MODE_REPLAY = 16
|
||||
TC_CAM_CMD_SEND = 17
|
||||
TC_MODE_IDLE = 18
|
||||
SET_UART_TX_TRISTATE = 20
|
||||
RELEASE_UART_TX = 21
|
||||
|
||||
|
||||
class MemAddresses(enum.IntEnum):
|
||||
@ -175,6 +177,16 @@ def pack_ploc_mpsoc_commands(
|
||||
command = object_id + struct.pack("!I", CommandIds.TC_CAM_CMD_SEND) + bytearray(cam_cmd, 'utf-8')
|
||||
command = PusTelecommand(service=8, subservice=128, ssc=32, app_data=command)
|
||||
tc_queue.appendleft(command.pack_command_tuple())
|
||||
elif op_code == "17":
|
||||
tc_queue.appendleft((QueueCommands.PRINT, "PLOC MPSoC: Set UART TX tristate"))
|
||||
command = object_id + struct.pack("!I", CommandIds.SET_UART_TX_TRISTATE)
|
||||
command = PusTelecommand(service=8, subservice=128, ssc=33, app_data=command)
|
||||
tc_queue.appendleft(command.pack_command_tuple())
|
||||
elif op_code == "18":
|
||||
tc_queue.appendleft((QueueCommands.PRINT, "PLOC MPSoC: Release UART TX"))
|
||||
command = object_id + struct.pack("!I", CommandIds.RELEASE_UART_TX)
|
||||
command = PusTelecommand(service=8, subservice=128, ssc=33, app_data=command)
|
||||
tc_queue.appendleft(command.pack_command_tuple())
|
||||
|
||||
return tc_queue
|
||||
|
||||
|
@ -769,7 +769,7 @@ def get_debug_verbosity() -> int:
|
||||
|
||||
|
||||
def pack_set_gpio_cmd(object_id: bytearray) -> bytearray:
|
||||
port = int(input("Specify port : 0x"), 16)
|
||||
port = int(input("Specify port: 0x"), 16)
|
||||
pin = int(input("Specify pin: 0x"), 16)
|
||||
val = int(input("Specify val: 0x"), 16)
|
||||
command = object_id + struct.pack("!I", SupvActionIds.SET_GPIO)
|
||||
|
Loading…
Reference in New Issue
Block a user