isaac_ros_argus_camera

Source code on GitHub.

Quickstart

Set Up Development Environment

  1. Set up your development environment by following the instructions in getting started.

  2. Clone isaac_ros_common under ${ISAAC_ROS_WS}/src.

    cd ${ISAAC_ROS_WS}/src && \
       git clone https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_common.git
    
  3. (Optional) Install dependencies for any sensors you want to use by following the sensor-specific guides.

    Warning

    We strongly recommend installing all sensor dependencies before starting any quickstarts. Some sensor dependencies require restarting the Isaac ROS Dev container during installation, which will interrupt the quickstart process.

Build isaac_ros_argus_camera

  1. Launch the Docker container using the run_dev.sh script:

    cd ${ISAAC_ROS_WS}/src/isaac_ros_common && \
    ./scripts/run_dev.sh
    
  2. Install the prebuilt Debian package:

    sudo apt-get install -y ros-humble-isaac-ros-argus-camera
    

Run Launch File

  1. Ensure that you have already set up your Hawk camera using the Hawk setup tutorial. If you have not, please set up the sensor and then restart this quickstart from the beginning.

  2. Continuing inside the Docker container, install the following dependencies:

    sudo apt-get install -y ros-humble-isaac-ros-examples
    
  3. Run the following launch file to spin up a demo of this package using a Hawk camera:

    ros2 launch isaac_ros_examples isaac_ros_examples.launch.py launch_fragments:=argus_stereo
    

Visualize Results

  1. Open a new terminal inside the Docker container:

    cd ${ISAAC_ROS_WS}/src/isaac_ros_common && \
       ./scripts/run_dev.sh
    
  2. Use image_saver to save the output images:

    ros2 run image_view image_saver --ros-args -r image:=/left/image_raw -p filename_format:="left_image.jpg"
    

    Stop the node by pressing Ctrl+C after saving the left image.

    ros2 run image_view image_saver --ros-args -r image:=/right/image_raw -p filename_format:="right_image.jpg"
    

    Stop the node by pressing Ctrl+C after saving the right image.

    Open the two images in your preferred image viewer to visualize the results.

Troubleshooting

Isaac ROS Troubleshooting

For solutions to problems with Isaac ROS, see troubleshooting.

Restarting the Argus Daemon

Argus is a library used by Isaac ROS on NVIDIA Jetson systems. It runs a daemon independent of ROS in a separate process to manage the camera. If you are having any sort of trouble with the camera, one of the first things you should try is restarting this daemon. From outside the container you can run:

sudo systemctl restart nvargus-daemon.service

This can resolve (Argus) Error EndOfFile and Failed to create capture session errors, among others. Generally these errors are caused by improper shutdown of a camera application.

Re-probing camera modules

If you are still having trouble with the camera, for example if restarting the daemon does not resolve a Failed to create capture session error, you can try re-probing the camera modules. This can be done from outside the container by running the following

sudo modprobe -r cam_cdi_tsc
sudo modprobe -r nv_hawk_owl
sudo modprobe nv_hawk_owl
sudo modprobe cam_cdi_tsc
sudo systemctl restart nvargus-daemon.service

API

Usage

ros2 launch isaac_ros_argus_camera isaac_ros_argus_camera_mono.launch.py
ros2 launch isaac_ros_argus_camera isaac_ros_argus_camera_stereo.launch.py

Argus Camera Mono Node

ROS Parameters

ROS Parameter

Type

Default

Description

camera_id

uint

0

The video device index E.g. /dev/video0

module_id

uint

0

The camera module index in the device tree when there is more than one of the same camera module connected

mode

uint

0

The resolution mode supported by the camera sensor and driver.

fsync_type

uint

1

Specifies what kind of Frame Synchronization to use, supported values are 0 for internal and 1 for external. For e3653 boards choose 0, for p3762 boards choose 1

camera_link_frame_name

string

camera

The frame name associated with the origin of the camera body.

optical_frame_name

string

left_cam

The frame name associated with the imager inside camera body.

camera_info_url

string

N/A

Optional URL of a camera info .ini file for monocular camera to read intrinsic information

ROS Topics Published

ROS Topic

Interface

Description

left/image_raw

sensor_msgs/Image

The image from mono camera.

left/camera_info

sensor_msgs/CameraInfo

The camera model.

Argus Camera Stereo Node

ROS Parameters

ROS Parameter

Type

Default

Description

camera_id

uint

0

The video device index E.g. /dev/video0

module_id

uint

0

The camera module index in the device tree when there is more than one of the same camera module connected

mode

uint

0

The resolution mode supported by the camera sensor and driver.

fsync_type

uint

1

Specifies what kind of Frame Synchronization to use, supported values are 0 for internal and 1 for external. For e3653 boards choose 0, for p3762 boards choose 1

camera_link_frame_name

string

camera

The frame name associated with the origin of the camera body.

left_optical_frame_name

string

left_cam

The frame name associated with the left imager inside camera body (for stereo camera).

right_optical_frame_name

string

right_cam

The frame name associated with the left imager inside camera body (for stereo camera).

left_camera_info_url

string

N/A

Optional URL of a camera info .ini file for the left imager of a stereo camera to read intrinsic information.

right_camera_info_url

string

N/A

Optional URL of a camera info .ini file for the right imager of a stereo camera to read intrinsic information.

wide_fov

boolean

false

Flag to output image with wide field of view.

ROS Topics Published

ROS Topic

Interface

Description

left/image_raw

sensor_msgs/Image

The image from the left lens in the stereo camera.

left/camera_info

sensor_msgs/CameraInfo

The left camera model.

right/image_raw

sensor_msgs/Image

The image from the right lens in the stereo camera.

right/camera_info

sensor_msgs/CameraInfo

The right camera model.

Output Color Space Format

The Isaac ROS Argus node supports the YUV444 and YUV420 colorspaces from libargus and converts it to the RGB888 colorspace as output.

CameraInfo Message

The Isaac ROS Argus node uses the Argus Ext API to retrieve calibration parameters from the camera through the Linux device driver and convert it into CameraInfo messages. Refer to this page for the data structure of the calibration parameters.

Note

Each camera module should have stored the calibration parameters in internal memory like EEPROM, and the device driver must support the Argus Ext API to extract those parameters. Contact your camera vendor to get the required drivers.

Note

If your camera does not support the Argus Ext API, you can also specify a URL to a camera info .ini file parsable by the ROS CameraInfoManager using the camera_info_url parameter on the Isaac ROS Argus node. This will allow you to provide parameters you may have calibrated using the ROS Camera Calibration package, for example.

Note

When the camera_info_url is provided, the loaded parameters override the CameraInfo from Argus Ext API.