yahboom
HomeLearn
Solution
Blog
Online Store
About Us
EN/中文
NUWA-HP60C Depth Camera📖
1.ROS1-Depth camera usage course
  • 1. Environment Construction
  • 2. Camera recording video
2.ROS1-ROS+OpenCV application
  • 1.ROS+Opencv Basics
  • 2.Face recognition
  • 3.Harris corner detection
  • 4. Target Tracking Algorithm
  • 5. Contour moment
  • 6. Polygonal Outlines
  • 7. Discrete Fourier Transform Algorithm
  • 8. Edge Detection Algorithm
  • 9. Face Detection Algorithm
  • 10. Optical flow detection algorithm
  • 11. Contour Detection
  • 12. General contour detection
  • 13. Feature point tracking
  • 14.HLS Color Filtering
  • 15. Hough circle detection
  • 16. Hough Line Detection
  • 17.HSV color filtering
  • 18.LK optical flow algorithm
  • 19. Human Detection Algorithm
  • 20. Phase-correlated displacement detection
  • 21. Image pyramid sampling algorithm
  • 22.RGB color filtering
  • 23. Clear background detection algorithm
  • 24. Streamlining the optical flow algorithm
  • 25. Simple Filter
  • 26. Threshold Image Processing
  • 27. Watershed segmentation algorithm
3.ROS1-Mediapipe course
  • 1.Hand detection
  • 2.Posture detection
  • 3.Overall detection
  • 4.Face Mesh
  • 5.Face recognition
  • 6.Face effects
  • 7.Face Detection
  • 8.3D Object Recognition
  • 9.Paintbrush
  • 10.Finger control
  • 11.Gesture Recognition
4.ROS1-Depth camera application course
  • 1. Camera calibration
  • 2. QR code
  • 3. Human Pose Estimation
  • 4. Target detection
  • 5. Point cloud data viewing
  • 6. AR Vision
  • 7.AR QR code tracking
  • 8. Color Tracking
  • 9. Object Tracking
5.ROS1-Linux basic course
  • 1.Introduction to Linux system
  • 2.Ubuntu file system
  • 3.Ubuntu common commands
  • 4.Ubuntu common editors
  • 5.Ubuntu software operation commands
  • 6.Virtual machine installation
  • 7.SSH remote control
  • 8.VNC remote control
  • 9.Transfer files remotely
  • 10.Driver library and communication
  • 11.Static IP and hotspot mode
  • 12.Bind device ID
  • 13.Capacity expansion and resource allocation
  • 14.Update system software sources
  • 15.Set root user password
  • 16.sudo free password
  • 17.Connect to WiFi network
  • 18.View system version
  • 19.Customized service management
  • 20.Back up system image
6.ROS1-OpenCV course
  • 1.Opencv Source CV Introduction
  • 2.Image reading and display
  • 3.Picture writing
  • 4.Picture Quality
  • 5.Pixel Operation
  • 6.Picture scaling
  • 7.Picture cutting
  • 8.Picture translation
  • 9.Picture mirroring
  • 10.Affine transformation
  • 11.Picture rotation
  • 12.Perspective transformation
  • 13.Grayscale processing
  • 14.Image binarization
  • 15.Edge detection
  • 16.Line segment drawing
  • 17.Rectangle and circle drawing
  • 18.Text and picture drawing
7.ROS1 basic course
  • 1.ROS introduction
  • 2.ROS installation
  • 3.ROS common command tools
  • 4.ROS workspace
  • 5.ROS function package
  • 6.ROS node
  • 7.ROS topic publisher
  • 8.ROS topic subscribers
  • 9.ROS service client
  • 10.ROS service server
  • 11.ROS action client
  • 12.ROS action server
  • 13.ROS custom message reception
  • 14.ROS-launch file
  • 15.ROS-TF transformation
  • 16.ROS parameter service
  • 17.ROS-rviz use
  • 18.ROS-rqt tool usage
  • 19.Topic message recording and playback
  • 20.urdf model introduction
  • 21.gazebo introduction
  • 22.ROS distributed communication
