--- id: pyubx2 version: "1.3.6" license: BSD-3-Clause license_treatment: permissive maintenance: active --- # pyubx2 — UBX protocol parser and generator License: permissive · Maintenance: active · Downloads: 93.0K/mo ## What it is and what it does pyubx2 is a parser and generator for the UBX binary protocol used by u-blox GNSS receiver modules. It reads and parses incoming UBX messages from streams (serial, file, or socket), returning both raw bytes and structured message objects. The package integrates support for NMEA 0183 and RTCM3 protocols via its runtime dependencies pynmeagps and pyrtcm, covering all output protocols that u-blox receivers produce. The library divides UBX messages into three categories: GET (output from the receiver), SET (commands to the receiver), and POLL (queries to the receiver). It provides a UBXReader class for streaming and parsing, a static parse() method for individual messages, and utilities for generating and serializing messages. The package is readily extensible and implements a comprehensive set of messages for current u-blox devices. Use it for: - Stream and parse real-time GNSS data from a u-blox receiver via file or socket. - Read and decode UBX messages from a binary file for post-processing or analysis. - Send configuration commands or queries to a u-blox receiver and parse responses. - Handle mixed protocol streams containing UBX, NMEA, and RTCM3 messages. - Extend the parser with custom UBX message definitions for non-standard outputs. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Parses and generates UBX protocol messages from u-blox GNSS receivers, and can also handle NMEA 0183 and RTCM3 protocols through pynmeagps and pyrtcm. Yes. The package is actively maintained, has no known vulnerabilities, low install friction, and a permissive BSD-3-Clause license. It fills a clear need for developers working with u-blox GNSS receivers. Install it if you need to parse or generate UBX protocol messages. ## Install pip install pyubx2 uv add pyubx2 poetry add pyubx2 ## Installing pyubx2 Before you install: Low install friction with a pure Python wheel. Actively maintained with a recent release 27 days old and a stable repository. Requires Python>=3.10. License in practice: BSD-3-Clause is permissive; you can use, modify, and distribute this package with minimal restrictions, provided you include the license notice. Quickstart: from pyubx2 import UBXReader with open('ubxdata.bin', 'rb') as stream: ubr = UBXReader(stream) for raw_data, parsed_data in ubr: print(parsed_data) Requires Python>=3.10; stream object must support read(n) -> bytes method. Verify before relying: - Whether the command-line utility and graphical client mentioned in the documentation are included in the PyPI distribution. - Performance characteristics when parsing high-frequency GNSS message streams. - Whether custom UBX message type extensibility is straightforward for typical use cases. ## Package facts - License: BSD-3-Clause (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 93.0K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags ubx protocol parser, gnss receiver data parsing, u-blox gps messages, nmea rtcm protocol handler, binary gnss protocol decoder, gnss-gps, protocol-parser, ubx-binary [View on SkillFed](https://skillfed.io/packages/pyubx2) · [View on PyPI](https://pypi.org/project/pyubx2/)