fix: replace helper in server.py with correct name.

This commit is contained in:
2026-04-08 16:16:47 -04:00
parent a41e7a9e1a
commit c8c57e950c
+3 -6
View File
@@ -629,8 +629,7 @@ def device_monitor_status(
Returns is_monitoring bool, battery voltage, and memory usage (total + free bytes). Returns is_monitoring bool, battery voltage, and memory usage (total + free bytes).
Battery and memory are only present when the unit is idle (not monitoring). Battery and memory are only present when the unit is idle (not monitoring).
""" """
transport = _make_transport(port=port, baud=baud, host=host, tcp_port=tcp_port) with _build_client(port=port, baud=baud, host=host, tcp_port=tcp_port) as client:
with MiniMateClient(transport=transport) as client:
try: try:
client.connect() client.connect()
except Exception as exc: except Exception as exc:
@@ -662,8 +661,7 @@ def device_monitor_start(
Sends SUB 0x96 and waits for ack SUB 0x69. Sends SUB 0x96 and waits for ack SUB 0x69.
""" """
transport = _make_transport(port=port, baud=baud, host=host, tcp_port=tcp_port) with _build_client(port=port, baud=baud, host=host, tcp_port=tcp_port) as client:
with MiniMateClient(transport=transport) as client:
try: try:
client.connect() client.connect()
except Exception as exc: except Exception as exc:
@@ -685,8 +683,7 @@ def device_monitor_stop(
Sends SUB 0x97 and waits for ack SUB 0x68. Sends SUB 0x97 and waits for ack SUB 0x68.
""" """
transport = _make_transport(port=port, baud=baud, host=host, tcp_port=tcp_port) with _build_client(port=port, baud=baud, host=host, tcp_port=tcp_port) as client:
with MiniMateClient(transport=transport) as client:
try: try:
client.connect() client.connect()
except Exception as exc: except Exception as exc: