Kalman filter for accelerometer and gyro data fusion

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 5.
To post in this forum you must have a registered copy of Flowcode 5 or higher.

Moderator: Benj

Post Reply
User avatar
Mantas
Posts: 221
Joined: Tue May 15, 2012 10:32 pm
Location: Klaipeda, Lithuania - North sea, UK
Has thanked: 57 times
Been thanked: 27 times

Kalman filter for accelerometer and gyro data fusion

Post by Mantas »

Hello MM,

I implemented Kalman filter for accelerometer and gyro data fusion to get precise pitch and roll angles. But for this Kalman filter need time delta between two measurements, so I use timer interrupt running at 187200 Hz to increment the count and then later calculate the delta time using formula:

Code: Select all

dt = INTT/INT_FREQ; /*where INTT is the incremented count in the interrupt service routine, INT_FREQ is 187200 and dt is the float variable for delta time */
INTT = 0;
The problem is that Flowcode ARM v5.3 is limited to 6 digit precision in floating point variables, and sometimes I get very small dt smaller than 6 digit precision as the SAM7 chip is running really fast.

So my question is: when is that magical update finally coming? :D

Best regards,
Mantas
Science is my true religion.

Post Reply