You are on page 1of 64

Automotive Technology - II

In-Vehicle Communication

M. Muthukumar
Introduction

Multiplicity of controllers that are


increasingly networked together by various
bus communication
It contains crucial components and driving
aid system
Unlike a point to point connection a bys is a
communication system that can logically
connect several peripherals.
The consequential potential saving of cost
and weight encourage the increasing
application of bus
Cont…

Busses are easy to implement and to


extend, and failure of one node should not
affect others.
Bus system all nodes share the same
communication line, need for collision
handling or collision avoidance schemes
Bus systems have a limited cable length
and a limited number of nodes.
The performance of bus degrades the more
nodes are connected.
In-Vehicle Example
MUX Standards (speed Vs Cost)

25.6M D2B, MOST


token ring
optical bus
Byteflight
optical bus
2M
TTx (in definition)
time triggered
fault tol, dependable
2x2 wire
1M
CAN-C
event triggered
dual wire
125K
CAN-B
event triggered
fault tolerant
dual wire
20K
LIN
master-slave
single wire bus

1 2 4.5 10
incremental cost per node [$]
Local Interconnect Network

It is Universal Asynchronous Receiver Transmitter


(UART) based and typical data rates up to
20kbit/s.
Single master, multiple slave networking and lower
power consumption by sleep mode.
Incorrectly transferred messages detected by
parity and checksum.
Enables effective communication for sensor and
actuators where the bandwidth and versatility of
CAN is not required.
Synchronization mechanism mean no quartz
oscillator required at slaves.
No specific hardware requirement and license free
LIN Application

Steering Wheel – Cruise control, Wiper,


Turning light, Climate control, Radio
Roof - Rain Sensor, Light Sensor, Light
control, Sun Roof.
Engine/Climate – Sensor, Small Motors,
Control panel (Climate).
Door/Seat - Mirror, Central ECU, Mirror
Switch, Window Lift, Door Lock, Seat
Position Motors, Occupant Sensors and
Seat Control Panel.
Controller Area Network

Is an asynchronous serial bus network that


connects devices, sensors and actuators in
system or sub system for control.
Multi master communication, designed for
data rate up to 1Mbps and high levels of
data integrity.
High speed CAN up to 1Mbps and low
speed/fault tolerant CAN up to 125Kbps
(data traffic to continue in the event of a
wiring fault).
CAN Cont…

Messages are not have a recipient


address, classified over their respective
identifier.
It uses decentralized, reliable, priority
driven CSMA/CD access control.
In case of error the flag will initiates
retransmission of affected message.
It contains mechanisms for automatic fault
localization including disconnection of the
faulty controller.
CAN Application

Safety - Passenger Occupant Detection,


Electronic Parking Brake
Body Control – Motor Control, Power Door,
Sunroof and Lift Gate.
Chassis – Motor control, Watch Dog.
Power Train – Vacuum Leak Detection,
Electronic Throttle Control, Watch Dog.
Flex Ray
It is a time deterministic communications protocol and error
tolerant high speed with a dual channel data rate of up to
10Mbps for advanced application.
Dual channel architecture offers system wide redundancy
that meet reliability requirement of emergency system.
The flexible, expandable up to 64 nodes connected point to
point or over a classical bus structure.
Receiver selective bus system and uses the cyclic TDMA for
data control.
Synchronous for time critical data and asynchronous fro non
time critical data via freely configurable time segments.
Flex Ray Application

Wheel node – Fail safe, Low to


medium performance MCU
Body control Modules – High
performance, Low Power MCU
X-by- Wire - highest level of fault
tolerance
Properties of Bus systems
Approaches to Security

All transferred information can be seen and


received in clear only by the desired
parties.
Modern security mechanism provides
integrity and authentication based on
cryptographic algorithms and protocols.
All unauthorized messages may then be
processed separately or are just
immediately discarded. The every
controller need certificate to authenticate
itself against the gateway as a valid sender
Cont…

Certificate consist of identifier and public key and


authorization of the respective controller.
Gateway holds public keys all accredited OEM’s.
Fundamental step to improve security is
encryption of all vehicular data transmission.
All controller of local bus system share the same,
periodically updated, symmetric key to encrypt
their bus internal communication.
Asymmetric encryption provides the acquisition of
the symmetric key for newly added authorized
controller and carries out the periodic updates.
Secure Vehicular Communication
Cont…

Gateways should implement capable


firewalls.
Controller capable of implementing MACs
or digital Signatures, the rules of the
firewall are based on the authorizations
given in the certificate of every controller.
Controllers of lower restricted network such
as LIN or MOST should generally be
prevented from sending messages in to
high safety relevant bus system as CAN or
Flex Ray.
Specification of Protocols
CAN Protocol

Defines the physical and data link layers


Two standards
CAN 2.0A has 11 bit identifier
CAN 2.0B has 29 bit identifier
Details of CAN Communication

Physical layer
Frame Contents
Arbitration
Node Synchronization
Error Detection & Handling
Physical Layer

• Twisted pair wire


• Differential signal for noise rejection

DATA Frame Format


Frame Contents

SOF Start Of Frame bit


IDE Identifier extension bit
RTR Remote Transmission request bit
DLC Data Length Code
CRC Cyclic Redundancy Check
ACK ACKnowledge
EOF End Of Frame
Arbitration

Bits on bus are either recessive (high) or


dominant (low)
The first node to transmit a dominant bit
during arbitration gets the bus
Node Synchronization

Nodes synchronize oscillators on bit


edges
Bit-stuffing is used to ensure a
sufficient number of edges
Node Synchronization

Bit Stuffing
Bit stuffing is used to guarantee enough
edges in the NRZ bit stream to maintain
synchronization.
After five identical and consecutive bit
levels have been transmitted, the
transmitter will automatically inject (stuff)
a bit of the opposite polarity into the bit
stream.
Receivers of the message will
automatically delete (de-stuff) such bits.
Error Detection

Message Level
Cyclic Redundancy Checks
Frame Checks
Acknowledgment Checks
Bit Level
Bit Monitoring
Bit Stuffing
If any node detects six consecutive bits
of the same level, a stuff error is flagged.
Message Level Error Detection

CRC Each receiver calculates the CRC


from the message and checks against
received CRC.
If it does not match a CRC error is
flagged
Message Level Error Detection

Frame Format
CRC delimiter
ACK delimiter
End of Frame Bit Field
Interframe Space (the 3 bit INTermission
field and a possible Bus Idle time).
Message Level Error Detection

ACK Error Check


Each receiving node writes a dominant
bit into the ACK slot
If a transmitter determines that a
message has not been ACKnowledged
then an ACK Error is flagged.
ACK errors may occur because of
transmission errors, because the ACK
field has been corrupted or because
there are no operational receivers.
Bit Level Error Detection

Bit Monitoring
Each bit level (dominant or recessive) on
the bus is monitored by the transmitting
node.
Bit monitoring is not performed during
arbitration or on the ACK Slot.
Bit Level Error Detection

Bit Stuffing
The coding for bit stuffing requires that
five consecutive bits of the same level to
be followed by a complimentary bit level.
Six consecutive bits of the same level
cause a bit stuffing error
Error Flag

If a node detects an error, it terminates


transmission by transmiting an error flag
The error flag is six consecutive dominant
bits
All other nodes respond to the error flag
by transmitting an error flag
TTCAN

Communication can be ET or TT
Time slots are allocated
Reserved slot
Arbitration slot
Free slot
Requires global time synchronization
LIN Protocol

Master Task
Determines order and priority of messages.
Monitors Data and check byte and controls the error
handler.
Serves as a reference with its clock base (stable clock
necessary)
Receives Wake- Up Break from slave nodes

Slave Task
Is one of 2-16 members on the bus
Receives or transmits data when an appropriate ID is
sent by the master.
The node serving as a master can be slave.
Master
To accomplish this the master
sends Sync Break
sends Sync Byte
sends ID-Field
monitors Data Bytes and Check Byte, and
evaluates them on consistance
receives WakeUp Break from slave nodes when
the bus is inactive and they request some action.
serves as a reference with it’s clock base.
Slave

