Core Reference

CAN Decoding and Input Mapping Internals

How selected setup signals become control telemetry in real-time across legacy PQ and Gen 5 MQB platforms.

Mapping key contract

Input mappings are stored and transferred as normalized keys:

bus|frameId|signalName|unit

Binding resolution path

  1. Setup writes mappings through POST /api/settings.
  2. Runtime refresh checks if source key changed for each input binding.
  3. Key is parsed into bus/frame/signal/unit tokens.
  4. Bus token resolves to enum (ANY, CHASSIS, or HALDEX).
  5. Frame token resolves to integer frame id.
  6. Selected Haldex generation chooses the active DBC family before signal lookup.
  7. Signal lookup resolves DBC descriptor by frame id plus normalized name/unit.
  8. Binding becomes ready when descriptor exists and key is valid.

Generation-aware DBC selection

Frame-to-value decode checks

A binding applies only when all checks pass:

Mux behavior

If mapped signal is muxed, runtime fetches mux selector signal for the frame id, decodes selector, then verifies selector equals mapped signal mux value before using the signal.

Freshness and fallback semantics

Control implication

Dynamic mode calculations consume received_vehicle_speed, received_pedal_value, and received_vehicle_rpm. Mapping quality directly affects control quality.

Validation strategy for integrators

  1. Assign one required input at a time in setup.
  2. Select the correct generation first so PQ or MQB decode resolution matches the vehicle.
  3. Observe live value response on setup rows and diagnostics telemetry.
  4. Verify monotonic behavior under expected vehicle action.
  5. Save mappings only after all required inputs are coherent.
  6. Road-test in conservative mode before aggressive tuning.

Try the OpenHaldex Firmware Demo

Preview the real OpenHaldex firmware UI in your browser with simulated live CAN traffic and interactive pages for tuning, diagnostics, logs, setup, and OTA workflows.

Open firmware demo