A couple of us here in Brisbane, Australia have been trying to get our ArduPilotMega to fly our "test" aircraft, in preparation for implanting the elctronics into something bigger for UAV and/or FPV.
Our problem at present manifests itself in the air. All the ground tests of control surfaces (in Manual and Stabilize modes) etc seem to be OK.
Symptom: when we switch from manual flight to "stabilize" flight, the aircraft uncontrollably pitches itself *hard* and suddenly in an arbitrary direction. ( more often up and to the left, but sometimes down ).
I've been ( nievely ) trolling through the logs and google earth output of few flights we had recently, and from what I can tell, the plane looses it's orientation. On the ground, and during the first few seconds of flight the google earth "attitude" plane model seems to be generally pointing the right way, but within moments it's drifted away from the reality of where the model plane really was, and the simulated position of the 3D model in google earth shows that it thinks the plane is oriented totally off. sometimes nozeup, sometimes completely upside down. ?
Attached is a google earth screen capture showing the first seconds after take off on one of the flights, where it started off with the correct orientation, and then internally, the sensors clearly though the aircraft had pitched nose-up in the air, but it was actually banking nicely to the right while climbing ( which the positioning and altitude data show correctly.
P.S. here is link to video from this flight too. ( both onboard, and from the ground ). i don't know if it helps any more than the logs do though?
We went out flying again today. I put the stable 2.23 firmware in and unplugged the GPS and magnetometer. During ground testing we observed that the control surfaces exhibited crazyness after throttling the motor up and wildly waving the plane around, then holding it flat and level again. We removed the IMU portion of the APM and noted that one of the SMT caps had come off the board. We replaced it with a fresh IMU from Buzz's quadcopter, and attached a supported GPS module; still no magnetometer.
It flew beautifully in stabilise. The manual control in stabilise mode was a bit "sawtoothy" but functional. We flattened one battery and put a fresh one in. With no configuration changes (besides a bit of trim on the TX) we found that the plane would tend upwards or downwards, more often downwards, in stabilise mode. This was possibly due to bad initialisation, or the trimming playing silly-buggers with it.
Buzz should be along shortly with video. I'll upload the logs later tonight.
Are you sure APM board is facing in the right direction? Are you using a magnetometer, and if so is it soldering on in the correct orientation?
A properly setup board should be pretty foolproof: even if it's not tuned it should stabilize anything, right out of the box. Your experience is either a setup error, or, if the above check out, another possibility could be a faulty IMU board that fails only under vibration in the air.
There are other APM users in Brisbane who can help you, I think. If need be, we can get you another IMU board.
Thanks Toby, but to be sure, yes, we put the aircraft into stabilize mode on the ground, and pitched the plane in each of it's axis and made sure that the elevators and ailerons moved the correct way.
Please also note that by reviewing the logs, and looking at the screen capture I supplied ( of takeoff, which is in Manual mode) you can see that the problem starts to occur immediately, before we even turn the aircraft into 'Stabilize' mode.
on the ground, in stabilise mode, if you hold the plane in your hands and tilt it forward, do you see the pitch control surface tilt upwards or downwards?
now tilt the plane upwards, does the same control surface now react in the opposite way and try to force the plane downwards.
what happens to the alerons when you roll the plane side to side? do they respond in a way that counteracts the movement?
the most likely cause is one of your control surfaces reversed (or not reversed as the case may be). This can cause everything to be fine in manual mode but then stabilize mode will send your plane in the opposite direction to where the sensors think it should be going causing an uncontrollable analog feedback loop that will eventually end in a nose dive.