syrlinks HK procedure

This commit is contained in:
2022-05-27 14:29:56 +02:00
parent 81501b4ae6
commit 88f319bed4
3 changed files with 39 additions and 7 deletions

View File

@ -85,6 +85,10 @@ class StarTrackerActionIds:
FIRMWARE_UPDATE = 84
class OpCodes:
NORMAL = ["2", "nml"]
class SetIds:
TEMPERATURE = 25
@ -172,7 +176,7 @@ def pack_star_tracker_commands(object_id: bytearray, tc_queue: TcQueueT, op_code
command = pack_mode_data(object_id, Modes.ON, Submode.FIRMWARE)
command = PusTelecommand(service=200, subservice=1, ssc=10, app_data=command)
tc_queue.appendleft(command.pack_command_tuple())
if op_code == "2":
if op_code in OpCodes.NORMAL:
tc_queue.appendleft((QueueCommands.PRINT, "Star tracker: Mode Normal"))
command = pack_mode_data(object_id, Modes.NORMAL, 0)
command = PusTelecommand(service=200, subservice=1, ssc=11, app_data=command)

View File

@ -19,6 +19,10 @@ class SetIds:
TX_REGISTERS_DATASET = 2
class OpCodes:
NORMAL = ["2", "nml"]
class CommandIds:
READ_RX_STATUS_REGISTERS = 2
SET_TX_MODE_STANDBY = 3
@ -37,9 +41,7 @@ class CommandIds:
DISABLE_DEBUG = 21
def pack_syrlinks_command(
object_id: bytearray, tc_queue: TcQueueT, op_code: str
) -> TcQueueT:
def pack_syrlinks_command(object_id: bytearray, tc_queue: TcQueueT, op_code: str):
tc_queue.appendleft(
(
QueueCommands.PRINT,
@ -57,7 +59,7 @@ def pack_syrlinks_command(
command = pack_mode_data(object_id, Modes.ON, 0)
command = PusTelecommand(service=200, subservice=1, ssc=10, app_data=command)
tc_queue.appendleft(command.pack_command_tuple())
if op_code == "2":
if op_code in OpCodes.NORMAL:
tc_queue.appendleft((QueueCommands.PRINT, "Syrlinks: Mode Normal"))
command = pack_mode_data(object_id, Modes.NORMAL, 0)
command = PusTelecommand(service=200, subservice=1, ssc=11, app_data=command)