Power communication network switching method, system, equipment, medium and product
By combining real-time monitoring and target decision functions, smooth and reliable switching of the power communication network is achieved, solving the problem of service interruption caused by the asynchrony between the transport layer protocol state and the data stream, and ensuring the high reliability and data integrity of power services.
Patent Information
- Application Number
- CN202511858651.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-10
- Publication Date
- 2026-02-10
AI Technical Summary
Existing power communication network switching technologies can cause service interruptions and data loss when the transport layer protocol state and data stream are out of sync, failing to meet the requirements for high reliability and smooth continuity.
By monitoring the quality parameters and service characteristic parameters of multiple networks in real time, calculating function values using the target decision function, determining whether the switching conditions are met, transmitting data in parallel at the link layer, synchronizing data status at the transport layer, and ensuring data consistency through verification code comparison, a smooth and reliable network switching is achieved.
It significantly reduces the risk of momentary interruptions during network switching, ensures highly reliable and low-latency transmission of power services, guarantees uninterrupted data transmission, and improves the reliability and stability of switching.
Smart Images

Figure CN121509494A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of computer vision and computer graphics, and more particularly to a method, system, device, medium, and product for switching power communication networks. Background Technology
[0002] With the continuous improvement of the intelligence level of power systems, distribution communication networks need to carry critical services such as fault recording, remote control, and real-time monitoring. These services have extremely high requirements for the reliability and continuity of communication. However, the distribution environment is complex, and a single communication network is prone to performance degradation or even interruption due to interference, obstruction, or congestion. Therefore, the ability to perform smooth and reliable intelligent switching between multiple access methods such as public networks, private networks, and wired networks has become a key technology to ensure the continuous operation of power services and is of great significance to improving the resilience and reliability of the power grid.
[0003] Currently, existing technical solutions for network handover typically rely on handover decision algorithms set on the communication terminal or network side. These algorithms are mostly based on single or limited-dimensional network quality parameters such as received signal strength. When the parameter is lower than a preset threshold, the handover process is triggered. Furthermore, at the handover execution level, the common practice is "disconnect first, then reconnect," that is, disconnect the connection with the current service network first, and then try to access the target network.
[0004] However, the existing switching process only focuses on the connectivity of the network link, neglecting the synchronization of the transport layer protocol state and the guarantee of the continuity of service data flow. As a result, after the switching occurs, the transport layer triggers timeout retransmission or connection reset due to the discontinuity of state information. At the same time, data that has been sent but not acknowledged at the switching critical point is very easy to be lost, thus causing significant interruptions or data errors at the service level. This cannot meet the stringent requirements of power services for high reliability and smooth continuity. Summary of the Invention
[0005] This invention provides a method, system, device, medium, and product for switching power communication networks. It can solve the problem of service interruption and data loss caused by the asynchrony between the transport layer protocol state and the data stream in existing network switching technologies in power distribution communication systems with extremely high reliability requirements, thereby achieving smooth, reliable, and uninterrupted data transmission network switching.
[0006] This invention provides a method for switching power communication networks, comprising: Real-time monitoring of network quality parameters of multiple primary networks, and acquisition of service characteristic parameters of power service data to be transmitted; For each of the first networks, a function value is calculated for the network quality parameters and the service characteristic parameters using a target decision function. Based on each function value, it is determined whether the network switching conditions are met. If they are met, the target transmission network is determined. During the process of switching from the current transmission network to the target transmission network, at the link layer, the link of the target transmission network is started and the power service data to be transmitted is transmitted in parallel with the link of the current transmission network. At the same time, at the transmission layer, the data transmission status between the current transmission network and the target transmission network is synchronized. For the same data unit in the power service data to be transmitted, if the verification code of the current transmission network is the same as the verification code of the target transmission network, the verification is successful, the link of the current transmission network is closed, and the power communication network is switched.
[0007] This invention provides real-time, multi-dimensional input data for subsequent handover decisions by monitoring network quality parameters of multiple first networks and acquiring service characteristic parameters of the power service data to be transmitted, ensuring sufficient and timely decision-making basis. A target decision function is used to calculate function values for the network quality parameters and service characteristic parameters. Based on these function values, it is determined whether network handover conditions are met, quantifying complex network states and service requirements into a single function value, simplifying decision logic and facilitating automation. At the link layer, the target network link is initiated and data is transmitted in parallel with the current network link. Simultaneously, at the transport layer, the data transmission status of the two networks is synchronized, achieving a smooth transition from connection to disconnection, ensuring the continuity of power services. For the same data unit, if the verification codes of the two networks are the same, the verification passes, the current link is closed, and the handover is completed. Verification code comparison ensures data consistency, preventing packet loss or duplication and improving handover reliability. Overall, this embodiment proposes a closed-loop handover process of "monitoring-decision-parallel transmission-consistency verification," significantly reducing the risk of instantaneous interruptions during power communication network handover, achieving smooth, reliable, and uninterrupted data transmission, thereby ensuring the high reliability and low latency transmission requirements of power services.
[0008] Furthermore, the step of determining whether the network switching conditions are met based on the function values, and determining the target transmission network if they are met, specifically involves: If the function value of the current transmission network is less than or equal to a first preset threshold, or, If the difference between the function value of the current network and the function value of the target transmission network is greater than or equal to the second preset threshold, then the network switching condition is met. The target transmission network is determined based on the maximum value of each of the stated function values.
[0009] If the current network function value is less than or equal to a first preset threshold, or the difference between the current and target network function values is greater than or equal to a second preset threshold, then the switching condition is met. By setting dual trigger thresholds, switching can be performed promptly when the current network quality deteriorates, and proactively when the target network is significantly better than the current network, avoiding the ping-pong effect. The network with the largest function value is used as the target network, ensuring that each switch points to the network with the best overall quality, thus improving overall transmission performance. Overall, this embodiment achieves intelligent decision-making of "switching when necessary and choosing the best option" through threshold comparison and maximum value selection mechanisms, balancing the timeliness and stability of switching and reducing unnecessary frequent switching.
[0010] Furthermore, the service characteristic parameters include bandwidth parameters, latency parameters, and security level parameters. The calculation of the function value using the target decision function on the network quality parameters and the service characteristic parameters specifically involves: For each of the first networks, the service feature parameters and the corresponding preset adjustment function are calculated to obtain the service feature vector, and the network quality parameters are processed by fuzzy logic to obtain the membership degree of the network quality parameters; The function value is obtained by combining the diagonal matrix and the network quality transformation rate penalty parameter, and calculating the membership degree between the service feature vector and the membership degree.
[0011] This approach incorporates business characteristic parameters such as bandwidth, latency, and security level, covering core power business needs and ensuring that decision-making results better align with actual business scenarios. By calculating business characteristic vectors through adjustment coefficients, different businesses can assign different weights to bandwidth, latency, and security, achieving differentiated service quality assurance. Fuzzy logic is used to process network quality parameters, obtaining membership degrees and transforming continuous or discrete network quality indicators into membership degrees within the [0,1] interval, weakening boundary abrupt changes and enhancing decision robustness. The function value is calculated by combining a diagonal matrix with a network quality transformation rate penalty parameter. The diagonal matrix highlights the weight of key indicators, while the penalty parameter suppresses drastic fluctuations in network quality, improving decision stability. Overall, this embodiment, by introducing fuzzy mathematics and matrix operations, transforms uncertain and nonlinear network states and business requirements into quantifiable and comparable function values, making switching decisions more scientific and robust.
[0012] Furthermore, the step of processing the network quality parameters using fuzzy logic to obtain the membership degree of the network quality parameters specifically involves: For each of the network quality parameters, a corresponding preset fuzzy set is obtained. The membership degree of the network quality parameter relative to the preset fuzzy set is calculated using a preset membership function. The network quality parameters include the reference signal received power of the public power grid, the channel interference ratio of the private power grid, and the bit error rate of the wired power grid.
[0013] This approach pre-defines fuzzy sets and membership functions for each network quality parameter, mapping specific values (such as a 50ms latency) to linguistic variables like "good / medium / poor," reducing reliance on precise models. Calculating the membership degree of network quality parameters relative to the fuzzy sets provides a smooth transition in membership relationships, avoiding jitter caused by hard thresholds and enhancing system stability. The first network includes the public power grid, private power grid, and wired power grid, covering mainstream communication media in the power industry, enhancing the method's applicability. Overall, this embodiment, through fuzzification processing, makes network quality assessment closer to human cognition, improving the interpretability and noise resistance of the decision-making algorithm.
[0014] Furthermore, the step of synchronizing the data transmission status between the current transmission network and the target transmission network at the transport layer specifically includes: After starting the target transmission network link and before closing the current transmission network link, the data packets to be sent, the sequence number to be sent, and the acknowledgment number to be received of the power service data to be transmitted in the current transmission network are synchronized to the target transmission network link.
[0015] This synchronization of data packets, sequence numbers, and acknowledgment numbers before and after the target link is started and the current link is closed allows the target link to instantly take over the session state of the current link at the transport layer, avoiding TCP / UDP reconnection or retransmission and achieving zero-packet-loss handover. Overall, this embodiment ensures that the application layer is unaware of network switching through transport layer state synchronization, guaranteeing the continuous online operation of critical services such as power relay protection and distribution automation.
[0016] Furthermore, the verification is successful if the verification code of the current transmission network is the same as the verification code of the target transmission network, specifically as follows: Obtain the first verification code of the last transmitted data packet from the current transmission network link, and the second verification code of the first transmitted data packet from the target transmission network; The second verification code is compared with the saved first verification code. If they match, the switch is considered successful. If they do not match, the switch is considered unsuccessful, and a data retransmission mechanism is triggered.
[0017] Obtaining the first verification code of the last data packet in the current network and the second verification code of the data packet received by the target network provides quantifiable verification criteria for the handover result. By comparing the two verification codes, a retransmission is triggered if they do not match. In the event of a handover failure, an error correction mechanism is automatically activated to prevent the loss of business data and improve the system's self-healing capabilities. Overall, this embodiment forms a complete reliability closed loop of "handover-verification-retransmission," ensuring data integrity even in extreme cases through the retransmission mechanism, thus meeting the stringent requirements of power systems for high communication reliability.
[0018] Another embodiment of the present invention provides a power communication network switching system, comprising: an acquisition module, a calculation module, a synchronization module, and a switching module; The acquisition module is used to monitor the network quality parameters of multiple first networks in real time and acquire the service characteristic parameters of the power service data to be transmitted. The calculation module is used to calculate function values for the network quality parameters and service characteristic parameters for each of the first networks using a target decision function, and to determine whether the network switching conditions are met based on each function value. If the conditions are met, the target transmission network is determined. The synchronization module is used to, during the process of switching from the current transmission network to the target transmission network, activate the link of the target transmission network at the link layer and transmit the power service data to be transmitted in parallel with the link of the current transmission network. At the same time, at the transmission layer, it synchronizes the data transmission status between the current transmission network and the target transmission network. The switching module is used to, for the same data unit in the power service data to be transmitted, if the verification code of the current transmission network is the same as the verification code of the target transmission network, then the verification is successful, the link of the current transmission network is closed, and the power communication network is switched.
[0019] Another embodiment of the present invention provides a terminal device, including: a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, it implements the steps of the power communication network switching method of the present invention.
[0020] Another embodiment of the present invention provides a computer-readable storage medium item, including: a stored computer program, which, when the computer program is running, controls the device where the computer-readable storage medium is located to perform the steps of the power communication network switching method of the present invention.
[0021] Another embodiment of the present invention also provides a computer program product stored in a storage medium, the computer program product being executed by at least one processor to implement the steps of the power communication network switching method as described in any one of the first aspects. Attached Figure Description
[0022] To more clearly illustrate the technical solution of this application, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0023] Figure 1This is a flowchart illustrating a power communication network switching method provided in an embodiment of the present invention; Figure 2 This is a schematic diagram of the structure of a power communication network switching system provided in an embodiment of the present invention. Detailed Implementation
[0024] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below with reference to the accompanying drawings of the embodiments. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0025] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims, and foregoing description of the drawings are intended to cover non-exclusive inclusion.
[0026] In the description of the embodiments of this application, technical terms such as "first" and "second" are used only to distinguish different objects and should not be construed as indicating or implying relative importance or implicitly specifying the number, specific order, or primary and secondary relationship of the indicated technical features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly defined.
[0027] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0028] In the description of the embodiments in this application, the term "and / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Additionally, the character " / " in this document generally indicates that the preceding and following related objects have an "or" relationship.
[0029] In the description of the embodiments of this application, the term "multiple" refers to two or more (including two), similarly, "multiple sets" refers to two or more (including two sets), and "multiple pieces" refers to two or more (including two pieces).
[0030] In the description of the embodiments of this application, unless otherwise expressly specified and limited, technical terms such as "installation," "connection," "joining," and "fixing" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral part; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; they can refer to the internal communication of two components or the interaction between two components. For those skilled in the art, the specific meaning of the above terms in the embodiments of this application can be understood according to the specific circumstances.
[0031] See Figure 1 To address the problem of service interruption and data loss caused by the asynchrony between transport layer protocol state and data stream in existing network switching technologies in power distribution communication systems with extremely high reliability requirements, and to achieve truly smooth, reliable, and uninterrupted data transmission network switching, an embodiment of the present invention provides a power communication network switching method, comprising: S101. Monitor the network quality parameters of multiple primary networks in real time and obtain the service characteristic parameters of the power service data to be transmitted.
[0032] In the steps described above, sensing modules deployed on communication terminals or the network side periodically or triggeredly collect raw communication quality data from all available networks (i.e., the "first network"). This data reflects the underlying network connectivity performance. Based on the type, source, or predefined strategy of the power service data to be transmitted, its core requirements for communication services are analyzed or queried. These requirement parameters define the service's expectations regarding network capabilities.
[0033] S102. For each of the first networks, a function value is calculated using the target decision function to obtain the network quality parameters and the service characteristic parameters. Based on each function value, it is determined whether the network switching conditions are met. If they are met, the target transmission network is determined.
[0034] In the above steps, a decision function is constructed or invoked. This function takes network quality parameters and service characteristic parameters as input. The core mechanism of this function is to quantify the matching between service requirements and network capabilities. The function calculates a comprehensive score (i.e., a "function value") for each candidate network. The score reflects "the degree to which the network is adapted to the current service." Based on the comprehensive scores of all candidate networks, a comparison logic is executed. The purpose of this logic is to determine whether maintaining the current connection is no longer the optimal choice and whether there is a significantly better alternative network. Once this logical condition is met, the candidate network with the highest score is directly identified as the switching target.
[0035] S103. During the process of switching from the current transmission network to the target transmission network, at the link layer, the link of the target transmission network is started, and the power service data to be transmitted is transmitted in parallel with the link of the current transmission network. At the same time, at the transmission layer, the data transmission status between the current transmission network and the target transmission network is synchronized.
[0036] The above steps are the execution phase for achieving smooth switching. The means of achieving this include two levels of coordination: the first level is the link layer coordination means: establishing a physical connection with the target network and putting it into a ready state. Then, for an overlapping period of time, the current network and the target network are arranged to simultaneously undertake data transmission tasks, forming a temporary dual-channel transmission architecture to ensure that there is always data being transmitted on the physical link during the switching period. The second layer is the transport layer coordination mechanism: In order to ensure that upper layer applications are unaware of the link changes at the lower layer, state synchronization needs to be performed at the transport layer. This involves transmitting key information that can identify the current data stream transmission progress and status from the current network link to the target network link, so that when the target network takes over, it can resume transmission from the precise breakpoint of the data stream, thereby maintaining the continuity of the transport layer session.
[0037] S104. For the same data unit in the power service data to be transmitted, if the verification code of the current transmission network is the same as the verification code of the target transmission network, the verification is successful, the link of the current transmission network is closed, and the power communication network is switched.
[0038] In the above steps, before and after the critical point of the handover process, verification information (i.e., a "verification code") representing the content of the same service data is generated based on data from the current transmission network and the target transmission network, respectively. By comparing whether these two verification codes are consistent, it is determined whether the data content has maintained integrity and consistency at the moment of handover, and whether no loss or error has occurred. When the consistency verification is successful, the system is certain that the target network has stably and correctly taken over the data stream. At this point, the system can safely release the connection resources of the current transmission network, marking the final completion of the entire handover process.
[0039] As an example of an embodiment of the present invention, the step of synchronizing the data transmission status between the current transmission network and the target transmission network at the transport layer specifically involves: after starting the target transmission network link and before closing the current transmission network link, synchronizing the data packets to be sent, the sequence number to be sent, and the acknowledgment number to be received of the power service data to be transmitted in the current transmission network to the target transmission network link.
[0040] In this embodiment, when the decision engine selects a certain access mode (such as a private network), it can smoothly switch from the current access mode to a new access mode (such as switching from the public network to the private network) while ensuring the continuity of data flow and the reliability of services. Specifically, the first step is to pre-activate the private network link. After the access network and access mode have been determined, the private network link is pre-activated to prepare for the takeover of data communication in advance. Frequency points are automatically allocated to the private network to ensure that the private network link can take over the traffic of the public network. In order to ensure data security, the encryption keys between the public network and the private network are also synchronized to ensure secure data transmission during the switch. The second step is to perform a smooth migration at the protocol layer. After the private network link is pre-activated, a smooth migration at the protocol layer is performed to ensure that the ongoing data flow can switch from the public network to the private network without interruption. The migration process includes protocol layer synchronization and private network continuation of the last frame data. During the protocol layer synchronization process, TCP sequence numbers, packet identifiers, and transmission status are synchronized at the protocol layer. During parallel transmission across dual links, the system uses a synchronization mechanism at the protocol layer to ensure data flow synchronization between the public network link and the private network link. When the private network resumes transmission of the last frame, after taking over, the system continues transmitting the remaining data from the public network link to ensure no data loss. Thirdly, during the dual-link parallel transmission switchover, both the public and private networks can transmit data simultaneously. The private network link will take over the transmission tasks from the public network link in advance, ensuring that if the public network link is disconnected, the private network can smoothly continue transmitting the remaining data, ensuring that the private network is preloaded with 30% of the data before the switchover.
[0041] As an example of an embodiment of the present invention, the step of determining whether the network switching condition is met based on each of the function values, and determining the target transmission network if the condition is met, specifically involves: if the function value of the current transmission network is less than or equal to a first preset threshold, or if the difference between the function value of the current network and the function value of the target transmission network is greater than or equal to a second preset threshold, then the network switching condition is met; the target transmission network is determined based on the maximum value of each of the function values.
[0042] In this embodiment, the judgment mechanism consists of two parallel logical channels, which together ensure the timeliness and optimality of the handover decision. The first judgment condition is a forced handover judgment based on a first preset threshold, specifically, the decision function value D of the current transmission network is... current With a pre-set, extremely low first preset threshold θ low Perform real-time comparisons; this threshold θ low Set as the critical point between network "available" and "unavailable", when D current ≤θ lowWhen this condition is met, it indicates that the overall quality of the current network has deteriorated to the point where it can no longer meet basic business needs (e.g., extremely poor public network RSRP or severe interference on the private network). Once this condition is met, a forced handover process will be immediately triggered. This is a safety fallback mechanism to ensure uninterrupted basic system communication; it has the highest priority and is designed to quickly escape faulty or severely degraded network environments. For example, when the RSRP value is below -110dBm, the public network signal quality is considered poor, triggering a handover decision; when C / I > 20dB, the private network signal quality is considered good and can continue to be used; when BER ≤ 10... -9 At that time, the wired network quality is considered stable and suitable for continued use. The second judgment condition is an optimized switching judgment based on a second preset threshold / hysteresis threshold, specifically, continuously calculating the decision function values of all candidate networks and finding the maximum value D. max Then, the difference between this maximum value and the current network function value is calculated: ΔD = D max -D current This difference ΔD is compared with a second preset threshold θ. hysteresis (i.e., hysteresis threshold) are compared, θ hysteresis This setting is to prevent the "ping-pong effect" (i.e., frequent switching) caused by slight fluctuations in network quality near the optimal value, ΔD ≥ θ hysteresis This means that there exists a candidate network whose quality is not only superior to the current network, but whose advantage is significant and stable enough to justify the switching overhead for better performance. After satisfying any of the above switching conditions, a simple maximization selection operation is performed: from all candidate networks, the decision function value D is selected. i The largest network ensures that the system always selects the network with the best overall evaluation as the switching target.
[0043] As an example of an embodiment of the present invention, the service feature parameters include bandwidth parameters, latency parameters, and security level parameters. Specifically, the step of calculating the function value of the network quality parameters and the service feature parameters using a target decision function involves: for each first network, calculating the service feature parameters and the corresponding preset adjustment function to obtain a service feature vector; processing the network quality parameters using fuzzy logic to obtain the membership degree of the network quality parameters; and combining the diagonal matrix and the network quality transformation rate penalty parameter to calculate the function value by combining the service feature vector and the membership degree.
[0044] In this embodiment, based on the actual needs of the power service, the bandwidth requirements, maximum tolerable latency, and security level of each service are quantified to generate the service requirement feature matrix Q, as shown below: ; Among them, Breq For the bandwidth requirements of the service (unit: Mbps), L max The maximum tolerable latency for the service (unit: ms), S level Security level for the business (value range: 1-5).
[0045] The bandwidth, latency, and security level parameters of each service are collected as input. For each parameter, a corresponding preset adjustment function (such as an S-shaped function or a linear function) is called. This function has built-in adjustment coefficients to transform the original requirements of the service (such as "needing high bandwidth") into relative importance (i.e., weighting factors) in the decision-making process. The specific formula is as follows: Bandwidth demand weighting factor (α): The greater the bandwidth demand, the higher the weighting factor, defined as: ; Where, k B This is the bandwidth adjustment factor, with B0=50Mbps as the baseline bandwidth value.
[0046] The latency requirement weighting factor (β) is defined as follows: The smaller the maximum tolerable latency, the higher the weighting factor. ; Where, k L L0 = 10ms is the delay adjustment coefficient and the base delay value.
[0047] The security level weighting factor (γ) is calculated based on the security level of the business and is defined as follows: ; Among them, S level The security level of the business (1-5) is determined by the weighting factor γ, which ranges from 0 to 1.
[0048] These weighting factors are dynamically adjusted based on specific business needs, ensuring that bandwidth, latency, and security levels are prioritized when selecting a network. By treating different weighting factors as different dimensions of a vector, a business feature vector (V) is obtained. Q ): .
[0049] For the original quality parameters of each candidate network, a preset membership function is used. This function defines one or more fuzzy sets of "quality levels" (such as "good signal" and "poor signal") for each parameter and maps the specific parameter value to a membership degree between 0 and 1. A weight matrix is used to combine the obtained business feature vector with the membership degree. This weight matrix is used to strengthen the importance of different dimensions, resulting in a matching degree. Furthermore, to reflect the forward-looking nature of the decision, a network quality change rate penalty parameter is introduced into the calculation. This parameter "deducts points" for networks whose quality is deteriorating and "adds points" for networks whose quality is improving, enabling the system to predict network trends and avoid switching to networks that are about to deteriorate, further improving the intelligence and stability of the decision. The combined result of the matching degree and the trend term is the final function value of the candidate network. The higher this value, the more suitable the network is for undertaking the current power business. The calculation formula for the target decision function is expressed as follows: ; Among them, V Q It is a business feature vector. Here, i ∈ {pub, pri, wire} represents the membership degree corresponding to the network quality parameter, and W is the weight matrix, which is a diagonal dominant matrix. It is a penalty term for the rate of change of network capability as a disturbance resistance term.
[0050] As an example of an embodiment of the present invention, the step of processing the network quality parameters through fuzzy logic to obtain the membership degree of the network quality parameters specifically involves: for each network quality parameter, obtaining a corresponding preset fuzzy set, and calculating the membership degree of the network quality parameter relative to the preset fuzzy set through a preset membership function. The network quality parameters include the reference signal received power of the public power grid, the channel interference ratio of the private power grid, and the bit error rate of the wired power grid.
[0051] In this embodiment, to achieve intelligent network handover, the present invention first constructs a real-time network status awareness mechanism, collecting key quality indicators of three different networks (public network, private network, and wired network). The network status awareness results include the following parameters: Public network signal strength (RSRP): The signal strength of the public network is evaluated by real-time measurement of the 5G NR cell reference signal received power (RSRP), ranging from -140dBm to -44dBm; Private network channel interference ratio (C / I): The communication quality of the private network is evaluated by measuring the interference ratio (C / I) of the 230MHz wireless private network carrier; Wired network bit error rate (BER): The quality of the wired network is judged by measuring the bit error rate (BER) of the EPON optical link; To integrate the quality data of the public network, private network, and wired network, a real-time awareness vector Γ(t) is constructed: '; By sensing the quality indicators of these three networks in real time, changes in different networks can be detected promptly. Based on real-time network quality perception and the quantification results of service requirements, this invention introduces a fuzzy decision engine for intelligent network switching. By normalizing network quality parameters through fuzzy logic, the applicability of each network can be more accurately evaluated. Network quality parameters (such as RSRP, C / I, and BER) are normalized and converted into fuzzy set values for further decision-making. The preset fuzzy set representation is as follows: Public network quality: ; Private network channel interference ratio: ; 3) Wired network bit error rate: ; As can be seen from the above, for each input original parameter, the system calls the preset membership function in the corresponding fuzzy set. This function is a calculation rule that outputs a membership degree between 0 and 1 based on whether the parameter value falls into the preset interval.
[0052] As an example of an embodiment of the present invention, if the verification code of the current transmission network is the same as the verification code of the target transmission network, then the verification is successful. Specifically, the following steps are taken: obtain the first verification code of the last transmitted data packet of the current transmission network link and the second verification code of the first transmitted data packet of the target transmission network; compare the second verification code with the saved first verification code; if they match, the handover is determined to be successful; if they do not match, the handover is determined to be unsuccessful, and a data retransmission mechanism is triggered.
[0053] In this embodiment, after the handover is complete, the system verifies data consistency through hash comparison to ensure that no data was lost or tampered with during the handover process, thus verifying the continuity of services. The specific steps are as follows: 1) When transmitting data over a public network link, the system generates a hash value for each data packet. The hash value of the last data packet is stored in memory for subsequent comparison.
[0054] 2) When the network switches to the private network, the system will synchronize the TCP sequence number of the public network and synchronize the hash value of the last data packet of the private network receiver with that of the public network receiver. In this way, when the private network takes over, it can continue to receive data and calculate hash values.
[0055] 3) After receiving the data, the private network will perform a hash calculation on each data packet to generate a new hash value. If no errors or data loss occur during the switching process, the hash value of the data packet received by the private network should match the hash value of the last data packet sent by the public network link.
[0056] 4) The system will compare the hash value received from the private network with the saved public network hash value. If the two match, it means that the data has not been lost and the switchover is successful. If the hash values do not match, it means that the data was lost or tampered with during the switchover process and the data needs to be retransmitted.
[0057] like Figure 2 As shown, based on the above-described method embodiments, a power communication network switching system 200 is provided, including: an acquisition module 201, a calculation module 202, a synchronization module 203, and a switching module 204; The acquisition module 201 is used to monitor the network quality parameters of multiple first networks in real time and acquire the service characteristic parameters of the power service data to be transmitted. The calculation module 202 is used to calculate function values for the network quality parameters and service characteristic parameters for each of the first networks using a target decision function, and to determine whether the network switching conditions are met based on each function value. If the conditions are met, the target transmission network is determined. The synchronization module 203 is used to, during the process of switching from the current transmission network to the target transmission network, start the link of the target transmission network at the link layer and transmit the power service data to be transmitted in parallel with the link of the current transmission network. At the same time, at the transmission layer, synchronize the data transmission status between the current transmission network and the target transmission network. The switching module 204 is used to, for the same data unit in the power service data to be transmitted, if the verification code of the current transmission network is the same as the verification code of the target transmission network, then the verification is successful, the link of the current transmission network is closed, and the power communication network is switched.
[0058] It is understood that the above system embodiments correspond to the method embodiments of the present invention, and can implement the power communication network switching method provided by any of the above method embodiments of the present invention.
[0059] It should be noted that the system embodiments described above are merely illustrative, and some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the system embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.
[0060] For ease of description and brevity, the system embodiments of the present invention include all the implementation methods described in the above-described power communication network switching method embodiments, and will not be repeated here.
[0061] Based on the above embodiments of the power communication network switching method, another embodiment of the present invention provides a terminal device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor. When the processor executes the computer program, it implements the power communication network switching method of any embodiment of the present invention.
[0062] For example, in this embodiment, the computer program can be divided into one or more modules, which are stored in the memory and executed by the processor to complete the present invention. The one or more modules may be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in the terminal device.
[0063] The terminal device may be a desktop computer, laptop, handheld computer, or cloud server, etc. The terminal device may include, but is not limited to, a processor and a memory.
[0064] The processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the terminal device, connecting all parts of the terminal device via various interfaces and lines.
[0065] Based on the above-described method embodiments, another embodiment of the present invention provides a computer-readable storage medium including a stored computer program, wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to execute the power communication network switching method described in any of the above-described method embodiments of the present invention.
[0066] Based on the above-described method embodiments, this invention also provides a computer program / program product, which is stored in a storage medium and executed by at least one processor to implement the various processes of any of the above-described method embodiments, and can achieve the same technical effect. To avoid repetition, it will not be described again here.
[0067] The modules / units integrated in the device / terminal equipment, if implemented as software functional units and sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the above embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include: any entity or device capable of carrying the computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium, etc.
[0068] The above description represents the preferred embodiments of the present invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of the present invention, and these improvements and modifications are also considered to be within the scope of protection of the present invention.
Claims
1. A method for switching power communication networks, characterized in that, include: Real-time monitoring of network quality parameters of multiple primary networks, and acquisition of service characteristic parameters of power service data to be transmitted; For each of the first networks, a function value is calculated for the network quality parameters and the service characteristic parameters using a target decision function. Based on each function value, it is determined whether the network switching conditions are met. If they are met, the target transmission network is determined. During the process of switching from the current transmission network to the target transmission network, at the link layer, the link of the target transmission network is started and the power service data to be transmitted is transmitted in parallel with the link of the current transmission network. At the same time, at the transmission layer, the data transmission status between the current transmission network and the target transmission network is synchronized. For the same data unit in the power service data to be transmitted, if the verification code of the current transmission network is the same as the verification code of the target transmission network, the verification is successful, the link of the current transmission network is closed, and the power communication network is switched.
2. The power communication network switching method as described in claim 1, characterized in that, The step of determining whether the network switching conditions are met based on the function values, and if so, determining the target transmission network, specifically involves: If the function value of the current transmission network is less than or equal to a first preset threshold, or, If the difference between the function value of the current network and the function value of the target transmission network is greater than or equal to the second preset threshold, then the network switching condition is met. The target transmission network is determined based on the maximum value of each of the stated function values.
3. The power communication network switching method as described in claim 1, characterized in that, in, The service characteristic parameters include bandwidth parameters, latency parameters, and security level parameters. The calculation of function values using a target decision function on the network quality parameters and the service characteristic parameters specifically involves: For each of the first networks, the service feature parameters and the corresponding preset adjustment function are calculated to obtain the service feature vector, and the network quality parameters are processed by fuzzy logic to obtain the membership degree of the network quality parameters; The function value is obtained by combining the diagonal matrix and the network quality transformation rate penalty parameter, and calculating the membership degree between the service feature vector and the membership degree.
4. The power communication network switching method as described in claim 3, characterized in that, The process of processing the network quality parameters using fuzzy logic to obtain the membership degree of the network quality parameters is as follows: For each of the network quality parameters, a corresponding preset fuzzy set is obtained. The membership degree of the network quality parameter relative to the preset fuzzy set is calculated using a preset membership function. The network quality parameters include the reference signal received power of the public power grid, the channel interference ratio of the private power grid, and the bit error rate of the wired power grid.
5. The power communication network switching method as described in claim 1, characterized in that, At the transport layer, synchronizing the data transmission status between the current transport network and the target transport network specifically involves: After starting the target transmission network link and before closing the current transmission network link, the data packets to be sent, the sequence number to be sent, and the acknowledgment number to be received of the power service data to be transmitted in the current transmission network are synchronized to the target transmission network link.
6. The power communication network switching method as described in claim 1, characterized in that, If the verification code of the current transmission network is the same as the verification code of the target transmission network, then the verification is successful. Specifically: Obtain the first verification code of the last transmitted data packet from the current transmission network link, and the second verification code of the first transmitted data packet from the target transmission network; The second verification code is compared with the saved first verification code. If they match, the switch is considered successful. If they do not match, the switch is considered unsuccessful, and a data retransmission mechanism is triggered.
7. A power communication network switching system, characterized in that, include: Acquisition module, calculation module, synchronization module, and switching module; The acquisition module is used to monitor the network quality parameters of multiple first networks in real time and acquire the service characteristic parameters of the power service data to be transmitted. The calculation module is used to calculate function values for the network quality parameters and service characteristic parameters for each of the first networks using a target decision function, and to determine whether the network switching conditions are met based on each function value. If the conditions are met, the target transmission network is determined. The synchronization module is used to, during the process of switching from the current transmission network to the target transmission network, activate the link of the target transmission network at the link layer and transmit the power service data to be transmitted in parallel with the link of the current transmission network. At the same time, at the transmission layer, it synchronizes the data transmission status between the current transmission network and the target transmission network. The switching module is used to, for the same data unit in the power service data to be transmitted, if the verification code of the current transmission network is the same as the verification code of the target transmission network, then the verification is successful, the link of the current transmission network is closed, and the power communication network is switched.
8. A terminal device, characterized in that, The device includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, it implements the power communication network switching method as described in any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, include: A stored computer program, wherein, when the computer program is executed, it controls the device containing the computer-readable storage medium to perform the power communication network switching method as described in any one of claims 1-6.
10. A computer program product, characterized in that, include: Computer instructions, when executed by a processor, implement the steps in the power communication network switching method as described in any one of claims 1 to 6.