logo elektroda
logo elektroda
X
logo elektroda
Dostępna jest polska wersja

Czy wolisz polską wersję strony elektroda?

Nie, dziękuję Przekieruj mnie tam

CAN Bus in Cars - How Controller Area Network Works in ECUs

User question

How does CAN bus system work in cars?

Artificial Intelligence Response

Direct answer to the question

A CAN bus — Controller Area Network — is the communication network that lets the electronic modules in a car talk to each other over a shared pair of wires instead of using separate wires for every signal.

In a car, ECUs such as the engine controller, transmission controller, ABS module, airbag module, body control module, instrument cluster, and steering system exchange short digital messages over the CAN bus.

Key ideas:

  • CAN uses two wires, called CAN High and CAN Low.
  • Signals are sent using differential voltage, which makes the system resistant to electrical noise.
  • All ECUs connected to the bus can “hear” all messages.
  • Messages are not addressed to a specific ECU; instead, they contain an identifier that tells other ECUs what the message means.
  • If two ECUs try to transmit at the same time, the message with the higher priority automatically wins without corrupting the data.
  • CAN includes strong error detection, acknowledgement, and retransmission mechanisms.

In simple terms: CAN bus is the car’s internal digital communication backbone.


Detailed problem analysis

1. Why cars need CAN bus

Modern vehicles contain many electronic control units, commonly called ECUs. Examples include:

ECU Typical function
Engine Control Module Fuel injection, ignition, torque control
Transmission Control Module Gear shifting
ABS / ESC module Wheel speed monitoring, braking control
Airbag ECU Crash detection and restraint deployment
Body Control Module Lights, locks, windows, wipers
Instrument cluster Gauges and warning lamps
Power steering ECU Steering assist
Climate control ECU HVAC control
Infotainment unit Media, navigation, display

Before networked vehicle electronics, signals were often sent with dedicated wires. For example, if the engine ECU needed to send engine speed to the dashboard, transmission ECU, and traction control system, it might require multiple separate signal paths.

CAN solves this by allowing one ECU to broadcast a message once, and multiple other ECUs can use it.

Example:

  • Engine ECU sends:
    “Engine speed = 2500 rpm”
  • Instrument cluster uses it for the tachometer.
  • Transmission ECU uses it for shift decisions.
  • Stability control may use it for torque control.
  • Other modules ignore it if they do not need it.

This reduces:

  • wiring complexity,
  • harness weight,
  • connector count,
  • cost,
  • failure points.

This is especially important because wiring harnesses are among the heaviest and most complex parts of a modern vehicle.


2. Physical layer: CAN High and CAN Low

A typical high-speed automotive CAN bus uses a twisted pair of wires:

  • CANH — CAN High
  • CANL — CAN Low

The two wires carry opposite voltage changes. The receiver does not mainly care about the voltage of each wire relative to chassis ground. Instead, it measures the difference between CANH and CANL.

This is called differential signaling.

Typical classical high-speed CAN voltage levels are approximately:

Bus state Logic value CANH CANL Differential voltage
Recessive 1 ~2.5 V ~2.5 V ~0 V
Dominant 0 ~3.5 V ~1.5 V ~2 V

The exact values can vary slightly depending on the transceiver and vehicle, but the concept is the same.

The important rule is:

  • Dominant bit = logic 0
  • Recessive bit = logic 1

A dominant bit overrides a recessive bit on the bus. This is fundamental to CAN arbitration.


3. Why differential signaling is used

Cars are electrically noisy environments. They contain:

  • ignition coils,
  • alternators,
  • electric motors,
  • relays,
  • injectors,
  • solenoids,
  • high-current switching loads,
  • DC/DC converters,
  • inverters in hybrid and electric vehicles.

If noise couples into both CAN wires equally, the receiver largely rejects it because it measures:

\[ V{diff} = V{CANH} - V_{CANL} \]

For example, suppose electrical noise adds +0.5 V to both wires.

Recessive state:

\[ CANH = 3.0V,\quad CANL = 3.0V \]

The differential voltage is still:

\[ 3.0V - 3.0V = 0V \]

So the receiver still sees a recessive bit.

That is why CAN is much more robust than a simple single-ended signal wire.


4. Termination resistors

A proper high-speed CAN bus has termination resistors at the two physical ends of the main bus.

Usually:

  • one 120 Ω resistor at one end,
  • one 120 Ω resistor at the other end.

Since they are in parallel, the resistance measured between CANH and CANL on an unpowered healthy bus is usually about:

