pause_resume: Use Octoprint's "paused" and "resumed" action commands.
These action commands prevent Octoprint from sending extra gcodes that can interfere with Klipper's pause/resume control. Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
parent
ca8233e6d5
commit
05a04d5d3d
|
@ -33,7 +33,7 @@ class PauseResume:
|
||||||
self.v_sd.do_pause()
|
self.v_sd.do_pause()
|
||||||
else:
|
else:
|
||||||
self.sd_paused = False
|
self.sd_paused = False
|
||||||
self.gcode.respond_info("action:pause")
|
self.gcode.respond_info("action:paused")
|
||||||
self.pause_command_sent = True
|
self.pause_command_sent = True
|
||||||
def cmd_PAUSE(self, params):
|
def cmd_PAUSE(self, params):
|
||||||
if self.is_paused:
|
if self.is_paused:
|
||||||
|
@ -58,7 +58,7 @@ class PauseResume:
|
||||||
# Printing from virtual sd, run pause command
|
# Printing from virtual sd, run pause command
|
||||||
self.v_sd.cmd_M24({})
|
self.v_sd.cmd_M24({})
|
||||||
else:
|
else:
|
||||||
self.gcode.respond_info("action:resume")
|
self.gcode.respond_info("action:resumed")
|
||||||
|
|
||||||
def load_config(config):
|
def load_config(config):
|
||||||
return PauseResume(config)
|
return PauseResume(config)
|
||||||
|
|
Loading…
Reference in New Issue