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

Inquiry about Tau Calculation in Robotics Control using CasADi #432

Open
tommasoandina1 opened this issue Apr 30, 2024 · 1 comment
Open

Comments

@tommasoandina1
Copy link

Hi everyone,

I hope you're all doing well. I'm currently working on a robotics control project using Python and the CasADi library. I have some doubts regarding the calculation of tau, especially in determining the actual joint positions compared to the desired ones.

I'm wondering if anyone could provide some guidance on how to approach this challenge. Specifically, I'm unsure whether it's more appropriate to use a forward kinematics law to estimate the real joint positions or if I should opt for more complex simulations. My goal is to strike a balance between computational efficiency and control precision.

Additionally, I'm unsure how to determine the values of ( q_{\text{des}} ) (desired joint position) and ( q ) (actual joint position). Should I use trajectory planning algorithms or rely on sensor feedback for ( q )?

I'm using the following equations in my project:

  1. The equation to solve for joint acceleration (ddq) is:

    ddq = M^-1(tau - h)

    Where:

    • M is the mass matrix,
    • h are the bias forces, and
    • tau are the joint torques.
  2. The joint torques (tau) are calculated using a proportional-derivative (PD) control law:

    tau = Kp(q_des - q) - Kd*dq

    Where:

    • Kp and Kd are the proportional and derivative gains respectively,
    • q_des is the desired joint position,
    • q is the actual joint position, and
    • dq is the actual joint velocity.

I would greatly appreciate any insights, suggestions, or references to relevant resources that could help me tackle this issue effectively.

Thank you very much in advance for your assistance!

https://github.com/tommasoandina1/Doosan_h2515/edit/main/doosan_h25215.py

@tommasoandina1
Copy link
Author

and I know that
q_next = q + dt * dq
dq_next = dq + dt * ddq

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

No branches or pull requests

1 participant