Communication in Automotive Networks Illustrated with an Example of Vehicle Stability Program: Part I - Control Area Network

 Abstract —The design of DAS (Direct Adaptive Steering) systems has been used in aviation for a long time. A few months ago a Japanese automotive company, Nissan Motor Co, for the first time introduced a steer-by-wire (no mechanical connection between the steering wheel and the front wheels of the car) solution - to the automotive world in their Infiniti Q50 car. This article aims to explain the issues related to controlling the car automation system, in which one of the control parameters is the examined turn of the wheels assigned by the driver ( or the DAS system).


I. INTRODUCTION
FEW weeks ago the Japanese company Nissan Motor Co. launched a new model of Infiniti car, the Q50 version, in which the virtual steering column was used for the first time in the world. It appears that the application of the DAS (Direct Adaptive Steering) system, in which the steering wheel is not physically connected to the front wheels, is a watershed moment for the entire automotive industry. Despite the fact that similar solutions have been used for a long time in aviation, no one in the automotive industry has had the appropriate technology or the courage to introduce the DAS system to a stock car.
The turn of car wheels assigned by the driver (in the analyzed case by using the DAS system) is analyzed by a number of systems and sensors related to driving safety.
ESP (Electronic Stability Program) is one of the most important safety systems based on the measurement of the turn of the wheel/steering wheel, to which a "wake" against falling of a car out of a given track is coupled; This article aims to explain the principles of adaptive control systems of a motor vehicle, depending on the assigned turn of the steering wheel.
These control systems use, inter alia, communication technologies implemented in fast on-board automotive networks, such as TTCAN (Time Triggered Control Area Network), TTP, Time Trigger Protocol or FlexRay.

II. AUTOMOTIVE INFORMATION NETWORKS
The development of information and microprocessor technology has been reflected also in the control of car automation systems. The introduction of communication buses and high-integration microcontrollers allowed to control and monitor virtually every mechanical system of a motor vehicle.
The figure below shows the contemporary communication networks installed in cars. Gateway is a system for providing communication between the different types of networks. Based on [6] One of the most important criteria for the evaluation of a network is its speed of operation. Due to the speed of data transmission various types of networks are used to handle the relevant systems and events associated with them. Onboard networks have also evolved and currently the most common types of networks are: LIN (Local Interconnect Network) running at speeds up to 125 kb/s. It supports connections of actuators and sensors (such as air conditioning, car interior lighting, seating arrangement or mirrors). Referred to as A class.
CAN (Controller Area Network -low speed) running at speeds up to 500 kb/s. It supports the connection of controllers operating in additional equipment systems in the vehicle. Referred to as B class.

Communication in Automotive Networks Illustrated with an Example of Vehicle Stability
Program: Part I -Control Area Network TTCAN (Time-Triggered CAN -high speed) running at speeds up to 10 Mb/s. It supports connections of powertrain and steering systems controllers. It is the basic network related to active and passive car safety. It supports on-board systems such as ABS, ASR and ESP.

