Hello Guest it is April 26, 2024, 04:15:17 PM

Author Topic: Rotary axis overshoot  (Read 648 times)

0 Members and 1 Guest are viewing this topic.

Rotary axis overshoot
« on: October 16, 2021, 03:46:07 PM »
Hi all,
I recently built a small rotary axis for my milling machine (I will call it B-Axis later). To see how it works, I tried to machine a simple rectangular workpiece with a ball cutter. This way I can check if the synchronization with the other axes works and if the dynamic of the rotary axis is sufficient.
First of all, I am using Mach4 build 4300, my CAM outputs the G-code with G93 (inverse time feed). However, I could see some strange behavior in the process. For a better understanding, I have recorded a short video:
https://youtu.be/vHKHx5cV_AQ

In the first scene I set a high acceleration of the rotary axis. You can see that the rotation becomes very slow when the cutter is perpendicular to the surface (or the direction of the vertical Z-axis changes).
That's a bit weird. In my opinion, the rotation speed should be highest at these Points B = 0 deg or B = -180 deg. I have created a diagram (see attachment) directly from the G-code, which shows the angle of rotation as a function of time. The highest slope is at B = 0 deg and B = -180 deg

I noticed that this behavior can be influenced by the acceleration of the rotation axis. As an example, I set a very low acceleration in the second scene. As expected, the movement is significantly slower overall. But more importantly, the rotary axis overshoots a few degrees. You can even see this clearly on the workpiece.
Could someone explain to me why this is happening? The G-code looks OK to me. As an example, I have attached a snippet for the first rotation. Later only axial shifting is done.
The position change in Z-axis is very small at B = 0 and B = -180 deg. So there is not a command for the Z-axis in each line. Could this be a problem?

Thank you!

Offline smurph

*
  • *
  •  1,546 1,546
  • "That there... that's an RV."
    • View Profile
Re: Rotary axis overshoot
« Reply #1 on: October 16, 2021, 05:10:03 PM »
In a couple of words, "constant velocity".  If acceleration changes the outcome, always suspect constant velocity.  Try running in exact stop mode.  But while in CV mode, the higher the acceleration, the closer the cut will be to the actual tool path.  So if you machine can handle it, turn the acceleration up more. 

Steve
Re: Rotary axis overshoot
« Reply #2 on: October 18, 2021, 09:09:46 AM »
i wrote here in the past
mach have very good features but one very important point its missing ,its called jerk or S curve
if you use servo drive you can try add the filter time ,this in my case act like jerk and almost solve the accl problem
Re: Rotary axis overshoot
« Reply #3 on: October 18, 2021, 02:18:44 PM »
smurph,
thanks for your answer! That makes sense. Especially the overshooting at low acceleration can be explained by this.
Nevertheless, the behavior at high accelerations (4000 Deg /s^2, scene 1 in the video above) looked a bit strange to me. After a few tries I was able to speed up the processing significantly by increasing the resolution of the G-code. Now I use 5 decimal places for X/Y/Z and 4 decimal places for the rotary axis and also increased the internal precision in CAM (step angle of the rotary axis is still the same).
I never bothered with this because the resolution of the motor drives is about 0.001 mm, so I wouldn't expect a better accuracy by increasing the number of decimal places. But this way I get a more continuous G-Code, which seems to help Mach4 with the path planning.
Here you can see a short comparison:
https://youtu.be/DyEQKCbuEaE

With 3 decimal places a rotation of the workpiece takes about 5.7 s. When I use the file with 5/4 decimal places a rotation takes only 4.87 s because the rotation is much faster at B = 0 deg and B = 180 deg. And the movement even sounds smoother.
Actually very simple. But maybe it will help someone else. I think for me it's ok like this.

KatzYaakov,
thanks. Yes, I totally agree with you! Including jerk would be a great improvement for Mach4.
Re: Rotary axis overshoot
« Reply #4 on: October 18, 2021, 03:30:32 PM »
Because no jerk ,you must put very poor acc dcc and then because very poor acc dcc ( you can see how the trapeze become longggg) CV cant calculate well and all movement become crazy
My suggestion its find the filter parameter in yours servo drive and play wirh it ,this will solve half of all problems