ROS2 humble, controller wont connect to service
Hello, Running ROS2 humble, Ubuntu 22.04.1LTS.
I have a model which is spawned in gazebo 11, and another node which is publishing data on '/forward_position_controller/commands', and the model is supposed to movie in space.
My problem is running the controller.
I have a yaml:
controller_manager:
ros__parameters:
update_rate: 100
joint_trajectory_controller:
type: joint_trajectory_controller/JointTrajectoryController
#broadcaste the state
joint_state_broadcaster:
type: joint_state_broadcaster/JointStateBroadcaster
#joint_trajectory_controller:
# type: joint_trajectory_controller/JointTrajectoryController
forward_position_controller:
type: forward_command_controller/ForwardCommandController
forward_vilocity_controller:
type: forward_command_controller/ForwardCommandController
forward_position_controller:
ros__parameters:
joints:
- crutch_joint__imu_position #joint the controller will control
interface_name: position #same name as defined in the sdf/urdf file
command_interfaces:
- position #
state_interfaces:
- position
- velocity
forward_vilocity_controller:
ros__parameters:
joints:
- crutch_joint__imu_position
interface_name: velocity
command_interfaces:
- velocity
state_interfaces:
- velocity
and in my launch I run the controller
ExecuteProcess(
cmd=['ros2', 'control', 'load_controller', '--set-state', 'active', "forward_position_controller"],
name="forward_position_controller",
output='screen'),
#Start controller
ExecuteProcess(
cmd=['ros2', 'control', 'load_controller', '--set-state', 'active', "forward_velocity_controller"],
name="forward_velocity_controller",
output='screen'),
but I always get the same error: "Could not contact service /controller_manager/load_controller"
A friend of mine running ros2 galactic is having the same issue Another friend is running ros1 and having similar issue. (its done little bit different but same error)
Is there any other way to move a model which is spawned in gazebo11 from a node that publishes data, any data. All i need for now is just to move the model....
BR, Anis
Not (necessarily) the cause, but just wanted to draw attention to the
forward_vilocity_controller
vsforward_velocity_controller
..Yeah I noticed it, but not fixing the problem.