Re: ikine problem

554 views
Skip to first unread message
Message has been deleted

Erik van Oene

unread,
Oct 24, 2017, 3:08:57 PM10/24/17
to Robotics & Machine Vision Toolboxes
Hi,

I have a few remarks.
  1. You excluded the rotational part, which may lead to an unreachable pose for the robot. (one of the two reasons I see often resulting in this warning)
  2. did you mix interchange T2 and T1 on purpose?
  3. You do not give the ikine function n initial guess,  (second reasons I see often resulting in this warning)
try to alter these two lines:
T = ctraj(T1, T2, 50);   -->       T = ctraj(Tz1, Tz2, 50);

q
= Robot.ikine(T);      -->       q = Robot.ikine(T,[0, 0, 0, 90, 0, 0]);


and the code runs fine here.

Erik

Op dinsdag 24 oktober 2017 20:52:17 UTC+2 schreef ...mail.com:
Hello,

I am trying to solve inverse problem for 6DOF manipulator (I am trying to do a kinematics for human arm).

I want to test the trajectory from one point to another but this problem occurs:

Warning: ikine: rejected-step limit 100 exceeded (pose 1), final err
0.81 
> In SerialLink/ikine (line 244)
  In test_workspace (line 35) 
Warning: failed to converge: try a different initial value of joint
coordinates 

To get the beginning position of end effector and the end position I performed fkine method:

Tz1 = Robot.fkine([0, 0, 0, 90, 0, 0])
Tz2 = Robot.fkine([0, 0, 0, 120, 0, 0])

It returned me this:

Tz1 = 
   -0.4481   -0.8940         0      89.4
         0            0              1         0
   -0.8940    0.4481         0     155.2
         0            0              0         1
 

Tz2 = 
    0.8142   -0.5806         0     58.06
         0            0              1        0
   -0.5806   -0.8142         0     281.4
         0            0              0         1


So I assumed that (x = 89, y = 0, z = 155) could be my start point and the end one could be a (x = 58, y = 0, z = 281)

but it appears that something went wrong... Could someone help me with it? Thanks in advance.


P (1) = Link([0  100  0  pi/2]);
P (2) = Link([0  0    0  -pi/2]);
P (3) = Link([0  100  0  -pi/2]);
P (4) = Link([0  0    0  pi/2]);
P (5) = Link([0  100    0  -pi/2]);
P (6) = Link([0  0    0  0]);

Robot = SerialLink(P);

Tz1 = Robot.fkine([0, 0, 0, 90, 0, 0])
Tz2 = Robot.fkine([0, 0, 0, 120, 0, 0])

T2 = transl(89, 0, 155) % define the start point
T1 = transl(58, 0, 281) % and destination
T = ctraj(T1, T2, 50); % compute a Cartesian path

% now solve the inverse kinematics

q = Robot.ikine(T); 

Robot.plot(q);

Message has been deleted

Erik van Oene

unread,
Oct 25, 2017, 2:10:20 PM10/25/17
to Robotics & Machine Vision Toolboxes
Hi,

This is probably a bug in the SE3 class which I fixes a while ago. Although I was not able to find my fix anymore.

does this line works for you?

T = ctraj(Tz1.double, Tz2.double, 50); % compute a Cartesian path


Erik

Op woensdag 25 oktober 2017 19:23:53 UTC+2 schreef p....ail.com:
Hello Eric!

Thank you very much for your support.

I changed the code according to your remarks:

P (1) = Link([0  100  0  pi/2]);
P (2) = Link([0  0    0  -pi/2]);
P (3) = Link([0  100  0  -pi/2]);
P (4) = Link([0  0    0  pi/2]);
P (5) = Link([0  100    0  -pi/2]);
P (6) = Link([0  0    0  0]);

Robot = SerialLink(P);

Tz1 = Robot.fkine([0, 0, 0, 90, 0, 0]);
Tz2 = Robot.fkine([0, 0, 0, 120, 0, 0]);

T = ctraj(Tz1, Tz2, 50); % compute a Cartesian path


% now solve the inverse kinematics

q = Robot.ikine(T,[0, 0, 0, 90, 0, 0]);

Robot.plot(q);


This is matlab output:

>> test_workspace
Error using SE3/interp (line 437)
error in trinterp

Error in SE3/ctraj (line 474)
                traj(i) = T0.interp(T1, s(i));

Error in test_workspace (line 29)
T = ctraj(Tz1, Tz2, 50); % compute a Cartesian path


did you mix interchange T2 and T1 on purpose?

No, it wasn't done on purpose it was just a copy paste error.

Could you please help with it?


Best regards,

program...@gmail.com

unread,
Oct 25, 2017, 2:16:40 PM10/25/17
to Robotics & Machine Vision Toolboxes
Yes, it helped!

Thank you very much for your help Eric.

Best regards

ask2...@gmail.com

unread,
Dec 2, 2017, 5:28:21 PM12/2/17
to Robotics & Machine Vision Toolboxes

Hi,

This discussion is also very helpful for me too. I am working on RRRP Robot.
Thank you very much Eric and program...@gmail.com for hlep .

Best Regards
Zain

Peter Corke

unread,
Dec 2, 2017, 6:48:49 PM12/2/17
to Robotics & Machine Vision Toolboxes
Using RTB10.2 your example

P (1) = Link([0  100  0  pi/2]);
P
(2) = Link([0  0    0  -pi/2]);
P
(3) = Link([0  100  0  -pi/2]);
P
(4) = Link([0  0    0  pi/2]);
P
(5) = Link([0  100    0  -pi/2]);
P
(6) = Link([0  0    0  0]);

Robot = SerialLink(P);

Tz1 = Robot.fkine([0, 0, 0, 90, 0, 0]);
Tz2 = Robot.fkine([0, 0, 0, 120, 0, 0]);
T
= ctraj(Tz1, Tz2, 50); % compute a Cartesian path
q = Robot.ikine(T,[0, 0, 0, 90, 0, 0]);


works perfectly

rood...@gmail.com

unread,
Jan 26, 2019, 6:15:46 PM1/26/19
to Robotics & Machine Vision Toolboxes
please how can in find my Mask value ? what is the technique

Peter Corke

unread,
Jan 26, 2019, 6:53:42 PM1/26/19
to Robotics & Machine Vision Toolboxes
You have not provided enough information to answer this.  Have you read the documentation for ikine()?
Reply all
Reply to author
Forward
0 new messages