diff options
author | Remco Burema <r.burema@ultimaker.com> | 2022-11-04 11:12:47 +0300 |
---|---|---|
committer | Remco Burema <r.burema@ultimaker.com> | 2022-11-04 11:12:47 +0300 |
commit | 997b6f830d6a711341d0211f3034a9cf343a692e (patch) | |
tree | 6868322e8f17d4ff98349bb7db4129fa5d107c84 | |
parent | b1138e12d9b6b1fb35bbb6bc6584f566063b284b (diff) |
Manually revert part of PR.
It shouldn't really be nescesary, but you _can_ put any gcode flavour in relative or absolute, so we should also deal with that in the pause-at-height script.
-rw-r--r-- | plugins/PostProcessingPlugin/scripts/PauseAtHeight.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/plugins/PostProcessingPlugin/scripts/PauseAtHeight.py b/plugins/PostProcessingPlugin/scripts/PauseAtHeight.py index 3c579d1ed5..6afac57359 100644 --- a/plugins/PostProcessingPlugin/scripts/PauseAtHeight.py +++ b/plugins/PostProcessingPlugin/scripts/PauseAtHeight.py @@ -514,7 +514,15 @@ class PauseAtHeight(Script): else: Logger.log("w", "No previous feedrate found in gcode, feedrate for next layer(s) might be incorrect") - prepend_gcode += self.putValue(M = 82) + "\n" + extrusion_mode_string = "absolute" + extrusion_mode_numeric = 82 + + relative_extrusion = Application.getInstance().getGlobalContainerStack().getProperty("relative_extrusion", "value") + if relative_extrusion: + extrusion_mode_string = "relative" + extrusion_mode_numeric = 83 + + prepend_gcode += self.putValue(M = extrusion_mode_numeric) + " ; switch back to " + extrusion_mode_string + " E values\n" # reset extrude value to pre pause value prepend_gcode += self.putValue(G = 92, E = current_e) + "\n" |