[ODE] "relative velocity" joint type
Patrick Enoch
Hendrix_ at gmx.net
Fri May 25 01:40:18 MST 2007
Hi Remi,
Thanks!
I was thinking of something like a relative 3d lin velocity and
angvel, but I guess I find the secret in the "motor" sources then.
Is there a how-to for motors? I found the one for joints by Russel
Smith "How to make new joints in ODE" which I found very useful.
Patrick
On 25. May 2007, at 2:28 Uhr, Remi Ricard wrote:
> Hi Patrick,
>
>> Hello all,
>> has anyone implemented a joint that makes two objects have some
>> fixed relative lin/ang velocity?
>
> If you create a joint between two bodies and set the speed of the
> joint
> then the velocity is the relative velocity of the 2 bodies.
>
>
>> Alternatively, anyone has a hint what I have to do for that?
>
> In C++ you can do
>
> dJoint *j = new dSliderJoint(worldID, 0; (or maybe dJointSlider)
>
> j->attach(bodyID1, bodyID2);
> j->setParam(dParamFMax, some_force_value);
> j->setParam(dParamVel, 10);
>
> In C it is something similar to
>
> dJointID j = dJointCreateSlider(worldID, 0);
> dJointAttach(j, bodyID0, boduID2);
> dJointSetSliderParam(dParamFMax, some_force_value);
> dJointSetSliderParam(j, dParamVel, 10);
>
>
> With this you will have a the two bodies trying to reach the
> relative velocity of 10 units with a force not exceeding
> some_force_value. The some_force_value should be large enough to
> counteract any force that try to stop the bodies from moving.
>
>
> Remi
More information about the ODE
mailing list