Autopilot Mayday!

 

So after a few flights of the APM just acting weird in general (fighting me while on stabilize, random tip stalls/dives, flying inverted randomly, etc) I finally recorded the telemetry screen while it was in flight (I was flying LOS as it was about to crash at any moment) and I noticed that the head's up display is showing a seriously wrong horizon, even the opposite at times.

 

I have a second APM that I'm going to try in the air while I try to fix this one. Anyone seen this before/have a solution?

See you Saturday,

-Trent

TLOG: (I think this is it, I'm having trouble with my graphing function on the APM, so I couldn't verify)

2012-09-17%2007-41-50.tlog

E-mail me when people leave their comments –

You need to be a member of diydrones to add comments!

Join diydrones

Comments

  • I am new to ArduPilot but I have had to sudden crashes fortunatly the copter was close to the ground so damage was limited .

    On the first occaision it flipped backwards and I checked everything out but rememered reading somehere that the board should be cased or at least have tissue taped over the baro sensor . I went for the tissue option and the next flight was OK But flying again and experimenting with Althold it dropped violently left  fortunatly onto grass and low so damage limited .

    From what is posted here it looks like wind on the sensor it was gusty and the crash happened as I flew out of some sheilding provided by trees behind me .So how sholud I sheild my Ardupilot Mega V2.5?

     

  • Hi Trent, hey as always I enjoy your adventures and love your enthusiasm but I have to say again, please stop flying next to that freeway. If you came down on the freeway and caused an accident, you might injure someone and besides getting into lots of trouble, you would feel terrible about it. You're bright, energetic guy and I would hate to see an accident like that diminish your future. Why take the risk... You might think it will never happen but hey, that's why they call it an accident. Please seriously consider finding a new test site.

    Kind regards, Mark

  • Tridge: You are the man. Seriously, an amazing analysis. Quick response:

     

    1. Nothing really changed on the airframe, not enough to change the airflow to that degree inside the fuselage

    2. Voltage might be effected as the motor was freeking out, might have bad magnets/etc and was just acting poorly all around because of the intense prolonged vibrations of an unbalanced prop. 

    3. I have no idea about the GPS location...

     

    I should also mention that after the flight I noticed that the APM was no longer secure (2 of the bolts had fallen off due to intense vibrations) so it could have been flopping around really bad.

     

    And the big update: I flew it again this morning, with a new motor and prop, and had zero issues. It flew just fine. I'll edit the video and publish it on my normal video this saturday, and will post the tlog as well.

     

    Thank you again!!!

  • Developer

    Hi Trent,

    Thanks for posting the tlog. The issue that caused the crazy attitude solution is indeed your barometer. I suspect that something changed in the airframe (perhaps a hatch coming loose?) to suddenly allow the wind pressure on the barometer to change a lot. Here is the key graph:

    3692508990?profile=originalthat shows the pressure suddenly spiked higher, indicating a higher altitude, but the GPS altitude didn't change. If we now plot VFR_HUD.climb (which is the first derivative of the altitude) we see this:

    3692509040?profile=originalas you can see, the climb rate suddenly went to -20 m/s, while the GPS altitude didn't change.

    You may wonder why this affects the attitude (and the roll estimate). This graph shows why:

    3692508878?profile=originalthat graph shows a momentary vertical acceleration of -1145 m/s/s. That is 100 gravities, and obviously your plane did not experience 100 gravities of acceleration. The code doesn't actually use that number directly, it goes through various bits of smoothing and other processing, but the basic problem is very clear. The DCM code used the apparent vertical acceleration from the barometer to correct the accelerometer readings, resulting in the z acceleration coming out negative, which was interpreted as the plane being upside down.

    I've had one other report of very bad barometer based acceleration error like this, and I think that I will change the code to avoid it. In the latest release you can already disable it by setting AHRS_BARO_USE to zero, but I think I will limit the impact of vertical accel from the barometer a lot more, or possibly disable it by default.

    Meanwhile, you should see if you can work out why your barometer suddenly got such crazy pressure readings. See if perhaps some wind got into the fuselage. If you want to fly again soon, then update to 2.63 and set AHRS_BARO_USE to 0. I'll do a release soon which changes how the barometer is used for acceleration correction.

    Another possibility that can cause bad sensor readings is a voltage change. Here is a graph of your APM CPU voltage against at the time of the bad altitude:

    3692509061?profile=originalthat shows the voltage is varying by a small amount (0.15V or so), which is not enough to explain a bad sensor reading.

    The other really puzzling thing in your log is the GPS altitude when you land. Here is your barometric versus GPS altitude:

    3692508900?profile=originalthat is really bizarre. It is clear that you landed at 22:49 (in my timezone in Australia!) but your GPS was still reading 100 meters off the ground. Then the GPS altitude slowly drops until it comes to a reasonable level at 22:55. The logs show you had between 10 and 12 satellites visible during this time, so it should have had a good altitude fix. So why did your GPS have such a poor altitude reading? A GPS altitude is often off by 20 meters or so, but 100m is getting silly. What type of GPS do you have?

    Cheers, Tridge

  • Iwoud like to know what system are you using i mean, the parts of the FPV thanks

  • Developer

    Hi Trent,

    With the current APM code I think it is very unlikely that vibration could cause a large enough attitude error for it to show inverted when it isn't.

    If you want a guess without looking at a tlog, the most likely cause would be wind over the barometer causing lots of noise in the vertical acceleration estimate. A tlog would tell us if that is correct.

    Cheers, Tridge

  • Veikko: I've not gotten the chance to test its range maximum yet (I'm wanting a good 20 - 30 flights without any errors before I'm willing to test it to it's limits).

     

    R_Lefebvre: Thats a good idea, maybe add some rubber mounts or something just to dampen it... and add rubber o-rings to the motor mount? Might help reduce vibs throughout the set up... balance the prop of course : )  Its a 1,800kv motor running at 11v so, 19,800 RPMs at maximum? Did I do that right? (1,800 x 11). I'll test another motor & prop too, maybe this one has had it :)

  • Trent, I should have mentioned, I did have some rudimentary vibration damping on the APM in my airplane.  It still shook, but it worked.  I think the RPM is ~10,000 IIRC?  It's been a long time....  I couldn't even guess what your electric motor is turning.

    Check the motor bearings.  Whenever I get a bad "leans" in my helicopter, it's been bearings that are going out.

    I can't understand how "leans" could possibly invert the AHRS however.  That just doens't make sense.  I wouldn't think it could go much past 45°, and certainly that's the worst I've ever seen.

  • I'm sorry, I'm trying to figure out how to post the logs? I don't see a button to upload a file from my hard drive...

  • R_Lefebvre: Sounds exactly what I'm seeing (leans). Bad enough to flip it over? Crazy... Using a standard 2 blade 8x6 prop. Glad to hear your big motor didn't mess it up. Which would be a higher RPM do you think? A standard Gas or Electric motor?

     

    Hein: Thank you for your help! I may look at interfearance as well as moisture, only time will tell as I continue using it.

     

    Veikko: I have it totally standard. Took it out of the box and flew it! :)

     

    Tridge: Posting soon... Reason I didn't post this time is that I swear the tlog chart tool on the last 2 or 3 planners doesn't work for me anymore... even on old logs. I'll post it and see if you can see anything. Thanks!

This reply was deleted.