(!) Please ask about problems and questions regarding this tutorial on answers.ros.org. Don't forget to include in your question the link to this page, the versions of your OS & ROS, and also add appropriate tags.

Viewing data from the rc_visard in Rviz

Description: This tutorial shows how to connect to the rc_visard and view data in RViz.

Keywords: rc_visard, rviz

Tutorial Level: BEGINNER

Next Tutorial: rc_visard/Tutorials/HandEyeCalibration

Goal

This tutorial shows how to visualize data of the rc_visard with RViz.

Installation

Install the rc_visard_driver with

$ sudo apt-get install ros-$ROS_DISTRO-rc-visard-driver

Launch

The rc_visard provides data via its Roboception rc_visard User Manual - rc_dynamics interface and its Roboception rc_visard User Manual - GigE Vision 2.0/GenICam image interface. The rc_visard_driver converts data of both interfaces to a ROS interface. Data relevant for visualization is mostly provided via ROS topics.

The rc_visard_driver uses rc_genicam_api to convert the GenICam image interface data to the ROS interface.

For information about the ROS topics which are published by the rc_visard_driver refer to rc_visard_driver.

rc_visard_driver

In case only one rc_visard is connected to the network one can launch with

$ rosrun rc_visard_driver rc_visard_driver _enable_tf:=True _autostart_dynamics:=True _autostop_dynamics:=True

In case multiple rc_visards are connected to the network one can launch the rc_visard_driver as node to access a specific rc_visard by specifying the serial number (here: 02912006)

$ rosrun rc_visard_driver rc_visard_driver _device:=:02912006 _enable_tf:=True _autostart_dynamics:=True _autostop_dynamics:=True
[ INFO] [1530276459.662423622]: rc_visard_driver: Opening connection to '00_14_2d_2c_6f_06'

Preceed the serial number with a colon (here: :02912006) when passing this on the command line or setting it via rosparam (see https://github.com/ros/ros_comm/issues/1339). This is not neccessary when specifying it as a string in a launch file.

The rc_visard_driver publishes all topics in the global name space. In case several rc_visards are used in the same network the topics need to be redirected into specific name spaces with the ROS namespace system.

To provide the rc_visard_drivers topics into a name space specific to a sensor (here: my_visard) launch rc_visard_driver as nodelet with

ROS_NAMESPACE=my_visard rosrun nodelet nodelet standalone rc_visard_driver _device:=:02912006

RViz

The rc_visard_driver also has an example configuration file rc_visard.rviz for RViz. You can also download the file from rc_visard_ros/rc_visard_driver/config/rc_visard.rviz.

$ rviz -d $(rospack find rc_visard_driver)/config/rc_visard.rviz

Data visualization

To enable point cloud visualization one may enable the check box "point cloud" in the "Displays" area and increase the "Decay Time" value to e.g. 10. To enable visualization of images one may enable the check boxes "disparity" (disparity image), "left image" (left camera image) and "confidence image".

Screenshot of RViz showing point cloud data  and images from a rc_visard

The RViz visualization of the left camera images published via the topic left_image may differ dependent on the purchased rc_visard type (color/monochrome). The screenshot above shows a scene captured with a rc_visard 65 monochrome.

To get some impression about how pointcloud data should be visualized in real-time consider the demonstration video rc_visard 65 - Orientation in 3D Space & Pointcloud Demonstration:

What Next?

Wiki: rc_visard/Tutorials/FirstSteps (last edited 2022-02-08 12:42:41 by ElenaGambaro)