How to use the RealSense2 camera
Installation
Go to the intel-ros github page. Clone the realsense repository in your catkin workspace inside src:
Camera Output
Run the following to get access to the camera:
Open rviz to visualize the camera output.
Configure camera output (OPTIONAL)
Run the following to open the rviz configuration window:
You can also try to change the "octree_resolution" value:
Setup Base Frame
Run the following:
where x, y, z are the distances and roll, pitch, yaw are the rotations from the base_link to the camera_link.
To visualize your frames in rzviz, add the TF feature in the rviz menu.
Save Point Clouds
If it's your first time saving point clouds, you need to choose where you want to save them and enable data collection:
Change the value of "dataset_collection" from "false" to "true". Change value of "logdir" from "/temp/ to the path in your computer where you want to save the files.
Run the following to get access to the point clouds given by the camera:
Publish the message 'e-start':
Publish the message 'e-add-cloud-start':
This last one will save the current point cloud of the observed object in your system.
BEWARE!! Sometimes the camera won't save the point cloud (don't worry, not your fault). Just try a different position for the object until it works.
Visualize Point Cloud
Run the following in the folder where you saved the point clouds:
Last updated
Was this helpful?