CN210324188U - Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof - Google Patents

Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof Download PDF

Info

Publication number
CN210324188U
CN210324188U CN201921408492.2U CN201921408492U CN210324188U CN 210324188 U CN210324188 U CN 210324188U CN 201921408492 U CN201921408492 U CN 201921408492U CN 210324188 U CN210324188 U CN 210324188U
Authority
CN
China
Prior art keywords
iic
manager
slave
equipment
automatic switching
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
Application number
CN201921408492.2U
Other languages
Chinese (zh)
Inventor
胡磊
张浩彬
刘跃武
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Maiming Technology Co ltd
Original Assignee
Shenzhen Maiming Technology Co ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Shenzhen Maiming Technology Co ltd filed Critical Shenzhen Maiming Technology Co ltd
Priority to CN201921408492.2U priority Critical patent/CN210324188U/en
Application granted granted Critical
Publication of CN210324188U publication Critical patent/CN210324188U/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Bus Control (AREA)

Abstract

The utility model discloses an integrated circuit bus IIC principal and subordinate compete automatic switch-over equipment and system thereof contains a manager and with a plurality of slave machine equipment that the manager is connected, manager and slave machine equipment and from the communication bus between machine equipment and slave machine equipment all adopt integrated circuit bus IIC. The utility model discloses the during operation, the second IIC module of manager all is the host computer, but the second IIC module of two parallelly connected back managers of equipment complete machine can only be by one as the host computer to go the information of inquiring subordinate's equipment to can only go the order of responding the host computer by the first IIC module of same manager, the second IIC module of another equipment must withdraw from original host computer mode, otherwise will cause the bus conflict to make whole bus paralysed. The manager losing the control right of the host closes the first IIC module, and the corresponding port is set to be in a high-impedance state, so that the upper computer is ensured to obtain the information of all the slave devices only by accessing one fixed address.

Description

Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof
Technical Field
The utility model relates to an automatic control field specifically is an integrated circuit bus IIC principal and subordinate competition automatic switch-over equipment and system thereof.
Background
The existing IIC bus may have the situation that two hosts conflict, and an upper-level controller is often used for controlling and switching a master-slave mode. The master and the slave of the IIC are switched through the superior controller, once the superior controller is separated from the controller, the two hosts always compete for the control right of the bus, and therefore the whole bus cannot be normally used.
The above prior art has the following disadvantages: (1) additional controller intervention is required to realize master-slave switching; (2) when the superior controller is not in use, once two hosts always compete for the bus control right, the whole bus is paralyzed and cannot be recovered.
SUMMERY OF THE UTILITY MODEL
An object of the utility model is to provide an integrated circuit bus IIC principal and subordinate competition automatic switch-over equipment and system to solve the problem that proposes among the above-mentioned background art.
In order to achieve the above object, the utility model provides a following technical scheme:
an integrated circuit bus IIC master-slave competition automatic switching device comprises a manager and a plurality of slave devices connected with the manager, wherein communication buses between the manager and the slave devices and communication buses between the slave devices and the slave devices adopt integrated circuit bus IIC; the second IIC module is connected with the slave equipment, works in a master mode and is responsible for collecting information of the slave equipment, the manager collects and temporarily stores the information of the slave equipment through the second IIC module and is also responsible for state management of the complete machine of the automatic switching equipment, and the upper computer obtains the state of the complete machine of the automatic switching equipment and the information of the slave equipment through accessing the manager. The number of the plurality of slave devices is at least 2.
As a further aspect of the present invention: a system adopting the integrated circuit bus IIC master-slave competition automatic switching equipment comprises a plurality of automatic switching equipment which are connected in parallel on the same upper computer, first IIC modules in the automatic switching equipment are connected together through an IIC bus, and second IIC modules of managers in the automatic switching equipment are connected together through the IIC bus.
As a further aspect of the present invention: the second IIC module of the manager after the devices are connected in parallel is used as a host to inquire the information of the slave devices, the first IIC module of the same manager responds to the command of the upper computer, the second IIC modules of other automatic switching devices exit the original host mode, the manager losing the control right of the host closes the first IIC module, and the corresponding ports are set to be in a high-resistance state, so that the upper computer only accesses one fixed address to obtain the information of all the slave devices.
Compared with the prior art, the beneficial effects of the utility model are that: the utility model discloses automatic switching equipment complete machine during independent work, the second IIC module of manager all is the host computer, but the second IIC module of two parallelly connected back managers of equipment complete machine can only be by one as the host computer to go the information of inquiring subordinate's equipment to can only go the command of responding the host computer by the first IIC module of same manager, the second IIC module of another equipment must withdraw from original host computer mode, otherwise will cause the bus conflict to make whole bus paralysed. The manager losing the control right of the host closes the first IIC module, and the corresponding port is set to be in a high-impedance state, so that the upper computer is ensured to obtain the information of all the slave devices only by accessing one fixed address.
Drawings
FIG. 1 is a schematic block diagram of an integrated circuit bus IIC master-slave contention automatic switching apparatus;
FIG. 2 is a functional block diagram of one embodiment of an integrated circuit bus IIC master-slave contention automatic switching system;
FIG. 3 is a flowchart illustrating the operation of the master/slave contention automatic switching system of the integrated circuit bus IIC.
Detailed Description
The technical solutions in the embodiments of the present invention will be described clearly and completely with reference to the accompanying drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments in the present invention, all other embodiments obtained by a person skilled in the art without creative work belong to the protection scope of the present invention.
As an embodiment of the present invention, as shown in fig. 1, the integrated circuit bus IIC master-slave competition automatic switching device includes a manager and a plurality of slave devices connected to the manager, the manager and the slave devices and communication buses between the slave devices and the slave devices all adopt the integrated circuit bus IIC, the manager includes two groups of IIC modules, which are a first IIC module and a second IIC module respectively, the first IIC module is connected to an upper computer, and operates in a slave mode and is responsible for sending device information to the upper computer; the second IIC module is connected with the slave equipment, works in a master mode and is responsible for collecting information of the slave equipment, the manager collects and temporarily stores the information of the slave equipment through the second IIC module and is also responsible for state management of the complete machine of the automatic switching equipment, and the upper computer obtains the state of the complete machine of the automatic switching equipment and the information of the slave equipment through accessing the manager. The number of the plurality of slave devices is at least 2.
Preferably, fig. 2 is an exemplary embodiment of the system of the present invention, because of system requirements, two automatic switching devices need to be connected in parallel for use, but the upper computer only has one IIC interface connected to the set of system, and therefore two sets of IIC modules of the manager need to be connected together respectively, specifically: the first IIC modules of the automatic switching devices are connected together through IIC buses, and the second IIC modules of the managers of the automatic switching devices are also connected together through IIC buses.
When the automatic switching equipment complete machine works independently, the second IIC module of the manager is the host, but after the two automatic switching equipment complete machines are connected in parallel, the second IIC module of the manager can only use one as the host to inquire the information of the lower-level equipment, and can only use the first IIC module of the same manager to respond to the command of the upper computer, and the second IIC module of the other automatic switching equipment must exit the original host mode, otherwise, bus conflict can be caused to enable the whole bus to be paralyzed. The manager losing the control right of the host computer closes the first IIC module, and the corresponding port is set to be in a high-impedance state. Therefore, the upper computer can obtain the information of all the slave devices only by accessing one fixed address.
Two automatic switching devices are connected in parallel, and the electrifying sequence has two possibilities:
(1) the first IIC module and the second IIC module of the two devices are connected together and then powered up:
after the manager is powered on, the first IIC module and the second IIC module are initialized to be slaves, corresponding timeout waiting time is set according to the IIC address of the manager, the timeout waiting time with the low address is short, for example 10ms, and the timeout waiting time with the high address is longer, for example 50 ms. During the timeout waiting period, if the second IIC module detects START and STOP signals on the IIC bus 2, the slave state of the second IIC module is maintained and the IO port corresponding to the first IIC module is set to a high-impedance state, and if no START or STOP signal is detected on the IIC bus 2 during the entire timeout waiting time, it is verified that there is no host device on the IIC bus 2, and the second IIC module can be switched from the slave mode to the host mode. In the parallel operation state, the master manager needs to inquire the information of the lower-level device, and also needs to inquire the manager in the slave state through the IIC bus 2 to acquire the state of the whole device of another device.
(2) After the two devices are respectively powered on, the first IIC module and the second IIC module are connected together:
the two automatic switching devices are respectively powered on, and the IIC bus 1 and the IIC bus 2 are disconnected, so that after the timeout waiting time is exceeded, the two managers are switched from the slave mode to the host mode to respectively control the IIC buses 2. When the IIC buses of the two complete automatic switching equipment are connected together, two hosts exist on the IIC bus 2, and the two hosts always send commands, and at this time, a high probability of bus collision occurs. When the manager detects that the IIC bus 2 has bus collision, the host mode is immediately exited, the slave mode is switched to, and a delay waiting mechanism is executed when power is on. The two devices exit the main mode together and enter the overtime waiting state, the waiting time of the device with low address is short, and the device is inevitably switched to the host mode first. Therefore, the low address device will first preempt the bus control right, and the high address device will detect the START and STOP signals from the low address device in the timeout period, and will keep the slave mode.
Therefore, whether the bus is connected first and then powered on or first and then connected, the device with the low address can be ensured to be the master, and the device with the high address can be ensured to be the slave. The process flow after the two cases are combined is shown in fig. 3.
The number of the automatic switching devices connected in parallel is two, but the system provided by the invention is not limited to the parallel connection of two automatic switching devices, and the system is also applicable to the situation that the number is more than two.
It is obvious to a person skilled in the art that the invention is not restricted to details of the above-described exemplary embodiments, but that it can be implemented in other specific forms without departing from the spirit or essential characteristics of the invention. The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference sign in a claim should not be construed as limiting the claim concerned.
Furthermore, it should be understood that although the present description refers to embodiments, not every embodiment may contain only a single embodiment, and such description is for clarity only, and those skilled in the art should integrate the description, and the embodiments may be combined as appropriate to form other embodiments understood by those skilled in the art.

Claims (4)

1. The master-slave competition automatic switching equipment of the integrated circuit bus IIC is characterized by comprising a manager and a plurality of slave equipment connected with the manager, wherein the manager and the slave equipment as well as communication buses between the slave equipment and the slave equipment adopt the integrated circuit bus IIC; the second IIC module is connected with the slave equipment, works in a master mode and is responsible for collecting information of the slave equipment, the manager collects and temporarily stores the information of the slave equipment through the second IIC module and is also responsible for state management of the complete machine of the automatic switching equipment, and the upper computer obtains the state of the complete machine of the automatic switching equipment and the information of the slave equipment through accessing the manager.
2. The integrated circuit bus IIC master-slave contention automatic switching apparatus of claim 1, wherein the number of slave apparatuses is at least 2.
3. A system using an integrated circuit bus IIC master-slave competition automatic switching device according to claim 1 or 2, comprising a plurality of automatic switching devices connected in parallel to the same upper computer, wherein first IIC modules in the plurality of automatic switching devices are connected together through an IIC bus, and second IIC modules in managers in the plurality of automatic switching devices are also connected together through an IIC bus.
4. The system as claimed in claim 3, wherein the second IIC module of the manager after the multiple devices are connected in parallel is used as a host to inquire the information of the slave devices, and the first IIC module of the same manager responds to the command of the host computer, the second IIC modules of other automatic switching devices exit the original host mode, the manager losing the control right of the host computer closes the first IIC module, and the corresponding port is set to be in a high impedance state.
CN201921408492.2U 2019-08-27 2019-08-27 Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof Active CN210324188U (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201921408492.2U CN210324188U (en) 2019-08-27 2019-08-27 Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201921408492.2U CN210324188U (en) 2019-08-27 2019-08-27 Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof

Publications (1)

Publication Number Publication Date
CN210324188U true CN210324188U (en) 2020-04-14

Family

ID=70131590

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201921408492.2U Active CN210324188U (en) 2019-08-27 2019-08-27 Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof

Country Status (1)

Country Link
CN (1) CN210324188U (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111698139A (en) * 2020-07-15 2020-09-22 深圳市天磁科技有限公司 RS485 bus multi-host competition switching method
CN112187474A (en) * 2020-09-27 2021-01-05 北京三未信安科技发展有限公司 Password authentication auto-negotiation switching system and method based on IIC multi-master-slave communication

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111698139A (en) * 2020-07-15 2020-09-22 深圳市天磁科技有限公司 RS485 bus multi-host competition switching method
CN112187474A (en) * 2020-09-27 2021-01-05 北京三未信安科技发展有限公司 Password authentication auto-negotiation switching system and method based on IIC multi-master-slave communication
CN112187474B (en) * 2020-09-27 2024-04-09 三未信安科技股份有限公司 IIC multi-master-slave communication-based password authentication auto-negotiation switching system and method

Similar Documents

Publication Publication Date Title
US7266625B2 (en) Data communication system
CN102724093B (en) A kind of ATCA machine frame and IPMB method of attachment thereof
CN107111588A (en) The data transfer of PCIe protocol is used via USB port
CN101610192B (en) Communication slave, bus cascading method and system
CN103248526A (en) Communication equipment and method for achieving out-of-band monitoring and management, and master-slave switching method
CN103645975B (en) A kind of method of abnormal restoring and serial bus transmission device
CN102946366B (en) In-band management method and system
EP1701271A1 (en) Electronic apparatus system with master node and slave node
CN210324188U (en) Integrated circuit bus IIC master-slave competition automatic switching equipment and system thereof
CN101557379B (en) Link reconfiguration method for PCIE interface and device thereof
US20190012246A1 (en) Method for locating and isolating failed node of electromechanical management bus in communication device
CN102870374B (en) Load-sharing method and apparatus, and veneer,
US20150156117A1 (en) High density server system
CN109586956B (en) FCoE switch capable of flexibly configuring ports and method
CN111698139A (en) RS485 bus multi-host competition switching method
CN207896980U (en) Communication structure and communication system
CN106874228A (en) Based on I2Communication means between the controller and communication means, multi-controller of C buses
CN103885910B (en) The method that many equipment carry out IIC communications under holotype
CN110456705B (en) Network control device capable of dynamically expanding interface and building automatic control system
CN212324117U (en) RS485 bus multi-host competition switching system
CN101281510B (en) Double-I2C bus setting method and double I2C bus system
CN104899164B (en) Address addressing method for integrated circuit bus, integrated circuit bus device and system
CN212256082U (en) Edge calculation control system
CN113253652A (en) Unit communication control device, method and unit
CN209860929U (en) Communication bus structure

Legal Events

Date Code Title Description
GR01 Patent grant
GR01 Patent grant