This commit is contained in:
Lynn Ochs 2022-11-22 22:09:14 +01:00
parent 14a6cf2042
commit 9358dfc74b

View File

@ -149,10 +149,13 @@ class Control(util.Loggable):
"closing some more") "closing some more")
self._comms.cmd_close() self._comms.cmd_close()
controlling = False controlling = False
action = None
elif self.state() == state.ERROR: elif self.state() == state.ERROR:
# Position too high, restart # Position too high, restart
self._logger().debug("Error") self._logger().debug("Error")
self._comm.cmd_restart() self._comm.cmd_restart()
sleep(5)
self._comm.cmd_close()
self.target(state.CLOSE) self.target(state.CLOSE)
else: else:
self._logger().debug("Reached wrong state") self._logger().debug("Reached wrong state")