Ask Your Question
0

Configuring moveit_servo for use with tmr_ros1 (techman robot)

asked 2022-02-15 05:36:42 -0500

Benjamin C gravatar image

updated 2022-02-15 07:28:25 -0500

gvdhoorn gravatar image

Hi everyone. I have a problem and I hope you can help me.

I'm using ROS Noetic and the tmr_ros1 pkg. Right now I am trying to use the realtime servoing functionnality for Moveit, see this.

tmr_ros1 is only using the FollowJointTrajectory controller and the tutorial says that i need to switch my controller. But the controller_manager is not runing so i can't call:

rosservice call /controller_manager/switch_controller "start_controllers: ['joint_group_position_controller']...

However as I am not using a gazebo simulation I can't just add this to my urdf:

<gazebo>
  <plugin name="gazebo_ros_control" filename="libgazebo_ros_control.so">
    <robotNamespace>/MYROBOT</robotNamespace>
  </plugin>
</gazebo>

So I tried serveral things like starting the controller in a launch file but nothing worked. And I kinda messed my workspace (no big deal ;)

Can anyone point me toward a direction to use the controller manager with a real robot instead of using Moveit's basic manager Trajectory execution is managing controllers All of this aim to change my controller to joint_group_position_controller.

Have a nice day !

edit retag flag offensive close merge delete

Comments

I've changed the title of your question as there are plenty of "real robots" with drivers which areros_control based and for which using moveit_servo would be a matter of following the tutorial you mention.

The real question here appears to be how would you go about configuring everything such that it works with a Techman robot, or specifically: with a Techman robot using their tmr_ros1 driver packages.

gvdhoorn gravatar image gvdhoorn  ( 2022-02-15 07:30:00 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
2

answered 2022-02-15 07:26:41 -0500

gvdhoorn gravatar image

updated 2022-02-15 07:30:56 -0500

Can anyone point me toward a direction to use the controller manager with a real robot instead of using Moveit's basic manager Trajectory execution is managing controllers All of this aim to change my controller to joint_group_position_controller.

You can't use any ros_control based solution as tmr_ros1 is not ros_control based.

It uses a regular stand-alone node which exposes the FollowJointTrajectoryAction server.

You'll have to investigate whether there is any possibility of sending position or velocity commands to tm_driver in any other way. Without being able to stream position or velocity setpoints, I'm not sure you can use moveit_servo in a meaningful way.

And note: "stream[ing] position or velocity setpoints" implies a low-latency connection. Servoing only really works well if that's something you have to your target robot.

edit flag offensive delete link more

Comments

Thank you very much for your time ! It seems like I need to investigate furthermore this tmr_ros1 driver.

Benjamin C gravatar image Benjamin C  ( 2022-02-15 07:45:17 -0500 )edit

The driver has a demo program that can send positions to the robot called demo_set_positions.cpp Do you think that if I run it fast and pass the outgoing positions from moveit_servo it might work ? Because I can't find another way.

Benjamin C gravatar image Benjamin C  ( 2022-02-15 08:15:51 -0500 )edit

I assume you are referring to TechmanRobotInc/tmr_ros1/demo/src/demo_set_positions.cpp?

If that's the case: that seems to use ROS services which use a service exposed by the driver, which then executes this code which finally seems to use some sort of text-based scripting interface to the TM controller.

I don't have any direct experience with TM robots nor controllers, but ROS services incur quite some latency. They're not used very often for anything "real-time".

You could try, but you'd have to create something which accepts position setpoints over a topic (which is what moveit_servo uses) and then uses a service client to communicate with the TM driver.

Absolutely no guarantees this will work.

gvdhoorn gravatar image gvdhoorn  ( 2022-02-15 08:51:07 -0500 )edit

I would advise you to ask the TM developers for more information about the available interfaces.

At this point I believe your initial question is answered: there doesn't appear to be a way for you to use moveit_servowith this driver -- or at least not without custom development, and even then, it's questionable the performance will be sufficient / satisfactory.

gvdhoorn gravatar image gvdhoorn  ( 2022-02-15 08:54:23 -0500 )edit

A big thanks to you sir !

Benjamin C gravatar image Benjamin C  ( 2022-02-15 09:01:42 -0500 )edit

I found this in moveit_servo config file and will try it:

# What type of topic does your robot driver expect?
# Currently supported are std_msgs/Float64MultiArray (for ros_control JointGroupVelocityController or JointGroupPositionController)
# or trajectory_msgs/JointTrajectory (for Universal Robots and other non-ros_control robots)
command_out_type: std_msgs/Float64MultiArray

Because this looks interesting: or trajectory_msgs/JointTrajectory (for Universal Robots and other non-ros_control robots

Benjamin C gravatar image Benjamin C  ( 2022-02-16 03:51:36 -0500 )edit

It's a really old comment (as "Universal Robots" don't need that at all any more), but sure. Try and see whether it works sufficiently.

(I doubt it, but perhaps for your use-case it's enough)

gvdhoorn gravatar image gvdhoorn  ( 2022-02-16 03:55:59 -0500 )edit

Your Answer

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

Add Answer

Question Tools

1 follower

Stats

Asked: 2022-02-15 05:36:42 -0500

Seen: 34 times

Last updated: Feb 15