Skip to content

Tuning PID in gazebo for SUMMIT XL Robot #30

@Eswar1991

Description

@Eswar1991

Hi all,
We are trying to move SUMMIT XL robot in a straight line and circle in gazebo. In connection with this task, we used PID controller for wheel actuation joints to obtain accurate output motion and response.

For this purpose, we have changed the launch files of summit xl robot to tune the pid gains as shown below:


  <param name="/robot/gazebo_ros_control/pid_gains/$(arg prefix)front_left_wheel_joint/p" type="double" value="$(arg p)" />
  <param name="/robot/gazebo_ros_control/pid_gains/$(arg prefix)front_left_wheel_joint/i" type="double" value="$(arg i)" />
  <param name="/robot/gazebo_ros_control/pid_gains/$(arg prefix)front_left_wheel_joint/d" type="double" value="$(arg d)" />

  <param name="/robot/gazebo_ros_control/pid_gains/robot_back_right_wheel_joint/p" type="double" value="$(arg p)" />
  <param name="/robot/gazebo_ros_control/pid_gains/robot_back_right_wheel_joint/i" type="double" value="$(arg i)" />
  <param name="/robot/gazebo_ros_control/pid_gains/robot_back_right_wheel_joint/d" type="double" value="$(arg d)" />

  <param name="/robot/gazebo_ros_control/pid_gains/robot_back_left_wheel_joint/p" type="double" value="$(arg p)" />
  <param name="/robot/gazebo_ros_control/pid_gains/robot_back_left_wheel_joint/i" type="double" value="$(arg i)" />
  <param name="/robot/gazebo_ros_control/pid_gains/robot_back_left_wheel_joint/d" type="double" value="$(arg d)" />

However, the outputs are not desirable. The effect of d-gain is to mitigate the oscillations in response patterns of velocity, which is not happening.

image

In both planar and differential drive plugins, it can be seen that the response patterns oscillates, and it doesn't reduce even by increasing d-gain.

For some values of p (>=100) with i & d being zero, the robot moves/ oscillates around the finish point, although the motion is complete.

Please see the below gif where the robot moves in a circle and after reaching the finsh point, it oscillates about that point (p=100, i=0, d=0)

https://lh3.googleusercontent.com/-K-9B7Z6JKZM/XuSAtjxyopI/AAAAAAAAAzQ/GQo42t1xkRMtWb1GvtGmQmNNkxQo14H0QCK8BGAsYHg/s0/gif2.gif

With reduced value of p, this behavior vanishes, but the circle formed is of greater dimension than the actual...
With both p and d enabled, the robot begins to oscillate at the start itself.
p:100 i:0 d:10
https://lh3.googleusercontent.com/-K-0_LrgqTR0/XuSBNUx0urI/AAAAAAAAAzo/x-gdf77g14cqAmhhKIurU7czDIrGK_5TgCK8BGAsYHg/s0/gif3.gif

We are being confused with this, as these behaviours are new and not getting aligned with our knowledge on PID Control theory. Is the summit xl being properly configured for manual tuning of PID gains in simulation? Is there any problem in this configuration?
Or, do we need to change the approach we used? Is it preferrable to do PID tuning in gazebo?

Any help on this issue would be appreciated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions