1
0
Fork 0
mirror of https://github.com/iNavFlight/inav-configurator.git synced 2025-07-15 12:25:13 +03:00

[PORTS] Add ESC and OPFLOW to serial port bit masks

This commit is contained in:
Konstantin Sharlaimov (DigitalEntity) 2019-05-11 22:04:23 +02:00
parent 8b9ed31448
commit bc95909055
3 changed files with 24 additions and 0 deletions

View file

@ -870,6 +870,12 @@
"portsFunction_RANGEFINDER": { "portsFunction_RANGEFINDER": {
"message": "Rangefinder" "message": "Rangefinder"
}, },
"portsFunction_OPFLOW": {
"message": "Optic flow"
},
"portsFunction_ESC": {
"message": "ESC output/telemetry"
},
"portsFunction_TELEMETRY_FRSKY": { "portsFunction_TELEMETRY_FRSKY": {
"message": "FrSky" "message": "FrSky"
}, },

View file

@ -45,8 +45,11 @@ var mspHelper = (function (gui) {
'RUNCAM_DEVICE_CONTROL': 10, 'RUNCAM_DEVICE_CONTROL': 10,
'TBS_SMARTAUDIO': 11, 'TBS_SMARTAUDIO': 11,
'IRC_TRAMP': 12, 'IRC_TRAMP': 12,
'OPFLOW': 14,
'LOG': 15,
'RANGEFINDER': 16, 'RANGEFINDER': 16,
'VTX_FFPV': 17, 'VTX_FFPV': 17,
'ESC': 18,
}; };
// Required for MSP_DEBUGMSG because console.log() doesn't allow omitting // Required for MSP_DEBUGMSG because console.log() doesn't allow omitting

View file

@ -64,6 +64,21 @@ TABS.ports.initialize = function (callback) {
groups: ['peripherals'], groups: ['peripherals'],
maxPorts: 1 } maxPorts: 1 }
); );
if (semver.gte(CONFIG.flightControllerVersion, "2.2.0")) {
functionRules.push({
name: 'OPFLOW',
groups: ['sensors'],
maxPorts: 1 }
);
functionRules.push({
name: 'ESC',
groups: ['peripherals'],
maxPorts: 1 }
);
}
for (var i = 0; i < functionRules.length; i++) { for (var i = 0; i < functionRules.length; i++) {
functionRules[i].displayName = chrome.i18n.getMessage('portsFunction_' + functionRules[i].name); functionRules[i].displayName = chrome.i18n.getMessage('portsFunction_' + functionRules[i].name);
} }