# Help to run diff_drive_controller

I’m trying to launch the diff_drive_controller but I get this message when I run the .launch file.

“Controller Spawner: Waiting for service controller_manager/load_controller”

" Controller Spawner couldn't find the expected controller_manager ROS interface."

This is my .launch file: https://www.dropbox.com/s/gwtwy3ogzq8... . I try with args="mobile_base_controller" instead of args="diff_drive_controller"

And the config file that I copied from the diff_drive_controller site.

mobile_base_controller:
type        : "diff_drive_controller/DiffDriveController"
left_wheel  : 'wheel_left_joint'
right_wheel : 'wheel_right_joint'
publish_rate: 50.0               # default: 50
pose_covariance_diagonal : [0.001, 0.001, 1000000.0, 1000000.0, 1000000.0, 1000.0]
twist_covariance_diagonal: [0.001, 0.001, 1000000.0, 1000000.0, 1000000.0, 1000.0]

# Wheel separation and diameter. These are both optional.
# diff_drive_controller will attempt to read either one or both from the
# URDF if not specified as a parameter
wheel_separation : 1.0

# Wheel separation and radius multipliers
wheel_separation_multiplier: 1.0 # default: 1.0
wheel_radius_multiplier    : 1.0 # default: 1.0

# Velocity commands timeout [s], default 0.5
cmd_vel_timeout: 0.25

# Base frame_id

# Velocity and acceleration limits
# Whenever a min_* is unspecified, default to -max_*
linear:
x:
has_velocity_limits    : true
max_velocity           : 1.0  # m/s
min_velocity           : -0.5 # m/s
has_acceleration_limits: true
max_acceleration       : 0.8  # m/s^2
min_acceleration       : -0.4 # m/s^2
has_jerk_limits        : true
max_jerk               : 5.0  # m/s^3
angular:
z:
has_velocity_limits    : true
has_acceleration_limits: true
has_jerk_limits        : true



Thanks for the help, I’m desperate with the ros_control package. Sorry for my english.

edit retag close merge delete

args="diff_drive_controller" is definitely wrong since you have it as "mobile_base_controller" in the config. The ns="/robot" also looks wrong, as I don't the config loaded into this namespace.

( 2018-04-25 03:04:17 -0500 )edit

Sort by » oldest newest most voted

Hi Jaime, you have a couple of errors in the information you posted:

1. the args on the launch file, do not have the correct name. You should specify there the name of the controller you defined in the config file, that is mobile_base_controller
2. also in the launch file, you are indicating a namespace /robot but that is not included in the yaml file. You can get rid of it

Those two points should resolved the problem of controller spawner couldn't .... However, you may have later a problem loading the controller with a different error report.

Since I don't know if you are loading the ROS control plugin and if you are specifying the transmisions. You need to do that in your URDF model if you want the controllers to load properly.

Have a look at this video where I show step by step how to modify your files for proper working: https://goo.gl/ZWE5st

more

Thanks a lot for the answers and specialy for the dedicated video.

Finaly I can launch the control node. You can see in this video one of the test of the weelchair working https://www.youtube.com/watch?v=2xSHQ...

( 2018-08-18 06:38:41 -0500 )edit