Properly restart sd prints
Fixes #258
(cherry picked from commit 076c676)
This commit is contained in:
parent
717ec0419f
commit
b51da4bd1a
1 changed files with 2 additions and 1 deletions
|
|
@ -330,6 +330,7 @@ class MachineCom(object):
|
|||
if self._currentFile is None:
|
||||
raise ValueError("No file selected for printing")
|
||||
|
||||
wasPaused = self.isPaused()
|
||||
self._printSection = "CUSTOM"
|
||||
self._changeState(self.STATE_PRINTING)
|
||||
eventManager().fire("PrintStarted", self._currentFile.getFilename())
|
||||
|
|
@ -337,7 +338,7 @@ class MachineCom(object):
|
|||
try:
|
||||
self._currentFile.start()
|
||||
if self.isSdFileSelected():
|
||||
if self.isPaused():
|
||||
if wasPaused:
|
||||
self.sendCommand("M26 S0")
|
||||
self._currentFile.setFilepos(0)
|
||||
self.sendCommand("M24")
|
||||
|
|
|
|||
Loading…
Reference in a new issue