0
$\begingroup$

Rosanswers logo

Hello everyone!

I'm trying to control the panda robot together with the UR5 robot through MoveIt!. For this, I combined both robots in a xacro file and correctly set up the simulation, including moving to poses etc.

Now I want to work with the real robots and have some troubles with the controllers. At first, I only try to control the Panda robot. The franka_example_controllers worked fine. Now I try to use a new controller. My controllers.yaml file looks like this:

UR5_controller:
action_ns: follow_joint_trajectory
type: FollowJointTrajectory
default: true
joints:
  - ur5_shoulder_pan_joint
  - ur5_shoulder_lift_joint
  - ur5_elbow_joint
  - ur5_wrist_1_joint
  - ur5_wrist_2_joint
  - ur5_wrist_3_joint

Panda_controller:
    type: effort_controllers/JointTrajectoryController
    joints:
      - panda_joint1
      - panda_joint2
      - panda_joint3
      - panda_joint4
      - panda_joint5
      - panda_joint6
      - panda_joint7
    gains:
        panda_joint1: { p: 120, d: 5, i: 0.0, i_clamp: 10000 }
        panda_joint2: { p: 300, d: 10, i: 0.02, i_clamp: 10000 }
        panda_joint3: { p: 180, d: 5, i: 0.01, i_clamp: 1 }
        panda_joint4: { p: 180, d: 7, i: 0.01, i_clamp: 10000 }
        panda_joint5: { p: 120, d: 7, i: 0.01, i_clamp: 1 }
        panda_joint6: { p: 100, d: 5, i: 0.01, i_clamp: 1 }
        panda_joint7: { p: 100, d: 2, i: 0.0, i_clamp: 1 }
    constraints:
        goal_time: 2.0
    state_publish_rate: 25

This leads me to an error while setting up:

[ERROR] [1561555629.203914705]: No controller_list specified.

The rest of setting up works: RViz opens, showing me the real robot states.

When trying to execute a trajectory, I get the following error message:

[ERROR] [1561553234.640997333]: Unable to identify any set of controllers that can actuate the specified joints: [ panda_joint1 panda_joint2 panda_joint3 panda_joint4 panda_joint5 panda_joint6 panda_joint7 ]
[ERROR] [1561553234.641057622]: Known controllers and their joints:

[ERROR] [1561553234.641112443]: Apparently trajectory initialization failed

It sounds like there weren't any controllers found, though the (rqt_)controller_manager says something different.

Here comes my first question, because it really confuses me that in some places it says, the controllers.yaml file should look like this:

controller_list:
  - name: UR5_controller
[...]

When I tried the latter method, I got another error:

[ERROR] [1561554412.210393573]: Could not load controller 'Panda_controller' because the type was not specified. Did you load the controller configuration on the parameter server (namespace: '/Panda_controller')?

In this case, the controller manager doesn't know my controllers.

EDIT: According to this post you have to configure two controllers.yaml-files: one for moveit, one for ROS. Can somebody confirm this? Doesn't sound like a clean solution. I tried to make it in this way, but it didn't work either. It fixes the error that no controller_list was specified, but the other error is still there. After a few tests, I even recognized that the first type of solution (moveit_controllers.yaml file) has no effect and can even be left out. So right now I'm trying it just with the ros_controllers.yaml file. This lets me see the controllers in the rqt Controller Manager and I'm able to control the joints trough the Joint Trajectory Controller of rqt. But whenever I send a move() command from MoveIt, I still get the error message with the empty list of available controllers.

After all, I'm also asking myself if I'm even on the right track. In some answers and tutorials, it sounded like there would be no predefined controllers (except from the franka_example_controllers, which already include the desired poses) at all. But the more I read about ros_control, the more certain I get that it is enough to reference one of the controllers of ros_control? But if that's true, what am I doing wrong?

This is my setup:

  • ROS Melodic
  • Ubuntu 18.04.2 LTS
  • Intel® Xeon(R) CPU E3-1225 v3 @ 3.20GHz × 4
  • Realtime Kernel (4.19.37-rt20-rc1 #1 SMP PREEMPT RT)

Thanks a lot! If you need any additional information (launch file, rqt_graph, ...) , let me know!

SOLVED SUB-PROBLEM: Also, when I'm setting up, I get another error, which I already got in the simulation. I guess it's not relevant and related to OMPL, because there are logging messages about OMPL before and after it.

[ INFO] [1561554412.219047682]: Initializing OMPL interface using ROS parameters
[ERROR] [1561554412.229484188]: Could not find the planner configuration 'None' on the param server
[ERROR] [1561554412.246956134]: Could not find the planner configuration 'None' on the param server
[ INFO] [1561554412.270927903]: Using planning interface 'OMPL'

I was able to resolve this issue by editing the ompl_planning.yaml file: Near the end all planning groups are listed and specified. In two cases, the default_planner_config-tag was set to None. It has to be "" for all planning groups.

Panda:
  default_planner_config: ""
  planner_configs:
    - SBL
    - EST
[...]

Originally posted by Gnr on ROS Answers with karma: 1 on 2019-06-26

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

This appears to be a cross-post of ros-controls/ros_control#383.

In any case:

It sounds like there weren't any controllers found, though the (rqt_)controller_manager says something different.

No, it doesn't.

You're confusing the ros_control controllers with whatever MoveIt calls "a controller".

MoveIt is printing that error message.

According to this post you have to configure two controllers.yaml-files: one for moveit, one for ROS. Can somebody confirm this? Doesn't sound like a clean solution.

I'm not sure how having two files is not "a clean solution", but: there is no need for two separate files, but you will need two sets of parameters: one for your hw interfaces (those of the Panda and the UR) and one for MoveIt. Those also typically live in separate namespaces, so having two files makes sense.

I tried to make it in this way, but it didn't work either. It fixes the error that no controller_list was specified, but the other error is still there. After a few tests, I even recognized that the first type of solution (moveit_controllers.yaml file) has no effect and can even be left out. So right now I'm trying it just with the ros_controllers.yaml file. This lets me see the controllers in the rqt Controller Manager and I'm able to control the joints trough the Joint Trajectory Controller of rqt. But whenever I send a move() command from MoveIt, I still get the error message with the empty list of available controllers.

Again: ros_control controllers != MoveIt controllers.

To gain some more insight into what is going on, I would suggest to configure ROS logging such that it includes the name of the node and of the logger when printing log messages. Refer to Console Output Formatting for more information, but this is how I'd configure things (add it to your .bashrc fi):

export ROSCONSOLE_FORMAT='[${severity}] [${time}] [${node}] [${logger}]: ${message}'

Running your setup again should show you that MoveIt is complaining.

You may take a look at the Low Level Controllers page on the MoveIt tutorials site. Comparing the "yaml configuration" shown there as an example and the one you show in your question immediately shows that yours is missing the top-level controller_list key. That is what MoveIt is complaining about.

Probably unrelated, but you'll also want to avoid using capitals everywhere (so no UR5_controller, but ur5_controller).

I would suggest to first get one robot working correctly with the ros_control configuration: single robot in your urdf, single robot set of parameters, launch files, etc. If/when you have that working, start extending it.


Originally posted by gvdhoorn with karma: 86574 on 2019-07-04

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by gvdhoorn on 2019-07-04:
And a comment: you must think of everything in this setup as a stand-alone component. The driver+ros_control is one component. MoveIt is another. What you are configuring is the connection between these components.

MoveIt is often used with its "simple controller" which is essentially just a FollowJointTrajectory action client which forwards trajectories wholesale to the driver. That is what is configured in MoveIt's controllers.yaml file.

The configuration of your driver+ros_control is completely separate from that. Putting everything in a single file is possible, but may not be the best approach, as it immediately tightly couples everything.

Comment by gvdhoorn on 2019-07-09:
So did you get things to work in the end?

Comment by Gnr on 2019-07-09:
Thanks, this helped a lot. I did several minor changes in both yaml files and now it works. (Lowercase controller names, removed unnecessary stuff that was added by the setup assistant wizard, re-checked consistency between the two files)

Maybe I haven't worked with ROS enough, but I did not find the connection between MoveIt and ros_control very intuitive. Also, the documentation for the FCI gets rather short when it comes to franka_ros.

Thank you very much for your help. Especially the console output format is very helpful to understand better whats going on.

Comment by gvdhoorn on 2019-07-09:\

Maybe I haven't worked with ROS enough, but I did not find the connection between MoveIt and ros_control very intuitive

I guess the assumption is that you already know a thing or two about setting things like this up (and that is "you" in the general sense, not you-you).

Also, the documentation for the FCI gets rather short when it comes to franka_ros.

that would be something to report/tell Franka Emika. Especially if the robot was specifically bought to use it with ROS.

Comment by Gnr on 2019-07-11:\

that would be something to report/tell Franka Emika. Especially if the robot was specifically bought to use it with ROS.

Good point. I will collect a bit of feedback and contact them in the end of my project.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.