Notifications
Clear all

How to move the z-axis up after a print in OctoPrint?  

  RSS
pmu
 pmu
(@pmu)
Eminent Member
How to move the z-axis up after a print in OctoPrint?

Hi all,

I know, it's a newbie question, but still I hope for help here: How I can move the Z-axis up after a print ?

What G-code I have to use for it?

And, since that's related: What g-code to use for x and y axis movements after a print?

 

Thanks all! 

Best Answer by towlerg:

If you are going to manipulate the Z axis in a script make sure you set relative mode.  Note that G0 Z5 in absolute mode (G90) will move the nozzle 5mm above the bed whereas in relative mode (G91) the nozzle will move up 5 mm from whereever it is.

Posted : 19/12/2020 7:51 pm
Turro75
(@turro75)
Estimable Member
RE: How to move the z-axis up after a print in OctoPrint?

Hi,

 

simply add the commands in the after job completed field in the octoprint GCode Settings.

Mine values raise up the Z by 20mm the place both X and Y carriages at 180 position.

Posted : 19/12/2020 9:39 pm
Sandersann and pmu liked
towlerg
(@towlerg)
Noble Member
RE: How to move the z-axis up after a print in OctoPrint?

If you are going to manipulate the Z axis in a script make sure you set relative mode.  Note that G0 Z5 in absolute mode (G90) will move the nozzle 5mm above the bed whereas in relative mode (G91) the nozzle will move up 5 mm from whereever it is.

Posted : 20/12/2020 1:20 pm
cwbullet
(@cwbullet)
RE: How to move the z-axis up after a print in OctoPrint?

There are also plugins that will allow easier manipulation manually in Octoprint.  

--------------------
Chuck H
3D Printer Review Blog

Posted : 21/12/2020 10:49 am
pmu
 pmu
(@pmu)
Eminent Member
Topic starter answered:
RE: How to move the z-axis up after a print in OctoPrint?

@cwbullet

Which plugins for OctoPrint?

Posted : 22/12/2020 7:03 am
towlerg
(@towlerg)
Noble Member
RE: How to move the z-axis up after a print in OctoPrint?

You can add code to the custom GCode option for the Cancel button. Goto OctoPrint Settings/GCODE Scripts/After print job is cancelled. For example I have

M84 ; disable motors
{% snippet 'disable_hotends' %} ; M104 S0
{% snippet 'disable_bed' %} ; M140 S0
M106 S0 ; disable fan M107
G91 ; go relative
G0 Z5 ; unconditionally clear part
G90 ; go absolute
G0 X0 Y140 ; move bed forward
G0 Z50 ; raise nozzle for cleaning

Posted : 22/12/2020 2:16 pm
robenheimer
(@robenheimer)
New Member
RE: How to move the z-axis up after a print in OctoPrint?

@towlerg

it's weird that you move the Z up 5 relative, but then set it to 50 absolute.   what if part of your print was located at X0 Y140 Z50?

Posted : 26/05/2021 1:58 pm
towlerg
(@towlerg)
Noble Member
RE: How to move the z-axis up after a print in OctoPrint?

@robenheimer

I guess that may seem odd but I want a small unconditional z move to clear the part which is unlikely to hit max z. I also want to unconditionally raise the nozzle to clean both nozzle and bed. I'm going to have a bit of a rethink, perhaps 0 x and max y or maybe just live with the unconditional z + 5 and manually move z if necessary. Idealy use z + 5 relative and then whatever + z to make z 50 absolute (but I don't know how to do that).

 

Posted : 26/05/2021 6:24 pm
Share: