diff options
author | Gary E. Miller <gem@rellim.com> | 2019-05-25 14:39:07 -0700 |
---|---|---|
committer | Gary E. Miller <gem@rellim.com> | 2019-05-25 14:39:07 -0700 |
commit | c0a78c2d2819cb9dca0ad3011d4ad4d3e22e0f18 (patch) | |
tree | 72963525dcdce61a061a2f5151b6a269eb08eb85 /ubxtool | |
parent | bffe026876ad844bb33bdbd71065e456618ef917 (diff) | |
download | gpsd-c0a78c2d2819cb9dca0ad3011d4ad4d3e22e0f18.tar.gz |
ubxtool: en-/dis-able RAWX now affects RAW on older devices.
Protver 14 and below used UBX-RXM-RAW, after it uses RAWX.
Diffstat (limited to 'ubxtool')
-rwxr-xr-x | ubxtool | 14 |
1 files changed, 10 insertions, 4 deletions
@@ -4255,10 +4255,16 @@ class ubx(object): gps_model.gps_send(6, 1, m_data) def send_able_rawx(self, able): - """dis/enable UBX-RXM-RAWX""" + """dis/enable UBX-RXM-RAW/RAWXX""" rate = 1 if able else 0 - m_data = bytearray([0x2, 0x15, rate]) + if 15 > opts['protver']: + # u-blox 7 or earlier, use RAW + sid = 0x10 + else: + # u-blox 8 or later, use RAWX + sid = 0x15 + m_data = bytearray([0x2, sid, rate]) gps_model.gps_send(6, 1, m_data) def send_able_sbas(self, able): @@ -4614,9 +4620,9 @@ class ubx(object): # en/dis able basic NMEA messages "NMEA": {"command": send_able_nmea, "help": "basic NMEA messages"}, - # en/dis able RAWX + # en/dis able RAW/RAWX "RAWX": {"command": send_able_rawx, - "help": "RAWX measurements"}, + "help": "RAW/RAWX measurements"}, # en/dis able SBAS "SBAS": {"command": send_able_sbas, "help": "SBAS"}, |