Mach3 Ref All Home Script < TESTED >
' --- Home Y Axis --- Message "Homing Y Axis..." DoOEMButton(1035) ' Ref Y While IsMoving() Sleep 100 Wend
' --- Re-enable limits if disabled --- ' DoOEMButton(1021) ' Re-enable limits
' --- Home X Axis --- Message "Homing X Axis..." DoOEMButton(1034) ' Ref X While IsMoving() Sleep 100 Wend mach3 ref all home script
Implementation and Configuration of a Unified "Ref All Home" Script for Mach3 CNC Controllers
' --- Disable limits temporarily (optional but prevents false triggers) --- ' DoOEMButton(1021) ' Uncomment if needed: Disable limits ' --- Home Y Axis --- Message "Homing Y Axis
' --- Home Z Axis first --- Message "Homing Z Axis..." DoOEMButton(1033) ' Ref Z While IsMoving() ' Wait for Z to complete Sleep 100 Wend
' Mach3 - Ref All Home Script ' Sequence: Z, X, Y, A ' --- Safety Check: Ensure machine is not running --- If IsMoving() Then Message "Cannot home while machine is moving. Stop first." Exit Sub End If mach3 ref all home script
Paste the following script. This example includes safety checks.