not much missing
All checks were successful
EIVE/-/pipeline/pr-main This commit looks good

This commit is contained in:
Robin Müller 2023-11-28 17:41:46 +01:00
parent 3cf312073a
commit d4147d8402
4 changed files with 63 additions and 5 deletions

View File

@ -12,6 +12,7 @@ from eive_tmtc.config.retvals import get_retval_dict
from eive_tmtc.tmtc.acs.acs_ctrl import create_acs_ctrl_node
from eive_tmtc.tmtc.acs.gps import create_gnss_node
from eive_tmtc.tmtc.acs.imtq import create_mgt_node
from eive_tmtc.tmtc.acs.star_tracker import create_str_node
from eive_tmtc.tmtc.acs.subsystem import create_acs_subsystem_node
from eive_tmtc.tmtc.com.ccsds_handler import create_ccsds_node
from eive_tmtc.tmtc.com.subsystem import create_com_subsystem_node
@ -29,6 +30,8 @@ from eive_tmtc.tmtc.power.subsystem import create_eps_subsystem_node
from eive_tmtc.tmtc.system import create_system_node
from eive_tmtc.tmtc.tcs.ctrl import create_tcs_ctrl_node
from eive_tmtc.tmtc.tcs.heater import create_heater_node
from eive_tmtc.tmtc.tcs.rtd import create_rtd_node
from eive_tmtc.tmtc.tcs.tmp1075 import create_tmp_sens_node
from eive_tmtc.tmtc.test import create_test_node
from eive_tmtc.tmtc.time import create_time_node
from eive_tmtc.tmtc.tm_store import create_persistent_tm_store_node
@ -75,7 +78,7 @@ class EiveHookObject(HookBase):
rws.add_child(rw_2)
rws.add_child(rw_3)
rws.add_child(rw_4)
star_tracker = CmdTreeNode("str", "Star Tracker")
star_tracker = create_str_node()
star_tracker_img_helper = CmdTreeNode(
"str_img_helper", "Star Tracker Image Helper"
)
@ -91,8 +94,8 @@ class EiveHookObject(HookBase):
acs_node.add_child(gnss_devs)
tcs_node = CmdTreeNode("tcs", "TCS Subsystem")
tmp_1075_node = CmdTreeNode("tmp1075_devs", "TMP1075 Devices")
rtds_node = CmdTreeNode("rtd_devs", "RTD Devices")
tmp_1075_node = create_tmp_sens_node()
rtds_node = create_rtd_node()
heaters_node = create_heater_node()
tcs_ctrl = create_tcs_ctrl_node()
tcs_node.add_child(rtds_node)

View File

