在运行sim这个demo时出现一个error:
error信息如下:
[ERROR] [1597926212.144023519, 0.092000000]: The error before
refreshing the cache was: According to the loaded plugin
descriptions the class yocs_cmd_vel_mux/CmdVelMuxNodelet with
base class type nodelet::Nodelet does not exist. Declared types
are SlamGMappingNodelet depth_image_proc/convert_metric
depth_image_proc/crop_foremost depth_image_proc/disparity
depth_image_proc/point_cloud_xyz
depth_image_proc/point_cloud_xyz_radial
depth_image_proc/point_cloud_xyzi
depth_image_proc/point_cloud_xyzi_radial
depth_image_proc/point_cloud_xyzrgb depth_image_proc/register
image_proc/crop_decimate image_proc/crop_nonZero
image_proc/crop_non_zero image_proc/debayer image_proc/rectify
image_proc/resize image_publisher/image_publisher
image_rotate/image_rotate image_view/disparity image_view/image
nodelet_tutorial_math/Plus pcl/BAGReader pcl/BoundaryEstimation
pcl/ConvexHull2D pcl/CropBox pcl/EuclideanClusterExtraction
pcl/ExtractIndices pcl/ExtractPolygonalPrismData
pcl/FPFHEstimation pcl/FPFHEstimationOMP
pcl/MomentInvariantsEstimation pcl/MovingLeastSquares
pcl/NodeletDEMUX pcl/NodeletMUX pcl/NormalEstimation
pcl/NormalEstimationOMP pcl/NormalEstimationTBB pcl/PCDReader
pcl/PCDWriter pcl/PFHEstimation pcl/PassThrough
pcl/PointCloudConcatenateDataSynchronizer
pcl/PointCloudConcatenateFieldsSynchronizer
pcl/PrincipalCurvaturesEstimation pcl/ProjectInliers
pcl/RadiusOutlierRemoval pcl/SACSegmentation
pcl/SACSegmentationFromNormals pcl/SHOTEstimation
pcl/SHOTEstimationOMP pcl/SegmentDifferences
pcl/StatisticalOutlierRemoval pcl/VFHEstimation pcl/VoxelGrid
stereo_image_proc/disparity stereo_image_proc/point_cloud2
[FATAL] [1597926212.145538226, 0.092000000]: Failed to load
nodelet '/cmd_vel_mux` of type
`yocs_cmd_vel_mux/CmdVelMuxNodelet` to manager
`mobile_base_nodelet_manager'
[cmd_vel_mux-8] process has died [pid 29156, exit code 255, cmd
/opt/ros/kinetic/lib/nodelet/nodelet load
yocs_cmd_vel_mux/CmdVelMuxNodelet mobile_base_nodelet_manager
cmd_vel_mux/output/cmd_vel:=cmd_vel __name:=cmd_vel_mux
__log:=/home/dcr/.ros/log/c1b4f756-e2df-11ea-a825-5800e30310dd/cmd_vel_mux-8.log].
log file:
/home/dcr/.ros/log/c1b4f756-e2df-11ea-a825-5800e30310dd/cmd_vel_mux-8*.log
第一段翻译:
[ERROR] [1597926212.144023519, 0.092000000]: The error before
refreshing the cache was: According to the loaded plugin
descriptions the class yocs_cmd_vel_mux/CmdVelMuxNodelet with
base class type nodelet::Nodelet does not exist.
即使刷新缓存后,也无法加载类型为[yocs_cmd_vel_mux / CmdVelMuxNodelet]的nodelet [/ cmd_vel_mux]:根据已加载的插件描述,不存在基类类型为nodelet :: Nodelet的yocs_cmd_vel_mux / CmdVelMuxNodelet类。
造成这个error的原因是缺失了yocs_cmd_vel_mux包,这个包是对机器人进行速度调节的包,在这个sim_demo里对xbot机器人进行速度调节的node是/cmd_vel_mux。
解决办法:
sudo apt-get install ros-kinetic-yocs-cmd-vel-mux
然后再运行
roslaunch robot_sim_demo robot_spawn.launch