Depth Camera ROS 2 Package Usage (Aurora933)
Hint
This document provides a standalone description of the build, launch, topic inspection, RViz display, and parameter configuration of the Aurora930 / Aurora933 depth camera ROS 2 package.
- Robot side: Ubuntu 22.04 + ROS 2 Humble
- Depth camera: Deptrum / Guangjian Aurora930 series; the car uses Aurora933
- ROS 2 driver source package:
deptrum-ros-driver-aurora930-aarch64-0.2.11-source.tar.gz - Build option:
-DSTREAM_SDK_TYPE=AURORA930 - Default namespace:
/aurora - Main outputs: RGB images, IR images, Depth images, and PointCloud2 point clouds
- The main difference between Aurora930 and Aurora933 is that the former has no glass dust cover, while the latter has a dust-proof glass cover.
Package/resource archive download link: (refer to Kit resources/Resource links to download)
Scenario Description
This package connects Aurora930 series depth cameras to a ROS 2 system and publishes RGB, IR, Depth, point cloud, and camera intrinsic topics for subsequent functions such as object detection, depth localization, robotic arm grasping, obstacle perception, and RViz visualization.
After the ROS 2 driver is started, the common outputs are as follows:
/aurora/rgb/image_raw: Color image, suitable for object detection, QR code recognition, and image preview./aurora/depth/image_raw: Depth image, encoded as 16-bit depth data and usually treated as millimeter-level depth./aurora/ir/image_raw: Infrared image, used for infrared imaging and debugging./aurora/points2: Point cloud data, used for 3D display and spatial localization in RViz./aurora/rgb/camera_info,/aurora/ir/camera_info: Camera intrinsic information.
Attention
Before starting the ROS 2 driver, it is recommended to complete the USB enumeration, udev permission, and SDK example test steps described in the hardware test document. If the SDK example cannot open the camera, the ROS 2 driver usually cannot open the camera normally either.
ROS 2-Related Content in the Resource Package
The ROS 2 package-related content in the archive is as follows:
930_SDK等文件/
└── 930_ROS/
└── ROS2/
└── ros2源码/
└── deptrum-ros-driver-aurora930-aarch64-0.2.11-source.tar.gz
The main structure of the extracted ROS 2 source package is as follows:
deptrum-ros-driver-aurora930-0.2.11/
├── CMakeLists.txt
├── package.xml
├── docs/
│ ├── building.md
│ └── usage_aurora930.md
├── launch_aurora930/
│ └── launch/
│ ├── aurora930_launch.py
│ ├── aurora930_multi_launch.py
│ ├── viewer930_launch.py
│ └── sub_node_ci_aurora930_launch.py
├── rviz/
│ └── aurora930-ros2.rviz
├── src/
├── include/
├── subscribe_node/
└── ext/
The commonly used files are described below:
| File / Directory | Purpose |
|---|---|
aurora930_launch.py |
Starts the Aurora930 depth camera driver node |
viewer930_launch.py |
Starts RViz and loads the official RViz configuration |
aurora930_multi_launch.py |
Multi-device launch reference |
sub_node_ci_aurora930_launch.py |
Starts the example node that subscribes to and saves images |
rviz/aurora930-ros2.rviz |
RViz display configuration for Aurora930 |
subscribe_node/ |
Example program for image subscription and saving |
Step 1: Install Basic ROS 2 Dependencies
In an Ubuntu 22.04 + ROS 2 Humble environment, it is recommended to install the common dependencies first:
sudo apt update
sudo apt install -y \
build-essential \
cmake \
python3-colcon-common-extensions \
libusb-1.0-0-dev \
libudev-dev \
libopencv-dev \
libgoogle-glog-dev \
libgflags-dev \
ros-humble-cv-bridge \
ros-humble-image-transport \
ros-humble-camera-info-manager \
ros-humble-tf2 \
ros-humble-tf2-ros \
ros-humble-tf2-geometry-msgs \
ros-humble-angles \
ros-humble-rviz2 \
ros-humble-rqt-image-view
Source the ROS 2 environment:
Attention
If the system is not Humble, replace humble in the commands with the name of the current ROS 2 distribution.
Step 2: Prepare the ROS 2 Workspace
Create a workspace:
Copy the ROS 2 source archive from the resource package to ~/dev_ws/src and extract it:
After extraction, the directory is usually:
You can rename it to a shorter directory name:
The recommended final structure is as follows:
~/dev_ws/
└── src/
└── deptrum-ros-driver/
├── CMakeLists.txt
├── package.xml
├── launch_aurora930/
├── rviz/
├── src/
├── include/
├── subscribe_node/
└── ext/
Step 3: Confirm the ROS 2 Package Name
The package name used by the launch files in the driver source is:
If the package name in package.xml is not deptrum-ros-driver-aurora930, it must be changed.
Enter the source directory:
Check the package name:
If the output is not the following:
You can perform a one-time replacement:
Attention
Run the sed replacement command only once. Before running it, confirm the package name with grep "<name>" package.xml to avoid an invalid package name caused by repeated replacement.
Step 4: Build the ROS 2 Package
Return to the workspace root directory:
Build for the Aurora930 type:
If you have switched the SDK type or modified the CMake configuration, you can force a reconfigure:
After the build is complete, source the workspace environment:
Check whether the package is visible:
Normally, the following should be displayed:
Step 5: Start the Depth Camera Driver
Run the following in a terminal:
source /opt/ros/humble/setup.bash
source ~/dev_ws/install/setup.bash
ros2 launch deptrum-ros-driver-aurora930 aurora930_launch.py
The namespace is set by default in the driver launch file:
Therefore, the actual topic names are prefixed with /aurora.
After a successful launch, open another terminal to inspect the topics:
A common output is as follows:
/aurora/rgb/image_raw
/aurora/rgb/camera_info
/aurora/ir/image_raw
/aurora/ir/camera_info
/aurora/depth/image_raw
/aurora/points2
Check the frame rate of the depth image:
Check the point cloud topic information:
Step 6: RViz Visualization
Option 1: Start with the Official RViz Configuration
The driver package already contains the RViz configuration file for Aurora930, so you can start it directly:
source /opt/ros/humble/setup.bash
source ~/dev_ws/install/setup.bash
ros2 launch deptrum-ros-driver-aurora930 viewer930_launch.py
This command opens RViz and loads:
Option 2: Open RViz Manually
If you need to configure RViz manually, run:
Configure RViz as follows:
- Set
Fixed FrameunderGlobal Optionsto:
- Click
Add, selectBy topic, and add the following display items:
Attention
If you run RViz directly in an SSH terminal, qt.qpa.xcb: could not connect to display may appear. This is a graphical display environment issue, not a camera driver issue. It is recommended to run RViz on a PC on the same ROS 2 network, or use a remote desktop / X11 forwarding.
Step 7: View Images with rqt_image_view
If you only want to view images and do not need the point cloud, you can use rqt_image_view:
After starting it, select the topic to view:
Where:
- The RGB image is used to confirm whether the color camera image is normal.
- The Depth image is used to confirm whether the depth data is normal.
- The IR image is used to confirm whether the infrared module is normal.
Step 8: Save Image Data
The driver source contains the subscribe_node example program, which can subscribe to the topics published by the driver and save RGB, IR, and Depth images locally.
After starting the depth camera driver, run the following in another terminal:
source /opt/ros/humble/setup.bash
source ~/dev_ws/install/setup.bash
cd ~/dev_ws/install/deptrum-ros-driver-aurora930/lib/deptrum-ros-driver-aurora930
./sub_node
The default save path is:
You can also use launch to start the subscriber node:
Attention
The depth camera driver node must be started before saving images; otherwise, the subscriber node has no data source.
Common Launch Parameters
aurora930_launch.py provides several adjustable parameters that can be overridden on the command line at launch time.
| Parameter Name | Default Value | Purpose |
|---|---|---|
rgb_enable |
true |
Whether to publish RGB color images |
ir_enable |
true |
Whether to publish IR infrared images |
depth_enable |
true |
Whether to publish depth images |
rgbd_enable |
false |
Whether to enable RGBD mode |
point_cloud_enable |
true |
Whether to publish point cloud data; depends on the depth image |
boot_order |
1 |
Camera startup order configuration |
ir_fps |
15 |
IR frame rate; selectable values are usually 5 / 10 / 12 / 15 |
rgb_fps |
15 |
RGB frame rate; should be less than or equal to the IR frame rate |
exposure_enable |
false |
Whether to set exposure manually |
exposure_time |
1 |
Exposure time; the range is usually 1 to 31 |
gain_enable |
false |
Whether to set gain manually |
gain_value |
20 |
Gain value; the range is usually 10 to 160 |
usb_port_number |
Empty | Specifies the USB port number to distinguish multiple devices |
threshold_size |
110 |
Denoising filter size |
depth_correction |
true |
Whether to enable depth correction |
align_mode |
true |
Whether to enable RGBD / IR alignment mode |
laser_power |
1.0 |
Laser power mode; common meanings: 1 auto, 2 indoor, 3 outdoor |
minimum_filter_depth_value |
150 |
Minimum depth filter value |
maximum_filter_depth_value |
4000 |
Maximum depth filter value |
resolution_mode_index |
2 |
Resolution mode index |
log_dir |
/tmp/ |
Log output directory |
stream_sdk_log_enable |
true |
Whether to enable SDK logs |
heart_enable |
false |
Whether to enable heartbeat detection |
Start only the RGB and depth images and do not publish point clouds:
ros2 launch deptrum-ros-driver-aurora930 aurora930_launch.py \
rgb_enable:=true \
ir_enable:=false \
depth_enable:=true \
point_cloud_enable:=false
Limit the maximum valid depth to 3 meters:
Reduce the load and keep only the depth image:
ros2 launch deptrum-ros-driver-aurora930 aurora930_launch.py \
rgb_enable:=false \
ir_enable:=false \
depth_enable:=true \
point_cloud_enable:=false
ROS 2 Topic Description
Because namespace="aurora" is set in the launch file, the complete topic names are as follows:
| Full Topic Name | Message Type | Purpose |
|---|---|---|
/aurora/rgb/image_raw |
sensor_msgs/msg/Image |
RGB color image, BGR888 / bgr8 format |
/aurora/rgb/camera_info |
sensor_msgs/msg/CameraInfo |
RGB camera intrinsics |
/aurora/ir/image_raw |
sensor_msgs/msg/Image |
IR infrared image |
/aurora/ir/camera_info |
sensor_msgs/msg/CameraInfo |
IR / Depth camera intrinsics |
/aurora/depth/image_raw |
sensor_msgs/msg/Image |
Depth image, 16-bit depth data |
/aurora/points2 |
sensor_msgs/msg/PointCloud2 |
Depth point cloud |
If other nodes subscribe to /camera/depth/image_raw or /camera/color/image_raw by default, you can connect them by remapping:
ros2 run your_package your_node --ros-args \
-r /camera/color/image_raw:=/aurora/rgb/image_raw \
-r /camera/depth/image_raw:=/aurora/depth/image_raw \
-r /camera/color/camera_info:=/aurora/rgb/camera_info \
-r /camera/depth/camera_info:=/aurora/ir/camera_info
Multi-Device Usage
If multiple ROS 2 devices are on the same LAN or the same host, you can set different ROS_DOMAIN_ID values to avoid confusion in DDS communication.
For example:
If you need the setting to take effect permanently:
For multiple depth cameras, you can also specify the device port with usb_port_number so that the driver does not open the wrong device.
Log Viewing
By default, the driver outputs logs to the /tmp/ directory. You can view the latest log symlink:
View the log contents:
You can also locate the driver log file:
Recommended Startup Procedure
For complete usage, it is recommended to open three terminals.
First Terminal: Start the Depth Camera Driver
source /opt/ros/humble/setup.bash
source ~/dev_ws/install/setup.bash
ros2 launch deptrum-ros-driver-aurora930 aurora930_launch.py
Second Terminal: View Topics and Frame Rate
source /opt/ros/humble/setup.bash
source ~/dev_ws/install/setup.bash
ros2 topic list | grep aurora
ros2 topic hz /aurora/depth/image_raw
Third Terminal: Image or Point Cloud Visualization
View images:
View the point cloud:
