TECS: set _ratio_underspeed to 0 if airspeed disabled

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
This commit is contained in:
Silvan Fuhrer 2023-12-07 10:44:50 +01:00
parent 634ad3893e
commit 740bf63fa7
1 changed files with 1 additions and 1 deletions

View File

@ -353,7 +353,7 @@ TECSControl::SpecificEnergyRates TECSControl::_calcSpecificEnergyRates(const Alt
void TECSControl::_detectUnderspeed(const Input &input, const Param &param, const Flag &flag)
{
if (!flag.detect_underspeed_enabled) {
if (!flag.detect_underspeed_enabled || !flag.airspeed_enabled) {
_ratio_undersped = 0.0f;
return;
}