kill all the duplication
This commit is contained in:
@ -44,7 +44,7 @@ def handle_eng_set(printer: FsfwTmTcPrinter, hk_data: bytes):
|
||||
coil_x_temperature,
|
||||
coil_y_temperature,
|
||||
coil_z_temperature,
|
||||
mcu_temperature
|
||||
mcu_temperature,
|
||||
]
|
||||
num_of_vars = len(header_list)
|
||||
pw.dlog(str(header_list))
|
||||
@ -58,19 +58,14 @@ def handle_calibrated_mtm_measurement(printer: FsfwTmTcPrinter, hk_data: bytes):
|
||||
"Calibrated MTM X [nT]",
|
||||
"Calibrated MTM Y [nT]",
|
||||
"Calibrated MTM Z [nT]",
|
||||
"Coild actuation status"
|
||||
"Coild actuation status",
|
||||
]
|
||||
mtm_x = struct.unpack("!I", hk_data[0:4])[0]
|
||||
mtm_y = struct.unpack("!I", hk_data[4:8])[0]
|
||||
mtm_z = struct.unpack("!I", hk_data[8:12])[0]
|
||||
coil_actuation_status = hk_data[12]
|
||||
validity_buffer = hk_data[12:]
|
||||
content_list = [
|
||||
mtm_x,
|
||||
mtm_y,
|
||||
mtm_z,
|
||||
coil_actuation_status
|
||||
]
|
||||
content_list = [mtm_x, mtm_y, mtm_z, coil_actuation_status]
|
||||
num_of_vars = len(header_list)
|
||||
pw.dlog(str(header_list))
|
||||
pw.dlog(str(content_list))
|
||||
@ -83,19 +78,14 @@ def handle_raw_mtm_measurement(printer: FsfwTmTcPrinter, hk_data: bytes):
|
||||
"Raw MTM X [nT]",
|
||||
"Raw MTM Y [nT]",
|
||||
"Raw MTM Z [nT]",
|
||||
"Coild actuation status"
|
||||
"Coild actuation status",
|
||||
]
|
||||
mtm_x = struct.unpack("!f", hk_data[0:4])[0]
|
||||
mtm_y = struct.unpack("!f", hk_data[4:8])[0]
|
||||
mtm_z = struct.unpack("!f", hk_data[8:12])[0]
|
||||
coil_actuation_status = hk_data[12]
|
||||
validity_buffer = hk_data[12:]
|
||||
content_list = [
|
||||
mtm_x,
|
||||
mtm_y,
|
||||
mtm_z,
|
||||
coil_actuation_status
|
||||
]
|
||||
content_list = [mtm_x, mtm_y, mtm_z, coil_actuation_status]
|
||||
num_of_vars = len(header_list)
|
||||
pw.dlog(str(header_list))
|
||||
pw.dlog(str(content_list))
|
||||
|
@ -15,8 +15,12 @@ from tmtccmd.logging import get_console_logger
|
||||
from pus_tm.devs.bpx_bat import handle_bpx_hk_data
|
||||
from pus_tm.devs.gps import handle_gps_data
|
||||
from pus_tm.devs.gyros import handle_gyros_hk_data
|
||||
from pus_tm.devs.imtq_mgt import handle_self_test_data, handle_eng_set, handle_calibrated_mtm_measurement, \
|
||||
handle_raw_mtm_measurement
|
||||
from pus_tm.devs.imtq_mgt import (
|
||||
handle_self_test_data,
|
||||
handle_eng_set,
|
||||
handle_calibrated_mtm_measurement,
|
||||
handle_raw_mtm_measurement,
|
||||
)
|
||||
from pus_tm.devs.pcdu import handle_pdu_data, handle_p60_hk_data, handle_acu_hk_data
|
||||
from pus_tm.devs.syrlinks import handle_syrlinks_hk_data
|
||||
from pus_tc.devs.imtq import ImtqSetIds
|
||||
|
Reference in New Issue
Block a user