Intel® RealSense™ ROS 2 Sample Application¶
This tutorial tells you how to:
Launch ROS nodes for a camera.
List ROS topics.
Confirm that Intel® RealSense™ topics are publishing data.
Retrieve data from the Intel® RealSense™ camera (data coming at FPS).
Visualize an image from the Intel® RealSense™ camera displayed in rviz2.
This Intel® RealSense™ ROS 2 Sample Application can be run using two different types of Intel® RealSense™ cameras. The next section explains how to run this sample application using an Intel® RealSense™ USB camera (for example, Intel® RealSense™ D435i). The subsequent section focuses on an Intel® RealSense™ Depth Camera D457 in MIPI mode, which is connected to an Axiomtek Robox500 ROS2 AMR Controller.
Using Intel® RealSense™ USB camera¶
Connect an Intel® RealSense™ USB camera (for example, Intel® RealSense™ D435i) to the host.
Install the
librealsense2
andrealsense2
tools:To download and install the Intel® RealSense™ ROS 2 sample application, run the command below:
Set up the ROS 2 environment:
Run the Intel® RealSense™ ROS 2 sample application:
Expected output: The image from the Intel® RealSense™ camera is displayed in rviz2, on the bottom left side.
To close this, do the following:
Type
Ctrl-c
in the terminal where the tutorial was run.
Using Intel® RealSense™ Depth Camera D457 on an Axiomtek Robox500 ROS2 AMR Controller¶
The following steps are required in order to setup the Axiomtek Robox500 ROS2 AMR Controller to support the Intel® RealSense™ Depth Camera D457.
Axiomtek Robox500 ROS2 AMR Controller Setup¶
Connect an Intel® RealSense™ Depth Camera D457 to the Axiomtek Robox500 ROS2 AMR Controller as shown in the below picture. Now, power-on the target.

Note
Select the “MIPI” mode of the Intel® RealSense™ Depth Camera D457 by moving the select switch on the camera to “M”, as shown in the below picture.

BIOS settings¶
Go to the BIOS menu by pressing “Del
” or “Esc
” button when the board is powered on. The following BIOS settings should be set to enable Intel® RealSense™ Depth Camera D457 support on an Axiomtek Robox500 ROS2 AMR Controller.
Intel Advanced Menu -> Power & Performance -> CPU-Power Management Control -> C States -> < Disable > (Note: If enabled, fps drops)
Intel Advanced Menu -> System Agent (SA) Configuration -> MIPI Camera Configuration -> < Enable > (Note: Enable all four cameras in this menu)
Camera BIOS settings.
BIOS setting |
Camera 1 |
Camera 2 |
Camera 3 |
Camera 4 |
---|---|---|---|---|
MIPI Port |
0 |
1 |
2 |
3 |
Lane user |
x2 |
x2 |
x2 |
x2 |
Port speed |
2 |
2 |
2 |
2 |
I2C Channel |
I2C5 |
I2C5 |
I2C5 |
I2C5 |
Device0 I2C Address |
12 |
14 |
16 |
18 |
Device1 I2C Address |
42 |
44 |
62 |
64 |
Device2 I2C Address |
48 |
4a |
68 |
6c |
Install librealsense2
and realsense2
tools¶
Install intel-ipu6
(intel-ipu6-dkms
) driver¶
Create a
/etc/modprobe.d/blacklist-ipu6.conf
file and add the lines of the listing below. This will prevent the loading of the existing defaultintel_ipu6_isys
kernel module.Reboot the target.
Install the
intel-ipu6-dkms
:Run the following command for
dkms
to force-install theintel-ipu6
driver:Check the
dkms
status by using the following command:If the
dkms
status is not “installed”, then rerun the command from step number 4.modprobe
the installedintel-ipu6
driver:Note
The
modprobe
command must be run after every system reboot. This is because theintel-ipu6-isys
kernel module is not loaded by OS at boot. It must be loaded manually using the above command.After installation, check the status of the loaded
intel-ipu6-isys
kernel module. The kernel module loaded must be/lib/modules/5.15.0-1048-intel-iotg/updates/dkms/intel-ipu6-isys.ko
as shown below:
Add the user to the video and render group¶
Install and run the Intel® RealSense™ ROS 2 sample application¶
To download and install the Intel® RealSense™ ROS 2 sample application run the below command:
Set up the ROS 2 environment:
Run the following command to bind the Intel® RealSense™ Depth camera D457 with
intel-ipu6
driver with metadata enabled:Run the Intel® RealSense™ ROS 2 sample application:
Expected output: The image from the Intel® RealSense™ camera is displayed in rviz2, on the bottom left side.
To close this, do the following:
Type
Ctrl-c
in the terminal where the tutorial was run.