aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/neopixel.py
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2020-11-04 18:47:36 -0500
committerKevin O'Connor <kevin@koconnor.net>2020-11-04 18:47:36 -0500
commit821561708d0973ba2dbc93fabff381075c0b2aed (patch)
tree262e984cdc0684d727e4705b6e6418fcd62b48e3 /klippy/extras/neopixel.py
parentfc0a18f8917334095acfa0035b7bc59ec37a2973 (diff)
downloadkutter-821561708d0973ba2dbc93fabff381075c0b2aed.tar.gz
kutter-821561708d0973ba2dbc93fabff381075c0b2aed.tar.xz
kutter-821561708d0973ba2dbc93fabff381075c0b2aed.zip
neopixel: Fix failure with multiple simultaneous neopixel updates
Make sure to set the oid parameter of mcu.lookup_query_command() so responses are routed correctly. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/extras/neopixel.py')
-rw-r--r--klippy/extras/neopixel.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/klippy/extras/neopixel.py b/klippy/extras/neopixel.py
index 03856c1f..b8a94599 100644
--- a/klippy/extras/neopixel.py
+++ b/klippy/extras/neopixel.py
@@ -56,7 +56,8 @@ class PrinterNeoPixel:
self.neopixel_update_cmd = self.mcu.lookup_command(
"neopixel_update oid=%c pos=%hu data=%*s", cq=cmd_queue)
self.neopixel_send_cmd = self.mcu.lookup_query_command(
- "neopixel_send oid=%c", "neopixel_result success=%c", cq=cmd_queue)
+ "neopixel_send oid=%c", "neopixel_result success=%c",
+ oid=self.oid, cq=cmd_queue)
def update_color_data(self, red, green, blue, white, index=None):
red = int(red * 255. + .5)
blue = int(blue * 255. + .5)