gCode to move to top of Z axis

I am looking for the gCode command to move the router to the top of the Z axis.

This will be part of a script to use the probe to zero the Z axis. I am not using the Carbide 3D probe. Once set, I want to move the router to the top of the Z axis so I can reattach the dust boot and get back to work.

If it matters, I am setting the Z axis zero to be the top surface of the work piece.

If I could home the Z axis that would be good. But as near as I can tell the only homing command available works on all three axis and the movement in X and Y direction would be counterproductive.

I am using GRBL 1.1 and Carbide Motion 4

G53 Z0 is the top of the axis, but that’s also your limit switch. G53 Z-5 is 5mm (if you’re in G21 / mm mode) below the limit switch.

3 Likes

But keep in mind this will change your coordinate system, I don’t know how to tell what coordinate system it was in before you do this so you can put it back.

G53 does not change the work coordinate system. It is non-modal, which means it only affects the lines it is on.

$G will report the current modal state which will tell you your WCS among lots of other stuff going on.

1 Like

Wow, I didn’t there were any non-modals for that, that’s great to know!

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.