Fixed timeout issues that occurred sometimes when connecting to the printer
parent
574961ceac
commit
49f7568de2
|
@ -388,7 +388,7 @@ class MachineCom(object):
|
||||||
self._sendCommand("M105")
|
self._sendCommand("M105")
|
||||||
elif 'ok' in line:
|
elif 'ok' in line:
|
||||||
self._changeState(self.STATE_OPERATIONAL)
|
self._changeState(self.STATE_OPERATIONAL)
|
||||||
if time.time() > timeout:
|
elif time.time() > timeout:
|
||||||
self.close()
|
self.close()
|
||||||
elif self._state == self.STATE_OPERATIONAL:
|
elif self._state == self.STATE_OPERATIONAL:
|
||||||
#Request the temperature on comm timeout (every 2 seconds) when we are not printing.
|
#Request the temperature on comm timeout (every 2 seconds) when we are not printing.
|
||||||
|
|
Loading…
Reference in New Issue