--- id: ldfparser version: "0.26.0" license: MIT license_treatment: permissive maintenance: aging --- # ldfparser — LDF Language support for Python License: permissive · Maintenance: aging · Downloads: 1.4M/mo ## What it is and what it does ldfparser reads LIN Description Files and extracts their signal and frame metadata, then uses those definitions to encode raw signal values into binary messages and decode binary messages back into signal dictionaries. It implements the LIN protocol standards (1.3, 2.0, 2.1, 2.2A) and provides both programmatic and command-line interfaces for working with LDF files. The package depends on lark for parsing, bitstruct for bit-level encoding/decoding, and jinja2 for templating. It is designed for automotive and embedded systems work where LIN bus communication requires translating between human-readable signal names and their binary representations. The library is still pre-release, so breaking changes can occur between minor versions; production use should pin to a specific version and test before upgrading. Use it for: - Decode raw CAN/LIN bus messages captured from a vehicle into human-readable signal values for analysis or logging. - Encode signal commands (e.g., motor RPM, fan state) into binary frames for transmission over a LIN bus. - Extract signal definitions and metadata from LDF files to build protocol documentation or validation tools. - Validate LDF file syntax and semantic correctness before using it in production automotive systems. - Automate conversion between LDF and other formats (e.g., JSON) for integration with external tools. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Parses LIN Description Files (LDF) to extract signal and frame definitions, and encodes/decodes messages according to those definitions. Yes, if you work with LIN bus protocols and LDF files in automotive or embedded contexts. The package has low install friction, permissive licensing, and no known vulnerabilities. However, be aware that maintenance is aging (last release 564 days ago) and the library is pre-release, so pin versions in production and test upgrades carefully. Not relevant for general-purpose Python development. ## Install pip install ldfparser uv add ldfparser poetry add ldfparser ## Installing ldfparser Before you install: Low install friction with three straightforward dependencies (lark, bitstruct, jinja2). Maintenance status is aging—last release was 564 days ago—so expect slower response to issues, though the repository remains active and not archived. License in practice: MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute the package freely provided you include the original license notice. Quickstart: pip install ldfparser import ldfparser ldf = ldfparser.parse_ldf(path="network.ldf") frame = ldf.get_unconditional_frame('Frame_1') message = frame.encode_raw({"Signal_1": 123, "Signal_2": 0}) Requires a valid LDF file; the library is in pre-release state, so breaking changes may occur between minor versions—pin to exact version in production. Verify before relying: - Whether the library successfully parses all real-world LDF files that conform to LIN 1.3, 2.0, 2.1, or 2.2A standards, or if compatibility gaps remain. - Current state of checksum calculation for frames (listed as a known missing feature in the description). - Stability and completeness of the experimental LDF save-to-file feature. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: aging - Downloads: 1.4M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags LIN protocol parsing, LDF file parser, automotive message encoding decoding, LIN signal extraction, frame definition parser, LIN bus protocol, message encode decode, automotive, protocol-parsing, embedded-systems [View on SkillFed](https://skillfed.io/packages/ldfparser) · [View on PyPI](https://pypi.org/project/ldfparser/)