op_code fix

This commit is contained in:
Jakob.Meier 2021-08-11 17:14:30 +02:00
parent 0c99bc9d11
commit c7f5db0f53
2 changed files with 4 additions and 4 deletions

View File

@ -13,7 +13,7 @@
<option name="ADD_SOURCE_ROOTS" value="true" />
<EXTENSION ID="PythonCoverageRunConfigurationExtension" runner="coverage.py" />
<option name="SCRIPT_NAME" value="$PROJECT_DIR$/tmtc_client_cli.py" />
<option name="PARAMETERS" value="-s pdu1 -l" />
<option name="PARAMETERS" value="-s pdu1 -l -t 6" />
<option name="SHOW_COMMAND_LINE" value="false" />
<option name="EMULATE_TERMINAL" value="true" />
<option name="MODULE_MODE" value="false" />

View File

@ -27,13 +27,13 @@ class PDU1TestProcedure:
turn_channel_2_on = False # Star Tracker connected to this channel (5V)
turn_channel_2_off = False
turn_channel_3_on = False # MTQ connected to this channel (5V)
turn_channel_3_off = True
turn_channel_3_off = False
def pack_pdu1_test_into(object_id: bytearray, tc_queue: TcQueueT, op_code: str):
def pack_pdu1_test_into(object_id: bytearray, tc_queue: TcQueueT, op_code: str) -> TcQueueT:
tc_queue.appendleft((QueueCommands.PRINT, "Commanding PDU1"))
if op_code == 1:
if op_code == "1":
tc_queue.appendleft((QueueCommands.PRINT, "PDU1: Turn star tracker on"))
command = pack_set_param_command(object_id, PDUConfigTable.out_en_2.parameter_address,
PDUConfigTable.out_en_2.parameter_size, Channel.on)