Hello,
I am working on a project to estimate the angle of attack and sideslip angle during flight. I am currently doing some tests using APM 2.0 and mission planner. The goal is to send the values of the AOA ans sideslip to mission planner and visualize them on the HUD of mission planner. They will be visualized using a small green circle that will move vertically to show the change in the angle of attack and horizontally to represent the change in slip angle.
I have modified the apm code and mission planner code to add the two new quantities. I modified the mavlink function on both sides and I can successfully read the values on mission planner. In addition, I modified the function currentstate.cs and HUD.cs to add the parameters.
The problem is that I am able to read the numerical values of the parameters but I am not able to visualize them using the green circle even though I made the circle position as a function of aoa and slipangle. The circle does not move at all but the numerical values start to change!! I suspected the problem might be in the definition of the circle, so I made the circle position as a function of roll and pitch and then the circle start to move with the angle change. I realized that the problem resides in relating the variables (aoa,sideslip) to be used within the HUD. I don't have experience with GUIs and little experience with visual studio.
Could you please tell me what are the functions that I need to modify to add these two new variables to the HUD visualizations. I have been stuck in this for 3 weeks now. I hope someone can help or direct me to blog or similar discussion.
A screenshot of the modified HUD is attached.
Thanks :)
Replies
Hi,
Try post the code that draws the green circle, and where it is placed / how it is integrated in the class that does the HUD. Maybe I or someone else can look into it. Actually it should not be necessary with the complete code with MAVLink extensions and all - debugging this could be done by just using random values and the circle should move.
I am writing a HUD similar thing (called the Primary Flight Display, even though it is not quite one) for QGroundControl. I would love to add the same feature there, and hear more about how you calculate the data.
AoA - I suppose you use pich, airspeed and vertical velocity?
Sideslip - also considered important by some (even though the aircraft is unmanned). Do you use local lateral acceleration?
Regards
Soren
I'm sorry but I cannot help you on the HUD source code mods but I would be very interested in your efforts to calculate angle of attack and sideslip. Could you please provide your equations and maybe even the APM source code? Many of us need these variables to improve autopilot performance and also just to evaluate best aircraft performance - especially 3D and gliders.
Thanks much - and I hope someone can help with the HUD. Maybe Michael O. might respond since this type of Alpha(AOA)/Beta display would be very welcome in the community
Dave