calculateInverseKinematics - currentPosition

Official Python bindings with a focus on reinforcement learning and robotics.
Post Reply
robin_rob96
Posts: 3
Joined: Thu Jan 21, 2021 12:40 pm

calculateInverseKinematics - currentPosition

Post by robin_rob96 »

Hi,

I want to control my robot using the calculateInverseKinematics function. Since I want to start from my resting position (defined as list with length of DoF), i would like to set this resting position as "starting position" in calculateInverseKinematics.

As the PyBullet Quickstart states ,"currentPosition" should be what I'm interested for.

But:

Code: Select all

 jointPoses = p.calculateInverseKinematics(
        bodyIndex=robot, 
        endEffectorLinkIndex=gripper_center_point,  
        targetPosition=pos, 
        targetOrientation=p.getQuaternionFromEuler(orn), 
        # jointDamping=jd,
        currentPosition=rest_pose,
    )
gives me following output after the termination:
Traceback (most recent call last):
File "C:\Users\Robin\dev\pybullet\pybullet_wsg50_implementation\ur_10_with_gripper2.py", line 142, in <module>
jointPoses = p.calculateInverseKinematics(
TypeError: 'currentPosition' is an invalid keyword argument for this function
What is the correct name for this arg then?

Thanks!
ynm13
Posts: 1
Joined: Sat Jul 24, 2021 6:32 pm

Re: calculateInverseKinematics - currentPosition

Post by ynm13 »

i faced the same problem...
Post Reply