aboutsummaryrefslogtreecommitdiffstats
path: root/bin/udt-accent
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-10-18 13:45:23 +0200
committerDanilo M. <danix@danix.xyz>2026-10-18 13:45:23 +0200
commit59ea46306cb11fe27e10ba827501ec21e52f7de3 (patch)
tree64029f7ceb63ba403c0e2cc8621b2105f0345d79 /bin/udt-accent
parentb859e0694e504c8756c1e051e92c3fc97eff587c (diff)
downloadunified-desktop-theme-59ea46306cb11fe27e10ba827501ec21e52f7de3.tar.gz
unified-desktop-theme-59ea46306cb11fe27e10ba827501ec21e52f7de3.zip
feat(accent): play the border gradient on a Tuya LED strip
udt-ledstrip sends the window border's three hues to every Tuya addressable strip in the tinytuya device list as a flow scene (DP 51, dreamlight_scene_mode), so the strip moves with the wallpaper accent. Fully local: it speaks protocol 3.5 itself with cryptography, finds the strip by its UDP discovery broadcast, and reads the local key from ~/.config/udt/tuya/devices.json, written once by tinytuya's wizard. DP 51's layout is undocumented and missing from the cloud spec; it was read off the strip's status pushes while the app set scenes. Saturation is floored at full because LEDs render pastel accents as white. udt-accent starts it detached next to udt-keyboard; install.sh links it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'bin/udt-accent')
-rwxr-xr-xbin/udt-accent4
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/udt-accent b/bin/udt-accent
index 5bb324b..2f9440d 100755
--- a/bin/udt-accent
+++ b/bin/udt-accent
@@ -625,7 +625,9 @@ def main(image):
# GRUB's background is a wallpaper snapshot. Detached for the same reason;
# it only rebuilds and notifies, since the copy into /boot needs root.
# The keyboard takes seconds per colour change, and is often not there.
- for helper in ("udt-homepage", "udt-grub", "udt-keyboard"):
+ # The LED strip waits up to 20 s for its address broadcast. Both read
+ # files written above.
+ for helper in ("udt-homepage", "udt-grub", "udt-keyboard", "udt-ledstrip"):
subprocess.Popen([Path(__file__).resolve().parent / helper],
stdin=subprocess.DEVNULL, stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL, start_new_session=True)