一分钟完成 RobCo ROS2 binding 安装
基于 RobCo 官方文档,本指南介绍如何仅用一个 shell 脚本完成 RobCo ROS2 binding 的安装。
install-ros2-binding.sh
mkdir -p robco_ws/src
cd robco_ws/src
git clone https://gitlab.com/robco-public/ros/robco_ros2
cd ..
rosdep update
rosdep install --from-paths src --ignore-src
colcon build
source install/local_setup.sh如下输出仅为警告,并不表示安装失败,可以安全忽略:
robco_hardware_warning.txt
--- stderr: robco_hardware
/tmp/zz/robco_ws/src/robco_ros2/robco_hardware/src/robco_hardware.cpp: In member function ‘virtual CallbackReturn robco_hardware::RobcoHardware::on_init(const hardware_interface::HardwareInfo&)’:
/tmp/zz/robco_ws/src/robco_ros2/robco_hardware/src/robco_hardware.cpp:20:51: warning: ‘virtual rclcpp_lifecycle::node_interfaces::LifecycleNodeInterface::CallbackReturn hardware_interface::HardwareComponentInterface::on_init(const hardware_interface::HardwareInfo&)’ is deprecated: Use on_init(const HardwareComponentInterfaceParams & params) instead. [-Wdeprecated-declarations]
20 | if (hardware_interface::SystemInterface::on_init(info) != CallbackReturn::SUCCESS) {
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~
In file included from /opt/ros/jazzy/include/hardware_interface/hardware_interface/system_interface.hpp:18,
from /tmp/zz/robco_ws/src/robco_ros2/robco_hardware/include/robco_hardware/robco_hardware.hpp:6,
from /tmp/zz/robco_ws/src/robco_ros2/robco_hardware/src/robco_hardware.cpp:1:
/opt/ros/jazzy/include/hardware_interface/hardware_interface/hardware_component_interface.hpp:140:26: note: declared here
140 | virtual CallbackReturn on_init(const HardwareInfo & hardware_info);
| ^~~~~~~
---
Summary: 4 packages finished [10.6s]
1 package had stderr output: robco_hardwareCheck out similar posts by category:
Robotics
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow