Hello Guest it is October 15, 2019, 08:11:29 AM

Author Topic: Auto Tool zero. Which Input etc. do I Use?  (Read 13123 times)

0 Members and 1 Guest are viewing this topic.

Auto Tool zero. Which Input etc. do I Use?
« on: August 26, 2008, 06:17:44 AM »
Hi,

The never ending saga of tool Tool zeroing!

I think I understand the macro posted elsewhere.

My questions are:
How and/or which pin do you wire the touch plate into the parallel port input.

How does the macro read the touch signal?

Is there somewhere I can find a how to it guide to setting up this common and popular feature in Mach3 mill. I know the videos explain (similar macros, but I cannot find a tutorial or guide on how to set up the hardware, screen buttons etc. to implement this common feature.
I am sure many starting out using Mach3 would welcome insight into how to easily do this. (There has been many posts on this and similar topics) I know it will encourage me to try other in house enhancement of my machine.

I appreciate any help on this post.

Thanks,


Bruce

(very keen Mach3 cnc-er)

Offline jimpinder

*
  •  1,233 1,233
  • Wakefield, West Yorks, UK
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #1 on: August 26, 2008, 12:04:36 PM »
If you look on the list of Ports and Pins/Input Pins then whatever pin you allocate to "Probe" is the one.

I haven't used this feature (yet) but I assume that if it is then "earthed" then movement on the aixis will stop.
I would try it and see. What I have seen of this is that the pin is connected to the pad. The tool (which should be earthed)comes down and touches the pad and the axis stops.

I can't really say much more - I am sure someone who uses it will comment.

Not me driving the engine - I'm better looking.

Offline budman68

*
  • *
  •  2,360 2,360
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #2 on: August 26, 2008, 12:09:01 PM »
Yes, Jim is correct but as for what exact pin you use depends on your setup. Depending on what BOB you use, the pins can be different from card to card or setup to setup so it's up to you to read your manual to find out what available input pins you can use.

Hope that helps-  :)
Dave
----------------------------------------------------------------------
Just because I'm a Global Moderator, don't assume that I know anything !

Dave->    ;)

Offline Chaoticone

*
  • *
  •  5,605 5,605
  • Precision Chaos
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #3 on: August 26, 2008, 01:41:43 PM »
Yup, Jim is right. I use my probe input. I have a piece of printed circuit board with a wire soldered to one side of the copper clad. This is landed on the input I assigned my probe to. So, it is hot and my tool in my spindle is the ground that sinks the voltage on the printed circuit board to 0. The probe pin is set up as active low so when it sees the change from 5V to 0, Mach considers it made. Adding a VB button in screen 4 is not bad at all to do. Once you have that you can make code to do as you wish. I have posted my Auto tool touch off button code below.


'Auto Tool Touchoff

CurrentFeed = GetOemDRO(818) 'Get the current feedrate.
PlateThickness =0.059
ProbeFeed = 5


Code "G90 F" &ProbeFeed

If GetOemLed (825)=0 Then
Code "G4 P2" 'Time to get to the z-plate
Code "G31Z-5 F" &ProbeFeed
While IsMoving()
Wend
Code "G4 P0.25"
ZProbePos = GetVar(2002)
Code "G0 Z" &ZProbePos
While IsMoving ()
Wend
Call SetDro (2, PlateThickness)
Code "G4 P0.5" 'Pause for Dro to update.
Code "G0 Z0.25" 'Change the Z retract height here
Code "(Z axis is now zeroed)"
Code "F" &CurrentFeed
Else
Code "(Z-Plate is grounded, check connection and try again)"
Exit Sub
End If   
     

Brett
;D If you could see the things I have in my head, you would be laughing too. ;D

My guard dog is not what you need to worry about!
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #4 on: August 26, 2008, 04:35:36 PM »
Thankyou,

I will try the probe input tonight.

Another quickie: do you put the VB script "directly in the Button" or do you store the VB script as a Macro M********* and call the Macro M********* from the button?
If it can be stored as a Macro can you please tell me the correct VB code to call this Macro. Is it "Call M*********" I tried this and it has not worked for me- maybe the syntax is wrong?



Thanks again,

Bruce

Offline Chaoticone

*
  • *
  •  5,605 5,605
  • Precision Chaos
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #5 on: August 26, 2008, 04:39:56 PM »
In screen 4 you'll make it a vb button. When you open the screen from Mach, go to the top, operator, edit button script. At this point the button starts blinking. Click on it, paste the code in and save and exit.

Brett
;D If you could see the things I have in my head, you would be laughing too. ;D

My guard dog is not what you need to worry about!

Offline Greolt

*
  •  956 956
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #6 on: August 26, 2008, 11:56:23 PM »

Another quickie: do you put the VB script "directly in the Button" or do you store the VB script as a Macro M********* and call the Macro M********* from the button?



Bruce

If you want to use the zero script from more than one on screen button (Might have one on offsets page for example)

or you want to call it from a pendant, then it is smarter to have it in the macros folder and call it from the various buttons etc.

Any fine tuning you do to the script can be done in the one place instead of several.  Easily forgotten.  Don't ask how I know.   ;D

Greg

Offline josh

*
  •  99 99
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #7 on: August 27, 2008, 12:14:57 AM »
interesting subject,
thats because I want to see if anyone can post pictures off how they went about doing the set up
I have no electronic skills so if anybody has time can you please post some pictures of your plate and
how its wire ,
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #8 on: August 27, 2008, 07:02:53 PM »
Thanks Greg,

Still having trouble getting it sorted - it should be easy I know.

1. I have assigned the probe input to a Parallel port input.  eg. +5V on pin12 when in normal state.  The input from the touch plate will
    ground pin 12 and should make the probe input true.
2. Grounding pin 12 makes the led on the Diagnostic screen work OK . (so far so good)
3. The VB script has been installed into the "Auto Tool Zero Button" on the Program Run Screen
4.  Pressing the Auto tool Zero starts the Z axis moving down.  ( so far very good!)
5. Grounding Pin 12  does nothing! The Z just keep going down till it reaches the minimum value set in the VB Script (somethings amiss here - not very good!)

What line of VB code picks up the input from pin 12?

What code do I need to place into the Auto Tool Zero Button to "Call a Macro" instead of just running the VB Script directly from the button.


Thanks for all help.

I will post a little "How to" Tutorial when I overcome these problems that I am sure others have encountered.

Bruce,
« Last Edit: August 27, 2008, 07:05:26 PM by MachBruce »

Offline Greolt

*
  •  956 956
    • View Profile
Re: Auto Tool zero. Which Input etc. do I Use?
« Reply #9 on: August 27, 2008, 07:09:37 PM »

2. Grounding pin 12 makes the led on the Diagnostic screen work OK . (so far so good)



Does the "Digitise" LED light up when you ground the touch plate?

The code to call a macro is simply    M615  or whatever the number is.

Greg
« Last Edit: August 27, 2008, 07:11:43 PM by Greolt »