I'm using the 'MoveL_Test' method in the following way:
when res = 0 (which is good, and means I would like to move the arm linearly), I see in the simulation that the arm position changes slightly after the MoveL_Test command (before I'm actually moving it (via 'MoveL')).
Is it a bug, or am I doing something wrong?
(if it helps, here is an example for the pos change:
from Pose(590.000, 0.000, 400.000, 180.000, -0.000, -90.000)
to Pose(442.954, 67.952, 400.000, 180.000, -0.000, -67.569))
02-07-2019, 08:41 AM
(This post was last modified: 02-07-2019, 09:22 AM by Yotamish.)
Hi Albert, thanks for your reply. I didn't quite understand it though. I'll try to make myself more clear.
I've attached a short code snippet of what I'm doing - going through all inverse kinematics solutions of the original pos, to verify if I have a linear path from origin to the pos destination.
I'm using MoveL_Test since in your documentation, all it does is validate if there is a linear path between current joint configuration and end pos of the gripper.
What happens is that after using MoveL_Test - the arm itself moves (hence the function does more than just validate if the motion is possible).
If this is indeed an expected behavior, I would really appreciate if you could tell me how I can verify in advance, using your API, if I can move the arm linearly from one gripper position to the other, while going through all inverse kinematics potential solutions. (since sometimes If I use your MoveL, and the joint config hits a singularity, I could have used another joint config for the same pos, without hitting this singularity)
Thanks in advance!
inverse_k_sols = self._solveIK(self.arm) #returns all Inverse Kinematics solutions
for i in range(0,len(inverse_k_sols)):
new_robot_joints = inverse_k_sols[:, i]
new_linear_move_res = self.arm.MoveL_Test(new_robot_joints, target.Pose()) #FIXME: after this command, if the result is 0, the arm position is moved!
if (new_linear_move_res != -1) and (new_linear_move_res != -2):
Another issue is that the return value of MoveL_Test is sometimes 0 and sometimes 1 (in addition to -1 and -2).
Could you please state the difference if there is one?
Thanks a lot for the replies,