Robotics StackExchange | Archived questions

Position ONLY IK with seed value using MoveIt

Hi,

I am using moveit for IK calculation of my Baxter Robot. I want to calculate the joint angles for a given position (excluding orientation) of End-Effector.

Following is code snippet:

import moveit_commander
group = moveit_commander.MoveGroupCommander("left_arm")
group.set_position_target([x, y, z])
plan = group.plan()

The variable plan contains complete trajectory for moving the robot arm from current position to target position. BUT I just want the joint angles for target position, so I select the last element of this trajectory to get the joint angle. There can be many solutions for a given position for Baxter arm, hence I want to provide an initial estimate of the joint angles as a seed value. So that moveit can search for IK solution nearest to the seed value.

Below are my questions:

  1. How to set seed value in moveit for IK calculation?
  2. How to perform IK for position only input (better suggestion compared to my approach) ?

- Thanks

Asked by ravijoshi on 2017-02-01 08:43:10 UTC

Comments

any suggestion, please?

Asked by ravijoshi on 2017-02-02 21:07:33 UTC

Answers

You can prolly use getPositonIK or searchPositionIK to provide a seed pose. As for doing position only IK, some solvers allow specifying a position_only_ik parameter, but I've not gotten it to work. (See here and here)

Asked by Rufus on 2021-02-18 10:24:31 UTC

Comments