Unknown controller type with Moveit
I am trying to control the open manipulator on the TB3. I created a Moveit config package and everything works fine until I want to execute the plan on a Gazebo simulated robot. Planning is solved but no controllers are found so execution failed.
When I use roslaunch open_manipulator_controller open_manipulator_controller.launch use_platform:=false use_moveit:=true
I can control the Gazebo robot but with my custom Moveit config file, I cannot.
I have controllers.yaml
and I believe it is loaded correctly because the problem comes from the controller types in the .yaml file.
[ERROR] [1629291143.338820460, 1893.061000000]: Unknown controller type: position_controllers/JointPositionController
[ERROR] [1629291143.339038429, 1893.061000000]: Unknown controller type: position_controllers/JointPositionController
[ERROR] [1629291143.339144118, 1893.061000000]: Unknown controller type: position_controllers/JointPositionController
[ERROR] [1629291143.339236787, 1893.061000000]: Unknown controller type: position_controllers/JointPositionController
[ERROR] [1629291143.339306340, 1893.061000000]: Unknown controller type: joint_state_controller/JointStateController
And the respective controllers.yaml
is here:
controller_list:
- name: joint1_position
action_ns: /om_with_tb3
type: position_controllers/JointPositionController
default: true
joints:
- joint1
- name: joint2_position
action_ns: /om_with_tb3
type: position_controllers/JointPositionController
default: true
joints:
- joint2
- name: joint3_position
action_ns: /om_with_tb3
type: position_controllers/JointPositionController
default: true
joints:
- joint3
- name: joint4_position
action_ns: /om_with_tb3
type: position_controllers/JointPositionController
default: true
joints:
- joint4
- name: joint_state_controller
action_ns: /om_with_tb3
type: joint_state_controller/JointStateController
default: true
joints:
- joint1
- joint2
- joint3
- joint4
With a bit of research, I found out that this problem is linked to some missing Moveit controller packages. I tried to install them sudo apt install ros-melodic-ros-controllers
and sudo apt install ros-melodic-joint-state-controller
but it looks like I already have them.
Anyone has any ideas why the Moveit config package cannot recognize any controller types?
did you install gazebo-ros-controllers?
it is installed in default as well.
ros-melodic-gazebo-ros-control is already the newest version (2.8.7-1bionic.20210616.200839)
MoveIt "controllers" !=
ros_control
controllers.Yes, I am aware of that part. Actually that's why I tried to explain the problem as "Moveit controller" issue. However, similar problem may occur if the
ros_control
is not installed (properly). I just tried to explain that part doesn't look like the issue for my case.I guess the problem is in the controller type. MoveitSimpleController has only FollowJointTrajectory and GripperAction type (I am not sure that part, couldn't find a proper documentation/tutorial) . So I cannot load let say
joint_state_controller/JointStateController
as ros_control supports. I don't know how to solve it...I think you want to use a
Yes,
position_controllers/JointTrajectoryController
for joints andjoint_state_controller/JointStateController
for the last joint_state_controller but the problem is that those ros_control controllers are not supported by Moveit (bymoveitsimplecontrollermanager
). That's my question.@Gates, you can use
position_controllers/JointTrajectoryController
with moveit (or any otherros_control
controller as long as the controller offers aFollowJointTrajectory
action service ). You need to usetype: position_controllers/JointTrajectoryController
in yourcontrollers.yaml
forros_control
. For the moveitcontrollers.yaml
you need to useaction_ns: follow_joint_trajectory
andtype: FollowJointTrajectory
for your controller.Check the minimal example in my answer below.