all speed up and down command
This commit is contained in:
parent
968db5ce51
commit
eb7cb3f28c
@ -8,6 +8,7 @@ import struct
|
|||||||
from typing import List
|
from typing import List
|
||||||
|
|
||||||
from pus_tm.defs import PrintWrapper
|
from pus_tm.defs import PrintWrapper
|
||||||
|
from config.object_ids import RW1_ID, RW2_ID, RW3_ID, RW4_ID
|
||||||
from tmtccmd.config import TmtcDefinitionWrapper, OpCodeEntry
|
from tmtccmd.config import TmtcDefinitionWrapper, OpCodeEntry
|
||||||
from tmtccmd.config.tmtc import tmtc_definitions_provider
|
from tmtccmd.config.tmtc import tmtc_definitions_provider
|
||||||
from tmtccmd.tc import DefaultPusQueueHelper
|
from tmtccmd.tc import DefaultPusQueueHelper
|
||||||
@ -45,12 +46,16 @@ class OpCodesAss:
|
|||||||
ON = ["0", "on"]
|
ON = ["0", "on"]
|
||||||
NML = ["1", "nml"]
|
NML = ["1", "nml"]
|
||||||
OFF = ["2", "off"]
|
OFF = ["2", "off"]
|
||||||
|
ALL_SPEED_UP = ["3", "speed_up"]
|
||||||
|
ALL_SPEED_OFF = ["4", "speed_off"]
|
||||||
|
|
||||||
|
|
||||||
class InfoAss:
|
class InfoAss:
|
||||||
ON = "Mode On: 3/4 RWs min. on"
|
ON = "Mode On: 3/4 RWs min. on"
|
||||||
NML = "Mode Normal: 3/4 RWs min. normal"
|
NML = "Mode Normal: 3/4 RWs min. normal"
|
||||||
OFF = "Mode Off: All RWs off"
|
OFF = "Mode Off: All RWs off"
|
||||||
|
ALL_SPEED_UP = "Speed up consecutively"
|
||||||
|
ALL_SPEED_OFF = "Speed down to 0"
|
||||||
|
|
||||||
|
|
||||||
class RwSetIds:
|
class RwSetIds:
|
||||||
@ -182,6 +187,10 @@ def pack_rw_ass_cmds(q: DefaultPusQueueHelper, object_id: bytes, op_code: str):
|
|||||||
service=200, subservice=Subservices.TC_MODE_COMMAND, app_data=data
|
service=200, subservice=Subservices.TC_MODE_COMMAND, app_data=data
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
if op_code in OpCodesAss.ALL_SPEED_UP:
|
||||||
|
rw_speed_up_cmd_consec(q, [RW1_ID, RW2_ID, RW3_ID, RW4_ID], 65000, 10000)
|
||||||
|
if op_code in OpCodesAss.ALL_SPEED_OFF:
|
||||||
|
rw_speed_down_cmd_consec(q, [RW1_ID, RW2_ID, RW3_ID, RW4_ID], 10000)
|
||||||
|
|
||||||
|
|
||||||
def pack_set_speed_command(
|
def pack_set_speed_command(
|
||||||
|
Loading…
Reference in New Issue
Block a user