; homeall.g ; called to home all axes G91 ; relative positioning G21 ; Set units to mm ;M584 X0.0 Y0.1:0.3 Z0.2:0.4 ; Apply drive mapping to axes G1 H1 Z{move.axes[2].max*2} F1500 ; move quickly to Z axis endstop and stop there (first pass) G1 H1 X{move.axes[0].max*2} F1500 ; move quickly to X axis endstops and stop there (first pass) G1 H1 Y{move.axes[1].max*2} F1500 ; move quickly to Y axis endstops and stop there (first pass) G92 X{move.axes[0].max} Y{move.axes[1].max} Z{move.axes[2].max} ; Set Home Position G1 X-3 Y-3 Z-3 F150 ; go back a few mm G1 H1 X{move.axes[0].max*2} F150 ; move slowly to X axis endstops once more (second pass) G1 H1 Y{move.axes[1].max*2} F150 ; move slowly to Y axis endstops once more (second pass) G1 H1 Z{move.axes[2].max*2} F150 ; move slowly to Z axis endstop once more (second pass) G92 X{move.axes[0].max} Y{move.axes[1].max} Z{move.axes[2].max} ; Set Home Position G90 ; absolute positioning