Hi all,
This is my first post on that forum, so first : many congratulations to those who are concerned about the development of this really amazing board ! I didn't get one at the moment, but as soon magnetometer + hotel will be available in stock, I'll do.
I had a look on the APM code, but something is not clear for me. The way the soft is fixing the yaw angle is my concern : I understood there is 2 ways for that in the code ?
- first is direct reading from magnetometer
- second is indirect fixing by GPS vector
But they are separate ways, is that true ?
I don't know if it's possible or already done so here is my question :
- with magnetomoter and pitot tube relative wind data (optional gyro + accel data for the pitch for 3D computing) you can have the real vector of the aircraft on the yaw angle,
- with the GPS you get real vector relative to the ground (optional more accuracy with the pressure sensor for the altitude)
With that informations, we can compute the real vector of the wind (optional in 3D), which is a real important information for the fly : to know if your plane is able or not to go in front of the wind (optionnal detecting thermals strength to climb more easily) ?
Perhaps it's already done, I don't know ?
What do you thing about ?
Many thanks again !
Replies
I agree with you on all that points... I hope you don't believe I'm trying to explain you how to code that board !! So I tell you again : you did an impressive work on that : no contest is possible !
What I wanted to say is :
- flying in auto mode without a pitot tube is at your own risk... Especialy if your plane is a slow speed one. When the weather is strong, even with pitot tube, it could be a good practice to detect gusty conditions and other environnemental parameters, in order to improve security parameters like the bank angle limit and others... To prevent stall, for example.
- to detect wind variations at a high frequency, a magnetometer appears to be necessary (but perhaps I should take a look at the Bill's script).
Everything is there :
" If you want to fly in winds of 10 gusting 20, again you cannot fly near the benign stall speed."
In other words, something like this :
if( MEAN_delta_wind_speed > 5 ){
target_speed += MAX_delta_wind_speed + 2;
if( target_speed > max_airplane_speed ){
Go_back_home("hurry!!")
}
}
But the impact on CPU and RAM may perhaps be dramatic...
Keep on your great work,
Regards
You are right in that we do not correct the wind in the present code. It will be a future upgrade. There are various ways that you can compute the wind. In fact you can do it without the magnetometer. Search the site for a post by Bill Premerlanni describing an algorithm he developed to compute the wind based on measuring changes in the rotation during turns. We have not decided what algorithm we will use. Perhaps we will use Bill P's as not everyone uses a magnetometer.
The core functionality of APM for fixed wing application does not really require knowing the wind. The way that we compute yaw will cause the indicated yaw to be biased to counteract the effect of a crosswind within a matter of seconds. However we do plan to add a wind calculation for doing more advanced things like your suggestions.