Ethernet loop chain communication system and method
By configuring a one-way communication interface for the control node and a local area network broadcast IP in the energy storage system, the problem of indiscriminate forwarding of broadcast frames in a ring topology network is solved, achieving efficient and reliable data transmission and rapid fault recovery, adapting to the high real-time requirements and flexible deployment of energy storage systems.
Patent Information
- Application Number
- CN202610136824.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-30
- Publication Date
- 2026-05-08
AI Technical Summary
In energy storage systems, the indiscriminate copying and forwarding of broadcast frames in a ring topology network leads to excessive network bandwidth consumption, which may cause network paralysis and system crashes. Furthermore, single-point disconnection can cause communication interruptions, affecting battery management and control command transmission.
The first communication interface of the control node is configured to be able to send and receive, while the second communication interface is configured to send only, forming a one-way communication network. In the event of a link failure, the second communication interface of the control node switches to be able to send and receive, ensuring that data is transmitted along a bidirectional path, and performs rapid fault detection and recovery by broadcasting IP and UDP protocols over the local area network.
It enables efficient and reliable data transmission in energy storage systems, avoids network storms, supports arbitrary node expansion, reduces deployment and maintenance costs, adapts to high real-time requirements, and ensures uninterrupted communication.
Smart Images

Figure CN122001707A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to an Ethernet ring chain communication system and method. Background Technology
[0002] In energy storage systems, a stable network topology needs to be built via Ethernet to achieve efficient communication between nodes. When using Ethernet as the master communication method for the energy storage system, if a daisy-chain network topology is used, communication between all subsequent nodes will be completely interrupted when a single point of failure occurs. This will prevent the uploading of core data (such as battery voltage and temperature) and the issuance of control commands, potentially leading to serious consequences such as battery overcharging, over-discharging, and system shutdown. To improve communication reliability, the industry generally upgrades the network topology to a ring structure, ensuring that the master control node can still maintain communication with all master control nodes through the reverse path when a single point of failure occurs.
[0003] When applying ring topology to energy storage systems, the following problems exist: After a broadcast frame is sent from a certain node, it continues to flow along the ring path. The broadcast frame may be copied and forwarded indiscriminately within the network, occupying all network bandwidth, which may eventually lead to network paralysis and system crash. Summary of the Invention
[0004] This invention provides an Ethernet ring link communication system and method to address at least one deficiency in the prior art.
[0005] In a first aspect, embodiments of the present invention provide an Ethernet ring chain communication system, comprising:
[0006] Several control nodes, which form a ring-chain communication network topology;
[0007] The control node includes a first communication interface and a second communication interface, which are connected in series in a ring-chain communication network for communication between different control nodes.
[0008] In each of the control nodes, the second communication interface is configured to send but not receive, and the first communication interface is configured to send and receive. In this case, the ring chain communication network supports one-way communication.
[0009] When at least one of the control nodes disconnects its second communication interface from the ring chain communication network, the second communication interface in the control node is configured to be both transmit and receive.
[0010] Optionally, the control node includes a switch module and a controller module;
[0011] The switch module is configured with a first communication interface, a second communication interface, and a third communication interface, and the switch module communicates with the controller module through the third communication interface.
[0012] The controller module is configured to allow the second communication interface to either transmit only or receive.
[0013] Optionally, the control node is configured as follows:
[0014] When a control node’s second communication interface is disconnected from the ring-chain communication network, in the one-way communication direction, the next control node adjacent to the faulty second communication interface sends a first broadcast message to the ring-chain communication network.
[0015] When the other control nodes receive the first broadcast message, they configure their corresponding second communication interface to be able to send and receive.
[0016] Optionally, the control nodes are configured with the same local area network broadcast IP, and the first broadcast message is configured to be sent to the local area network broadcast IP.
[0017] Optionally, the first broadcast message is transmitted using the UDP protocol.
[0018] Optionally, the control node includes a central control node and several master control nodes;
[0019] The master control node is configured to, upon receiving the first broadcast message, determine the location of the master control node whose second communication interface is disconnected based on the first broadcast message, and generate and send fault alarm information for that master control node.
[0020] Optionally, when the disconnected second communication interface is reconnected to the ring chain communication network, the control node that configured the second communication interface sends a second broadcast message to the ring chain communication network.
[0021] Upon receiving the second broadcast message, the control node controls its corresponding second communication interface to switch to a transmit-only mode.
[0022] Optionally, the master control node is further configured to send TCP packets to the master control node through the ring chain communication network.
[0023] Optionally, the switch module includes a switch chip configured to generate an interrupt when the second communication interface is disconnected;
[0024] The controller module is configured to determine that the second communication interface is disconnected from the ring-chain communication network when the interruption is detected.
[0025] Optionally, this also includes creating a static MAC address table;
[0026] In each control node, the first communication interface is configured to be both transmit and receive, including:
[0027] The first communication interface is configured to allow sending data to the target MAC address pre-stored in the static MAC address table; and to allow receiving data from the broadcast MAC address pre-stored in the static MAC address table.
[0028] The second communication interface is configured to only send and not receive, including:
[0029] Configure the second communication interface to disable physical layer reception, allowing data to be sent to target MAC addresses pre-stored in the static MAC address table.
[0030] Optionally, when the second communication interface of at least one control node is disconnected from the ring chain communication network, the second communication interface in the control node is configured to be transmit-and-receive, including:
[0031] Configure the second communication interface to receive at the physical layer, and configure the second communication interface to allow receiving data from broadcast MAC addresses pre-stored in the static MAC address table.
[0032] Secondly, embodiments of the present invention also provide an Ethernet ring link communication method, applicable to any Ethernet ring link communication system described in the embodiments of the present invention, the method comprising:
[0033] In each control node, the second communication interface is configured to transmit only and not receive, and the first communication interface is configured to transmit and receive. At this time, the ring chain communication network supports one-way communication.
[0034] When at least one of the control nodes disconnects its second communication interface from the ring chain communication network, the second communication interface in the control node is configured to be transmit-and-receive.
[0035] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0036] 1. In the system proposed in this invention, all control nodes are configured identically, without needing to distinguish roles. As long as the control node supports basic Ethernet transmission, it can access the ring chain communication network. Adding new nodes only requires physical concatenation, supporting expansion of any number of nodes without modifying the system architecture, resulting in high deployment efficiency and low maintenance costs. Under normal operating conditions, by configuring the second communication interface P2 to only transmit and not receive, data frames cannot circulate in the ring chain communication network, eliminating reliance on protocol stability and providing a more direct and reliable way to prevent network storms.
[0037] 2. The system proposed in this invention can be applied to energy storage scenarios. It can detect whether the second communication interface P2 is disconnected through the control node, and configure the second communication interface P2 to only transmit and not receive or to both transmit and receive. Through the detection by Ying Jianhua and the simplified configuration logic, it has low resource occupancy, convenient deployment and maintenance, and adapts to the high real-time and flexible deployment requirements of energy storage systems. Attached Figure Description
[0038] Figure 1 This is a block diagram of the Ethernet ring link communication system in the embodiment;
[0039] Figure 2 This is a block diagram of the control node structure in the embodiment;
[0040] Figure 3 This is another control node structure block diagram in the embodiment;
[0041] Figure 4 This is a schematic diagram of unidirectional communication in the ring chain in the embodiment;
[0042] Figure 5 This is a schematic diagram of the broken chain in the embodiment;
[0043] Figure 6 This is a schematic diagram of the broken chain topology in the embodiment;
[0044] Figure 7 This is a flowchart of the Ethernet ring chain communication method in the embodiment. Detailed Implementation
[0045] The present invention will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and not intended to limit it. Furthermore, it should be noted that, for ease of description, the accompanying drawings show only the parts relevant to the present invention, and not all of the structures.
[0046] Example 1
[0047] Figure 1 This is a block diagram of the Ethernet ring link communication system in the embodiment, for reference. Figure 1 The Ethernet ring link communication system includes several control nodes (e.g., control nodes 1 to 4), which form a ring link communication network topology.
[0048] The control node includes a first communication interface P1 and a second communication interface P2. The first communication interface P1 and the second communication interface P2 are connected in series in the ring chain communication network for communication between different control nodes.
[0049] In each control node, the second communication interface P2 is configured to send but not receive, and the first communication interface P1 is configured to send and receive. In this case, the ring chain communication network supports unidirectional communication.
[0050] When the second communication interface P2 of at least one control node is disconnected from the ring chain communication network, the second communication interface P2 in the control node is configured to be able to send and receive.
[0051] In this scheme, the first communication interface P1 and the second communication interface P2 are both transmit and receive interfaces, meaning that either interface has data sending and receiving permissions. They can transmit data frames (such as TCP packets, UDP broadcast packets, etc.) to the next connected control node and receive data frames transmitted from the previous connected control node. The second communication interface P2 is transmit-only, meaning that this interface only has data sending permissions. It can transmit data frames outwards without affecting the unidirectional forwarding of data, but it disables data receiving permissions and refuses to receive data frames from external sources.
[0052] In this scheme, the control nodes are connected in series through their respective first communication interface P1 and second communication interface P2. The second communication interface P2 of control node 1 is connected to the first communication interface P1 of control node 2; the second communication interface P2 of control node 2 is connected to the first communication interface P1 of control node 3; the second communication interface P2 of control node 3 is connected to the first communication interface P1 of control node 4; and the second communication interface P2 of control node 4 is connected to the first communication interface P1 of control node 1, forming a closed loop chain.
[0053] In this scheme, each control node is configured by default to send only on its second communication interface P2 and not receive, while its first communication interface P1 can both send and receive. In this case, data frames are transmitted in a single direction (e.g., clockwise) in the ring-link communication network. Because the second communication interface P2 only sends and does not receive, data frames in the ring-link communication network cannot be circulated within the ring, thus preventing network storms.
[0054] In this scheme, when the second communication interface P2 of any control node is disconnected (such as when the network cable between the second communication interface P2 of control node 2 and the first communication interface P1 of control node 3 is disconnected), all control nodes configure their second communication interface P2 to switch to send and receive mode. At this time, data frames can be transmitted along a bidirectional path, ensuring the overall connectivity of the ring link.
[0055] In this solution, all control nodes are configured identically, without needing to differentiate roles. As long as the control node supports basic Ethernet transmission, it can access the ring chain communication network. Adding new nodes only requires physical concatenation, supporting expansion of any number of nodes without modifying the system architecture. This results in high deployment efficiency and low maintenance costs. Under normal operating conditions, by configuring the second communication interface P2 to only transmit and not receive, data frames cannot circulate in the ring chain communication network. This eliminates reliance on protocol stability and provides a more direct and reliable way to prevent network storms.
[0056] The system proposed in this solution is applicable to energy storage scenarios. It can detect whether the second communication interface P2 is disconnected through the control node, and configure the second communication interface P2 to only transmit and not receive or to both transmit and receive. With the detection by Ying Jianhua and the simplified configuration logic, it has low resource consumption, convenient deployment and maintenance, and is suitable for the high real-time and flexible deployment requirements of energy storage systems.
[0057] Figure 2 This is a block diagram of the control node structure in the embodiment, for reference. Figure 2 As one possible implementation, the control node includes a switch module and a controller module.
[0058] The switch module is configured with a first communication interface P1, a second communication interface P2, and a third communication interface P3. The switch module communicates with the controller module through the third communication interface P3. The controller module is configured to configure the second communication interface P2 to either transmit only or receive.
[0059] In this solution, the controller module can be a microcontroller unit (MCU), and the switch module can include a switch chip that supports basic Ethernet.
[0060] In this solution, the third communication interface P3 can be an IO interface. The controller module can directly configure the transmit and receive status of the second communication interface P2 of the control switch module through the IO interface. No protocol stack is required, no topology information needs to be stored, memory overhead is extremely low, and it is compatible with control (node) devices such as battery control units (BCU) and battery aggregation units (BAU) in energy storage systems with limited resources.
[0061] In this solution, the computing power and memory resources of the control chips of BCU and BAU in the energy storage system are limited. This solution uses MCU to implement interface configuration, without protocol stack, without the need to continuously parse protocol frames and maintain state machine. Interface configuration will not occupy the computing resources of the control chip and will not affect core business such as battery data acquisition and charging and discharging control.
[0062] Based on any of the aforementioned schemes, in one possible implementation, the control nodes are configured such that: when the second communication interface of one control node is disconnected from the ring-chain communication network, in the unidirectional communication direction, the next control node adjacent to the faulty second communication interface sends a first broadcast message to the ring-chain communication network. Upon receiving the first broadcast message, the remaining control nodes configure their corresponding second communication interfaces to be both transmit and receiveable.
[0063] refer to Figure 1For example, in this scheme, by default, the entire ring chain communication network only allows broadcast frames to be transmitted in a clockwise direction, and the one-way communication direction is P2 of control node 1, P1 of control node 2... P1 of control node 1.
[0064] If the P2 link of heating control node 2 is disconnected (e.g., the network cable is unplugged), the physical connection between the P2 interface of control node 2 and the P1 interface of control node 3 is interrupted. Since the P2 of each control node is still only transmitting and not receiving at this time, when the broadcast frame is only transmitted in a clockwise direction, only control node 3 is able to notify other control nodes in the entire ring chain communication network that the P2 link of control node 2 is disconnected (or the P1 link of control node 3 is disconnected).
[0065] In this scheme, the first broadcast message may include information such as the link failure event, the faulty node ID, the faulty interface, and a timestamp. When the P2 of control node 2 fails to connect, the MCU of control node 3 immediately generates the first broadcast message and configures its P2, which was previously only for sending and not for receiving, to become capable of both sending and receiving. Control node 3 then sends the first broadcast message to the capable P1 of control node 4 via its own P2, and the first broadcast message spreads along the unidirectional communication path to all control nodes.
[0066] After receiving the first broadcast message, control nodes 1, 2, and 4 parse the message and confirm that the link loss event is valid. The MCU of each control node sends a configuration command to its respective switch chip to change its P2 from transmit-only to transmit-and-receive.
[0067] After P2 completes the transmit / receive state switch, the system enters a two-way communication mode. Data can be transmitted along both forward and reverse paths. Control node 2's P1 and control node 1's P2 can communicate through a reverse (counterclockwise) path.
[0068] Based on any of the aforementioned schemes, in one possible implementation, the control nodes are configured with the same local area network broadcast IP, and the first broadcast message is configured to be sent to the local area network broadcast IP.
[0069] In this scheme, all control nodes are pre-configured with the same LAN broadcast IP, ensuring that broadcast messages sent by any control node can be received by all control nodes within the ring chain. The LAN broadcast IP can be set to 255.255.255.255. This address does not require subnetting and can directly penetrate all control nodes within the same LAN without routing forwarding.
[0070] In this solution, after the MCU of all control nodes starts up, it initializes the UDP listening service, listens to the preset fixed port, and continuously receives broadcast messages pointing to 255.255.255.255; it configures message filtering rules to only parse the first broadcast message carrying the link break event identifier to avoid accidental triggering.
[0071] In this solution, the same local area network broadcast IP is configured, eliminating the need to configure a separate target address for each control node, thus avoiding notification omissions due to inconsistent IP addresses.
[0072] Based on any of the aforementioned schemes, in one possible implementation, the first broadcast message is transmitted using the UDP protocol.
[0073] In this scheme, the first broadcast message is transmitted using the UDP protocol. By leveraging the connectionless, low-latency, and lightweight characteristics of the UDP protocol, a fast, efficient, and low-resource-consumption network-wide notification channel is provided for ring chain break events, ensuring that all control nodes can receive the break information synchronously in a short time.
[0074] In this scheme, the UDP protocol is used as the transmission carrier. The key information of the link failure (fault node ID, fault interface, event identifier, etc.) is encapsulated into a first broadcast message and sent via the local area network broadcast IP. This triggers all control nodes to synchronously perform interface state switching, ensuring the connectivity of the ring link after the link failure.
[0075] In this scheme, the transmission of the first broadcast message does not rely on any ring network protection protocol. When the MCU detects a communication interface disconnection, the MCU directly broadcasts the first broadcast message through the UDP protocol. Compared with the traditional Spanning Tree Protocol (STP) or ERPS protocol, it can reduce the time consumption of disconnection notification, realize the rapid switching of interface sending and receiving states, ensure uninterrupted communication, and guarantee the stability of energy storage system operation.
[0076] Based on any of the aforementioned schemes, in one possible implementation, the control node includes a central control node and several master control nodes; the central control node is configured to, upon receiving a first broadcast message, determine the location of the master control node whose second communication interface is disconnected based on the first broadcast message, and generate and send fault alarm information for that master control node.
[0077] In this solution, the main control node can be BAU and the master control node can be BCU. After a link failure, the location of the faulty BCU can be located through the BAU, and the fault alarm information can be pushed to the external operation and maintenance system through the BAU to achieve rapid fault handling.
[0078] For example, in this solution, the master control node can be configured to parse fault information from the first broadcast message, locate the faulty master control node, generate and report fault alarm information, and maintain communication scheduling with all master control nodes. As the local control unit of the energy storage system, the master control node is responsible for core operations such as battery status acquisition (voltage, temperature) and charge / discharge control, while also participating in ring chain communication and cooperating to switch the transmit / receive status of designated interfaces in the event of a chain failure.
[0079] For example, in this scheme, the first broadcast message can carry the UID of the faulty BCU and the broken link identifier of the second communication interface P2. The BAU can pre-store the ring link topology (the physical connection order between the BAU and each BCU). After parsing the first broadcast message, the BAU can accurately locate the physical location of the faulty BCU based on the UID and the ring link topology.
[0080] In this solution, after a link failure occurs, the master control node is configured to generate and send fault alarm information for that master control node. The fault alarm information allows maintenance personnel to troubleshoot the fault in a timely manner and avoid system risks caused by subsequent multiple link failures.
[0081] Based on any of the aforementioned schemes, in one possible implementation, when the disconnected second communication interface is reconnected to the ring chain communication network, the control node configuring the second communication interface sends a second broadcast message to the ring chain communication network; the control node receiving the second broadcast message controls its corresponding second communication interface to change to send-only and not receive.
[0082] In this scheme, when the second communication interface that has been disconnected is reconnected to the ring link, a second broadcast message is sent through the corresponding control node to allow the ring link to return from bidirectional communication mode to unidirectional communication mode, thereby avoiding network storms and restoring the transmission under normal system conditions.
[0083] Based on any of the aforementioned schemes, in one possible implementation, the central control node is further configured to send TCP packets to the master control node via a ring chain communication network.
[0084] In this scheme, TCP packets are configured for the central control node to send critical instructions (such as charging / discharging parameter configuration and equalization control instructions) to the master control node, and to receive important data (such as battery voltage / temperature summaries and fault status) uploaded by active nodes. The central control node sends TCP packets to the master control node through the ring-chain communication network, utilizing the reliable transmission and error retransmission characteristics of the TCP protocol to provide a secure and stable transmission channel for critical control instructions and important data in the energy storage system.
[0085] In this scheme, under normal operating conditions, TCP packets are transmitted along the unidirectional path of the ring link, and network storms are avoided by the unidirectional logic of P2 which only sends and does not receive. Under abnormal operating conditions, TCP packets are sent simultaneously by the master control node from its own P1 and P2 interfaces, and the master control node can receive them through any valid path in any direction (forward / reverse), ensuring that communication is not interrupted when the link is lost.
[0086] In addition to any of the aforementioned schemes, one possible implementation also includes establishing a static MAC address table.
[0087] In this scheme, the first communication interface of each control node is configured to be able to send and receive data, including: the first communication interface is configured to allow sending data to the target MAC address pre-stored in the static MAC address table; and to allow receiving data from the broadcast MAC address pre-stored in the static MAC address table.
[0088] In this scheme, configuring the second communication interface to transmit only includes: disabling the second communication interface at the physical layer to receive data, while allowing data to be sent to the target MAC address pre-stored in the static MAC address table.
[0089] In this scheme, the static MAC address table is bound to the first communication interface and the second communication interface, and the sending function of the first communication interface and the second interface only applies to the target MAC address pre-stored in the static MAC address table.
[0090] In this scheme, when a control node needs to send data to the ring chain, the MCU encapsulates the static MAC address of the target node into the data frame, and the MCU sends the data frame to the switch module through the third communication interface; the switch module queries the static MAC address table and sends it to the first communication interface of the next control node through the second communication interface.
[0091] When a control node's first communication interface receives a data stream (such as a unicast frame or broadcast frame) from the second communication interface of a preceding control node, the switch module verifies the target MAC address. If it is the MAC address of the local control node, it forwards the data to the MCU of the local control node; if it is the MAC address of another control node, it forwards the data to the next-level control node through the second communication interface according to the unidirectional rule.
[0092] In this scheme, the second communication interface is configured at the physical layer (e.g., PHY chip layer) to enable transmission and disable reception, allowing only the output of Ethernet electrical signals and not responding to input signals from the physical link, thus blocking reverse data input at the hardware level.
[0093] In this scheme, under normal circumstances, the second communication interface is configured to send only valid data frames from the local controller module (MCU) or the first communication interface to the outside, and is not allowed to forward external data frames to the local MCU or other ports.
[0094] In this scheme, the send function of the second communication interface only applies to the target MAC address pre-stored in the static MAC address table. That is, the data frame is only allowed to be sent through the second communication interface when the target MAC address is the static MAC address of the next level node (the subsequent master control node) or the master control node of the ring chain.
[0095] Based on any of the aforementioned schemes, in one possible implementation, when the second communication interface of at least one control node is disconnected from the ring chain communication network, configuring the second communication interface in the control node to be transmit and receive includes: configuring the second communication interface to receive at the physical layer, and configuring the second communication interface to allow receiving data from broadcast MAC addresses pre-stored in the static MAC address table.
[0096] In this scheme, when the control node determines that the second communication interface of at least one control node in the ring chain is disconnected, the MCU sends a configuration command to the switch module through the third communication interface to change the second communication interface from transmit enabled and receive disabled to transmit and receive bidirectional enabled, allowing the reception of data streams from the physical link, and also allowing the forwarding of legal data frames from the local or other ports, including allowing the transmission of unicast frames with the target MAC address being the static MAC address of any control node in the ring chain, and broadcast frames with the target MAC address being the broadcast address through the second communication interface.
[0097] In this scheme, when a link is lost, the first communication interface still maintains the function of static MAC directional transmission and forms a bidirectional communication path with the second communication interface. Taking the main control node sending data to the master control node as an example, the main control node simultaneously sends a message encapsulated with a static MAC address through its first and second communication interfaces. The master control node can receive the data through its own first communication (forward path) or second communication interface (reverse path), ensuring that communication is not interrupted.
[0098] In this scheme, all control nodes are pre-configured with the same LAN broadcast IP and static MAC address. When a control node sends a broadcast message (first / second broadcast message), it must simultaneously meet the dual encapsulation requirements of the IP layer and MAC layer. In the event of a link failure, only messages with a valid static MAC address within the ring link and a destination IP of the LAN broadcast IP (e.g., 255.255.255.255) are allowed to pass.
[0099] Based on any of the aforementioned schemes, in one possible implementation, the switch module includes a switch chip configured to generate an interrupt when the second communication interface is disconnected; the controller module is configured to determine that the second communication interface is disconnected from the ring-chain communication network when an interrupt is detected.
[0100] In this solution, the switch chip is a 3-interface switch chip. The interface of the switch chip can be equipped with a PHY chip. The switch chip supports the function of detecting the plugging and unplugging status of the network cable. When the P2 interface is disconnected (network cable unplugged, interface failure), the PHY chip will generate a physical layer level change, triggering an interrupt signal inside the switch chip.
[0101] The switch chip is connected to the controller module (MCU) through a third communication interface. The switch chip transmits the chain break interrupt signal to the MCU. The MCU is pre-configured with an interrupt handler. When the interrupt signal is detected, it directly determines that the second communication interface has been disconnected from the chain and immediately starts the subsequent broadcast notification process.
[0102] In this solution, the switch chip and MCU of the master control node (BAU) and the main control node (BCU) adopt the same configuration logic to ensure that all control nodes can independently and quickly detect the disconnection status of their own P2 interface.
[0103] In this solution, the physical interruption detection of the second communication interface disconnection is implemented based on the switch chip. Combined with the first broadcast message using the UDP protocol for fault broadcasting, it can ensure that the disconnection response and the switching of the interface transmission and reception status are completed in a very short time (milliseconds), ensuring uninterrupted communication and avoiding the problem that battery charging and discharging control may run out of control due to long-term communication disconnection, thus ensuring the stability of the energy storage system operation.
[0104] Figure 3 This is another control node structure block diagram in the embodiment, see reference. Figure 3 Based on any of the aforementioned schemes, in one possible implementation, the control node includes an MCU and a switch chip. The switch chip is configured with a first communication interface P1, a second communication interface P2, and a third communication interface P3. The first communication interface P1 and the second communication interface P2 are respectively configured with Ethernet interfaces J1 and J2. The switch chip communicates with the MCU through the third communication interface P3.
[0105] In this scheme, the control nodes include a central control node and a master control node. The MCU and switch chips configured in the central control node and the master control node have the same functions.
[0106] Figure 4 This is a schematic diagram of unidirectional communication in a ring chain in the embodiment, for reference. Figure 4 The first communication interface P1 and the second communication interface P2 of the switch chip are both enabled for data transmission and reception. However, the MCU can adjust this by configuring the switch chip. Under normal communication conditions, all control nodes configure their own switch chips to normal communication via P1 and transmit-only via P2 after startup. All control nodes internally follow a unidirectional transmission from J1 to J2, and all data on the entire loop is transmitted in the same direction.
[0107] refer to Figure 4Under normal circumstances, the messages sent by control node 2 (device 2) will be forwarded to both ports P1 and P2 at the same time. However, since the receiving function of port P2 of control node 1 (device 1) is turned off, the messages can only be sent in a clockwise direction.
[0108] Figure 5 This is a schematic diagram of the broken chain in the embodiment, for reference. Figure 5 In this solution, the switch chip is configured to support network cable plug-in / plug-out detection. An interrupt is generated when the connection is lost. Based on the interrupt signal, the MCU can obtain network cable plug-in / plug-out information within milliseconds.
[0109] refer to Figure 5 When the network cable between Device 1 and Device 2 is unplugged, both Device 1 and Device 2 can obtain information from the switch chip that the network cable for the corresponding Ethernet interface has been unplugged, as the physical electrical signal is disconnected. Since the entire network only allows data packets to be transmitted clockwise at this time, only Device 2 is capable of sending a broadcast notification via the 255.255.255.255 LAN broadcast IP address to inform other devices in the ring LAN that the network cable at port J2 of Device 1 (or port J1 of Device 2) is disconnected.
[0110] When one or more network cables are disconnected in a ring network, the ring network effectively ceases to exist, and a network storm is no longer possible. Therefore, all other devices that receive the disconnection notification will resume data reception on their P2 ports. This enables normal communication even when the ring connection is broken.
[0111] Figure 6 This is a schematic diagram of the broken chain topology in the embodiment, for reference. Figure 6 Even if a breakpoint occurs at any point in the ring chain, the master control node will still send TCP packets to any master control node simultaneously from both ports J1 and J2. The target master control node will be able to reply normally regardless of which side it is on.
[0112] After confirming the location of the breakpoint via a link failure notification, the master control node can promptly send an alarm to the outside world and request intervention from maintenance personnel while maintaining normal system operation. This greatly increases the security of the energy storage system.
[0113] For example, assuming the network cable between master node 2 and master node 3 is disconnected, the operation process of the Ethernet ring chain communication system includes:
[0114] When the P2 interface of master node 2 is disconnected (e.g., the network cable is unplugged), the physical connection between the J2 interface of master node 2 and the J1 interface of master node 3 is interrupted. The switch chips of master node 2 and master node 3 can detect the disconnection of the network cable and trigger an interrupt. After the MCU of master node 2 and master node 3 detects the interrupt signal, they generate the first broadcast message.
[0115] The first broadcast message generated by master node 3 can be sent to the ring chain via its P2 interface (which only sends and does not receive). The first broadcast message is encapsulated using the UDP protocol, and the local area network broadcast IP is set to 255.255.255.255. The first broadcast message will quickly spread to all master nodes and central control nodes along the one-way communication path.
[0116] After receiving the first broadcast message, the main control node 1 and master control nodes 2-4 parse the message to confirm the link loss event. Each node's MCU sends a configuration command to the switch chip, changing its P2 interface from transmit-only to transmit-and-receive. After the switch is completed, the system enters bidirectional communication mode, and data can be transmitted along the reverse path. Nodes on both sides of the link loss point can communicate through the reverse path.
[0117] The master control node 1 parses the fault node ID carried in the first broadcast message to determine the specific location of the link break; the master control node generates a fault alarm message and sends it to the operation and maintenance system through the host computer interface to prompt staff to troubleshoot the problem.
[0118] When the disconnected second communication interface (P2) is reconnected to the ring chain (e.g., the network cable is plugged back in, or the interface fault is repaired), the switch chip and MCU of the corresponding control node detect the link restoration signal. The fault-recovered node generates and sends a second broadcast message to inform the ring chain that the link has been restored.
[0119] After receiving the second broadcast message, all control nodes (including the main control node BAU and the master control node BCU) synchronously change their own P2 interface from being able to send and receive to being able to send but not receive, and the ring chain resumes one-way communication to avoid network storms caused by broadcast frame flooding after the loop is closed.
[0120] Example 2
[0121] Figure 7 This is a flowchart of the Ethernet ring link communication method in the embodiment, for reference. Figure 7 The methods include:
[0122] S101. In each control node, the second communication interface is configured to transmit only and not receive, and the first communication interface is configured to transmit and receive. At this time, the ring chain communication network supports one-way communication.
[0123] S102. When the second communication interface of at least one control node is disconnected from the ring chain communication network, the second communication interface in the control node is configured to be able to send and receive.
[0124] In this embodiment, the method is applied to any of the Ethernet ring chain communication systems described in Embodiment 1. The implementation method, working process and beneficial effects of the system are the same as the corresponding content described in Embodiment 1, and the specific details will not be described in detail.
[0125] Note that the above description is merely a preferred embodiment of the present invention and the technical principles employed. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of the present invention, the scope of which is determined by the scope of the appended claims.
Claims
1. An Ethernet ring chain communication system, characterized in that, include: Several control nodes, which form a ring-chain communication network topology; The control node includes a first communication interface and a second communication interface, which are connected in series in a ring-chain communication network for communication between different control nodes. In each of the control nodes, the second communication interface is configured to send but not receive, and the first communication interface is configured to send and receive. In this case, the ring chain communication network supports one-way communication. When at least one of the control nodes disconnects its second communication interface from the ring chain communication network, the second communication interface in the control node is configured to be both transmit and receive.
2. The Ethernet ring chain communication system as described in claim 1, characterized in that, The control node includes a switch module and a controller module; The switch module is configured with a first communication interface, a second communication interface, and a third communication interface, and the switch module communicates with the controller module through the third communication interface. The controller module is configured to allow the second communication interface to either transmit only or receive.
3. The Ethernet ring chain communication system as described in claim 1, characterized in that, The control node is configured as follows: When a control node’s second communication interface is disconnected from the ring-chain communication network, in the one-way communication direction, the next control node adjacent to the faulty second communication interface sends a first broadcast message to the ring-chain communication network. When the other control nodes receive the first broadcast message, they configure their corresponding second communication interface to be able to send and receive.
4. The Ethernet ring chain communication system as described in claim 3, characterized in that, The control nodes are configured with the same local area network broadcast IP, and the first broadcast message is configured to be sent to the local area network broadcast IP.
5. The Ethernet ring chain communication system as described in claim 3, characterized in that, The control node includes a central control node and several master control nodes; The master control node is configured to, upon receiving the first broadcast message, determine the location of the master control node whose second communication interface is disconnected based on the first broadcast message, and generate and send fault alarm information for that master control node.
6. The Ethernet ring chain communication system as described in claim 3, characterized in that, When the disconnected second communication interface is reconnected to the ring chain communication network, the control node that configured the second communication interface sends a second broadcast message to the ring chain communication network; Upon receiving the second broadcast message, the control node controls its corresponding second communication interface to switch to a transmit-only mode.
7. The Ethernet ring chain communication system as described in any one of claims 1 to 6, characterized in that, This also includes establishing a static MAC address table; In each control node, the first communication interface is configured to be both transmit and receive, including: The first communication interface is configured to allow sending data to the target MAC address pre-stored in the static MAC address table; and to allow receiving data from the broadcast MAC address pre-stored in the static MAC address table. The second communication interface is configured to only send and not receive, including: Configure the second communication interface to disable physical layer reception, allowing data to be sent to target MAC addresses pre-stored in the static MAC address table.
8. The Ethernet ring chain communication system as described in claim 7, characterized in that, When the second communication interface of at least one control node is disconnected from the ring chain communication network, the second communication interface in the control node is configured to be transmit-and-receive, including: Configure the second communication interface to receive at the physical layer, and configure the second communication interface to allow receiving data from broadcast MAC addresses pre-stored in the static MAC address table.
9. The Ethernet ring chain communication system as described in claim 6, characterized in that, The master control node is also configured to send TCP packets to the master control node through the ring chain communication network.
10. An Ethernet ring link communication method, characterized in that, Applied to the Ethernet ring chain communication system according to any one of claims 1 to 9, the method comprises: In each control node, the second communication interface is configured to transmit only and not receive, and the first communication interface is configured to transmit and receive. At this time, the ring chain communication network supports one-way communication. When at least one of the control nodes disconnects its second communication interface from the ring chain communication network, the second communication interface in the control node is configured to be transmit-and-receive.