Application of LIN bus technology in automobile intelligent lighting control system

Publisher:SHow111timeLatest update time:2010-05-06 Source: 同济大学 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

With the continuous development of modern electronic technology and its continuous application in automobile systems, various performances of automobiles have been greatly improved. Modern drivers and passengers have higher and higher requirements for various aspects of automobiles, such as vision, convenience, comfort and entertainment.

New control functions are increasing with the improvement of automobile grade, such as central door lock, lighting control, glass lifting, rearview mirror adjustment, sunroof control, seat adjustment and ignition delay control. Traditional control systems mostly use relays and independent mode control, which makes the wiring harness in the car too much and the wiring is complicated, thus causing serious electromagnetic interference and reducing the reliability of the system. The application of CAN/LIN bus technology replaces the traditional wiring harness, making information exchange safe, fast and efficient.

CAN (Controller Area Network) in automobiles is mainly used to exchange information between various electronic control units ECU on board to form an automotive electronic control network. Each control unit uses a specific bus technology to realize the transmission of digital/analog signals between the central control unit and the actuators and sensors. There is a dedicated channel for the transmission of each state or event. In order to transmit information from the central control unit to each subunit, each subunit should have a universal, standard open interface. The control actuators and sensor modules do not require very high transmission rates, such as rearview mirror positioning. All these low-rate modules do not need to use the CAN bus, but can choose a cheaper and more effective way than the CAN bus - the LIN bus.

LIN (Local Interconnect Network) is a new low-cost serial communication network for distributed electronic systems in automobiles. It was developed by automobile manufacturers and is specifically used in low-end systems as an auxiliary network or sub-network of CAN. In situations where the bandwidth and multi-function of the CAN bus are not required, such as communication between smart sensors and brake devices, using the LIN bus can greatly save costs.

At present, high/low speed CAN and J1850 buses have become standard automotive network buses. These buses are extremely high speed and have excellent performance such as high electromagnetic interference resistance and high transmission reliability, but the price is also high. A large number of applications in body and safety performance do not require high performance of automotive network buses, and only require a more cost-effective standard automotive network bus, and LIN bus can meet this demand. Therefore, LIN bus technology is currently being used more and more widely in body electronics.

This article will introduce the application of LIN bus technology in the automotive intelligent lighting control system. This article first introduces the overall functional design of the lighting control module based on the C167CS microcontroller and intelligent power devices, and then conducts an in-depth study on the specific implementation and application of LIN bus technology in the automotive intelligent lighting control system, including the hardware interface circuit design and software design of the LIN bus module.

1 Lighting control module design

This paper designs a car lighting control module based on Infineon C167CS microcontroller and intelligent power devices, as shown in Figures 1 and 2. The microcontroller uses Infineon's C167CS-LM (external expansion Flash). Submodule 1 is used to control the switching action of all power devices, and at the same time monitor the system status regularly and provide appropriate feedback signals. The feedback signal reflects the fault status of the car lights. Submodule 1 transmits the fault diagnosis information to submodule 2 through the LIN bus. Submodule 2 receives the fault diagnosis information from submodule 1 and displays it periodically through the LCD. Submodule 2 also processes the car light control information from the instrument panel and transmits it to submodule 1 through the LIN bus. Then submodule 1 acts on the corresponding power device according to the information on the instrument panel to realize the switch setting of the car lights.

The system uses LIN bus technology to achieve real-time transmission of car light information between two control modules. The LIN bus hardware interface circuit uses Infineon's TLE6258 bus LIN transceiver, which serves as an interface between the protocol controller and the physical bus and is particularly suitable for driving the bus in LIN systems in automotive and industrial applications. TLE6258 also provides an idle working mode to reduce current consumption, and has protection functions such as short-circuit protection and over-temperature protection.

Submodule 1 uses a large number of Infineon intelligent power devices, among which BTS724 and BTS716 are power MOSFET high-position switches (drain connected to power supply) with charge pump, input reference ground compatible with CMOS and diagnostic feedback, while BTS443 and BTS134 are single-channel FET power tubes, also known as low-position switches (source connected to power supply), and both high-position switches and low-position switches have built-in protection functions. The load can be resistive load, inductive load or capacitive load, and is most suitable for loads with high surge current, such as lights, thus replacing the traditional automotive lighting control method of traditional relays, fuses and discrete circuits, avoiding the use of too many discrete components, reducing the module size, and improving the EMC characteristics of the module. The module has protection functions such as short circuit protection, overload protection, current limiting, over-temperature shutdown, overvoltage protection, power reverse connection protection, ground drop and undervoltage protection and electrostatic protection.

2 LIN Bus Introduction

LIN bus is a serial communication network that can connect simple control devices such as switches, displays, sensors and actuators. It is mainly used in distributed electronic control systems in automobiles. LIN adopts a single-host/multi-slave bus topology (no bus arbitration) and uses only a 12V signal bus. The master node contains master tasks and slave tasks, and the slave node only contains slave tasks. It does not require a dedicated on-chip communication module and uses a standard serial communication interface USART with a rate of up to 20kbps and a bus length of no more than 40m. As an auxiliary bus network, LIN bus has a higher cost-effectiveness than CAN bus in situations where the superior performance of CAN bus is not required.

It has the following advantages.

● LIN is a low-end network system that provides a simple network solution, supports interoperability of network nodes, and greatly reduces the cost and time of system installation, debugging, and wiring.

● LIN has small communication volume and flexible configuration. It adopts single-line connection and single-master/multiple-slave communication structure (no bus arbitration required), which can ensure simple and fast real-time communication between low-end devices and electronic control units.

● LIN can be connected to the upper-layer network (such as CAN) through the host node to realize the sub-bus auxiliary communication function of LIN, thereby optimizing the network structure and improving network efficiency and reliability.

● The LIN protocol is open and can be obtained by any organization or individual without paying any fee.

The LIN specification consists of three main parts: the LIN protocol specification part (describing the physical layer and data link layer of LIN), the LIN configuration language part (describing the format of the LIN configuration file) and the LIN API part (describing the interface between the network and the application).

[page]

The communication mechanism and frame structure of the LIN protocol are shown in Figure 3. Each node in the LIN network has a slave task module, and the master node also contains a master task module. The frame header is sent by the master task, including the synchronization gap, synchronization field, and information identifier. The slave tasks in all nodes (including the master node) filter the information identifier and send back the data field and check field. The byte field uses the SCI/UART serial data format.

3 Application of LIN Bus Technology in Automobile Intelligent Lighting Control System

The control of the car lighting control module is actually realized based on the status information of the car lights and the driver's requirements for the status of the car lights. The status information of the car lights is mainly the feedback of fault information, and the driver's requirements for the status of the car lights are transmitted through the car light button on the instrument panel. In order to facilitate the installation of the whole vehicle, this car lighting control module is divided into two sub-modules, as shown in Figure 4. Sub-module 1 is responsible for controlling the switching action of the power device according to the status of the car light button on the instrument panel, while monitoring the status of the car lights, providing feedback signals, and judging the fault status of the car lights based on the feedback signals. Sub-module 2 is responsible for collecting the information of the car light button on the instrument panel, and using the LCD to display the current fault status information of the car lights.

The following is a specific analysis of the control concept of the automotive intelligent lighting control module and the application of LIN bus technology in it: After the system is started and initialized, submodule 1 starts a timer to periodically detect the lights output by digital diagnostic output and the lights output by analog current sensor diagnostic output (detecting the digital and analog fault signals fed back to the microcontroller by different intelligent switches). The information of the faulty lights is transmitted to submodule 2 through the LIN bus. The transmission information includes the name of the faulty light, the diagnostic group (digital diagnostic group or analog diagnostic group) where the faulty light belongs, and the fault status (open circuit or short circuit, etc.). Submodule 1 also receives the light button scanning information from the instrument panel of submodule 2, which contains the driver's requirements for the light status (on or off). Then, combined with the diagnostic results and the scanning results of the instrument panel, it decides whether to turn on or off the lights. Submodule 2 receives the fault diagnosis information of the lights transmitted by submodule 1 through the LIN bus and displays it periodically through the LCD. At the same time, it also periodically scans the button status of the scanner dial and transmits it to submodule 1 through the LIN bus.

As a low-end network of the vehicle body, the car lighting control module has a small amount of data transmission and does not require high transmission speed. 20kBaud can fully meet the system's requirements for transmission rate. Compared with the CAN bus, which has more excellent performance but is more expensive, the LIN bus has a lower cost, is easy to implement in UART, and has better fault tolerance and transmission reliability. After comprehensively considering the hardware and software costs of the bus and the reliability of the bus, the LIN bus is selected to realize the data transmission between the two sub-modules in the lighting control module, while the CAN bus is used for communication between the lighting control module and other ECUs in the vehicle body.

3.1 LIN bus hardware interface circuit

The LIN bus hardware interface circuit is shown in Figure 5. The module is divided into two units: the master node and the slave node. The power supply circuit is implemented using the Infineon TLE4278 voltage regulator, with an input Vi of 12V and an output Vq of 5V. The transceiver uses the Infineon TLE 6258 series LIN bus transceiver. From a safety perspective, the master node circuit connects a 1kΩ resistor and a 1nF capacitor between the power pin and the bus and between the bus and the reference ground, respectively, to ensure that the bus signal has a suitable time delay when switching between the dominant level and the recessive level.

[page]

TLE 6258 is a single-line transceiver suitable for LIN protocol, compatible with LIN specification 1.2, with a transmission rate of up to 20kbps, low power consumption, and short-circuit protection and over-temperature protection. It is particularly suitable for automotive and industrial applications, and can be used in standard ISO9141 systems. In order to reduce current consumption, TLE 6258 provides an idle mode. In idle mode, TLE 6258 exits bus activity, neither receives nor sends data, and the current is reduced to a minimum, thereby achieving the purpose of reducing current consumption. The switching process of TLE 6258 between normal working mode and idle mode is shown in Figure 6. In normal working mode, the idle mode is entered by setting ENN to 1. In idle mode, the host or slave can be awakened from idle mode and returned to normal working mode by sending a wake-up frame on the bus. After entering the normal working mode, ENN becomes 0, and RxD is released to transmit data state.

3.2 LIN bus communication software design

LIN software is based on several state mechanisms and function blocks. The state mechanism is called through the interrupt of the serial interface. Each state is represented by nTRANSCEIVER_STATUS in the program. The host task sends the synchronization interval field (Synch Break Field), the synchronization field (Synch Field) and the identifier field. If the slave detects a matching identifier on the bus, it will receive or send data to the bus (here it is assumed that the data bytes are 8, the host receives data, and the slave sends data. It can also be defined as the host sends data and the slave receives data). The following (1) to (3) are host tasks, and (4) to (13) are slave tasks.

(1) Sending a synchronization interval field;

(2) Receive the synchronization interval field and send the synchronization field;

(3) Receive the synchronization field and generate/send the ID field;

(4) Receive the ID field (message filtering), copy the data to the buffer (LIN transfer buffer) and send the first data byte;

(5) Receive the first data byte and send the second data byte;

(6) Receive the second data byte and send the third data byte;

(7) Receive the third data byte and send the fourth data byte;

(8) Receive the fourth data byte and send the fifth data byte;

(9) Receive the fifth data byte and send the sixth data byte;

(10) Receive the sixth data byte and send the seventh data byte;

(11) Receive the seventh data byte and send the eighth data byte;

(12) Receive the eighth data byte and calculate/send the checksum field;

(13) Receive checksum field.

In order to transmit the information required by the car intelligent lighting control module, 7 byte variables a0, a1, a2, a3, a4, a5 and a6 are defined to store the light fault status information; in addition, two byte variables key_result0 and key_result1 are defined to store the light button scanning information of the dashboard.

The definition of vehicle lamp fault status information is divided into digital diagnostic group and analog diagnostic group: the digital diagnostic group includes 20 lamps such as parking lamps, warning lamps and tail lamps; the analog diagnostic group includes 6 lamps such as headlamps and fog lamps. There are three fault states for each lamp, which are represented by two "bits": normal state (DIAG_OK), represented by "00"; open circuit state (DIAG_OPEN_LOAD), represented by "01"; overload state (DIAG_OVERLOAD), represented by "10". For example, the left parking lamp is represented by the lower two bits of a2, which is defined as static sbit parklightfrontleft_lowbit=a2^0, static sbit parklightfrontleft_highbit=a2^1; a2^1=0, a2^0=1, which means that the parking lamp is in an open circuit fault state. In this way, the analog diagnostic group has 6 lights, and the fault status information needs to occupy 12 bits, which we use byte memories a0 and a1 to represent; the digital diagnostic group has 20 lights, and the fault status information needs to occupy 40 bits, which we use byte memories a2, a3, a4, a5 and a6 to represent. The fault status information of the lights is 7 bytes in total, which is transmitted in a message frame format with 8 bytes, and the 8th byte is padded with 0.

[page]

The dashboard light buttons have a total of 16 switch values, each of which has two states, represented by a "bit": the button is off, represented by "1"; the button is on, represented by "0". We use two-byte memories key_result0 and key_result1 to store button information, and the message frame contains two bytes of data.

The process of sending data bytes is shown in Figure 7. Taking the sending of the lamp fault status information as an example, this state mechanism is used to send the data byte to the bus, and the ID is defined as the send ID (SEND_ID).

The sub-states and corresponding transceiver states are as follows.

Substates 1 to 8: Node is used to send data byte receive interrupt LIN_vRxd_Interrupt;

Substate 9: Node is used to send data byte receive interrupt LIN_vRxd_Interrupt;

Substate 10: The checksum field has been received correctly and the receive interrupt LIN_vRxd_Interrupt is generated.

Among them, the function UCB_Txd is called in the receiving interrupt of substate 1, and the function obtains the first address of the user data storage.

The process of receiving data bytes is shown in Figure 8. Taking the reception of dashboard light button information as an example, this state mechanism is used to receive data from the bus, and the ID is defined as the receiving ID (REC_ID).

The sub-states and corresponding transceiver states are as follows.

Substate 1: Node is used to receive data byte receive interrupt LIN_vRxd_Interrupt;

Substate 2: Node is used to receive data byte receive interrupt LIN_vRxd_Interrupt;

Substate 3: Node is used to receive data byte receive interrupt LIN_vRxd_Interrupt;

Substate 4: The node uses the receive interrupt LIN_vRxd_Interrupt to receive the data byte.

Among them, the function UCB_Rxd is called in the receiving interrupt of substate 4, and the function stores the received data into the user buffer.

4 Conclusion

This paper combines the automotive intelligent lighting control system to conduct an in-depth study on the specific implementation and application of LIN bus technology in the automotive intelligent lighting control system, including the hardware interface circuit design and software design of the LIN bus module. Experiments have confirmed that the LIN bus, with its unique advantages of simple structure, flexible configuration, and high cost performance, can not only meet the requirements of automotive intelligent lighting control systems for data information transmission, but also save costs, fully meet the expected performance and price requirements, and has broad application prospects.

Reference address:Application of LIN bus technology in automobile intelligent lighting control system

Previous article:Design of high-speed CAN network data analysis system for four-wheel independent drive electric vehicles
Next article:Design of power supply protection for USB interface circuit in vehicle ECU

Latest Automotive Electronics Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号