Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

Use SolveIK with freedom for the 6th joint

#1
Hi,
I would like to know if it is possible to use the SolveIK call to solve for a point/vector only (not force a fix xt/yt direction)?  In some case (like a touch probe) it is only necessary to solve for a point/vector.

Is this already possible or do we have to do it by trial/error  ?

Thanks,
Francois
#2
Your request may have different answers depending on the mechanism being used. Specifying a point and a vector is a 5-DOF constrain and it would give you a unique solution for a 5-axis machine (which makes sense).

For example, for a 6-axis robot, a 5-DOF constrain (like specifying a point and a vector) would give you infinite solutions. Another example is that a a 6-DOF constrain (full position and orientation, also known as pose) on 7-axis can easily give you infinite solutions.

Another example would be for a 5-axis CNC: specifying a point and a vector constrain makes total sense as this is a 5-DOF constrain for a 5-axis machine. In RoboDK when you provide the pose to the SolveIK function, we only account for the position and the Z axis of the machine flange to perform the inverse kinematic calculations.

For your information, we have recently improved the solver of 5-axis CNC to prioritize the XYZ position of the machine tool flange and the Z vector of the same flange.
#3
(12-07-2024, 04:58 PM)Albert Wrote: For example, for a 6-axis robot, a 5-DOF constrain (like specifying a point and a vector) would give you infinite solutions. Another example is that a a 6-DOF constrain (full position and orientation, also known as pose) on 7-axis can easily give you infinite solutions.

This is the mechanism I am interested in: Using a 6DOF robot to do, let's say, CNC program, where the 6th joint position is not important (one position still need to be computed at the end). 
It there a way to use SolveIK with just a point/vector (and maybe a joints_approx)?

Thanks
#4
If you have a 6DOF mechanism or robot arm and you need to calculate the inverse kinematics given a point and the Z vector of the pose you could use the function point_Zaxis_2_pose:
https://robodk.com/doc/en/PythonAPI/robo...xis_2_pose

This function takes the point, the Z axis and returns the pose. You can optionally provide a Y axis as a hint. Example:
Code:
from robodk ipmort robomath
point = [x,y,z]
zaxis = [i,j,k]
yaxis_hint = [0,1,0]
pose = robomath.point_Zaxis_2_pose(point, zaxis, yaxis_hint1=[0, 0, 1], yaxis_hint2=[0, 1, 1])
joints = robot.SolveIK(pose)
#5
Hi Albert,
this I already know how to do.
What I mean is what if the Pose that was computed by point_Zaxis_2_pose is not reachable by the robot (SolveIK can't find a solution). 

It looks like you don't have a way to do that except by trial and error, use SolveIK with different pose (same point/normal but different xt/yt direction) until SolveIK worked, is that right?
Thanks,
Francois
#6
Great then. We don't have another solution for now. Another option is to iterate over the pose by changing the rotation around the Z axis and calculate the inverse kinematics solution, for example, from 0 to +/- 180 deg around the Z axis by steps of 45 deg.
#7
(12-18-2024, 03:49 PM)Albert Wrote: Great then. We don't have another solution for now. Another option is to iterate over the pose by changing the rotation around the Z axis and calculate the inverse kinematics solution, for example, from 0 to +/- 180 deg around the Z axis by steps of 45 deg.

Thank you Albert, this is what I was thinking from the start, just wanted to make sure there was no other way.
#8
There is no other way for the time being but let us know if you have performance issues and we can take a better look to help you implement a custom solution.
  




Users browsing this thread:
1 Guest(s)