Need END GCODE that doesnt send the printer head straight up

I am having difficulty still with the ending code for the Cura nGen profile. It seems to shoot the print head straight up and as I have my spool mounted on top, this is no good.

Anyone have a good ending code that just lifts the head slightly up after the print is done and moves the build plate forward?


This is what I use for my Taz 5.

M104 S0 ; hotend off
M140 S0 ; heated bed heater off (if you have it)
M107 ; fans off
G91 ; relative positioning
G1 E-1 F300 ; retract the filament a bit before lifting the nozzle
to release some of the pressure
G1 Z+0.5 E-5 X-20 Y-20 F3000 ; move Z up a bit and retract filament even more
G90 ; absolute positioning
G1 X100 Y250 ; move to cooling position
M84 ; steppers off
G90 ; absolute positioning