COMMUNICATION GATEWAY

Abstract: A gateway for avoiding unnecessary increase of communication traffic through a communication bus on the side to which data is sent by subjecting only the actually required information to gateway processing. If it is judged that the contents of the received data relate to a command requiring no gateway processing, the gateway processing is inhibited. If it is judged that the contents of the received data represent information to be subjected to gateway processing only when the contents vary, comparison is made with the latest contents of the same kind of information stored in a memory, and it is judged whether or not the contents do not vary. If the contents are judged to have varied the gateway processing is inhibited.

Description: TECHNICAL FIELD The present invention relates to a gateway device that interconnects two communication buses implemented with different communication methods. BACKGROUND ART In recent years, in automobiles and other applications, two or more dissimilar communication buses, each handling unique control information, are used. When there is a need to exchange information between one communication bus and another, a gateway device is provided through which the two buses, implemented with different communication methods, are interconnected. When two communication buses are interconnected via a gateway device as described above, the amount of communication traffic on each communication bus increases because information on one communication bus is transmitted to the other communication bus and vice versa. To suppress such an increase in communication traffic, some prior art gateway devices employ techniques of information filtering using physical addresses or logical addresses, but in that case, information associated with the same address is all transferred to the other communication bus. Accordingly, with such prior art gateway devices, if only part of information is needed on the communication bus at the receiving side, all information destined for its address is processed for gatewaying into the receiving communication bus. This increases the communication traffic since unnecessary portions of the information are also transferred. Furthermore, in configurations where periodically occurring information is processed for gatewaying regardless of whether there occurs a change in its contents, the amount of communication traffic also increases because unnecessary information whose contents remain unchanged is also transferred when only information representing the latest change is needed on the receiving communication bus. US-A-5379292 discloses a gateway device for interconnecting two buses in which information to be communicated is made of a header field containing information necessary for communication and a message field containing information to be used at the receiving side. The device comprises judging means for judging, based on the information to be communicated, whether or not the information received from one bus should be transmitted to the other bus and filtering means for transmitting the received information to the other bus when the received information is judge to be the information that should be transmitted to the other bus. According to a first aspect of the invention, a gateway device for interconnecting two communication buses implementing different communication methods comprises: judging means for judging whether or not information received from one communication bus is information that should be transmitted to the other communication bus; and storage means for storing the information that is judged by said judging means to be the information that should be transmitted; and characterized in that the device further comprises filtering means for comparing the information stored in said storage means with newly received information which is representative of the same kind of condition as said stored information and is judged by said judging means to be the information that should be transmitted and, only when their contents differ, transmitting said received information to said other communication bus while, at the same time, storing said newly received information in said storage means. According to a second aspect of the invention, a method of gatewaying in a gateway device which interconnects two communication buses implementing different communication methods comprises: (a) judging whether or not information received from one communication bus is information that should be transmitted to the other communication bus; (b) storing the information that is judged in said step (a) to be the information that should be transmitted; and characterized by the step of: (c) performing filtering whereby the information stored in said step (b) is compared with newly received information which is representative of the same kind of condition as said stored information and is judged in step (a) to be the information that should be transmitted and, only when their contents differ, said received information is transmitted to said other communication bus while, at the same time, storing said newly received information in said step (b). The present invention provides a gateway device that processes only really necessary information for gatewaying and thereby avoids unnecessary increases in communication traffic on the communication bus at the receiving side. BRIEF DESCRIPTION OF THE DRAWINGS Figure 1 is a block diagram showing interconnections between a gateway device, according to the present invention, two communication buses connected by the gateway device, and devices connected to the respective communication buses. Figure 2 is a diagram showing in simplified form the format of data transmitted on each communication bus. Figure 3 is a flowchart illustrating the processing steps of a service routine that a control microcomputer within the gateway device carries out when data is received. Figure 4 is a diagram showing a table used to judge the contents of received data. Figure 5 is a diagram showing a table of stored information. Figure 6 is a flowchart illustrating the processing steps of a service routine that the control microcomputer within the gateway device carries out when a stored information transmission request is received. BEST MODE FOR CARRYING OUT THE INVENTION An embodiment of the present invention will be described below with reference to the accompanying drawings. Figure 1 is a block diagram showing interconnections between a gateway device 10 according to the present invention, two communication buses 20 and 30 connected by the gateway device, and devices connected to the respective communication buses. The devices 21, 22, 23, 24, etc. connected to the communication bus A as the first communication bus 20 perform communications with one another in accordance with a communication protocol A (a set of communication rules) as a first communication method. Likewise, the devices 31, 32, 33, 34, etc. connected to the communication bus B as the second communication bus 30 perform communications with one another in accordance with a communication protocol B as a second communication method. The gateway device 10, which interconnects the communication bus A 20 and the communication bus B 30, comprises an interface 11 for interfacing with the communication bus A, an interface 12 for interfacing with the communication bus B, a memory 13, and a microcomputer 14, and accomplishes the function of receiving data from one communication bus and transmitting the data to the other communication bus by performing protocol conversion. The embodiment here specifically assumes the case in which the invention is applied to an automobile, and the communication bus A 20 is configured as a bus that uses a protocol intended for data communications between vehicle body-related control devices, while the communication bus B 30 is configured as a bus that uses a protocol intended for data communications between status information-related control devices. An engine ECU (electronic control unit) as the device 21, an air-conditioner ECU as the device 22, a meter ECU as the device 23, etc. are connected to the communication bus A 20. To the communication bus B 30 are connected a display ECU as the device 31, a navigation ECU as the device 32, an audio ECU as the device 33, etc. Figure 2 is a diagram showing in simplified form the format of data transmitted on each communication bus. As shown in the diagram, the data consists of a header and a message, and the message is made up of a command and a parameter accompanying the command. The command is expressed by a 1-byte code. The header contains an address, an attribute, etc. The data format on the communication bus A 20 and the data format on the communication bus B 30 are fundamentally the same as that shown in Figure 2; however, the details differ between the two formats, and the conversion between them is accomplished by the gateway device 10. Figure 3 is a flowchart illustrating the processing steps of a service routine that the control microcomputer 14 within the gateway device 10 carries out when data is received. Figures 4 and 5 are diagrams showing in schematic form the contents of tables held in the memory 13 and used during the processing of Figure 3. This routine can be carried out not only when gatewaying from the communication bus A 20 to the communication bus B 30 but also when gatewaying from the communication bus B 30 to the communication bus A 20. The following description deals with the gatewaying from the communication bus A 20 to the communication bus B 30. First, in step 102, the contents of the received data are examined to judge whether the data concerns a command that does not need gatewaying or information that should be gatewayed only when there is a change in the contents or as it is received, regardless of whether a change has occurred or not. This judgement is made based on the command code contained in the data, and a table such as shown in Table 4 is prestored in the memory 13 for this purpose. The table has a column indicating the command type for each command code. For example, the engine ECU 21 periodically transmits an engine rpm display command expressed by a command code (1F) 16 (meaning the hexadecimal number 1F); this and other commands indicted by the command type "0" are commands that do not need gatewaying. On the other hand, the air-conditioner ECU 22 periodically transmits an outside temperature display command expressed by a command code (05) 16 ; this and other commands indicated by the command type "1" are commands that should be gatewayed only when there is a change in the contents. Further, the meter ECU 23 transmits a distance-to-empty display command expressed by a command code (B3) 16 and an instantaneous fuel economy display command expressed by a command code (DE) 16 ; these and other commands indicted by the command type "2" are commands that should be gatewayed as they are received, regardless of whether a change has occurred or not. If it is judged in step 102 that the command is a command, such as the engine rpm display command, that does not need gatewaying, the routine is terminated without performing processing for gatewaying. This serves to prevent the increase in traffic that would occur on the data receiving communication bus if the processing for gatewaying were performed. If it is judged in step 102 that the command is a command, such as the outside temperature display command, that should be gatewayed only when there is a change in data contents, the process proceeds to step 104. In step 104, a table such as shown in Figure 5 is referenced. This table stores the latest data of information that should be stored. In step 104, the outside temperature data stored in the table, for example, is compared with the value of the outside temperature expressed by the currently received outside temperature display command, to determine whether there is a change in the contents. If it is determined that there is no change, the routine is terminated without performing processing for gatewaying. In this case also, the increase in traffic that would occur on the data receiving communication bus if the processing for gatewaying were performed can be prevented. On the other hand, if it is determined in step 104 that there is a change, the process proceeds to step 108 where the contents of the currently received data are stored as the latest data in the corresponding area of the table of Figure 5. Then, the process proceeds to step 110 to perform processing for gatewaying. If it is judged in step 102 that the contents of the data show information, such as the distance-to-empty display command or the instantaneous fuel economy display command, that should be gatewayed as it is received, the process proceeds to step 106. In step 106, it is judged whether the received data carries information that should always be output via the gateway upon a request from the communication bus. A stored flag column in the table of Figure 4 is reference for this judgement. For example, a command whose stored flag is "1", like the distance-to-empty display command, is a command that should always be output via the gateway upon a request from the communication bus; on the other hand, a command whose stored flag is "0", like the instantaneous fuel economy display command, does not fall into the above command category. If the result of the judgement in step 106 is YES, the previously described storing processing of step 108 and the gateway processing of step 110 are carried out before terminating the routine. On the other hand, if the result of the judgement in step 106 is NO, only the gateway processing of step 110 is carried out before terminating the routine. Figure 6 shows the processing steps of a service routine carried out by the control microcomputer 14 when the gateway device has received a stored information transmission request from the communication bus. First, in step 202, it is determined whether the requested information is stored in the stored information table (Figure 5) within the memory 13. For example, when the result of the determination is YES, like the case when a request for the distance-to-empty data is made from the communication bus B 30, the process proceeds to step 204 where the requested stored information is processed for gatewaying to the requesting communication bus, after which the routine is terminated. On the other hand, when the result of the determination is NO, the process proceeds to step 206 to notify the requesting communication bus that the requested information is not stored in the stored information table (Figure 5) within the memory 13, after which the routine is terminated. In cases where a device connected to the receiving communication bus has failed to capture the information transmitted through the gateway or the information has been erased by a reset operation, etc., if the processing such as shown in Figure 6 is provided there is no need to have the transmitting communication bus re-transmit the information, but the gateway information can be acquired from the gateway device any time. Trial calculations were made to see how much the increase in traffic can be suppressed when the present invention is employed. First, it was assumed that the communication bus A has a transfer speed of 10 kbps, and that the bus usage by itself is 60% and the maximum allowable bus usage is set to 90%. It was also assumed that the communication bus B has a transfer speed of 17 kbps, and that the bus usage by itself is 30% and the maximum allowable bus usage is set to 40%. Considering the case where the communication buses A and B are interconnected and gatewaying is performed from the communication bus A to the communication bus B, it is assumed that the gatewaying entails a factor of 1.7 increase in loss because of the addition of additional information, etc. associated with protocol conversion. Supposing that 20% of the information on the communication bus A flows into the communication bus B by the gatewaying of the prior art, the bus usage on the communication bus B rises to 30% + 60% × 20% × 1.7 = 50.4% and thus cannot be held within the maximum allowable bus usage 40% for the communication bus B. On the other hand, supposing that the percentage of the information on the communication bus A that flows into the communication bus B is held down to 5% because of the filtering effect of the gateway device according to the present invention, the bus usage on the communication bus B is then 30% + 60% × 5% × 1.7 = 35.1% and can thus be held below the maximum allowable bus usage 40% for the communication bus B. As described above, according to the present invention, by processing only really necessary information for gatewaying, it becomes possible to prevent unnecessary increases in communication traffic on the communication bus to which the data is sent through the gateway.

