Ok, do this:
open your Mach3, goto the Operator->Edit Button script
press the "Ref All Home" button it will open up a VB script editor.
Put this code in it.
DoButton( 24 )
DoButton( 23 )
DoButton( 22 )
DoButton( 25 )
While IsMoving()
Wend
Code("M990")
now hit the save button, then goto View->Save current layout, NOTE were not done yet.
Now go to Operator->VB Script Editor it will open the VB script editor
Put this code in the window (note if some code appears in it, just delete that code):
Code("G0 X 1.0 Y 1.0 Z 1.0")
While IsMoving()
Wend
SetOEMDRO(800,0)
SetOEMDRO(801,0)
SetOEMDRO(802,0)
Now, hit the "Save As" and call it "M990.m1s" NOTE: MAKE SURE that it is saving this macro to the macro folder that belongs to the profile you
are currently running!!!!!!!!!!!!!!!
hit the ok
Now your Mach3 should still be in its "Just opened it up and started it state" (i.e. the reset is still flashing), and the Ref LEDs should all be red.
now push the "Ref All" button, what it will do is this, it will first reference to your home switches, once there (ref leds turn green), it will call the Macro M990
Now M990 will run and it will move the machine to the position X = 1, Y = 1, Z = 1 at a G0 rate, once it reaches the position, it will "Zero" the work coordinates
of the X, Y, and Z to "0".
What YOU will need to do is open up the M990 in the VB script editor, and change the Positions I put in it to where YOU want it to stop at, if you need to add
more axis, then you now have an example.
scott