commands to enable and disable star tracker filestamping

This commit is contained in:
Robin Müller 2022-02-24 13:47:09 +01:00
parent 209958711b
commit fd43ef0c8a
4 changed files with 18 additions and 4 deletions

View File

@ -6,7 +6,7 @@
<envs>
<env name="PYTHONUNBUFFERED" value="1" />
</envs>
<option name="SDK_HOME" value="C:\Users\EIVE_Reinraumrechner\AppData\Local\Programs\Python\Python39\python.exe" />
<option name="SDK_HOME" value="C:\Users\EIVE_Reinraumrechner\EIVE-Software-Q7S\eive-obsw\tmtc\Scripts\python.exe" />
<option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
<option name="IS_MODULE_SDK" value="false" />
<option name="ADD_CONTENT_ROOTS" value="true" />

View File

@ -387,6 +387,8 @@ def get_eive_service_op_code_dict(service_op_code_dict: ServiceOpCodeDictT):
"67": ("Star Tracker: Set log subscription parameters", {OpCodeDictKeys.TIMEOUT: 2.0}),
"68": ("Star Tracker: Set debug camera parameters", {OpCodeDictKeys.TIMEOUT: 2.0}),
"69": ("Star Tracker: Firmware update", {OpCodeDictKeys.TIMEOUT: 2.0}),
"70": ("Star Tracker: Disable timestamp generation", {OpCodeDictKeys.TIMEOUT: 2.0}),
"71": ("Star Tracker: Enable timestamp generation", {OpCodeDictKeys.TIMEOUT: 2.0}),
}
service_star_tracker_tuple = ("Star tracker", op_code_dict_srv_star_tracker)

View File

@ -82,6 +82,8 @@ class StarTrackerActionIds:
LOG_SUBSCRIPTION = 82
DEBUG_CAMERA = 83
FIRMWARE_UPDATE = 84
DISBALE_TIMESTAMP_GENERATION = 85
ENABLE_TIMESTAMP_GENERATION = 86
class FileDefs:
@ -96,8 +98,8 @@ class FileDefs:
downloadFpgaImageName = "testname"
uploadFpgaImageName = "/mnt/sd0/startracker/fpga-image.bin"
egseGroundConfig = "/home/pi/arcsec/ground-config.json"
egseFlightConfig = "/home/pi/arcsec/flight-config.json"
q7sGroundConfig = "/mnt/sd0/startracker/ground-config.json"
egseFlightConfig = "/home/pi/arcsec/json/flight-config.json"
q7sGroundConfig = "/mnt/sd0/startracker/json/ground-config.json"
q7sFlightConfig = "/mnt/sd0/startracker/flight-config.json"
firmware2_1 = "/home/pi/arcsec/firmware/sagitta2-1.bin"
firmware22_1 = "/home/pi/arcsec/firmware/sagitta-22.1.bin"
@ -649,6 +651,16 @@ def pack_star_tracker_commands(
command = object_id + struct.pack('!I', StarTrackerActionIds.FIRMWARE_UPDATE) + bytearray(firmware, "utf-8")
command = PusTelecommand(service=8, subservice=128, ssc=87, app_data=command)
tc_queue.appendleft(command.pack_command_tuple())
if op_code == "70":
tc_queue.appendleft((QueueCommands.PRINT, "Star tracker: Disable timestamp generation"))
command = object_id + struct.pack('!I', StarTrackerActionIds.DISBALE_TIMESTAMP_GENERATION)
command = PusTelecommand(service=8, subservice=128, ssc=88, app_data=command)
tc_queue.appendleft(command.pack_command_tuple())
if op_code == "71":
tc_queue.appendleft((QueueCommands.PRINT, "Star tracker: Enable timestamp generation"))
command = object_id + struct.pack('!I', StarTrackerActionIds.DISBALE_TIMESTAMP_GENERATION)
command = PusTelecommand(service=8, subservice=128, ssc=89, app_data=command)
tc_queue.appendleft(command.pack_command_tuple())
def pack_write_command(object_id: bytearray) -> bytearray:

@ -1 +1 @@
Subproject commit bfa459ccc3c7189a77374a68f0217d448525b34b
Subproject commit 0a713b8695c54008b28e1314a2618dc4ba051ff5