mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 14:25:20 +03:00
Avoid updating in-flight adjustments when not receiving rx data.
This commit is contained in:
parent
26f2affd88
commit
53eec05809
1 changed files with 6 additions and 0 deletions
|
@ -588,6 +588,9 @@ void processRcAdjustments(controlRateConfig_t *controlRateConfig, rxConfig_t *rx
|
|||
uint8_t adjustmentIndex;
|
||||
uint32_t now = millis();
|
||||
|
||||
bool canUseRxData = rxIsReceivingSignal();
|
||||
|
||||
|
||||
for (adjustmentIndex = 0; adjustmentIndex < MAX_SIMULTANEOUS_ADJUSTMENT_COUNT; adjustmentIndex++) {
|
||||
adjustmentState_t *adjustmentState = &adjustmentStates[adjustmentIndex];
|
||||
|
||||
|
@ -607,6 +610,9 @@ void processRcAdjustments(controlRateConfig_t *controlRateConfig, rxConfig_t *rx
|
|||
MARK_ADJUSTMENT_FUNCTION_AS_READY(adjustmentIndex);
|
||||
}
|
||||
|
||||
if (!canUseRxData) {
|
||||
continue;
|
||||
}
|
||||
|
||||
uint8_t channelIndex = NON_AUX_CHANNEL_COUNT + adjustmentState->auxChannelIndex;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue