Deceleration distance too long

More
27 May 2021 09:06 #210433 by rodw
Replied by rodw on topic Deceleration distance too long
We've noticed this behaviour too. Try running some gcode and plot current-vel. it will be as expected
Then do it from MDI. I think the trapezoid will have a different slope. (different accel)

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

More
27 May 2021 10:58 #210435 by roland
I have tested a little more:

1. jog move. Acceleration is 500 -> ok




2. MDI move. Acceleration is 250




3. run a little program. At the beginning acceleration is 500 an will be reduced to 450




4. run program again. Acceleration is still at 450




5. MDI move. Acceleration now is 500

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

More
27 May 2021 18:10 - 27 May 2021 18:11 #210458 by roland
it makes a difference if G61 or G64 is active

In G61 mode:
MDI acceleration is 500 -> ok
program acceleration is 450

in G64 mode:
MDI acceleration is 250
programm acceleration is 250
Last edit: 27 May 2021 18:11 by roland.

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

More
27 May 2021 21:47 - 27 May 2021 21:52 #210471 by Grotius
Hi,

Can you check in mm or inches?

At first sight i get a feeling it's a typo in the source. Like 0.5* or /2
Maybe it has something to do with : UNITS_PER_REVOLUTION=2
the function : line2184 of src/emc/rs274ngc/interp_convert.cc
Last edit: 27 May 2021 21:52 by Grotius.

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

More
28 May 2021 08:57 #210501 by roland
As far as I can tell, it doesn't matter whether the machine is set up in mm or inches.

I suspect the acceleration will be reduced at this point:
github.com/LinuxCNC/linuxcnc/blob/master/src/emc/tp/tc.c
double tcGetOverallMaxAccel(const TC_STRUCT *tc)
{
    // Handle any acceleration reduction due to an approximate-tangent "blend" with the previous or next segment
    double a_scale = (1.0 - fmax(tc->kink_accel_reduce, tc->kink_accel_reduce_prev));

    // Parabolic blending conditions: If the next segment or previous segment
    // has a parabolic blend with this one, acceleration is scaled down by 1/2
    // so that the sum of the two does not exceed the maximum.
    if (tc->blend_prev || TC_TERM_COND_PARABOLIC == tc->term_cond) {
        a_scale *= 0.5;
    }

    return tc->maxaccel * a_scale;
}


But I am just user, not a programmer. The source code thing is beyond my capabilities

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

More
28 May 2021 14:12 #210524 by Grotius
Hi Roland,

Good search.
If you want to be sure it is this. You can edit the scale to 1 and do a recompile and do a test.
I don't know what they exactly mean with the comment text and what the concequences are.

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

More
29 May 2021 07:31 - 29 May 2021 07:32 #210595 by roland
I can really influence the acceleration at this point.
I don't understand why the acceleration has to be reduced. But I suppose, this reduction is not built in for no reason.

So I'll look for another workaround
Last edit: 29 May 2021 07:32 by roland.

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

More
30 May 2021 17:16 #210701 by andypugh
I think that the half-max accelleration is required in the single-segment lookahead planner just in case the machine has to stop during the next (as-yet unseen) segment.

I note that the moves shown are joint 3. Which axis is that?
If it is one of X,Y, Z then I am a bit surprised, as those should not be using the paraboilic blend, but should be using the circular arc blend and the large lookahead planner.

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

More
30 May 2021 17:27 #210704 by roland
joint 3 is Z axis

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

More
30 May 2021 17:39 #210705 by andypugh
Then I am not sure why (or if) it is using parabolic blending.

Do you see the same with joint 0 ?

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

Time to create page: 0.138 seconds
Powered by Kunena Forum