unitreerobotics / unitree_legged_sdk

SDK tools for control robots.
BSD 3-Clause "New" or "Revised" License
283 stars 156 forks source link

is there a way to give a high level velocity command and see what joint torques it applies? #82

Open dhruvmetha opened 1 year ago

dhruvmetha commented 1 year ago

I see the MotorState has the estimated output torque, but I want to know what joint torques are being applied from the high level velocity command

Wsser commented 1 year ago
    uint8_t mode;                      // motor working mode 
    float q;                           // current angle (unit: radian)
    float dq;                          // current velocity (unit: radian/second)
    float ddq;                       // current acc (unit: radian/second*second)
    float tauEst;                    // current estimated output torque (unit: N.m)
    float q_raw;                       // current angle (unit: radian)
    float dq_raw;                      // current velocity (unit: radian/second)
    float ddq_raw;
    int8_t temperature;                // current temperature (temperature conduction is slow that leads to lag)
    // uint32_t reserve[2];
    std::array<uint32_t, 2> reserve;
} MotorState;                          // motor feedback

This is the current estimated output torque of the motor based on the current

xyq1223 commented 1 year ago

Hello,you can download the latest version of our SDK and run it again https://github.com/unitreerobotics/unitree_legged_sdk/tree/go1