Beruflich Dokumente
Kultur Dokumente
Abstract
The field bus application in a train control system has its own specialty. There has been no special CAN bus application layer standard protocol faced to railway application up to now. In this paper, a new CAN bus application layer protocol is introduced that named Train-CAN that make reference to TCN(IEC61375-1) and other CAN application layer protocol. The protocol at the assignment of message, the transmission rules of message, and the network management is described. A typical application in the train control and fault detecting system is introduced. The real application of the system proved that the Train-CAN protocol is rationality.
1. Introduction
With the development of computer technology and industrial field-bus technology and the communication based on field-bus being used more and more widely on the rolling stocks, CAN bus is subject to a number favored with its simple structure, low-cost, good features and high reliability, the scene anti-interference capability, and the opening up of the characteristics of the development. Nowadays, there are mainly two kinds of Commercial protocols based on CAN bus: device NET and CAN open. While these two protocols are developed for general purposes, they are not fit for the railway rolling stock occasions which require high reliability due to the complicated structure. By reference to the train network communication protocol TCN (Train Communication Network), application norms of TCN faced to railway locomotives are proposed. The detecting and recording system of locomotive instant fault is used for its object to show the application process [1][2].
ID13 ID5
Since the CAN message is based on the priority competition, we change the priority competition mode faced to nodes to that faced to messages as to the Train-CAN protocol. Message Priority engaged 3 bits: ID28-26, using 000 to 111 to present 8 priorities of all the data in the communication net. In the application system of Train-CAN protocol, the design of message priority takes the importance, frequency of transmission, length of data, the real time requirement of the messages into account. Segment transmission flag engages 1 bit: ID25, illustrating whether the message needs to be divided into segments. And the receipt node will decide whether to cope with segments receiving according to this sign. It is effective when set, and the first byte of
2782
data will corporate with this bit which we will talk about later. FUNC ID is assigned 4 bits: ID24-21, to indicate the function the message is designed to work out. The node to receive messages will deal with the message according to the FUNC ID. DMAC and SMAC which indicate the address of the nodes that receive and transmit data each engage 8 bits. In Train-CAN protocol the maxim nodes capacity of one single communication net is 256 in theory, while in practice application, the number of nodes is limited by the electrical properties of net hardware. For example, when Philips P82C250 is used for CAN transceivers, one single net can only hold 110 nodes. SID takes 4 bits: ID4 to ID1, indicating the inside units of nodes that will be operated. Operation is being taken of units inside device according to the SID in the messages. Not all the messages need to be acknowledged in the CAN protocol, and not all the messages need not to be acknowledged. In practical application, users can choose to fill the ACK or not according to the nature of message.
DMAC are local. SID is 0X0E. The length of data is 0. The format of the message is shown in table 4 as below: Table 4: format of MAC ID detecting messages
PRI 0x00 FCODE 0x07 DMAC Own MAC SMAC Own MAC SID 0x0E ACK 1 DATA NULL
When the network data is longer than 8 bytes, the segFlag is needed to be set and used combined with the data bytes. In the segment transmission mode, the maxim length of data is 7 bytes, in which the first byte is defined as below: Table3: segment transmission mode
Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0 SegPolo SegNum
MAC detecting command is aimed to accomplish network managements, in which the SMAC and
2783
To protect the normality of communication, monitoring should be taken on each device in the network and proper actions should be taken to deal with communication abnormality [5]. Since there is an independent connection between each master and slave device in Train-CAN network, it is possible to monitor every connection. Consequently, the monitoring being charged on the communication in Train-CAN network is based on the monitoring of the connections. The network management mainly includes node management and communication management. The node management in Train-CAN network is realized by defining the access mechanism of network status of Train-CAN devices. The access mechanism of Train-CAN network regulates a status graph that is needed when nodes in the network is supposed to start, regulates the rules that how nodes change their status in detail, and can master the nodes by specific messages. The initialization process of devices in the Train-CAN is shown as below:
the cyclic transfer timer is overtime in one connection, the device will send a message. The cyclic parameters are set according to its own data requirements. The procedure of cyclic transfer timer is shown as below:
Connection established
Figure1: The initialization process of devices in the Train-CAN The control of communication is used to monitor the messages in the network, ensuring that when abnormal communication occurred, proper method can be taken to recover normal communication. The control of communication is depended on the communication interval between the master device and the slave device. So in the Train-CAN network, whether the communication is abnormal is determined by overtime mechanism. To control the communication, cyclic transfer timer is defined in Train-CAN protocol: Cyclic transfer timer is used to realize the time triggered transmission of Train-CAN devices. When
2784
With the help of acceptance filter, only when the ACK bit is equal to the value acceptance filter defined can the CAN controller store the information to RXFIFO. The acceptance filter is defined with the acceptance code register and acceptance masking register and single filtering mode is adapted in this system. When the bit corresponding to acceptance masking register AMR.x is 0, filtering is effective. Or the result is opposite. Therefore, when the system is initialization, ACR1 should be set the MAC address corresponding to its own node, while AMR1 should be filled with the value reverse to its own. From the definition above we can see that binding the system devices of Train-CAN we can conveniently control the direction of data flow when data is transmitted. We can realize point to point, multicast and broadcast mode communication just by fill 1 to the bit of receiving node corresponding to the 8-bit SMAC of the message being transmitted. Figure 4 shows the analogy interface of the display screen of the detecting and recording system of locomotive instant fault.
3) The bus polling referenced by MVB definition makes effective monitoring of network status, and good management of data transmission. The network management mechanism provides controllable communication maintenance, node maintenance, and fault recovering function. 4) The combined mode based on master-slave communication mode and production/consumption multicast and broadcast mode, effectively improves the reliability and efficiency of communication. The features above are designed for the train bus application. Train-CAN as one CAN application layer protocol special for the railway, applied in the detecting and recording system of locomotive instant fault with its simplicity and effective feature. By verification of practical application, its reliability, real time performance, flexibility, extensibility and standardization are all meet the demand of general train bus network. Popularization of this protocol will be taken in the later detecting and recording system of locomotive instant fault.
7. References
[1] IEC61375-1-1999, Part 1 Train Communication Network [2] Jaime Jimnez, Jos L.Martin, Carlos Cuadrado, Jagoba Arias and Jess Lzaro A Top-down Design for the Train Communication Network2003 IEEE [3] Rao Yun-tao, Zou Ji-jun and Zheng Yong-yun. Principal and application CAN field-bus, Press of Beijing University of Aeronautics and Astronautics, 2003
[4] Ma Chen-pu, A CAN protocol development suitable for railway locomotives, Electric locomotives and urban rail vehicles, 2005, No. 4,Volume 28pp.17-19 [5] Zhang Da-yong, The research of application of CAN bus used in fault detecting system of locomotives, master degree thesis, 2004
6. Conclusion
Through the analysis of MVB bus protocol we have participated in development, a simplified and practical CAN application layer protocol Train-CAN is proposed, combined the structure specialty of CAN bus model and control of rolling stocks. This protocol has characters as below: 1) The combined use of message ID and data makes the possibility that the CAN frame ID and data being defined specifically and used flexibly. 2) Time and event-triggering transmission mode provide the transmitting ability of periodical procedure data and nonperiodic information data. Meanwhile, event-triggering mode can make full use of the band width.
2785