Referred to as C + class
FlexRay -the latest network, similar to TTCAN, running at speeds of 10 Mb/s. It is the network of the highest reliability and speed of transmission. It is used in safety and steering control systems in real time mode. It supports analogous systems as the TTCAN network. Also referred to as C + class. [1] MOST (Media Oriented Systems Transport) -working at speeds up to 25 Mb/s. It supports multimedia transmissions. It implements connections of drivers in telematics systems. Referred to as D class. [1] III. STANDARDS IN ON-BOARD NETWORKS The first action of standardizing the work of automotive components was the introduction of the OBD II standard 1 the purpose of which was to establish the technical and legal requirements that define the diagnostics.
Communication system and the development of standards for diagnostic communication and communication procedures designed both for diagnosed components and the user.
The OBD II standard sanctioned the diagnostic standardization process and therefore on-board communications, thereby contributing to the development of systems that meet the defined requirements. (e,g, standard DLC connector with the communication standard). It was also the beginning of the standardization of information exchange with the user, and the standard diagnostic fault code sets gave rise to the development of off-board systems for car diagnosis. Off-board systems are becoming increasingly available telematics services.) [3,4] The flow of information in on-board networks, as in wide area computer networks, describes and standardizes the ISO OSI model (Open System Interconnection). According to that model, it is possible to separate different tasks of data transmission into the following layers: (1) Physical, (2) DataLink (3) Network (4) Transportation (5) Session (6) Presentation (7) Application. Data flows from the Application layer into the correct transmission layer, i.e the Physical layer. Model approach to transmission allows us to understand rules for the transmission of information between the sender and the receiver. However, not all layers of the OSI model for different types of networks have defined standards. Similarlyfor the same tasks there are many standards. Often these are only the manufacturer's (a consortium of manufacturers) standards. Transmission tasks in CAN networks in terms of the ISO -OSI model for the physical, data link layer and application layers are shown in Figure 5. Systems/networks that support real-time tasks, such as controlling the engine, brakes and steering system or the drive must meet the highest requirements for speed and reliability. Exchange of information from sensors translating into the online adjustment of multiple systems setting must be short, fast, reliable, and repeated with high frequency and with a short time delay. CAN (Control Area Network C +) meets such requirements.
However, a request to access the bus by several microcontrollers simultaneously can be a certain speed and reliability limit in a CAN network. This problem is quite an old issue known in the automation and control networks and referred to as the concept of arbitration.
In the automotive CAN networks the problem is solved by CSMA/CA (Carrier Sense Multiple Access /Collision Avoidance) arbitration, i.e in accordance with the priorities assigned to individual nodes in the network for bus access. Arbitration can be solved by either hardware, software or by using the so-called TDMA time slots. (Time Division Multiple Access) 3 The time slot bus access method in CAN networks was the basis for the development of their next-generation networks, i.e TTCAN (Time-Triggered CAN in the ISO 11898-4 standard) and TTP (Time-Triggered Protocol) in the standard of consortium of manufacturers) (see Fig.4); 3 Similar solutions are used in GPRS large wireless data transmission networks [5] where the transmission of information occurs in strictly allocated time slots. T he principle of time slots is described later in this paper.
By obtaining almost 10 times the baud rate in TTP and FlexRay networks, as well as very high reliability, the use of x-by-wire steering became possible in cars.
The introduction of a steer-by-wire solution for the first time a few weeks ago in the Infiniti Q50 car would not be  possible if not the previously available communication  solutions such as TTP or FlexRay 4 IV. CAN BUS. SELECTED ISSUES

A. Construction
The most common bus used in automotive industry is the CAN (Control Area Network) bus 5 working in connection topologies as in Fig. 6 a. Connecting model -bus topology b. Connecting model -star point topology Communication in CAN networks is done in a serial and asynchronous manner along the bus, which consists of two conductors (twisted pair). Other transmission media are optical fiber and radio link. Transmission speed depends on the length of the bus (see Table 2) and is the result of the duration of one bit. It is expressed by the formula: The frequency of the waveform calculated on the basis of the duration of the bit (see Figure 7) is: where Tbit = 8 μs Figure 7. Duration of the bit [7] The signal in CAN networks is present in the form of the difference between two voltages on the wires CAN_H and CAN_L. (The applied differential method eliminates interference which are eliminated as a result of the deduction). The main role in the exchange of information in CAN networks is played by nodes that have the "classic" microcontroller, CAN transceiver and CAN controller in their structure. Two basic states should be recognized in the work of the node. Send (1) and receive (2) information.
(ad.1) On the basis of the signal from the sensor the microcontroller generates a set of data for another subscriber in the network to trigger the respective actuators. 6 This data are formed into transmission frames in the CAN-Controller system, and sent to the bus in the form of suitable electrical voltages by using the CAN Transceiver.
(ad.2) When a node receives information, signals from the bus are translated in the CAN-Transceiver and then CAN-Controller part to the format accepted by the microcontroller. The CAN Controler Architecture is shown on figure 10.
Both the transceiver and controller are high-integration electronic circuits manufactured with the latest technologies, such as FPGA (Field Programmable Gate Arrays) 7 .

B. Data transmission
Transmission of information from any node is done by diffusion to all controllers using broadcast or to their subgroup using multicast. (Fig. 11) Figure 11. Multicast communication

C. Data directing messages on the network
In every message sent from a node there is addressing data which tells about the message destination. There are two types of addressing in the CAN networks: (1) -addressing by the device identifier (an identifier of the destination node is given in the header of the message) and (2) addressing by the message identifier. Depending on the type of data, only the nodes for which the transmitted information is useful can collect the message (for example, an information on the rotational speed of the wheels.) a. subscriber-oriented (node address) b-message oriented 8 (message identifier) Figure 12. Methods of addressing. 8 Examples of message identifiers are: 2 -signal, 3 -brake lights, 4cornering lights, 6 -fuel level, C (hex) -the state of the passenger door, etc

