mirror of
https://github.com/iNavFlight/inav-configurator.git
synced 2025-07-15 20:35:19 +03:00
Ensure offset variable is updated consistently in MSP_MISC.
See 9261163ca2
This commit is contained in:
parent
99494d0157
commit
2e046db53e
1 changed files with 11 additions and 11 deletions
22
js/msp.js
22
js/msp.js
|
@ -375,18 +375,18 @@ var MSP = {
|
||||||
offset += 2;
|
offset += 2;
|
||||||
MISC.failsafe_throttle = data.getUint16(offset, 1); // 1000-2000
|
MISC.failsafe_throttle = data.getUint16(offset, 1); // 1000-2000
|
||||||
offset += 2;
|
offset += 2;
|
||||||
MISC.gps_type = data.getUint8(offset);
|
MISC.gps_type = data.getUint8(offset++);
|
||||||
MISC.gps_baudrate = data.getUint8(++offset);
|
MISC.gps_baudrate = data.getUint8(offset++);
|
||||||
MISC.gps_ubx_sbas = data.getInt8(++offset);
|
MISC.gps_ubx_sbas = data.getInt8(offset++);
|
||||||
MISC.multiwiicurrentoutput = data.getUint8(++offset);
|
MISC.multiwiicurrentoutput = data.getUint8(offset++);
|
||||||
MISC.rssi_channel = data.getUint8(++offset);
|
MISC.rssi_channel = data.getUint8(offset++);
|
||||||
MISC.placeholder2 = data.getUint8(++offset);
|
MISC.placeholder2 = data.getUint8(offset++);
|
||||||
MISC.mag_declination = data.getInt16(++offset, 1) / 10; // -18000-18000
|
MISC.mag_declination = data.getInt16(offset, 1) / 10; // -18000-18000
|
||||||
offset += 2;
|
offset += 2;
|
||||||
MISC.vbatscale = data.getUint8(offset, 1); // 10-200
|
MISC.vbatscale = data.getUint8(offset++, 1); // 10-200
|
||||||
MISC.vbatmincellvoltage = data.getUint8(++offset, 1) / 10; // 10-50
|
MISC.vbatmincellvoltage = data.getUint8(offset++, 1) / 10; // 10-50
|
||||||
MISC.vbatmaxcellvoltage = data.getUint8(++offset, 1) / 10; // 10-50
|
MISC.vbatmaxcellvoltage = data.getUint8(offset++, 1) / 10; // 10-50
|
||||||
MISC.vbatwarningcellvoltage = data.getUint8(++offset, 1) / 10; // 10-50
|
MISC.vbatwarningcellvoltage = data.getUint8(offset++, 1) / 10; // 10-50
|
||||||
break;
|
break;
|
||||||
case MSP_codes.MSP_MOTOR_PINS:
|
case MSP_codes.MSP_MOTOR_PINS:
|
||||||
console.log(data);
|
console.log(data);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue