Detect and parse
Automatically identify Gen1 or Gen2 and card or vehicle-unit data. Read from a file path or an in-memory byte slice.
Turn a digital tachograph download into strongly typed Rust data. Parse cards and vehicle units, export records and verify supported signatures in your own application.
Rust library · Command-line tools · WebAssembly
use esm_parser::parse_from_file;
fn main() -> Result<(), Box<dyn std::error::Error>> {
let data = parse_from_file("card.ddd")?;
println!("{data:#?}");
Ok(())
}
.DDD → Rust types · JSON · XML
Keep parsing in one library. Use the decoded records in your own tools, services or browser-based application.
Automatically identify Gen1 or Gen2 and card or vehicle-unit data. Read from a file path or an in-memory byte slice.
Access activities, events, faults, vehicle usage and calibration data through structured Rust types and generation-specific modules.
Use the included esm2json and esm2xml command-line examples. Choose an output path and optional pretty formatting.
Check Gen1 and Gen2 card and vehicle-unit signatures with the corresponding ERCA certificate material. Verification scope stays explicit.
Compile with wasm-pack. The WebAssembly boundary includes a generated TypeScript contract and a discriminated kind/data envelope.
Read the implementation, extend the parser and integrate it under the project license. ESM Viewer is a separate desktop application for inspecting downloads.
Parsing and signature verification do not calculate driving-time compliance or provide a certified legal assessment.
A library for integration, examples for conversion, and a WebAssembly build for browser projects.
Run the JSON example from a source checkout. Use esm2xml and --xml-file for XML output.
cargo run --example esm2json -- \
--ddd-file card.ddd \
--json-file card.json \
--pretty
CLI options and examples →
Load the ERCA certificates for the generations you need, then verify the parsed data.
let data = parse_from_file("vehicle_unit.ddd")?;
let gen1 = std::fs::read("gen1-erca.bin")?;
let gen2 = std::fs::read("gen2-erca.bin")?;
let result = data.verify(
Some(&gen1), Some(&gen2),
)?;
Verification contract and limitations →
Try the actual Rust parser compiled to WebAssembly. Your file is processed in this browser, not uploaded to a server.
A dedicated workspace with drag-and-drop, JSON preview and download. No upload needed. Parsing does not verify digital signatures.
The library parses data in the application that calls it. The command-line examples work with local files; no hosted upload service is needed.
DDD downloads can contain personal driver and vehicle information. Keep production files and certificate material out of public repositories, screenshots and support reports.
Local DDD download
Your input file or byte slice
ESM Parser
Decode and optionally verify
Your application
Typed records or exported data
Prebuilt command-line examples and a WebAssembly package. For the Rust library, build from source below.
Latest stable archives: v0.4.1 release notes.
x86-64 command-line examples
Windows archive ZIP ↓Choose your processor architecture
Apple silicon TAR.GZ ↓Intel Mac archive ↓x86-64 command-line examples
Linux archive TAR.GZ ↓Package for browser integration
WASM package TAR.GZ ↓These are developer tools, not desktop installers. Release contents can differ from the current source; read the linked release notes.
Use a current stable Rust toolchain. There is no published minimum supported Rust version policy.
git clone https://github.com/mbolaric/esm-parser.git
cd esm-parser
cargo build
Extract the archive for your platform. Open a terminal in the extracted directory and run ./esm2json --help or ./esm2xml --help. On Windows, use .\esm2json.exe --help. If an extracted Unix executable lacks permission, run chmod +x esm2json esm2xml. Only run binaries from a source you trust.
Try the full-page demo, or build the standalone example locally. From the repository root, install wasm-pack and run the build script. It regenerates the TypeScript contract before building the browser package.
cargo install wasm-pack
./scripts/build-wasm.sh --release
python3 -m http.server 8090Open http://127.0.0.1:8090/examples/web/. Serve the repository root, not examples/web: the standalone example loads the generated pkg directory. The full-page demo loads the parser only after you select a file.
A Gen1 ERCA value must be exactly 144 bytes; a Gen2 ERCA CVC must be exactly 205 bytes. Pass the corresponding --erca-gen1-file and --erca-gen2-file options to an exporter. Parsing alone does not verify signatures.
Company and Control Gen2 applications do not have a signed elementary-file verification path. Combined Driver and Workshop cards are verified separately by generation. See the full verification reference for certificate chains, rollover and supported scopes.
No. ESM Parser is a Rust parsing library with CLI examples and WebAssembly support. ESM Viewer is the separate desktop application for exploring tachograph records through a graphical interface.
Yes. Use parse_from_memory with a byte slice. Both it and parse_from_file return TachographData, distinguishing Gen1/Gen2 and card/vehicle-unit results.
ESM Parser is open source. Review the project license before integrating or distributing it.
Open a GitHub issue with the version, command or API call, and a redacted error. Do not attach personal DDD downloads or certificate material. The fixture-backed integration tests are ignored by default so private files can stay local.