How to get constant velocity output from joint_trajectory_controller?
Hi,
is there a way to put the constraints into the joint_trajectory_controller
so that the computed velocity is constant for all the waypoints? Basically, I want that the end-effector of the robot moves with a constant velocity along the trajectory.
Yes: feed it a trajectory that will make your EEF move with a constant velocity.
Coming up with such a trajectory is not the job of
JointTrajectoryController
. It's on the execution side of things, not on the motion planning side.You'll have to generate such a trajectory using a proper motion planner, or write some code yourself.
Thank you, but could you elaborate a bit more on „Yes: feed it a trajectory that will make your EEF move with a constant velocity.“ I am not quite following you...
The
JointTrajectoryController
(JTC) only executes trajectories. It does not do any motion planning, so it cannot come up with trajectories or constraints itself.To make it "do" something, you'll have to send it a trajectory which already adheres to whatever constraints you have in mind.
If your constraints include "move with a constant velocity", then you have to make sure the trajectory you sent the JTC causes the EEF to move with a constant velocity. You cannot make the JTC execute a trajectory with a constant EEF velocity unless that is already encoded in the trajectory's timing information.
What I'm trying to explain is that you seem to focus on the JTC, while the behaviour you're looking for is not the responsibility of the JTC. It would be the responsibility of the entity which generates your trajectory.