ROS 进阶学习笔记(17):ROS导航2:关于 move_base Package(底盘移动包)

== 关于move_base 包(底盘移动包?移动底盘包?) ==

开始之前,我sonictl@CSDN有几个问题(Link on ROS_Answer)需要搞定:

  1. costmap_2d包 与 move_base包 是什么关系?
  2. 导航时,在RviZ工具中,可以看到,inflate 地图是由一个叫做 /move_base/local_costmap/costmap 主题生成的,这个主题的发布者又是move_base,怎么发布的?
  3. 到底是costmap_2d发布的/move_base/local_costmap/costmap还是move_base发布的它?又回到第1个问题,关系问题。
  4. http://wiki.ros.org/costmap_2d/hydro/obstacles 这里是不是可以探寻一点东西出来,以调整obstacle层的刷新机制
  5. 我sonictl@CSDN要解决的就是inflated obstacle层的刷新机制

How to solve the problem:



=== 我学这个包的时候,尽量总结wiki page上的内容如下,算是sonictl@CSDN读书笔记:===
wikipage: http://wiki.ros.org/move_base
move_base package 所属Stack: navigation
关于这个包在 ROS Navigation 框架中的位置,参见:ROS探索总结(十三)——导航与定位框架

【Summary】

The move_base package provides an implementation of an action (see the actionlib package) that, given a goal in the world, will attempt to reach it with a mobile base. The move_base node links together a global and local planner to accomplish its global navigation task. It supports any global planner adhering to the nav_core::BaseGlobalPlanner interface specified in the nav_core package and any local planner adhering to the nav_core::BaseLocalPlanner interface specified in thenav_core package. The move_base node also maintains two costmaps, one for the global planner, and one for a local planner (see thecostmap_2d package) that are used to accomplish navigation tasks.

这个包就是一个Action的实现,关于action,是一个ROS里的概念,需要到链接去学习。这个action就是要有几个输入,比如goal,然后它要给出的就是你的mobile base怎么到那里去的一个action输出。the move_base node实际上是一个link, 把全局规划器、局部规划器连接起来,以达成导航到目的地的目标。nav_core::BaseGlobalPlanner 接口里由nav_core指定的那些全局或 nav_core::BaseLocalPlanner 接口里由nav_core指定的局部规划器都被 move_base 支持。move_base node 还维护了俩costmap, 一个是为全局规划器准备的 global costmap, 一个是local的,这俩costmap也是为了完成sonictl@CSDN导航的任务。


【关于 move_base Nodes】

This package provides the move_base ROS Node which is a major component of thenavigation stack. A detailed description of this Node and its configuration options is found below. 主要的结构就是见下图咯:


    要说的呢,就是move_base看起来仿佛是个壳儿,壳儿负责和外界交流,它肚子里的才是干货~~sonictl@CSDN呵呵!

    The move_base node provides a ROS interface for configuring, running, and interacting with thenavigation stack on a robot. A high-level view of the move_base node and its interaction with other components is shown above. The blue vary based on the robot platform, the gray are optional but are provided for all systems, and the white nodes are required but also provided for all systems. For more information on configuration of themove_base node, and the navigation stack as a whole, please see thenavigation setup and configuration tutorial.

    这里讲了各个颜色的方框代表的含义,给了一个tutorial的链接,教你怎么配置 navigation setup and configuration. 配置导航stack肯定会用到的link

   

【期望的机器人的行为】

先扔了一幅图:

Running the move_base node on a robot that is properly configured (please seenavigation stack documentation for more details) results in a robot that will attempt to achieve a goal pose with its base to within a user-specified tolerance. In the absence of dynamic obstacles, the move_base node will eventually get within this tolerance of its goal or signal failure to the user. Themove_base node may optionally perform recovery behaviors when the robot perceives itself as stuck. By default, themove_base node will take the following actions to attempt to clear out space(sonictl@CSDN):

First, obstacles outside of a user-specified region will be cleared from the robot's map. Next, if possible, the robot will perform an in-place rotation to clear out space. If this too fails, the robot will more aggressively clear its map, removing all obstacles outside of the rectangular region in which it can rotate in place. This will be followed by another in-place rotation. If all this fails, the robot will consider its goal infeasible and notify the user that it has aborted. These recovery behaviors can be configured using the recovery_behaviors parameter, and disabled using the recovery_behavior_enabled parameter.

对图作一下解释: 在你已经配置得比较好的机器人上运行 move_base node就会让你的机器人跑到指定的位姿去,在tolerance,容错值允许的范围内到达。In the absence of dynamic obstacles,要么 move_base node会最终到达,要么会返回一个失败信号。当机器人感觉被卡住stuck时,the move_base node可能会选择性地执行recovery 恢复行为。默认的,这个 move_base node 会采取以下的措施来clear out space: 搞清楚自己的处境?

  • 首先,机器人清扫地图,无关紧要的障碍就不处理了。
  • 然后,机器人会原地转圈来搞清楚自己处境clear out space
  • 如果这个失败,机器人会变得更勇敢地clear its map, 移除矩形区域以外的所有的障碍,而这个矩形区域是它可以在其中原地转圈的区域。
  • 接下来就是另一个 in-place 转圈原地转圈。
  • 如果上述所有步骤都失败了,机器人可能会考虑它的goal达不到了并通知用户aborted任务失败。
        sonictl@CSDN: 这些恢复行为可以在 the recovery_behaviors parameter 里配置,或者开关这些行为:and be disabled using the recovery_behavior_enabled parameter


【Action API】

The move_base node provides an implementation of theSimpleActionServer (seeactionlib documentation), that takes in goals containinggeometry_msgs/PoseStamped messages. You can communicate with themove_base node over ROS directly, but the recommended way to send goals tomove_base if you care about tracking their status is by using theSimpleActionClient. Please see actionlib documentation for more information.

The move_base node 提供的是一个SimpleActionServer (seeactionlib documentation)的动作服务器,它吃进 goals containinggeometry_msgs/PoseStamped messages。你可以在ROS架构上和move_base node 通信,但如果你关心它们的状态的话,推荐的方式是通过使用 theSimpleActionClient给它发goals, 详见actionlib documentation for more information。(看来 actionlib documentation 是必须要搞一搞才行了~~)

sonictl: 这里面涉及到ROS里的几个值得总结的概念分类问题: 1. What is Service/Actionlib/plugin...     2. What is message/topic/parameter/node/tf   3. ...other concepts

Action Subscribed Topics:

  • 5
    点赞
  • 28
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值