PLOC SUPV extensions
EIVE/-/pipeline/head This commit looks good Details

This commit is contained in:
Robin Müller 2023-11-08 18:18:40 +01:00
parent 99c6c8bbd0
commit c4bd355146
4 changed files with 15 additions and 9 deletions

View File

@ -167,6 +167,9 @@ NOT_OK_TM_STORE = bytes([0x73, 0x02, 0x00, 0x03])
HK_TM_STORE = bytes([0x73, 0x02, 0x00, 0x04])
CFDP_TM_STORE = bytes([0x73, 0x03, 0x00, 0x00])
SUPV_FILTER_SET = [PLOC_SUPV_ID, PDU_2_HANDLER_ID, PDU_1_HANDLER_ID]
ObjectIdDict = Dict[bytes, ObjectIdU32]

View File

@ -676,10 +676,10 @@ def pack_set_gpio_cmd(object_id: bytes) -> bytearray:
port = int(input("Specify port: 0x"), 16)
pin = int(input("Specify pin: 0x"), 16)
val = int(input("Specify val: 0x"), 16)
command = object_id + struct.pack("!I", SupvActionId.SET_GPIO)
command = command + struct.pack("!B", port)
command = command + struct.pack("!B", pin)
command = command + struct.pack("!B", val)
command = bytearray(object_id + struct.pack("!I", SupvActionId.SET_GPIO))
command.append(port)
command.append(pin)
command.append(val)
return bytearray(command)

View File

@ -28,10 +28,12 @@ from tmtccmd.util import ObjectIdU32
class P60OpCode:
STACK_3V3_ON = ["stack_3v3_on", "1"]
STACK_3V3_OFF = ["stack_3v3_off", "2"]
STACK_5V_ON = ["stack_5v_on", "3"]
STACK_5V_OFF = ["stack_5v_off", "4"]
STACK_3V3_ON = "stack_3v3_on"
STACK_3V3_OFF = "stack_3v3_off"
STACK_5V_ON = "stack_5v_on"
STACK_5V_OFF = "stack_5v_off"
ACU_OFF = "acu_off"
ACU_ON = "acu_on"
TEST = ["test", "0"]

View File

@ -55,6 +55,7 @@ from eive_tmtc.config.definitions import (
CFDP_REMOTE_ENTITY_ID,
)
from eive_tmtc.config.hook import EiveHookObject
from eive_tmtc.config.object_ids import SUPV_FILTER_SET
from eive_tmtc.pus_tm.pus_demux import pus_factory_hook
_LOGGER = APP_LOGGER
@ -78,7 +79,7 @@ class PusHandler(SpecificApidHandlerBase):
self.verif_wrapper = wrapper
self.raw_logger = raw_logger
self.hk_level = hk_level
self.these_objs_hk_only = []
self.these_objs_hk_only = SUPV_FILTER_SET
self.hk_filter = HkFilter(object_ids=self.these_objs_hk_only, set_ids=[])
def handle_tm(self, packet: bytes, _user_args: any):