diff --git a/_locales/en/messages.json b/_locales/en/messages.json index b19cdd2e..03a253a5 100755 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -464,7 +464,7 @@ "RX_SERIAL": { "message": "Serial-based receiver (SPEKSAT, SBUS, SUMD)" }, - "RX_PARALLEL_PWM": { + "RX_PWM": { "message": "PWM RX input (one wire per channel)" }, "RX_MSP": { diff --git a/js/fc.js b/js/fc.js index b053f19e..4805823a 100644 --- a/js/fc.js +++ b/js/fc.js @@ -611,37 +611,35 @@ var FC = { }, { name: 'RX_PPM', - bit: 0, - value: 1, - }, - { - name: 'RX_PARALLEL_PWM', bit: 13, value: 2, }, { - name: 'RX_MSP', - bit: 14, - value: 4, + name: 'RX_PWM', + bit: 0, + value: 1, }, ]; + if (semver.gte(CONFIG.apiVersion, "1.21.0")) { - rxTypes.push( - { - name: 'RX_SPI', - bit: 25, - value: 5, - }, - ); - } - if (semver.gt(CONFIG.flightControllerVersion, "1.7.3")) { - rxTypes.push( - { - name: 'RX_NONE', - value: 0, - }, - ); + rxTypes.push({ + name: 'RX_SPI', + bit: 25, + value: 5, + }); } + + rxTypes.push({ + name: 'RX_MSP', + bit: 14, + value: 4, + }); + + rxTypes.push({ + name: 'RX_NONE', + value: 0, + }); + return rxTypes; }, isRxTypeEnabled: function(rxType) { @@ -659,8 +657,10 @@ var FC = { for (var ii = 0; ii < rxTypes.length; ii++) { BF_CONFIG.features = bit_clear(BF_CONFIG.features, rxTypes[ii].bit); } - // Set the feature for this rx type - BF_CONFIG.features = bit_set(BF_CONFIG.features, rxType.bit); + // Set the feature for this rx type (if any, RX_NONE is set by clearing all) + if (rxType.bit !== undefined) { + BF_CONFIG.features = bit_set(BF_CONFIG.features, rxType.bit); + } } }, getSerialRxTypes: function () {