Composite method and system for hybrid bridging of I2C (Inter-Integrated Circuit) and CAN (Controller Area Network)

By adopting multi-buffer concurrent transmission and independent software architecture in I2C and CAN bus communication, the speed matching and delay problems in heterogeneous network communication are solved, and dynamic interaction and synchronous transmission of I2C and CAN are realized, which is suitable for a variety of applications Scene.

CN118916316APending Publication Date: 2024-11-08SHANDONG INSPUR SCI RES INST CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410958224.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-17
Publication Date
2024-11-08

AI Technical Summary

Technical Problem

In the prior art, heterogeneous network communication between I2C and CAN buses has problems with speed matching, data buffering and synchronization, resulting in delay and mismatch problems, making it difficult to achieve dynamic interaction.

Method used

Multiple buffers are used to realize concurrent transmission of the output stream through a single dedicated process. By fixed the speed of one party, the size of the packet and the transmission speed of the other party are transformed. The communication speed is selected to make the reception and transmission delay controllable, and the buffer elimination of the multiplication factor is introduced. Delay, using a bridge subnet to connect I2C and CAN, implementing independent software architecture and concurrent transmission process.

Benefits of technology

Solve the speed delay and mismatch problems of heterogeneous networks I2C and CAN, realize the synchronization and timing of data transmission, eliminate the delay between reception and transmission, and realize the dynamic interaction between I2C and CAN, suitable for on-board equipment and industry. Scenes such as on-site and medical equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118916316A_ABST
    Figure CN118916316A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of communication, and particularly provides a composite method and system for hybrid bridging of I2C and CAN, which is based on a plurality of buffer areas, realizes a concurrent transmission process of an output stream through a single dedicated process, and connects the I2C and the CAN by adopting a subnet bridging mode. Compared with the prior art, the method can solve the problems of heterogeneous network I2C and CAN interconnection, including data speed matching, data buffering, synchronization or timing of data transmission and the like, and eliminates the problems of speed delay and mismatching of heterogeneous network I2C and CAN interconnection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication technology and specifically provides a hybrid bridge I 2 C and CAN composite method and system. Background Art

[0002] I 2 C is a serial bus communication protocol that uses two wires, data line and clock line. It is simple and flexible, low cost, can realize multi-master control, and has strong scalability. It is widely used in various devices and application fields, such as sensors, memories (such as EEPROM), displays, temperature sensors, real-time clocks (RTC), expansion IO chips, etc.

[0003] CAN bus is a field serial communication protocol for data transmission and control, which can realize the interactive communication of multiple devices and is widely used in the fields of automobiles, industrial sites, aviation and ship electronics, etc. It has high reliability, strong anti-interference ability and real-time performance, and is suitable for application scenarios that require reliable communication and data transmission between multiple devices.

[0004] At present, with the development of signal integration interaction, I 2 The demand for heterogeneous subnet communication between I2C and CAN bus is becoming more and more urgent. For example, initially, automobile-related engine control, braking, sensing, etc. 2 C was implemented, and later the car added high-speed communication drives such as photosensitive and reverse braking, and began to use CAN communication. The two need to exchange some information, but heterogeneous network communication has many problems, including data transmission rate, address, format synchronization, etc. Summary of the invention

[0005] The present invention aims to provide a hybrid bridge with strong practicability. 2 Composite method of C and CAN.

[0006] A further technical task of the present invention is to provide a hybrid bridge having a reasonable design and being safe and applicable. 2 Composite system of C and CAN.

[0007] The technical solution adopted by the present invention to solve its technical problem is:

[0008] A hybrid bridge 2 The composite method of I2C and CAN is based on multiple buffers, and the concurrent transmission process of output streams is realized through a single dedicated process, and the bridge subnet is used to connect I2C and CAN.

[0009] Furthermore, we first fixed the speed of one party and changed the packet size and transmission speed of the other party to observe whether the speeds were synchronized and converged.

[0010] For I 2 C and CAN bus group test, any combination of data transmission speed and packet size, I 2 Neither C nor CAN will converge to the other's speed, and timing cannot be matched without time delay.

[0011] Furthermore, the communication speed of sending and receiving is selected so that the delay time of receiving and transmitting can be controlled. If a match is not found, multiple attempts are required.

[0012] Furthermore, the transmission speed is chosen so that the response time of sending and receiving are multiples of each other, that is, the delay time is eliminated by introducing a buffer equivalent to a multiplication factor, following an independent software architecture, and when the input buffer is filled, the buffer is cleared simultaneously by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture.

[0013] Furthermore, the receiving process keeps receiving data and fills the buffer serially in a circular manner. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer;

[0014] Additionally, a separate process continuously and serially streams data into the output transmission line.

[0015] A hybrid bridge 2 The composite system of I2C and CAN is based on multiple buffers and realizes the concurrent transmission process of output streams through a single dedicated process, and connects I2C and CAN in the form of bridge subnet.

[0016] Furthermore, we first fixed the speed of one party and changed the packet size and transmission speed of the other party to observe whether the speeds were synchronized and converged.

