Added check for serial RX being unidirectional for sharing with telemetry.

This commit is contained in:
mikeller 2018-01-10 20:54:35 +13:00
parent 4258651b3a
commit 015f27e122
1 changed files with 10 additions and 1 deletions

View File

@ -123,7 +123,16 @@ bool telemetryDetermineEnabledState(portSharing_e portSharing)
bool telemetryCheckRxPortShared(const serialPortConfig_t *portConfig)
{
if (portConfig->functionMask & FUNCTION_RX_SERIAL && portConfig->functionMask & TELEMETRY_SHAREABLE_PORT_FUNCTIONS_MASK) {
if (portConfig->functionMask & FUNCTION_RX_SERIAL && portConfig->functionMask & TELEMETRY_SHAREABLE_PORT_FUNCTIONS_MASK &&
(rxConfig()->serialrx_provider == SERIALRX_SPEKTRUM1024 ||
rxConfig()->serialrx_provider == SERIALRX_SPEKTRUM2048 ||
rxConfig()->serialrx_provider == SERIALRX_SBUS ||
rxConfig()->serialrx_provider == SERIALRX_SUMD ||
rxConfig()->serialrx_provider == SERIALRX_SUMH ||
rxConfig()->serialrx_provider == SERIALRX_XBUS_MODE_B ||
rxConfig()->serialrx_provider == SERIALRX_XBUS_MODE_B_RJ01 ||
rxConfig()->serialrx_provider == SERIALRX_IBUS)) {
return true;
}
#ifdef USE_TELEMETRY_IBUS