mirror of
https://github.com/betaflight/betaflight-configurator.git
synced 2025-07-20 23:05:15 +03:00
Update msp.js
This commit is contained in:
parent
a2920a0f49
commit
f4fb947f8f
1 changed files with 3 additions and 0 deletions
|
@ -295,6 +295,7 @@ var MSP = {
|
||||||
RC_tuning.dynamic_THR_PID = parseFloat((data.getUint8(4) / 100).toFixed(2));
|
RC_tuning.dynamic_THR_PID = parseFloat((data.getUint8(4) / 100).toFixed(2));
|
||||||
RC_tuning.throttle_MID = parseFloat((data.getUint8(5) / 100).toFixed(2));
|
RC_tuning.throttle_MID = parseFloat((data.getUint8(5) / 100).toFixed(2));
|
||||||
RC_tuning.throttle_EXPO = parseFloat((data.getUint8(6) / 100).toFixed(2));
|
RC_tuning.throttle_EXPO = parseFloat((data.getUint8(6) / 100).toFixed(2));
|
||||||
|
RC_tuning.dynamic_THR_breakpoint = parseInt(data.getUint16(7, 1));
|
||||||
break;
|
break;
|
||||||
case MSP_codes.MSP_PID:
|
case MSP_codes.MSP_PID:
|
||||||
// PID data arrived, we need to scale it and save to appropriate bank / array
|
// PID data arrived, we need to scale it and save to appropriate bank / array
|
||||||
|
@ -917,6 +918,8 @@ MSP.crunch = function (code) {
|
||||||
buffer.push(parseInt(RC_tuning.dynamic_THR_PID * 100));
|
buffer.push(parseInt(RC_tuning.dynamic_THR_PID * 100));
|
||||||
buffer.push(parseInt(RC_tuning.throttle_MID * 100));
|
buffer.push(parseInt(RC_tuning.throttle_MID * 100));
|
||||||
buffer.push(parseInt(RC_tuning.throttle_EXPO * 100));
|
buffer.push(parseInt(RC_tuning.throttle_EXPO * 100));
|
||||||
|
buffer.push(lowByte(RC_tuning.dynamic_THR_breakpoint));
|
||||||
|
buffer.push(highByte(RC_tuning.dynamic_THR_breakpoint));
|
||||||
break;
|
break;
|
||||||
// Disabled, cleanflight does not use MSP_SET_BOX.
|
// Disabled, cleanflight does not use MSP_SET_BOX.
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue