mirror of
https://github.com/iNavFlight/inav-configurator.git
synced 2025-07-15 04:15:28 +03:00
[PORTS] Add ESC and OPFLOW to serial port bit masks
This commit is contained in:
parent
8b9ed31448
commit
bc95909055
3 changed files with 24 additions and 0 deletions
|
@ -870,6 +870,12 @@
|
|||
"portsFunction_RANGEFINDER": {
|
||||
"message": "Rangefinder"
|
||||
},
|
||||
"portsFunction_OPFLOW": {
|
||||
"message": "Optic flow"
|
||||
},
|
||||
"portsFunction_ESC": {
|
||||
"message": "ESC output/telemetry"
|
||||
},
|
||||
"portsFunction_TELEMETRY_FRSKY": {
|
||||
"message": "FrSky"
|
||||
},
|
||||
|
|
|
@ -45,8 +45,11 @@ var mspHelper = (function (gui) {
|
|||
'RUNCAM_DEVICE_CONTROL': 10,
|
||||
'TBS_SMARTAUDIO': 11,
|
||||
'IRC_TRAMP': 12,
|
||||
'OPFLOW': 14,
|
||||
'LOG': 15,
|
||||
'RANGEFINDER': 16,
|
||||
'VTX_FFPV': 17,
|
||||
'ESC': 18,
|
||||
};
|
||||
|
||||
// Required for MSP_DEBUGMSG because console.log() doesn't allow omitting
|
||||
|
|
|
@ -64,6 +64,21 @@ TABS.ports.initialize = function (callback) {
|
|||
groups: ['peripherals'],
|
||||
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++) {
|
||||
functionRules[i].displayName = chrome.i18n.getMessage('portsFunction_' + functionRules[i].name);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue