ifm3d-ros2
is a wrapper around ifm3d
enabling the usage of ifm pmd-based ToF cameras from within
ROS 2 software systems.
ifm3d-ros2 version | ifm3d version | ROS 2 distribution(s) |
---|---|---|
0.1.0 | 0.12.0 | Dashing |
0.1.1 | 0.12.0, 0.13.0 | Dashing |
0.2.0 | 0.12.0, 0.13.0 | Dashing |
ifm3d-ros2
is intended to be built with
colcon
To that end, the shell commands below assume a single colcon workspace in which
ifm3d-ros2
will be built.
Create the colcon workspace:
$ mkdir ~/colcon/ifm3d_ros2/src
Clone the ifm3d-ros2
github repo into this workspace and build it:
(NOTE: the --cmake-args -DBUILD_TESTING=ON
part of the colcon
command below
is not strictly necessary (tests are ON
by default), however, it is explicit
(see: python3 -mthis
)).
$ cd ~/colcon/ifm3d_ros2/src
$ git clone https://github.com/ifm/ifm3d-ros2.git ifm3d_ros2
$ cd ..
$ colcon build --cmake-args -DBUILD_TESTING=ON
Starting >>> ifm3d_ros2
Finished <<< ifm3d_ros2 [17.6s]
Summary: 1 package finished [17.8s]
Run the test suite (optional, you will need supported hardware connected):
$ colcon test
$ colcon test-result --all
[ ... output omitted ... ]
Launch the camera node (assuming you are in ~/colcon/ifm3d_ros2
):
$ . install/setup.bash
$ ros2 launch ifm3d_ros2 camera_managed.launch.py
In a new shell, to visualize the data from the camera in rviz (assuming you are in
~/colcon/ifm3d_ros2
):
$ . install/setup.bash
$ ros2 launch ifm3d_ros2 rviz.launch.py
Name | Data Type | Default Value | Description |
---|---|---|---|
~/frame_latency_thresh | float | 1.0 | Time (seconds) used to determine that timestamps from the camera cannot be trusted. When this threshold is exceeded, when compared to system time, we use the reception time of the frame and not the capture time of the frame. |
~/ip | string | 192.168.0.69 | The ip address of the camera. |
~/password | string | The password required to establish an edit session with the camera. | |
~/schema_mask | uint16 | 0xf | The schema mask to apply to the active session with the frame grabber. This determines which images are available for publication from the camera. More about schemas can be gleaned from the ifm3d project. |
~/timeout_millis | int | 500 | The number of milliseconds to wait for the framegrabber to return new frame data before declaring a "timeout" and to stop blocking on new data. |
~/timeout_tolerance_secs | float | 5.0 | The wall time to wait with no new data from the camera before trying to establish a new connection to the camera. This helps to provide robustness against camera cables becoming unplugged or other in-field pathologies which would cause the connection between the ROS node and the camera to be broken. |
~/sync_clocks | bool | false | Attempt to sync the camera clock to the system clock at start-up. The side-effect is that timestamps on the image should reflect the capture time as opposed to the receipt time. Please note: resolution of this synch is only granular to 1 second. If fine-grained image acquisition times are needed, consider using the on-camera NTP server (available on select camera models). |
~/xmlrpc_port | uint16 | 80 | The TCP port the camera's xmlrpc server is listening on for requests. |
Name | Data Type | Quality of Service | Description |
---|---|---|---|
amplitude | sensor_msgs/msg/Image | ifm3d_ros::LowLatencyQoS | The normalized amplitude image |
cloud | sensor_msgs/msg/PointCloud2 | ifm3d_ros::LowLatencyQoS | The point cloud data |
confidence | sensor_msgs/msg/Image | ifm3d_ros::LowLatencyQoS | The confidence image |
distance | sensor_msgs/msg/Image | ifm3d_ros::LowLatencyQoS | The radial distance image |
raw_amplitude | sensor_msgs/msg/Image | ifm3d_ros::LowLatencyQoS | The raw amplitude image |
unit_vectors | sensor_msgs/msg/Image | ifm3d_ros::LatchedQoS | The rotated unit vectors |
xyz_image | sensor_msgs/msg/Image | ifm3d_ros::LowLatencyQoS | A 3-channel image encoding of the point cloud. Each of the three image channels respesent a spatial data plane encoding the x, y, z Cartesian values respectively. |
None.
Name | Service Definition | Description |
---|---|---|
Dump | ifm3d/Dump | Dumps the state of the camera parameters to JSON |
Config | ifm3d/Config | Provides a means to configure the camera and imager settings, declaratively from a JSON encoding of the desired settings. |
We are currently working on rounding out the feature set of our ROS2 interface. Our current objectives are to get the feature set to an equivalent level to that of our ROS1 interface and to tune the ROS2/DDS performance to optimize the usage of our cameras from within ROS2 system. Thanks for your patience as we continue to ensure our ROS2 interface is feature-rich, robust, and performant. Your feedback on our issue tracker is greatly appreciated.
Please see the file called TODO for more information of what we are currently working on.
Please see the file called LICENSE.