1
0
Fork 0
mirror of https://github.com/iNavFlight/inav-configurator.git synced 2025-07-23 16:25:19 +03:00

Merge pull request #271 from fiam/mspv2_fix

Fix decoding MSPv2 message codes with high byte != 0
This commit is contained in:
Konstantin Sharlaimov 2017-10-07 10:12:17 +10:00 committed by GitHub
commit a2ae69b170

View file

@ -165,7 +165,7 @@ var MSP = {
this.state = this.decoder_states.CODE_V2_HIGH;
break;
case this.decoder_states.CODE_V2_HIGH:
this.message_length_expected |= data[i] << 8;
this.code |= data[i] << 8;
this.state = this.decoder_states.PAYLOAD_LENGTH_V2_LOW;
break;
case this.decoder_states.PAYLOAD_LENGTH_JUMBO_LOW: