When using Max Achievable accel, is the velocity the velocity the motor is at or the velocity setpoint.

Same question for Max Achievable vel.

When using Max Achievable accel, is the velocity the velocity the motor is at or the velocity setpoint.

Same question for Max Achievable vel.

You can use either, and the computed result will mean a different thing in each case.

What are you trying to use it for?

determining constraints for profiledpid

In that case you use whatever velocity you picked as a profile constraint; the method will calculate the corresponding acceleration constraint that is achievable given your motor.

So if I used the maximum motor velocity then this would give me the maximum motor acceleration in theory.

No; it would return zero because at max velocity thereâ€™s no remaining voltage to drive acceleration.

How would I go about finding the max acceleration constraint then

Pick a max profile velocity that is lower than the actual peak motor velocity. You have to do this to have an achievable profile.

So I have an arm that I want to get to a setpoint as soon as possible. How do I go about choosing a value?

Thatâ€™s a complicated nonlinear dynamics question, and the â€śtrueâ€ť answer is not to use a trapezoidal profile.

So just a regular Feedforward and pid then?

No, you should definitely use a profile; the point to take away is that getting there â€śas fast as possibleâ€ť is not the only thing youâ€™re trying to do. Trapezoidal profiles are a compromise.

So it comes down to the behavior that I want. What is the primary benefit of the profile then?

1 Like

A well-constrained profile is going to keep your commanded motion within what the mechanism can achieve, so that the mechanism is never uncontrolled. This gives more reliable movement.

Profiles also reduce wear on the mechanism and motor, since constrained motion is less aggressive/violent.

1 Like

Thank you. Any recommended mathematical voodoo (aka rules of thumb) to help out

Best way to get an idea of whatâ€™s appropriate is to try a few choices and see how they work. Knock a little bit off the calculated value to give yourself more â€śheadroom.â€ť

Start with 25% of max speed and go up from there.

1 Like

So the â€śprocessâ€ť . Run some tests with different max velocities. Use maxachievableAccel from these maxvelocities. Create the constraint, create the profiledPIDController.

One last thought. For profiledPID motion control do I need to use feedforward to get a voltage component from that?

Yes, you should use a feedforward whenever possible.

Oh right. Good point. I get the angle hold value for free with FF.

1 Like