Unparking (retrieve homing & position info at startup)

Users should post macros that they want to share in this forum. It is recommended that you attach the actual macro code to your posting. Also, please include a detailed description of what the macro does and why it is useful. It is also helpful to include line by line comments in the macro g-code file. This will help users modify it to fit their exact needs.

Please only submit one macro per posting and clearly name the subject in a way that describes the macro being posted.

If your macro builds on the work of others, please don't forget to give that person credit for his/her work.
Forum rules
No profanity, No gambling. No porn. No illegal activity of any kind. Violators will be removed without notice.
Post Reply
missionarymike
Posts: 15
Joined: Mon Mar 29, 2021 6:46 pm

Unparking (retrieve homing & position info at startup)

Post by missionarymike » Thu Jun 30, 2022 6:51 pm

This macro allows you to retrieve the homing and position info that was used during shutdown without having to read GCode system variables.

Simply put, this code sends the machine to a specified location, mine is front center with the Z at full height, so it is ready for a tool change, and then sets the homing variables that were used during the "parking" procedure.

This is great as it saves time by not requiring you to rehome the machine each time you startup. After the macro is run, you can do a tool change and start cutting.

This macro is used in conjunction with the "parking" macro and the XYZ variables that are set in this file MUST match exactly to what was set in the "parking" macro.

Code: Select all

(File: 'unparking.nc')

G20 (imperial mode)

; no need to use G53 as there are no existing offsets
G28.3 X36 (set home)
G28.3 Y48 (set home)
G28.3 Z7 (set home)

G0 Y6 X24 (move to front center for tool change)
M2
Please feel free to provide feedback on how this works on your machine.
Attachments
machine-unparking.nc
machine-unparking.nc
(223 Bytes) Downloaded 1665 times

Post Reply