【求助】ros2 humble下gazebo&moveit联合仿真,ros2 control node加载失败
-
报错信息:[ros2_control_node-6] [INFO] [1750770401.570871549] [resource_manager]: Loading hardware 'GazeboSystem'
[ros2_control_node-6] terminate called after throwing an instance of 'pluginlib::LibraryLoadException'
[ros2_control_node-6] what(): According to the loaded plugin descriptions the class gazebo_ros2_control/GazeboSystem with base class type hardware_interface::SystemInterface does not exist. Declared types are fake_components/GenericSystem mock_components/GenericSystem test_hardware_components/TestSystemCommandModes test_hardware_components/TestTwoJointSystem
我的相关包版本:
ros-humble-ros2-control is already the newest version (2.51.0-1jammy.20250617.234359);
ros-humble-ros2-controllers is already the newest version (2.47.0-1jammy.20250618.000355);
ros-humble-gazebo-ros2-control is already the newest version (0.4.10-1jammy.20250617.235819);
ros-humble-gazebo-ros-pkgs is already the newest version (3.9.0-1jammy.20250618.001012);
在/opt/ros/humble/share/gazebo_ros2_control/gazebo_hardware_plugins.xml描述性文件下,其定义的基类是gazebo_ros2_control::GazeboSystemInterface,而非系统提示的hardware_interface::SystemInterface,请问该如何解决?
我的ros2_control.xacro配置如下:
<hardware>
<plugin>gazebo_ros2_control/GazeboSystem</plugin>
<param name="robot_sim_type">gazebo_ros2_control/GazeboSystem</param>
</hardware>
...
<gazebo>
<plugin name="gazebo_ros2_control" filename="libgazebo_ros2_control.so">
<parameters>$(find robot_description)/config/swhbot_ros2_controllers.yaml</parameters>
<robot_sim_type>gazebo_ros2_control/GazeboSystem</robot_sim_type>
<robot_param>/robot_description</robot_param>
</plugin>
</gazebo>