Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inverse kinematics with a custom tool frame #452

Open
guri-dominic opened this issue Jul 31, 2024 · 1 comment
Open

Inverse kinematics with a custom tool frame #452

guri-dominic opened this issue Jul 31, 2024 · 1 comment

Comments

@guri-dominic
Copy link

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.

@guri-dominic
Copy link
Author

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().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant