5
« on: March 31, 2022, 06:22:45 PM »
Hey guys. I've setup for Z zero touch plate. The Digitize DRO in Mach3 and the Data Monitor for the ESS are both indicating the "Touch".
But the script I found is not working. The Z axis starts it's move but has no reaction when the probe (Bit) hits the plate. Below is the script I found. Can someone point me to a better one or suggest a fix for the one I have?
CurrentFeed = GetOemDRO(818) 'Get the current feed rate to return to later
CurrentAbsinc = GetOemLED(48) 'Get current G90/G91 state
CurrentGmode = GetOemDRO(819) 'Get the current G0/G1 state
If GetOemLed (825)=0 Then 'Check to see if the probe is already grounded or faulty
DoOEMButton (1010) 'zero the Z axis so the probe move will start from here
Code "G4 P5" ' this delay gives me time to get from computer to hold probe in place
Code "G90 G31Z-2. F5" 'probing move, can set the feed rate here as well as how far to move
While IsMoving() 'wait while it happens
Wend
ZProbePos = GetVar(2002) 'get the axact point the probe was hit
Code "G0 Z" &ZProbePos 'go back to that point, always a very small amount of overrun
While IsMoving ()
Wend
Call SetDro (2, .192) 'set the Z axis DRO to whatever is set as plate thickness
sleep 200 'pause for Dro update.
Code "G1 Z1,F50" 'put the Z retract height you want here
Code "(Z axis is now zeroed)" 'puts this message in the status bar
Else
Code "(Z-Plate is grounded, check connection and try again)" 'this goes in the status bar if aplicable
Exit Sub
End If
Thanks.........dt
Mach3
CNC4PC bob
ESS
Win10