CAN#
Controller Area Network. A differential pair plus ground; message-based, multi-master, no addressing of nodes but addressing of messages. The protocol on every modern car’s OBD-II port, on industrial machines, and on robotics platforms. Reverse-engineer a car by capturing the CAN bus, isolating frames that change when the operator presses a button, and replaying them.
Wires#
Signal |
Direction |
Purpose |
|---|---|---|
|
Bidirectional |
High line of the differential pair; ~3.5 V dominant, ~2.5 V recessive. |
|
Bidirectional |
Low line; ~1.5 V dominant, ~2.5 V recessive. |
|
Reference |
Ground; not always run on short buses but recommended. |
Each end of the bus terminates with a 120 Ω resistor between
CANH and CANL.
Wire format#
Logic is dominant (0) and recessive (1); a dominant bit wins on the wire, which is how multiple transmitters arbitrate without a master. Frames carry an 11-bit (CAN 2.0A) or 29-bit (CAN 2.0B) identifier, up to 8 bytes of data (64 bytes in CAN FD), and a CRC.
Common speeds are 125 kbps (low-speed bodies, comfort buses), 500 kbps (high-speed powertrain), and 1 Mbps. CAN FD raises the data-phase bit rate to 5 Mbps or more.
SOF (1 bit), start of frame.
Identifier (11 or 29 bits), the message ID. Lower IDs win arbitration.
RTR / IDE / r0, control bits.
DLC (4 bits), data length code.
Data (0–8 bytes, or up to 64 in CAN FD).
CRC (15 bits) + delimiter.
ACK slot, the receivers’ acknowledgement.
EOF, end of frame.
Pads#
The OBD-II 16-pin J1962 connector is the operator’s most common entry point.
Pin |
Signal |
|---|---|
4 |
Chassis ground |
5 |
Signal ground |
6 |
|
14 |
|
16 |
Battery + (12 V) |
DB9 pinouts vary; the operator confirms with a meter before hooking up a transceiver.
Tools#
Tool |
Effect |
|---|---|
|
Linux SocketCAN userspace; capture, replay, fuzz. |
Linux |
In-kernel CAN stack; |
|
Vendor capture and replay tools. |
|
USB-to-CAN bridges; Macchina M2 is the operator’s OBD-II workhorse. |
|
Decode CAN captures ( |