ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

controller frequency in navigation stack

asked 2016-02-19 13:29:07 -0500

Double X gravatar image

Hy,

I'm having problems with navigation of my robot. I am using ROS navigation stack. The thing is my robot is driving like a snake around calculated global plan (it's like it can't drive straight). I think that my encoder odometry data and transforms are fine. I tried changing the parameters for velocity, acceleration and others but I got stuck. The oscillations around the global plan trajectory are smaller but they are still there. I think that increasing my controller loop frequency could help me but for some reason I can't speed it up.

I am using rpi2 and my laptop which is synchronized with the ros master on my rpi2. On rpi2 I have nodes for laser, odometry and node that publishes frame transforms (and ros master). On my laptop I'm running nodes for amcl, map_server, move_base package and rviz.

The default rate for the control loop frequency is set to 20Hz, but it keeps sending me warnings that it missed it's desired rate. The real control loop frequency is close to 4Hz (but I would really like to make it higher). When I look at my CPU usage it is less then 60% on both rpi2 and laptop so I wonder what is the problem and is it possible to speed it up.

Thanks in advance

edit retag flag offensive close merge delete

Comments

I faced similar issue, I wonder did you solve it & how? Thanks.

g7tan gravatar image g7tan  ( 2021-11-03 14:53:35 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-02-19 14:28:04 -0500

Two easy things to check are:

  • Are you overloading your wireless network bandwidth? It might be much lower than you expect and bad connectivity can increase latency significantly.
  • Are the clocks of the machines properly synced? If they are off by, say 250ms, one machine would hang for that long while waiting for tf data to be valid. That could also cause lower update rates than desired.
edit flag offensive delete link more

Comments

First of all thanks for answering. Ok. I checked it. The problem was actually in frequency of publishing my laser scan data, which is around 6.5Hz. So, at this point the controller loop frequency problem is solved, but the robot is still behaving as it was.

Double X gravatar image Double X  ( 2016-02-24 07:40:03 -0500 )edit

Here is link to my new question about the problem (if you want to check it)

http://answers.ros.org/question/22745...

Double X gravatar image Double X  ( 2016-02-24 08:22:08 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2016-02-19 13:29:07 -0500

Seen: 3,241 times

Last updated: Feb 19 '16