[go: up one dir, main page]

CN119071142A - Dual redundant network communication switching method, device and system - Google Patents

Dual redundant network communication switching method, device and system Download PDF

Info

Publication number
CN119071142A
CN119071142A CN202411263894.3A CN202411263894A CN119071142A CN 119071142 A CN119071142 A CN 119071142A CN 202411263894 A CN202411263894 A CN 202411263894A CN 119071142 A CN119071142 A CN 119071142A
Authority
CN
China
Prior art keywords
phy port
phy
state
port
spanning tree
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.)
Pending
Application number
CN202411263894.3A
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.)
Wuhan Guide Infrared Co Ltd
Original Assignee
Wuhan Guide Infrared 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 Wuhan Guide Infrared Co Ltd filed Critical Wuhan Guide Infrared Co Ltd
Priority to CN202411263894.3A priority Critical patent/CN119071142A/en
Publication of CN119071142A publication Critical patent/CN119071142A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/0654Management of faults, events, alarms or notifications using network fault recovery
    • H04L41/0663Performing the actions predefined by failover planning, e.g. switching to standby network elements

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本发明公开了一种双冗余网络通信切换方法、装置及系统,涉及冗余网络通信技术领域,双冗余网络通信切换方法包括以下步骤:利用单片机周期性查询非管理型网络交换芯片的双冗余物理层接口设备PHY端口的连接状态,判断PHY端口是否有物理连接;基于生成树协议,并根据PHY端口的连接状态,动态调整PHY端口的生成树状态,以完成PHY端口切换。本申请采用单片机在主程序中周期查询非管理型网络交换芯片的PHY端口的连接状态,当发生网络连接异常时,自动切换至备份网络连接端口,不依赖系统主机,不影响系统可靠性,而且由于不使用双网卡或网管型交换机,降低了使用成本和安装空间要求。

The present invention discloses a dual-redundant network communication switching method, device and system, and relates to the field of redundant network communication technology. The dual-redundant network communication switching method includes the following steps: using a single-chip microcomputer to periodically query the connection status of the dual-redundant physical layer interface device PHY port of an unmanaged network switching chip to determine whether the PHY port has a physical connection; based on the spanning tree protocol, and according to the connection status of the PHY port, dynamically adjust the spanning tree status of the PHY port to complete the PHY port switching. The present application uses a single-chip microcomputer to periodically query the connection status of the PHY port of the unmanaged network switching chip in the main program. When a network connection abnormality occurs, it automatically switches to the backup network connection port, does not rely on the system host, does not affect the system reliability, and because it does not use dual network cards or network management switches, it reduces the use cost and installation space requirements.

Description

Dual-redundancy network communication switching method, device and system
Technical Field
The present application relates to the field of redundant network communication technologies, and in particular, to a dual-redundancy network communication switching method, device, and system.
Background
With the rapid development of information technology, network communication is becoming more important, and ethernet is also becoming a main medium for interconnection of various control system interfaces. In some applications, the stability requirement on the network system is very high, and in order to improve the reliability and the survivability of the system, a dual redundancy design mode is often adopted.
The prior method for realizing the communication switching of the dual redundant network mainly adopts the dual network card or network management type switch technology, and the management and the switching of the dual network are all responsible for a system host. When one network card fails, the system host switches the data network to the other network card to continue network communication by reading the failure state.
The prior art relies on the data processing capability of a system host, has the defects of large switching delay, low data instantaneity, influence on the system reliability and incapability of realizing transparent switching on a client, and has large use cost and installation space of a double-network card or network management type switch and space for substitution and optimization.
Disclosure of Invention
The application provides a dual-redundancy network communication switching method, a device and a system, which adopt a singlechip to periodically inquire the connection state of a PHY port of a non-management network switching chip in a main program, and automatically switch to a backup network connection port when network connection abnormality occurs, so that the system host is not relied on, the reliability of the system is not influenced, and the use cost and the installation space requirement are reduced because a dual-network card or a network management type switch is not used.
In a first aspect, an embodiment of the present application provides a dual redundancy network communication switching method, where the dual redundancy network communication switching method includes the following steps:
periodically inquiring the connection state of the PHY port of the dual-redundancy physical layer interface device of the non-management network exchange chip by utilizing the singlechip, and judging whether the PHY port is physically connected or not;
based on the spanning tree protocol, and according to the connection state of the PHY port, dynamically adjusting the spanning tree state of the PHY port to complete the PHY port switching.
With reference to the first aspect, in one implementation manner, the dynamically adjusting the spanning tree state of the PHY port according to the connection state of the PHY port based on the spanning tree protocol to complete the PHY port switching includes:
Initializing the spanning tree state of the PHY ports, so that the spanning tree state of one PHY port is a forward state, and the spanning tree state of the other PHY port is a block state;
And dynamically adjusting according to the connection state result of the PHY ports periodically queried by the singlechip, setting the PHY ports with physical connection to be in forward state, and setting the other PHY ports to be in block state so as to finish PHY port switching.
With reference to the first aspect, in an implementation manner, the periodically querying, by using the single chip microcomputer, a connection state of a PHY port of the dual-redundancy physical layer interface device of the non-management network switch chip, and determining whether the PHY port has a physical connection includes:
and periodically inquiring the functional register address 0x01H of the PHY chip in the PHY port by using the singlechip to judge whether the PHY port has physical connection.
In a second aspect, an embodiment of the present application provides a dual redundancy network communication switching apparatus, which is characterized in that the dual redundancy network communication switching apparatus includes:
The inquiry module is used for periodically inquiring the connection state of the PHY ports of the dual-redundancy physical layer interface device of the non-management network switching chip based on the singlechip and judging whether the PHY ports are physically connected or not;
And the switching module is based on a spanning tree protocol and dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port so as to finish PHY port switching.
With reference to the second aspect, in one implementation manner, the switching module dynamically adjusts a spanning tree state of the PHY port according to a connection state of the PHY port based on a spanning tree protocol to complete PHY port switching, including:
Initializing the spanning tree state of the PHY ports, so that the spanning tree state of one PHY port is a forward state, and the spanning tree state of the other PHY port is a block state;
And dynamically adjusting according to the connection state result of the PHY ports periodically queried by the singlechip, setting the PHY ports with physical connection to be in forward state, and setting the other PHY ports to be in block state so as to finish PHY port switching.
With reference to the second aspect, in an implementation manner, the query module periodically queries, based on the single chip microcomputer, a connection state of a PHY port of a dual-redundancy physical layer interface device of the non-management network switch chip, and determines whether the PHY port has a physical connection, including:
And periodically inquiring the functional register address 0x01H of the PHY chip in the PHY port based on the singlechip to judge whether the PHY port has physical connection.
In a third aspect, an embodiment of the present application provides a dual-redundancy network communication switching system, where the dual-redundancy network communication switching system includes an embedded real-time operation platform and a switch;
The embedded real-time operation platform comprises a singlechip, and the switch comprises an unmanaged network switching chip;
The singlechip is used for periodically inquiring the connection state of the PHY port of the dual-redundancy physical layer interface device of the non-management network exchange chip and judging whether the PHY port is physically connected or not;
The singlechip is also based on a spanning tree protocol, and dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port so as to complete PHY port switching.
With reference to the third aspect, in one implementation manner, the single chip microcomputer is configured to:
Initializing the spanning tree state of the PHY ports, so that the spanning tree state of one PHY port is a forward state, and the spanning tree state of the other PHY port is a block state;
And dynamically adjusting according to the connection state result of the PHY ports which are periodically queried, setting the PHY ports with physical connection to be in a forward state, and setting the other PHY ports to be in a block state so as to finish PHY port switching.
With reference to the third aspect, in one implementation manner, a PHY chip is disposed in the PHY port, and the single chip microcomputer is configured to query a functional register address 0x01H of the PHY chip to determine whether the PHY port has a physical connection.
With reference to the third aspect, in one implementation manner, the single chip microcomputer and the unmanaged network switching chip are connected through a media independent interface.
The technical scheme provided by the embodiment of the application has the beneficial effects that at least:
The dual-redundancy network communication switching method of the application periodically inquires the connection state of the PHY ports of dual-redundancy physical layer interface equipment of a non-management network switching chip by utilizing a singlechip, judges whether the PHY ports are physically connected or not, dynamically adjusts the spanning tree state of the PHY ports based on a spanning tree protocol according to the connection state of the PHY ports, and completes the PHY port switching. The application adopts the singlechip to periodically inquire the connection state of the PHY port of the non-management network exchange chip in the main program, and when network connection abnormality occurs, the connection state is automatically switched to the backup network connection port, the system host is not depended, the system reliability is not affected, and the use cost and the installation space requirement are reduced because the double network card or the network management type switch is not used.
Drawings
FIG. 1 is a flow chart of a dual redundant network communication switching method according to an embodiment of the present application;
FIG. 2 is a flow chart of an implementation of the dual redundant network of the present application;
FIG. 3 is a block diagram illustrating an embodiment of a dual redundant network communication switching device according to the present application;
FIG. 4 is a block diagram illustrating an embodiment of a dual redundant network communication switching system of the present application;
FIG. 5 is a schematic diagram of the internal information cross-linking of the dual redundant network of the present application.
Detailed Description
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The terms "comprising" and "having" and any variations thereof in the description and claims of the application and in the foregoing drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those listed steps or elements but may include other steps or elements not listed or inherent to such process, method, article, or apparatus. The terms "first," "second," and "third," etc. are used for distinguishing between different objects and not necessarily for describing a sequential or chronological order, and are not limited to the fact that "first," "second," and "third" are not identical.
In describing embodiments of the present application, "exemplary," "such as," or "for example," etc., are used to indicate by way of example, illustration, or description. Any embodiment or design described herein as "exemplary," "such as" or "for example" is not necessarily to be construed as preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary," "such as" or "for example," etc., is intended to present related concepts in a concrete fashion.
In the description of the embodiment of the present application, "/" means or, for example, a/B may mean a or B, and "and/or" in the text is merely an association relationship describing an association object, means that three relationships may exist, for example, a and/or B, three cases where a exists alone, a and B exist together, and B exists alone, and further, in the description of the embodiment of the present application, "a plurality" means two or more.
In some of the processes described in the embodiments of the present application, a plurality of operations or steps occurring in a particular order are included, but it should be understood that the operations or steps may be performed out of the order in which they occur in the embodiments of the present application or in parallel, the sequence numbers of the operations merely serve to distinguish between the various operations, and the sequence numbers themselves do not represent any order of execution. In addition, the processes may include more or fewer operations, and the operations or steps may be performed in sequence or in parallel, and the operations or steps may be combined.
For the purpose of making the objects, technical solutions and advantages of the present application more apparent, the embodiments of the present application will be described in further detail with reference to the accompanying drawings.
In a first aspect, an embodiment of the present application provides a dual redundancy network communication handover method.
In an embodiment, referring to fig. 1, fig. 1 is a flow chart illustrating an embodiment of a dual redundancy network communication handover method according to the present application. As shown in fig. 1, the dual redundancy network communication switching method includes:
S1, periodically inquiring the connection state of a PHY port of dual-redundancy physical layer interface equipment of a non-management network exchange chip by utilizing a singlechip, and judging whether the PHY port is physically connected or not;
s2, based on a spanning tree protocol, dynamically adjusting the spanning tree state of the PHY port according to the connection state of the PHY port so as to complete PHY port switching.
Specifically, the Protocol of the dual redundant network in the present embodiment adopts STP (SPANNING TREE Protocol ). The main idea of STP is that when redundant links are present, only the main link is allowed to be active, and if the main link is disconnected due to a failure, the standby link is opened. STP spanning tree is a protocol for building loop-free network structures. STP can build a spanning tree by selecting a root node, thereby avoiding loops in the network. A spanning tree is a sub-graph that contains all network nodes that connects all nodes by connecting a minimal set of edges while maintaining loop-free. The STP protocol spanning tree has the function of prohibiting unnecessary connection, and the dual redundancy function can realize simultaneous access of two network wires to avoid conflict by utilizing the function of the spanning tree.
In this embodiment, each PHY port of the switch has a PHY chip, and the address 0x01H of the function register (BASIC STATUS REGISTER) of each PHY chip is read to determine whether the PHY terminal has physical connection. Setting the spanning tree state of the non-management network switching chip storage register port as a forward state or a block state. And periodically reading the state of the PHY port in the main cycle of the singlechip program, setting the PHY port with physical connection to be in a forward state, setting the other PHY port to be in a block state, completing network port switching, and realizing a dual-redundancy network function.
Specifically, see fig. 2:
Step 1, initializing spanning tree states of a dual redundant PHY port, namely port1, forward state, port2 and block state;
step 2, reading PHY port connection states of port1 and port2 in a main cycle period of a singlechip program;
step 3, judging whether the PHY port of the port1 or the port2 is in a connection state, if not, returning to the step 2, and if so, executing the step 4;
Step 4, reading the PHY port spanning tree state in the connection state;
Step 5, judging whether the PHY port generation tree state in the connection state is a forward state or not, if so, returning to the step 2, and if not, executing the step 6;
It can be understood that the initialization is default that the PHY port of port1 is in a connection state, if the PHY port of port1 is still in a connection state during periodic reading, the PHY port of port1 is kept as it is, if the PHY port of port1 is not in a connection state, the standby link is opened after the connection state is broken;
and 6, setting the PHY port to be in a forward state, and returning to the step 2.
Thus, the network port switching is completed, and the dual redundancy network function is realized.
It can be understood that the application adopts the non-management network exchange chip to complete the receiving and transmitting of network data, bears the function of dual redundant interfaces, and periodically inquires the PHY network connection state in the main program by the singlechip, and when the network connection is abnormal, the application automatically switches to the backup network connection port, and the switching time is consistent with the sampling period of the system. The test result shows that the switching delay time of the dual-redundancy network is within 20 ms;
in addition, the invention increases the reliability of network transmission, realizes transparent switching on the client, does not affect the system task, and realizes the dual redundancy network function under the condition of not increasing the IP address.
The application has the advantages of simple structure, low cost and easy operation, and can realize the data processing without depending on the system host computer, and has no influence on the system reliability.
In summary, the dual-redundancy network communication switching method of the present application periodically queries the connection state of the PHY port of the dual-redundancy physical layer interface device of the non-management network switching chip by using the singlechip to determine whether the PHY port has physical connection, and dynamically adjusts the spanning tree state of the PHY port based on the spanning tree protocol according to the connection state of the PHY port to complete the PHY port switching. The application adopts the singlechip to periodically inquire the connection state of the PHY port of the non-management network exchange chip in the main program, and when network connection abnormality occurs, the connection state is automatically switched to the backup network connection port, the system host is not depended, the system reliability is not affected, and the use cost and the installation space requirement are reduced because the double network card or the network management type switch is not used.
In a second aspect, the embodiment of the application further provides a dual-redundancy network communication switching device.
In an embodiment, referring to fig. 3, fig. 3 is a schematic functional block diagram of an embodiment of a dual redundancy network communication switching apparatus according to the present application. As shown in fig. 3, the dual redundancy network communication switching apparatus includes a query module and a switching module.
The query module periodically queries the connection state of the PHY ports of the dual-redundancy physical layer interface device of the non-management network switching chip based on the singlechip and judges whether the PHY ports are physically connected or not;
And the switching module is based on a spanning tree protocol and dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port so as to finish PHY port switching.
Further, in an embodiment, the switching module dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port based on the spanning tree protocol to complete the PHY port switching, including:
Initializing the spanning tree state of the PHY ports, so that the spanning tree state of one PHY port is a forward state, and the spanning tree state of the other PHY port is a block state;
And dynamically adjusting according to the connection state result of the PHY ports periodically queried by the singlechip, setting the PHY ports with physical connection to be in forward state, and setting the other PHY ports to be in block state so as to finish PHY port switching.
Further, in an embodiment, the query module periodically queries the connection state of the PHY port of the dual-redundancy physical layer interface device of the non-management network switch chip based on the singlechip, and determines whether the PHY port has physical connection, including:
And periodically inquiring the functional register address 0x01H of the PHY chip in the PHY port based on the singlechip to judge whether the PHY port has physical connection.
In a third aspect, the embodiment of the application further provides a dual-redundancy network communication switching system.
In one embodiment, referring to fig. 4, fig. 4 is a block diagram illustrating an embodiment of a dual redundancy network communication switching system according to the present application. As shown in fig. 4, the dual redundant network communication switching system includes an embedded real-time operation platform and a switch.
The embedded real-time operation platform comprises a singlechip, and the switch comprises a non-management network switching chip;
The singlechip is used for periodically inquiring the connection state of the PHY port of the dual-redundancy physical layer interface device of the non-management network exchange chip and judging whether the PHY port is physically connected or not;
The singlechip is also based on a spanning tree protocol, and dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port so as to complete PHY port switching.
Referring to fig. 5, the following describes a single chip and an unmanaged network switching chip in the present application:
a) Chip introduction
1) The core CPU adopts a 32-bit ARM chip, the model of the singlechip is GD32F407VET6, the main frequency reaches more than 100M, and the network communication is realized by an MII interface;
2) The non-management network switching chip is of a SW8328 type, the SW8328 integrates 8-channel gigabit electric interface PHY, supports 10/100/1000BASE-T and 100BASE-FX functions, and supports 1-channel GMII or 2-channel MII/RGMII interfaces as extensible management interfaces.
B) Power supply
The external power supply interface of the 28VDC is provided, and the external power supply interface is converted into 3.3V power supply to GD32, and is converted into +1.1V, +2.5V and +3.3V power supply to the unmanaged network switching chip SW8328
Rated operating voltage is 28VDC (general DC consumer: 22.0V-30.0V).
Product power consumption: the system power is less than or equal to 4W.
C) Communication system
1) The singlechip and the non-management network exchange chip are interconnected through a media independent interface (MII interface) to support data transmission modes of 10Mbit/s and 100 Mbit/s.
2) The MII signal of the single chip MAC controller and the non-management network exchange chip PHY comprises:
3) ETH_MII_TX_CLK, a clock signal used to transmit data, the present scheme uses 100Mbit/s of data transmission, this clock being 25MHz.
4) ETH_MII_RX_CLK, a clock signal used to receive data, the present scheme uses 100Mbit/s data transmission, this clock being 25MHz.
5) ETH_MII_TX_EN, send enable signal, hold until transmission is completed.
6) ETH_MII_TXD [3:0]: transmit data lines, 4 bits of data per transmission, the data being valid when the MII_TX_EN signal is valid. MII_TXD [0] is the least significant bit of data, and MII_TXD [3] is the most significant bit. When the mii_tx_en signal is inactive, the PHY ignores the transmitted data.
7) The ETH_MII_CRS is controlled by the non-management network switching chip PHY only in a half-duplex mode, and the scheme PHY works in a full-duplex mode and is negligible.
8) The ETH_MII_COL collision detection signal only works in a half-duplex mode and is controlled by the non-management network switching chip PHY, and the scheme PHY works in a full-duplex mode and is therefore negligible.
9) ETH_MII_RXD [3:0]: receive data lines, 4 bits of data each time, the data being valid when the MII_RX_DV signal is valid. MII_RXD [0] is the lowest bit of data, and MII_RXD [3] is the highest bit.
10 Etc_mii_rx_dv, receive data enable signal, controlled by PHY, which is active when PHY is ready for data reception by MAC. This signal must appear in synchronization with the first 4 bits of frame data and remain active until the data transfer is complete. This signal must go inactive before the first clock after the last 4 bits of data are transferred.
11 ETH_MII_RX_ER) receives an error signal, maintains the active state for one or more clock cycles (MII_RX_CLK), indicating that the MAC detected an error during reception.
12 The singlechip MAC controller is communicated with the ETH_MDIO data line and the non-management network exchange chip through the ETH_MDC clock line, and can access any register of the external physical layer interface PHY.
13 Eth_mdc, a clock signal with a maximum frequency of 2.5MHz, the pin is kept in a low state in the idle state. The minimum hold time of the high level and the low level of the signal is 160ns when data is transmitted, and the minimum period of the signal is 400ns;
14 Etc_mdio for data transmission with PHY, and receiving/transmitting data in cooperation with MDC clock line.
After the dual-redundancy network communication switching system in the embodiment is adopted, the specific implementation effect is as follows:
1) The Ethernet A is connected with external equipment;
2) The Ethernet B is connected with external equipment;
3) The Ethernet A and the Ethernet B are simultaneously connected and disconnected with any network cable, and connection is established within 20ms of the other network cable;
4) The Ethernet A or the Ethernet B is connected with only one network cable (such as the Ethernet A), the other network cable (such as the Ethernet B), the Ethernet (such as the Ethernet A) communicated before disconnection, and the Ethernet B can still be connected.
Further, in an embodiment, the single chip microcomputer is configured to:
Initializing the spanning tree state of the PHY ports, so that the spanning tree state of one PHY port is a forward state, and the spanning tree state of the other PHY port is a block state;
And dynamically adjusting according to the connection state result of the PHY ports which are periodically queried, setting the PHY ports with physical connection to be in a forward state, and setting the other PHY ports to be in a block state so as to finish PHY port switching.
Further, in an embodiment, a PHY chip is disposed in the PHY port, and the single chip microcomputer is configured to query a function register address 0x01H of the PHY chip to determine whether the PHY port has physical connection.
Further, in an embodiment, the single chip microcomputer is connected to the unmanaged network switching chip through a media independent interface.
The foregoing description is only of the preferred embodiments of the present application, and is not intended to limit the scope of the application, but rather is intended to cover any equivalents of the structures or equivalent processes disclosed herein or in the alternative, which may be employed directly or indirectly in other related arts.

Claims (10)

1.一种双冗余网络通信切换方法,其特征在于,所述双冗余网络通信切换方法包括:1. A dual redundant network communication switching method, characterized in that the dual redundant network communication switching method comprises: 利用单片机周期性查询非管理型网络交换芯片的双冗余物理层接口设备PHY端口的连接状态,判断PHY端口是否有物理连接;The single-chip microcomputer is used to periodically query the connection status of the dual redundant physical layer interface device PHY port of the unmanaged network switching chip to determine whether the PHY port has a physical connection; 基于生成树协议,并根据PHY端口的连接状态,动态调整PHY端口的生成树状态,以完成PHY端口切换。Based on the spanning tree protocol and according to the connection status of the PHY port, the spanning tree status of the PHY port is dynamically adjusted to complete the PHY port switching. 2.如权利要求1所述的双冗余网络通信切换方法,其特征在于,所述基于生成树协议,并根据PHY端口的连接状态,动态调整PHY端口的生成树状态,以完成PHY端口切换,包括:2. The dual redundant network communication switching method according to claim 1, wherein the spanning tree state of the PHY port is dynamically adjusted based on the spanning tree protocol and according to the connection state of the PHY port to complete the PHY port switching, comprising: 初始化PHY端口的生成树状态,使得一个PHY端口的生成树状态为forward状态,另一个PHY端口的生成树状态为block状态;Initialize the spanning tree state of the PHY port so that the spanning tree state of one PHY port is in the forward state and the spanning tree state of the other PHY port is in the block state; 根据单片机周期性查询的PHY端口的连接状态结果,进行动态调整,将有物理连接的PHY端口设置为forward状态,将另一PHY端口设置为block状态,以完成PHY端口切换。According to the connection status result of the PHY port periodically queried by the single-chip microcomputer, dynamic adjustment is performed to set the PHY port with physical connection to the forward state and set the other PHY port to the block state to complete the PHY port switching. 3.如权利要求1所述的双冗余网络通信切换方法,其特征在于,所述利用单片机周期性查询非管理型网络交换芯片的双冗余物理层接口设备PHY端口的连接状态,判断PHY端口是否有物理连接,包括:3. The dual redundant network communication switching method according to claim 1, wherein the step of periodically querying the connection status of the dual redundant physical layer interface device PHY port of the unmanaged network switch chip using the single chip microcomputer to determine whether the PHY port has a physical connection comprises: 利用单片机周期性查询PHY端口内的PHY芯片的功能寄存器地址0x01H,以判断该PHY端口是否有物理连接。The single-chip microcomputer is used to periodically query the function register address 0x01H of the PHY chip in the PHY port to determine whether the PHY port has a physical connection. 4.一种双冗余网络通信切换装置,其特征在于,所述双冗余网络通信切换装置包括:4. A dual-redundancy network communication switching device, characterized in that the dual-redundancy network communication switching device comprises: 查询模块,其基于单片机周期性查询非管理型网络交换芯片的双冗余物理层接口设备PHY端口的连接状态,判断PHY端口是否有物理连接;A query module, which periodically queries the connection status of the dual redundant physical layer interface device PHY port of the unmanaged network switch chip based on the single chip microcomputer, and determines whether the PHY port has a physical connection; 切换模块,其基于生成树协议,并根据PHY端口的连接状态,动态调整PHY端口的生成树状态,以完成PHY端口切换。The switching module is based on the spanning tree protocol and dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port to complete the PHY port switching. 5.如权利要求4所述的双冗余网络通信切换装置,其特征在于,所述切换模块基于生成树协议,并根据PHY端口的连接状态,动态调整PHY端口的生成树状态,以完成PHY端口切换,包括:5. The dual redundant network communication switching device according to claim 4, wherein the switching module is based on the spanning tree protocol and dynamically adjusts the spanning tree state of the PHY port according to the connection state of the PHY port to complete the PHY port switching, comprising: 初始化PHY端口的生成树状态,使得一个PHY端口的生成树状态为forward状态,另一个PHY端口的生成树状态为block状态;Initialize the spanning tree state of the PHY port so that the spanning tree state of one PHY port is in the forward state and the spanning tree state of the other PHY port is in the block state; 根据单片机周期性查询的PHY端口的连接状态结果,进行动态调整,将有物理连接的PHY端口设置为forward状态,将另一PHY端口设置为block状态,以完成PHY端口切换。According to the connection status result of the PHY port periodically queried by the single-chip microcomputer, dynamic adjustment is performed to set the PHY port with physical connection to the forward state and set the other PHY port to the block state to complete the PHY port switching. 6.如权利要求4所述的双冗余网络通信切换装置,其特征在于,所述查询模块基于单片机周期性查询非管理型网络交换芯片的双冗余物理层接口设备PHY端口的连接状态,判断PHY端口是否有物理连接,包括:6. The dual-redundant network communication switching device according to claim 4, characterized in that the query module periodically queries the connection status of the dual-redundant physical layer interface device PHY port of the unmanaged network switching chip based on the single-chip microcomputer to determine whether the PHY port has a physical connection, comprising: 基于单片机周期性查询PHY端口内的PHY芯片的功能寄存器地址0x01H,以判断该PHY端口是否有物理连接。The single-chip microcomputer periodically queries the function register address 0x01H of the PHY chip in the PHY port to determine whether the PHY port has a physical connection. 7.一种双冗余网络通信切换系统,其特征在于:所述双冗余网络通信切换系统包括嵌入式实时操作平台和交换机;7. A dual-redundant network communication switching system, characterized in that: the dual-redundant network communication switching system comprises an embedded real-time operating platform and a switch; 所述嵌入式实时操作平台包括单片机,所述交换机包括非管理型网络交换芯片;The embedded real-time operating platform includes a single-chip microcomputer, and the switch includes an unmanaged network switching chip; 所述单片机用于周期性查询非管理型网络交换芯片的双冗余物理层接口设备PHY端口的连接状态,判断PHY端口是否有物理连接;The single chip microcomputer is used to periodically query the connection status of the dual redundant physical layer interface device PHY port of the unmanaged network switching chip to determine whether the PHY port has a physical connection; 所述单片机还基于生成树协议,并根据PHY端口的连接状态,动态调整PHY端口的生成树状态,以完成PHY端口切换。The single chip microcomputer also dynamically adjusts the spanning tree state of the PHY port based on the spanning tree protocol and according to the connection state of the PHY port to complete the PHY port switching. 8.如权利要求7所述的双冗余网络通信切换系统,其特征在于,所述单片机用于:8. The dual redundant network communication switching system according to claim 7, wherein the single chip microcomputer is used for: 初始化PHY端口的生成树状态,使得一个PHY端口的生成树状态为forward状态,另一个PHY端口的生成树状态为block状态;Initialize the spanning tree state of the PHY port so that the spanning tree state of one PHY port is in the forward state and the spanning tree state of the other PHY port is in the block state; 根据周期性查询的PHY端口的连接状态结果,进行动态调整,将有物理连接的PHY端口设置为forward状态,将另一PHY端口设置为block状态,以完成PHY端口切换。According to the connection status result of the PHY port periodically queried, dynamic adjustment is performed to set the PHY port with physical connection to the forward state and set the other PHY port to the block state to complete the PHY port switching. 9.如权利要求7所述的双冗余网络通信切换系统,其特征在于:9. The dual redundant network communication switching system according to claim 7, characterized in that: 所述PHY端口内设有PHY芯片,所述单片机用于查询PHY芯片的功能寄存器地址0x01H,以判断该PHY端口是否有物理连接。The PHY port is provided with a PHY chip, and the single chip microcomputer is used to query the function register address 0x01H of the PHY chip to determine whether the PHY port has a physical connection. 10.如权利要求7所述的双冗余网络通信切换系统,其特征在于:10. The dual redundant network communication switching system according to claim 7, characterized in that: 所述单片机和非管理型网络交换芯片通过介质无关接口相连。The single chip microcomputer and the unmanaged network switching chip are connected via a medium-independent interface.
CN202411263894.3A 2024-09-10 2024-09-10 Dual redundant network communication switching method, device and system Pending CN119071142A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202411263894.3A CN119071142A (en) 2024-09-10 2024-09-10 Dual redundant network communication switching method, device and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202411263894.3A CN119071142A (en) 2024-09-10 2024-09-10 Dual redundant network communication switching method, device and system

Publications (1)

Publication Number Publication Date
CN119071142A true CN119071142A (en) 2024-12-03

Family

ID=93633588

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202411263894.3A Pending CN119071142A (en) 2024-09-10 2024-09-10 Dual redundant network communication switching method, device and system

Country Status (1)

Country Link
CN (1) CN119071142A (en)

Similar Documents

Publication Publication Date Title
US6349331B1 (en) Multiple channel communication system with shared autonegotiation controller
US6859825B1 (en) System and method enabling configuration of physical layer devices and corresponding link partners for communicating network data via a configuration source or auto-negotiation
US8514877B2 (en) Method and system for a plurality of physical layers for network connection
EP0766434B1 (en) A method and system for performing auto-negotiation for a group of interface devices
EP0967758B1 (en) Media access control
US5884041A (en) Method and apparatus for monitoring auto-negotiation progress
US8452996B2 (en) Operating mode for extreme power savings when no network presence is detected
CN102185753B (en) Device for realizing dual-backup switching of Ethernet link inside communication equipment
US11500901B2 (en) Apparatuses and methods involving synchronization using data in the data/address field of a communications protocol
US20050259685A1 (en) Dual speed interface between media access control unit and physical unit
EP0952705A2 (en) Media access controller capable of connecting to a serial physical layer device and a media independent interface (MII) physical layer device
JP2000209220A (en) Computer, network controller, system using them and remote start method
US10996950B2 (en) Apparatuses and methods involving selective disablement of side effects caused by accessing register sets
US20020124110A1 (en) Media converter and link test technique using the same
WO2007107624A2 (en) Method for the resolution of addresses in a communication system
CN106487679A (en) The active-standby switch system of Ethernet switch and changing method
CN104009867A (en) A switching method of an FPGA-based fiber optic Ethernet intelligent splitter
US6507591B1 (en) Handshaking between repeater and physical layer device in a variable rate network transceiver
US7668194B2 (en) Dual speed interface between media access control unit and physical unit
US10999097B2 (en) Apparatuses and methods involving first type of transaction registers mapped to second type of transaction addresses
EP0963080B1 (en) Network transceiver having media independent interface
US7428599B2 (en) Method for detecting link partner state during auto negotiation and switching local state to establish link
US7339902B2 (en) Repeater for performing auto-negotiation between two node devices in a network
CN119071142A (en) Dual redundant network communication switching method, device and system
CN115842871A (en) Network port communication bridging and management method based on multi-type PHY chip

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination