Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for getting PID parameters from loaded parameters (backport #374) #375

Merged
merged 1 commit into from
Sep 17, 2024

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Sep 16, 2024

Hello!

The issue #369 will be fixed once this is merged. It seems that for our Humanoids we will be needing this PID feature to make it work using position.

This PR:

I hope this helps someone. If this PR changes look fine. I will open the following PR in the gz_ros2_control

   <gazebo>
      <plugin filename="libgazebo_ros2_control.so" name="gazebo_ros2_control">
        <ros>
          <argument>--ros-args</argument>
          <argument>--params-file</argument>
          <argument>$(find talos_description)/config/gazebo_controller_manager_cfg.yaml</argument>
        </ros>
        <hold_joints>false</hold_joints>
        <parameters>$(find talos_description)/config/gazebo_controller_manager_cfg.yaml</parameters>
      </plugin>
    </gazebo>

Defining it like this should work

gazebo_ros2_control:
  ros__parameters:
    pid_gains:
      position:
        leg_left_1_joint: {kp:  5000.0, kd: 20.0, ki:  5.0, max_integral_error: 10000.0}
        leg_left_2_joint: {kp:  5000.0, kd: 20.0, ki:  5.0, max_integral_error: 10000.0}
        leg_left_3_joint: {kp:  5000.0, kd: 20.0, ki:  5.0, max_integral_error: 10000.0}
        leg_left_4_joint: {kp:  5000.0, kd: 20.0, ki:  5.0, max_integral_error: 10000.0}
        leg_left_5_joint: {kp:  5000, kd: 20.0, ki:  5.0, max_integral_error: 10000.0}
        leg_left_6_joint: {kp:  5000.0, kd: 20.0, ki:  5.0, max_integral_error: 10000.0}<hr>This is an automatic backport of pull request #374 done by [Mergify](https://mergify.com).

Co-authored-by: Christoph Fröhlich <[email protected]>
Co-authored-by: Alejandro Hernández Cordero <[email protected]>
(cherry picked from commit 6a4cc84)
@saikishor
Copy link
Member

@ahcorde Great news! The backports seem to work already without any issues. Tested on a fresh docker Humble docker

@ahcorde ahcorde merged commit 145e25e into humble Sep 17, 2024
5 checks passed
@ahcorde ahcorde deleted the mergify/bp/humble/pr-374 branch September 17, 2024 09:36
@saikishor
Copy link
Member

@ahcorde Can we tag and release to upstream the changes in the branch humble and iron?
and can we tag the master branch, without any release?

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants