From 7abad9e98b66ffd8527a6fb2d7de02c161b059ad Mon Sep 17 00:00:00 2001 From: daid Date: Mon, 7 May 2012 16:42:15 +0200 Subject: [PATCH] Add 3 seconds delay in config wizard for the SD card init to timeout. --- Cura/gui/configWizard.py | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/Cura/gui/configWizard.py b/Cura/gui/configWizard.py index 8edaf410..812b073f 100644 --- a/Cura/gui/configWizard.py +++ b/Cura/gui/configWizard.py @@ -180,11 +180,13 @@ class UltimakerCheckupPage(InfoPage): wx.CallAfter(self.AddProgressText, "Error: Missing start message.") self.comm.close() return - + + #Wait 3 seconds for the SD card init to timeout if we have SD in our firmware but there is no SD card found. + time.sleep(3) + wx.CallAfter(self.AddProgressText, "Disabling step motors...") if self.DoCommCommandWithTimeout('M84') == False: wx.CallAfter(self.AddProgressText, "Error: Missing reply to Deactivate steppers (M84).") - wx.CallAfter(self.AddProgressText, "Possible cause: Temperature MIN/MAX.\nCheck temperature sensor connections.") self.comm.close() return @@ -289,6 +291,7 @@ class UltimakerCheckupPage(InfoPage): if line == '': self.comm.close() return False + print line if line.startswith(replyStart): break t.cancel() @@ -372,6 +375,9 @@ class UltimakerCalibrateStepsPerEPage(InfoPage): return if line.startswith('start'): break + #Wait 3 seconds for the SD card init to timeout if we have SD in our firmware but there is no SD card found. + time.sleep(3) + self.sendGCommand('M302') #Disable cold extrusion protection self.sendGCommand("M92 E%f" % (currentEValue)); self.sendGCommand("G92 E0"); @@ -392,6 +398,9 @@ class UltimakerCalibrateStepsPerEPage(InfoPage): return if line.startswith('start'): break + #Wait 3 seconds for the SD card init to timeout if we have SD in our firmware but there is no SD card found. + time.sleep(3) + self.sendGCommand('M104 S200') #Set the temperature to 200C, should be enough to get PLA and ABS out. wx.MessageBox('Wait till you can remove the filament from the machine, and press OK.\n(Temperature is set to 200C)', 'Machine heatup', wx.OK | wx.ICON_INFORMATION) self.sendGCommand('M104 S0') -- 2.30.2