From 2af901bdca73470ffc780c10272359df35c7e6fa Mon Sep 17 00:00:00 2001 From: David Gwilliam Date: Wed, 24 Jun 2026 05:03:32 -0700 Subject: [PATCH] debug: add real-time logging to viz (note on/off, frame sent/drop) --- scripts/led-matrix-viz.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/led-matrix-viz.py b/scripts/led-matrix-viz.py index d054188..89ef3e6 100755 --- a/scripts/led-matrix-viz.py +++ b/scripts/led-matrix-viz.py @@ -131,6 +131,7 @@ def main(): changed = True if changed: events_processed += 1 + print(f"[viz] note {note} {'on' if vel > 0 else 'off'} active={len(active_notes)}", flush=True) params = render(active_notes) if params != last_sent_params: msg_id = (msg_id + 1) % 65535 @@ -143,8 +144,10 @@ def main(): if ok: pending_bytes = None frames_sent += 1 + print(f"[viz] sent frame #{msg_id}", flush=True) else: frames_dropped += 1 + print(f"[viz] drop frame #{msg_id}", flush=True) # Background refresh: resend last params to recover from router drops if refresh_due: