2021.08.26
环境:树莓派4B+ubuntu18.04
下载地址
https://github.com/orbbec/ros_astra_camera
https://github.com/orbbec/ros_astra_launch
#1,Install ROS.
#2,安装依赖
sudo apt install ros-$ROS_DISTRO-rgbd-launch ros-$ROS_DISTRO-libuvc ros-$ROS_DISTRO-libuvc-camera ros-$ROS_DISTRO-libuvc-ros
#3 Create a ROS Workspace(if you don't have one)
mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/
catkin_make
source devel/setup.bash
#4 Pull the repository into your ROS workspace
cd ~/catkin_ws/src
git clone https://github.com/orbbec/ros_astra_camera
#5 Create astra udev rule
roscd astra_camera
./scripts/create_udev_rules
#6 Go to catkin workspace and compile astra_camera
cd ~/catkin_ws
catkin_make --pkg astra_camera
#7
cd ~/catkin_ws/src
git clone https://github.com/orbbec/ros_astra_launch
#8 use astra
roslaunch astra_launch astra.launch
#9 use astra pro (uvc rgb )
roslaunch astra_launch astrapro.launch
#10 You can use rviz or image_view to verify driver
rosrun rviz rviz
rosrun image_view image_view image:=/camera/depth/image_raw
rosrun image_view image_view image:=/camera/rgb/image_raw
各种错误
错误1,No matching device found 2bc5/0401
No matching device found… waiting for devices. Reason: astra_wrapper::AstraDevice::AstraDevice(const string&) @ /tmp/binarydeb/ros-kinetic-astra-camera-0.2.2/src/astra_device.cpp @ 76 : Device open failed
Could not open “2bc5/0401@3/5”: Failed to set USB interface!
原因是上面第5步骤的./scripts/create_udev_rules,会在 /etc/udev/rules.d/放一个规则文件56-orbbec-usb.rules
SUBSYSTEM==“usb”, ATTR{idProduct}“0401”, ATTR{idVendor}“2bc5”, MODE:=“0666”, OWNER:=“root”, GROUP:=“video”, SYMLINK+=“astra”
SUBSYSTEM==“usb”, ATTR{idProduct}“0402”, ATTR{idVendor}“2bc5”, MODE:=“0666”, OWNER:=“root”, GROUP:=“video”, SYMLINK+=“astra_s”
SUBSYSTEM==“usb”, ATTR{idProduct}“0403”, ATTR{idVendor}“2bc5”, MODE:=“0666”, OWNER:=“root”, GROUP:=“video”, SYMLINK+=“astra_pro”
SUBSYSTEM==“usb”, ATTR{idProduct}“0404”, ATTR{idVendor}“2bc5”, MODE:=“0666”, OWNER:=“root”, GROUP:=“video”, SYMLINK+=“astra_mini”
SUBSYSTEM==“usb”, ATTR{idProduct}“0407”, ATTR{idVendor}“2bc5”, MODE:=“0666”, OWNER:=“root”, GROUP:=“video”, SYMLINK+=“astra_mini_s”
然而我用的不是root用户名,所以要把OWNER内容设置为当前用户名,保存后执行下面命令,就好了。
sudo service udev reload
sudo service udev restart
错误2:Warning: USB events thread – failed to set priority. This might cause loss of data…
声明:
本文采用
BY-NC-SA
协议进行授权,如无注明均为原创,转载请注明转自
走着的小站
本文地址: 乐视orbbec深度摄像头ROS安装详细教程以及遇到的问题
本文地址: 乐视orbbec深度摄像头ROS安装详细教程以及遇到的问题