From c21922e5200ff773ff7e5911d4c4f60958819758 Mon Sep 17 00:00:00 2001 From: "Adrian A. Baumann" Date: Sat, 11 Apr 2026 00:10:52 +0200 Subject: [PATCH] Speed increase test --- gaugemqttcontinuous.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gaugemqttcontinuous.py b/gaugemqttcontinuous.py index e16db2e..24602a4 100644 --- a/gaugemqttcontinuous.py +++ b/gaugemqttcontinuous.py @@ -749,7 +749,12 @@ def main(): current_target = g._val_to_step(gauge_targets[i]) if current_target != g._current_step: direction = 1 if current_target > g._current_step else -1 - g.step(direction) + steps_to_move = current_target - g._current_step + steps_to_move = max( + -10, min(10, steps_to_move) + ) # move up to 10 steps at a time + for _ in range(abs(steps_to_move)): + g.step(direction) moved_any = True if (