Merge pull request #119 from Flyer350/patch-8

fix bug in squawk decoding for BDS61
This commit is contained in:
Junzi Sun 2021-11-22 10:23:32 +01:00 committed by GitHub
commit 00f04a8886
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -77,7 +77,7 @@ def emergency_squawk(msg: str) -> str:
msgbin = common.hex2bin(msg)
# construct the 13 bits Mode A ID code
idcode = msgbin[43:49] + "0" + msgbin[49:55]
idcode = msgbin[43:56]
squawk = common.squawk(idcode)
return squawk