Need Help! How to get my tool length sensor to work in Mach3?


Results 1 to 18 of 18

Thread: How to get my tool length sensor to work in Mach3?

  1. #1
    Member
    Join Date
    Sep 2012
    Location
    Hong Kong
    Posts
    15
    Downloads
    0
    Uploads
    0

    Default How to get my tool length sensor to work in Mach3?

    Hi,

    I have a tool sensor that came together with my machine.How to get my tool length sensor to work in Mach3?-taster_laengentaster_werkzeugtaster_nullpunkttaster_3-jpg

    Mach3 has no problem detecting the sensor after I enter the appropriate settings(LPT:1, Pin:15) under the Ports and Pins page.
    Probe led under Diagnostics page lights up when sensor plate is depressed.

    Next, how do I get the Mach3 to move the tool to the location of the sensor?
    Do I need to inform Mach3 the sensor height? The touch plate on the sensor is designed to be depressed slightly when a tool is lowered onto it. Do I need to find out the travel of that slight depression?

    Similar Threads:


  2. #2
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    I advise you to read the manual. Especially pages 124 and onward, starting from chapter "10.7.12 Straight probe - G31" but in general, yes, Mach3 must know the position of your sensor, otherwise it can't find it and yes, Mach3 must also know the exact height of your tool setter. BTW, I find those tool setters pretty pointless. They are too large to be of any use. A simple piece of copper, or almost any other material with a known height (thickness) is just as good and is easier to handle. Personally I am in most cases not interested in the length of tools or the table surface position. I set the Z0 to the top of the work piece most of the time, some times use the bottom of the work piece as Z0 reference but almost never the table surface.



  3. #3
    Member
    Join Date
    Sep 2012
    Location
    Hong Kong
    Posts
    15
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by A_Camera View Post
    I advise you to read the manual. Especially pages 124 and onward, starting from chapter "10.7.12 Straight probe - G31" but in general, yes, Mach3 must know the position of your sensor, otherwise it can't find it and yes, Mach3 must also know the exact height of your tool setter. BTW, I find those tool setters pretty pointless. They are too large to be of any use. A simple piece of copper, or almost any other material with a known height (thickness) is just as good and is easier to handle. Personally I am in most cases not interested in the length of tools or the table surface position. I set the Z0 to the top of the work piece most of the time, some times use the bottom of the work piece as Z0 reference but almost never the table surface.
    Finding out the height of the sensor is easy. But, do I also need to find out how deep the touch plate on top of the sensor depress when the tool is set onto it?

    Honestly, I regret buying this machine but I can't throw it away after spending so much money. Only option now is to use this machine to make enough money to buy a proper mill.
    I just take it as an expensive lesson for a newbie like me.



  4. #4
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by oddodd View Post
    Finding out the height of the sensor is easy. But, do I also need to find out how deep the touch plate on top of the sensor depress when the tool is set onto it?
    Well... that depends on the accuracy you need and how fast your machine stops, but generally speaking no, you don't need that information because your Z descend should stop fast enough, a few microseconds after the tool touches the top of your tool setter, so it should not get depressed. I don't know if your tool setter is a switch based one, or just a dumb plate with a spring underneath which can be depressed, I hope it is the later. A touch plate is normally working on contact with the tool, signalling Mach3 to stop on contact and then you have your Z zeroed. Of course, the height of the plate (your tool) must be entered as a Z offset to get the table, or work material surface as Z0.

    In Mach3 G code the G31 is the command, so G31 Z-2 F10 would for example lower the Z with feed rate 10 until it reaches -2 or the touch plate is hit, whichever comes first. If the touch plate is hit you can click on the Zero Z button and in the offset you enter the height of the toll setter. Of course, you do that normally through a macro so all that is automatic. It is important that the F value is not too high otherwise the Z will not be stopped fast enough and your tool will depress the tool setter far too much to be of any use. Try it out in the air first, just in case...

    Quote Originally Posted by oddodd View Post
    Honestly, I regret buying this machine but I can't throw it away after spending so much money. Only option now is to use this machine to make enough money to buy a proper mill.
    I just take it as an expensive lesson for a newbie like me.
    Sorry that you are not happy but a "proper mill" is probably much more expensive than this machine. You get what you pay for is I think a valid assumption.



  5. #5
    Member
    Join Date
    Sep 2012
    Location
    Hong Kong
    Posts
    15
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by A_Camera View Post
    Well... that depends on the accuracy you need and how fast your machine stops, but generally speaking no, you don't need that information because your Z descend should stop fast enough, a few microseconds after the tool touches the top of your tool setter, so it should not get depressed. I don't know if your tool setter is a switch based one, or just a dumb plate with a spring underneath which can be depressed, I hope it is the later. A touch plate is normally working on contact with the tool, signalling Mach3 to stop on contact and then you have your Z zeroed. Of course, the height of the plate (your tool) must be entered as a Z offset to get the table, or work material surface as Z0.

    In Mach3 G code the G31 is the command, so G31 Z-2 F10 would for example lower the Z with feed rate 10 until it reaches -2 or the touch plate is hit, whichever comes first. If the touch plate is hit you can click on the Zero Z button and in the offset you enter the height of the toll setter. Of course, you do that normally through a macro so all that is automatic. It is important that the F value is not too high otherwise the Z will not be stopped fast enough and your tool will depress the tool setter far too much to be of any use. Try it out in the air first, just in case...
    Thank you very much A_Camera, you are so much help than the support department of the company that I bought the mill from. I appreciate all the help you've given.
    Am I right to say that all I need now is add a script or macro to Mach3 to get everything working?




    Quote Originally Posted by A_Camera View Post
    Sorry that you are not happy but a "proper mill" is probably much more expensive than this machine. You get what you pay for is I think a valid assumption.
    I was actually torn between Tormach and my current mill had enough funds for either machine, with the Tormach costing only 1K+ more than my mill. Somehow I decided to base my decision on which machine has the biggest work area. Well, the rest is history.
    And I wish I can be a deaf when people tell me I overpaid for my current machine
    Well, just have learn from mistake and move on.



  6. #6
    Member
    Join Date
    Mar 2016
    Location
    Poland
    Posts
    322
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    You don't need to know the height of a sensor. Of course it is good to know, but it's not must to.
    You can always assume length of one tool that You use to measure part zero and then use it also as reference for toolsetter.



  7. #7
    Member
    Join Date
    Sep 2012
    Location
    Hong Kong
    Posts
    15
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by steryd View Post
    You don't need to know the height of a sensor. Of course it is good to know, but it's not must to.
    You can always assume length of one tool that You use to measure part zero and then use it also as reference for toolsetter.
    Thanks for the tip!



  8. #8
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by steryd View Post
    You don't need to know the height of a sensor. Of course it is good to know, but it's not must to.
    You can always assume length of one tool that You use to measure part zero and then use it also as reference for toolsetter.
    How do you know EXACTLY where the table top or the top of your work piece is if you don't know the height of the tool setter?



  9. #9
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by oddodd View Post
    Thank you very much A_Camera, you are so much help than the support department of the company that I bought the mill from. I appreciate all the help you've given.
    Am I right to say that all I need now is add a script or macro to Mach3 to get everything working?
    Yes, just paste a macro in the proper button VB macro window and you are all ready to go. If you want I can post the one I am using, but the web is full of different type of VB macro for tool setting/auto zero Z.

    Anyway, good luck.



  10. #10
    Member
    Join Date
    Mar 2016
    Location
    Poland
    Posts
    322
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    You don't know, but You don't need to know as long as Yo keep connection to one reference.
    When You work with one tool and assume it as 0 length, then You can make zero level at part or by milling it's top plane or by measuring it with tool.
    Then the length of another tool is just a difference between their lengths, and you just have to change coordinates due to this difference(of course mach does it for You), not to some specific point on table.

    Anyway only proper way to calibrate toolsetter is to do it with reference tool.

    Last edited by steryd; 03-24-2016 at 02:25 PM. Reason: Precising


  11. #11
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by steryd View Post
    You don't know, but You don't need to know as long as Yo keep connection to one reference.
    When You work with one tool and assume it as 0 length, then You can make zero level at part or by milling it's top plane or by measuring it with tool.
    Then the length of another tool is just a difference between their lengths, and you just have to change coordinates due to this difference(of course mach does it for You), not to some specific point on table.

    Anyway only proper way to calibrate toolsetter is to do it with reference tool.
    It seems extremely complicated to me. I understand that you can use any tool and call that zero length and reference all the others from that tool plus or minus direction, but that does not tell you where wour work piece starts, where it's top or bottom is. You have to guess or have to find it manually.

    Normally I use the top (or the bottom) of the work piece as a reference, in some cases surfacing it first, in other cases not, but the length of the tool is not interesting to me at all, the interesting thing is WHERE a certain tool is going to hit the work surface or where it should end it's work. I don't have any specific known point on my table, no home position, no ATC, so this I think is the easiest way to work, especially if I need to make several identical objects and need to change tool and work piece often. It is always necessary to find and define X and Y zero positions anyway, so setting Z zero takes just a few seconds extra.

    I don't use a tool setter, use only an aluminum block which I measured accurately (as accurate as I can measure) and a PC board piece with copper layer on one side, which I also measured as accurate as I can. When the tool touches the surface the Z zero is set and that's it. Takes a few seconds and everything is fine.



  12. #12
    Member
    Join Date
    Sep 2012
    Location
    Hong Kong
    Posts
    15
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by A_Camera View Post
    Yes, just paste a macro in the proper button VB macro window and you are all ready to go. If you want I can post the one I am using, but the web is full of different type of VB macro for tool setting/auto zero Z.

    Anyway, good luck.
    Can you post the VB macro please? Thank you very much!



  13. #13
    Member
    Join Date
    Mar 2016
    Location
    Poland
    Posts
    322
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    A_Camera You're describing the same method. You use aluminium piece as reference, but You always can use a workpiece top surface. It will be the same. BTW how do You find out where is Your workpoece CS by measurong some (evem super accurate) piece of metal? Youhave to find it with measured tool anyway right?



  14. #14
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by oddodd View Post
    Can you post the VB macro please? Thank you very much!
    Code:
    CurrentFeed = GetOemDRO(818)
    
    ZMove = 20.00 'Total lenght of Probe to move before Stop or no Contact Made.
    ZOffset = 1.47 ' Plate Hight
    ZSal = ZOffset + 2.00 '+ Free Hight, Will position the probe 2 mm over the material.
    
    StopZmove = 0
    If GetOemLed (825)=0 Then
     DoOEMButton (1010)
     Code "G31 Z-"& ZMove & "F40"
     While IsMoving()
      Sleep(200)
     Wend
     Probepos = GetVar(2002)
     
    
    ' Improve accuracy
    
     Code "G0 Z" & Probepos + 0.5 ' Move back a bit to get a new reading
     While IsMoving()
      Sleep(200)
     Wend
     Code "G31 Z-" & ZMove & "F4" ' Move very slow for greater accuracy
     While IsMoving()
      Sleep(200)
     Wend
    
     Probepos = GetVar(2002) ' Z var for probe 
      
     If Probepos = - ZMove Then
      responce = MsgBox ("**ERROR** " , 4 , "Probe **ERROR**" )
      Code "G0 Z10"
      StopZmove = 1
      Code "F" &CurrentFeed
     End If
     If StopZmove = 0 Then
      Code "G0 Z" & Probepos
      While IsMoving ()
       Sleep (200)
      Wend
      Call SetDro (2, ZOffset)
      Code "G0 Z" & ZSal
      While IsMoving()
       Sleep(200)
      Wend
      Code "(Z zeroed)"
      Code "F" &CurrentFeed
     End If
    Else
     Code "(Check Ground Probe)"
    End If
    Exit Sub
    '-------------------
    Take the code above, copy everything and paste it into the "Auto Tool Zero" button macro. Before you close the file and save changes you need to enter the probe height, i.e. replace 1.47 with your probe (tool setter) height. Make sure you test BEFORE you run it, because if something went wrong during your copy/paste/change than the machine might crash your tool setter. Remember that the tool you are using must be connected to one end of the toll setter and the top of the tool setter must be the ground. Check before the first run that your Digitize LED gets lit when the probe (your tested end mill or drill bit) touches the tool setter. Note that the macro is for mm units.

    The way to use it:

    1. Position the end mill near the top of the tool setter, about 2mm above.
    2. Make sure the tool setter and the end mill is connected to the BoB GND and the input pin you defined as probe.
    3. Click on the Auto Tool Zero button in Program Run screen. The end mill will slowly descend towards the top of the tool setter and will stop as soon as it touches, move up again a tiny bit (0.5mm above the stop) and descend the second time. Once it touches the top of the tool setter surface a second time it will retract 2mm above the top of the tool setter and stop. At the same time your Z DRO will be set to the tool setter height plus 2 mm, so at the command "G0 Z0" Z will be lowered to the surface, the bottom of the tool setter. If the tool (end mill) is not touching the the top of the tool setter the movement will stop if the Z reaches the 20mm depth. Change that value if you want something else there, but make sure the value is right.



    Note: Be careful. If you change anything else in my macro or enter the wrong values somewhere then something can seriously go wrong or the macro stops working.

    Good luck.



  15. #15
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1899
    Downloads
    2
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by steryd View Post
    A_Camera You're describing the same method.
    No I am not. In my case you MUST know the height of the tool setter, and you say I must not.

    Quote Originally Posted by steryd View Post
    You use aluminium piece as reference, but You always can use a workpiece top surface. It will be the same.
    You can do that ONLY if your workpiece surface is metal and that is by far not the case most of the time for me. I work mostly with plastics, so I need a conductive surface. That surface in this thread is the tool setter. Of course, if I am milling aluminum I don't need to use a tool setter, just connect the surface.

    Quote Originally Posted by steryd View Post
    BTW how do You find out where is Your workpoece CS by measurong some (evem super accurate) piece of metal? Youhave to find it with measured tool anyway right?
    Again, I don't understand your question. Perhaps if I have time during the weekend I make a short video to show how I X, Y and Z zero, as well as the centre of a piece in X, Y or X and Y direction.



  16. #16
    Member
    Join Date
    Jan 2018
    Location
    Greece
    Posts
    5
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Hey,
    I have same setup,I suppose you have cnc step.Did you figure how tool length sensor it works?

    Στάλθηκε από το Lenovo P1ma40 μου χρησιμοποιώντας Tapatalk



  17. #17
    Member
    Join Date
    Jan 2018
    Location
    Greece
    Posts
    5
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Quote Originally Posted by oddodd View Post
    Can you post the VB macro please? Thank you very much!
    Hey.
    Did you figure out how it works?I have the same tool lenght sensor with Heiz cnc machine



  18. #18
    Member Bazzer's Avatar
    Join Date
    Apr 2016
    Location
    United Kingdom
    Posts
    102
    Downloads
    0
    Uploads
    0

    Default Re: How to get my tool length sensor to work in Mach3?

    Alexcrafts

    Here is what I do with Heiz S-1000T for tool height meaurement.

    This is with the Kinetic NC software and Heiz tool height switch.

    I have the tool test switch at the 0,0 point in X,Y

    I put the tool into the spindle and run this short programme

    %
    T1 M66
    G79
    M30

    M66 is the manual tool change macro

    G79 is the tool length measurement.

    After running this the tool length for T1 will be updated.

    Now take the tool tip to the workpiece point where you want Z zero to be (often on the top of the material), touch the workpiece with the tool and Z zero again, in Kinetic NC it will automatically be in G54 when doing this.

    Now load your programme which should look like this

    %
    G90
    G28
    G64
    T1 M66
    G79
    M3
    Your code for part here
    M30

    This tests the tool again and then starts work.

    Every time you have a tool change the programme should look like this.

    T2 M66
    G79

    I regulary run jobs with 6 or 7 tool changes.

    With this process you can just put a new piece of material in after the first job and if it is the same thickness there is no need to update the tool height, everything just works.

    I expect Mach 3 will be similar.

    Regards

    Barrie
    How to get my tool length sensor to work in Mach3?-extract-hood-1-jpg

    Attached Thumbnails Attached Thumbnails How to get my tool length sensor to work in Mach3?-extract-hood-1-jpg  
    Barrie @ Composite Specialities Ltd. using BobCAD V30 Mill 3 axis Pro, Bricscad V14 and MOI V3 with CNC-Step High Z 1000S and Wabeco CC-F1210


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

How to get my tool length sensor to work in Mach3?

How to get my tool length sensor to work in Mach3?