1
VB and the development of wizards / Tool Zero Code w/ Wait for Probe Confirmation
« on: August 14, 2017, 12:02:54 PM »
I was wondering if someone could help with some code that I could add to my tool zero script which waits for you to touch the plate to the bit to confirm that your ground clip is connected. I ran my script yesterday and forgot to attach the ground clip and I ended up driving into the block before I could hit the stop. That made me start thinking that rather than rely on my memory it would be good to add that into the script.
I'm thinking it might be something like this:
Instead of a pause it would be better to wait until it sees the probe touch and then ask the operator to continue by clicking on a button or something.
Any suggestions?
I'm thinking it might be something like this:
Code: [Select]
Code "(Touch Z-Plate to bit)" 'this goes in the status bar
Code "G4 P1" 'Pause
If GetOemLed (825) <> 0 Then
Code "(I didn't see the Z-Plate)"
Exit Sub
End If
Instead of a pause it would be better to wait until it sees the probe touch and then ask the operator to continue by clicking on a button or something.
Any suggestions?