\[ R_{total} = 120\Omega \parallel 120\Omega = 60\Omega \]

This is a common diagnostic check.

The terminations serve two main purposes:

  1. Prevent signal reflections
    CAN edges are fast enough that long wiring behaves like a transmission line. Without correct termination, reflections can distort bits.

  2. Maintain signal integrity
    Proper termination helps the differential signal remain clean at high bit rates.

Typical diagnostic interpretation:

Measured resistance between CANH and CANL Possible meaning
~60 Ω Both terminators likely present
~120 Ω One terminator missing or disconnected
Very low resistance Short between CANH and CANL
Infinite/open Bus wiring or both terminators open

This measurement should usually be done with the vehicle powered down and modules asleep, following the manufacturer’s service procedure.


5. CAN is a broadcast network

CAN does not work like a typical computer network where every message has a source and destination IP address.

Instead, CAN is message-based.

A CAN frame contains an identifier, often called the CAN ID. The ID describes the meaning and priority of the message.

For example:

CAN ID Possible meaning
0x100 Engine speed and torque
0x180 Wheel speeds
0x220 Coolant temperature
0x300 Door and lock status
0x3F0 Dashboard warning lamp status

These IDs are examples only. Actual IDs are manufacturer-specific unless they are part of a standardized diagnostic protocol.

Every ECU connected to the bus receives the message electrically, but each ECU filters messages based on ID.

For example:

  • The instrument cluster may accept engine speed messages.
  • The transmission ECU may accept engine torque messages.
  • The door module may ignore both.

This makes CAN efficient because one transmitted message can be used by many receivers.


6. CAN frame structure

A classical CAN data frame contains several fields.

Simplified structure:

Field Purpose
Start of Frame Marks the beginning of a CAN message
Arbitration Field Contains the message ID and priority information
Control Field Contains information such as payload length
Data Field Contains the actual data, 0 to 8 bytes in classical CAN
CRC Field Error-checking code
ACK Field Receivers acknowledge valid reception
End of Frame Marks the end of the message

Classical CAN supports two main identifier formats:

Format Identifier length
Standard CAN, CAN 2.0A 11-bit ID
Extended CAN, CAN 2.0B 29-bit ID

Classical CAN payload length is up to 8 bytes.

Example CAN frame conceptually:

ID: 0x100
DLC: 8
Data: 09 C4 1A 00 5F 20 00 00

The raw bytes need interpretation according to the vehicle manufacturer’s database, often called a DBC file in engineering contexts.

For example, two bytes might represent engine speed:

\[ RPM = \frac{RawValue}{4} \]

If the raw value is 10000:

\[ RPM = \frac{10000}{4} = 2500 \]

The CAN bus itself does not know that the value means “2500 rpm.” It only transports bytes. The meaning is defined by the vehicle’s communication specification.


7. Arbitration: how CAN avoids collisions

One of the cleverest parts of CAN is its arbitration system.

Because all ECUs share the same wires, two modules may try to transmit at the same time. CAN handles this automatically using non-destructive bitwise arbitration.

The rule is:

  • dominant 0 overrides recessive 1,
  • every transmitting ECU also listens to the bus while transmitting,
  • if an ECU sends recessive 1 but reads dominant 0, it knows it lost arbitration,
  • the losing ECU stops transmitting and waits,
  • the winning ECU continues without its message being corrupted.

Priority is based on the CAN ID:

  • lower numerical CAN ID = higher priority.

Example:

Suppose two ECUs start transmitting at the same time.

ECU A ID: 0b0010 0000 000
ECU B ID: 0b0100 0000 000

They transmit bit by bit. At the first bit where one sends 0 and the other sends 1:

  • ECU A sends dominant 0.
  • ECU B sends recessive 1.
  • The bus becomes dominant 0.
  • ECU B sees that the bus does not match what it transmitted.
  • ECU B stops.
  • ECU A continues.

The message is not destroyed. This is why CAN arbitration is called non-destructive.

This mechanism allows safety-critical or time-critical messages to be assigned high priority.

For example:

Message type Typical priority
Brake/ABS/stability control data High
Engine torque control High
Steering data High
Body comfort features Medium/low
Window switch status Low
Seat adjustment Low

8. Error detection and reliability

CAN was designed for harsh real-time environments, so it has multiple error-detection mechanisms.

Common error checks include:

Error type Meaning
CRC error Received data does not match the checksum
Bit error Transmitter reads a different bit than it sent
Stuff error Bit-stuffing rule violated
Form error Fixed-format part of the frame is invalid
ACK error No receiver acknowledged the message

CAN also uses bit stuffing. After five consecutive bits of the same value, the transmitter inserts a bit of the opposite value. This guarantees enough signal transitions for synchronization.

If a node detects an error, it transmits an error frame, which causes all nodes to discard the corrupted message. The transmitter then retries later.

CAN also has fault confinement. Each node maintains internal error counters:

  • Transmit Error Counter
  • Receive Error Counter

Depending on these counters, a node may enter different states:

State Meaning
Error active Normal operation
Error passive Node has seen many errors and reduces its ability to disturb the bus
Bus-off Node disconnects itself logically from the bus to protect the network

This prevents one faulty ECU from continuously destroying communication for all other modules.


9. Typical CAN bus speeds in cars

Different CAN networks in a vehicle may operate at different speeds.

Typical values:

Network type Typical speed Typical use
High-speed CAN 500 kbit/s to 1 Mbit/s Powertrain, chassis, ABS, stability control
Medium-speed CAN 125 kbit/s to 250 kbit/s Body electronics
Low-speed/fault-tolerant CAN ~40 kbit/s to 125 kbit/s Comfort systems, older body networks

A vehicle may contain several CAN buses, for example:

  • powertrain CAN,
  • chassis CAN,
  • body CAN,
  • diagnostic CAN,
  • infotainment CAN.

These buses are often connected through a gateway module.

The gateway decides which messages should be passed between networks. For example, engine speed from the powertrain CAN may be forwarded to the instrument cluster on another bus.


Current information and trends

CAN remains widely used in vehicles because it is robust, inexpensive, deterministic enough for many control functions, and well understood by manufacturers and suppliers.

However, modern vehicles now require much more bandwidth because of:

  • advanced driver-assistance systems,
  • cameras,
  • radar,
  • lidar,
  • infotainment,
  • over-the-air updates,
  • electrified powertrains,
  • centralized vehicle computing,
  • software-defined vehicle architectures.

Because of this, CAN is increasingly used together with newer networks.

CAN FD

CAN FD, or CAN Flexible Data-rate, is an extension of classical CAN.

Compared with classical CAN:

Feature Classical CAN CAN FD
Payload Up to 8 bytes Up to 64 bytes
Arbitration phase Same CAN-style arbitration Same CAN-style arbitration
Data phase speed Usually same as arbitration Can be faster
Use case Traditional vehicle control Higher data volume control and diagnostics

CAN FD is useful when systems need more data per message but still want CAN-like robustness and arbitration.

Automotive Ethernet

Automotive Ethernet is increasingly used for high-bandwidth systems such as:

  • cameras,
  • radar,
  • lidar,
  • infotainment,
  • centralized computing,
  • high-speed diagnostics,
  • zonal architectures.

CAN is not disappearing; rather, it is becoming one layer in a mixed in-vehicle network. Safety and body-control messages may still use CAN or CAN FD, while high-bandwidth sensor data may use Ethernet.

LIN and other buses

CAN is also commonly used alongside LIN, or Local Interconnect Network.

LIN is:

  • cheaper,
  • slower,
  • usually single-wire,
  • master-slave rather than multi-master,
  • used for simple devices.

Typical LIN applications:

  • mirror motors,
  • seat motors,
  • rain sensors,
  • door switches,
  • HVAC flap actuators.

In many vehicles, a door module may communicate with the main vehicle network over CAN, while controlling smaller local devices over LIN.


Supporting explanations and examples

Example 1: Engine speed sent to dashboard

  1. Engine ECU measures crankshaft speed.
  2. It formats a CAN message with a specific ID.
  3. The CAN controller sends the frame.
  4. The CAN transceiver drives CANH and CANL.
  5. All ECUs receive the frame.
  6. The instrument cluster recognizes the ID.
  7. The cluster extracts the rpm value and moves the tachometer needle or updates the display.
  8. Other ECUs ignore the message unless they need it.

Example 2: ABS and engine torque reduction

During wheel slip:

  1. ABS/ESC module detects different wheel speeds.
  2. It broadcasts a traction-control message.
  3. Engine ECU receives the message.
  4. Engine ECU reduces torque by adjusting throttle, ignition, or fuel.
  5. Transmission ECU may modify shift behavior.
  6. Instrument cluster may illuminate a traction-control indicator.

All of this happens through CAN frames.

