在查看了最近一次试飞的日志后,我的飞行器报告了fix_type
class 变量的值为 4 dronekit.GPSInfo(eph, epv, fix_type, satellites_visible)
。
eph
并且epv
没有价值,satellites_visible
在 9 到 12 之间变化。
飞行时间长达 30 分钟。GPS模块是ublox gps + compass模块。
室内我fix_type
按预期得到 0 或 1,但室外我得到 3-4?我可以找到有关 3D 定位的信息,但 4D GPS 定位是什么意思?
这个变量是如何在源代码中设置的?
class GPSInfo(object):
"""
Standard information about GPS.
If there is no GPS lock the parameters are set to ``None``.
:param Int eph: GPS horizontal dilution of position (HDOP).
:param Int epv: GPS vertical dilution of position (VDOP).
:param Int fix_type: 0-1: no fix, 2: 2D fix, 3: 3D fix
:param Int satellites_visible: Number of satellites visible.
.. todo:: FIXME: GPSInfo class - possibly normalize eph/epv? report fix type as string?
"""
def __init__(self, eph, epv, fix_type, satellites_visible):
self.eph = eph
self.epv = epv
self.fix_type = fix_type
self.satellites_visible = satellites_visible
def __str__(self):
return "GPSInfo:fix=%s,num_sat=%s" % (self.fix_type, self.satellites_visible)