Ask Your Question
0

change base_local_planner params min and max

asked 2014-03-17 11:37:05 -0600

AbuIbra gravatar image

updated 2014-03-19 08:30:01 -0600

When I run the rqt_reconfigure, I can see that some of the base_local_planner params can't be chosen outside certain limits. If we look at the package responsible for this we can see on the /opt/ros/fuerte/stacks/navigation/base_local_planner/cfg/BaseLocalPlanner.cfg file for example: (min = 0.0 and max = 20.0)

gen.add("min_vel_x", double_t, 0, "The minimum x velocity for the robot in m/s", 0.0, 0.0, 20.0)

What if I want the min and max to be different. For example, min = -5.0 and/or max = 25.0? How can I do this (without touching the original code if possible)?

Edit

ahendrix: I wonder if your answer is just a guess: In fact, a negative minimum velocity does make sense (you give no evidence for why this does not make sense)!
Putting a negative value on my base_local_planner_param.yaml file make my robot able to move backwards when given a goal to move_base. While it doesn't at all when this value is >= 0.0 (or when I use the rqt_reconfigure to change params of course) That's exactly the change I want to be able to do dynamically (i.e. without relaunching move_base with a new config file). As for the 25.0 change it was just a suggestion, and it would be great if Icould lower the max value (and many other max values) to avoid the uselessly high velocities possibilities.

Edit 2

Here's the solution I found. Copy the whole base_local_planner package, then modify the .cfg file on the copy. Rename the original package to avoid conflict with copy. Finally, compile the copy: it compiles with no problem! Every thing looks fine! I can now dynamically change configuration to make the robot move only backwards for the manoeuvres of my choice: it works perfectly.

(PS: Renaming a ROS installed package is not a healthy practice I guess. I could have modified the copy to make it compile with a complete new name. But... I am lazy)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2014-03-17 12:47:04 -0600

ahendrix gravatar image

updated 2014-03-17 16:38:34 -0600

This isn't possible.

The minimum and maximum limits are specified in the cfg, and you'll have to modify the cfg to change them.

That said, your proposed changes are a bit absurd; 20 m/s is already VERY fast for the average robot ( 45 miles/hour or 72 kilometers/hour), and a negative minimum velocity doesn't make sense in this context, because min_vel_x is meant as the minimum velocity required to make the robot move.

If your local planner doesn't plan backwards when it should, you may need to adjust the other planner parameters or switch planners.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2014-03-17 11:37:05 -0600

Seen: 751 times

Last updated: Mar 19 '14