From e934eee6763cc1fefc8a4eb28c452eaa6da8ac26 Mon Sep 17 00:00:00 2001 From: michael Date: Mon, 16 Mar 2026 00:16:34 -0700 Subject: [PATCH] fix(pm3py): LED return echoes what was sent instead of meaningless status int --- pm3py/hw.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/pm3py/hw.py b/pm3py/hw.py index 519554b..2ca494a 100644 --- a/pm3py/hw.py +++ b/pm3py/hw.py @@ -95,9 +95,17 @@ class HWCommands: action_code = 1 brightness_val = 0 + ACTION_NAMES = {0: "off", 1: "on", 2: "toggle", 3: "pwm", 4: "pulse", 5: "fade", 6: "blink"} + payload = struct.pack("= 4 else None, + "count": count if action_code in (4, 6) else None, + } @staticmethod def _parse_led_str(led: str) -> int: