Changed velocity source names
This commit is contained in:
@@ -159,7 +159,7 @@ def velocity(msg, rtn_sources=False):
|
|||||||
ground track or heading (degree),
|
ground track or heading (degree),
|
||||||
rate of climb/descent (ft/min), speed type
|
rate of climb/descent (ft/min), speed type
|
||||||
('GS' for ground speed, 'AS' for airspeed),
|
('GS' for ground speed, 'AS' for airspeed),
|
||||||
direction source ('gnd_trk' for ground track, 'mag_hdg' for
|
direction source ('true_north' for ground track, 'mag_north' for
|
||||||
magnetic heading), rate of climb/descent source ('Baro' for
|
magnetic heading), rate of climb/descent source ('Baro' for
|
||||||
barometer, 'GNSS' for GNSS constellation).
|
barometer, 'GNSS' for GNSS constellation).
|
||||||
|
|
||||||
|
|||||||
@@ -154,7 +154,7 @@ def surface_velocity(msg, rtn_sources=False):
|
|||||||
(int, float, int, string, string, None): speed (kt),
|
(int, float, int, string, string, None): speed (kt),
|
||||||
ground track (degree), None for rate of climb/descend (ft/min),
|
ground track (degree), None for rate of climb/descend (ft/min),
|
||||||
and speed type ('GS' for ground speed), direction source
|
and speed type ('GS' for ground speed), direction source
|
||||||
('gnd_trk' for ground track), None rate of climb/descent source.
|
('true_north' for ground track), None rate of climb/descent source.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
if common.typecode(msg) < 5 or common.typecode(msg) > 8:
|
if common.typecode(msg) < 5 or common.typecode(msg) > 8:
|
||||||
@@ -188,6 +188,6 @@ def surface_velocity(msg, rtn_sources=False):
|
|||||||
spd = round(spd, 2)
|
spd = round(spd, 2)
|
||||||
|
|
||||||
if rtn_sources:
|
if rtn_sources:
|
||||||
return spd, trk, 0, 'GS', 'gnd_trk', None
|
return spd, trk, 0, 'GS', 'true_north', None
|
||||||
else:
|
else:
|
||||||
return spd, trk, 0, 'GS'
|
return spd, trk, 0, 'GS'
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ def airborne_velocity(msg, rtn_sources=False):
|
|||||||
ground track or heading (degree),
|
ground track or heading (degree),
|
||||||
rate of climb/descent (ft/min), speed type
|
rate of climb/descent (ft/min), speed type
|
||||||
('GS' for ground speed, 'AS' for airspeed),
|
('GS' for ground speed, 'AS' for airspeed),
|
||||||
direction source ('gnd_trk' for ground track, 'mag_hdg' for
|
direction source ('true_north' for ground track, 'mag_north' for
|
||||||
magnetic heading), rate of climb/descent source ('Baro' for
|
magnetic heading), rate of climb/descent source ('Baro' for
|
||||||
barometer, 'GNSS' for GNSS constellation)
|
barometer, 'GNSS' for GNSS constellation)
|
||||||
"""
|
"""
|
||||||
@@ -74,7 +74,7 @@ def airborne_velocity(msg, rtn_sources=False):
|
|||||||
|
|
||||||
tag = 'GS'
|
tag = 'GS'
|
||||||
trk_or_hdg = round(trk, 2)
|
trk_or_hdg = round(trk, 2)
|
||||||
dir_type = 'gnd_trk'
|
dir_type = 'true_north'
|
||||||
|
|
||||||
else:
|
else:
|
||||||
if mb[13] == '0':
|
if mb[13] == '0':
|
||||||
@@ -93,7 +93,7 @@ def airborne_velocity(msg, rtn_sources=False):
|
|||||||
else:
|
else:
|
||||||
tag = 'TAS'
|
tag = 'TAS'
|
||||||
|
|
||||||
dir_type = 'mag_hdg'
|
dir_type = 'mag_north'
|
||||||
|
|
||||||
vr_source = 'GNSS' if mb[35]=='0' else 'Baro'
|
vr_source = 'GNSS' if mb[35]=='0' else 'Baro'
|
||||||
vr_sign = -1 if mb[36]=='1' else 1
|
vr_sign = -1 if mb[36]=='1' else 1
|
||||||
|
|||||||
Reference in New Issue
Block a user