[0017] For I 2 C and CAN bus group test, any combination of data transmission speed and packet size, I 2 Neither C nor CAN will converge to the other's speed, and timing cannot be matched without time delay.

[0018] Furthermore, the communication speed of sending and receiving is selected so that the delay time of receiving and transmitting can be controlled. If a match is not found, multiple attempts are required.

[0019] Furthermore, the transmission speed is chosen so that the response time of sending and receiving are multiples of each other, that is, the delay time is eliminated by introducing a buffer equivalent to a multiplication factor, following an independent software architecture, and when the input buffer is filled, the buffer is cleared simultaneously by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture.

[0020] Furthermore, the receiving process keeps receiving data and fills the buffer serially in a circular manner. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer;

[0021] Additionally, a separate process continuously and serially streams data into the output transmission line.

[0022] A hybrid bridge of the present invention 2 Compared with the prior art, the composite method and system of C and CAN has the following outstanding beneficial effects:

[0023] The present invention solves the problem of heterogeneous network I 2 The problems of interconnection between I2C and CAN, including data speed matching, data buffering, synchronization or timing of data transmission, etc., eliminate the heterogeneous network I 2 C and CAN interconnection speed delay and mismatch problem; intelligent solution of heterogeneous network I 2 C and CAN bridging to achieve their dynamic interaction.

[0024] It can be applied to scenarios such as vehicle-mounted equipment communications, industrial sites, medical equipment, etc., and has broad future prospects. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0026] Attached Figure 1 It is a hybrid bridge I 2 Schematic diagram of the bridge network topology structure of the composite method of C and CAN;

[0027] Attached Figure 2 It is a hybrid bridge I 2 Figure 1. Bridge software architecture diagram for composite approach of C and CAN. DETAILED DESCRIPTION

[0028] In order to enable those skilled in the art to better understand the solution of the present invention, the present invention is further described in detail below in conjunction with specific implementation methods. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0029] A best embodiment is given below:

[0030] In this embodiment, a hybrid bridge I 2 A composite method of I2C and CAN is proposed. Based on multiple buffers, a concurrent transmission process of output streams is realized through a single dedicated process. A bridge subnet is used to connect I2C and CAN, and the transmission speed corresponding to the delay can be greatly reduced.

[0031] First, by fixing the speed of one party, change the packet size (smaller than the maximum achievable packet value) and transmission speed of the other party respectively, and observe whether the speeds are synchronized and converged;

[0032] For I 2 C and CAN bus group test, any combination of data transmission speed and packet size, I 2 Neither C nor CAN converges to the other’s speed and cannot achieve time matching without time delay. From the data obtained, it can be seen that there is an appropriate buffering strategy to minimize the delay between data reception and transmission.

[0033] Select the communication speed for sending and receiving so that the receiving and transmission delay times are controllable. If a match is not found, try multiple times.

[0034] The transmission speed is chosen so that the response time of sending and receiving are multiples of each other, that is, the delay time is eliminated by introducing a buffer equivalent to a multiplication factor, following an independent software architecture, and when the input buffer is filled, the buffer is cleared simultaneously by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture.

[0035] The receiving process keeps receiving data and fills the buffer serially in a circular manner. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer;

[0036] In addition, a separate process continuously and serially streams data onto the output transmission line, eliminating any delays that exist between reception and transmission.

[0037] Based on the above method, a hybrid bridge I in this embodiment 2The composite system of I2C and CAN is based on multiple buffers and realizes the concurrent transmission process of output streams through a single dedicated process, and connects I2C and CAN in the form of bridge subnet.

[0038] First, fix the speed of one party and change the data packet size and transmission speed of the other party to see if the speeds are synchronized and converged.

[0039] For I 2 C and CAN bus group test, any combination of data transmission speed and packet size, I 2 Neither C nor CAN will converge to the other's speed, and timing cannot be matched without time delay.

[0040] Select the communication speed for sending and receiving so that the receiving and transmission delay times are controllable. If a match is not found, try multiple times.

[0041] The transmission speed is chosen so that the response time of sending and receiving are multiples of each other, that is, the delay time is eliminated by introducing a buffer equivalent to a multiplication factor, following an independent software architecture, and when the input buffer is filled, the buffer is cleared simultaneously by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture.

[0042] The receiving process keeps receiving data and fills the buffer serially in a circular manner. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer;

[0043] Additionally, a separate process continuously and serially streams data into the output transmission line.

[0044] like Figure 1 As shown, the bridge network topology of the present invention is a 2 Both C and CAN networks are common, and bidirectional data flow can be achieved through this system.

[0045] The data transmission rates of the two communication protocols are different. 2 In C, data can be communicated at 100kbps, 400kbps, 1Mbps and 3.4Mbps, while in CAN communication, the data communication speed range is 40kbps to 1Mbps. The packet size can also vary from 4 bytes to 8 bytes. By fixing the speed of one side, changing the packet size (less than the value of the maximum achievable packet) and the transmission speed of the other side, and observing whether the speeds are synchronized and converged. After testing multiple sets of data, whether it is a change in packet size or a change in rate, considering any combination of achievable data transmission speed and packet size, I 2Neither C nor CAN converges to the other’s speed and cannot achieve time matching without time delay. From the data obtained, it can be seen that there is an appropriate buffering strategy to minimize the delay between data reception and transmission.

