moved 2 parameters
This commit is contained in:
parent
6182369e4f
commit
17dd9de51e
@ -153,11 +153,9 @@ def handle_pdu_data(
|
||||
current_idx = 0
|
||||
priv_idx = pdu_idx - 1
|
||||
if set_id == SetId.AUX or set_id == SetId.AUX:
|
||||
fmt_str = "!hhBBBIIH"
|
||||
fmt_str = "!BBBIIH"
|
||||
inc_len = struct.calcsize(fmt_str)
|
||||
(
|
||||
vcc,
|
||||
vbat,
|
||||
conv_enb_0,
|
||||
conv_enb_1,
|
||||
conv_enb_2,
|
||||
@ -165,7 +163,6 @@ def handle_pdu_data(
|
||||
uptime,
|
||||
reset_cause,
|
||||
) = struct.unpack(fmt_str, hk_data[current_idx : current_idx + inc_len])
|
||||
pw.dlog(f"VCC {vcc} mV | VBAT {vbat} mV")
|
||||
pw.dlog(f"Converter Enables [{conv_enb_0},{conv_enb_1},{conv_enb_2}]")
|
||||
pw.dlog(
|
||||
f"Boot Cause {boot_cause} | Uptime {uptime} | Reset Cause {reset_cause}",
|
||||
@ -216,14 +213,14 @@ def handle_pdu_data(
|
||||
f"{voltage_list[idx]:05} | {current_list[idx]:04}"
|
||||
)
|
||||
pw.dlog(content_line)
|
||||
fmt_str = "!IBf"
|
||||
fmt_str = "!IBfhh"
|
||||
inc_len = struct.calcsize(fmt_str)
|
||||
(boot_count, batt_mode, temperature) = struct.unpack(
|
||||
(boot_count, batt_mode, temperature, vcc, vbat) = struct.unpack(
|
||||
fmt_str, hk_data[current_idx : current_idx + inc_len]
|
||||
)
|
||||
info = (
|
||||
f"Boot Count {boot_count} | Battery Mode {batt_mode} | "
|
||||
f"Temperature {temperature}"
|
||||
f"Temperature {temperature} | VCC {vcc} | VBAT {vbat}"
|
||||
)
|
||||
pw.dlog(info)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user