From 16adaf12db865d71ef08bed557dbfe0147f55ea5 Mon Sep 17 00:00:00 2001 From: Jason Short Date: Wed, 18 Jul 2012 22:45:31 -0700 Subject: [PATCH] Arducopter increased landing authority --- ArduCopter/commands_logic.pde | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/ArduCopter/commands_logic.pde b/ArduCopter/commands_logic.pde index 79862bf05d..05117a0d50 100644 --- a/ArduCopter/commands_logic.pde +++ b/ArduCopter/commands_logic.pde @@ -383,15 +383,8 @@ static bool verify_land_sonar() } if(current_loc.alt < 150 ){ - //rapid throttle reduction - //int16_t lb = (1.75 * icount * icount) - (7.2 * icount); - //icount++; - //lb = constrain(lb, 0, 180); - //landing_boost += lb; - //Serial.printf("%0.0f, %d, %d, %d\n", icount, current_loc.alt, landing_boost, lb); - // if we are low or don't seem to be decending much, increment ground detector - if(current_loc.alt < 40 || abs(climb_rate) < 20) { + if(current_loc.alt < 80 || abs(climb_rate) < 20) { landing_boost++; // reduce the throttle at twice the normal rate if(ground_detector < 30) { @@ -420,12 +413,12 @@ static bool verify_land_baro() landing_boost = min(landing_boost, 40); } - if(current_loc.alt < 200 ){ + if(current_loc.alt < 100 ){ wp_control = NO_NAV_MODE; } - if(current_loc.alt < 150 ){ - if(abs(climb_rate) < 20) { + if(current_loc.alt < 200 ){ + if(abs(climb_rate) < 40) { landing_boost++; if(ground_detector < 30) {