From d3437f924b32fe3be644d5e5605e7f52ffa7d753 Mon Sep 17 00:00:00 2001 From: Hermes Agent Date: Wed, 16 Sep 2026 17:30:43 +0200 Subject: [PATCH] Force wmi method on brightness fallback to skip slow DDC/VCP 49-retry --- black_screen_dim.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/black_screen_dim.py b/black_screen_dim.py index 66e16df..8bde989 100644 --- a/black_screen_dim.py +++ b/black_screen_dim.py @@ -129,7 +129,7 @@ class BrightnessController: else: idx = t[1] try: - v = sbc.get_brightness(display=idx) + v = sbc.get_brightness(display=idx, method="wmi") except Exception as e: LOG.warning("wmi get display %d failed: %r", idx, e) v = None @@ -149,7 +149,7 @@ class BrightnessController: else: idx = t[1] try: - sbc.set_brightness(0, display=idx) + sbc.set_brightness(0, display=idx, method="wmi") LOG.info("wmi dim display %d", idx) except Exception as e: LOG.warning("wmi dim display %d failed: %r", idx, e) @@ -168,7 +168,7 @@ class BrightnessController: else: idx = t[1] try: - sbc.set_brightness(int(val), display=idx) + sbc.set_brightness(int(val), display=idx, method="wmi") LOG.info("wmi restore display %d -> %s", idx, val) except Exception as e: LOG.warning("wmi restore display %d failed: %r", idx, e)