aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/mcu.py
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2021-04-02 13:42:25 -0400
committerKevin O'Connor <kevin@koconnor.net>2021-06-09 18:58:35 -0400
commitbc29ee1c6d1fbd99a9d0c6db6b4419bbc8f8a7c3 (patch)
treecf0ead51fffdf6bb7d5d70fbfcb0749ce84f0a50 /klippy/mcu.py
parent983951443cf14fe2985585c2c2eb20efe526411d (diff)
downloadkutter-bc29ee1c6d1fbd99a9d0c6db6b4419bbc8f8a7c3.tar.gz
kutter-bc29ee1c6d1fbd99a9d0c6db6b4419bbc8f8a7c3.tar.xz
kutter-bc29ee1c6d1fbd99a9d0c6db6b4419bbc8f8a7c3.zip
homing: Check for failures during multi-endstop homing
If any endstop reports a failure, then stop homing on all endstops. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/mcu.py')
-rw-r--r--klippy/mcu.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/klippy/mcu.py b/klippy/mcu.py
index bd7267ad..1b77aff7 100644
--- a/klippy/mcu.py
+++ b/klippy/mcu.py
@@ -84,7 +84,9 @@ class MCU_trsync:
tc = self._trigger_completion
if tc is not None:
self._trigger_completion = None
- self._reactor.async_complete(tc, True)
+ reason = params['trigger_reason']
+ is_failure = (reason == self.REASON_COMMS_TIMEOUT)
+ self._reactor.async_complete(tc, is_failure)
elif self._home_end_clock is not None:
clock = self._mcu.clock32_to_clock64(params['clock'])
if clock >= self._home_end_clock: