mirror of
https://github.com/orbbec/OrbbecSDK_ROS2.git
synced 2026-10-04 12:07:46 +08:00
Enhance installation documentation by adding missing dependencies.
This commit is contained in:
@@ -6,6 +6,22 @@ Install ROS 2 according to the official guide:
|
|||||||
|
|
||||||
* [ROS 2 installation (Ubuntu)](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
|
* [ROS 2 installation (Ubuntu)](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
|
||||||
|
|
||||||
|
Install dependencies:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo apt install libgflags-dev nlohmann-json3-dev \
|
||||||
|
ros-$ROS_DISTRO-image-transport ros-${ROS_DISTRO}-image-transport-plugins ros-${ROS_DISTRO}-compressed-image-transport \
|
||||||
|
ros-$ROS_DISTRO-image-publisher ros-$ROS_DISTRO-camera-info-manager \
|
||||||
|
ros-$ROS_DISTRO-diagnostic-updater ros-$ROS_DISTRO-diagnostic-msgs ros-$ROS_DISTRO-statistics-msgs ros-$ROS_DISTRO-xacro \
|
||||||
|
ros-$ROS_DISTRO-backward-ros libdw-dev libssl-dev
|
||||||
|
```
|
||||||
|
|
||||||
|
Enable ROS 2 auto-completion:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
eval "$(register-python-argcomplete3 ros2)"
|
||||||
|
eval "$(register-python-argcomplete3 colcon)"
|
||||||
|
```
|
||||||
#### Linux Binary Package Installation
|
#### Linux Binary Package Installation
|
||||||
|
|
||||||
Check available packages:
|
Check available packages:
|
||||||
@@ -27,18 +43,7 @@ After installation, you can use it directly without compilation.
|
|||||||
|
|
||||||
### Build from Source
|
### Build from Source
|
||||||
|
|
||||||
#### Environment
|
#### Linux ROS2 Wrapper Compilation
|
||||||
|
|
||||||
Install ROS 2 according to the official guide:
|
|
||||||
|
|
||||||
* [ROS 2 installation (Ubuntu)](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
|
|
||||||
|
|
||||||
Enable ROS 2 auto-completion:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
eval "$(register-python-argcomplete3 ros2)"
|
|
||||||
eval "$(register-python-argcomplete3 colcon)"
|
|
||||||
```
|
|
||||||
|
|
||||||
Create a `colcon` workspace:
|
Create a `colcon` workspace:
|
||||||
|
|
||||||
@@ -46,8 +51,6 @@ Create a `colcon` workspace:
|
|||||||
mkdir -p ~/ros2_ws/src
|
mkdir -p ~/ros2_ws/src
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Linux ROS2 Wrapper Compilation
|
|
||||||
|
|
||||||
Clone source and checkout `v2-main` branch:
|
Clone source and checkout `v2-main` branch:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@@ -57,16 +60,6 @@ cd OrbbecSDK_ROS2
|
|||||||
git checkout v2-main
|
git checkout v2-main
|
||||||
```
|
```
|
||||||
|
|
||||||
Install dependencies:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
sudo apt install libgflags-dev nlohmann-json3-dev \
|
|
||||||
ros-$ROS_DISTRO-image-transport ros-${ROS_DISTRO}-image-transport-plugins ros-${ROS_DISTRO}-compressed-image-transport \
|
|
||||||
ros-$ROS_DISTRO-image-publisher ros-$ROS_DISTRO-camera-info-manager \
|
|
||||||
ros-$ROS_DISTRO-diagnostic-updater ros-$ROS_DISTRO-diagnostic-msgs ros-$ROS_DISTRO-statistics-msgs ros-$ROS_DISTRO-xacro \
|
|
||||||
ros-$ROS_DISTRO-backward-ros libdw-dev libssl-dev
|
|
||||||
```
|
|
||||||
|
|
||||||
Build:
|
Build:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|||||||
@@ -19,6 +19,11 @@ Make sure ROS 2 and your workspace environment are sourced:
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
source /opt/ros/$ROS_DISTRO/setup.bash
|
source /opt/ros/$ROS_DISTRO/setup.bash
|
||||||
|
```
|
||||||
|
|
||||||
|
Source code build requirements
|
||||||
|
|
||||||
|
```bash
|
||||||
source ~/ros2_ws/install/setup.bash
|
source ~/ros2_ws/install/setup.bash
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -4,6 +4,16 @@
|
|||||||
|
|
||||||
* [ROS 2 安装指南(Ubuntu)](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
|
* [ROS 2 安装指南(Ubuntu)](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
|
||||||
|
|
||||||
|
安装依赖项:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo apt install libgflags-dev nlohmann-json3-dev \
|
||||||
|
ros-$ROS_DISTRO-image-transport ros-${ROS_DISTRO}-image-transport-plugins ros-${ROS_DISTRO}-compressed-image-transport \
|
||||||
|
ros-$ROS_DISTRO-image-publisher ros-$ROS_DISTRO-camera-info-manager \
|
||||||
|
ros-$ROS_DISTRO-diagnostic-updater ros-$ROS_DISTRO-diagnostic-msgs ros-$ROS_DISTRO-statistics-msgs ros-$ROS_DISTRO-xacro \
|
||||||
|
ros-$ROS_DISTRO-backward-ros libdw-dev libssl-dev
|
||||||
|
```
|
||||||
|
|
||||||
启用 ROS 2 自动补全:
|
启用 ROS 2 自动补全:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@@ -11,12 +21,6 @@ eval "$(register-python-argcomplete3 ros2)"
|
|||||||
eval "$(register-python-argcomplete3 colcon)"
|
eval "$(register-python-argcomplete3 colcon)"
|
||||||
```
|
```
|
||||||
|
|
||||||
创建 `colcon` 工作空间:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
mkdir -p ~/ros2_ws/src
|
|
||||||
```
|
|
||||||
|
|
||||||
### 二进制安装
|
### 二进制安装
|
||||||
|
|
||||||
#### Linux 二进制包安装
|
#### Linux 二进制包安装
|
||||||
@@ -42,6 +46,12 @@ sudo apt install ros-humble-orbbec-camera ros-humble-orbbec-description
|
|||||||
|
|
||||||
#### Linux ROS2 包装器编译
|
#### Linux ROS2 包装器编译
|
||||||
|
|
||||||
|
创建 `colcon` 工作空间:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mkdir -p ~/ros2_ws/src
|
||||||
|
```
|
||||||
|
|
||||||
克隆源代码并切换到 `v2-main` 分支:
|
克隆源代码并切换到 `v2-main` 分支:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@@ -51,16 +61,6 @@ cd OrbbecSDK_ROS2
|
|||||||
git checkout v2-main
|
git checkout v2-main
|
||||||
```
|
```
|
||||||
|
|
||||||
安装依赖项:
|
|
||||||
|
|
||||||
```bash
|
|
||||||
sudo apt install libgflags-dev nlohmann-json3-dev \
|
|
||||||
ros-$ROS_DISTRO-image-transport ros-${ROS_DISTRO}-image-transport-plugins ros-${ROS_DISTRO}-compressed-image-transport \
|
|
||||||
ros-$ROS_DISTRO-image-publisher ros-$ROS_DISTRO-camera-info-manager \
|
|
||||||
ros-$ROS_DISTRO-diagnostic-updater ros-$ROS_DISTRO-diagnostic-msgs ros-$ROS_DISTRO-statistics-msgs ros-$ROS_DISTRO-xacro \
|
|
||||||
ros-$ROS_DISTRO-backward-ros libdw-dev libssl-dev
|
|
||||||
```
|
|
||||||
|
|
||||||
构建:
|
构建:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
|||||||
@@ -19,6 +19,11 @@
|
|||||||
|
|
||||||
```bash
|
```bash
|
||||||
source /opt/ros/$ROS_DISTRO/setup.bash
|
source /opt/ros/$ROS_DISTRO/setup.bash
|
||||||
|
```
|
||||||
|
|
||||||
|
源码构建需要
|
||||||
|
|
||||||
|
```bash
|
||||||
source ~/ros2_ws/install/setup.bash
|
source ~/ros2_ws/install/setup.bash
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -89,4 +94,3 @@ ros2 service call /camera/get_device_info orbbec_camera_msgs/srv/GetDeviceInfo '
|
|||||||
```bash
|
```bash
|
||||||
ros2 bag record /camera/color/image_raw /camera/depth/image_raw
|
ros2 bag record /camera/color/image_raw /camera/depth/image_raw
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user