Have a 2.9.1 quadcopter which flies really well in stabilize mode but when I attempt to use Loiter or RTL, it takes off at maximum climb. It's easily recoverable by switching back in to stabilize mode again but don't know whats wrong. Also, when it takes off, the first few metres seems to read the altitude correctly (sonar maybe?) but as soon as it gains some height the altitude soon goes negative. The altitude seems to be correct, but negative values. I am new to RC in general but I am thinking the neg altitude issue may be related to the loiter/RTL problem?
I do have sonar fitted which I have tested in the CLI and it is working but I have tried with the sonar on and with it off and makes no difference to the behavior in loiter/RTL mode.
You made a good point Richard. If the altitude control is using vertical accelerometer (zAcc) (and I think it is) in conjunction with the baro sensor, it may explain why people are so concerned about vibration. Accelerometers are very sensitive to vibration as far as I know.
I think you got it...
This problem happens to me as well. The baro shows negative values. The reason behind is vibration as pointed out earlier. The ardu uses Accelerometer z-axis (up/down) values in conjunction to sonar (<11m, if enabled) and barometric for altitude hold.
Please have a look at the sonar/baro logged data (on ground both are similar while flying due to vibration, baro shows negative values)
Another reason sometime of baro erratic behavior is: the temperature fluctuation and wind pressure changes (proper covering is recommended, plz have a look at this: http://diydrones.com/profiles/blogs/protecting-apm2-5-baro-sensor)
One my autopilot APM 2.5 has the same negative altitude and I am sure it is not vibrations, because the autopilot is sitting on the bench in my lab and directly connected to my laptop. the indicated altitude vary from -60 cm to - 80 cm to 0cm then to + 20cm then back to - xx cm quite randomly. see my first report on page 2.