D. Access to the bus
A key issue to be resolved in the network data transmissions is a decision which node at any given time is entitled to occupy the bus for the purpose of transmitting its messages.
One of the methods of accessing the bus is the event-driven method. The method involves sending a message by a node when a specific event occurs, such as turning the air conditioning on. The important thing is for the transmission to proceed uninterrupted, and the message which appeared on the bus to reach the destination in its entirety.
Events are not always predictable, which means that at any given moment more than one controller /node may require the access to the bus. In order to avoid collisions while accessing the bus, the arbitration method is used, which consists of assigning priorities to events. The event with the highest priority wins the arbitration.
There is a possibility that a low priority event may never be handled. The method of arbitration is shown in Figure 13   Bit RTR -is a remote transmission request (must be 0 (dominant) in a data frame Bit SRR -is the equivalent of RTR and must be recessive (= 1) IDE field distinguishes whether the identifier is extended and should be recessive (= 1) in the extended frame The newest, fastest and most reliable method of bus access method is the time-division multiple access (TDMA) method, applicable especially in on-line controlling of the steering system of a car. In this method, individual controllers are allocated time slots in which they can transmit their messages. These moments are specified at the time of their design. All nodes transmit messages at a certain time, and then the cycle repeats. Depending on the message, time slots which are larger or made at shorter intervals can be assigned.
If the controller does not have data to send, then its time slot remains empty. In this method, it is known in advance when and which controller occupies the bus. Collisions do not occur, however, all controllers must be precisely synchronized. (Fig.15) Due to its high reliability, the TDMA bus access method is used in real-time systems. 9 Examples of applications are TTCAN bus systems (time triggered CAN bus) and FlexRay.

E. Messages in CAN networks
Messages are sent in the form of strictly-defined frames. Four types of frames are identified, e,g Data Frame, Remote Frame, Error Frame and Overload Frame. The frame containing the relevant measurement/control data is the Data Frame containing seven fields shown in Figure 16.
Depending on the quantity of transferred data, nonseparated frames for data not exceeding 7 bytes), Fig.16, and separated frames for transmission of data exceeding 7 bytes 10 , Fig. 17 (according to [2]), are applied. 9 T DMA methods was described in [1] (pp.179-181) 10 Details related to transferring frames have been determined by all European motor-cars manufacturers. T he example of transfer frame, which has been discussed, corresponds to the frames applied in diagnostic systems. [2] Figure 16. Structure of non-separated message and its transfer First four binary units of the first byte, so called PCI (Protocol Control Information), inform that it is a single frame whereas all remaining 4 binary units (DL) represent the length of data field. Reception, by the receiver, of the first byte of information enables explicit determination of the quantity of bytes of information that will be transferred to it.
The transfer exceeding 7 bytes is completed through separated message, Fig.17 Firstly, FF (First Frame) is transferred through producer. A specific controller responses or refuses to respond with request for readiness to receive messages (Flow Control Frame). If the receiver responses with readiness request, then all remaining data is transferred as part of Consecutive Frames. PCI bytes produced by FCF and CF frames inform about the type of transferred frames. Structure of separated message. (Fig.18 a, b and  The first frame consists of PCI byte that includes the information that FF (First Frame) is being transferred. Four last binary units of PCI byte constitute extended information related to data length. Along with DL byte the data may code 0 to 4095 of the values.

CONCLUDING REMARKS
Taking above into consideration, it must be stated that the communication within on-board CAN networks may be described by the following features: manners for addressing the information recipients, manners for arbitration solving, length of data to be transferred, and applied technology for the access to the bus. All these features determine programming transmission between controllers. Offered CAN modules are high-scale integrated circuits that require deep knowledge and acting logically when programmed. The following, second, part of this article describes application of CAN network for adaptation control of systems for travel safety that are based on, among others, measurement of steering wheel/wheels turn. This turn, applied in modern solutions 11 , is requested by another steer -by-wire (minimum driver's action) circuit. 11 model of Infiniti car, the Q50 version , Nissan Motor Co