How to obtain a floating base robot ?

Official Python bindings with a focus on reinforcement learning and robotics.
Post Reply
aled96
Posts: 5
Joined: Fri Jan 28, 2022 2:24 pm

How to obtain a floating base robot ?

Post by aled96 »

Hi, I have an urdf model in which from the base link the other joints are attached with fixed or revolute joints.

I load this model inside the code with the following line:

Code: Select all

self.robot = pybullet.loadURDF(path_to_urdf_file,  [0, 0, 0.7],  useFixedBase=0)
Now, despite the fact the useFixedBase is 0, the robot base_link is fixed with respect to the world and ground. What should I do to be able to move it freely in the space (for example via walking) ?

Thanks !
zhsh
Posts: 7
Joined: Thu Oct 11, 2018 10:48 pm

Re: How to obtain a floating base robot ?

Post by zhsh »

How you created it should allow it to move in space, such as via createConstraint, setMotorControl, or just by dragging it around in GUI mode. If that's not available, it might be that your urdf object has 0 mass, making it a static rather than dynamic object. In that case even if the base is labelled movable, the robot won't be movable.
aled96
Posts: 5
Joined: Fri Jan 28, 2022 2:24 pm

Re: How to obtain a floating base robot ?

Post by aled96 »

Thank you for the answer.
I had few links with zero mass, I changed them and now it works !
Post Reply