当前位置: 首页 > news >正文

零基础做网站教程宁波网站推广公司报价

零基础做网站教程,宁波网站推广公司报价,阿里云 做网站,湖州网站建设培训仅为学习记录和一些自己的思考,不具有参考意义。 1navigation导航框架 2导航设置过程 (1)启动仿真环境 roslaunch why_simulation why_robocup.launch (2)启动move_base导航、amcl定位 roslaunch why_simulation nav…

仅为学习记录和一些自己的思考,不具有参考意义。

1navigation导航框架

2导航设置过程

(1)启动仿真环境

roslaunch why_simulation why_robocup.launch

(2)启动move_base导航、amcl定位

roslaunch why_simulation nav.launch 

<launch><node pkg="move_base" type="move_base" name="move_base"><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="global_costmap" /><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="local_costmap" /><rosparam file="$(find why_simulation)/config/global_costmap_params.yaml" command="load" /><rosparam file="$(find why_simulation)/config/local_costmap_params.yaml" command="load" /><param name="base_global_planner" value="global_planner/GlobalPlanner" /> <param name="base_local_planner" value="wpbh_local_planner/WpbhLocalPlanner" /></node><node pkg="map_server" type="map_server" name="map_server" args="$(find why_simulation)/maps/map.yaml"/><node pkg="amcl" type="amcl" name="amcl"/></launch>

(3)启动rviz

rviz

(4)设置目标点

(5)将左右指令完善到launch文件中

<launch><include file="$(find why_simulation)/launch/why_robocup.launch"/><node pkg="move_base" type="move_base" name="move_base"><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="global_costmap" /><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="local_costmap" /><rosparam file="$(find why_simulation)/config/global_costmap_params.yaml" command="load" /><rosparam file="$(find why_simulation)/config/local_costmap_params.yaml" command="load" /><param name="base_global_planner" value="global_planner/GlobalPlanner" /> <param name="base_local_planner" value="wpbh_local_planner/WpbhLocalPlanner" /></node><node pkg="map_server" type="map_server" name="map_server" args="$(find why_simulation)/maps/map.yaml"/><node pkg="amcl" type="amcl" name="amcl"/><node name="rviz" pkg="rviz" type="rviz" args="-d $(find why_simulation)/rviz/nav.rviz"/></launch>

3全局路径规划算法

功能包简介

navfn与global_planner功能相同,同时包含了Dijkstra与A*算法。

navfn默认使用Dijkstra算法,算法无问题,但是此包的A*存在问题。

global_planner功能包无bug。

carrot_planner功能包碰到障碍物就停止了,常作为自己书写的规划器的模板。

启动全局规划

    <node pkg="move_base" type="move_base" name="move_base"><param name="base_global_planner" value="global_planner/GlobalPlanner" /> </node>

golbal_planner默认使用Dijkstra算法,若要切换为A*,则需要以下修改。

    <node pkg="move_base" type="move_base" name="move_base"><param name="base_global_planner" value="global_planner/GlobalPlanner" /> .<param name="GlobalPlanner/use_dijkstra" value="false" /> <param name="GlobalPlanner/use_grid_path" value="true" /> </node>

4 amcl

    <node pkg="amcl" type="amcl" name="amcl"/>

开始导航后真实位置的粒子越来越少

5 costmap

代价地图

代价地图的参数设置

costmap_common_params.yaml

robot_radius: 0.25
inflation_radius: 0.5
obstacle_range: 6.0
raytrace_range: 6.0
observation_sources: base_lidar
base_lidar: {data_type: LaserScan,topic: /scan, marking: true, clearing: true}

global_costmap_params.yaml

global_costmap:global_frame: maprobot_base_frame: base_footprintstatic_map: trueupdate_frequency: 1.0publish_frequency: 1.0transform_tolerance: 1.0recovery_behaviors:- name: 'conservative_reset'type: 'clear_costmap_recovery/ClearCostmapRecovery'- name: 'rotate_recovery'type: 'rotate_recovery/RotateRecovery'- name: 'aggressive_reset'type: 'clear_costmap_recovery/ClearCostmapRecovery'conservative_reset:reset_distance: 2.0layer_names: ["obstacle_layer"]aggressive_reset:reset_distance: 0.0layer_names: ["obstacle_layer"]

