1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-25 17:25:18 +03:00

[NAV] Allow using GPS altitude instead of barometer

This commit is contained in:
Konstantin (DigitalEntity) Sharlaimov 2020-06-24 11:48:21 +02:00
parent a41a4de247
commit 8611b37563
4 changed files with 9 additions and 3 deletions

View file

@ -189,7 +189,7 @@ void initActiveBoxIds(void)
activeBoxIds[activeBoxIdCount++] = BOXCAMSTAB;
#ifdef USE_GPS
if (STATE(ALTITUDE_CONTROL) && (sensors(SENSOR_BARO) || (STATE(AIRPLANE) && feature(FEATURE_GPS)))) {
if (STATE(ALTITUDE_CONTROL) && (sensors(SENSOR_BARO) || (feature(FEATURE_GPS) && (STATE(AIRPLANE) || positionEstimationConfig()->use_gps_no_baro)))) {
activeBoxIds[activeBoxIdCount++] = BOXNAVALTHOLD;
activeBoxIds[activeBoxIdCount++] = BOXSURFACE;
}