8.ROS2-Depth Camera Application Course
  • 1. Use of Depth Camera
  • 2. Camera internal parameter calibration
  • 3. Color tracking
  • 4. KCF Object Tracking
  • 5. ORBSLAM2 Basics
  • 6. ORB_SLAM2 PCL Mapping
  • 7. ORB_SLAM2 Octomap Mapping
9.ROS2-OpenCV course
  • 1. ROS+OpenCV application
  • 2. QR code creation and recognition
  • 3. AR Vision
10.ROS2-Mediapipe course
  • 1.Hand detection
  • 2.Posture detection
  • 3.Overall detection
  • 4.Face Mess
  • 5.Face recognition
11.ROS2 basic course
  • 1.Introduction to ROS2
  • 2.ROS2 install Humble
  • 3.ROS2 development environment
  • 4.ROS2 workspace
  • 5.ROS2 function package
  • 6.ROS2 node
  • 7.ROS2 topic communication
  • 8.ROS2 service communication
  • 9.ROS2 action communication
  • 10.ROS2 custom interface message
  • 11.ROS2 parameter service case
  • 12.ROS2 meta-function package
  • 13.ROS2 distributed communication
  • 14.ROS2 DDS
  • 15.ROS2 time related API
  • 16.ROS2 common command tools
  • 17.ROS2 rviz2 use
  • 18.ROS2 rqt toolbox
  • 19.ROS2 Launch startup file configuration
  • 20.ROS2 recording and playback tool
  • 21.ROS2 URDF model
  • 22.ROS2 Gazebo simulation platform
  • 23.ROS2 TF2 coordinate transformation
5.Bracket installation video
  • Bracket installation video
Download
  • ROS1_VM
  • ROS2_VM
  • ROS1_Code
  • ROS2_Code
  • DataSheet
  • 3D_Model_File
  • Windows Software
  • ROS2_Basic_VM
Download ZIP

Welcome to NUWA-HP60C Depth Camera repository

6. ORB_SLAM2 PCL Mapping

6. ORB_SLAM2 PCL Mapping

Note: This example is implemented on Orin NX, and cannot be implemented on a virtual machine. It only explains how the process is implemented. If you want to implement this function on your own motherboard, you need to compile the entire function package and connect related peripherals and debug.

6. ORB_SLAM2 PCL Mapping6.1, Introduction6.2, Use6.3, Node analysis6.3.1, Display calculation graph6.3.2, pointcloud_mapping node details6.3.3, TF transformation

pcl official website address: http://pointclouds.org

pcl_ros wiki: https://wiki.ros.org/pcl_ros

pcl_ros github: https://github.com/ros-perception/perception_pcl

The operating environment and reference configuration of software and hardware are as follows:

  • Reference vehicle: ROSMASTER X3
  • Robot hardware configuration: Arm series master control, Silan A1 laser radar, depth camera
  • Robot system: Ubuntu 20.04
  • PC virtual machine: Ubuntu (20.04) + ROS2 (Foxy)
  • Usage scenario: Use on a relatively clean 2D plane

6.1, Introduction

PCL (The Point Cloud Library) is a large open source project for 2D/3D image and point cloud processing. The PCL framework consists of many advanced algorithms, including filtering, feature estimation, surface reconstruction, registration, model stitching and segmentation. These algorithms have many applications, such as filtering outliers from noisy data, merging multiple sets of 3D point clouds, segmenting related parts of a scene, extracting key points and calculating geometric descriptors for object recognition, creating and visualizing object surfaces using point clouds, and so on. PCL has been successfully compiled and configured on Linux, MacOS, Windows, and Android/iOS platforms. To simplify development, PCL is divided into a series of small code libraries that can be compiled separately.

Basic concepts of the point cloud library and the PCL interface of ROS:

Point cloud library: provides a set of data structures and algorithms for processing 3D data;

ROS PCL interface: provides a set of messages and conversion functions between messages and PCL data structures.

From a C++ perspective, PCL contains a very important data structure, which is the point cloud. This data structure is designed as a template class, which takes the type of point as a parameter of the template class. The point cloud class is actually a container that contains all the common information required by the point cloud, regardless of the type of point. The following are the most important public fields in the point cloud:

header: This field is of type pcl:PCLHeader. Specifies the time when the point cloud was acquired.

points: This field is of type std::vector<PointT…>, which is a container for all points. PointT in the vector definition corresponds to the template parameter of the class, i.e. the type of point.

width: This field specifies the width of the point cloud when it is organized into an image, otherwise it contains the number of points in the cloud.

height: This field specifies the height of the point cloud when it is organized into an image, otherwise it is always 1.

is_dense: This field specifies whether there are invalid values (infinite or NaN values) in the point cloud.

sensor origin: This field is of type Eigen::Vector4f, and defines the pose of the sensor according to the translation relative to the origin.

sensororientation: This field is of type Eigen::Ouaternionf, and defines the pose of the sensor when it is rotated.

6.2, Use

  1. Start the camera
#Camera start
ros2 launch astra_camera gemini.launch.xml
  1. Start orbslam to publish the camera pose, color image and depth image. Depending on the performance of different master controllers, the waiting time here is about 10 seconds
xxxxxxxxxx
ros2 launch yahboomcar_slam orbslam_base_launch.py

image-20230418094624816

  1. Start point cloud mapping
xxxxxxxxxx
ros2 launch yahboomcar_slam orbslam_pcl_map_launch.py

After opening, the [viewer] window will pop up. Slowly move the camera. When a picture appears, as shown below:

image-20230418094841269

You need to scale and rotate the coordinate system until it is as shown below

Slide the wheel: zoom in and out

Press and hold the wheel: pan

Left mouse button: rotate

Right mouse button: zoom in and out

You can open rviz at the same time to view the real-time point cloud mapping effect. Considering the huge CPU and memory overhead during point cloud mapping, it is recommended to use the virtual machine to open rviz to view:

xxxxxxxxxx
ros2 launch yahboomcar_slam display_pcl_launch.py

image-20230419112209078

image-20230418095240459

  1. Slowly move the camera to build the map as shown below. After building, press [Ctrl+c] to close and automatically save the pcd point cloud file. esultPointCloudFile.pcd, the path is as follows:
xxxxxxxxxx
~/ascam_ros2_ws/src/yahboomcar_slam/pcl/resultPointCloudFile.pcd
  1. View the resultPointCloudFile.pcd file

(1) Method 1: Use the pcl_viewer tool

Install the pcl_viewer command:

xxxxxxxxxx
sudo apt-get install pcl-tools

Enter the directory where the pcd file is located and enter the following command to view the pcd point cloud image

xxxxxxxxxx
pcl_viewer resultPointCloudFile.pcd

(2) Method 2: Use the pcd-viewer plug-in of vscode [Recommended]

First install the pcd-viewer plug-in in vscode, then open resultPointCloudFile.pcd to view the pcd point cloud image. Here, directly select the Y+ direction and the RGBA mode at the bottom to quickly rotate the image to the main view

image-20230419113618139

6.3, Node analysis

6.3.1, Display calculation graph

xxxxxxxxxx
rqt_graph

6.3.2, pointcloud_mapping node details

image-20230419121854299

6.3.3, TF transformation

xxxxxxxxxx
ros2 run tf2_tools view_frames.py 

image-20230419144328427

ORBSLAM2 Basics
ORB_SLAM2 Octomap Mapping

COMPANY

  • About us
  • Team Style
  • Blog

LEARNING & EXPLORATION

  • Tutorials
  • Edge AI hardware
  • Educational robots
  • Embedded intelligent hardware

WHERE TO BUY

  • Yahboom Online Store
  • Amazon
  • Alibaba
  • AliExpress
  • Mercado

TECHNOLOGY SUPPORT

  • Email: support@yahboom.com

BE A DISTRIBUTOR

  • Email: sales@yahboom.com
QR Code

Copyright © 2017-2026 Yahboom. All Rights Reserved.

EN/中文