local_costmap_params.yaml

local_costmap:global_frame: odomrobot_base_frame: base_footprintstatic_map: falserolling_window: truewidth: 3.0height: 3.0update_frequency: 10.0publish_frequency: 10.0transform_tolerance: 1.0

6 recovery_behaviors

应急机制,在导航进行停滞时,尝试刷新周围障碍物的信息,重新进行全局路径规划。

recovery_behaviors:- name: 'conservative_reset'type: 'clear_costmap_recovery/ClearCostmapRecovery'- name: 'rotate_recovery'type: 'rotate_recovery/RotateRecovery'- name: 'aggressive_reset'type: 'clear_costmap_recovery/ClearCostmapRecovery'

7局部路径规划算法

更改launch文件中的以下代码即可更换算法

        <param name="base_local_planner" value="wpbh_local_planner/WpbhLocalPlanner" />

DWA测试

<launch><include file="$(find why_simulation)/launch/why_robocup.launch"/><node pkg="move_base" type="move_base" name="move_base"><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="global_costmap" /><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="local_costmap" /><rosparam file="$(find why_simulation)/config/global_costmap_params.yaml" command="load" /><rosparam file="$(find why_simulation)/config/local_costmap_params.yaml" command="load" /><param name="base_global_planner" value="global_planner/GlobalPlanner" /> <!-- <param name="GlobalPlanner/use_dijkstra" value="false" />  --><!-- <param name="GlobalPlanner/use_grid_path" value="true" />  --><!-- DWA --><param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS" /><rosparam file="$(find why_simulation)/config/dwa_local_planner_params.yaml" command="load" /></node><node pkg="map_server" type="map_server" name="map_server" args="$(find why_simulation)/maps/map.yaml"/><node pkg="amcl" type="amcl" name="amcl"/><node name="rviz" pkg="rviz" type="rviz" args="-d $(find why_simulation)/rviz/nav.rviz"/></launch>

导航结果可以看过许多白色的候选路径,绿色为最优路线。

dwa_local_planner_params.yaml

DWAPlannerROS:# 速度参数max_vel_x: 0.3      # 最大x方向速度min_vel_x: -0.05    # 最小x方向速度(设置负数将会允许倒车)max_vel_y: 0.0      # 差分驱动机器人的最大y方向速度为 0.0min_vel_y: 0.0      # 差分驱动机器人的最小y方向速度为 0.0max_vel_trans: 0.3  # 最大平移速度min_vel_trans: 0.01 # 最小平移速度(建议不要设置为 0.0 )trans_stopped_vel: 0.1  # 当平移速度小于这个值,就让机器人停止acc_lim_trans: 2.5      # 最大平移加速度acc_lim_x: 2.5          # x方向的最大加速度上限acc_lim_y: 0.0          # y方向的加速度上限(差分驱动机器人应该设置为 0.0 )max_vel_theta: 1.0      # 最大旋转速度,略小于基座的功能min_vel_theta: -0.01    # 当平移速度可以忽略时的最小角速度theta_stopped_vel: 0.1  # 当旋转速度小于这个值,就让机器人停止acc_lim_theta: 6.0      # 旋转的加速度上限# 目标容差参数yaw_goal_tolerance: 0.1         # 目标航向容差xy_goal_tolerance: 0.05         # 目标xy容差latch_xy_goal_tolerance: false  # 到达目标容差范围后,停止移动,只旋转调整航向# 向前模拟参数sim_time: 1.7       # 模拟时间,默认值 1.7vx_samples: 3       # x方向速度采样数,默认值 3vy_samples: 1       # 差分驱动机器人y方向速度采样数,只有一个样本vtheta_samples: 20  # 旋转速度采样数,默认值 20# 轨迹评分参数path_distance_bias: 32.0  # 靠近全局路径的权重,默认值 32.0goal_distance_bias: 24.0  # 接近导航目标点的权重,默认值 24.0occdist_scale: 0.01       # 控制器避障的权重,默认值 0.01forward_point_distance: 0.325 # 从机器人到评分点的位置,默认值 0.325stop_time_buffer: 0.2     # 在碰撞前机器人必须停止的时间长度,留出缓冲空间,默认值 0.2scaling_speed: 0.25       # 缩放机器人速度的绝对值,默认值 0.25max_scaling_factor: 0.2   # 机器人足迹在高速时能缩放的最大系数,默认值 0.2# 防振动参数oscillation_reset_dist: 1.05 # 重置振动标志前需要行进的距离,默认值 0.05# 辅助调试选项publish_traj_pc : true      # 是否在 RViz 里发布轨迹publish_cost_grid_pc: true  # 是否在 RViz 里发布代价网格global_frame_id: odom       # 基础坐标系# 差分驱动机器人配置holonomic_robot: false # 是否全向移动机器人

在线调参工具

rosrun rqt_reconfigure rqt_reconfigure

TEB测试

<launch><include file="$(find why_simulation)/launch/why_robocup.launch"/><node pkg="move_base" type="move_base" name="move_base"><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="global_costmap" /><rosparam file="$(find why_simulation)/config/costmap_common_params.yaml" command="load" ns="local_costmap" /><rosparam file="$(find why_simulation)/config/global_costmap_params.yaml" command="load" /><rosparam file="$(find why_simulation)/config/local_costmap_params.yaml" command="load" /><param name="base_global_planner" value="global_planner/GlobalPlanner" /> <!-- <param name="GlobalPlanner/use_dijkstra" value="false" />  --><!-- <param name="GlobalPlanner/use_grid_path" value="true" />  --><!-- DWA --><!-- <param name="base_local_planner" value="dwa_local_planner/DWAPlannerROS" /> --><!-- <rosparam file="$(find why_simulation)/config/dwa_local_planner_params.yaml" command="load" /> --><!-- TEB --><param name="base_local_planner" value="teb_local_planner/TebLocalPlannerROS" /><rosparam file="$(find why_simulation)/config/teb_local_planner_params.yaml" command="load" /></node><node pkg="map_server" type="map_server" name="map_server" args="$(find why_simulation)/maps/map.yaml"/><node pkg="amcl" type="amcl" name="amcl"/><node name="rviz" pkg="rviz" type="rviz" args="-d $(find why_simulation)/rviz/nav.rviz"/></launch>

http://www.hengruixuexiao.com/news/47308.html

相关文章:

  • win8风格门户网站商丘网站优化公司
  • 陵水网站建设公司网页关键词优化软件
  • wordpress里面如何加载百度地图seo查询优化
  • 北京做手机网站的公司哪家好东莞互联网公司排名
  • wordpress创建三级分类深圳网络优化推广公司
  • 空间做网站怎么优化整站
  • 北京感染峰值已过广州网站优化系统
  • 茶陵网站建设网络服务网络推广
  • 微信分销平台系统软件网站关键词优化
  • 怎么创造网站西安百度关键词推广
  • 关于做网站的了解点免费网站建站2773
  • 西安的网站建设网站优化seo
  • google代理服务器地址seo内链优化
  • 视频网站开发的难点外贸怎么建立自己的网站
  • 免费素材库网站如何做百度关键词推广
  • 住房建设部网站监理员上海网站建设开发
  • 龙华区民治街道安卓优化大师老版本下载
  • 公司网站彩页怎么做成人职业技能培训学校
  • 南宁网站建设公司如何为老板打造网站赚钱的技术培训学校机构
  • 网站编写教程飞猪关键词排名优化
  • 有什么免费开发网站建设软件软文代写费用
  • 网站做订购石家庄关键词排名首页
  • 许昌网站开发公司seo研究所
  • 华为公司网站建设相关内容设计网络推广方案
  • 网站平台建设软文范例大全200字
  • 做性的网站有哪些内容windows优化大师官方免费下载
  • 网站建设素材图大连网络营销seo
  • 网站开发不用框架全网营销推广 好做吗
  • web网站如何做负载均衡视频营销
  • 做关于网站的开题报告杭州seo百度关键词排名推广