Alttitude dirift problem in copter v3.5

nealjing,
That log is mostly empty so you may not have grabbed the correct one.
It’s most likely to be vibration levels.
http://ardupilot.org/copter/docs/common-measuring-vibration.html#common-measuring-vibration
http://ardupilot.org/copter/docs/common-vibration-damping.html

Could you,please explain what happened at about 10:30 in this case:

Log is here: https://1drv.ms/u/s!AieROjktQIZ3jkhI6yJyeS6hD6Qj

About vibrations: I just figured out that LightWare Lidar on a serial input, 19200 baud may cause low-frequency (2-3 Hz) vertical vibrations of self-oscillation nature due to a latency in receiving of samples from Lidar. In this case it creates a loopback with phase shift around 180 deg. at about 2-3 Hz range, creating conditions for up-down auto-oscillations in height (z-axis). These vibrations hard to detect because they are not present while on the ground, so all my ground tests were clear but appeared only when airborne, causing random EKF switches and increase in battery load. In my case it was not possible to get rid of them using SONAR_GAIN value - vibrations existed always as long as Lidar was honored by the autopilot. Also I tried to change Altitude Hold P-value but with no joy. I was able to reduce them significantly though by using internal Lidar median filter. And switching to I2C interface allowed me to finally get rid of these oscillations. But the log above supposed to be “clean”. At least I couldn’t find any correlations between vibrations and altitude shift.

1 Like

Really… ok, that’s very interesting. We’ve never tested the latency of the serial interface… I will add that to my list to look at.

Thanks for the update.

You know, I just had a thought that maybe there is potentially additional contributing factor: I use DJI E310 “propulsion system” with its “active braking” technique: http://wiki.dji.com/en/index.php/E310#ACTIVE_BRAKING. Which potentially could make the auto-oscillation effect more prominent by reducing vehicle response time to altitude change.

Arif,
It’s possible but many ESCs have active breaking and it’s generally a good thing to have. It means the motors/ESCs try harder to slow down the propellers which results in better control.

1 Like

Yeah, I know that, just mentioned this as a possible contributor to the problem I’ve described, for you to have the full picture.

We are using the Lightware Lidar connected via serial.
Should we be looking for this problem in 3.5rc8 or has it been resolved?

As it was in my case: look at the RCOUT log - if the log looks like a “hair” of constant “corrections” in the motor outputs, unlike when the Lidar disconnected, this is the one. Also, you might look at the Current consumption log, it will have a lot of “hair” like spikes as well. In my case, turning Lidar on caused increase in power consumption (and decrease in flight time) of about 20%…

Hi,mackkay9,Thanks to your answer。Can you tell me how to turn the origin altitude drift off? The current_loc.alt displayed on the controller drift along with origin altitude。It took me several days to solve the problem。Thank you very much。

Thank you very much ,mackkay9,I have found Paul’s commit about origin height drift.
Best Wishes!!