-
Notifications
You must be signed in to change notification settings - Fork 3
Feet in the half-sitting position are not flat on the ground #7
Description
The half-sitting position, defined in https://github.com/stack-of-tasks/sot-talos/blob/master/src/dynamic_graph/sot/pyrene/robot.py, is currently given as
halfSitting = (0.0, 0.0, 1.018213, 0.00 , 0.0, 0.0, #Free flyer
0.0, 0.0, -0.411354, 0.859395, -0.448041, -0.001708, #Left Leg
0.0, 0.0, -0.411354, 0.859395, -0.448041, -0.001708, #Right Leg
0.0 , 0.006761, #Chest
0.25847 , 0.173046, -0.0002, -0.525366, 0.0, -0.0, 0.1, -0.005, #Left Arm
-0.25847 , -0.173046, 0.0002 , -0.525366, 0.0, 0.0, 0.1,-0.005, #Right Arm
0., 0. #Head
)
With this configuration, the feet are not flat on the ground, but slightly tilted around the x-axis. These are the results I get (I add the CoM for reference):
leg_left_6_joint: 13
R =
1 0 0
0 0.999999 0.001708
0 -0.001708 0.999999
p = -0.00884695 0.085 0.105941
leg_right_6_joint: 27
R =
1 0 0
0 0.999999 0.001708
0 -0.001708 0.999999
p = -0.00884695 -0.085 0.105941
com: [-0.003163736637462875, 0.0012373842912037295, 0.875624058590194]
This does not seem a good idea.
The last joint of each leg corresponds to the roll angle of the respective ankle. It is enough to set these two joints to zero instead of their current value of -0.001708, and the problem is solved.
In other words, by correcting the half-sitting configuration to
halfSitting = (0.0, 0.0, 1.018213, 0.00 , 0.0, 0.0, #Free flyer
0.0, 0.0, -0.411354, 0.859395, -0.448041, 0.0, #Left Leg
0.0, 0.0, -0.411354, 0.859395, -0.448041, 0.0, #Right Leg
0.0 , 0.006761, #Chest
0.25847 , 0.173046, -0.0002, -0.525366, 0.0, -0.0, 0.1, -0.005, #Left Arm
-0.25847 , -0.173046, 0.0002 , -0.525366, 0.0, 0.0, 0.1,-0.005, #Right Arm
0., 0. #Head
)
the results are
leg_left_6_joint: 13
R =
1 0 0
0 1 0
0 0 1
p = -0.00884695 0.085 0.105941
leg_right_6_joint: 27
R =
1 0 0
0 1 0
0 0 1
p = -0.00884695 -0.085 0.105941
com: [-0.0031637366374628797, 0.0012410807883628755, 0.8756240439687248]
The error is tiny and invisible to the naked eye (about one hundredth of a degree) but it was screwing up the expected results in some unit tests I was making, where I required really strict correspondence between the algorithmic results and the analytically-computed ones (specifically, the transformation of the vertical force to the local ankle frame was causing a tiny force along the y-axis to appear, a bit less than 1 N, which is irrelevant from the control viewpoint but was still much more than I expected).
I do not know how these values were chosen, but I really think the feet in the default position should be flat on the ground. That is what one would expect.
Should we change the half-sitting configuration to reflect this need?