Page 1 of 1

Control Algorithim Origins

PostPosted: Thu Jul 15, 2010 8:27 pm
by Michael
Hi Tom,

I was curious if you could tell me any more specific information on the papers you used to write your quaternion and kalman code. You reference that they came from Mahony and Beard, but that hasn't helped much since those guys have written sooo many papers.

Currently I'm testing a quaternion algorithim from Madgwick titled "A efficient orientation filter for IMUs and MARG sensor arrays", and I'm mostly happy with it's implementation, but I've noticed that it has a tendancies to get it's direction vector flipped when in the up-side-down condition too long, so I'm wondering what other people have done to get around this or if I'm just being too nitpicky.

By the way, Thanks, your work has been a big inspiration for me!

Re: Control Algorithim Origins

PostPosted: Sun Jul 18, 2010 5:28 pm
by Tom
Hi Michael,

Attached you can find the paper I refer to.

The quaternion method is very straightforward, the dynamics are substracted from the accelerometers, and the gyro drift is estimated with a PID controller.

Best regards,

Tom

Re: Control Algorithim Origins

PostPosted: Fri Sep 24, 2010 7:02 pm
by nyd
When you say "the dynamics are substracted from the accelerometers". Are you referring to the dynamics of the quaternion?

I was wondering how to solve the dynamics of the quaternions using the acc data, but i still haven't found any conclusive doc regarding this subject.

Have you achieves this?

Thanks for your answer.

Regards.

Re: Control Algorithim Origins

PostPosted: Fri Sep 24, 2010 7:08 pm
by Tom
No, I'm referring the other accelerations except the earth's gravity (e.g. centripetal acceleration).
You don't need to substract them from the quaternions, but from the accelerometers:

Code: Select all
/*simplified:*/
// calculate the gravity-component from the accelerometers by substracting the dynamics
double g_ax = sensor_data.acc_x - sensor_data.q * w / G;
double g_ay = sensor_data.acc_y - (sensor_data.r * u - sensor_data.p * w) / G;
double g_az = sensor_data.acc_z + (sensor_data.q * u / G);