Coordinated Motion involving rotary axis

More
11 years 1 month ago #62939 by Rick G
Replied by Rick G on topic Coordinated Motion involving rotary axis

I would not be surprised to find that all coordinated rotary motions are exact-stop. The path blending tolerance is given in linear units, and there is no way to know how angular error correlates to linear error. (the axis origins might be at the rotation axis, but they might equally well be at the part surface, simply depending on setup and coding style).

That does seem logical, so I tried a little test...
Code:
% f100 g0 x0 y0 z0 a0 g64 p.05 q.05 g1 x 0.01 y 0.01 a 0.01 x 0.02 y 0.02 a 0.02 x 0.03 y 0.03 a 0.03 x 0.04 y 0.04 a 0.04 x 0.05 y 0.05 a 0.05 x 0.06 y 0.06 a 0.06 x 0.07 y 0.07 a 0.07 x 0.08 y 0.08 a 0.08 x 0.09 y 0.09 a 0.09 x 0.1 y 0.1 a 0.1 x 0.11 y 0.11 a 0.11 x 0.12 y 0.12 a 0.12 x 0.13 y 0.13 a 0.13 x 0.14 y 0.14 a 0.14 x 0.15 y 0.15 a 0.15 x 0.16 y 0.16 a 0.16 x 0.17 y 0.17 a 0.17 x 0.18 y 0.18 a 0.18 x 0.19 y 0.19 a 0.19 x 0.2 y 0.2 a 0.2 x 0.21 y 0.21 a 0.21 x 0.22 y 0.22 a 0.22 x 0.23 y 0.23 a 0.23 x 0.24 y 0.24 a 0.24 x 0.25 y 0.25 a 0.25 x 0.26 y 0.26 a 0.26 x 0.27 y 0.27 a 0.27 x 0.28 y 0.28 a 0.28 x 0.29 y 0.29 a 0.29 x 0.3 y 0.3 a 0.3 x 0.31 y 0.31 a 0.31 x 0.32 y 0.32 a 0.32 x 0.33 y 0.33 a 0.33 x 0.34 y 0.34 a 0.34 x 0.35 y 0.35 a 0.35 x 0.36 y 0.36 a 0.36 x 0.37 y 0.37 a 0.37 x 0.38 y 0.38 a 0.38 x 0.39 y 0.39 a 0.39 x 0.4 y 0.4 a 0.4 x 0.41 y 0.41 a 0.41 x 0.42 y 0.42 a 0.42 x 0.43 y 0.43 a 0.43 x 0.44 y 0.44 a 0.44 x 0.45 y 0.45 a 0.45 x 0.46 y 0.46 a 0.46 x 0.47 y 0.47 a 0.47 x 0.48 y 0.48 a 0.48 x 0.49 y 0.49 a 0.49 x 0.5 y 0.5 a 0.5 %
Using the 9 axis sim (with new Trajectory planner enabled) on 2.8 the velocity seems to be constant and the same for G64 and G64 P.05 Q.05
However with G61 the velocity is choppy and slower.

Rick G

Please Log in or Create an account to join the conversation.

More
11 years 1 month ago #62941 by andypugh
Replied by andypugh on topic Coordinated Motion involving rotary axis

Rick G wrote: Using the 9 axis sim (with new Trajectory planner enabled) on 2.8 the velocity seems to be constant and the same for G64 and G64 P.05 Q.05
However with G61 the velocity is choppy and slower.


That seems to suggest that it is exact-path (no blending) but not exact stop.

I am perhaps getting terms mixed up, does G61 actually stop at the end of each move before starting the next?

Please Log in or Create an account to join the conversation.

More
11 years 1 month ago #62943 by Todd Zuercher
Replied by Todd Zuercher on topic Coordinated Motion involving rotary axis
I ran your test on the 9-axis sim as well because you didn't mention the actual velocities achieved (and I wanted to know). And what I saw, I believe, is what I've suspected, that when movements are made in any other axis than XYZ the planner reverts to the old trajectory planner and its must be able to stop by the end of the next line look ahead, therefore full speed is never achieved with short line segments. (unless the acceleration is high enough to go from 0 to full speed within the length of the next line segment) When the test file is restarted and the tool retraces its previous movement in a single command, full speed is achieved.

I do not know if any work is being done to extend the new trajectory planner beyond XYZ.

Please Log in or Create an account to join the conversation.

More
11 years 1 month ago #62944 by Todd Zuercher
Replied by Todd Zuercher on topic Coordinated Motion involving rotary axis
Further testing I think shows it. I ran that test file as is, with A replaced with W and with only XYZ and this was the result. The velocities for A and W were identical, and XYZ was as you'd expect.
A-Test


W-Test


XYZ-test
Attachments:

Please Log in or Create an account to join the conversation.

