[ODE] nonholonomic vehicle path following
kxubb at yahoo.com
Mon Jun 11 15:05:57 MST 2007
Found one sample code on ODE FAQ section.
How can I simulate a servo motor?
dReal Gain = 0.1;
dReal MaxForce = 100;
dReal TruePosition = dJointGetHingeAngle(joint);
dReal DesiredPosition = /* whatever */;
dReal Error = TruePosition - DesiredPosition;
dReal DesiredVelocity = -Error * Gain;
dJointSetHingeParam(joint[a], dParamFMax, MaxForce);
seems it uses motor angular velocity (dParamVel) to
achieve the motor position control.
Can I also use the same way to do steering angles
control in order to achieve desired car-body heading
I feel it has to wait for the ODE integrator to reach
my desired steering, maybe need couples of time-steps.
But my steering control sequences are given every
time-step. Or any other way we can perform such
similar angular position control?
--- "STenyaK (Bruno González)" <stenyak at gmail.com>
> On 6/11/07, Ke <kxubb at yahoo.com> wrote:
> > After tuning up the parameters like
> > velocity, our car can reach one target position w/
> > less than 5% error. But that set of parameters may
> > give us good error control for other testing
> > we need to find a good set of parameters good for
> > general cases. Looks we have to tune the control
> > parameters case by case.
> > > You should not copy the steering values from one
> > > to the other
> > > verbatim, but calculate the difference to the
> > > desired path and apply
> > > that to the car. This way you will have a
> > > self-correcting steering. I
> > > hope this is stable, which depends on how big
> > > errors are from
> > > step to step.
> Wheels will always slide a bit, so even when the
> front wheels point to
> the correct point, there will probably exist some
> understeer that will
> prevent the car from steering enough to reach the
> If that's the case, try to feed it wrong data (make
> the car think it
> has to go further to the left/right than it really
> has). Then maybe
> apply some dampening to the steering wheel, so that
> it doesn't swerve
> left-right like mad when it's actually following the
> desired path
> With some luck, that'll work for most situations,
> not needing to
> fine-tune each case. Hope it helps :)
> Msn/Jabber: stenyak AT gmail.com
> ICQ: 153709484
> Webs: http://1ksurvivor.homeip.net 1kSurvivor
> http://motorsport-sim.org Motorsport
> http://emuletutorial.info EmuleTutorial
> ODE mailing list
> ODE at ode.org
Boardwalk for $500? In 2007? Ha! Play Monopoly Here and Now (it's updated for today's economy) at Yahoo! Games.
More information about the ODE