1. 安装Ubuntu20的Ros版本,把Cart2.0版本编译一下,遇到点小问题

问题:

CMake Error: The following variables are used in this project, but they are set to NOTFOUND.

Please set them or make sure they are set and tested correctly in the CMake files:

GMOCK_LIBRARY (ADVANCED)

 linked by target "time_conversion_test" in directory /home/wishchin/catkin_ws/src/cartographer_ros/cartographer_ros

.......................

    linked by target "msg_conversion_test" in directory /home/wishchin/catkin_ws/src/cartographer_ros/cartographer_ros

-- Configuring incomplete, errors occurred!

See also "/home/wishchin/catkin_ws/build/CMakeFiles/CMakeOutput.log".

See also "/home/wishchin/catkin_ws/build/CMakeFiles/CMakeError.log".

Invoking "cmake" failed

解决方法:sudo apt install libgmock-dev,安装了一个新版本,catkin_make编译成功;

2.Ros版本的Slam模式源代码

问题:在node.cc和node.h中

void Node::PublishLocalTrajectoryData(const ::ros::TimerEvent& timer_event) {

absl::MutexLock lock(&mutex_);

这个函数有问题,参数错了

修改为

void Node::PublishLocalTrajectoryData(const ::ros::WallTimerEvent& & timer_event) {

absl::MutexLock lock(&mutex_);

则可以使用Slam模式

Logo

聚焦RDK与具身智能,汇集机器人开发教程、开源案例和技术交流

更多推荐