More
11 years 1 month ago #62970 by Rick G
Replied by Rick G on topic Coordinated Motion involving rotary axis
Andy,

With G61 each move appears to accelerates then deaccelerate however maybe not to a complete stop, like you stated exact path.

From linuxcnc.org/docs/html/common/User_Concepts.html

1.3. Programming the Planner

The trajectory control commands are as follows:

G61 - (Exact Path Mode) visits the programmed point exactly, even though that means it might temporarily come to a complete stop in order to change direction to the next programmed point.

G61.1 - (Exact Stop Mode) tells the planner to come to an exact stop at every segment’s end.

G64 - (Blend Without Tolerance Mode) G64 is the default setting when you start LinuxCNC. G64 is just blending and the naive cam detector is not enabled. G64 and G64 P0 tell the planner to sacrifice path following accuracy in order to keep the feed rate up. This is necessary for some types of material or tooling where exact stops are harmful, and can work great as long as the programmer is careful to keep in mind that the tool’s path will be somewhat more curvy than the program specifies. When using G0 (rapid) moves with G64 use caution on clearance moves and allow enough distance to clear obstacles based on the acceleration capabilities of your machine.

G64 P- Q- - (Blend With Tolerance Mode) This enables the naive cam detector and enables blending with a tolerance. If you program G64 P0.05, you tell the planner that you want continuous feed, but at programmed corners you want it to slow down enough so that the tool path can stay within 0.05 user units of the programmed path. The exact amount of slowdown depends on the geometry of the programmed corner and the machine constraints, but the only thing the programmer needs to worry about is the tolerance. This gives the programmer complete control over the path following compromise. The blend tolerance can be changed throughout the program as necessary. Beware that a specification of G64 P0 has the same effect as G64 alone (above), which is necessary for backward compatibility for old G Code programs. See the G64 section of the G code chapter.

Blending without tolerance - The controlled point will touch each specified movement at at least one point. The machine will never move at such a speed that it cannot come to an exact stop at the end of the current movement (or next movement, if you pause when blending has already started). The distance from the end point of the move is as large as it needs to be to keep up the best contouring feed.

Naive Cam Detector - Successive G1 moves that involve only the XYZ axes that deviate less than Q- from a straight line are merged into a single straight line. This merged movement replaces the individual G1 movements for the purposes of blending with tolerance. Between successive movements, the controlled point will pass no more than P- from the actual endpoints of the movements. The controlled point will touch at least one point on each movement. The machine will never move at such a speed that it cannot come to an exact stop at the end of the current movement (or next movement, if you pause when blending has already started) On G2/3 moves in the G17 (XY) plane when the maximum deviation of an arc from a straight line is less than the G64 Q- tolerance the arc is broken into two lines (from start of arc to midpoint, and from midpoint to end). those lines are then subject to the naive cam algorithm for lines. Thus, line-arc, arc-arc, and arc-line cases as well as line-line benefit from the naive cam detector. This improves contouring performance by simplifying the path.


Todd,

That is interesting, So any move beyond a xyz reverts to parabolic blending (1 segment look ahead.)?
As Andy stated any rotary axis move the tolerances of P and Q with G64 would not work properly.
But that still leaves uvw.


Same as setting the
linuxcnc.org/docs/html/config/ini_config.html#sub:TRAJ-section

2.10. [TRAJ] Section
Warning
The new Trajectory Planner (TP) is on by default.
If you have no TP settings in your [TRAJ] section - LinuxCNC defaults to:
ARC_BLEND_ENABLE = 1
ARC_BLEND_FALLBACK_ENABLE = 0
ARC_BLEND_OPTIMIZATION_DEPTH = 50
ARC_BLEND_GAP_CYCLES = 4
ARC_BLEND_RAMP_FREQ = 100

The [TRAJ] section contains general parameters for the trajectory planning module in motion.

ARC_BLEND_ENABLE = 1 - Turn on new TP. If set to 0 TP uses parabolic blending (1 segment look ahead.) Default value 1.


I wonder if the "old" trajectory planner also did not work with u,v,w

Rick G

Please Log in or Create an account to join the conversation.

More
11 years 1 month ago #62976 by Todd Zuercher
Replied by Todd Zuercher on topic Coordinated Motion involving rotary axis
I don't think the naive cam detection worked with ABCUVW in the old planner either, and the halscope plots for each of the 3 path modes look pretty much the same in 2.61 as it does running 2.7.

For this test file G61 moves without stopping with only XYZ moves, but with any movement in ABCUVW the movement is the same as G61.1 (stopping at each point).
I didn't post pictures of the G61 and G61.1 halscope plots.

Please Log in or Create an account to join the conversation.

Time to create page: 0.792 seconds
Powered by Kunena Forum