robotics-toolbox-python
robotics-toolbox-python copied to clipboard
Inverse kinematics with a custom tool frame
Thank you for your work on this great software package!
I am working with the xarm6 urdf with no end-effector, and I would like to use a tool frame transform. For forward kinematics, I am using
Tool = sm.SE3.Tz(0.1)
ee = xarm.fkine(xarm.q, tool=Tool)
How do I include Tool in the ik solvers? Setting xarm.tool = Tool does not work, and there is no tool argument in the ik functions.
I found a solution:
import roboticstoolbox as rbt
import spatialmath as sm
ets_tool_transform = rbt.ET.tz(0.1)
x6 = # (type = rtb.Robot), from URDF file
ets = x6.ets()
# ets = x6.ets().copy() # could be better?
ets.insert(ets_tool_transform)
# Usage:
ets.fkine(q)
ets.ik_GN(T) # T \in sm.SE3
I don't know if this is a bug, but using x6.fkine(..), x6.ik_GN(..), x6.ik_GN(..), etc. does not produce the same results as calling ets functions, even though updating ets also updates x6.ets().
Do you have a way to use the UR5 robotic arm and Robotiq grippers?