use new decorator to add tmtc definitions now

This commit is contained in:
2022-08-12 10:18:21 +02:00
parent 26a886b5a2
commit 8625a98eb9
15 changed files with 84 additions and 85 deletions

View File

@ -4,9 +4,9 @@ import time
from typing import Optional
from config.definitions import CustomServiceList
from tmtccmd.config import TmTcDefWrapper
from tmtccmd.config import TmtcDefinitionWrapper
from tmtccmd.config.tmtc import OpCodeEntry, register_tmtc_definitions
from tmtccmd.config.tmtc import OpCodeEntry, tmtc_definitions_provider
from tmtccmd.tc import DefaultPusQueueHelper
from tmtccmd.tc.pus_3_fsfw_hk import (
make_sid,
@ -115,8 +115,8 @@ class ParamIds(enum.IntEnum):
INJECT_ALL_ON_FAILURE = 35
@register_tmtc_definitions
def add_pl_pcdu_cmds(defs: TmTcDefWrapper):
@tmtc_definitions_provider
def add_pl_pcdu_cmds(defs: TmtcDefinitionWrapper):
oce = OpCodeEntry()
oce.add(keys=OpCodes.SWITCH_HPA_ON_PROC, info=Info.SWITCH_HPA_ON_PROC)
oce.add(keys=OpCodes.SWITCH_ON, info=Info.SWITCH_ON)