Machsupport Forum
Mach Discussion => Mach4 General Discussion => Topic started by: mofetters on December 14, 2014, 10:06:41 PM
-
I have been using the following auto tool zero script in Mach3 and I would like to port it over to Mach4. Any help would be appreciated.
Thanks,
Mark
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 P1" ' this delay gives me time to get from computer to hold probe in place
Code "G31Z-2 F2" '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, .0627) 'set the Z axis DRO to whatever is set as plate thickness
Code "G4 P0.25" 'Pause for Dro to update.
Code "G0 Z1" '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
-
Have you had any luck with this. I just started looking at this. I have the Triqueta zeroing block.
-
Have you looked at the touch module in 4? It was designed to be used with a touch plate.
https://www.youtube.com/watch?v=VA49atQNzmg
-
I did discover that last night. Tried it this morning and it would not work. I am using a pdmx 424 board and have the probe mapped to input3 which is the touch plate. But touch dialog shows inactive state. Looking at the input status indicators show the touch plate working. Not sure what I am doing wrong. Would love to get this working.
-
have the probe mapped to input3
Have you tried mapping it to the Probe input?
-
Yes input3 is mapped to the probe input
-
Looking at the input status indicators show the touch plate working
What input status indicators are you referring to? Is this in the PMDX diagnostics, Mach's diagnostics logging or the machine diagnostics tab of the screen set? There are also probe, probe 1, probe 2 and probe 3 leds above the touch button in the current default wx4, wx6 and wxRouter screen sets.
It sounds like you have the input signal incorrectly mapped but I could be wrong. Post a screen shot of the input configuration page with the signal your using for the probe in view.
-
I have watched this. Where can I get the touch module document that is referred too? I have looked for it and can not find it. The help menu item prints up a placeholder down no details.
-
The touch doc is in the docs folder. You must be running an old version?