complete surface position decoding

This commit is contained in:
junzis
2016-10-19 16:22:28 +02:00
parent b648f4e7a5
commit 4bafa1de19
4 changed files with 120 additions and 27 deletions

View File

@@ -37,6 +37,13 @@ def test_adsb_surface_position_with_ref():
assert pos == (-43.48564, 175.87195)
def test_adsb_surface_position():
pos = adsb.surface_position("8CC8200A3AC8F009BCDEF2000000",
"8FC8200A3AB8F5F893096B000000",
0, 2,
-43.496, 172.558)
assert pos == (-43.48564, 172.53942)
def test_adsb_alt():
assert adsb.altitude("8D40058B58C901375147EFD09357") == 39000

View File

@@ -12,7 +12,8 @@ def test_ehs_BDS():
assert ehs.BDS("A0001839CA3800315800007448D9") == 'BDS40'
assert ehs.BDS("A000139381951536E024D4CCF6B5") == 'BDS50'
assert ehs.BDS("A000029CFFBAA11E2004727281F1") == 'BDS60'
assert ehs.BDS("A0281838CAE9E12FA03FFF2DDDE5") is None
assert ehs.BDS("A0281838CAE9E12FA03FFF2DDDE5") == 'BDS44'
assert ehs.BDS("A00017B0C8480030A4000024512F") is None
def test_ehs_BDS20_callsign():
@@ -39,4 +40,4 @@ def test_ehs_BDS60_functions():
assert ehs.ias("A000029CFFBAA11E2004727281F1") == 336
assert ehs.mach("A000029CFFBAA11E2004727281F1") == 0.48
assert ehs.baro_vr("A000029CFFBAA11E2004727281F1") == 0
assert ehs.ins_vr("A000029CFFBAA11E2004727281F1") == -3648
assert ehs.ins_vr("A000029CFFBAA11E2004727281F1") == -3648