During a test fight I noted that the modes I had programmed in setup did not seem to operating correctly.
I have APM 2.22 installed in control board.
I had " Manual, Stability and RTL " set in the 3 position mode switch. the first 2 modes seemed to work OK but RTL was not working and appeared to be circling.
I checked the download of the flight LOG and found the mode had been changing into ' Circle ' mode on several occasions and did not show a switch to 'RTL' mode even though 'Circle' selection was never setup .
I have set the mode switch positions to exactly the correct pulse-width as specified in the manual.
What is the best way to identify what is the problem ???
I did a a setup>>erase and then loaded the new code with my custom config file.
Looking at the log, it looks like you have a pretty normal waypoint mission that goes a long time (you could tune your NAV and Crosstrack gains a bit for a smoother course, but it broadly goes where it's supposed to go), and then at the end something happens that I can't see from the logs.It might be a brown-out, which can be caused by a low voltage situation or over-current situation caused by high-drain servos on an insufficiently high-capacity ESCs.
Very unlikely to be software. It's hard to get embedded microprocessors to reboot with software bugs; they tend to lock up instead, which was obviously not the case here. If you check your onboad datalogs, you'll be able to tell if in fact the board did shut down due to a brownout/low voltage situation.
Do you know the max output of the APM board telemetry port @ 5v? 500mA? My Xtend was set to auto TX power based on voltage, and it may have been trying to transmit at 1W for most of the flight... At 1W, it sucks up 730mAh at 5v. If I can confirm that the setting is way to high (and what a reasonable limit is on the APM), then I can try this again.
I can also go with the 500mw setting, 500mA at 5v.