mirror of
https://github.com/betaflight/betaflight-configurator.git
synced 2025-07-25 01:05:15 +03:00
parent
e31cf536a6
commit
4bdf7fbe17
1 changed files with 13 additions and 2 deletions
|
@ -268,8 +268,8 @@ setup.initialize = function (callback) {
|
||||||
|
|
||||||
const showSensorInfo = function() {
|
const showSensorInfo = function() {
|
||||||
const gyroElements = [
|
const gyroElements = [
|
||||||
|
'AUTO',
|
||||||
'NONE',
|
'NONE',
|
||||||
'DEFAULT',
|
|
||||||
'MPU6050',
|
'MPU6050',
|
||||||
'L3G4200D',
|
'L3G4200D',
|
||||||
'MPU3050',
|
'MPU3050',
|
||||||
|
@ -292,7 +292,7 @@ setup.initialize = function (callback) {
|
||||||
];
|
];
|
||||||
|
|
||||||
const accElements = [
|
const accElements = [
|
||||||
'DEFAULT',
|
'AUTO',
|
||||||
'NONE',
|
'NONE',
|
||||||
'ADXL345',
|
'ADXL345',
|
||||||
'MPU6050',
|
'MPU6050',
|
||||||
|
@ -350,6 +350,17 @@ setup.initialize = function (callback) {
|
||||||
'TF02',
|
'TF02',
|
||||||
];
|
];
|
||||||
|
|
||||||
|
// remove deprecated sensors
|
||||||
|
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_47)) {
|
||||||
|
gyroElements.splice(gyroElements.indexOf("L3G4200D"), 1);
|
||||||
|
gyroElements.splice(gyroElements.indexOf("MPU3050"), 1);
|
||||||
|
|
||||||
|
accElements.splice(accElements.indexOf("ADXL345"), 1);
|
||||||
|
accElements.splice(accElements.indexOf("MMA8452"), 1);
|
||||||
|
accElements.splice(accElements.indexOf("BMA280"), 1);
|
||||||
|
accElements.splice(accElements.indexOf("LSM303DLHC"), 1);
|
||||||
|
}
|
||||||
|
|
||||||
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_46)) {
|
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_46)) {
|
||||||
MSP.send_message(MSPCodes.MSP2_SENSOR_CONFIG_ACTIVE, false, false, function() {
|
MSP.send_message(MSPCodes.MSP2_SENSOR_CONFIG_ACTIVE, false, false, function() {
|
||||||
// Sensor info
|
// Sensor info
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue