Merge branch 'main' of https://egit.irs.uni-stuttgart.de/eive/eive-tmtc
This commit is contained in:
commit
dfa5cad8a6
@ -1,2 +1,3 @@
|
|||||||
from .payload.pl_subsystem import add_payload_subsystem_cmds
|
from .payload.pl_subsystem import add_payload_subsystem_cmds
|
||||||
|
from .solar_array_deployment import add_sa_depl_cmds
|
||||||
from .test import add_test_defs
|
from .test import add_test_defs
|
||||||
|
@ -35,7 +35,7 @@ class ActionId:
|
|||||||
|
|
||||||
|
|
||||||
@tmtc_definitions_provider
|
@tmtc_definitions_provider
|
||||||
def pack_sa_depl_cmds(defs: TmtcDefinitionWrapper):
|
def add_sa_depl_cmds(defs: TmtcDefinitionWrapper):
|
||||||
oce = OpCodeEntry()
|
oce = OpCodeEntry()
|
||||||
oce.add(keys=OpCode.MANUAL_DEPLOYMENT, info=Info.MANUAL_DEPLOYMENT)
|
oce.add(keys=OpCode.MANUAL_DEPLOYMENT, info=Info.MANUAL_DEPLOYMENT)
|
||||||
defs.add_service(
|
defs.add_service(
|
||||||
|
@ -144,9 +144,6 @@ def handle_thermal_controller_hk_data(
|
|||||||
printer.file_logger.info(str(parsed_data))
|
printer.file_logger.info(str(parsed_data))
|
||||||
pp = pprint.PrettyPrinter(depth=4)
|
pp = pprint.PrettyPrinter(depth=4)
|
||||||
pp.pprint(parsed_data)
|
pp.pprint(parsed_data)
|
||||||
# tcp_server_sensor_temperatures.report_parsed_hk_data(
|
|
||||||
# object_id, set_id, parsed_data
|
|
||||||
# )
|
|
||||||
elif set_id == SetId.DEVICE_SENSORS:
|
elif set_id == SetId.DEVICE_SENSORS:
|
||||||
pw = PrintWrapper(printer)
|
pw = PrintWrapper(printer)
|
||||||
pw.dlog("Received device temperature data")
|
pw.dlog("Received device temperature data")
|
||||||
@ -184,29 +181,25 @@ def handle_thermal_controller_hk_data(
|
|||||||
printer.file_logger.info(str(parsed_data))
|
printer.file_logger.info(str(parsed_data))
|
||||||
pp = pprint.PrettyPrinter(depth=4)
|
pp = pprint.PrettyPrinter(depth=4)
|
||||||
pp.pprint(parsed_data)
|
pp.pprint(parsed_data)
|
||||||
# print(parsed_data)
|
|
||||||
# tcp_server_device_temperatures.report_parsed_hk_data(
|
|
||||||
# object_id, set_id, parsed_data
|
|
||||||
# )
|
|
||||||
elif set_id == SetId.SUS_TEMP_SENSORS:
|
elif set_id == SetId.SUS_TEMP_SENSORS:
|
||||||
pass
|
pw = PrintWrapper(printer)
|
||||||
# pw = PrintWrapper(printer)
|
pw.dlog("Received SUS temperature data")
|
||||||
# pw.dlog("Received SUS temperature data")
|
fmt_str = "!ffffffffffffffffff"
|
||||||
# fmt_str = "!ffffffffffffffffff"
|
tm_data = struct.unpack(fmt_str, hk_data[: 4 * 18])
|
||||||
# tm_data = struct.unpack(fmt_str, hk_data[:4 * 18])
|
parsed_data = {
|
||||||
# parsed_data = {
|
"SUS_0": tm_data[0],
|
||||||
# "SUS_0": tm_data[0],
|
"SUS_1": tm_data[1],
|
||||||
# "SUS_1": tm_data[1],
|
"SUS_2": tm_data[2],
|
||||||
# "SUS_2": tm_data[2],
|
"SUS_3": tm_data[3],
|
||||||
# "SUS_3": tm_data[3],
|
"SUS_4": tm_data[4],
|
||||||
# "SUS_4": tm_data[4],
|
"SUS_5": tm_data[5],
|
||||||
# "SUS_5": tm_data[5],
|
"SUS_6": tm_data[6],
|
||||||
# "SUS_6": tm_data[6],
|
"SUS_7": tm_data[7],
|
||||||
# "SUS_7": tm_data[7],
|
"SUS_8": tm_data[8],
|
||||||
# "SUS_8": tm_data[8],
|
"SUS_9": tm_data[9],
|
||||||
# "SUS_9": tm_data[9],
|
"SUS_10": tm_data[10],
|
||||||
# "SUS_10": tm_data[10],
|
"SUS_11": tm_data[11],
|
||||||
# "SUS_11": tm_data[11],
|
}
|
||||||
# }
|
printer.file_logger.info(str(parsed_data))
|
||||||
# print(parsed_data)
|
pp = pprint.PrettyPrinter(depth=4)
|
||||||
# TODO: Forward data to space simulator
|
pp.pprint(parsed_data)
|
||||||
|
@ -5,7 +5,7 @@ from tmtccmd.config.tmtc import (
|
|||||||
TmtcDefinitionWrapper,
|
TmtcDefinitionWrapper,
|
||||||
OpCodeEntry,
|
OpCodeEntry,
|
||||||
)
|
)
|
||||||
from tmtccmd.pus.s17_test import pack_service_17_ping_command
|
from tmtccmd.pus.s17_test import create_service_17_ping_command
|
||||||
from tmtccmd.tc import service_provider
|
from tmtccmd.tc import service_provider
|
||||||
from tmtccmd.tc.decorator import ServiceProviderParams
|
from tmtccmd.tc.decorator import ServiceProviderParams
|
||||||
|
|
||||||
@ -42,7 +42,7 @@ def pack_test_command(p: ServiceProviderParams):
|
|||||||
q = p.queue_helper
|
q = p.queue_helper
|
||||||
if info.op_code == OpCodes.PING:
|
if info.op_code == OpCodes.PING:
|
||||||
q.add_log_cmd("Sending PUS TC [17,1]")
|
q.add_log_cmd("Sending PUS TC [17,1]")
|
||||||
q.add_pus_tc(pack_service_17_ping_command())
|
q.add_pus_tc(create_service_17_ping_command())
|
||||||
if info.op_code == OpCodes.TRIGGER_EVENT:
|
if info.op_code == OpCodes.TRIGGER_EVENT:
|
||||||
q.add_log_cmd("Sending PUS TC Event Trigger [17, 128]")
|
q.add_log_cmd("Sending PUS TC Event Trigger [17, 128]")
|
||||||
q.add_pus_tc(PusTelecommand(service=PusService.S17_TEST, subservice=128))
|
q.add_pus_tc(PusTelecommand(service=PusService.S17_TEST, subservice=128))
|
||||||
|
Loading…
Reference in New Issue
Block a user