Hello everyone,
i'm using Gazebo to simulate a PD controller on a quadrotor UAV.
The control evalueates the force and torque to apply to the quadrotor and
then i use the methods
dBodyAddRelForce(body_id, 0, 0, thrust) and dBodyAddRelTorque(body_id,
roll_torque, pitch_torque, 0).
Now i would like to get information about position, velocity and
acceleration of the quadrotor. 
To do so, i use the methods:
body->GetPosition()
body->GetLinearVel()
body->GetLinearAccel()
and the last one appears to give practically nonsense results (gravity
acceleration depending on the mass for instance...).
Browsing into the code i found out that GetLinearAccel() simply does 
return this->GetForce() /  this->GetMass();
That is " F = m*a "  as it should be.
Anyway the controller works and the quadrotor get still on the target point,
but the acceleration i get on the z axis is positive (e.g. = 19.6) even
though the quadrotor is not varying its height.
I really have no point...please help me! :)
Thanks in advance.  

Luca


For the sake of completeness i'm using the following software version:
Gazebo - 0.9.0
Player - 2.1.3

http://old.nabble.com/file/p31215867/QuadrotorControllerPD.cc
QuadrotorControllerPD.cc 
-- 
View this message in context: 
http://old.nabble.com/Get-acceleration-from-Gazebo-%28is-it-working-%29-tp31215867p31215867.html
Sent from the playerstage-gazebo mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Xperia(TM) PLAY
It's a major breakthrough. An authentic gaming
smartphone on the nation's most reliable network.
And it wants your games.
http://p.sf.net/sfu/verizon-sfdev
_______________________________________________
Playerstage-gazebo mailing list
Playerstage-gazebo@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/playerstage-gazebo

Reply via email to