From fd65bdd11d8f09f44813b0ab5f5ab89b2e3de508 Mon Sep 17 00:00:00 2001 From: Khishore-KM <79529664+Khishore-KM@users.noreply.github.com> Date: Wed, 30 Aug 2023 04:03:36 +0530 Subject: [PATCH] Additional Condition to Mitigate Probe Failures --- src/py/bbctrl/Mach.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/py/bbctrl/Mach.py b/src/py/bbctrl/Mach.py index 677c160..2aee1ef 100644 --- a/src/py/bbctrl/Mach.py +++ b/src/py/bbctrl/Mach.py @@ -139,6 +139,12 @@ class Mach(Comm): if log['msg'] == 'Switch not found': self.estop() + def _end_cycle(self): + if (self._get_cycle() != 'idle' and self._is_ready() + and not self.planner.is_busy() and not super().is_active()): + self.planner.position_change() + self._set_cycle('idle') + def _update(self, update): # Detect motor faults