Modifying built-in macros
-
This is most likely me missing the obvious, but how can I find, modify and save 'built-in' macros? For example pause.g, which I'd like to have a relative movement to get the bed away from a hot nozzle, or the macro to change filament that invokes load and unload filament macros.
Thanks, -
To edit system files (Pause.g, Resume.g etc) You would find them via Files - System and click them, this opens a text editor.
To edit Macro's, you find them via Files - Macros and right click to open a menu and then Edit file.
-
@rushmere3d said in Modifying built-in macros:
To edit system files (Pause.g, Resume.g etc) You would find them via Files - System and click them, this opens a text editor.
To edit Macro's, you find them via Files - Macros and right click to open a menu and then Edit file.
That was the first place I looked but those macros aren't there or they are not visible. There are 2 directories within System (System directory and Firmware directory) and neither have those macros, unless perhaps they are hidden in a 'bin' I have also looked in 'Macros' and they aren't there either.
-
@tomf if you have pause.g and resume.g then they should be in the System directory. Perhaps you don't have them? Can you see config.g in the System directory?
-
The "built-in" macros are not really built-in - you have to create them if you need/want them.
Frederick
-
@dc42
Yes. config.g is there, so I guess I don't have the others. I though they were somehow built in based on the explanation in the M226 documentation "Initiates a pause in the same way as if the pause button is pressed, except that execution of all prior GCode commands in the same input stream is completed first. Then the SD card input stream is paused and file sys/pause.g is run" so I was looking for a file. Are there examples of pause, resume, load, etc. that I can use? -
@fcwilt said in Modifying built-in macros:
The "built-in" macros are not really built-in - you have to create them if you need/want them.
Frederick
I'm now realising that! I will have to find some examples somewhere. Any suggestions?
-
@tomf said in Modifying built-in macros:
@fcwilt said in Modifying built-in macros:
The "built-in" macros are not really built-in - you have to create them if you need/want them.
Frederick
I'm now realising that! I will have to find some examples somewhere. Any suggestions?
Perhaps these will help you get started.
Here is my pause.g:
M291 R"Pausing Print" P"Please wait..." T0 M83 ; relative extruder moves G1 E-1 F3600 ; retract filament (see resume.g) G91 ; relative moves G1 Z10 F9999 ; move nozzle out of the way - step 1 (max speed) G90 ; absolute moves G1 X0 Y150 F6000 ; move nozzle out of the way - step 2 M291 R"Print Paused" P"Done" T1 Here is my resume.g:
M291 R"Resuming print" P"Please wait..." T0 G1 R1 Z5 ; move nozzle to 5mm above resume point (Z) G1 R1 X0 Y0 ; move nozzle to resume point (XY) G1 R1 Z0 ; lower nozzle to resume point (Z) M83 ; relative extruder moves G1 E1 F3600 ; undo the retraction done in pause.g M291 R"Print Resumed" P"Done" T1 -
@fcwilt
Great, thanks! I found some through the Duet macros documentation, so I should hopefully be able to work out something from these.