Chefbot_ROS_pkg icon indicating copy to clipboard operation
Chefbot_ROS_pkg copied to clipboard

how did you tune your PID controller?

Open alexisdal opened this issue 5 years ago • 0 comments

thanks for your excellent book.

in chefbot_bringup/scripts/pid_velocity.py

        self.Kp = rospy.get_param('~Kp',10)
        self.Ki = rospy.get_param('~Ki',10)
        self.Kd = rospy.get_param('~Kd',0.001)

however, in the book and the launch file chefbot_bringup/launch/robot_standalone.launch

      <rosparam param="Kp">400</rosparam>
      <rosparam param="Ki">100</rosparam>
      <rosparam param="Kd">0</rosparam>

There is a significant difference between the defaults values in the python pid code and what you finally used. I am also guessing that the parameter ticks_meter (which depends on hardware encoder resolution * gear reduction) might influence the final Kp/Ki/Kd. You must have somehow tuned your PID controller. But -- unless i missed it -- it says nothing about the procedure you used to tune it. I'm complete noob about PID. Wikipedia does mention a manual procedure, but i could not implement it successfully with my own hard (in particular my ticks_meters value (that i did calibrate following its specific section in the book), is much lower.

Bottom line : how did you tune the Ki/Kp/Kd values of your pid controller?

alexisdal avatar Aug 24 '18 08:08 alexisdal