ROS中 Navigation包

ROS Navigation包的理解:https://blog.csdn.net/qq91752728/article/details/79863677

1、costMap

整个代价地图中,我们都会给每一个格子分配一个值,取值为下列几个
255 代表 未知区域
254 代表 障碍物
253 代表 小车会和障碍物冲突
128 代表 小车可能会冲突也可能不会,根据朝向决定
0 – 128 代表 不冲突

ROS中 Navigation包_第1张图片

2、机器人的里程计信息:
rosmsg show nav_msgs/Odometry 
std_msgs/Header header
  uint32 seq  //消息序列序号
  time stamp  //时间戳
  string frame_id  //坐标系
string child_frame_id
geometry_msgs/PoseWithCovariance pose
  geometry_msgs/Pose pose
    geometry_msgs/Point position  //XYZ位置信息
      float64 x
      float64 y
      float64 z
    geometry_msgs/Quaternion orientation  //以四元素形式描述的姿态位置
      float64 x
      float64 y
      float64 z
      float64 w
  float64[36] covariance  //协方差矩阵,作里程计的位置估算,kf计算的时候会用到
geometry_msgs/TwistWithCovariance twist
  geometry_msgs/Twist twist
    geometry_msgs/Vector3 linear  //线速度信息
      float64 x
    float64 y
      float64 z
    geometry_msgs/Vector3 angular  //角速度信息
      float64 x
      float64 y
      float64 z
  float64[36] covariance

 

 

3、ROS系统里的坐标系方向:

      ROS中 Navigation包_第2张图片

 

4、move_base包:

全局路径规划(global planer)

——》使用Dijkstra方法和A*方法。

——》作用:实现全局最优路径规划

本地实时规划(local planer)

——》Trajectory  Rollout和Dynamic Window Approaches方法

——》作用:实时避障

      ROS中 Navigation包_第3张图片

5、 查看雷达的采集信息命令:rostopic echo /scan 

 

---
header: 
  seq: 228      //节点启动后采集雷达数据的序列号
  stamp:         //时间戳
    secs: 1545184554
    nsecs: 626462325
  frame_id: laser      //坐标系
angle_min: -3.12413907051
angle_max: 3.14159274101
angle_increment: 0.0174532923847
time_increment: 3.2735627542e-07
scan_time: 0.00011752089631
range_min: 0.15000000596
range_max:  16.0
ranges: [2.48799991607666, 2.4820001125335693, 2.4749999046325684, 2.4779999256134033, 2.4790000915527344, 2.4779999256134033, 2.4779999256134033, 2.4809999465942383, 2.4749999046325684, 2.4830000400543213, 2.4839999675750732, 2.490000009536743, 2.490999937057495, 2.496000051498413, 2.506999969482422, 2.5169999599456787, 2.5220000743865967, 2.5309998989105225, 2.5309998989105225, inf, inf, inf, inf, inf, 1.5010000467300415, 1.4609999656677246, 1.371999979019165, 1.3329999446868896, 1.2640000581741333, 1.225000023841858, 1.1699999570846558, 1.1449999809265137, 1.1009999513626099, 1.0740000009536743, 1.031999945640564, 1.0130000114440918, 0.9700000286102295, 0.953000009059906, 0.6119999885559082, 0.5989999771118164, 0.593999981880188, 0.5899999737739563, 0.578000009059906, 0.5630000233650208, 0.5519999861717224, 0.5289999842643738, 0.5120000243186951, 0.5040000081062317, 0.4909999966621399, 0.48500001430511475, 0.4740000069141388, 0.46799999475479126, 0.4560000002384186, 0.4490000009536743, 0.4359999895095825, 0.4259999990463257, 0.41999998688697815, 0.41200000047683716, 0.4090000092983246, 0.4059999883174896, 0.4000000059604645, 0.39500001072883606, 0.3930000066757202, 0.3889999985694885, 0.3869999945163727, 0.382999986410141, 0.3799999952316284, 0.3790000081062317, 0.3779999911785126, 0.375, 0.375, 0.3720000088214874, 0.3709999918937683, 0.36800000071525574, 0.367000013589859, 0.3630000054836273, 0.3619999885559082, 0.3569999933242798, 0.3569999933242798, 0.3540000021457672, 0.3529999852180481, 0.35199999809265137, 0.35100001096725464, 0.3499999940395355, 0.3499999940395355, 0.3490000069141388, 0.3490000069141388, 0.3490000069141388, 0.3490000069141388, 0.35100001096725464, 0.35100001096725464, 0.35199999809265137, 0.3529999852180481, 0.35499998927116394, 0.35600000619888306, 0.3569999933242798, 0.35899999737739563, 0.3610000014305115, 0.3610000014305115, 0.3619999885559082, 0.3619999885559082, 0.3610000014305115, 0.3619999885559082, 0.3619999885559082, 0.3619999885559082, 0.3630000054836273, inf, 0.3630000054836273, 0.36500000953674316, 0.3659999966621399, 0.3720000088214874, inf, 0.5389999747276306, 0.5440000295639038, 0.5460000038146973, 0.5519999861717224, 0.5529999732971191, 0.5580000281333923, 0.5649999976158142, 0.5659999847412109, 0.5740000009536743, 0.578000009059906, 0.5849999785423279, 0.5910000205039978, 0.5920000076293945, 0.6010000109672546, 0.6060000061988831, 0.6179999709129333, 0.6200000047683716, 0.6330000162124634, 0.6399999856948853, 0.6449999809265137, 0.6570000052452087, 0.6629999876022339, 0.6759999990463257, 0.6830000281333923, 0.6930000185966492, 0.7049999833106995, 0.7139999866485596, 0.7350000143051147, 0.7419999837875366, 0.7639999985694885, 0.7760000228881836, 0.7870000004768372, 0.8090000152587891, 0.824999988079071, 0.8489999771118164, 0.8640000224113464, 0.878000020980835, 0.9100000262260437, 0.9240000247955322, 0.9480000138282776, 0.9670000076293945, 0.9879999756813049, 1.0410000085830688, 1.065999984741211, 1.1150000095367432, 1.1419999599456787, 1.1690000295639038, 1.2330000400543213, 1.2740000486373901, 1.350000023841858, 1.3899999856948853, 1.4359999895095825, 1.5299999713897705, 1.5959999561309814, inf, inf, inf, inf, inf, inf, 3.927000045776367, inf, inf, 4.074999809265137, inf, 5.38700008392334, 5.348999977111816, 5.3460001945495605, 5.348999977111816, 5.341000080108643, 5.333000183105469, 5.315999984741211, 5.329999923706055, 3.6389999389648438, 6.485000133514404, 5.914999961853027, 5.908999919891357, inf, 5.699999809265137, 2.2869999408721924, 2.440000057220459, 1.9670000076293945, 1.7890000343322754, 1.871000051498413, 1.8919999599456787, 1.8910000324249268, 1.9010000228881836, 1.906999945640564, 1.9110000133514404, 1.9240000247955322, 1.937999963760376, 0.8669999837875366, 0.8500000238418579, inf, 0.9399999976158142, 0.8159999847412109, 0.7749999761581421, 0.7570000290870667, 0.722000002861023, 0.6909999847412109, 0.6759999990463257, 0.6489999890327454, 0.6370000243186951, 0.6129999756813049, 0.6010000109672546, 0.5799999833106995, 0.5709999799728394, 0.5529999732971191, 
0.5350000262260437, 0.5270000100135803, 0.5130000114440918, 0.5049999952316284, 0.492000013589859, 0.4860000014305115, 0.4729999899864197, 0.46299999952316284, 0.4569999873638153, 0.44699999690055847, 0.44999998807907104, 0.45899999141693115, 0.5299999713897705, 0.5379999876022339, 0.5479999780654907, 0.5649999976158142, 0.5740000009536743, 0.5839999914169312, 0.6039999723434448, 0.6179999709129333, 0.6420000195503235, 0.6539999842643738, 0.6700000166893005, 0.6959999799728394, 0.7139999866485596, 0.746999979019165, 0.7649999856948853, 0.7860000133514404, 0.8410000205039978, 0.8339999914169312, 0.8309999704360962, 0.8550000190734863, 0.8820000290870667, inf, 1.6009999513626099, 1.524999976158142, 1.5379999876022339, 1.5720000267028809, 1.5709999799728394, 1.5540000200271606, inf, 0.8539999723434448, 0.8399999737739563, 0.8309999704360962, 0.8220000267028809, 0.8209999799728394, 0.8190000057220459, 1.5169999599456787, 1.5099999904632568, 1.5069999694824219, 1.5049999952316284, inf, 0.8840000033378601, 0.8389999866485596, 0.8259999752044678, 0.8230000138282776, 0.8349999785423279, 0.8360000252723694, inf, 1.5160000324249268, 1.5169999599456787, inf, inf, 0.6460000276565552, 0.6430000066757202, 0.6309999823570251, 0.6290000081062317, inf, 0.6449999809265137, inf, inf, 1.1970000267028809, 1.1660000085830688, 1.121000051498413, 1.1080000400543213, 1.0820000171661377, 1.0499999523162842, 1.0449999570846558, 1.0329999923706055, 1.0180000066757202, 1.003000020980835, 0.984000027179718, 0.9739999771118164, 0.953000009059906, 0.9340000152587891, 0.9229999780654907, 0.902999997138977, 0.8930000066757202, 0.8830000162124634, 0.8880000114440918, 1.0360000133514404, 1.003999948501587, 0.9879999756813049, 0.9620000123977661, 0.9459999799728394, 0.921999990940094, 0.9100000262260437, 0.8870000243186951, 0.875, 0.8519999980926514, 0.843999981880188, 0.8270000219345093, 0.8209999799728394, 0.8009999990463257, 0.7950000166893005, 0.777999997138977, 0.7730000019073486, 0.7599999904632568, 0.753000020980835, 0.7419999837875366, 0.7329999804496765, 0.7260000109672546, 0.7200000286102295, 0.7089999914169312, 0.699999988079071, 0.6940000057220459, 0.6949999928474426, 0.6790000200271606, 0.6769999861717224, 0.7409999966621399, 0.7910000085830688, 0.8140000104904175, inf, 0.8679999709129333, inf, 0.7910000085830688, 0.7839999794960022, 0.7789999842643738, 0.7670000195503235, 0.7649999856948853, 0.7540000081062317, inf, 0.7839999794960022, 0.7829999923706055, 0.7940000295639038, 0.8009999990463257, 0.8100000023841858, 0.8460000157356262, inf, 2.484999895095825]
intensities: [47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 0.0, 0.0, 0.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 47.0, 0.0, 0.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 0.0, 0.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 0.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0, 47.0, 47.0, 47.0, 47.0, 47.0, 0.0, 47.0]

 

 

 

你可能感兴趣的:(SLAM)