mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Added relative extrusion mode support for PauseAtHeight.py script
This commit is contained in:
parent
dc09465afe
commit
76da7768e8
1 changed files with 10 additions and 1 deletions
|
@ -507,7 +507,16 @@ 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) + " ; switch back to absolute E values\n"
|
||||
extrusion_mode_string = "absolute"
|
||||
extrusion_mode_numeric = 82
|
||||
|
||||
extruders = list(Application.getInstance().getGlobalContainerStack().extruders.values())
|
||||
relative_extrusion = extruders[0].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"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue