CN215642683U - I2C bus data transmission monitoring device - Google Patents
I2C bus data transmission monitoring device Download PDFInfo
- Publication number
- CN215642683U CN215642683U CN202122057703.6U CN202122057703U CN215642683U CN 215642683 U CN215642683 U CN 215642683U CN 202122057703 U CN202122057703 U CN 202122057703U CN 215642683 U CN215642683 U CN 215642683U
- Authority
- CN
- China
- Prior art keywords
- bus
- data transmission
- port
- main control
- control board
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Landscapes
- Debugging And Monitoring (AREA)
Abstract
The embodiment of the utility model provides an I2C bus data transmission monitoring device, and belongs to the technical field of I2C bus data transmission. The I2C bus data transmission monitoring device comprises: a main control board, and a plurality of I2C ports disposed on the main control board; the main control board is used for carrying out data communication with each connected I2C peripheral device; the plurality of I2C ports includes: at least one master mode I2C port and at least one slave mode I2C port; the at least one slave mode I2C port is connected at the rear end of the at least one master mode I2C port; the master mode I2C port is used for connecting each I2C peripheral device; the slave mode I2C port is used for monitoring the communication information of the master control board and each I2C peripheral device. The I2C bus data transmission monitoring device provided by the scheme of the utility model realizes quick and convenient data transmission and acquisition of the I2C bus.
Description
Technical Field
The utility model relates to the technical field of I2C bus data transmission, in particular to an I2C bus data transmission monitoring device.
Background
Now, more and more peripheral devices and microcontrollers are interfaced in the form of a two-wire I2C serial bus, and the I2C bus is used in many electronic applications. The I2C bus is a master-slave structure, the single chip is a master device, and the memory is a slave device. One bus may carry multiple slave devices, with the SDA and SCL of the I2C bus being bi-directional, an open gate configuration, with a positive power supply connected through a pull-up resistor. When data is transmitted, the data on the SDA line must remain stable during the high period of the clock. The high or low state of the data line can only change when the clock signal of the SCL line is low. The interaction between the master and the slave on the I2C bus is accompanied by a large amount of data transmission, and in the development and debugging stage, the bus data needs to be analyzed, often by using a logic analyzer or an oscilloscope.
The measurement principle of the logic analyzer or oscilloscope is to compare an input signal with a set threshold voltage by adopting a certain frequency, wherein the input signal is logic 1 when the input level is greater than the threshold voltage, and the input signal is logic 0 when the input level is lower than the threshold voltage. Because the frequency of the electronic circuit is high, and the logic analyzer or oscilloscope needs to accurately measure the electronic signals, the performance requirement is high, so that the manufacturing cost is high, the purchase cost is high, the configuration is also complex, and the operation is not simple and convenient. Meanwhile, the equipment is large in size and inconvenient to carry and use. Aiming at the problems of high cost and complex operation of the existing bus data test device, a new I2C bus data transmission monitoring device needs to be created.
SUMMERY OF THE UTILITY MODEL
An object of an embodiment of the present invention is to provide an I2C bus data transmission monitoring apparatus, so as to at least solve the problems of high cost and complex operation of the existing bus data testing apparatus.
In order to achieve the above object, an embodiment of the present invention provides an I2C bus data transmission monitoring device, where the I2C bus data transmission monitoring device includes: a main control board, and a plurality of I2C ports disposed on the main control board; the main control board is used for carrying out data communication with each connected I2C peripheral device; the plurality of I2C ports includes: at least one master mode I2C port and at least one slave mode I2C port; the at least one slave mode I2C port is connected at the rear end of the at least one master mode I2C port; the master mode I2C port is used for connecting each I2C peripheral device; the slave mode I2C port is used for monitoring the communication information of the master control board and each I2C peripheral device.
Optionally, an I2C communication bus is connected to a rear end of the port of the master mode I2C, and a plurality of connection ports for connecting I2C peripheral devices are arranged on the I2C communication bus.
Optionally, only one connection port among the plurality of connection ports on the I2C communication bus can be activated to be conducted at the same time.
Optionally, the main control board includes a determination module for determining the identity of the I2C peripheral device that needs to communicate.
Optionally, a data acquisition line is connected to the rear end of the slave mode I2C port.
Optionally, the main control board includes an acquisition module, and the acquisition module is configured to acquire communication information on the I2C communication bus through the data acquisition line during communication between the main control board and a certain I2C peripheral device.
Optionally, the main control board further includes: and the storage module is used for storing the communication information on the I2C communication bus.
Optionally, the storage system mounted on the storage module is a sysfs system.
Optionally, the I2C bus data transmission monitoring apparatus further includes: and the human-computer interaction module is connected with the main control panel and is used for monitoring communication information interaction between personnel and the main control panel.
Optionally, the human-computer interaction module includes: the control module is used for calling the communication information; and the display module is used for displaying the communication information.
Through the technical scheme, due to the fact that the plurality of I2C ports are arranged, at least one slave mode I2C port can be arranged, and the rear end of the slave mode I2C port is connected with the I2C bus. When I2C bus communication is carried out, the port of the slave mode I2C can recognize transmission data on the bus, but is designed not to respond, so that the port of the slave mode I2C becomes a device only recording the transmission data, self-monitoring of the main control panel is realized, the transmission data is recorded and stored in real time, the use of other professional equipment is avoided, and quick and convenient data transmission and acquisition of the I2C bus are realized.
Additional features and advantages of embodiments of the utility model will be set forth in the detailed description which follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the embodiments of the utility model and are incorporated in and constitute a part of this specification, illustrate embodiments of the utility model and together with the description serve to explain the embodiments of the utility model without limiting the embodiments of the utility model. In the drawings:
fig. 1 is a schematic structural diagram of an I2C bus data transmission monitoring device according to an embodiment of the present invention.
Description of the reference numerals
10-a main control panel; 20-main mode I2C port; 30-slave mode I2C port.
Detailed Description
The following detailed description of embodiments of the utility model refers to the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating embodiments of the utility model, are given by way of illustration and explanation only, not limitation.
In the embodiments of the present invention, unless otherwise specified, the use of the directional terms such as "upper, lower, left, and right" generally refers to the directions or positional relationships shown in the drawings, or the directions or positional relationships that the products of the present invention are usually placed when they are used.
The terms "first," "second," "third," and the like are used solely to distinguish one from another and are not to be construed as indicating or implying relative importance.
In the description of the present invention, it should also be noted that, unless otherwise explicitly specified or limited, the terms "disposed," "mounted," "connected," and "connected" are to be construed broadly and may, for example, be fixedly connected, detachably connected, or integrally connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meanings of the above terms in the present invention can be understood in specific cases to those skilled in the art.
When the I2C bus is used for communication, there is a large amount of data transmission between the main control board 10 and each I2C peripheral device. In the development and test stage, in order to know whether the transmission path and the transmission integrity are normal, transmission data on the transmission path needs to be analyzed, so that corresponding data needs to be collected. At present, when data analysis is carried out, a logic analyzer or an oscilloscope is mainly used for carrying out the data analysis. A logic analyzer or oscilloscope is a tool dedicated to testing data signals and can express data transmitted on a bus as logic 0 and logic 1 to record data changes on the bus. The bus transmission data analysis device is used for analyzing the data transmitted by the bus according to the recorded waveform, and searching whether the bus has errors or not and the reason of the errors. Although the logic analyzer and the oscilloscope can realize the I2C bus transmission monitoring, the logic analyzer and the oscilloscope are very troublesome to use and operate, require professional personnel to carry out active operation, and have strong requirements on the technical capability and equipment of the personnel. Moreover, logic analyzers and oscilloscopes are relatively expensive, and in the face of the increasing volume of developed test instruments, the cost investment in test equipment becomes prohibitively large, which indirectly limits equipment development.
Therefore, the utility model designs an I2C bus data transmission monitoring device, a part of I2C ports are set as slave mode I2C ports 30, the ports are only used for collecting communication information on a bus, the communication information is monitored through the main control board 10, the use of professional detection equipment is avoided, and the self detection of the main control board 10 can be realized only by carrying out corresponding line and module improvement. The cost investment of test equipment for development and test is greatly reduced, the self-monitoring of the main control board 10 is realized, the workload of related personnel is also greatly reduced, and the intelligence of the whole development and test process is improved.
Referring to fig. 1, the present embodiment provides an I2C bus data transmission monitoring device, where the I2C bus data transmission monitoring device includes: a main control board 10, and a plurality of I2C ports provided on the main control board 10; the main control board 10 is used for data communication with each connected I2C peripheral device; the plurality of I2C ports includes: at least one master mode I2C port 20 and at least one slave mode I2C port 30; the at least one slave mode I2C port 30 is connected at the rear end of the at least one master mode I2C port 20; the master mode I2C port 20 is used for connecting each I2C peripheral device; the slave mode I2C port 30 is used to monitor the communication information between the master control board 10 and each I2C peripheral.
The I2C bus is a master-slave structure, the single chip is a master device, and the memory is a slave device. One bus may have multiple slave devices (there may also be multiple master configurations), and the SDA and SCL of the I2C bus are bi-directional, open gate configurations, with positive power supplied through pull-up resistors. When data is transmitted, the data on the SDA line must remain stable during the high period of the clock. The high or low state of the data line can only change when the clock signal of the SCL line is low. The measurement principle of the logic analyzer or oscilloscope is to compare an input signal with a set threshold voltage by adopting a certain frequency, wherein the input signal is logic 1 when the input level is greater than the threshold voltage, and the input signal is logic 0 when the input level is lower than the threshold voltage. Because of the relatively high frequency of the electronic circuits in the IC2 bus communication, the performance requirements of the logic analyzer or oscilloscope that are required to accurately measure these electronic signals are high, which results in high cost, high purchase cost, complex configuration, and inconvenient operation. Meanwhile, the equipment is large in size and inconvenient to carry and use.
In the embodiment of the present invention, based on the operating principle of I2C, each device on the bus can detect the level change of the bus, that is, the peripheral device 2 can also detect the data signal sent to the peripheral device 1 by the master through I2C. Just before this communication, the master first performs an I2C addressing action and sends the level signal of the address to be addressed on the bus. When the peripheral device on the bus detects that the slave address of the data frame does not accord with the address of the peripheral device, the peripheral device abandons to participate in the communication, and the peripheral device which detects the same slave address participates in the communication. By means of the principle, the I2C bus data transmission monitoring device is designed, a peripheral device is selected to play the role of a slave in a bus and not participate in communication, but is always used for recording data transmission on the bus, and therefore data transmission on the I2C bus can be recorded and detected in real time. Here we access the I2C port operating in slave mode to the I2C bus operating in master mode, then for the master I2C port 20, the slave I2C port 30 is a slave to it, and we can treat it as a peripheral device. However, the slave mode I2C port 30 is a set of I2C interfaces on the master that we can control. The slave mode I2C port 30 is configured not to respond to the addressing action of the bus, but rather silently records and stores the address frame and the data frame on the bus in a fixed form, thereby realizing simple monitoring of the transmission of I2C bus data.
Preferably, an I2C communication bus is connected to the rear end of the port 20 of the main mode I2C.
In the embodiment of the present invention, as known above, a part of the I2C ports are used as the slave mode I2C ports 30, and the I2C ports originally used for bus communication are reserved for maintaining data communication with each I2C peripheral device.
Preferably, a plurality of connection ports are arranged on the I2C communication bus and are used for connecting I2C peripheral equipment.
In the embodiment of the present invention, the I2C bus is a master-slave configuration, in which the master control board 10 is the master device and each I2C peripheral device is the slave device. A plurality of I2C peripheral devices are connected to one bus, so a plurality of connection ports are arranged on the I2C communication bus, and a plurality of I2C peripheral devices are connected at the same time.
Preferably, among a plurality of connection ports on the I2C communication bus, only one connection port can be activated to conduct at the same time; the main control board 10 includes a determination module, which is used to determine the identity of the I2C peripheral device that needs to communicate.
In an embodiment of the present invention, in an I2C bus communication, a master device is used to initiate a bus transfer of data and generate a clock to open up the transferred devices, when any addressed device is considered a slave device. The relationship of master and slave, send and receive on the bus is not constant, but depends on the direction of data transfer at the time. If the host wants to send data to the slave device, the host addresses the slave device first, then actively sends the data to the slave device, and finally the host terminates the data transmission; if the host is to receive data from the slave device, the slave device is first addressed by the master device, then the host receives the data sent by the slave device, and finally the host terminates the receiving process. In this case, the host is responsible for generating the timing clock and terminating the data transfer. The SDA (serial data line) and SCL (serial clock line) are bi-directional, open gate structures with positive power supplied through a pull-up resistor. Therefore, when communication is established, the master device needs to judge the identity of the slave device, and the situation of data error transmission is avoided. In this case, the determination module may be configured to determine whether the corresponding I2C peripheral device knows that the device is a device requiring communication based on address information sent from the device, and open the communication line only after the authentication is passed.
Preferably, a data acquisition line is connected to the rear end of the slave mode I2C port 30.
In the embodiment of the present invention, when performing I2C bus communication, there is data transmission on the corresponding I2C bus, so when a data transmission test is desired, data acquisition needs to be performed on the signal transmission path. The data acquisition circuit is led out from the port 30 of the mode I2C through presetting, and the other end of the data acquisition circuit is connected on the bus in a bypass mode, so that when data pass through the corresponding interface, the data can be acquired by the data acquisition circuit, and the bus transmission data acquisition is realized. Because the bus has a plurality of ports, one of the ports is used for expanding the data acquisition circuit, the structure of the line is improved little, and the expansion is convenient.
Preferably, the main control board 10 includes an acquisition module, and is configured to acquire communication information on the I2C communication bus through the data acquisition line when the main control board 10 communicates with one of the I2C peripheral devices.
In the embodiment of the present invention, the acquisition module is disposed on the main control board 10, and when performing bus communication, the acquisition module performs real-time data transmission acquisition through the slave mode I2C port 30. In the whole acquisition process of the acquisition module, the signals of the master device and the slave devices are not responded, data acquisition is carried out only according to a preset program, and interference on the response signals on the bus is avoided. And the master device can judge that a plurality of response slave devices exist due to the existence of the response signals, so that data transmission errors can be avoided.
Preferably, the main control board 10 further includes: and the storage module is used for storing the communication information on the I2C communication bus, and the storage system carried by the storage module is a sysfs system.
In the embodiment of the utility model, when 12C bus data communication is carried out, a large amount of data interaction exists, and when data acquisition is carried out, the cache capacity of a module is limited, so that the data storage of the part cannot be carried out. Therefore, the storage module is added, and after the acquisition module finishes data acquisition, the acquired data is transmitted to the storage module in real time and is stored. The whole storage capacity of the device is improved, complete communication data acquisition is carried out in the bus data transmission process, and the integrity of the volume of the analysis data is guaranteed. Preferably, the storage system carried by the storage module is a sysfs system, the sysfs is a virtual memory-based file system which is newly designed in a Linux kernel, the sysfs system has the advantages of more uniform kernel data exporting mode and better organization mode, and the multi-layer structure of the sysfs system can well improve the storage and read-write efficiency of the acquired data.
The I2C bus data transmission monitoring device further comprises: and the human-computer interaction module is connected with the main control panel 10 and is used for monitoring communication information interaction between a monitoring person and the main control panel 10. The human-computer interaction module comprises: the control module is used for calling the communication information; and the display module is used for displaying the communication information.
In the embodiment of the utility model, in the development and test stage, relevant personnel need to observe and learn the specification of the bus or search the reason of the bus error according to the transmission data in the bus transmission path. Therefore, a corresponding human-computer interaction module is configured, and comprises a control module and a mental affair module. The control module is connected with the main control panel 10 and used for relevant personnel to trigger a calling request of corresponding communication information, and the main control panel 10 outputs corresponding stored information from the storage module according to the calling request and displays the stored information on the display module for the relevant personnel to look up.
Although the embodiments of the present invention have been described in detail with reference to the accompanying drawings, the embodiments of the present invention are not limited to the details of the above embodiments, and various simple modifications can be made to the technical solutions of the embodiments of the present invention within the technical idea of the embodiments of the present invention, and the simple modifications all belong to the protection scope of the embodiments of the present invention.
It should be noted that the various features described in the above embodiments may be combined in any suitable manner without departing from the scope of the utility model. In order to avoid unnecessary repetition, the embodiments of the present invention do not describe every possible combination.
Those skilled in the art will understand that all or part of the steps in the method according to the above embodiments may be implemented by a program, which is stored in a storage medium and includes several instructions to enable a single chip, a chip, or a processor (processor) to execute all or part of the steps in the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
In addition, any combination of various different implementation manners of the embodiments of the present invention is also possible, and the embodiments of the present invention should be considered as disclosed in the embodiments of the present invention as long as the combination does not depart from the spirit of the embodiments of the present invention.
Claims (10)
1. An I2C bus data transmission monitoring device, wherein the I2C bus data transmission monitoring device comprises:
a main control board, and a plurality of I2C ports disposed on the main control board;
the main control board is used for carrying out data communication with each connected I2C peripheral device;
the plurality of I2C ports includes: at least one master mode I2C port and at least one slave mode I2C port; the at least one slave mode I2C port is connected at the rear end of the at least one master mode I2C port;
the master mode I2C port is used for connecting each I2C peripheral device;
the slave mode I2C port is used for monitoring the communication information of the master control board and each I2C peripheral device.
2. The I2C bus data transmission monitoring device of claim 1, wherein an I2C communication bus is connected to the rear end of the I2C port of the master mode, and a plurality of connection ports for connecting I2C peripheral devices are arranged on the I2C communication bus.
3. The I2C bus data transmission monitoring device of claim 2, wherein only one connection port among the plurality of connection ports on the I2C communication bus can be activated to conduct at the same time.
4. The I2C bus data transmission monitoring device of claim 1, wherein the main control board includes a determination module for determining the identity of the I2C peripheral devices that need to communicate.
5. The I2C bus data transmission monitoring device of claim 1, wherein a data acquisition line is connected to the rear end of the slave mode I2C port.
6. The I2C bus data transmission monitoring device of claim 5, wherein the main control board includes an acquisition module for acquiring communication information on the I2C communication bus via the data acquisition line during the communication between the main control board and a certain I2C peripheral device.
7. The I2C bus data transmission monitoring device of claim 6, wherein the main control board further comprises: and the storage module is used for storing the communication information on the I2C communication bus.
8. The I2C bus data transmission monitoring device of claim 7, wherein the memory module-mounted memory system is a sysfs system.
9. The I2C bus data transmission monitor device of claim 1, wherein the I2C bus data transmission monitor device further comprises:
and the human-computer interaction module is connected with the main control panel and is used for monitoring communication information interaction between personnel and the main control panel.
10. The I2C bus data transmission monitoring device of claim 9, wherein the human-computer interaction module comprises:
the control module is used for calling the communication information;
and the display module is used for displaying the communication information.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202122057703.6U CN215642683U (en) | 2021-08-27 | 2021-08-27 | I2C bus data transmission monitoring device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202122057703.6U CN215642683U (en) | 2021-08-27 | 2021-08-27 | I2C bus data transmission monitoring device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN215642683U true CN215642683U (en) | 2022-01-25 |
Family
ID=79903697
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202122057703.6U Active CN215642683U (en) | 2021-08-27 | 2021-08-27 | I2C bus data transmission monitoring device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN215642683U (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117424776A (en) * | 2023-12-19 | 2024-01-19 | 深圳市宇通联发科技有限公司 | Data transmission system, control method, device and medium |
-
2021
- 2021-08-27 CN CN202122057703.6U patent/CN215642683U/en active Active
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117424776A (en) * | 2023-12-19 | 2024-01-19 | 深圳市宇通联发科技有限公司 | Data transmission system, control method, device and medium |
CN117424776B (en) * | 2023-12-19 | 2024-04-02 | 深圳市宇通联发科技有限公司 | Data transmission system, control method, device and medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10955461B2 (en) | Smart and efficient protocol logic analyzer configured within automated test equipment (ATE) hardware | |
US20190354453A1 (en) | Traffic capture and debugging tools for identifying root causes of device failure during automated testing | |
CN110050441B (en) | Capturing traffic in real time for protocol debugging in case of failure | |
CN207115097U (en) | A kind of FPGA isomeries accelerator card | |
KR970076738A (en) | Hard disk drive test device | |
CN114528792B (en) | Chip verification method and device, electronic equipment and storage medium | |
JP5153774B2 (en) | Test apparatus, program, and recording medium | |
CN111767177B (en) | Test method, device and equipment of LED display screen control card and storage medium | |
CN215642683U (en) | I2C bus data transmission monitoring device | |
CN102879732B (en) | Method and system for testing board card | |
CN114281624A (en) | Method, system, device and equipment for testing I2C signal integrity | |
WO2016184170A1 (en) | Smi interface device debugging apparatus and method, and storage medium | |
CN112485699A (en) | Server power supply test system | |
TWI420318B (en) | A non-intrusive general-purpose common busbar switching device | |
CN104572515A (en) | Tracking module, method, system and SOC (System-On-Chip) | |
CN101071394A (en) | Inter-board transparent transmission bus test device and method | |
CN215017215U (en) | Honeycomb type detection device | |
US20040044485A1 (en) | Failure analysis system and failure analysis method of logic LIS | |
CN111198322A (en) | Relay protection action export analyzer | |
EP3557422A1 (en) | Method for accessing code sram, and electronic device | |
CN105450818B (en) | mobile terminal power consumption current measuring method and device | |
JPH05334120A (en) | Information processor | |
CN218938940U (en) | I2C bus test fixture | |
CN211785797U (en) | Test and diagnosis system for test equipment of combat system | |
JPS5917625A (en) | Single-chip microcomputer |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
GR01 | Patent grant | ||
GR01 | Patent grant |