0
$\begingroup$

Rosanswers logo

Hi everyone, the joints of my robot model start to sway when I spawn it in gazebo and then launch its controllers I added previously. Here is the contents of my yaml file:

cambot: # Publish all joint states ----------------------------------- joint_state_controller: type: joint_state_controller/JointStateController publish_rate: 50
# Position Controllers --------------------------------------- tilt_position_controller:

type: effort_controllers/JointPositionController
joint: tilt
pid: {p: 100.0, i: 0.01, d: 10.0}   pan_position_controller:
type: effort_controllers/JointPositionController
joint: pan
pid: {p: 100.0, i: 0.01, d: 10.0}   lift_position_controller:
type: effort_controllers/JointPositionController
joint: lift
pid: {p: 100.0, i: 0.01, d: 10.0}

And this is the contents of my launch file:

file="$(find cambot_description)/config/cambot_control.yaml" command="load"/>

What am I supposed to do to avoid the sway situation mentioned above?


Originally posted by stefanvan on ROS Answers with karma: 23 on 2018-03-27

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

You first probably want to tweak the controller PID parameters. This can be done at runtime using dynamic_reconfigure. I'd recommend dropping i and d gains to 0 and first adjusting p only. In most cases this adjustment is sufficient to make the robot "behave".

If your robot is hard to simulate correctly (for instance if it has very different masses/inertias of different links), then you might want to look at some other things to tweak as discussed in this Q/A and the links provided there.


Originally posted by Stefan Kohlbrecher with karma: 24361 on 2018-03-27

This answer was ACCEPTED on the original site

Post score: 2


Original comments

Comment by stefanvan on 2018-03-27:
Really appreciate your advice, sir. I do fix the problem by modifying the pid gains (even though I still can't comprehend the concept of pid).

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.