Hello PyODE list,

I posted something similar to this on the ODE list recently but  
didn't receive any responses, so I thought I'd try here (also since  
I'm using PyODE).

I have a rectangular box (mostly in the xz plane) with 4 chains in  
the +y direction, attached with ball joints on the corners of the  
box.  I want to use the chains to hold the box above the floor.  I'm  
able to do this without a problem; the box hovers above the ground  
with the chains taut and the top element of the chain within +-0.01  
or so of the desired position.  But, let's say I want to pull up one  
corner of the box by applying work to one chain.  I can do this, the  
box corner moves up, I get a new desired hold position.  But my  
holding algorithm does not hold the chain at the desired position;  
the x and z components hover within +- 0.01 of the desired position,  
but once I stop applying the additional force, the corner slips  
downward (-y), with the y position often off by -4.0 or more.

Pseudo-code for the holding algorithm (in both cases described above)  
is as follows:

currentVelocity = finalChainElement.getLinearVel()
currentPosition = finalChainElement.getPosition()
desiredPosition = holdPosition

desiredVelocity = desiredPosition - currentPosition
desiredAccel = desiredVeclocity - currentVelocity
finalChainElement.addForce(holdingMass * desiredAcel + holdingForce)

Is there something in my algorithm that seems wrong?  I've tried  
various combinations of lookahead and PID controllers to no avail.

I'm using the latest PyODE and ODE 0.8.

Thanks for any help!  This should be simple and it's been stumping me  
for a while...

nick

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Pyode-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pyode-user

Reply via email to