Claims: A gateway device (10) for interconnecting two communication buses (20,30) implementing different communication methods, comprising: judging means (14) for judging whether or not information received from one communication bus is information that should be transmitted to the other communication bus; and storage means (13) for storing the information that is judged by said judging means (14) to be the information that should be transmitted; characterized in that the device further comprises filtering means (14) for comparing the information stored in said storage means with newly received information which is representative of the same kind of condition as said stored information and is judged by said judging means to be the information that should be transmitted and, only when their contents differ, transmitting said received information to said other communication bus while, at the same time, storing said newly received information in said storage means. A gateway device as claimed in claim 1, further comprising: means for transmitting the information stored in said storage means (13) to said communication bus in accordance with a request made from said communication bus. A gateway device as claimed in claim 1 or claim 2, wherein said gateway device comprises means for interconnecting two communication buses (20,30) in an automobile. A device according to any of the preceding claims, wherein each information contains a command, the judging means (14) being adapted to judge based on the command. A method of gatewaying in a gateway device (10) which interconnects two communication buses (20,30) implementing different communication methods, comprising the steps of: (a) judging (102) whether or not information received from one communication bus is information that should be transmitted to the other communication bus; (b) storing (108) the information that is judged in said step (a) to be the information that should be transmitted; and characterized by the step of: (c) performing filtering whereby the information stored in said step (b) is compared (104) with newly received information which is representative of the same kind of condition as said stored information and is judged in step (a) to be the information that should be transmitted and, only when their contents differ, said received information is transmitted to said other communication bus while, at the same time, storing said newly received information in said step (b). A method of gatewaying as claimed in claim 5, further comprising the step of: (d) transmitting the information stored in step (b) to said other communication bus in accordance with a request made from said other communication bus. A method according to claim 5 or claim 6, wherein each information contains a command, step (a) comprising judging based on the command.

Inventors: YAMAWAKI TOSHIO, YAMAWAKI, TOSHIO
Applicants: FUJITSU TEN LTD, FUJITSU TEN LIMITED
Application year: 1998
Main classification: H04L12
IPC codes: H04L12