start adding acs ctrl modes
This commit is contained in:
parent
e1cd0e9b5c
commit
aff3ced2c2
@ -15,6 +15,7 @@ from tmtccmd.config.tmtc import (
|
|||||||
)
|
)
|
||||||
from tmtccmd.tc.pus_20_params import pack_scalar_boolean_parameter_app_data
|
from tmtccmd.tc.pus_20_params import pack_scalar_boolean_parameter_app_data
|
||||||
from tmtccmd.tc import service_provider
|
from tmtccmd.tc import service_provider
|
||||||
|
from tmtccmd.tc.pus_200_fsfw_modes import Modes, pack_mode_data, Subservices
|
||||||
from tmtccmd.tc.decorator import ServiceProviderParams
|
from tmtccmd.tc.decorator import ServiceProviderParams
|
||||||
from tmtccmd.tc.pus_3_fsfw_hk import (
|
from tmtccmd.tc.pus_3_fsfw_hk import (
|
||||||
generate_one_hk_command,
|
generate_one_hk_command,
|
||||||
@ -42,6 +43,8 @@ class SetId(enum.IntEnum):
|
|||||||
|
|
||||||
|
|
||||||
class OpCodes:
|
class OpCodes:
|
||||||
|
OFF = ["off"]
|
||||||
|
NML = ["normal"]
|
||||||
REQUEST_RAW_MGM_HK = ["0", "mgm_raw_hk"]
|
REQUEST_RAW_MGM_HK = ["0", "mgm_raw_hk"]
|
||||||
ENABLE_RAW_MGM_HK = ["1", "enable_mgm_raw_hk"]
|
ENABLE_RAW_MGM_HK = ["1", "enable_mgm_raw_hk"]
|
||||||
DISABLE_RAW_MGM_HK = ["2", "disable_mgm_raw_hk"]
|
DISABLE_RAW_MGM_HK = ["2", "disable_mgm_raw_hk"]
|
||||||
@ -75,6 +78,8 @@ class OpCodes:
|
|||||||
|
|
||||||
|
|
||||||
class Info:
|
class Info:
|
||||||
|
OFF = "Switch ACS CTRL off"
|
||||||
|
NML = "Switch ACS CTRL normal"
|
||||||
REQUEST_RAW_MGM_HK = "Request Raw MGM HK once"
|
REQUEST_RAW_MGM_HK = "Request Raw MGM HK once"
|
||||||
ENABLE_RAW_MGM_HK = "Enable Raw MGM HK data generation"
|
ENABLE_RAW_MGM_HK = "Enable Raw MGM HK data generation"
|
||||||
DISABLE_RAW_MGM_HK = "Disable Raw MGM HK data generation"
|
DISABLE_RAW_MGM_HK = "Disable Raw MGM HK data generation"
|
||||||
@ -122,6 +127,8 @@ if PERFORM_MGM_CALIBRATION:
|
|||||||
@tmtc_definitions_provider
|
@tmtc_definitions_provider
|
||||||
def acs_cmd_defs(defs: TmtcDefinitionWrapper):
|
def acs_cmd_defs(defs: TmtcDefinitionWrapper):
|
||||||
oce = OpCodeEntry()
|
oce = OpCodeEntry()
|
||||||
|
oce.add(keys=OpCodes.OFF, info=Info.OFF)
|
||||||
|
oce.add(keys=OpCodes.NML, info=Info.NML)
|
||||||
oce.add(keys=OpCodes.REQUEST_RAW_MGM_HK, info=Info.REQUEST_RAW_MGM_HK)
|
oce.add(keys=OpCodes.REQUEST_RAW_MGM_HK, info=Info.REQUEST_RAW_MGM_HK)
|
||||||
oce.add(keys=OpCodes.ENABLE_RAW_MGM_HK, info=Info.ENABLE_RAW_MGM_HK)
|
oce.add(keys=OpCodes.ENABLE_RAW_MGM_HK, info=Info.ENABLE_RAW_MGM_HK)
|
||||||
oce.add(keys=OpCodes.DISABLE_RAW_MGM_HK, info=Info.DISABLE_RAW_MGM_HK)
|
oce.add(keys=OpCodes.DISABLE_RAW_MGM_HK, info=Info.DISABLE_RAW_MGM_HK)
|
||||||
@ -161,6 +168,10 @@ def acs_cmd_defs(defs: TmtcDefinitionWrapper):
|
|||||||
def pack_acs_ctrl_command(p: ServiceProviderParams):
|
def pack_acs_ctrl_command(p: ServiceProviderParams):
|
||||||
op_code = p.op_code
|
op_code = p.op_code
|
||||||
q = p.queue_helper
|
q = p.queue_helper
|
||||||
|
if op_code in OpCodes.OFF:
|
||||||
|
pass
|
||||||
|
if op_code in OpCodes.NML:
|
||||||
|
pass
|
||||||
if op_code in OpCodes.REQUEST_RAW_MGM_HK:
|
if op_code in OpCodes.REQUEST_RAW_MGM_HK:
|
||||||
q.add_log_cmd(Info.REQUEST_RAW_MGM_HK)
|
q.add_log_cmd(Info.REQUEST_RAW_MGM_HK)
|
||||||
q.add_pus_tc(
|
q.add_pus_tc(
|
||||||
|
Loading…
Reference in New Issue
Block a user