mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-04-19 20:29:40 +08:00
Rename pause duration to disarm timeout and set default to give same behavior as before
The name wasn't really covering what it was doing. It wasn't setting the duration of the pause, it was setting the timeout for the stepper disarm. Also, ive set the defaults so that the behavior remains the same, unlesss a user explicitly enables this CURA-7331
This commit is contained in:
parent
4682b9c4ae
commit
329c5c5c11
@ -49,14 +49,14 @@ class PauseAtHeight(Script):
|
||||
"minimum_value_warning": "1",
|
||||
"enabled": "pause_at == 'layer_no'"
|
||||
},
|
||||
"pause_duration":
|
||||
"disarm_timeout":
|
||||
{
|
||||
"label": "Pause Duration",
|
||||
"description": "After this time steppers are going to disarm (meaning that they can easyly lose their positions)",
|
||||
"label": "Disarm timeout",
|
||||
"description": "After this time steppers are going to disarm (meaning that they can easily lose their positions). Set this to 0 if you don't want to set any duration.",
|
||||
"type": "int",
|
||||
"value": "120",
|
||||
"value": "0",
|
||||
"minimum_value": "0",
|
||||
"minimum_value_warning": "30",
|
||||
"minimum_value_warning": "0",
|
||||
"maximum_value_warning": "1800",
|
||||
"unit": "s"
|
||||
},
|
||||
@ -152,7 +152,7 @@ class PauseAtHeight(Script):
|
||||
pause_at = self.getSettingValueByKey("pause_at")
|
||||
pause_height = self.getSettingValueByKey("pause_height")
|
||||
pause_layer = self.getSettingValueByKey("pause_layer")
|
||||
pause_duration = self.getSettingValueByKey("pause_duration")
|
||||
disarm_timeout = self.getSettingValueByKey("disarm_timeout")
|
||||
retraction_amount = self.getSettingValueByKey("retraction_amount")
|
||||
retraction_speed = self.getSettingValueByKey("retraction_speed")
|
||||
extrude_amount = self.getSettingValueByKey("extrude_amount")
|
||||
@ -320,7 +320,8 @@ class PauseAtHeight(Script):
|
||||
prepend_gcode += "M117 " + display_text + "\n"
|
||||
|
||||
# Set the disarm timeout
|
||||
prepend_gcode += self.putValue(M = 18, S = pause_duration) + " ; Set the disarm timeout\n"
|
||||
if disarm_timeout > 0:
|
||||
prepend_gcode += self.putValue(M = 18, S = disarm_timeout) + " ; Set the disarm timeout\n"
|
||||
|
||||
# Wait till the user continues printing
|
||||
prepend_gcode += self.putValue(M = 0) + " ; Do the actual pause\n"
|
||||
|
Loading…
x
Reference in New Issue
Block a user