@ -14,7 +14,7 @@ from eive_tmtc.config.definitions import CustomServiceList
from eive_tmtc.pus_tm.defs import PrintWrapper
from eive_tmtc.utility.input_helper import InputHelper
from spacepackets.ecss.tc import PusTelecommand
from tmtccmd.config import TmtcDefinitionWrapper, OpCodeEntry
from tmtccmd.config import CmdTreeNode, TmtcDefinitionWrapper, OpCodeEntry
from tmtccmd.config.tmtc import tmtc_definitions_provider
from tmtccmd.pus.tc.s3_fsfw_hk import (
create_request_one_diag_command,
@ -1147,6 +1147,41 @@ def handle_read_secondary_tm_set(pw: PrintWrapper, custom_data: bytes):
pw.dlog(f"Unknown Set ID {set_id}")
def create_str_node() -> CmdTreeNode:
node = CmdTreeNode("str", "Star Tracker Device")
node.add_child(CmdTreeNode(OpCodes.ON_BOOTLOADER, "Mode On, Submode Bootloader"))
node.add_child(CmdTreeNode(OpCodes.ON_FIRMWARE, "Mode On, Submode Firmware"))
node.add_child(CmdTreeNode(OpCodes.NORMAL, "Mode Normal"))
node.add_child(CmdTreeNode(OpCodes.OFF, "Mode Off"))
node.add_child(CmdTreeNode(OpCodes.PING, "Star Tracker: Ping"))
node.add_child(CmdTreeNode(OpCodes.TAKE_IMAGE, "Take Image"))
node.add_child(CmdTreeNode(OpCodes.UPLOAD_IMAGE, Info.UPLOAD_IMAGE))
node.add_child(CmdTreeNode(OpCodes.DOWNLOAD_IMAGE, Info.DOWNLOAD_IMAGE))
node.add_child(CmdTreeNode(OpCodes.ONE_SHOOT_HK, Info.ONE_SHOOT_HK))
node.add_child(CmdTreeNode(OpCodes.ENABLE_HK, Info.ENABLE_HK))
node.add_child(CmdTreeNode(OpCodes.DISABLE_HK, Info.DISABLE_HK))
node.add_child(
CmdTreeNode(OpCodes.SET_IMG_PROCESSOR_MODE, Info.SET_IMG_PROCESSOR_MODE)
)
node.add_child(
CmdTreeNode(
OpCodes.ADD_SECONDARY_TM_TO_NORMAL_MODE,
Info.ADD_SECONDARY_TM_TO_NORMAL_MODE,
)
)
node.add_child(
CmdTreeNode(OpCodes.READ_SECONDARY_TM_SET, Info.READ_SECONDARY_TM_SET)
)
node.add_child(
CmdTreeNode(OpCodes.RESET_SECONDARY_TM_SET, Info.RESET_SECONDARY_TM_SET)
)
node.add_child(CmdTreeNode(OpCodes.FW_UPDATE, Info.FW_UPDATE))
node.add_child(
CmdTreeNode(OpCodes.SET_TIME_FROM_SYS_TIME, Info.SET_TIME_FROM_SYS_TIME)
)
return node
@tmtc_definitions_provider
def add_str_cmds(defs: TmtcDefinitionWrapper):
oce = OpCodeEntry()

View File

@ -5,7 +5,7 @@ import struct
from eive_tmtc.config.definitions import CustomServiceList
from eive_tmtc.pus_tm.defs import PrintWrapper
from spacepackets.ecss import PusTelecommand
from tmtccmd.config import TmtcDefinitionWrapper, OpCodeEntry
from tmtccmd.config import CmdTreeNode, TmtcDefinitionWrapper, OpCodeEntry
from tmtccmd.config.tmtc import tmtc_definitions_provider
from tmtccmd.tmtc import DefaultPusQueueHelper
@ -95,6 +95,15 @@ class CmdInfo:
WRITE_CONFIG = "Write config"
def create_rtd_node() -> CmdTreeNode:
node = CmdTreeNode("rtd", "RTD commands", hide_children_which_are_leaves=True)
node.add_child(CmdTreeNode(CmdStr.ON, CmdInfo.ON))
node.add_child(CmdTreeNode(CmdStr.NORMAL, CmdInfo.NORMAL))
node.add_child(CmdTreeNode(CmdStr.OFF, CmdInfo.OFF))
node.add_child(CmdTreeNode(CmdStr.WRITE_CONFIG, CmdInfo.WRITE_CONFIG))
return node
@tmtc_definitions_provider
def specify_rtd_cmds(defs: TmtcDefinitionWrapper):
oce = OpCodeEntry()

View File

@ -8,6 +8,8 @@
import enum
import struct
from tmtccmd.config import CmdTreeNode
from eive_tmtc.config.definitions import CustomServiceList
from eive_tmtc.pus_tm.defs import PrintWrapper
from spacepackets.ecss.tc import PusTelecommand
@ -71,6 +73,15 @@ def pack_tmp1075_test_into(
return q
def create_tmp_sens_node() -> CmdTreeNode:
node = CmdTreeNode("tmp_1075", "TMP1075 Temperatur Sensors")
node.add_child(CmdTreeNode(CmdStr.OFF, CmdInfo.OFF))
node.add_child(CmdTreeNode(CmdStr.ON, CmdInfo.ON))
node.add_child(CmdTreeNode(CmdStr.NML, CmdInfo.NML))
node.add_child(CmdTreeNode(CmdStr.HK, CmdInfo.HK))
return node
@tmtc_definitions_provider
def add_tmp_sens_cmds(defs: TmtcDefinitionWrapper):
oce = OpCodeEntry()