According to ID, slave determines what to do.


– either receive data
– or transmit data
– or do nothing.
When transmitting the slave
– sends 1, 2, 4, or 8 Data Bytes
– sends Check-Byte
Time Triggered Approach

Message Length is known


Number of transmitted data bytes is known
minimum length can be calculated
Each Message has length budget of 140% of it’s
minimum length
maximum allowed length is known
distance between beginning of two messages
Frame Format
Frame Format

Synch Byte:
Specific Pattern for Determination of Time Base
(Determination of the time between two rising edges)
A Synch Byte precedes any Message Frame
ID-Field:
Message Identifier, Incorporates Information about the
sender, the receivers, the purpose, and the Data field
length.
Length 6 Bit.
4 classes of 1/2/4/8 Data Bytes. The length coding is in
the
2 LSB of the ID-Field. Each class has 16 Identifiers. A
total of 64 Message Identifiers are possible.
2 Parity Bits protect this highly sensitive ID-Field.
Flex Ray (Time Triggered Protocol)
It is deterministic and error tolerant high speed
bus.
Supports up to 64 nodes connected point to
point or over a classical bus structure.
Synchronous transmission for time critical data
and asynchronous for non-time critical data via
freely configurable, static & dynamic time
segments.
Automatic fault localization, bus guardian used
for deactivation of controller by error
messages.
Security requirements
Redundant communications
Avoid collision for bus access
Option for variable geometry redundancy
Operates by a ‘never give up’ strategy,
thus ensuring that any unavailable
communication system automatically
disables distributed backup mechanism.
Application class
Class 1 – Communication with high
bandwidth
Class 2 – Deterministic communication with
high bandwidth
Class 3 – deterministic and redundant
communication with high bandwidth

Use of CAN as a sub-bus of Flex Ray and


use of LIN as a sub-bus of CAN.
Protocol Handling
Designed for communication system in
which collision for access to the medium
are impossible.
The physical layer does not provide any
means of resolving these collisions.
To communicate at a precise, known
instant for a known max time.
Communication at variable speed, thus
require an unspecified time
Cont…

Flex ray follows the TTCAN


‘communication cycles’
It combines two paradigms,
Time controlled
Event controlled
Communication cycle having
Static segment
Dynamic segment
Communication cycle
Communication Frame
Cont…

Header segment
Payload segment – useful data
Trailer segment - end of frame

Header – cycle count indicates the


number of the current communication
cycle and act as a continuity index
Payload field
Time overlap avoidance
Physical layer

Pair wire or optical fibers, version 2.0


of describes differential wire medium
Supporting two completely
independent channels of the physical
layer
Higher speed while network operating well
Functional redundancy of data transmission
– enhancing the fault tolerant aspect.
Cont…

Bit coding
Non return to zero, transmission of each
byte is framed by a start and stop bit
Bit rate
Nominal value of 100ns, implying a
gross bit rate of 100Mbps
Network topology will all have major
effects on quality of bit carried.
Fault tolerance mechanism

Redundancy – using two channels


message may be sent separately on both
channels in different slots.
Network topology

Point to point link


Link using a passive linear bus
Passive star
Active star
Cascaded active star
Hybrid solution
MOST (Media Oriented System
Transport)
Future automotive multimedia network for
transmitting audio, video and control via
optic cables.
Peer to peer network connect plug and play
up to 64 nodes in ring, star and bus
topology.
Similar to flax ray having static and
dynamic time segments for the
synchronous (up to 24Mbps) and
asynchronous (up to 14Mbps).
Cont…

MOST message always include sender and


receiver address.
Access control via Time Division Multiplex
respectively CSMA/CA.
Detects errors over parity bits, status flags
and checksums and disconnects erroneous
nodes if necessary.
One MOST device handles the role of the
timing master, which sends timing frames
that allow slaves to synchronize
MOST ring of Multimedia in car
Basic Frame Structure
Frame Format
Asynchronous Area
Control Message
Thank you…

You might also like