Example 3: Diagnostic scan tool

A diagnostic scan tool connects through the OBD-II port. In many vehicles, high-speed CAN is available at:

OBD-II pin Function
Pin 6 CAN High
Pin 14 CAN Low

The scan tool sends diagnostic requests. ECUs respond with diagnostic trouble codes, live data, identification information, or test results.

For example:

  • The scan tool asks the engine ECU for stored fault codes.
  • The engine ECU replies with codes such as misfire, oxygen sensor, or communication faults.
  • The scan tool displays the result to the technician.

Practical guidelines

Basic CAN troubleshooting approach

A technician or engineer usually checks the CAN system in stages.

1. Visual inspection

Look for:

  • damaged wiring,
  • water intrusion,
  • corrosion in connectors,
  • aftermarket accessories spliced into CAN wires,
  • accident damage,
  • poor grounds,
  • pinched harnesses.
2. Resistance check

With power off and the system safely isolated:

  • measure resistance between CANH and CANL,
  • expect around 60 Ω on a correctly terminated high-speed CAN bus.

Abnormal readings can indicate:

  • missing terminator,
  • short circuit,
  • open circuit,
  • incorrect module or harness connection.
3. Voltage check

With power on, typical idle voltages may be around:

  • CANH: approximately 2.5 V,
  • CANL: approximately 2.5 V.

During communication:

  • CANH toggles upward,
  • CANL toggles downward.

If one line is stuck at battery voltage, ground, or an abnormal fixed voltage, there may be a short or failed transceiver.

4. Oscilloscope test

An oscilloscope is the best tool for seeing CAN signal quality.

A healthy CAN waveform should show:

  • clean differential switching,
  • CANH and CANL moving in opposite directions,
  • no excessive ringing,
  • no severe rounding,
  • no large noise spikes,
  • no stuck dominant state.
5. Scan tool communication

A diagnostic scan tool can show:

  • which modules are online,
  • stored communication fault codes,
  • live data availability,
  • network gateway status,
  • bus-off or no-communication faults.

Common diagnostic trouble codes include U-codes, such as network communication errors.


Possible disclaimers or additional notes

CAN is not the same as OBD-II

CAN is a network protocol used inside the car.

OBD-II is a diagnostic standard/interface. Many modern OBD-II systems use CAN as the physical and data-link layer for diagnostics, but CAN and OBD-II are not identical.

CAN messages are manufacturer-specific

Many normal vehicle CAN messages are proprietary. Without the manufacturer’s database, the raw data may be difficult to interpret.

For example, a frame such as:

ID: 0x218
Data: 34 A1 00 7F 12 00 00 00

does not mean much unless you know:

  • which signal starts at which bit,
  • byte order,
  • scaling factor,
  • offset,
  • units,
  • valid range.

This decoding information is usually contained in engineering databases such as DBC files.

Security matters

Traditional CAN was designed for reliability, not cybersecurity. Most classical CAN frames do not include encryption, authentication, or source verification.

That means if an attacker gains access to the bus through a compromised module, diagnostic connector, telematics unit, or poorly designed aftermarket device, they may be able to inject malicious messages.

Modern vehicles mitigate this with:

  • secure gateways,
  • message authentication in higher-level protocols,
  • intrusion detection,
  • secure diagnostics,
  • network segmentation,
  • hardware security modules,
  • controlled access to safety-critical buses.

Brief summary

A CAN bus in a car is a robust two-wire communication system that allows many ECUs to exchange short digital messages over a shared network.

The essential principles are:

  • CANH and CANL carry differential signals.
  • Dominant 0 overrides recessive 1.
  • All ECUs listen to all messages.
  • The message ID defines meaning and priority.
  • Lower ID values usually have higher priority.
  • Arbitration allows multiple ECUs to attempt transmission without corrupting the winning message.
  • CRC, acknowledgement, error frames, and fault confinement make CAN reliable.
  • Modern vehicles often use several CAN buses connected by gateways.
  • Newer systems increasingly combine classical CAN with CAN FD, LIN, and Automotive Ethernet.

In practical terms, CAN bus is the reason a car’s engine controller, brakes, dashboard, body electronics, and diagnostic systems can coordinate quickly and reliably using only a small number of wires.

Ask additional question

Wait...(2min)
Disclaimer: The responses provided by artificial intelligence (language model) may be inaccurate and misleading. Elektroda is not responsible for the accuracy, reliability, or completeness of the presented information. All responses should be verified by the user.