2
« on: December 09, 2008, 08:47:58 PM »
I've looked all thru this forum at all of the suggested ways to make a macro pause and I have not found the one that works for me... here goes
In a button script, I'm trying to move the spindle to a given point to zero X & Y, then run M6 to change the tool & zero Z and then perform some Gcode. Everything works as expected except the script does not pause to allow me to zero Z after the tool change.
Sub Main()
My script has a routine that allows me to jog to a point and zero X & Y (this parts works) then
XDist = GetUserDRO(1152)
Code "m06 T20"
Code "M03"
Code "S21000"
Code "G4 P2"
Code "G00x0.0000y0.000z.7500"
Code "G01z-.3125F10.0"
Code "G01x"XDist""
Code "G01x0.0000F30.0"
Code "G01z.7500"
Code "M05"
End Sub
The M6 sets the tool # in the proper box on the screen and the "Change tool" LED flashes green and red as it does when run in Gcode. I just can't get it to pause so I can do the "Auto Tool Zero" button.
Any suggestions? I have tried SystemWaitFor(Start) with no results.