Joint->GetVelocity() returns 0 while there is movement
Hi there,
I have a simple car model, which has steering joints and wheel joints.
So the problem is, I simply try to make the car move straight by setting steering angle to zero with Steering_Joints->SetPosition(0, 0). Then I apply force either to joints, or simply to chassis to make the car move, so it moves.
Then, while moving, for the wheel joints I print the following: joint->GetVelocity(0), but for the front wheels, which has steering joints that had already been set to be 0, I get 0 although they move as the rear wheels do.
If I do not set steering joints to 0, then I observe the non-zero velocity from each of wheel joints but this is not what we want because we have to control the steering joint angle.
Is this a bug? I think this should be fixed, this does not seem very realistic for a physics simulator.
Thanks for the time!
Asked by Canberk Demirsoy on 2018-12-06 09:15:35 UTC
Comments
Can you post your SDF model along with the code you are using and step to reproduce what you are seeing?
Asked by nkoenig on 2018-12-06 11:01:08 UTC