Maybe PX4 pilot processor power could make possible to make a learning pilot. The idea would be that you put the autopilot in to the plane and fly few rounds in manual mode. After the flight the autopilot/gcs software could analyze how the plane was fying with different servo and power values in different situations and speeds etc... After the analyzing the pids could be adjusted automatically according the manual flight record values. Maybe this could be even possible with apm 2.5 if there was a gcs that could analyzing work, just by analyzing the logs.
Example: If I put the radio stick to left it takes x millisecond to make 10° change in the roll angle. And when this information is recorded the analyzing software could use this information to adjust the roll PID automatically for the current plane. It could "learn" the performance of the aircraft.
Replies
If you are not afraid of theory and mathematics:
Adaptive Control: Second Edition (Dover Books on Electrical Engineering) [Paperback]
Karl J. Astrom (Author), Dr. Bjorn Wittenmark (Author)
The book is about $17 (be sure to get the Dover Edition) and present some of the theory behind self adapting controller of auto tuning. Search for "Karl Astrom" and you will find lots of (scientific) material in this area.
Note, fixed wing flight control is primarily scheduled/ adapted (=> aerodynamic forces and moments scaler) by dynamic pressure. After that angle of attack and Mach number (if applicable) are used for adaptation. As both are not available in APM, try dynamic pressure scaling and linear (=fixed values) controller.
Have fun
This is a great idea, something like this is in development with copter control - self tuning mode.
I've got mine setup, just not had time to play yet. Their code is opensource too, but I'd struggle to make sense of it or port it. I wonder if any nice chaps from copter control development hang around there that might be able to help.