This package provides a ROS 2 launch file to initialize and configure the OAK-D camera for RGBD, stereo, and point cloud processing. It includes adjustable camera configurations for transform frames, position, orientation, and depth processing parameters, along with a sample RViz configuration.
-
Execute the below command to install the required dependencies:
sudo wget -qO- https://docs.luxonis.com/install_dependencies.sh | bash
Please refer to Installation documentation if any issues occur.
-
Clone the repository and add it to your ROS 2 workspace:
git clone https://github.com/jmguerreroh/oak_d_camera.git
-
Install dependencies:
rosdep install --from-paths src --ignore-src -r -y
-
Build the workspace:
colcon build --symlink-install
To launch the OAK-D camera node with default parameters:
ros2 launch oak_d_camera rgbd_stereo.launch.py
The launch file provides several configurable arguments:
camera_model
: Model of the camera. Options:OAK-D
,OAK-D-LITE
. Default:OAK-D-LITE
tf_prefix
: TF prefix for camera frames. Default:oak
base_frame
: Name of the camera's base frame. Default:oak-d_frame
parent_frame
: Parent frame for the camera's base. Default:oak-d-base-frame
cam_pos_x
,cam_pos_y
,cam_pos_z
: Camera position relative to the base frame. Default:0.0
cam_roll
,cam_pitch
,cam_yaw
: Camera orientation relative to the base frame. Default:0.0
lrcheck
: Enable left-right consistency check. Default:True
extended
: Enable extended disparity range. Default:False
subpixel
: Enable subpixel accuracy. Default:True
confidence
: Set confidence threshold for depth estimation. Default:200
LRchecktresh
: Set left-right consistency threshold. Default:5
Please refer to StereoDepth documentation for more information.
only_rgb
: Enable publishing of only RGB images. Default:False
use_rviz
: Launch RViz for visualization. Default:True
use_depth
: Enable depth image publishing. Default:True
use_disparity
: Enable disparity image publishing. Default:True
use_lr_raw
: Enable left and right raw image publishing. Default:True
use_pointcloud
: Enable point cloud publishing. Default:True
pc_color
: Use color in the point cloud. Options:True
for color orFalse
for intensity. Default:True
The launch file opens RViz with a pre-configured view. You can modify rviz/rgbd_stereo_pcl.rviz
to customize the visualization.
This project was made by José Miguel Guerrero, Associate Professor at Universidad Rey Juan Carlos.
Copyright © 2024.
This work is licensed under the terms of the MIT license.