reaction wheel get telemetry

This commit is contained in:
Jakob Meier 2021-06-30 15:08:43 +02:00
parent 78b6830782
commit da2968a512
2 changed files with 8 additions and 0 deletions

View File

@ -70,6 +70,7 @@ class EiveHookObject(TmTcHookBase):
"2": ("Reaction Wheel: Set mode on", {OpCodeDictKeys.TIMEOUT: 2.0}), "2": ("Reaction Wheel: Set mode on", {OpCodeDictKeys.TIMEOUT: 2.0}),
"3": ("Reaction Wheel: Set mode normal", {OpCodeDictKeys.TIMEOUT: 2.0}), "3": ("Reaction Wheel: Set mode normal", {OpCodeDictKeys.TIMEOUT: 2.0}),
"4": ("Reaction Wheel: Set mode off", {OpCodeDictKeys.TIMEOUT: 2.0}), "4": ("Reaction Wheel: Set mode off", {OpCodeDictKeys.TIMEOUT: 2.0}),
"5": ("Reaction Wheel: Send get-telemetry-command", {OpCodeDictKeys.TIMEOUT: 2.0}),
} }
service_rw_tuple = ("Reaction Wheel", op_code_dict_srv_rw) service_rw_tuple = ("Reaction Wheel", op_code_dict_srv_rw)

View File

@ -27,6 +27,7 @@ class RwCommandIds:
SET_SPEED = bytearray([0x0, 0x0, 0x0, 0x06]) SET_SPEED = bytearray([0x0, 0x0, 0x0, 0x06])
# Reads temperature from reaction wheel into dataset with id 8 # Reads temperature from reaction wheel into dataset with id 8
GET_TEMPERATURE = bytearray([0x0, 0x0, 0x0, 0x08]) GET_TEMPERATURE = bytearray([0x0, 0x0, 0x0, 0x08])
GET_TM = bytearray([0x0, 0x0, 0x0, 0x09])
class SpeedDefinitions: class SpeedDefinitions:
@ -69,6 +70,12 @@ def pack_single_rw_test_into(object_id: bytearray, tc_queue: TcQueueT, op_code:
mode_data = pack_mode_data(object_id, 0, 0) mode_data = pack_mode_data(object_id, 0, 0)
command = PusTelecommand(service=200, subservice=1, ssc=43, app_data=mode_data) command = PusTelecommand(service=200, subservice=1, ssc=43, app_data=mode_data)
tc_queue.appendleft(command.pack_command_tuple()) tc_queue.appendleft(command.pack_command_tuple())
if op_code == "5":
tc_queue.appendleft((QueueCommands.PRINT, "Reaction Wheel: Send get-telemetry-command"))
command = object_id + RwCommandIds.GET_TM
command = PusTelecommand(service=8, subservice=128, ssc=44, app_data=command)
tc_queue.appendleft(command.pack_command_tuple())
return tc_queue return tc_queue