Improve baro altitude estimation with accelerometer and Kalman filter

Hello!
This is one of the first projects I've to realize with Arduino.
I've got a BMP085, MMA7361L 3-axis accelerometer and an Arduino UNO.
I have to fuse the data of baro and accelerometer in order to improve the altitude estimation but I've not yet understood how to fuse the dynamic acceleration with the altitude. I've red that Kalman filtering is used to fuse sensors data but I've not found pratic examples.

Could anyone help me?

P.s.: sorry for the bad English.

The accelerometer and Kalman filter can be use to sense aTTiude. I have no idea how an accelerometer can help to estimate aLTitude.

I don't know how you'd implement it, but this is theoretically possible. This is complicated by the fact that your craft turning, speeding up, and slowing down are also sensed by the accelerometers. Simply ignoring two axes and directly reading only the vertical axis is an option only if your craft is traveling straight and level at a steady speed. If you want to sense altitude, it then becomes a matter of using your gyroscopes/magnetometers to determine your attitude with respect to the Earth's surface. Once you know which way is "down" (Z-axis), you can subtract acceleration measured in the X and Y axes and what's left over should be 1G if you are neither descending nor climbing. Less than 1G would indicate descent (or more properly, accelerating towards earth), and more than 1G would indicate a climb (accelerating away from earth).

Unfortunately, gyros drift, which means you lose track of which direction the earth is. This can be solved with:

http://gentlenav.googlecode.com/files/RollPitchDriftCompensationRv3.pdf

Once you've got a solid lock on which way "down is", to actually subtract the X and Y axes accelerations involves some serious math, which is beyond me. Here are a link to get you started:

http://gentlenav.googlecode.com/files/DCMDraft2.pdf