[0046] One method is to select the communication speed of sending and receiving so that the delay time of receiving and transmitting can be controlled. If the match is not found, multiple attempts are required. 2 When 1Mbps is selected for C and CAN, the delay is 0.043 milliseconds, which is the minimum delay caused. However, in practice, this method cannot accurately guarantee the accuracy of the transmission speed, so its practicality is limited.

[0047] The transmission speed is selected so that the response time of sending and receiving is a multiple of each other. The delay time is eliminated by introducing a buffer equivalent to a multiplication factor. Following an independent software architecture, when the input buffer is filled, the buffer is cleared at the same time by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture. For example, CAN (500kbps), I 2 The transmission speed of C (1Mbps) is multiplied by 2, CAN (125kbps), I 2 C (500 kbps) has a transmission speed multiple of 4. A multiple of 2 results in a delay of 0.136 milliseconds, while a multiple of 4 results in a delay of 0.618 milliseconds. This delay can be avoided by selecting a number of concurrent processes equal to the number of buffers selected for transmission. The same number of buffers as this multiple is the best choice.

[0048] like Figure 2 The software architecture of the bridge is shown in Figure 1. The receiving process keeps receiving data and fills the buffer serially in a loop. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer.

[0049] In addition, a separate process continuously and serially streams data onto the output transmission line, eliminating any delays that exist between reception and transmission.

[0050] Regardless of I 2 Regardless of which of C and CAN is located at the transmitting end and which is located at the receiving end, the above-mentioned sending and receiving processes are also applicable.

[0051] The above-mentioned specific implementations are only specific cases of the present invention. The patent protection scope of the present invention includes but is not limited to the above-mentioned specific implementations. Any technical solutions that comply with the claims of the present invention and any appropriate changes or substitutions made by ordinary technicians in the relevant technical field shall fall within the patent protection scope of the present invention.

[0052] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A hybrid bridge I 2 A composite method of C and CAN, characterized in that, Based on multiple buffers, the concurrent transmission process of the output stream is realized through a single dedicated process, and the I2C and CAN are connected by a bridge subnet.

2. A hybrid bridge according to claim 1 2 A composite method of C and CAN, characterized in that, First, fix the speed of one party and change the data packet size and transmission speed of the other party to see if the speeds are synchronized and converged. For I 2 C and CAN bus group test, any combination of data transmission speed and packet size, I 2 Neither C nor CAN will converge to the other's speed, and timing cannot be matched without time delay.

3. A hybrid bridge according to claim 2 2 A composite method of C and CAN, characterized in that, Select the communication speed for sending and receiving so that the receiving and transmission delay times are controllable. If a match is not found, try multiple times.

4. A hybrid bridge according to claim 3 2 A composite method of C and CAN, characterized in that, The transmission speed is chosen so that the response time of sending and receiving are multiples of each other, that is, the delay time is eliminated by introducing a buffer equivalent to a multiplication factor, following an independent software architecture, and when the input buffer is filled, the buffer is cleared simultaneously by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture.

5. A hybrid bridge according to claim 4 2 A composite method of C and CAN, characterized in that, The receiving process keeps receiving data and fills the buffer serially in a circular manner. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer; Additionally, a separate process continuously and serially streams data into the output transmission line.

6. A hybrid bridge I 2 The composite system of C and CAN is characterized by: Based on multiple buffers, the concurrent transmission process of the output stream is realized through a single dedicated process, and the I2C and CAN are connected by a bridge subnet.

7. A hybrid bridge according to claim 6 2 The composite system of C and CAN is characterized by: First, fix the speed of one party and change the data packet size and transmission speed of the other party to see if the speeds are synchronized and converged. For I 2 C and CAN bus group test, any combination of data transmission speed and packet size, I 2 Neither C nor CAN will converge to the other's speed, and timing cannot be matched without time delay.

8. A hybrid bridge according to claim 7 2 The composite system of C and CAN is characterized by: Select the communication speed for sending and receiving so that the receiving and transmission delay times are controllable. If a match is not found, try multiple times.

9. A hybrid bridge according to claim 8 2 The composite system of C and CAN is characterized by: The transmission speed is chosen so that the response time of sending and receiving are multiples of each other, that is, the delay time is eliminated by introducing a buffer equivalent to a multiplication factor, following an independent software architecture, and when the input buffer is filled, the buffer is cleared simultaneously by using multiple transmission processes concurrently, that is, the delay is eliminated through a specific software architecture.

10. A hybrid bridge according to claim 7 2 The composite system of C and CAN is characterized by: The receiving process keeps receiving data and fills the buffer serially in a circular manner. At the same time, several sending processes equal to the number of buffers will concurrently read the data and put it into the output buffer; Additionally, a separate process continuously and serially streams data into the output transmission line.