Communication device and communication system for transmitting I2C protocol data based on universal interface
By using standard RS232 interface and analog switch chip in I2C protocol data transmission, the problems of interface inconsistency and signal attenuation are solved, the high versatility and security of I2C devices are achieved, and the transmission efficiency and equipment application range are improved.
Patent Information
- Application Number
- CN202421181207.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-28
- Publication Date
- 2025-01-07
- Estimated Expiration
- 2034-05-28
AI Technical Summary
The I2C protocol data transmission has problems such as inconsistent interfaces, poor signal attenuation and compatibility, which leads to low device versatility and existing transmission methods require voltage matching, which limits the equipment compatibility of different manufacturers.
The communication device based on a common interface is adopted, and the transmission of I2C protocol data is realized through the standard RS232 interface and analog switch chip, ensuring interface standardization and level unification, supporting multiple communication protocols, and enhancing the universality and security of the equipment.
It improves the versatility and application range of I2C devices, reduces transmission problems, improves transmission security and efficiency, reduces equipment cost and volume, and enhances the data transmission experience.
Smart Images

Figure CN222319459U_ABST
Abstract
Description
Technical Field
[0001] The utility model relates to the technical field of data transmission, in particular to a communication device and a communication system for transmitting I2C protocol data based on a universal interface. Background Art
[0002] The current I2C protocol data transmission basically uses a specific interface, such as a white terminal with 4 pins. This type of terminal is easily damaged when plugged in and out, and is soldered on the circuit board and cannot be exposed outside the product. Therefore, the I2C interface cannot be easily expanded externally.
[0003] Since the I2C interfaces of different products are different and the terminals may be inconsistent, this also brings connection difficulties to devices using the I2C protocol, resulting in a significant reduction in the versatility of devices using the I2C protocol.
[0004] The I2C interface generally uses ordinary wires for transmission, there is no relevant standard, and the wire signals of various devices may also be different, which can easily cause signal attenuation during transmission.
[0005] I2C protocol transmission requires voltage matching. Existing transmission methods require that the voltage of the transmission line be consistent, which requires a unified design at both ends of the transmission. I2C communication devices produced by different manufacturers cannot be well compatible. Utility Model Content
[0006] In order to improve the versatility of I2C protocol devices, the present application provides a communication device and a communication system for transmitting I2C protocol data based on a universal interface.
[0007] In a first aspect, the present application provides a communication device for transmitting I2C protocol data based on a universal interface, including a communication module and a communication device, wherein the communication module includes a first chip, a universal interface and a data line, and the communication device includes a data interaction interface, the first chip is electrically connected to the data interaction interface and the universal interface respectively, the universal interface is electrically connected to one end of the data line, and the other end of the data line is electrically connected to other devices.
[0008] The beneficial effects of the utility model are as follows: I2C protocol data is transmitted through a universal interface, which can greatly improve the versatility of communication equipment (I2C equipment). Since the universal interface is widely used, the communication equipment can be more widely used in different devices and different scenarios, enriching the application scope of the I2C protocol.
[0009] Furthermore, the universal interface is a first RS232 interface, and the data line is a standard RS232 interface transmission line.
[0010] The beneficial effect of adopting the above further scheme is: using standard RS232 interface transmission line to transmit I2C protocol data, the I2C protocol data transmission line can be standardized, reducing the transmission problems caused by different transmission lines, and the level of RS232 interface transmission line is unified, and I2C devices with different voltage standards can be connected, which greatly improves transmission security and transmission efficiency.
[0011] Furthermore, the first chip is an analog switch chip, the data interaction interface includes an I2C interface and other interfaces, the analog switch chip includes a common pin for a set operation and a first connection pin electrically connected to the I2C interface, a second connection pin electrically connected to the other interface, and the common pin is electrically connected to the first connection pin or the second connection pin.
[0012] The beneficial effect of adopting the above further solution is: by adopting a standard first RS232 interface, data corresponding to other interfaces and I2C protocol data of various different communication protocols can be transmitted, which can reduce equipment costs, reduce equipment size, and maximize the use of transmission cables, thereby improving data transmission experience.
[0013] Furthermore, the other interface is a second RS232 interface.
[0014] The beneficial effect of adopting the above further solution is: since the RS232 interface is widely used, most data transmission devices are equipped with an RS232 interface, so the communication equipment can be more widely used in different devices and different scenarios, enriching the application scope of the I2C protocol.
[0015] Furthermore, the first chip is electrically connected to a second chip, and the second chip is electrically connected to the communication device.
[0016] The beneficial effect of adopting the above further solution is that due to the presence of the second chip, malicious attacks or misoperations can be prevented from damaging the system to a certain extent. At the same time, the second chip can also verify and filter the received set control signal to ensure that only valid signals are forwarded to the analog switch chip.
[0017] Further, the analog switch chip includes a 1st pin and a 2nd pin, the first RS232 interface includes a 2nd pin and a 3rd pin, the 1st pin of the analog switch chip is electrically connected to the 3rd pin of the first RS232 interface, and the 2nd pin of the analog switch chip is electrically connected to the 2nd pin of the first RS232 interface.
[0018] Further, the first connecting pin includes the 4th pin and the 6th pin of the analog switch chip, the second connecting pin includes the 5th pin and the 7th pin of the analog switch chip, the 5th pin and the 7th pin of the analog switch chip are electrically connected to the second RS232 interface respectively, the 4th pin and the 6th pin of the analog switch chip are electrically connected to the I2C interface respectively, the 1st pin and the 2nd pin of the analog switch chip are common pins for the set operation, the 5th pin and the 7th pin of the analog switch chip are connected to the 1st pin and the 2nd pin of the analog switch chip respectively, or the 4th pin and the 6th pin of the analog switch chip are connected to the 1st pin and the 2nd pin of the analog switch chip respectively.
[0019] Furthermore, the first chip includes pins 8 and 10, the second chip includes pins 15 and 16, the pin 8 of the first chip is electrically connected to the pin 16 of the second chip, and the pin 10 of the first chip is electrically connected to the pin 15 of the second chip.
[0020] Furthermore, the second chip further includes a first pin, and the first pin of the second chip is electrically connected to the communication device.
[0021] In a second aspect, the present application provides a communication system using the communication device described in the first aspect, comprising a first communication device and a second communication device, wherein the first communication device comprises a first communication device and a first communication module, the first communication device is electrically connected to the first communication module, the second communication device comprises a second communication device and a second communication module, the second communication device is electrically connected to the second communication module, and the data line corresponding to the first communication module is electrically connected to the data line in the second communication module. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] Figure 1 This is a structural block diagram of a communication device for transmitting I2C protocol data based on a universal interface according to an embodiment of the present application;
[0023] Figure 2 This is a circuit schematic diagram of the communication module of the embodiment of the present application;
[0024] Figure 3 This is a structural block diagram of a communication system for transmitting I2C protocol data based on a universal interface according to an embodiment of the present application.
[0025] In the accompanying drawings, the components represented by the reference numerals are listed as follows:
[0026] 1. Communication module; 11. First chip; 12. First RS232 interface; 13. Data line; 14. Second chip; 2. Communication equipment; 21. I2C interface; 22. Second RS232 interface; 3. First communication device; 4. Second communication device. DETAILED DESCRIPTION
[0027] The present application is further described in detail below in conjunction with the accompanying drawings.
[0028] like Figure 1-2 As shown, a communication device for transmitting I2C protocol data based on a universal interface includes a communication module and a communication device, wherein the communication module includes a first chip, a universal interface and a data line, the communication device includes a data interaction interface, the first chip is electrically connected to the data interaction interface and the universal interface respectively, the I2C protocol data is transmitted between the first chip and the communication device, the I2C protocol data is transmitted between the first chip and the universal interface, the universal interface is electrically connected to one end of the data line, the other end of the data line is electrically connected to other devices, and the data line is used to transmit the I2C protocol data between other devices.
[0029] A universal interface refers to an interface standard that can be widely used between a variety of different devices or systems to ensure that they can be connected and communicated with each other on different hardware and software platforms. For example, a universal interface can include an RS232 serial port and a USB interface. It is easy to understand that RS232 (also known as EIA RS-232 or TIA / EIA-232-F) is an interface standard for serial binary data exchange, and USB (Universal Serial Bus) is a serial bus standard for connecting computers and external devices.
[0030] The data line is a transmission line corresponding to the universal interface. In this embodiment, the universal interface may be a first RS232 interface, the first RS232 interface may be a DB9 standard interface, and the data line is a standard RS232 interface transmission line.
[0031] I2C protocol data is transmitted through the standard first RS2132 interface, which can greatly improve the versatility of communication equipment (I2C equipment). Since the RS232 interface is widely used, most data transmission equipment will be equipped with an RS232 interface, so communication equipment can be more widely used in different devices and different scenarios, enriching the application scope of the I2C protocol.
[0032] Using standard RS232 interface transmission lines to transmit I2C protocol data can standardize the I2C protocol data transmission lines, reducing transmission problems caused by different transmission lines. In addition, the level of the RS232 interface transmission lines is unified, and I2C devices with different voltage standards can be connected, greatly improving transmission security and efficiency.
[0033] In this embodiment, the other devices may be other communication devices or other communication devices. When the other devices are other communication devices, the data line is directly electrically connected to the communication device. When the other devices are other communication devices, the data line may be electrically connected to the data line corresponding to the communication module in the communication device.
[0034] In this embodiment, the first chip is an analog switch chip, the data interaction interface includes an I2C interface and other interfaces, the analog switch chip includes a common pin for a set operation and a first connection pin for electrically connecting to the I2C interface, and a second connection pin for electrically connecting to the other interfaces, the common pin is electrically connected to the first connection pin or the second connection pin, and the analog switch chip is used to switch the connection position of the common pin with the first connection pin and the second connection pin according to a set control signal. Exemplarily, the model of the analog switch chip can be TMUX121.
[0035] The other interface may be one or more interfaces that are the same as the universal interface. In this embodiment, the other interface is a second RS232 interface.
[0036] like Figure 1-2 As shown, the analog switch chip includes a 1st pin and a 2nd pin, the first RS232 interface includes a 2nd pin and a 3rd pin, the 1st pin of the analog switch chip is electrically connected to the 3rd pin of the first RS232 interface, and the 2nd pin of the analog switch chip is electrically connected to the 2nd pin of the first RS232 interface.
[0037] In this embodiment, the communication module also includes a second chip, the first chip is electrically connected to the second chip, the second chip is electrically connected to the communication device, and the second chip is used to receive a set control signal sent by the communication device to control the analog switch chip to perform a set operation, and send the set control signal to the analog switch chip.
[0038] like Figure 1-2As shown, the second chip can be a transmission control chip with model number MSPM0L130, the first chip includes pins 8 and 10, the second chip includes pins 15 and 16, the 8th pin of the first chip is electrically connected to the 16th pin of the second chip, and the 10th pin of the first chip is electrically connected to the 15th pin of the second chip.
[0039] In this embodiment, the first connecting pins include the 4th and 6th pins of the analog switch chip, the second connecting pins include the 5th and 7th pins of the analog switch chip, the 5th and 7th pins of the analog switch chip are electrically connected to the second RS232 interface respectively, the 4th and 6th pins of the analog switch chip are electrically connected to the I2C interface respectively, the 1st and 2nd pins of the analog switch chip are common pins for set operation, the 5th and 7th pins of the analog switch chip are connected to the 1st and 2nd pins of the analog switch chip respectively, or the 4th and 6th pins of the analog switch chip are connected to the 1st and 2nd pins of the analog switch chip respectively.
[0040] In this embodiment, when there is no need to transmit I2C protocol data, the communication device does not need to send a set control signal to the second chip. When the second chip does not receive the set control signal, the analog switch chip and the communication device are in a default connection state. The default connection state can be that the 5th pin and the 7th pin of the analog switch chip are respectively electrically connected to the common pin of the analog switch chip, and the 4th pin and the 6th pin of the analog switch chip are respectively disconnected from the common pin of the analog switch chip. The communication device can transmit RS232 data to the analog switch chip through the second RS232 interface, and then realize the transmission of RS232 data with other devices through the first RS232 interface connected to the analog switch chip.
[0041] It is easy to understand that the I2C protocol data does not need to be transmitted including before the I2C protocol data transmission between the communication device and the other device starts, and after the I2C protocol data transmission between the communication device and the other device ends.
[0042] When the second chip receives the set control signal, the analog switch chip performs a set operation. After the set operation, the 4th and 6th pins of the analog switch chip are electrically connected to the common pin of the analog switch chip, and the 5th and 7th pins of the analog switch chip are disconnected from the common pin of the analog switch chip. The communication device can transmit I2C protocol data with the analog switch chip through the I2C interface, and then realize the transmission of I2C protocol data with other devices through the first RS232 interface connected to the analog switch chip.
[0043] In this embodiment, by adopting a standard first RS232 interface, two communication protocols, RS232 data and I2C protocol data, can be transmitted, which can reduce device costs, reduce device size, and maximize the use of transmission cables, thereby improving data transmission experience.
[0044] The TMUX121 analog switch chip is a high-performance bidirectional 2-channel 2:1 (SPDT) switch that supports both differential and single-ended signals. The TMUX121 analog switch chip is an analog passive switch with power-off protection. When the VDD pin is powered off, it forces all I / O pins to enter high-impedance mode. The selection pin and enable pin of the TMUX121 analog switch chip are compatible with 1.8V and 3.3V control voltages, so it can be directly connected to the general-purpose I / O (GPIO) of a low-voltage processor. With this feature and the low on-resistance and low on-capacitance of the device, the analog switch chip of the TMUX121 model is selected in this embodiment.
[0045] Based on the same technical concept, such as Figure 1-3 As shown, the embodiment of the present application also discloses a communication system based on the above communication device, including a first communication device and a second communication device, the first communication device includes a first communication device and a first communication module, the first communication device is electrically connected to the first communication module, the second communication device includes a second communication device and a second communication module, the second communication device is electrically connected to the second communication module, and the data line corresponding to the first communication module is electrically connected to the data line in the second communication module. In this embodiment, the first communication module and the second communication module are both the above communication modules with the same structure.
[0046] Taking the first communication device as the data sending end and the second communication device as the data receiving end as an example, before the I2C protocol data transmission starts between the first communication device and the second communication device, the analog switch chip corresponding to the first communication device and the first communication device, as well as the analog switch chip corresponding to the second communication device and the second communication device are both in a default connection state, and the first communication device and the second communication device can both transmit RS232 data between the corresponding second RS232 interface and the corresponding analog switch chip, and then realize the transmission of RS232 data between the first communication device and the second communication device through the first RS232 interface connected to the analog switch chip.
[0047] It is easy to understand that when the first communication device and the second communication device are both in a default connection state, the first communication device and the second communication device can perform RS232 data transmission based on the first communication module and the second communication module.
[0048] Before the I2C protocol data transmission starts between the first communication device and the second communication device, the first communication device can send a set of request data for transmitting the I2C protocol to the corresponding analog switch chip. The content of the request data is a request for transmitting the I2C protocol. The request data is a set of RS232 data. The request data is connected to the corresponding first RS232 interface through the analog switch corresponding to the first communication device, and then transmitted to the corresponding data line and analog switch chip of the second communication device through the corresponding data line.
[0049] In the default connection state, the analog switch chip corresponding to the second communication device sends request data to the second communication device. After receiving the request data, the second communication device transmits consent data for agreeing to transmit I2C protocol data to the analog switch chip. At the same time, the second communication device transmits a set control signal to the corresponding second chip. The second chip sends the set control signal to the analog switch chip, and the analog switch chip performs a set operation. The I2C interface of the second communication device is connected to the common pin of the analog switch chip, so that I2C protocol data can be transmitted between the second communication device and the analog switch chip.
[0050] The consent data is connected to the corresponding first RS232 interface through the analog switch corresponding to the second communication device, and then transmitted to the corresponding data line and the analog switch chip of the first communication device through the corresponding data line.
[0051] In the default connection state, the analog switch chip corresponding to the first communication device will send the consent data to the corresponding first communication device, the first communication device transmits a set control signal to the corresponding second chip, the second chip sends the set control signal to the analog switch chip, the analog switch chip performs a set operation, and the I2C interface of the first communication device is connected to the common pin of the analog switch chip, so that the I2C protocol data can be transmitted between the first communication device and the analog switch chip, thereby realizing the communication requirement of transmitting I2C protocol data between the first communication device and the second communication device.
[0052] By setting the analog switch chip according to the control signal, the protocol equivalence between the first communication device and the second communication device can be ensured, the possibility of data transmission errors is reduced, the stability and reliability of transmission are improved, and the integrity of transmission data is guaranteed.
[0053] In this embodiment, after the I2C protocol data transmission between the first communication device and the second communication device is completed, the sending of the data packet is turned off, and the analog switch chip corresponding to the first communication device and the analog switch chip corresponding to the second communication device are reset, so that the first communication device and the second communication device are both in a default connection state, reducing the possibility of errors occurring during the next transmission process when the I2C protocol data is transmitted to the second RS232 interface corresponding to the other communication device.
[0054] The terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion such that a process, method, article, or apparatus that includes a list of elements includes not only those elements but also other elements not expressly listed, or also includes elements inherent to such process, method, article, or apparatus.
[0055] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of the present utility model, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0056] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the utility model. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0057] Although the embodiments of the present invention have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limitations of the present invention. Ordinary technicians in the field can change, modify, replace and modify the above embodiments within the scope of the present invention.
Claims
1. A communication device for transmitting I2C protocol data based on a universal interface, characterized in that: It includes a communication module and a communication device, the communication module includes a first chip, a universal interface and a data line, the communication device includes a data interaction interface, the first chip is electrically connected to the data interaction interface and the universal interface respectively, the universal interface is electrically connected to one end of the data line, and the other end of the data line is electrically connected to other devices.
2. A communication device for transmitting I2C protocol data based on a universal interface according to claim 1, characterized in that: The universal interface is a first RS232 interface, and the data line is a standard RS232 interface transmission line.
3. A communication device for transmitting I2C protocol data based on a universal interface according to claim 2, characterized in that: The first chip is an analog switch chip, the data interaction interface includes an I2C interface and other interfaces, the analog switch chip includes a common pin for a set operation and a first connection pin electrically connected to the I2C interface, a second connection pin electrically connected to the other interface, and the common pin is electrically connected to the first connection pin or the second connection pin.
4. A communication device for transmitting I2C protocol data based on a universal interface according to claim 3, characterized in that: The other interface is a second RS232 interface.
5. A communication device for transmitting I2C protocol data based on a universal interface according to claim 3, characterized in that: The first chip is electrically connected to a second chip, and the second chip is electrically connected to the communication device.
6. A communication device for transmitting I2C protocol data based on a universal interface according to claim 4, characterized in that: The analog switch chip includes a first pin and a second pin, the first RS232 interface includes a second pin and a third pin, the first pin of the analog switch chip is electrically connected to the third pin of the first RS232 interface, and the second pin of the analog switch chip is electrically connected to the second pin of the first RS232 interface.
7. A communication device for transmitting I2C protocol data based on a universal interface according to claim 6, characterized in that: The first connection pins include the 4th and 6th pins of the analog switch chip, the second connection pins include the 5th and 7th pins of the analog switch chip, the 5th and 7th pins of the analog switch chip are electrically connected to the second RS232 interface respectively, the 4th and 6th pins of the analog switch chip are electrically connected to the I2C interface respectively, the 1st and 2nd pins of the analog switch chip are common pins for set operation, the 5th and 7th pins of the analog switch chip are connected to the 1st and 2nd pins of the analog switch chip respectively, or the 4th and 6th pins of the analog switch chip are connected to the 1st and 2nd pins of the analog switch chip respectively.
8. A communication device for transmitting I2C protocol data based on a universal interface according to claim 5, characterized in that: The first chip includes pins 8 and 10, the second chip includes pins 15 and 16, the pin 8 of the first chip is electrically connected to the pin 16 of the second chip, and the pin 10 of the first chip is electrically connected to the pin 15 of the second chip.
9. A communication device for transmitting I2C protocol data based on a universal interface according to claim 8, characterized in that: The second chip further includes a first pin, and the first pin of the second chip is electrically connected to the communication device.
10. A communication system using the communication device according to any one of claims 1 to 6, characterized in that: It includes a first communication device and a second communication device, the first communication device includes a first communication equipment and a first communication module, the first communication equipment is electrically connected to the first communication module, the second communication device includes a second communication equipment and a second communication module, the second communication equipment is electrically connected to the second communication module, and the data line corresponding to the first communication module is electrically connected to the data line in the second communication module.