From 557d704b9e0569efce149afea6b699d516bf85ab Mon Sep 17 00:00:00 2001 From: mikeller Date: Mon, 21 May 2018 15:07:36 +1200 Subject: [PATCH] Fixed RC modes PG version after GPS rescue. --- src/main/fc/rc_modes.c | 2 +- src/main/fc/rc_modes.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/fc/rc_modes.c b/src/main/fc/rc_modes.c index 42077533fa..dde865ed27 100644 --- a/src/main/fc/rc_modes.c +++ b/src/main/fc/rc_modes.c @@ -42,7 +42,7 @@ boxBitmask_t rcModeActivationMask; // one bit per mode defined in boxId_e static bool modeChangesDisabled = false; PG_REGISTER_ARRAY(modeActivationCondition_t, MAX_MODE_ACTIVATION_CONDITION_COUNT, modeActivationConditions, - PG_MODE_ACTIVATION_PROFILE, 0); + PG_MODE_ACTIVATION_PROFILE, 1); bool IS_RC_MODE_ACTIVE(boxId_e boxId) { diff --git a/src/main/fc/rc_modes.h b/src/main/fc/rc_modes.h index 78661ecd23..2a2dafeca4 100644 --- a/src/main/fc/rc_modes.h +++ b/src/main/fc/rc_modes.h @@ -43,6 +43,8 @@ typedef enum { BOXGPSRESCUE, BOXID_FLIGHTMODE_LAST = BOXGPSRESCUE, +// When new flight modes are added, the parameter group version for 'modeActivationConditions' in src/main/fc/rc_modes.c has to be incremented to ensure that the RC modes configuration is reset. + // RCMODE flags BOXANTIGRAVITY, BOXHEADADJ,