[Opensim-dev] Springs, Torques, joints , friction, questions and Vehicles oh my

Charles Krinke cfk at pacbell.net
Wed Apr 15 17:49:46 UTC 2009


Jeff Heaton at "Heaton Research" wrote a book on LSL scripting. All his scripts are available at his "Heaton Research" parcel on SecondLife and in the books, which are on Amazon.com.

There are a couple of chapters devoted to vehicles and angular motors in making a script for a car, boat & airplane.

It might be that using Jeff's examples might get us further along the vehicle physics curve?

Charles




________________________________
From: Dahlia Trimble <dahliatrimble at gmail.com>
To: opensim-dev at lists.berlios.de
Sent: Wednesday, April 15, 2009 10:21:45 AM
Subject: Re: [Opensim-dev] Springs, Torques, joints , friction, questions and  Vehicles oh my

Unfortunately I lack experience using the LSL vehicle API, and I've also had little success finding good example scripts which were written for the Havok 4 implementation which is currently in use in SL. Most of the scripts I found were quite simple and written for Havok 1, and unfortunately do not work well with H4. I've also had little success finding anyone with extensive experience using these apis who would be willing to share code and insight. :(

I'm not aware that jointed vehicles are currently implemented in SL so I wouldn't think that a comparable API written for ODE or Bullet would need to include recursive methods for joints if compatibility with the current LSL implementation were desired. Then again, providing access may inspire some interesting vehicles but could they be displayed with the LL viewer? Perhaps as separate physical prims, or as linksets where the translations of the individual prims which make up wheels and axles could be manipulated to simulate joints?

Other potential issues might be understanding the effects of each of the parameters and their interactions. i.e., does changing buoyancy affect hover efficiency? which takes precedence? Are there any scripts which use these parameters properly which might be ported over and would be affected?

Perhaps an alternative during development might be to have temporary names for the methods and parameters which are different than the LSL names, then once the necessary characterizations have been completed and the mappings and interactions are implemented and deemed sufficient, the names could be changed to the equivalent LSL names.



On Wed, Apr 15, 2009 at 9:42 AM, Teravus Ovares <teravus at gmail.com> wrote:

Greetings all

I was hoping to get some robot physics simulation people's ideas here.

Looking at the LSL Vehicle API, it seems clear that there is at least
an angular motor and a linear motor involved.   There may be two
angular motors, one for the angular movement and one for the vertical
attractor(which may just be a jacobian constraint).  In ODE, angular
motors are implemented as springs.    Sometimes this can cause
instability and vibration.     The truth is, using ODE's angular motor
may or may not be the best solution.   There are others.   For
example, on the ODE-users list currently they're talking about
applying torques directly using the Recursive Newton-Euler
formulation.

"
desired joint velocities and accelerations (qp and qpp respectively),
then the joint torques can be calculated with:

tau = M(q) * qpp + V(q,qp) + G(q) + F(qp)

where M(q) is your inertia matrix and V(q,qp) is a vector of the
coriolis forces, G(q) is a vector of the gravity forces and F(qp) is a
vector of fiction forces.
"

Recursive Newton-Euler formulation
http://www.cours.polymtl.ca/roboop/docs/node146.html

A list of some constants in the LSL Vehicle API:

ANGULAR_DEFLECTION_EFFICIENCY
ANGULAR_DEFLECTION_TIMESCALE
ANGULAR_FRICTION_TIMESCALE
ANGULAR_MOTOR_DECAY_TIMESCALE
ANGULAR_MOTOR_DIRECTION
ANGULAR_MOTOR_TIMESCALE
BANKING_EFFICIENCY
BANKING_MIX
BANKING_TIMESCALE
BUOYANCY
HOVER_EFFICIENCY
HOVER_HEIGHT
HOVER_TIMESCALE
LINEAR_DEFLECTION_EFFICIENCY
LINEAR_DEFLECTION_TIMESCALE
LINEAR_FRICTION_TIMESCALE
LINEAR_MOTOR_DECAY_TIMESCALE
LINEAR_MOTOR_DIRECTION
LINEAR_MOTOR_OFFSET
LINEAR_MOTOR_TIMESCALE
VERTICAL_ATTRACTION_EFFICIENCY
VERTICAL_ATTRACTION_TIMESCALE

Thoughts and patches appreciated.

You'll find a mostly logically complete ODEVehicleSettings.cs in
OpenSim.Region.Physics.OdePlugin.ODEVehicleSettings.cs that contains
all of the constants as well as methods that are plugged in to the
physics plugin, but don't take any action in the physics engine yet.
This was created to organize vehicle API development.

Best Regards

Teravus
_______________________________________________
Opensim-dev mailing list
Opensim-dev at lists.berlios.de
https://lists.berlios.de/mailman/listinfo/opensim-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://opensimulator.org/pipermail/opensim-dev/attachments/20090415/53182109/attachment-0001.html>


More information about the Opensim-dev mailing list