Crate can_tools

Crate can_tools 

Source
Expand description

§can_tools

Rust utilities for parsing and modeling automotive CAN data.

§Highlights

  • DBC parser: load CAN databases from .dbc into a SlotMap-backed Database.
  • ASC parser: read Vector ASCII traces (.asc) into a decoupled CanLog.
  • Stable keys: Nodes/Messages/Signals use SlotMap keys that remain valid across reordering.
  • Ordered iteration: Database::iter_*() respects order vectors; use sort_*_by_name() to present alphabetically.
  • Fast lookups: normalized helpers (get_message_by_id/_hex/_name, get_node_by_name, get_signal_by_name).
  • Signal decoding: SignalDB::compile_inline, extract_raw_*, and to_sigframe.

Crate docs refreshed: 2025-08-22.

Modules§

arxml
arxml
asc
asc
dbc
dbc

Structs§

AbsoluteTime
Represents an absolute, timezone-unaware timestamp.
CanFrame
A single row from the log with timing/channel and a pointer to its MessageLog.
CanLog
In-memory representation of a parsed CAN trace.
Database
In-memory representation of a CAN database (DBC/ARXML).
MessageDB
CAN message defined in the database (DBC/ARXML).
MessageKey
MessageLog
Metadata and payload carried by a CanFrame.
NodeDB
Node/ECU defined in the database.
NodeKey
SignalDB
Definition of a signal within a CAN message (DBC).
SignalKey
SignalLog
Aggregated time-series for a decoded signal.

Enums§

Present

Functions§

resolve_message_signals
Yields the SignalLogs referenced by the MessageLog at msg_idx.