#5021 is the current X position (in the Machine Coordinate System), and #5022 is the current Y position.
#7001 is the G110 X, #7002 = G110 Y, etc.
You should be able to probe the hole, move to the G110 zero, and execute the following command:
#7001=#5201 (SET G110 X)
#7002=#5202 (SET G110 Y)
It seems like a waste of motion to actually move to the WCS Zero, though. You should be able to "do the math" in the macro. |