Plane: fix a relative altitude check for glide slope building

This commit is contained in:
Michael du Breuil 2015-04-12 22:17:41 -07:00
parent 4b1d71e390
commit 867ca05e17

View File

@ -87,7 +87,7 @@ static void setup_glide_slope(void)
// is basically to prevent situations where we try to slowly
// gain height at low altitudes, potentially hitting
// obstacles.
if (relative_altitude() > 20 || above_location_current(next_WP_loc)) {
if (adjusted_relative_altitude_cm() > 2000 || above_location_current(next_WP_loc)) {
set_offset_altitude_location(next_WP_loc);
} else {
reset_offset_altitude();