# ROS Wrapper for Intel® RealSense™ Devices
These are packages for using Intel RealSense cameras (D400 series SR300 camera and T265 Tracking Module) with ROS.
This version supports Kinetic, Melodic and Noetic distributions.
For running in ROS2 environment please switch to the [ros2 branch](https://github.com/IntelRealSense/realsense-ros/tree/ros2). </br>
LibRealSense2 supported version: v2.50.0 (see [realsense2_camera release notes](https://github.com/IntelRealSense/realsense-ros/releases))
## Installation Instructions
### Ubuntu
#### Step 1: Install the ROS distribution
- #### Install [ROS Kinetic](http://wiki.ros.org/kinetic/Installation/Ubuntu), on Ubuntu 16.04, [ROS Melodic](http://wiki.ros.org/melodic/Installation/Ubuntu) on Ubuntu 18.04 or [ROS Noetic](http://wiki.ros.org/noetic/Installation/Ubuntu) on Ubuntu 20.04.
### Windows
#### Step 1: Install the ROS distribution
- #### Install [ROS Melodic or later on Windows 10](https://wiki.ros.org/Installation/Windows)
### There are 2 sources to install realsense2_camera from:
* ### Method 1: The ROS distribution:
*Ubuntu*
realsense2_camera is available as a debian package of ROS distribution. It can be installed by typing:
```sudo apt-get install ros-$ROS_DISTRO-realsense2-camera```
This will install both realsense2_camera and its dependents, including librealsense2 library and matching udev-rules.
Notice:
* The version of librealsense2 is almost always behind the one availeable in RealSense™ official repository.
* librealsense2 is not built to use native v4l2 driver but the less stable RS-USB protocol. That is because the last is more general and operational on a larger variety of platforms.
* realsense2_description is available as a separate debian package of ROS distribution. It includes the 3D-models of the devices and is necessary for running launch files that include these models (i.e. rs_d435_camera_with_model.launch). It can be installed by typing:
`sudo apt-get install ros-$ROS_DISTRO-realsense2-description`
*Windows*
**Chocolatey distribution Coming soon**
* ### Method 2: The RealSense™ distribution:
> This option is demonstrated in the [.travis.yml](https://github.com/intel-ros/realsense/blob/development/.travis.yml) file. It basically summerize the elaborate instructions in the following 2 steps:
### Step 1: Install the latest Intel® RealSense™ SDK 2.0
*Ubuntu*
Install librealsense2 debian package:
* Jetson users - use the [Jetson Installation Guide](https://github.com/IntelRealSense/librealsense/blob/master/doc/installation_jetson.md)
* Otherwise, install from [Linux Debian Installation Guide](https://github.com/IntelRealSense/librealsense/blob/master/doc/distribution_linux.md#installing-the-packages)
- In that case treat yourself as a developer. Make sure you follow the instructions to also install librealsense2-dev and librealsense2-dkms packages.
*Windows*
Install using vcpkg
`vcpkg install realsense2:x64-windows`
#### OR
- #### Build from sources by downloading the latest [Intel® RealSense™ SDK 2.0](https://github.com/IntelRealSense/librealsense/releases/tag/v2.50.0) and follow the instructions under [Linux Installation](https://github.com/IntelRealSense/librealsense/blob/master/doc/installation.md)
### Step 2: Install Intel® RealSense™ ROS from Sources
- Create a [catkin](http://wiki.ros.org/catkin#Installing_catkin) workspace
*Ubuntu*
```bash
mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/src/
```
*Windows*
```batch
mkdir c:\catkin_ws\src
cd c:\catkin_ws\src
```
- Clone the latest Intel® RealSense™ ROS from [here](https://github.com/intel-ros/realsense/releases) into 'catkin_ws/src/'
```bashrc
git clone https://github.com/IntelRealSense/realsense-ros.git
cd realsense-ros/
git checkout `git tag | sort -V | grep -P "^2.\d+\.\d+" | tail -1`
cd ..
```
- Make sure all dependent packages are installed. You can check .travis.yml file for reference.
- Specifically, make sure that the ros package *ddynamic_reconfigure* is installed. If *ddynamic_reconfigure* cannot be installed using APT or if you are using *Windows* you may clone it into your workspace 'catkin_ws/src/' from [here](https://github.com/pal-robotics/ddynamic_reconfigure/tree/kinetic-devel)
```bash
catkin_init_workspace
cd ..
catkin_make clean
catkin_make -DCATKIN_ENABLE_TESTING=False -DCMAKE_BUILD_TYPE=Release
catkin_make install
```
*Ubuntu*
```bash
echo "source ~/catkin_ws/devel/setup.bash" >> ~/.bashrc
source ~/.bashrc
```
*Windows*
```batch
devel\setup.bat
```
## Usage Instructions
### Start the camera node
To start the camera node in ROS:
```bash
roslaunch realsense2_camera rs_camera.launch
```
This will stream all camera sensors and publish on the appropriate ROS topics.
Other stream resolutions and frame rates can optionally be provided as parameters to the 'rs_camera.launch' file.
### Published Topics
The published topics differ according to the device and parameters.
After running the above command with D435i attached, the following list of topics will be available (This is a partial list. For full one type `rostopic list`):
- /camera/color/camera_info
- /camera/color/image_raw
- /camera/color/metadata
- /camera/depth/camera_info
- /camera/depth/image_rect_raw
- /camera/depth/metadata
- /camera/extrinsics/depth_to_color
- /camera/extrinsics/depth_to_infra1
- /camera/extrinsics/depth_to_infra2
- /camera/infra1/camera_info
- /camera/infra1/image_rect_raw
- /camera/infra2/camera_info
- /camera/infra2/image_rect_raw
- /camera/gyro/imu_info
- /camera/gyro/metadata
- /camera/gyro/sample
- /camera/accel/imu_info
- /camera/accel/metadata
- /camera/accel/sample
- /diagnostics
>Using an L515 device the list differs a little by adding a 4-bit confidence grade (pulished as a mono8 image):
>- /camera/confidence/camera_info
>- /camera/confidence/image_rect_raw
>
>It also replaces the 2 infrared topics with the single available one:
>- /camera/infra/camera_info
>- /camera/infra/image_raw
The "/camera" prefix is the default and can be changed. Check the rs_multiple_devices.launch file for an example.
If using D435 or D415, the gyro and accel topics wont be available. Likewise, other topics will be available when using T265 (see below).
### Launch parameters
The following parameters are available by the wrapper:
- **serial_no**: will attach to the device with the given serial number (*serial_no*) number. Default, attach to available RealSense device in random.
- **usb_port_id**: will attach to the device with the given USB port (*usb_port_id*). i.e 4-1, 4-2 etc. Default, ignore USB port when choosing a device.
- **device_type**: will attach to a device whose name includes the given *device_type* regular expression pattern. Default, ignore device type. For example, device_type:=d435 will match d435 and d435i. device_type=d435(?!i) will match d435 but not d435i.
- **rosbag_filename**: Will publish topics from rosbag file.
- **initial_reset**: On occasions the device was not closed properly and due to firmware issues needs to reset. If set to true, the device will reset prior to usage.
- **reconnect_timeout**: When the driver cannot connect to the device try to reconnect after this timeout (in seconds).
- **align_depth**: If set to true, will publish additional topics for the "aligned depth to color" image.: ```/camera/aligned_depth_to_color/image_raw```, ```/camera/aligned_depth_to_color/camera_info```.</br>
The pointcloud, if enabled, will be built based on the aligned_depth_to_color image.</br>
- **filters**: any of the following options, separated by commas:</br>
- ```colorizer```: will color the depth image. On the depth topic an RGB image will be published, instead of the 16bit depth values .
- ```pointcloud```: will add a poin
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
教育部认可的大学生竞赛备赛资料代码,源码,竞赛总结,所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通 全国电子设计大赛、全国大学生智能汽车竞赛、蓝桥杯、集成电路创新创业大赛、光电设计竞赛、挑战杯、大创项目、互联网+、三创赛、计算机设计竞赛、创新创业大赛、ACM-ICPC国际大学生程序设计竞赛、全国大学生数学建模竞赛、全国大学生电子商务“创新、创意及创业”挑战赛、全国大学生节能减排社会实践与科技竞赛、全国大学生工程训练综合能力竞赛、全国大学生机器人大赛-RoboMaster、RoboCon、“西门子杯”中国智能制造挑战赛、中国大学生计算机设计大赛、世界技能大赛、中国高校计算机大赛-大数据挑战赛、团体程序设计天梯赛、移动应用创新赛、网络技术挑战赛、全国大学生信息安全竞赛、“中国软件杯”大学生软件设计大赛、全国大学生光电设计竞赛、中国机器人及人工智能大赛、“大唐杯”全国大学生移动通信5G技术大赛、华为ICT大赛、全国大学生嵌入式芯片与系统设计竞赛、中国高校智能机器人创意大赛
资源推荐
资源详情
资源评论
收起资源包目录
竞赛资料源码-2023国电赛二等奖视觉仓库.zip (213个子文件)
stepConfig.cfg 307B
func.cmake 2KB
path.cmake 207B
base_realsense_node.cpp 103KB
serialib.cpp 31KB
main.cpp 21KB
yolox.cpp 19KB
matchTemplate.cpp 15KB
realsense_node_factory.cpp 13KB
Task.cpp 12KB
image_processing.cpp 10KB
mv_driver.cpp 8KB
main.cpp 7KB
yolov5.cpp 6KB
t265_realsense_node.cpp 6KB
img_displayer.cpp 5KB
recognize.cpp 5KB
modelManager.cpp 5KB
main.cpp 4KB
modelManager.cpp 4KB
Drone.cpp 3KB
modelManager.cpp 2KB
modelManager.cpp 2KB
InferResult.cpp 2KB
benchmark.cpp 1KB
inferRequest.cpp 1KB
serial_common.cpp 902B
TaskManager.cpp 323B
image_recognization.cpp 36B
preprocess.cu 501B
l515.dae 31.67MB
d435.dae 15.05MB
udev.em 9KB
.gitignore 182B
.gitignore 182B
.gitignore 176B
.gitignore 60B
.gitignore 49B
.gitignore 20B
.gitkeep 0B
nanobench.h 125KB
logging.h 16KB
base_realsense_node.h 14KB
listener.h 9KB
serialib.h 6KB
check.h 5KB
constants.h 5KB
serialPro.h 5KB
Task.h 3KB
serial_common.h 3KB
realsense_node_factory.h 3KB
robotComm.h 3KB
image_processing.h 2KB
Drone.h 2KB
writer.h 2KB
matchTemplate.h 1KB
modelManager.h 1KB
InferResult.h 1KB
t265_realsense_node.h 1KB
callback_manager.h 1KB
modelManager.h 904B
inferRequest.h 779B
modelManager.h 769B
image_recognization.h 675B
yolov5.h 486B
modelManager.h 478B
TaskManager.h 425B
common.h 408B
infer.h 405B
preprocess.h 398B
msg_serialize.h 254B
yolox.h 227B
DigitalRecognition.iml 97B
src.iml 97B
src.iml 97B
download.jpeg 4KB
8.jpg 20KB
3.jpg 20KB
7.jpg 18KB
2.jpg 18KB
10.jpg 18KB
5.jpg 18KB
6.jpg 15KB
1.jpg 15KB
9.jpg 14KB
4.jpg 13KB
rs_rgbd.launch 10KB
rs_camera.launch 8KB
rs_d435_camera_with_model.launch 6KB
rs_from_file.launch 4KB
rs_aligned_depth.launch 4KB
rs_t265.launch 3KB
rs_d400_and_t265.launch 3KB
opensource_tracking.launch 3KB
rs_rtabmap.launch 2KB
rs_multiple_devices.launch 2KB
demo_pointcloud.launch 1KB
view_l515_model.launch 529B
view_d415_model.launch 529B
view_d435_model.launch 529B
共 213 条
- 1
- 2
- 3
资源评论
妄北y
- 粉丝: 2w+
- 资源: 1万+
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功