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

mixer_profile switch support

This commit is contained in:
shota 2023-10-15 17:26:46 +09:00
parent 0bb8c1521b
commit 51c33d2bd9
9 changed files with 60 additions and 5 deletions

View file

@ -118,6 +118,7 @@ var FC = {
i2cError: 0,
activeSensors: 0,
mode: [],
mixer_profile: 0,
profile: 0,
battery_profile: 0,
uid: [0, 0, 0],

View file

@ -260,6 +260,7 @@ GUI_control.prototype.updateStatusBar = function() {
};
GUI_control.prototype.updateProfileChange = function() {
$('#mixerprofilechange').val(CONFIG.mixer_profile);
$('#profilechange').val(CONFIG.profile);
$('#batteryprofilechange').val(CONFIG.battery_profile);
};

View file

@ -240,5 +240,7 @@ var MSPCodes = {
MSP2_INAV_SET_LED_STRIP_CONFIG_EX: 0x2049,
MSP2_INAV_RATE_DYNAMICS: 0x2060,
MSP2_INAV_SET_RATE_DYNAMICS: 0x2061
MSP2_INAV_SET_RATE_DYNAMICS: 0x2061,
MSP2_INAV_SELECT_MIXER_PROFILE: 0x2070
};

View file

@ -79,6 +79,8 @@ var mspHelper = (function (gui) {
profile_byte = data.getUint8(offset++)
CONFIG.profile = profile_byte & 0x0F;
CONFIG.battery_profile = (profile_byte & 0xF0) >> 4;
profile_byte = data.getUint8(offset++)
CONFIG.mixer_profile = profile_byte & 0x0F;
CONFIG.armingFlags = data.getUint32(offset, true);
offset += 4;
gui.updateStatusBar();