ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A
Ask Your Question

Understanding effort_controllers/JointTrajectoryController

asked 2023-03-04 05:55:04 -0500

CroCo gravatar image

The manipulator I have has a gripper that is controlled by effort_controllers/JointTrajectoryController as shown below

  type: effort_controllers/JointTrajectoryController
    - gripper_finger_joint_l
    - gripper_finger_joint_r
    gripper_finger_joint_l: {p: 1000.0, d: 1.0}
    gripper_finger_joint_r: {p: 1000.0, d: 1.0}

The topic shows this information for commanding the gripper

>rostopic pub /arm_1/gripper_controller/command trajectory_msgs/JointTrajectory "header:
  seq: 0
    secs: 0
    nsecs: 0
  frame_id: ''
- ''
- positions: [0]
  velocities: [0]
  accelerations: [0]
  effort: [0]
  time_from_start: {secs: 0, nsecs: 0}"

It isn't clear to me what needs to be done to open and close the gripper quickly. What is the syntax for the above command?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2023-03-08 09:30:11 -0500

dcconner gravatar image

Not a complete answer as I'm going from memory, but your JointTrajectory message needs to provide a list of all joint_names, e.g. gripper_finger_joint_l and gripper_finger_joint_r as strings,

points is a list of TrajectoryPoints. where each point provides the data for a single knot point at a given time from start.

For a trajectory, you'd need at least two points

Each knot point needs to provide the commanded positions, (and vel and acc for higher order splines). So for two joints, positions should be an array of two values. If you don't provide all required data for joint names and positions, then the command won't work.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools



Asked: 2023-03-04 05:55:04 -0500

Seen: 336 times

Last updated: Mar 08