This commit is contained in:
parent
4b054b7628
commit
bf9ab7edf7
@ -23,34 +23,44 @@ _LOGGER = logging.getLogger(__name__)
|
|||||||
class OpCode:
|
class OpCode:
|
||||||
OFF = "off"
|
OFF = "off"
|
||||||
ON = "on"
|
ON = "on"
|
||||||
REQ_OS_HK = ["hk"]
|
REQ_CORE_HK = ["core_hk_request"]
|
||||||
ENABLE_HK = ["enable_hk"]
|
ENABLE_CORE_HK = ["core_hk_enable"]
|
||||||
DISABLE_HK = ["disable_hk"]
|
DISABLE_CORE_HK = ["core_hk_disable"]
|
||||||
|
REQ_SKYVIEW_HK = ["skyview_hk_request"]
|
||||||
|
ENABLE_SKYVIEW_HK = ["skyview_hk_enable"]
|
||||||
|
DISABLE_SKYVIEW_HK = ["skyview_hk_disable"]
|
||||||
RESET_GNSS = ["reset"]
|
RESET_GNSS = ["reset"]
|
||||||
|
|
||||||
|
|
||||||
class Info:
|
class Info:
|
||||||
OFF = "Off"
|
OFF = "Off"
|
||||||
ON = "On"
|
ON = "On"
|
||||||
REQ_OS_HK = "Request One-Shot HK"
|
REQ_CORE_HK = "Request Core HK"
|
||||||
ENABLE_HK = "Enable HK"
|
ENABLE_CORE_HK = "Enable Core HK"
|
||||||
DISABLE_HK = "Disable HK"
|
DISABLE_CORE_HK = "Disable Core HK"
|
||||||
|
REQ_SKYVIEW_HK = "Request Skyview HK"
|
||||||
|
ENABLE_SKYVIEW_HK = "Enable Skyview HK"
|
||||||
|
DISABLE_SKYVIEW_HK = "Disable Skyview HK"
|
||||||
RESET_GNSS = "Reset GNSS using reset pin"
|
RESET_GNSS = "Reset GNSS using reset pin"
|
||||||
|
|
||||||
|
|
||||||
class SetId(enum.IntEnum):
|
class SetId(enum.IntEnum):
|
||||||
HK = 0
|
CORE_HK = 0
|
||||||
|
SKYVIEW_HK = 1
|
||||||
|
|
||||||
|
|
||||||
@tmtc_definitions_provider
|
@tmtc_definitions_provider
|
||||||
def add_gps_cmds(defs: TmtcDefinitionWrapper):
|
def add_gps_cmds(defs: TmtcDefinitionWrapper):
|
||||||
oce = OpCodeEntry()
|
oce = OpCodeEntry()
|
||||||
oce.add(keys=OpCode.RESET_GNSS, info=Info.RESET_GNSS)
|
|
||||||
oce.add(keys=OpCode.REQ_OS_HK, info=Info.REQ_OS_HK)
|
|
||||||
oce.add(keys=OpCode.ENABLE_HK, info=Info.ENABLE_HK)
|
|
||||||
oce.add(keys=OpCode.DISABLE_HK, info=Info.DISABLE_HK)
|
|
||||||
oce.add(keys=OpCode.OFF, info=Info.OFF)
|
oce.add(keys=OpCode.OFF, info=Info.OFF)
|
||||||
oce.add(keys=OpCode.ON, info=Info.ON)
|
oce.add(keys=OpCode.ON, info=Info.ON)
|
||||||
|
oce.add(keys=OpCode.RESET_GNSS, info=Info.RESET_GNSS)
|
||||||
|
oce.add(keys=OpCode.REQ_CORE_HK, info=Info.REQ_CORE_HK)
|
||||||
|
oce.add(keys=OpCode.ENABLE_CORE_HK, info=Info.ENABLE_CORE_HK)
|
||||||
|
oce.add(keys=OpCode.DISABLE_CORE_HK, info=Info.DISABLE_CORE_HK)
|
||||||
|
oce.add(keys=OpCode.REQ_SKYVIEW_HK, info=Info.REQ_SKYVIEW_HK)
|
||||||
|
oce.add(keys=OpCode.ENABLE_SKYVIEW_HK, info=Info.ENABLE_SKYVIEW_HK)
|
||||||
|
oce.add(keys=OpCode.DISABLE_SKYVIEW_HK, info=Info.DISABLE_SKYVIEW_HK)
|
||||||
defs.add_service(
|
defs.add_service(
|
||||||
name=CustomServiceList.GPS_CTRL.value,
|
name=CustomServiceList.GPS_CTRL.value,
|
||||||
info="GPS/GNSS Controller",
|
info="GPS/GNSS Controller",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user