finds.dev← search

// the find

ebroecker/canmatrix

★ 1,080 · Python · BSD-2-Clause · updated Jun 2026

Converting Can (Controller Area Network) Database Formats .arxml .dbc .dbf .kcd ...

canmatrix is a Python library for reading, writing, and converting CAN bus database files — the kind automotive engineers deal with daily: DBC files from Vector tools, ARXML from AUTOSAR toolchains, KCD from Kayak, and a dozen others. It also handles message encoding/decoding at the signal level. If you work on embedded automotive systems and need to manipulate CAN databases programmatically, this is the only real option in Python.

The format coverage is genuinely broad — DBC, ARXML, FIBEX, KCD, SYM, LDF, ODX, EDS, plus Excel import/export for the spreadsheet-driven workflows that are common in automotive projects. The object model (CanMatrix → Frame → Signal) maps cleanly to how CAN databases are actually structured, which makes it usable as a library rather than just a CLI tool. The test suite uses reference files for round-trip conversions across every supported format pair, which is the right way to test format converters. It also generates Wireshark Lua dissectors and Scapy definitions directly, which saves a lot of manual work during protocol debugging.

The ARXML support is explicitly marked 'very basic' and AUTOSAR files in the real world are anything but basic — if you're working with a serious OEM AUTOSAR architecture description, you'll hit gaps quickly. The codebase has grown organically and the format modules vary a lot in completeness and style; the DBC parser in particular has accumulated years of edge-case handling that makes it hard to contribute to. No async API, which matters if you're processing large batches of files in a modern Python service. Documentation is thin on the object model itself — the API reference exists but you'll spend time reading source to understand what attributes are guaranteed versus optional for a given format.

View on GitHub →

// want more like this?

We dig through GitHub every week and send a few repos picked for what you actually care about — each with an honest take like this one.

Get finds in your inbox → Search again →