1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-17 05:15:21 +03:00

Adding fixes for 3D to the newest version

Merge remote-tracking branch 'upstream/master'

Conflicts:
	tabs/configuration.html
This commit is contained in:
NightHawk32 2015-11-12 17:33:17 -05:00
commit 904a55c930
219 changed files with 25961 additions and 4066 deletions

View file

@ -52,7 +52,7 @@ var MSP_codes = {
MSP_WP: 118,
MSP_BOXIDS: 119,
MSP_SERVO_CONFIGURATIONS: 120,
MSP_3D: 124,
MSP_3D: 124,
MSP_SET_RAW_RC: 200,
MSP_SET_RAW_GPS: 201,
@ -68,7 +68,7 @@ var MSP_codes = {
MSP_SET_HEAD: 211,
MSP_SET_SERVO_CONFIGURATION: 212,
MSP_SET_MOTOR: 214,
MSP_SET_3D: 217,
MSP_SET_3D: 217,
// MSP_BIND: 240,
@ -411,16 +411,16 @@ var MSP = {
MISC.vbatmaxcellvoltage = data.getUint8(offset++, 1) / 10; // 10-50
MISC.vbatwarningcellvoltage = data.getUint8(offset++, 1) / 10; // 10-50
break;
case MSP_codes.MSP_3D:
var offset = 0;
case MSP_codes.MSP_3D:
var offset = 0;
_3D.deadband3d_low = data.getUint16(offset, 1);
offset += 2;
_3D.deadband3d_high = data.getUint16(offset, 1);
offset += 2;
_3D.neutral3d = data.getUint16(offset, 1);
offset += 2;
_3D.deadband3d_throttle = data.getUint16(offset, 1);
break;
_3D.deadband3d_high = data.getUint16(offset, 1);
offset += 2;
_3D.neutral3d = data.getUint16(offset, 1);
offset += 2;
_3D.deadband3d_throttle = data.getUint16(offset, 1);
break;
case MSP_codes.MSP_MOTOR_PINS:
console.log(data);
break;
@ -1141,6 +1141,7 @@ MSP.crunch = function (code) {
}
}
break;
case MSP_codes.MSP_SET_3D:
buffer.push(lowByte(_3D.deadband3d_low));
buffer.push(highByte(_3D.deadband3d_low));