66Lau / NEXTE_Sentry_Nav

The navigation system of "sentry" for Next-E team in RoboMaster2023
MIT License
119 stars 17 forks source link

使用move_base导航出现问题 #7

Open dddddym203 opened 6 months ago

dddddym203 commented 6 months ago

您好,我在使用sentry_nav进行导航时出现问题。因为我的这个小车它的底盘本身代码里定义了一个机器人坐标系叫base_link,还有一个里程计坐标系叫odom_combined(这个小车是x86的主板,底盘上还有一个arduino,他这个里程计是通过编码器实现的轮速里程计(我也不太确定)。 所以和fast_lio的里程计就起了冲突。fast_lio里的里程计坐标系camera_init, 但当我运行sentry_localize和move_base这两个launch,然后看odom这个topic的时候,显示的都是odom_combined这个里程计坐标系的信息,也就是parent frame是odom_combined, child frame 是base_link的信息。而不是camera_init和body.

这个odom topic不对应该是我运行move_base失败的原因吧?运行move_base的话,刚开始会显示odom received, 但只要一在rviz里发布目标点,走的方向就不对,而且会显示报错和warning如下: [ERROR] [1711114322.923268666]: Global Frame: robot_foot_init Plan Frame size 49: map [ WARN] [1711114322.923286792]: Could not transform the global plan to the frame of the controller [ERROR] [1711114322.923304710]: Could not get local plan [ERROR] [1711114322.923268666]: Global Frame: robot_foot_init Plan Frame size 49: map [ WARN] [1711114322.923286792]: Could not transform the global plan to the frame of the controller [ERROR] [1711114322.923304710]: Could not get local plan [ WARN] [1711114322.924408719]: Map update loop missed its desired rate of 10.0000Hz... the loop actually took 0.1270 seconds [ INFO] [1711114322.973189092]: Got new plan [ WARN] [1711114323.093114183]: Control loop missed its desired rate of 20.0000Hz... the loop actually took 0.1200 seconds [ WARN] [1711114323.214691495]: Control loop missed its desired rate of 20.0000Hz... the loop actually took 0.1216 seconds [ WARN] [1711114323.324585396]: Control loop missed its desired rate of 20.0000Hz... the loop actually took 0.1099 seconds

大概tf tree如这个图所示:

1

这是主要因为里程计消息的原因吗?我应该怎么处理呢?需要把底盘里发布的里程计数据删掉?

66Lau commented 5 months ago

tf树是没问题的,fast_lio的里程计输出话题是/Odometry不是odom,你看看是不是把轮式里程计的话题输入给move_base了