turtlebot / turtlebot_apps

A group of simple demos and exmaples to run on your TurtleBot to help you get started with ROS and TurtleBot.
http://www.ros.org/wiki/turtlebot_apps
196 stars 225 forks source link

In place rotations with dwa performance #91

Closed stonier closed 10 years ago

stonier commented 10 years ago

Currently the in place rotations that the dwa create have almost zero (e.g. 0.04 rad/s) angular velocity and for most robots, this command will not generate any movement.

This seems to be independant of the min_rot_vel parameter (i.e. this one seems to go unused).

stonier commented 10 years ago

This particular line is the magic for dwa.

  if ((limits_->min_trans_vel >= 0 && vmag + eps < limits_->min_trans_vel) &&
      (limits_->min_rot_vel >= 0 && fabs(sample_target_vel[2]) + eps < limits_->min_rot_vel)) {
    return false;
  }

A min_trans_vel of zero automatically passes this check and allows trajectories of negligible rotational velocity.