Try
(Safe home)
G00 G91 G28 Z0.0
G00 G28 X0.0 Y0.0
G90
M1
M30



Slowley --SINGLE STEP ---RAPID Down
This should send the machine to Home

(ATC/APC/Loading Position)
G00 G91 G30 Z0.0
G00 G30 X0.0 Y0.0
G90
M1
M30

this will send the machine to 2nd ref position usually for an ATC or Pallet change position or loading if required