Welcome to ROSMASTER M3 repository
01.Dabai_DCW2 Camera Introduction
Dabai_DCW2 Camera Introduction
Dabai_DCW2 Camera Introduction1. Course Content2. Camera Introduction3. Start Camera Node3.1 Subscribe to Color Image3.2 Subscribe to Depth Image3.3 Subscribe to Infrared Image3.4 Subscribe to Image Point Cloud
1. Course Content
[!IMPORTANT]
This course section is only for users with the Dabai_DCW2 camera package to view and reference
- Run example programs, use Orbbec's depth camera - Dabai_DCW2, to view color images, depth images, infrared images, and point clouds published by camera nodes.
2. Camera Introduction
DaBai DCW2/DW2 depth camera obtains object depth images based on binocular structured light 3D imaging technology, while using a color camera to capture object color images. It is suitable for intelligent products that perform 3D object scanning at distances of 0.2m-5m, and can achieve object depth data measurement within the measurement range.

IR: Infrared camera
LDP: Laser dot matrix projector
LDM: Laser drive module
RGB: Color camera
Features of DaBai DCW2:
- Low reflectivity objects: Can effectively recognize objects with 5% reflectivity
- Anti-interference: Comprehensively improved electromagnetic compatibility and anti-static capabilities
- Balanced field of view: H-FOV: 91° V-FOV: 62°
- Energy level switching: Provides two energy level modes for customer adaptation
- Depth image: Supports up to 640*400 depth resolution
- Working distance: 0.15m-5m
- Depth accuracy: <1%@1m
- Interface: USB2.0 Type C
3. Start Camera Node
For Raspberry Pi 5 users, if the ROS container is not started, you need to start the container first,
bringup_m3Open a terminal inside the container,
xxxxxxxxxxexec_m3- Enter command in terminal
xxxxxxxxxxros2 launch m3_bringup bringup_camera.launch.pySuccessfully driven camera screen is as follows

- If the camera cannot be started, you need to check if the camera connection to the mainboard/Hub expansion board is loose. You can use ros2 node tools to view which topics the camera node has published and which services are provided. Enter in terminal,
xxxxxxxxxxros2 node info /camera/cameraPublished topics are as shown in the figure below,

Provided services are as shown in the figure below,

3.1 Subscribe to Color Image
According to the queried node information, the following color image topics can be found;
/camera/color/image_raw: Color image topic /camera/color/image_raw/compressed: Compressed color image topic /camera/color/image_raw/compressedDepth: Depth compressed color image topic /camera/color/image_raw/theora: Color image topic compressed using theora encoder
After the camera is started, you can enter the following command in the terminal to start the rqt_images_view tool, and view images according to the selected image topic. Enter in terminal,
xxxxxxxxxxros2 run rqt_image_view rqt_image_view
As shown in the red box in the figure above, the color image topic /camera/color/image_raw is selected for display.
3.2 Subscribe to Depth Image
According to the queried node information, the following depth image topics can be found:
/camera/depth/image_raw: Depth image topic /camera/depth/image_raw/compressed: Compressed depth image topic /camera/depth/image_raw/compressedDepth: Depth compressed depth image topic /camera/depth/image_raw/theora: Depth image topic compressed using theora encoder
Similarly, we can enter the command mentioned above ros2 run rqt_image_view rqt_image_view in the terminal to start the rqt_images_view tool, and select the depth image topic to display depth images,

As shown in the figure above, the depth image of the /camera/depth/image_raw depth image topic is displayed.
3.3 Subscribe to Infrared Image
According to the queried node information, the following infrared image topics can be found:
/camera/ir/image_raw: Infrared image topic /camera/ir/image_raw/compressed: Compressed infrared image topic /camera/ir/image_raw/compressedDepth: Depth compressed infrared image topic /camera/ir/image_raw/theora: Infrared image topic compressed using theora encoder
rqt_image_view cannot display infrared images, we need to use the rviz tool to display them. Use the virtual machine and the car for distributed communication, start rviz on the virtual machine side to select plugins to display infrared images. Before this, you need to set up distributed communication between the virtual machine and the car. For detailed setup steps, please refer to the content in [0. Robot Configuration and Operation Guide] - [Car Virtual Machine Distributed Communication Setup] in this product tutorial. Open a terminal in the virtual machine and enter the following command to start rviz,
xxxxxxxxxxrviz2
Follow the arrow instructions in the figure above, and finally click [ok] to complete the selection. As shown in the figure below, the infrared image is successfully displayed

3.4 Subscribe to Image Point Cloud
According to the queried node information, it can be found that the camera node publishes image point clouds
/camera/depth/points: 3D depth point cloud information
/camera/depth_registered/points: Registered 3D point cloud topic (depth data (Depth) has been aligned (registered) with color image (RGB), ensuring each depth point corresponds to the correct color)
Use the rviz tool to display point cloud information. Similarly, you need to set up distributed communication between the virtual machine and the car. We enter rviz2 in the virtual machine terminal to start rviz, then make selections according to the following steps,

After selection is complete, we also need to set the coordinate system to camera_link, as shown in the figure below,

As shown in the figure below, the /camera/depth/points topic point cloud is displayed,

We can also modify the display settings of point clouds,

In [topic], select /camera/depth_registered/points to display the point cloud after aligning depth and color images; in [Color Transformer], select RGB8 to display RGB point clouds, as shown in the figure below
