Commit e0d55efd authored by enfo's avatar enfo

Added SBAS attempt and enabled messages.

parent ca63799f
......@@ -141,8 +141,6 @@ class UbloxPackageRxmMeasX(UbloxPackage):
for list_ix, u in enumerate(unpacked):
lists[list_ix][i] = u
class UbloxPackageNavPosLLH(UbloxPackage):
ubx_name = 'NAV-POSLLH'
ubx_id = b'\x01\x02'
......@@ -218,9 +216,26 @@ class UbloxPackageNavClock(UbloxPackage):
values = struct.unpack('I2i2I', self.package)
self._dict.update(dict(zip(names, values)))
class UbloxPackageSBAS(UbloxPackage):
ubx_name = 'NAV-SBAS'
ubx_id = b'\x01\x32'
def __init__(self, ubx_id, tov, package, toa, tot, timestamp):
UbloxPackage.__init__(self, ubx_id, tov, package, toa, tot, timestamp)
names = ('iTow', 'geo', 'mode', 'sys', 'service', 'cnt', 'res1', 'res2', 'res3')
self._dict.update(names, struct.unpack_from('I2Bb5B', self.package, 0))
cnt = self._dict['cnt']
sbas_data = [{} for _ in range(cnt)]
for ix, data in enumerate(sbas_data):
names = ('svid', 'flags', 'udre', 'svService', 'reserved2', 'prc', 'reserved3', 'ic')
data.update(names, struct.unpack_from('6BhHh', self.package, 12 + 12*ix))
MSG_TYPES = [UbloxPackageRxmRawX, UbloxPackageNavPosLLH, UbloxPackageRxmSfrbX,
UbloxPackageNavPosECEF, UbloxPackageNavVelEcef]
UbloxPackageNavPosECEF, UbloxPackageNavVelEcef, UbloxPackageNavVelNED,
UbloxPackagePVT, UbloxPackageNavClock, UbloxPackageSBAS]
UBX_MSG_TYPES = dict([(t.ubx_id, t) for t in MSG_TYPES])
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment