Not every ECU needs CAN. A door module, a wiper or a headlight exchanges a few bytes now and then, and for those jobs the Local Interconnect Network, LIN, is cheaper: one wire, a simple transceiver and a microcontroller’s standard serial interface. In most applications LIN works as a sub-bus of CAN, often with the LIN commander built into the ECU that acts as the gateway.
The LIN Consortium published the first specification as version 1.3. Version 2.0 followed in 2003, version 2.1 in 2006, and version 2.2A in 2010, after the consortium had closed. Since 2016 LIN has been an international standard, the ISO 17987 series, and several of its parts were updated in 2025. The new edition calls the two roles commander and responder, where earlier versions said master and slave.
One wire and a pull-up
A LIN cluster is one commander and up to 16 responders on a single wire. The commander pulls the line up to the vehicle’s battery voltage through a resistor, typically 1 kΩ, and a diode; each responder has a 30 kΩ pull-up built into its transceiver. With nobody transmitting, the bus sits high: the recessive state. A node sends a dominant bit by pulling the line low. Transceivers usually work from 9 to 18 V; a typical vehicle has a 12 V battery system, some larger vehicles 24 V. The bit rate goes up to 20 kbit/s.
Every byte on the bus is framed the way a serial port frames it: a dominant start bit, eight data bits with the least significant bit first, and a recessive stop bit. That is why a LIN node can use a microcontroller’s standard serial interface rather than a dedicated protocol controller.
The commander keeps the schedule
LIN has no arbitration, because only the commander starts frames. It works through a schedule table and opens every frame with a header:
- Break: 13 dominant bit times, longer than any byte can produce, so every node recognizes the start of a frame, followed by a recessive break delimiter.
- Sync byte, 0x55: alternating ones and zeros. Responders measure the bit time from its edges, which is how they keep in step without a crystal oscillator.
- Protected identifier: a 6-bit frame ID plus two parity bits. IDs 0 to 59 carry signals, 60 and 61 carry diagnostics, 62 and 63 are reserved.
The node that publishes that ID answers with the response: one to eight data bytes and a checksum. The publisher can be a responder or the commander itself, since the commander also runs a responder task. LIN 2.x uses the enhanced checksum, the inverted 8-bit sum with carry over the protected identifier and the data; the classic checksum covers the data only, and the diagnostic frames always use it.
Because responders only speak when the header asks them to, LIN traffic is fully predictable. The price is a single point of failure: if the commander stops, the whole cluster stops, which is one reason LIN is not used for safety-related communication. Besides the ordinary unconditional frames, LIN defines event-triggered and sporadic frames to save bandwidth for signals that change rarely, and diagnostic frames, always 8 bytes long, for configuration and diagnostics.
LIN on a test rig
On a hardware-in-the-loop rig, the simulator plays whichever side of the cluster is not on the bench. To test a responder, such as a door module, the rig runs the commander’s schedule and stands in for the other responders. To test the commander, for example a body controller that also acts as the CAN gateway, the rig answers as every responder it expects to find. The schedule, frames and signals come from the cluster’s LIN description file, so the rig follows the same definition as the vehicle.
We integrate LIN into real-time systems with the same fault injection we use on CAN: responses that are missing or late, checksum and parity errors, and signals out of range, so you can see how the unit under test reacts. If you are bringing up a rig with LIN on it, get in touch.
Sources
- CAN in Automation, LIN standards and specifications
- NI, Introduction to the LIN Bus Protocol
- Texas Instruments, LIN Protocol and Physical Layer Requirements, SLLA383A
- Freescale Semiconductor (NXP), LIN demonstration application note, AN2103