System, method and controller for multi-channel I2C bus equipment
By using the monitoring module and processing module in the digital chip to adjust the data transmission direction of the I2C device, the problem of difficulty in connecting multiple I2C devices when there is only logic 0/1 inside is solved, and a safe and concise multi-device connection is achieved.
Patent Information
- Application Number
- CN202411573320.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-06
- Publication Date
- 2024-12-03
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art is difficult to connect multiple I2C devices together when there is only logic 0/1 internally, resulting in difficulty in coexisting multiple devices on the I2C bus and may lead to circuit damage.
By introducing a monitoring module and a processing module into the digital chip, the clock signal and data signal are monitored, the control signal is output according to the data information, and the data transmission direction between the master and slave devices is adjusted, so as to realize the connection of multiple I2C devices.
With only logic 0/1 internally, multiple I2C devices are connected, avoiding circuit damage, simplifying the connection between chips, and reducing interconnection complexity.
Smart Images

Figure CN119066016A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of bus technology, and in particular to a system, method and controller for multi-channel I2C bus devices. Background Art
[0002] I2C is the abbreviation of Inter-Integrated Circuit (IIC), which is a universal bus protocol. It is a simple bidirectional two-wire bus protocol standard developed by Philips, now NXP Semiconductors. The I2C bus is a very popular serial bus used for communication between a single or multiple hosts and a single or multiple slaves.
[0003] The I2C bus needs to rely on open collector (OC) or open drain (OD) circuits to achieve the coexistence of multiple I2C devices on the bus. The reason for using open drain instead of push-pull is that if one device outputs a high level and the other outputs a low level when the line is connected, it will cause Figure 1 The upper and lower MOS tubes in the circuit shown will be turned on, causing a large current between VCCIO (the voltage used to drive the IO module) and the ground terminal GND, or between the VCC terminal and the ground terminal GND, and even burning the circuit. Figure 1 As shown in the figure, it is a circuit composed of 4 MOS tubes, among which, if the INP1 terminal inputs a low level and the INN2 terminal inputs a high level, so that the MOS tubes Q1 and Q4 are turned on at the same time, or if the INP2 terminal inputs a low level and the INN1 terminal inputs a high level, so that the MOS tubes Q3 and Q2 are turned on at the same time, a large current will be generated between the VCC terminal and the ground terminal GND, which may burn the circuit.
[0004] like Figure 2 As shown, the I2C bus has two signal lines, SDA (Serial Data Line) and SCL (Serial Clock Line), which are bidirectional I / O (IO) buses. The interface circuit is an open-drain output and needs to be connected to VCCIO (the voltage used to drive the IO module) or +VDD voltage through pull-up resistors Rp. Figure 2 Device 1 and device 2 are shown connected to the bus in a wired AND (wired AND logic) manner. When the bus is idle, both signal lines (SDA and SCL) are high level; when the output is 0, the bus is pulled low. The state of the I2C bus is the wired AND of each I2C device. When the bus is idle, it is in the High-Z state, which is represented as a logic 1 through the pull-up resistor, and when the output is 0, the bus is pulled low.
[0005] However, in general, digital chips only have three-state signals on the IO Buffer, and only have logic 0 / 1 inside. There is no three-state signal, and it is impossible to output the High-Z state. Therefore, multiple I2C devices cannot be connected together inside the digital chip.
[0006] In summary, it is necessary to provide a system, method and controller for multiple I2C bus devices that can connect multiple I2C devices together when there is only logic 0 / 1 inside. Summary of the invention
[0007] To solve the above problems, the present application proposes a system, method and controller for multi-channel I2C bus devices.
[0008] On the one hand, the present application proposes a system for multiple I2C bus devices, which is used for digital chips, including: A monitoring module, used to obtain a clock signal and data signals of a master device and multiple slave devices, and determine and output a control signal according to data information in the data signal corresponding to the clock signal; The processing module is used to control the data transmission direction between the master device and the multiple slave devices according to the control signal; and transmit the logical AND of the data of the multiple slave devices to the master device.
[0009] Preferably, the monitoring module is also used to obtain the clock signal of the master device and / or the multiple slave devices, determine the target high-level signal from the clock signal; obtain the target data signal in the data signal corresponding to the target high-level signal; and output a control signal based on the data information of the target data signal.
[0010] Preferably, the target high-level signal is a high-level signal after an address period in the clock signal; The data information of the target data signal includes write information and read information; when the data information of the target data signal is write information, the monitoring module outputs a first control signal; when the data information of the target data signal is read information, the monitoring module outputs a second control signal.
[0011] Preferably, the master device is connected to the monitoring module and the processing module through the IO interface of the digital chip; each of the multiple slave devices is connected to the processing module through the IO interface of the digital chip; wherein the master device and each of the multiple slave devices are respectively connected to different IO interfaces among the multiple IO interfaces of the digital chip.
[0012] Preferably, the processing module is further used for: In the case where the received control signal is a first control signal, the processing module controls the logical AND of a plurality of first data in the data signal to be transmitted from the plurality of slave devices to the master device, and controls the plurality of second data in the data signal to be transmitted from the master device to the plurality of slave devices; wherein the logical AND of the plurality of first data is a result obtained by performing a logical AND on the plurality of first data; In the case where the received control signal is the second control signal, the processing module controls the logical AND of multiple third data in the data signal to be transmitted from the multiple slave devices to the master device, and controls the multiple fourth data in the data signal to be transmitted from the master device to the multiple slave devices; wherein the logical AND of the multiple third data is the result of performing the logical AND of the multiple third data.
[0013] Preferably, the plurality of first data include data in a data signal corresponding to a ninth clock, an eighteenth clock and a twenty-seventh clock in the clock signal; The plurality of second data include data in the data signal corresponding to the tenth to seventeenth clocks and the nineteenth to twenty-sixth clocks in the clock signal; The plurality of third data include data in the data signal corresponding to the ninth clock, the tenth clock to the seventeenth clock, and the nineteenth clock to the twenty-sixth clock in the clock signal; The plurality of fourth data include data in the data signal corresponding to an eighteenth clock and a twenty-seventh clock in the clock signal.
[0014] Preferably, in the case of controlling the transmission of multiple first data in the data signal from the multiple slave devices to the master device, or in the case of controlling the transmission of multiple third data in the data signal from the multiple slave devices to the master device, the processing module is also used to perform AND logic on the multiple first data of the multiple slave devices and output them, or to perform AND logic on the multiple third data of the multiple slave devices and output them.
[0015] Preferably, the plurality of slave devices include: physical slave devices and / or virtual slave devices.
[0016] In a second aspect, the present application proposes a method for a multi-channel I2C bus device, which is used in a digital chip, comprising: The monitoring module obtains the clock signal and the data signals of the master device and multiple slave devices; The monitoring module determines and outputs a control signal according to data information in the data signal corresponding to the clock signal; The processing module controls the data transmission direction between the master device and the multiple slave devices according to the control signal; and transmits the logical AND of the data of the multiple slave devices to the master device.
[0017] In a third aspect, the present application proposes a controller, comprising: a system for multiple I2C bus devices as described in any one of the first aspects.
[0018] The advantages of the present application are: by acquiring the data signals of the master device and multiple slave devices through the monitoring module, and determining and outputting the control signal according to the data information in the data signal, the transmission direction of the data information of the master device and the multiple slave devices can be determined; by adjusting the data transmission direction between the master device and the multiple slave devices through the processing module, it is possible to connect multiple I2C devices together when there is only logic 0 / 1 inside. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] By reading the detailed description of the preferred embodiment below, various other advantages and benefits will become clear to those of ordinary skill in the art. The accompanying drawings are only used for the purpose of illustrating the preferred embodiment and are not to be considered as limiting the present application. Moreover, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings: Figure 1 A schematic diagram of an existing circuit; Figure 2 It is a schematic diagram of an existing I2C bus connected to multiple devices; Figure 3 It is a schematic diagram of the output structure inside an existing digital chip; Figure 4 It is a schematic diagram of an existing multiple digital chips connected through line-and-logic connection; Figure 5 It is a schematic diagram of the connection between an existing I2C bus and multiple devices; Figure 6 It is a schematic diagram of data transmission between an I2C bus and multiple devices; Figure 7 It is a schematic diagram of the IO pin structure inside an existing digital chip; Figure 8 It is a schematic diagram of the structure of multiple IO pins inside an existing digital chip; Fig. 9 It is a schematic diagram of the data flow inside an existing digital chip; Fig.10 It is a schematic diagram of the connection of multiple IO pins inside a digital chip; Fig.11 It is a schematic diagram of the connection of an I2C bus device outside an existing digital chip; Fig.12 It is a schematic diagram of the connection of an I2C bus with multiple devices through a MUX; Fig.13 is a schematic diagram of a system for multiple I2C bus devices provided by the present application; Fig.14 It is a schematic diagram of the clock and data of a bus for a system of multi-channel I2C bus devices provided by the present application; Fig.15 It is a schematic diagram of the cycle and data transmission direction of the existing I2C bus; Fig.16 It is a schematic diagram of the existing I2C bus signals; Fig.17 This is a schematic diagram of connecting a master device and multiple slave devices in a system of multiple I2C bus devices provided by the present application; Fig.18 It is a schematic diagram of connecting a master device and multiple slave devices in another system for multiple I2C bus devices provided by the present application; Fig.19 This is a schematic diagram of a master device and two slave devices connected to a system of multiple I2C bus devices provided by the present application; Fig. 20 This is a schematic diagram of a system for multiple I2C bus devices provided by the present application that connects a master device with two slave devices and a virtual slave device; Fig.21 It is a schematic diagram of another master device connected to two slave devices and a virtual slave device in a system for multiple I2C bus devices provided by the present application; Fig. 22 It is a flowchart of a method for multi-channel I2C bus devices provided by the present application. DETAILED DESCRIPTION
[0020] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments described herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0021] like Figure 3The figure shows the output structure inside the digital chip. When Data output is 0, the transistor NPN is turned on, and the IO port is equivalent to being connected to the ground; when Data output is 1, the transistor NPN is turned off, and the IO port is equivalent to being suspended. After adding an external pull-up resistor R, when Data output is 0, the transistor NPN is turned on, and the IO port output Data_out is 0; when Data output is 1, the transistor NPN is turned off, the IO port is pulled up to the IO level, and the output Data_out is 1.
[0022] like Figure 4 As shown in the figure, the chip pins of the OC (Open Collector) outputs of multiple chips (chip 1 and chip 2) can be connected together based on the following logic, that is, as long as one output is 0, the bus level will be pulled to 0; only when all outputs are 1, the bus is high level 1, thus realizing the logic of line AND. The I2C bus uses the characteristics of line AND to connect multiple I2C slave devices to one bus.
[0023] like Figure 5 As shown in FIG. 1 , it is an existing I2C bus connection method, that is, a master device is connected to multiple slave devices through the I2C bus. For a digital chip, taking FPGA as an example, it is hoped that it can achieve the following Figure 6 The data transmission of multiple I2C bus devices shown in the figure can realize the data transmission between the I2C master device (master device) and multiple I2C slave devices (slave devices). Figure 7 As shown in the figure, the IO pin structure inside the chip (digital chip) has only one-way drive or logic operation, that is, 1. When the output enable is valid (T=1), the I data is output to the IO pin; 2. When the output enable is invalid (T=0), the IO pin outside the chip is in high configuration (Z); 3. The chip IO pin level can be input into the chip through O, but the chip has no internal High-Z state. Figure 8 As shown, the input / output of the chip's IO1 and IO2 pins can only be controlled by internal logic, which can achieve IO1 input / IO2 output, IO2 input / IO1 output, or control through T. Since the data flow inside the chip is like this Fig. 9 The data flow is unidirectional (i.e., from I to O) as shown in the figure. Therefore, although the IO pins outside the chip can have a high configuration (Z), it is not possible to achieve a high configuration between IO1 and IO2 inside the chip. Fig.10 As shown in Figure 1, the connection is completely direct and data is transmitted bidirectionally. Therefore, conventional implementations can only interconnect I2C devices through physical lines from outside the chip, such as Fig.11 shown.
[0024] However, since FPGA cannot implement Figure 5The connection shown in the figure does not have three states, so it is impossible to achieve Figure 6 Therefore, when the master device Master is connected to the FPGA through the I2C bus, and two slave devices Slave (the first slave device Slave1 and the second slave device Slave2) need to be connected to the master device Master for normal communication, as shown in the figure. Fig.12 As shown, we can consider using a MUX (multiplexer) to combine the signals of two slave devices (the first slave device Slave1 and the second slave device Slave2) and connect them to the master device. Although using MUX is a possible way, there are two prominent problems: 1. SDA is a bidirectional signal. How to determine when the signal flows from the master device to the slave device and when the slave device flows to the master device? 2. High-Z logic cannot be implemented inside the FPGA. How to combine the two SDAs of the two slave devices and realize the switching of the data direction between the master device and the slave device? These are all problems that need to be solved.
[0025] In the first aspect, in order to solve the above problems, the embodiments of the present application provide a system for multi-channel I2C bus devices, for digital chips, such as Fig.13 As shown, including: The monitoring module 100 is used to obtain the clock signal and the data signals of the master device Master and multiple slave devices Slave (such as slave device 1Slave to slave device nSlave), determine the control signal according to the data information in the data signal corresponding to the clock signal and output it; The processing module 200 is used to control the data transmission direction between the master device Master and multiple slave devices Slave according to the control signal; and transmit the logical AND of the data of the multiple slave devices Slave to the master device Master.
[0026] A digital chip is a chip that has a logic AND function but does not have a three-state state (that is, there is only logic 0 / 1 inside and no High-Z state).
[0027] Among them, the monitoring module 100 includes: circuit. The processing module (Switch) 200 includes: circuit. The circuit includes: a hardware circuit that implements functions by a programming language, or a digital circuit composed of a NAND gate, etc. Since the I2C bus is a bidirectional transmission, the monitoring module 100 can only be connected to the clock signal (SCL) line and the data signal (SDA) line on the master device Master side to obtain the data signal of the master device Master and multiple slave devices Slave (such as slave device 1Slave to slave device nSlave).
[0028] The monitoring module 100 is also used to obtain the clock signal of the master device Master and / or multiple slave devices Slave, determine the target high level signal from the clock signal; obtain the target data signal in the data signal corresponding to the target high level signal; and output the control signal according to the data information of the target data signal.
[0029] The target high-level signal is a high-level signal after the address cycle in the clock signal.
[0030] like Fig.14 As shown, the I2C bus generally allows data to change during the SCL low level period and collects data on SDA during the SCL high level period.
[0031] In the address cycle and write cycle of I2C, the master device Master sends the address / data signal, and the slave device Slave gives the response (ACK) signal; in the read cycle, the slave device Slave sends the data signal, and the master device Master gives the response (ACK) signal. The master device Master and the slave device Slave control the bus cycle and data transmission direction as shown in the figure. Fig.15 As shown, S represents the start bit; P represents the stop bit; R represents read; W ̅ represents write; A is ACK, which means answer; A ̅ is NACK, which means no answer; Dm represents that this part of data is transmitted from the master device to the slave device, and Ds represents that this part of data is transmitted from the slave device to the master device.
[0032] like Fig.16 The figure shows a signal diagram of the I2C bus, where the clock signal (SCL) starts from the start bit (START), the 1st to 7th high-level signals are high-level signals of the address cycle, and the corresponding data signal (SDA) includes the address data signal, and the 8th high-level signal is the high-level signal of the read / write cycle, that is, the target high-level signal, and the corresponding data signal includes the read / write data signal. By determining the specific read or write operation from the read / write data signal, the transmission direction of the data signal can be determined. Therefore, the transmission direction of the data signal can be determined based on the difference between the data signals of the read cycle and the write cycle of the above-mentioned I2C.
[0033] The data information of the target data signal includes write information and read information. When the data information of the target data signal is write information, the monitoring module 100 outputs a first control signal. When the data information of the target data signal is read information, the monitoring module 100 outputs a second control signal.
[0034] like Fig.17As shown, the processing module 200 is also used for, when the received control signal is the first control signal, the processing module 200 controls the logical AND of multiple first data in the data signal to be transmitted from multiple slave devices Slave to the master device Master, and controls the multiple second data in the data signal to be transmitted from the master device Master to the multiple slave devices Slave; wherein the logical AND of the multiple first data is the result of performing the logical AND of the multiple first data; when the received control signal is the second control signal, the processing module 200 controls the logical AND of multiple third data in the data signal to be transmitted from multiple slave devices Slave to the master device Master, and controls the multiple fourth data in the data signal to be transmitted from the master device Master to the multiple slave devices Slave; wherein the logical AND of the multiple third data is the result of performing the logical AND of the multiple third data.
[0035] like Fig.16 As shown, the plurality of first data include data in the data signal corresponding to the ninth clock, the eighteenth clock, and the twenty-seventh clock in the clock signal. The plurality of second data include data in the data signal corresponding to the tenth clock to the seventeenth clock and the nineteenth clock to the twenty-sixth clock in the clock signal. The plurality of third data include data in the data signal corresponding to the ninth clock, the tenth clock to the seventeenth clock, and the nineteenth clock to the twenty-sixth clock in the clock signal. The plurality of fourth data include data in the data signal corresponding to the eighteenth clock and the twenty-seventh clock in the clock signal.
[0036] When multiple first data in the control data signal are transmitted from multiple slave devices Slave to the master device Master, or when multiple third data in the control data signal are transmitted from multiple slave devices Slave to the master device Master, the processing module 200 is also used to perform AND logic on the multiple first data of the multiple slave devices Slave and output them, or perform AND logic on the multiple third data of the multiple slave devices Slave and output them.
[0037] The monitoring module 100 of the embodiment of the present application operates at a clock frequency much higher than that of the I2C bus, such as 10 MHz. By adding a monitoring module 100, the SDA signal and the SCL signal of the I2C bus are monitored in real time. By collecting and analyzing the SDA signal and the SCL signal in real time, the SDA and SCL data are parsed according to the I2C protocol; at the falling edge of the SCL signal, the data transmission direction is determined according to the parsed result, and a control signal corresponding to the data transmission direction is output. The processing module 200 adjusts or maintains the data transmission direction according to the control signal, thereby achieving the following. Fig.18As shown, the master device and multiple slave devices are connected to the chip (digital) through physical lines, and multiple I2C devices are interconnected inside the chip. In addition, this method can not only connect multiple external I2C devices through the digital chip, but also connect the I2C module inside the digital chip to the bus.
[0038] like Fig.18 As shown, the master device is connected to the monitoring module and the processing module through the IO interface of the digital chip; each of the multiple slave devices is connected to the processing module through the IO interface of the digital chip; wherein the master device and each of the multiple slave devices are respectively connected to different IO interfaces (IO1, IO2 and IO3) among the multiple IO interfaces of the digital chip.
[0039] For example, at the end of the address cycle, when the last SCL is at a high level, the monitoring module 100 will collect the level of the SDA signal, followed by the falling edge of SCL. At this moment, based on the previously collected information, it can be determined whether the next data direction is from the slave device Slave to the master device Master, or from the master device Master to the slave device Slave, and it can also be determined how long the data transmission direction needs to last, thereby adjusting the data transmission direction.
[0040] like Fig.19 As shown, when the data direction is from the master device Master to the slave device Slave, the SDA signal and the SCL signal are directly output to all the slave devices Slave; when the data direction is from the slave device Slave to the master device Master, the processing module 200 outputs the SCL signal of the master device Master to all the slave devices Slave, and performs AND logic on the SDA signal of the first slave device Slave1 and the SDA signal of the second slave device Slave2 and outputs them to the SDA signal port of the master device Master. If there are more than two slave devices Slave, the processing module 200 performs AND logic on the SDA signals of all the slave devices Slave and outputs them to the SDA signal port of the master device Master.
[0041] The multiple slave devices Slave include: physical slave devices and / or virtual slave devices. The virtual slave devices include virtual slave devices in a controller (such as FPGA).
[0042] Therefore, in addition to connecting with an external I2C device (physical slave device), the embodiments of the present application can also connect with a virtual I2C device (virtual slave device) inside a digital chip (such as an FPGA). Fig. 20As shown, the embodiment of the present application can be connected to a virtual slave device when connected to multiple physical slave devices (a first slave device Slave1 and a second slave device Slave2), wherein the third slave device Slave3 is used to represent the virtual slave device.
[0043] Taking FPGA as an example, digital chip Fig.21 As shown in the figure, when connected to the virtual I2C device inside the FPGA, the data processing method is the same as that when connected to the external I2C device. When the data direction is from the master device Master to the slave device Slave, the SDA signal and the SCL signal are directly output to all slave devices Slave, including the external slave devices (the first slave device Slave1 and the second slave device Slave2) and the internal virtual slave device (the third slave device Slave3). When the data direction is from the slave device Slave to the master device Master, the transmission direction of the SCL signal remains unchanged, and is still output from the master device Master to all slave devices Slave, and the SDA signal is the SDA signal port of the master device Master after the SDA signal of all external slave devices (the first slave device Slave1 and the second slave device Slave2) and the internal virtual slave device (the third slave device Sla3) are ANDed.
[0044] Second, as Fig. 22 As shown, according to the implementation of the present application, a method for a multi-channel I2C bus device is also proposed, which is used for a digital chip, comprising: S101, a monitoring module obtains a clock signal and data signals of a master device and multiple slave devices; S102, the monitoring module determines and outputs a control signal according to data information in a data signal corresponding to the clock signal; S103, the processing module controls the data transmission direction between the master device and the plurality of slave devices according to the control signal; and transmits the logical AND of the data of the plurality of slave devices to the master device.
[0045] In a third aspect, according to an implementation of the present application, a controller is further proposed, comprising: a system for multiple I2C bus devices as described in any one of the first aspects.
[0046] The controller includes a programmable digital chip such as an FPGA, or a device using a programmable digital chip.
[0047] In the implementation of the present application, the controller (such as a chip) can be connected to one or more I2C devices (slave devices), and connected to the upper device (such as a master device including the chip) through an uplink I2C line. At the same time, the I2C device (such as a virtual slave device) inside the controller (such as a chip) can also be connected to the upper device (such as a master device including the chip) through an uplink I2C line. And the I2C device connected to the controller can also be shared with other devices (such as chips).
[0048] In the implementation of the present application, the data signals of the master device and multiple slave devices are obtained by the monitoring module, and the control signal is determined and output according to the data information in the data signal, so that the transmission direction of the data information of the master device and multiple slave devices can be determined; the data transmission direction between the master device and multiple slave devices is adjusted by the processing module, so that multiple I2C devices can be connected together when there is only logic 0 / 1 inside. The implementation of the present application can effectively reduce the number of bus interconnection signals, and at the same time can also reduce the complexity of interconnection, making the connection between chips more concise.
[0049] The above is only a preferred specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A system for multiple I2C bus devices, for digital chips, It is characterized in that include: A monitoring module, used to obtain a clock signal and data signals of a master device and multiple slave devices, and determine and output a control signal according to data information in the data signal corresponding to the clock signal; The processing module is used to control the data transmission direction between the master device and the multiple slave devices according to the control signal; and transmit the logical AND of the data of the multiple slave devices to the master device.
2. The system according to claim 1, It is characterized in that The monitoring module is also used to obtain the clock signal of the master device and / or the multiple slave devices, determine the target high-level signal from the clock signal; obtain the target data signal in the data signal corresponding to the target high-level signal; and output a control signal based on the data information of the target data signal.
3. The system according to claim 2, It is characterized in that The target high-level signal is a high-level signal after an address period in the clock signal; The data information of the target data signal includes write information and read information; when the data information of the target data signal is write information, the monitoring module outputs a first control signal; when the data information of the target data signal is read information, the monitoring module outputs a second control signal.
4. The system according to claim 1, It is characterized in that The master device is connected to the monitoring module and the processing module through the IO interface of the digital chip; each of the multiple slave devices is connected to the processing module through the IO interface of the digital chip; wherein the master device and each of the multiple slave devices are respectively connected to different IO interfaces among the multiple IO interfaces of the digital chip.
5. The system according to claim 4, It is characterized in that The processing module is also used for: In the case where the received control signal is a first control signal, the processing module controls the logical AND of a plurality of first data in the data signal to be transmitted from the plurality of slave devices to the master device, and controls the plurality of second data in the data signal to be transmitted from the master device to the plurality of slave devices; wherein the logical AND of the plurality of first data is a result obtained by performing a logical AND on the plurality of first data; In the case where the received control signal is the second control signal, the processing module controls the logical AND of multiple third data in the data signal to be transmitted from the multiple slave devices to the master device, and controls the multiple fourth data in the data signal to be transmitted from the master device to the multiple slave devices; wherein the logical AND of the multiple third data is the result of performing the logical AND of the multiple third data.
6. The system according to claim 5, It is characterized in that The plurality of first data include data in the data signal corresponding to a ninth clock, an eighteenth clock and a twenty-seventh clock in the clock signal; The plurality of second data include data in the data signal corresponding to the tenth to seventeenth clocks and the nineteenth to twenty-sixth clocks in the clock signal; The plurality of third data include data in the data signal corresponding to the ninth clock, the tenth clock to the seventeenth clock, and the nineteenth clock to the twenty-sixth clock in the clock signal; The plurality of fourth data include data in the data signal corresponding to an eighteenth clock and a twenty-seventh clock in the clock signal.
7. The system according to claim 5, It is characterized in that In the case of controlling the transmission of multiple first data in the data signal from the multiple slave devices to the master device, or in the case of controlling the transmission of multiple third data in the data signal from the multiple slave devices to the master device, the processing module is further used to perform AND logic on the multiple first data of the multiple slave devices and output them, or to perform AND logic on the multiple third data of the multiple slave devices and output them.
8. The system of claim 1, It is characterized in that The multiple slave devices include: physical slave devices and / or virtual slave devices.
9. A method for multiple I2C bus devices, for digital chips, It is characterized in that include: The monitoring module obtains the clock signal and the data signals of the master device and multiple slave devices; The monitoring module determines and outputs a control signal according to data information in the data signal corresponding to the clock signal; The processing module controls the data transmission direction between the master device and the multiple slave devices according to the control signal; and transmits the logical AND of the data of the multiple slave devices to the master device.
10. A controller, characterized by comprising the system for multiple I2C bus devices according to any one of claims 1 to 8.
Citation Information
Patent Citations
System and method for realizing I2C bus control
CN101763331A
Data communication system
CN110659238A
FPGA-based I3C logic controller implementation method, I3C read-write test device and I3C read-write test system
CN113031486A
Bus data reading method, bus interface circuit and verification system
CN118377739A
Controlling passthrough of communication between multiple buses
US20110099310A1
Cited By
Circuit for controlling data read-write direction in I2C HUB chip, chip and electronic equipment
CN121722692A
