added acs functional test
This commit is contained in:
parent
0943a7a998
commit
b3751004a6
@ -16,8 +16,15 @@ from pus_tc.devs.bpx_batt import BpxSetIds
|
|||||||
from pus_tc.system.core import SetIds as CoreSetIds
|
from pus_tc.system.core import SetIds as CoreSetIds
|
||||||
from gomspace.gomspace_common import SetIds as GsSetIds
|
from gomspace.gomspace_common import SetIds as GsSetIds
|
||||||
from pus_tc.devs.rad_sensor import CommandIds as RadSetIds
|
from pus_tc.devs.rad_sensor import CommandIds as RadSetIds
|
||||||
|
from pus_tc.devs.mgms import MgmLis3SetIds as MgmSetIds_0_2
|
||||||
|
from pus_tc.devs.mgms import MgmRm3100SetIds as MgmSetIds_1_3
|
||||||
|
from pus_tc.devs.gyros import AdisGyroSetIds as GyroSetIds_0_2
|
||||||
|
from pus_tc.devs.gyros import L3gGyroSetIds as GyroSetIds_1_3
|
||||||
|
|
||||||
|
|
||||||
from pus_tc.system.tcs import pack_tcs_sys_commands
|
from pus_tc.system.tcs import pack_tcs_sys_commands
|
||||||
from pus_tc.system.controllers import pack_controller_commands
|
from pus_tc.system.controllers import pack_controller_commands
|
||||||
|
from pus_tc.system.acs import pack_acs_command
|
||||||
|
|
||||||
|
|
||||||
class OpCodes:
|
class OpCodes:
|
||||||
@ -27,6 +34,7 @@ class OpCodes:
|
|||||||
PCDU_FT = ["pcdu-ft"]
|
PCDU_FT = ["pcdu-ft"]
|
||||||
RAD_SEN_FT = ["rad-sen-ft"]
|
RAD_SEN_FT = ["rad-sen-ft"]
|
||||||
TCS_FT = ["tcs-ft-on"]
|
TCS_FT = ["tcs-ft-on"]
|
||||||
|
ACS_FT = ["acs-ft"]
|
||||||
|
|
||||||
|
|
||||||
class KeyAndInfo:
|
class KeyAndInfo:
|
||||||
@ -35,7 +43,8 @@ class KeyAndInfo:
|
|||||||
CORE_FT = ["OBC", "OBC functional test"]
|
CORE_FT = ["OBC", "OBC functional test"]
|
||||||
PCDU_FT = ["PCDU", "PCDU functional test"]
|
PCDU_FT = ["PCDU", "PCDU functional test"]
|
||||||
RAD_SEN_FT = ["Radiation Sensor", "Radiation Sensor functional test"]
|
RAD_SEN_FT = ["Radiation Sensor", "Radiation Sensor functional test"]
|
||||||
TCS_FT = ["TCS Act.", "TCS functional test activation"]
|
TCS_FT = ["TCS", "TCS functional test"]
|
||||||
|
ACS_FT = ["ACS", "ACS functional test"]
|
||||||
|
|
||||||
|
|
||||||
KAI = KeyAndInfo
|
KAI = KeyAndInfo
|
||||||
@ -46,6 +55,7 @@ PROC_INFO_DICT = {
|
|||||||
KAI.PCDU_FT[0]: [OpCodes.PCDU_FT, KAI.PCDU_FT[1], 120.0, 10.0],
|
KAI.PCDU_FT[0]: [OpCodes.PCDU_FT, KAI.PCDU_FT[1], 120.0, 10.0],
|
||||||
KAI.RAD_SEN_FT[0]: [OpCodes.RAD_SEN_FT, KAI.RAD_SEN_FT[1], 120.0, 10.0],
|
KAI.RAD_SEN_FT[0]: [OpCodes.RAD_SEN_FT, KAI.RAD_SEN_FT[1], 120.0, 10.0],
|
||||||
KAI.TCS_FT[0]: [OpCodes.TCS_FT, KAI.TCS_FT[1], 1800.0, 10.0],
|
KAI.TCS_FT[0]: [OpCodes.TCS_FT, KAI.TCS_FT[1], 1800.0, 10.0],
|
||||||
|
KAI.ACS_FT[0]: [OpCodes.ACS_FT, KAI.ACS_FT[1], 120.0, 10.0]
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -124,17 +134,18 @@ def pack_proc_commands(tc_queue: TcQueueT, op_code: str):
|
|||||||
)
|
)
|
||||||
|
|
||||||
if op_code in OpCodes.RAD_SEN_FT:
|
if op_code in OpCodes.RAD_SEN_FT:
|
||||||
key = KAI.CORE_FT[0]
|
key = KAI.RAD_SEN_FT[0]
|
||||||
sid = make_sid(oids.RAD_SENSOR_ID, RadSetIds.READ_CONVERSIONS)
|
sid = make_sid(oids.RAD_SENSOR_ID, RadSetIds.READ_CONVERSIONS)
|
||||||
pack_generic_hk_listening_cmds(
|
pack_generic_hk_listening_cmds(
|
||||||
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
)
|
)
|
||||||
|
|
||||||
if op_code in OpCodes.TCS_FT:
|
if op_code in OpCodes.TCS_FT:
|
||||||
|
# does not work with .WAIT
|
||||||
pack_tcs_sys_commands(tc_queue=tc_queue, op_code="tcs-normal")
|
pack_tcs_sys_commands(tc_queue=tc_queue, op_code="tcs-normal")
|
||||||
pack_controller_commands(tc_queue=tc_queue, op_code="thermal_controller")
|
pack_controller_commands(tc_queue=tc_queue, op_code="thermal_controller")
|
||||||
|
|
||||||
key = KAI.CORE_FT[0]
|
key = KAI.TCS_FT[0]
|
||||||
# Ids for TCS Board missing. No HK generation?
|
# Ids for TCS Board missing. No HK generation?
|
||||||
sid = make_sid(oids.TCS_BOARD_ASS_ID, RadSetIds.READ_CONVERSIONS)
|
sid = make_sid(oids.TCS_BOARD_ASS_ID, RadSetIds.READ_CONVERSIONS)
|
||||||
pack_generic_hk_listening_cmds(
|
pack_generic_hk_listening_cmds(
|
||||||
@ -144,6 +155,114 @@ def pack_proc_commands(tc_queue: TcQueueT, op_code: str):
|
|||||||
pack_tcs_sys_commands(tc_queue=tc_queue, op_code="tcs-off")
|
pack_tcs_sys_commands(tc_queue=tc_queue, op_code="tcs-off")
|
||||||
pack_controller_commands(tc_queue=tc_queue, op_code="thermal_controller")
|
pack_controller_commands(tc_queue=tc_queue, op_code="thermal_controller")
|
||||||
|
|
||||||
|
if op_code in OpCodes.ACS_FT:
|
||||||
|
key = KAI.ACS_FT[0]
|
||||||
|
|
||||||
|
pack_acs_command(tc_queue=tc_queue, op_code="acs-a")
|
||||||
|
|
||||||
|
sid = make_sid(oids.MGM_0_LIS3_HANDLER_ID, MgmSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.MGM_1_RM3100_HANDLER_ID, MgmSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
|
||||||
|
sid = make_sid(oids.GYRO_0_ADIS_HANDLER_ID, GyroSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_0_ADIS_HANDLER_ID, GyroSetIds_0_2.CFG_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_1_L3G_HANDLER_ID, GyroSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
|
||||||
|
# GNSS0 missing
|
||||||
|
|
||||||
|
|
||||||
|
pack_acs_command(tc_queue=tc_queue, op_code="acs-off")
|
||||||
|
tc_queue.appendleft((QueueCommands.WAIT, 5.0))
|
||||||
|
pack_acs_command(tc_queue=tc_queue, op_code="acs-b")
|
||||||
|
|
||||||
|
sid = make_sid(oids.MGM_2_LIS3_HANDLER_ID, MgmSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.MGM_3_RM3100_HANDLER_ID, MgmSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
|
||||||
|
sid = make_sid(oids.GYRO_2_ADIS_HANDLER_ID, GyroSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_2_ADIS_HANDLER_ID, GyroSetIds_0_2.CFG_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_3_L3G_HANDLER_ID, GyroSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
|
||||||
|
# GNSS1 missing
|
||||||
|
|
||||||
|
pack_acs_command(tc_queue=tc_queue, op_code="acs-off")
|
||||||
|
tc_queue.appendleft((QueueCommands.WAIT, 5.0))
|
||||||
|
pack_acs_command(tc_queue=tc_queue, op_code="acs-d")
|
||||||
|
|
||||||
|
sid = make_sid(oids.MGM_0_LIS3_HANDLER_ID, MgmSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.MGM_1_RM3100_HANDLER_ID, MgmSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.MGM_2_LIS3_HANDLER_ID, MgmSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.MGM_3_RM3100_HANDLER_ID, MgmSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
|
||||||
|
sid = make_sid(oids.GYRO_0_ADIS_HANDLER_ID, GyroSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_0_ADIS_HANDLER_ID, GyroSetIds_0_2.CFG_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_1_L3G_HANDLER_ID, GyroSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_2_ADIS_HANDLER_ID, GyroSetIds_0_2.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_2_ADIS_HANDLER_ID, GyroSetIds_0_2.CFG_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
sid = make_sid(oids.GYRO_3_L3G_HANDLER_ID, GyroSetIds_1_3.CORE_HK)
|
||||||
|
pack_generic_hk_listening_cmds(
|
||||||
|
tc_queue=tc_queue, proc_key=key, sid=sid, diag=False
|
||||||
|
)
|
||||||
|
|
||||||
|
# GNSS0+1 missing
|
||||||
|
|
||||||
|
pack_acs_command(tc_queue=tc_queue, op_code="acs-off")
|
||||||
|
|
||||||
|
|
||||||
def listen_to_hk_for_x_seconds(
|
def listen_to_hk_for_x_seconds(
|
||||||
tc_queue: TcQueueT,
|
tc_queue: TcQueueT,
|
||||||
|
Loading…
Reference in New Issue
Block a user