Question about acceleration and deceleration of linuxCNC linear movement

More
04 Sep 2023 09:46 #279807 by lqb
Hello, everyone.
In the "tpUpdateCycle" function in the "tp.c" file, the calculation of the acceleration phase is done with the "tpCalculateRampAccel" function and the "tpUpdateDistFromAccel" function, but I can't see where the calculation of the deceleration phase is done.

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

More
04 Sep 2023 11:20 #279812 by lqb
Sorry, I looked into the function "tcUpdateDistFromAccel" again, and when a line segment is added and the final velocity of the segment is 0, it should be a decelerated displacement.
This seems to mean that I have to add three displacements to do acceleration, uniform velocity and deceleration

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

  • rodw
  • rodw's Avatar
  • Away
  • Platinum Member
  • Platinum Member
More
05 Sep 2023 03:19 #279917 by rodw
Correct, Linuxcnc accellerates at max velocity until it reaches requested velocity, then decellerates at the same rate to get to the end point accelleration. If you graph this in halscope, you will see the classic trapezoid. 

There are a few other factors that come into play regarding segment length and the look ahead to the next segment in the real world.
The following user(s) said Thank You: lqb

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

Time to create page: 0.082 seconds
Powered by Kunena Forum