commands to set and get pcdu parameters
This commit is contained in:
@ -180,13 +180,13 @@ def handle_pdu_data(
|
||||
current_list = []
|
||||
for idx in range(len(PDU1_CHANNELS_NAMES)):
|
||||
current_list.append(
|
||||
struct.unpack("!h", hk_data[current_idx : current_idx + 2])[0]
|
||||
struct.unpack("!h", hk_data[current_idx: current_idx + 2])[0]
|
||||
)
|
||||
current_idx += 2
|
||||
voltage_list = []
|
||||
for idx in range(len(PDU1_CHANNELS_NAMES)):
|
||||
voltage_list.append(
|
||||
struct.unpack("!H", hk_data[current_idx : current_idx + 2])[0]
|
||||
struct.unpack("!H", hk_data[current_idx: current_idx + 2])[0]
|
||||
)
|
||||
current_idx += 2
|
||||
output_enb_list = []
|
||||
@ -205,7 +205,7 @@ def handle_pdu_data(
|
||||
fmt_str = "!IBh"
|
||||
inc_len = struct.calcsize(fmt_str)
|
||||
(boot_count, batt_mode, temperature) = struct.unpack(
|
||||
fmt_str, hk_data[current_idx : current_idx + inc_len]
|
||||
fmt_str, hk_data[current_idx: current_idx + inc_len]
|
||||
)
|
||||
info = (
|
||||
f"Boot Count {boot_count} | Battery Mode {batt_mode} | "
|
||||
|
Reference in New Issue
Block a user