Problem moving the robot to specific position


I’m in the 2nd part of the quiz. I’ve already created my project_controller package, and I’ve created my custom controller. In my .yaml file, I assigned to the shoulder_lift_joint my custom controller (of type ur5_custom_controller/PositionController). When I launch my launch file, all the controllers are loaded correctly (It doesn’t shows any error message), but when I launch the launch file, the robot starts moving in a strange way, as it was colliding with something:


To move the robot to the desired position in the simulation, I’ve tried to modify the gain and setpoint values of the cpp file. But it doesn’t work. So I got stuck here and I don’t know how to proceed.

Any help would be appreciated :smiley:

Hello @a01731815,

That’s the way to test it! You can try also commands like:

rostopic pub /ur5/shoulder_lift_joint_position_controller/command std_msgs/Float64 “data: -1.5”

in order to find out which positions are reachable for the joint. This way, you won’t have to modify and recompile the code each time you want to test.


1 Like

Thank you! My problem was that I was forgetting to recompile the code after modifying the setpoint value in the cpp file. It works now.

1 Like