586,094 active members*
4,097 visitors online*
Register for free
Login
IndustryArena Forum > WoodWorking Machines > DIY CNC Router Table Machines > Z Axis changes coordinates mid program
Page 1 of 2 12
Results 1 to 20 of 29
  1. #1
    Join Date
    Mar 2009
    Posts
    45

    Z Axis changes coordinates mid program

    Hi guys,
    I ran into a problem with my machine. While running a program, the machine changes its Z Axis coordinates and does not plunge into the part, instead it is rising higher between layers.
    My machine is a DIY gantry router with 4th axis, 1605 ball screws, 20- series linear rails, controller is Adtech CNC4640, linear axis' are driven by 750W and 1kW servos, 4th axis is driven by 400W servo with 28:1 ratio gearbox.
    Pictures show the screen of the controller while running program. Several times during program, the Z axis coordinate changes, seemingly by 5mm at a time.
    The program consists of multiple tool paths created in Fusion 360, each tool path is 3d Adaptive Clearing, and is oriented in 90 degree increments of the A Axis. So, at the beginning, the machine runs the first tool path, then indexes A Axis into another position, then runs next portion, etc.
    During first tool path, the Z axis changed its coordinate maybe 20 times and ended up running at 100 mm above the part. After A-axis rotated, the machine started running second portion of the program like nothing happened, happily, at the right height. Then, some time later, it shifted again, and that's when are the pictures from.
    I checked the G code and there is no G commands other than G01 G02 G03 between Z axis shifts.
    Any help is appreciated.
    Thanks

  2. #2
    Join Date
    Mar 2003
    Posts
    35538

    Re: Z Axis changes coordinates mid program

    I know nothing about that controller, but it looks like a bug, if it's moving somewhere other than the commanded position. Are there any tool length offsets being used?
    Gerry

    UCCNC 2017 Screenset
    http://www.thecncwoodworker.com/2017.html

    Mach3 2010 Screenset
    http://www.thecncwoodworker.com/2010.html

    JointCAM - CNC Dovetails & Box Joints
    http://www.g-forcecnc.com/jointcam.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  3. #3
    Join Date
    Mar 2009
    Posts
    45

    Re: Z Axis changes coordinates mid program

    I use tool length setter, the settings for it have Z axis offset, which is a height difference between the tool setter and the part origin. When i execute tool check command, the coordinates are being recorded automatically in G54.

  4. #4
    Join Date
    Jan 2005
    Posts
    15362

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by robotek View Post
    I use tool length setter, the settings for it have Z axis offset, which is a height difference between the tool setter and the part origin. When i execute tool check command, the coordinates are being recorded automatically in G54.
    G54 X---- and Y----- axis is your work Offset position

    Tool length is set in the G43 tool Offset page

    Your Program is incorrect or your tool / work setting

    The program is doing what you are telling it to do Z+ = up Z-=down so you have Z+ moves so the Z axis is going to move up.

    Make sure in your drawing you have your work piece Zero to the top of the part, and the tool is set to the top of the part, then you program will have all Z- = down
    Mactec54

  5. #5
    Join Date
    Mar 2009
    Posts
    45
    Quote Originally Posted by mactec54 View Post
    G54 X---- and Y----- axis is your work Offset position

    Tool length is set in the G43 tool Offset page

    Your Program is incorrect or your tool / work setting

    The program is doing what you are telling it to do Z+ = up Z-=down so you have Z+ moves so the Z axis is going to move up.

    Make sure in your drawing you have your work piece Zero to the top of the part, and the tool is set to the top of the part, then you program will have all Z- = down
    Thank you for your input. I really appreciate it! I’m kind of new to all this and sometimes I think I got in over my head. The only way now is forward. I checked the NC program and it has G43 commands at the beginning of every tool path, right after indexing the A Axis. This explains why the tool paths start at the right height. The puzzling thing in all this is Z-Axis “creeping” up as it progresses through the code. I ran smaller jobs on the machine and this didn’t happen then.

  6. #6
    Join Date
    Mar 2009
    Posts
    45
    I set my part’s center point at the bottom as the origin and the attachment point to the machine. Because, when I set front corner as such, the z axis plunged right down after A-axis rotation.

  7. #7
    Join Date
    Jan 2005
    Posts
    15362

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by robotek View Post
    I set my part’s center point at the bottom as the origin and the attachment point to the machine. Because, when I set front corner as such, the z axis plunged right down after A-axis rotation.
    I did not see that you where using a rotating 4th Axes.

    When you are using a 4th axis it is quite normal to use the center of the part not the bottom of the part as Z zero, but it also can be the top of the part if it has a referance point to the finished part.

    Your drawing and work, both must match how you want to machine it.

    Most tool setters unless it is a probe are a waste of money, this too could be where part of your problem is, in the setup as well.
    Mactec54

  8. #8
    Join Date
    Mar 2009
    Posts
    45
    Quote Originally Posted by mactec54 View Post
    I did not see that you where using a rotating 4th Axes.

    When you are using a 4th axis it is quite normal to use the center of the part not the bottom of the part as Z zero, but it also can be the top of the part if it has a referance point to the finished part.

    Your drawing and work, both must match how you want to machine it.

    Most tool setters unless it is a probe are a waste of money, this too could be where part of your problem is, in the setup as well.
    Sorry, my last reply I just pressed a wrong button.
    I actually find tool length probe very useful. Especially, when having to use multiple tools on one part.
    The thing about my issue is that G code is not changing, it’s still tells the machine to go to certain height, layer after layer, but the machine is like hitting an invisible “floor” and bouncing higher.

  9. #9
    Join Date
    Jan 2005
    Posts
    15362

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by robotek View Post
    Sorry, my last reply I just pressed a wrong button.
    I actually find tool length probe very useful. Especially, when having to use multiple tools on one part.
    The thing about my issue is that G code is not changing, it’s still tells the machine to go to certain height, layer after layer, but the machine is like hitting an invisible “floor” and bouncing higher.
    Probing is fine as I said, you said you had a Tool setter which is part of your problem if you have a tool setter, the rest of the problem is in the programing
    Mactec54

  10. #10
    Join Date
    Mar 2009
    Posts
    45
    Quote Originally Posted by mactec54 View Post
    Probing is fine as I said, you said you had a Tool setter which is part of your problem if you have a tool setter, the rest of the problem is in the programing
    I called the tool probe a Tool Setter, my mistake. Can you suggest anything on how to identify problems in the program? Thanks

  11. #11
    Join Date
    Jan 2013
    Posts
    228

    Re: Z Axis changes coordinates mid program

    It sounds like you are losing steps in the z- direction there could be a few causes:

    Since it's always creeping up, I think you may be trying to drive your tool into the work to fast, causing Z to skip. Are you moving Z down in a ramp motion, or straight down? Are you using a center cutting bit? Is it a large diameter bit? is it dull? Try running the code without any stock (air cutting) and see if your Z axis is correct at the end of the cycle. If it is this is most likely the culprit. If not you need to look for something else:

    - Noise on your Z axis wires, But generally this would cause loss in either direction, so sometime it would be to high, sometimes to low, so I don't think this is it
    - cumulative error from back lash, You would need to do a bunch measurements to see if you have some backlash that is affected by gravity causing your axis to creep
    - trying to drive your Z to fast and missing pulses, try cutting the feedrate in half and see if the issue goes away

    Let us know the result of your testing and we can suggest some fixes.

    edit: Also add a few pics of your machine, and it's Z axis, someone may spot something else to look at

  12. #12
    Join Date
    Jan 2005
    Posts
    15362

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by TTalma View Post
    It sounds like you are losing steps in the z- direction there could be a few causes:

    Since it's always creeping up, I think you may be trying to drive your tool into the work to fast, causing Z to skip. Are you moving Z down in a ramp motion, or straight down? Are you using a center cutting bit? Is it a large diameter bit? is it dull? Try running the code without any stock (air cutting) and see if your Z axis is correct at the end of the cycle. If it is this is most likely the culprit. If not you need to look for something else:

    - Noise on your Z axis wires, But generally this would cause loss in either direction, so sometime it would be to high, sometimes to low, so I don't think this is it
    - cumulative error from back lash, You would need to do a bunch measurements to see if you have some backlash that is affected by gravity causing your axis to creep
    - trying to drive your Z to fast and missing pulses, try cutting the feedrate in half and see if the issue goes away

    Let us know the result of your testing and we can suggest some fixes.

    edit: Also add a few pics of your machine, and it's Z axis, someone may spot something else to look at
    Anything is possible, if you look at the program though it has Z positive moves, so the Z axis is going to move up and away from the cutting surface.
    Mactec54

  13. #13
    Join Date
    Mar 2009
    Posts
    45
    Quote Originally Posted by TTalma View Post
    It sounds like you are losing steps in the z- direction there could be a few causes:

    Since it's always creeping up, I think you may be trying to drive your tool into the work to fast, causing Z to skip. Are you moving Z down in a ramp motion, or straight down? Are you using a center cutting bit? Is it a large diameter bit? is it dull? Try running the code without any stock (air cutting) and see if your Z axis is correct at the end of the cycle. If it is this is most likely the culprit. If not you need to look for something else:

    - Noise on your Z axis wires, But generally this would cause loss in either direction, so sometime it would be to high, sometimes to low, so I don't think this is it
    - cumulative error from back lash, You would need to do a bunch measurements to see if you have some backlash that is affected by gravity causing your axis to creep
    - trying to drive your Z to fast and missing pulses, try cutting the feedrate in half and see if the issue goes away

    Let us know the result of your testing and we can suggest some fixes.

    edit: Also add a few pics of your machine, and it's Z axis, someone may spot something else to look at
    Thank you. I use 750W servo on Z Axis. Strongly believe it’s not losing steps. Besides, it’s doing it while dry run.

  14. #14
    Join Date
    Mar 2009
    Posts
    45
    I’ll try and attach some pictures tomorrow, from my computer. Phone seem to have trouble doing it.

  15. #15
    Join Date
    Jan 2013
    Posts
    228

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by robotek View Post
    I’ll try and attach some pictures tomorrow, from my computer. Phone seem to have trouble doing it.
    It's hard to know what the application is doing based on one line of code. In your image, on the right hand side, could you translate what is written above the positions?

    Another way to test if it's the code, is to write a simple routine where it moves around and returns to the starting position:

    (Untested code, verify it's correct for your machine before using)
    G90
    G00 X500 Y500 Z500
    G00 Z100
    G00 X100
    G00 Y100
    G91 F1000
    G01 X-400 Y-400 Z-400

    If it returns to original position, then try putting it in a loop for 100 times and see if it returns to the original position. If it does, then you probably have an issue with your file. Perhaps a tool setting or a incorrect tool offsets.

    Can you run other files that don't have this problem?

  16. #16
    Join Date
    Jan 2005
    Posts
    15362

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by robotek View Post
    Thank you. I use 750W servo on Z Axis. Strongly believe it’s not losing steps. Besides, it’s doing it while dry run.
    Servo's don't lose steps.
    Mactec54

  17. #17
    Join Date
    Jan 2005
    Posts
    15362

    Re: Z Axis changes coordinates mid program

    Quote Originally Posted by TTalma View Post
    It's hard to know what the application is doing based on one line of code. In your image, on the right hand side, could you translate what is written above the positions?

    Another way to test if it's the code, is to write a simple routine where it moves around and returns to the starting position:

    (Untested code, verify it's correct for your machine before using)
    G90
    G00 X500 Y500 Z500
    G00 Z100
    G00 X100
    G00 Y100
    G91 F1000
    G01 X-400 Y-400 Z-400

    If it returns to original position, then try putting it in a loop for 100 times and see if it returns to the original position. If it does, then you probably have an issue with your file. Perhaps a tool setting or a incorrect tool offsets.

    Can you run other files that don't have this problem?
    That is code that you would not want to use to check your machine
    Mactec54

  18. #18
    Join Date
    Mar 2009
    Posts
    45
    Quote Originally Posted by mactec54 View Post
    Servo's don't lose steps.
    I know. I said that to kindly let know that losing steps is not my machine’s problem.

  19. #19
    Join Date
    Mar 2009
    Posts
    45
    Quote Originally Posted by TTalma View Post
    It's hard to know what the application is doing based on one line of code. In your image, on the right hand side, could you translate what is written above the positions?

    Another way to test if it's the code, is to write a simple routine where it moves around and returns to the starting position:

    (Untested code, verify it's correct for your machine before using)
    G90
    G00 X500 Y500 Z500
    G00 Z100
    G00 X100
    G00 Y100
    G91 F1000
    G01 X-400 Y-400 Z-400

    If it returns to original position, then try putting it in a loop for 100 times and see if it returns to the original position. If it does, then you probably have an issue with your file. Perhaps a tool setting or a incorrect tool offsets.

    Can you run other files that don't have this problem?
    I did something similar when tested the machine’s max speeds and stuff. It can go 20m/min and accelerate and stop almost instantaneously without any problems.

  20. #20
    Join Date
    Mar 2009
    Posts
    45

    Re: Z Axis changes coordinates mid program

    pictures attached

Page 1 of 2 12

Similar Threads

  1. Recalibrating machine coordinates mid job
    By jbvries in forum Mach Mill
    Replies: 0
    Last Post: 11-03-2015, 03:43 PM
  2. Program coordinates
    By Kristy in forum FlashCut CNC
    Replies: 2
    Last Post: 01-19-2011, 09:31 PM
  3. setting work coordinates through program
    By lsrengineering in forum Haas Mills
    Replies: 2
    Last Post: 06-08-2010, 03:07 PM
  4. Program Restart in mid program?
    By Donkey Hotey in forum Haas Lathes
    Replies: 16
    Last Post: 03-18-2008, 08:19 PM
  5. Mid program restart
    By HuFlungDung in forum Haas Mills
    Replies: 4
    Last Post: 06-26-2007, 10:32 PM

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
  •