1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 00:05:33 +03:00

a bit more cleanup

This commit is contained in:
Raphael Coeffic 2016-10-28 14:19:01 +02:00
parent 160bfaf907
commit d38d4949e9
2 changed files with 6 additions and 12 deletions

View file

@ -71,7 +71,7 @@ local function mspReceivedReply(payload)
-- return error
-- CRC checking missing
--return bit32.band(payload[idx],0xFF)
--return payload[idx]
return nil
end
@ -93,8 +93,10 @@ local function mspReceivedReply(payload)
elseif not mspStarted then
mspReceivedReply_cnt3 = mspReceivedReply_cnt3 + 1
return nil
-- TODO: add sequence number checking
-- elseif ...
elseif bit32.band(lastSeq+1,0x0F) ~= seq then
mspStarted = false
return nil
end
while (idx <= 6) and (mspRxIdx <= mspRxSize) do