Machsupport Forum

Mach Discussion => VB and the development of wizards => Topic started by: Soorena123 on August 12, 2020, 11:45:20 PM

Title: Auto Tool Zero without Z surface
Post by: Soorena123 on August 12, 2020, 11:45:20 PM
Hello,

I have my auto tool button functioning fine with my probe however it does not help me when doing carvings and such that remove the surface z datum. What I want to be able to do is fixate the probe somewhere and do this:

Current tool -> click auto tool zero -> touch probe -> store Z value in variable -> Retract to g28 -1mm then:
Change tool -> click auto tool zero again -> touch probe -> set z value to stored value -> retract to g28 -1mm -> tool change complete -> cycle start continues the code

I have completely removed my M6start and m6end to avoid any collision. For some reason when it would return to previous location after tool change sometimes it would lower the z to the previous z and just dragged across the workpiece. This way when I am done I'm above the part and the g code will rapid to location before the toolpath start anyways so I'm safe.

Even if I could just have a simple script that goes to the probe and just touches it and waits for me that would even help. Right now what I am doing is touching it manually by jogging it down slowly and seeing the diagnostic probe button register the touch, then I write down the z value on paper, then I touch the next tool and enter in this value manually. This is unreliable and tedious because the registering of the touch is not precise or accurate its by hand.

I do programming but not visual basic. If anyone can tell me if this is even possible or if you have a better method to not have to rely on the z surface and still be able to change the tool properly using the probe fixated then please your help and suggestions are greatly appreciated!
Title: Re: Auto Tool Zero without Z surface
Post by: reuelt on September 12, 2020, 07:33:10 PM
You can  Set where you want to Measure the Tool.
Normally, the place that will not be machined.
1. In Mach3, Click "Settings (Alt-6)" on the Menu.
2. Then enter where you want in the X & Y DRO's
3. Under the "Tool Change Location" label.

You can use SIMPLE m6Start.m1s
with following contents:
   tool = GetSelectedTool()
   SetCurrentTool( tool )
   
   GageH = GetOEMDRO(1001)   
   
   Code"G0 G53 Z0"
   
   Xpos = GetUserDro(1200)
   Ypos = GetUserDro(1201)
   Code"G0 G53 X" & Xpos & "Y" & Ypos
   
cr = Chr(13)
msg = "Please Change The Tool" & cr  & cr & "Then Press [Auto Tool Zero]" & cr
msg = msg & "------- ------  -----------------------"  & cr  & cr
msg = msg & "Then Press [Cycle Start]"
MsgBox(msg)   


Title: Re: Auto Tool Zero without Z surface
Post by: ZASto on September 13, 2020, 06:35:38 AM
The easiest way is to use 2 (two) touch plates. One movable for setting first tool on top of your material and one atfixed position to measure each subsequent tool when you don't have the same Z0 level due to first carving.
All of that can be found in Big-Tex tool setter screen set.
Search this forum, I've posted a link for download.