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

Merge pull request #8171 from breadoven/abo_msp_surfacemode_fix

Fix surface mode msp box availability logic
This commit is contained in:
Paweł Spychalski 2022-07-01 21:30:52 +02:00 committed by GitHub
commit 99681da2c6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -103,7 +103,7 @@ static uint8_t activeBoxIds[CHECKBOX_ITEM_COUNT];
uint8_t activeBoxIdCount = 0;
#define RESET_BOX_ID_COUNT activeBoxIdCount = 0
#define ADD_ACTIVE_BOX(box) activeBoxIds[activeBoxIdCount++] = box
#define ADD_ACTIVE_BOX(box) activeBoxIds[activeBoxIdCount++] = box
const box_t *findBoxByActiveBoxId(uint8_t activeBoxId)
{
@ -196,7 +196,7 @@ void initActiveBoxIds(void)
ADD_ACTIVE_BOX(BOXHEADFREE);
ADD_ACTIVE_BOX(BOXHEADADJ);
}
if (sensors(SENSOR_BARO) && sensors(SENSOR_RANGEFINDER) && sensors(SENSOR_OPFLOW)) {
if (sensors(SENSOR_BARO) && sensors(SENSOR_RANGEFINDER)) {
ADD_ACTIVE_BOX(BOXSURFACE);
}
ADD_ACTIVE_BOX(BOXFPVANGLEMIX);