How-to guides · 2026-11-27
CAN addresses for datalogger
Stefan Bogdanescu
Founder & Senior Architect
Retrieving Vehicle Parameters via CAN Bus for External Data Logging
The objective of this procedure is to systematically identify, extract, and utilize specific Controller Area Network (CAN) Message Identifiers (IDs) corresponding to critical Engine Control Unit (ECU) parameters. This allows the integration of real-time operational data—such as engine speed, throttle angle, or boost pressure—into an external datalogging system for performance analysis, research, or diagnostics.
Prerequisites and Required Equipment
Successfully capturing CAN data requires a structured understanding of both automotive network protocols and diagnostic tools.
Technical Knowledge
- CAN Protocol: Understanding the structure of CAN messages (ID, DLC, Data Bytes) and bus arbitration.
- Diagnostic Standards: Familiarity with Universal Diagnostic Services (UDS) or equivalent protocol methods used by vehicle diagnostic tools.
- Data Mapping: Ability to read and interpret standardized data definition files (e.g., DBC files).
Hardware and Software
- CAN Interface/Bus Analyzer: A reliable hardware interface capable of tapping into the vehicle's CAN bus (e.g., a specialized breakout box or OBD-II adapter with advanced logging capabilities).
- Datalogger System: The external recording device designed to capture, timestamp, and store high-speed data streams.
- Analysis Software: PC software capable of receiving, filtering, decoding, and visualizing raw CAN traffic (e.g., specialized CAN sniffing tools).
- Vehicle Access: A vehicle equipped with the specific ECU under test (EUT) to ensure compatibility with diagnostic procedures.
Understanding Vehicle Data Addressing
In an automotive network, data is not stored by physical variable name; it is transmitted within defined digital packets. Every parameter must be addressed through a combination of three elements:
- CAN ID: A unique identifier defining the specific message stream (e.g.,
0x2A3). - Byte Offset/Index: The specific byte within the data payload where the information resides.
- Bit Position: The specific bit within that byte that defines the value (critical for parameters encoded across multiple bits).
When attempting to log a parameter, you are not looking up a "value"; you are identifying the precise network address location of that value stream. Consulting comprehensive resources like those provided by ECU Docs can assist in understanding complex data structures and communication protocols relevant to your specific application.
Procedure: Identifying CAN Addresses for Logging
This process requires moving beyond simple physical connection and employing advanced diagnostic techniques to map parameters to their unique digital addresses.
Step 1: Define Required Parameters
Before connecting any hardware, create a comprehensive list of every parameter required for the log file (e.g., Engine Speed in RPM, Manifold Absolute Pressure [MAP], Throttle Position, Wheel Speed). This minimizes unnecessary logging and reduces data volume.
Step 2: Establish Baseline Communication (The Passive Sniff)
- Connect the CAN interface to the designated vehicle bus connection point (usually OBD-II or a dedicated harness tap).
- Power up the vehicle while monitoring the network traffic using the analysis software.
- Allow the system to run under normal operational conditions (e.g., idling, cruising) for several minutes. This baseline data reveals which CAN IDs are active and what general data structures are being exchanged without actively probing them.
Step 3: Utilize Diagnostic Tools for Parameter Identification (Active Probing)
Since most modern parameters are only accessible via a standardized diagnostic request (e.g., UDS services), you must simulate the function of a professional diagnostic scan tool.
- Initiate Connection: Use the analysis software or an external diagnostic device to establish communication with the target ECU's gateway port.
- Request Parameter Data: Select one specific parameter from your list (e.g., Throttle Position). The diagnostic tool will send a query, and the ECU will respond by transmitting the data payload containing that value.
- Capture Response IDs: Crucially, record all CAN IDs used during this successful request-response cycle. These IDs are the primary candidates for your logging stream.
- Determine Data Structure: Analyze the received data bytes. Determine which byte contains the target parameter and how that value is scaled (e.g., raw voltage reading vs. calculated physical unit).
Step 4: Validation and Confirmation
To ensure the captured ID is stable and reliable for logging, repeat the probing process multiple times under varied conditions (e.g., increasing RPM, changing load) to confirm that the assigned CAN ID does not change or become intermittently unavailable.
Configuration and Data Interpretation
Once the addresses are identified, the data must be configured correctly for the datalogger system to interpret it meaningfully.
Data Scaling and Unit Conversion
Raw digital values captured from the bus rarely match engineering units (e.g., volts, psi). You must apply known scaling factors:
$$ \text{Physical Value} = (\frac{\text{Observed Raw Digital Value}}{2^{N}} ) \times \text{Scale Factor} $$
Where $N$ is related to the data bit depth and the Scale Factor is determined by engineering specifications (e.g., 1 unit/Volt, or 1 PSI per X raw count). Miscalculating this step results in unusable log data.
Addressing High-Frequency Parameters
Parameters like engine speed often fluctuate rapidly. When configuring the logging system:
- Set a high sampling rate (e.g., 100 Hz or higher) to capture transient events accurately.
- Filter out noise and low-priority IDs that do not contribute to the core diagnostic data set.
Troubleshooting CAN Data Logging Errors
| Symptom | Potential Cause(s) | Action/Verification |
|---|---|---|
| No Data Captured for an ID | 1. The ECU uses a proprietary or undocumented message. 2. The required diagnostic service was not properly executed to trigger the transmission. |
Verify connectivity and re-run the active probing sequence (Step 3). Check vehicle fault codes—some parameters may be disabled if a major system warning is present. |
| Data Values Are Unrealistic | 1. Incorrect scaling factor or offset applied during post-processing. 2. The parameter value resides in a different byte than initially assumed (Bit Shift error). |
Cross-reference the observed raw digital values against known technical specifications for that vehicle model and ECU hardware revision. |
| Intermittent Data Loss | 1. High bus load from other components (e.g., infotainment system running background processes). 2. Physical wiring issue (poor shielding, bad connection). |
Check the electrical integrity of the physical connection point. If the issue persists, consider logging on a separate, dedicated CAN gateway port if available. |
| Missing Specific Parameter | The parameter may only be transmitted when specific operational conditions are met (e.g., high boost pressure only occurs under aggressive acceleration). | Repeat Step 3 while intentionally stressing the system to force the ECU to report the desired data point. |
Always prioritize safety when integrating external logging systems with active vehicle electrical networks. Ensure all connections meet proper voltage and current specifications for the target CAN bus.