ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Building a hardware interface for a 6DOF custom build robot

asked 2019-09-23 10:37:07 -0500

denrot gravatar image

Hello all together,

I am currently building a hardware interface for a custom build 6DOF robot arm to control it with MoveIt and execute trajectories. So far I've had success implementing a hardware_interface::PositionJointInterface and using a position_controllers/JointTrajectoryController to control the robot. The robot publishes the current joint angles into /joint_states and there is another topic on which the robot gets the positions (in radians) from the controller to follow the trajectory as calculated from MoveIt and visualized in rviz.

So far so good.. When trying to move the robot on a cartesian path the end-effector is not really moving straight. I assume that the controller I am using is not appropriate for this purpose since it does not (to the best of my knowledge) contain an inner feedback loop. Since I can also send velocities to the robots stepper motors, it would be better to use a controller which takes joint positions as an input and outputs velocities.

Anyone knows which controller could be suitable for my situation? I was thinking about using a velocity_controllers/JointTrajectoryController or a pos_vel_controllers/JointTrajectoryController but I am not sure how these controllers are controlling my actual robot.

I'd be very grateful if anyone could clarify that for me.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2021-08-08 22:15:19 -0500

Pratik Somaiya gravatar image

I am not sure which controller would be better for your application but here is some information that might help:

  • To the best of my knowledge, the position_controllers/JointTrajectoryController is an open-loop controller so it will simply forward the commands (without doing any corrections).
  • velocity_controllers/JointTrajectoryController will give you velocity as an output which you can forward to your motors. You can tune the PID gains to get the required performance. You can also use pos_vel_controllers or pos_vel_acc_controllers/JointTrajectoryController with pos_vel or pos_vel_acc interface respectively.
  • In general, JointTrajectoryControllercan work with different trajectory representations so, based on what information you provide out of pos, vel an acc in your waypoints, the degree of spline interpolation will be chosen. (http://wiki.ros.org/joint_trajectory_...)

Just a side note, you can also check the state topic published by the JointTrajectoryController and maybe use it to visualise the error with rqt_plot. (http://wiki.ros.org/joint_trajectory_...)

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2019-09-23 10:37:07 -0500

Seen: 229 times

Last updated: Aug 08 '21