mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-15 12:25:20 +03:00
Merge pull request #6997 from mikeller/fix_fport_conditionals
Fixed build errors when building with USE_SERIALRX_FPORT but without USE_SERIALRX_SBUS or USE_TELEMETRY_SMARTPORT.
This commit is contained in:
commit
b0705caf6a
3 changed files with 9 additions and 4 deletions
|
@ -254,15 +254,16 @@ static bool checkChecksum(uint8_t *data, uint8_t length)
|
|||
|
||||
static uint8_t fportFrameStatus(rxRuntimeConfig_t *rxRuntimeConfig)
|
||||
{
|
||||
static bool hasTelemetryRequest = false;
|
||||
|
||||
#ifdef USE_TELEMETRY_SMARTPORT
|
||||
static smartPortPayload_t payloadBuffer;
|
||||
static bool rxDrivenFrameRate = false;
|
||||
static uint8_t consecutiveTelemetryFrameCount = 0;
|
||||
#endif
|
||||
static bool hasTelemetryRequest = false;
|
||||
|
||||
uint8_t result = RX_FRAME_PENDING;
|
||||
|
||||
static bool rxDrivenFrameRate = false;
|
||||
static uint8_t consecutiveTelemetryFrameCount = 0;
|
||||
|
||||
if (rxBufferReadIndex != rxBufferWriteIndex) {
|
||||
uint8_t bufferLength = rxBuffer[rxBufferReadIndex].length;
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
#include "platform.h"
|
||||
|
||||
#ifdef USE_SERIALRX_SBUS
|
||||
#ifdef USE_SBUS_CHANNELS
|
||||
|
||||
#include "common/utils.h"
|
||||
|
||||
|
|
|
@ -116,6 +116,10 @@
|
|||
#undef USE_TELEMETRY_SRXL
|
||||
#endif
|
||||
|
||||
#if defined(USE_SERIALRX_SBUS) || defined(USE_SERIALRX_FPORT)
|
||||
#define USE_SBUS_CHANNELS
|
||||
#endif
|
||||
|
||||
#if !defined(USE_TELEMETRY_SMARTPORT) && !defined(USE_TELEMETRY_CRSF)
|
||||
#undef USE_MSP_OVER_TELEMETRY
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue