Go Down

### Topic: Altitude estimation from barometer and accelerometer , fusion algoritm (Read 10930 times)previous topic - next topic

#### nagarkar

#15
##### Jul 29, 2017, 06:32 pm
I have a working Kalman Filter for altitude estimation from barometer and accelerometer data. It also estimates z axis acceleration bias.

At the moment, I'm using the LPS25HB barometer from ST, and over short time durations (< 5 minutes), it gives accuracy of around 100 mm (0.1 meters). Over longer durations, atmospheric pressure changes causes drift in the nominal value.

Has anyone been able to get better accuracy than that?

#### Southpark

#16
##### Jul 30, 2017, 01:28 amLast Edit: Jul 30, 2017, 01:29 am by Southpark
The barometer alone, won't serve much as that is very unreliable and prone to a wide range of ambient disturbances or measurm. errors. TO make a decent altitude hold I need and want something more robust, which the barometer alone cannot give me.
The options appear limited obviously. Can only do so much. Eg..... the best we can do is to consider all the feasible option..... like, barometer, gps, accelerometer...... and maybe that's about it. If that's all we have, then that's the best we can do.

#### Southpark

#17
##### Jul 30, 2017, 01:42 amLast Edit: Aug 01, 2017, 03:27 pm by Southpark
Extensive writeup:

I took a lot of math in college but not enough to grasp all of this.
I think the only reason why most people don't grasp it - is because there appears to be never one source of information that 'fully' guides everybody from beginning to end.....with step-by-step examples of collecting various measurement data, collecting background noise data, then calculating covariance matrices from the data sets, then choosing starting values (starting estimates), and using the formulae and the obtained matrices/data to compute things like a projected/future values (such as 0.001 second ahead) using a 'kalman gain matrix'. A lot of sources explain the various matrix equations in wishy-washy ways as well. Can't blame people for not understanding it. There are at least a few internet sources, where the authors do provide enough detail to get people into the subject. But usually, it's either necessary to gather a whole bunch of sources together and figure it all out (including all the statistic mathematical manipulations/derivations) yourself, or ask somebody that already understands the area very well (to iron out uncertainties or questions).

The word 'fusion' used in kalman discussions is kind of wishy-washy in itself. But I guess they have to give a word for it heheh. I prefer to just call it information combining, or estimation based on gathering of information (with statistical considerations).

Also..... one more thing..... the equation at the top of page 14 at this link here ...

has three vertical lines in the expression, plus three dots.

I think it means ... n = the number of states = 3, and the vertical lines are just separators for sub-matrices in-between, to be stitched together. And the pattern is:

{(Phi_T)^0}H_T {(Phi_T)^1}H_T {(Phi_T)^2}H_T

We stop at (Phi_T)^2 because that term represents (Phi_T)^(n-1) where n = 3

The "..." just means : keep building up the power of Phi_T until we get to a power index of n-1.

Update: I know what's going on now. The matrix is meant to be the 'observability matrix', so it involves the output matrix C... or in this case 'H', and also involves the state transition matrix A... in this case 'Phi_T'.

#### MarkT

#18
##### Jul 30, 2017, 04:28 amLast Edit: Jul 30, 2017, 04:29 am by MarkT
I have a barometer that give me the altitude estimation but this is not enought because barometer have some drift and the sample rate is not enought fast for have a good stabilization so i thought to fuse the accelerometer z axis with the barometer datas for have a clean and fast altitude estimation.
Firstly the accelerometer can do nothing at all about barometer drift, you need good GPS data to do that.
(Or good weather forecast!)

The Accelerometer can fill in the short term changes, with the barometer correcting for the accelerometer drift
(which rapidly gets unmanagably, but most barometers sample 1 or more times a second which should be enough I think).

For flight in practice an accelerometer alone won't do, you need a 6DoF IMU to get attitude-corrected accelerometer.  It would work in a lift mechanism where the z-axis is accurately aligned at all times, but
not for a drone.
[ I will NOT respond to personal messages, I WILL delete them, use the forum please ]

Go Up