ITPub博客

首页 > 移动开发 > HTML5 > ROS 使用 奥比中光 astra_camera + ar_track_alvar

ROS 使用 奥比中光 astra_camera + ar_track_alvar

HTML5 作者:iibull 时间:2019-08-02 06:01:47 0 删除 编辑
根据
http://wiki.ros.org/Sensors/OrbbecAstra
主要有 两个 ROS pack
http://wiki.ros.org/astra_camera
http://wiki.ros.org/astra_launch

apt 没有 melodic 的版本, 所以尝试从源码安装一下。
根据
https://github.com/orbbec/ros_astra_camera 的 readme.md

1. sudo apt install ros-$ROS_DISTRO-rgbd-launch ros-$ROS_DISTRO-libuvc ros-$ROS_DISTRO-libuvc-camera ros-$ROS_DISTRO-libuvc-ros
2. ss; git clone https://github.com/orbbec/ros_astra_camera
3. 编译 astra      sm --pkg=astra_camera
4. 
roscd astra_camera;  ./scripts/create_udev_rules

使用:
roslaunch astra_camera astra.launch
或者  roslaunch astra_camera stereo_s.launch

对应的topic

点击(此处)折叠或打开

  1. */image_raw: depth/rgb/ir raw images
  2. */image_rect_raw: images rectified by intrinsic/extrinsic parameters
  3. */camera_info: camera intrinsic/extrinsic parameters
  4. /camera/depth/points: point cloud without color information
  5. /camera/depth_registered/points: xyzrgb point cloud
常用的service

点击(此处)折叠或打开

  1. /camera/get_device_type: return a string containing astra device type
  2. /camera/get_ir_exposure: get exposure value of ir camera
  3. /camera/get_ir_gain: get gain value of ir camera
  4. /camera/get_serial: get serial number
  5. /camera/get_uvc_exposure: get exposure value of rgb camera
  6. /camera/get_uvc_gain: get gain value of rgb camera
  7. /camera/get_uvc_white_balance: get white balance value of rgb camera
  8. /camera/reset_ir_exposure: reset ir exposure to default value
  9. /camera/reset_ir_gain: reset ir gain to default value
  10. /camera/set_ir_exposure: set ir exposure to specific value
  11. /camera/set_ir_gain: set ir gain to specific value
  12. /camera/set_laser: turn on (true) or turn off (false) laser
  13. /camera/set_uvc_exposure: set uvc exposure. (set 0 indicating auto mode)
  14. /camera/set_uvc_gain: set uvc gain
  15. /camera/set_uvc_white_balance: set uvc white balance (set 0 indicating auto mode)
  16. /camera/set_ir_flood: turn on (true) or turn off (false) ir flood
范例

点击(此处)折叠或打开

  1. rosservice call /camera/get_ir_exposure 获取 IR 曝光
  2. rosservice call /camera/set_ir_exposure "{exposure: 50}"

  3. //开关 laser
  4. rosservice call /camera/set_laser "{enable: true}" #turn on
  5. rosservice call /camera/set_laser "{enable: false}" #turn off




来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/27875/viewspace-3154005/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2021-04-04

  • 博文量
    11
  • 访问量
    155