We are trying to derive the dynamical model of the robot’s arm to be the base of a new control method we are implementing.
As the question involves a lot of equations, we have attached the full question as images for convenience.
Please let us know if anything is unclear and thanks in advance!
It is nice to see that you are working on a new control method !
There is a simple way to get the center of mass and the inertia matrix that you need:
Follow the links to the the 3D mechanical parts of Reachy that have been shared in this post: 3D CAD models release!
When you can see Reachy’s parts in Onshape, you can click on the icon on the right side of the toolbar at the bottom of the interface.
There, you can click on the part that you’re interested in and have access to what you need:
I hope this is clear and will help you!
Thanks a lot for your reply, that’s definitely very helpful. We’ll check it out
Hey @Augustin (cc @pierre )
We’re still working on this dynamics model, which would give us the torque we need to (hopefully) overcome the effect of gravity.
In the meantime, we want to test out changing the motors’ torque through:
We are trying to find the default torque limit set to the motors, but cannot find it.
Does this mean that the motors are always given maximum torque if we do not manually change the
The torque_limit can be set via:
reachy.right_arm.shoulder_pitch.torque_limit = 50
It is expressed as a percentage of the physical maximum torque of the motor (see https://emanual.robotis.com/docs/en/dxl/mx/mx-28/#torque-limit for details).
And yes, by default the torque limit is set to 100% meaning its maximum.
@pierre just to clarify, does that mean that when calling the “reachy.goto(goal_positions, duration, wait)” method to move the robot, the motors uses its MAXIMUM torque?
if your answer is yes, does that mean we cannot compensate for the gravity by increasing the torque?
No It’s a bit more complex than that.
It actually means that when using the goto method the motor is allowed to use its maximum torque. You have to see the torque_limit as only the upper bound.
Yet, the real used torque will mainly depend on its PID controller and therefore and the trajectory you make it follow. If you ask the motor to go far and real quick, then it will most likely use its maximum torque.
@pierre yes that makes more sense, but that way you would need to modify the motor’s API to switch to current and position control mode, correct?
The Dynamixel motors used in Reachy only allow for position control. You can access the present current used by the motor but it’s extremely noisy and make force control impossible on such motor.
I’ve heard of people changing the firmware inside the motor to try to do force control, but without achieving significant results (and it obviously goes against Dynamixel warranty).
To sum up:
- you need to control them in position
- you can play with their PID gains to adjust their behavior
Thanks for your answer. Is there a straightforward way to change the PID gains (perhaps through the API?)
@pierre (cc @Augustin)
Do you have a response for this please? We have a tight deadline and would massively appreciate your help on this
It is not exposed directly by the motor yet, but you can access it via:
reachy.right_arm.shoulder_pitch._motor.positionPid = [4, 0, 0]