Relay protection parameter management method and system based on twin data space

By adopting a method based on twin data space in the relay protection system, the problems of high coupling, poor compatibility, low communication efficiency and difficulty in ensuring parameter correctness of parameter management methods in the existing technology are solved, and efficient and accurate parameters are achieved. Management and decoupling improve system compatibility and user experience.

CN119336750APending Publication Date: 2025-01-21NANJING GUODIAN NANZI WEIMEIDE AUTOMATION CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411169018.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-23
Publication Date
2025-01-21

AI Technical Summary

Technical Problem

The existing relay protection device parameter management methods have problems such as high coupling degree, poor compatibility, low communication efficiency and difficult to guarantee parameter accuracy.

Method used

Using a method based on twin data space, we create a twin data space, register resource index pointers, generate a tree menu structure, instantiate page classes and combine function columns, use a state ring scheduling mechanism to migrate page states, and design a system based on continuous memory fragments. Communication method, optimize twin data space to complete relay protection parameter management.

Benefits of technology

It achieves the decoupling of protection configuration management software and relay protection devices, improves system compatibility, communication efficiency and parameter management accuracy, reduces maintenance costs, and improves user operating experience and system intelligence.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119336750A_ABST
    Figure CN119336750A_ABST
Patent Text Reader

Abstract

The invention discloses a twinborn data space-based relay protection parameter management method and system, and relates to the technical field of power system relay protection, and the method comprises the steps: creating a twinborn data space; registering a resource index pointer, and establishing a pointing relationship between the resource index pointer and the twin data space memory; analyzing the twin data space through a resource index pointer, extracting key data and generating a tree menu structure page; instantiating page classes and combining function columns based on real-time data in the twin data space, and performing page state transition by adopting a state ring scheduling mechanism; designing a communication mode based on continuous memory fragments, and transmitting the continuous memory fragments in the twin data space; and optimizing twin data space to complete relay protection parameter management. According to the invention, the flexibility, compatibility and intelligence of relay protection upper computer parameter management are significantly improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of relay protection of power systems, and in particular to a relay protection parameter management method and system based on twin data space. Background Art

[0002] The existing parameter management method of relay protection devices usually uses a specific parsing module to generate a configuration logic page, and summarizes its code into a logical binary data stream file, which is downloaded to the device and runs through the engine interpretation mode. Under this architecture, the protection configuration management software is tightly coupled with the underlying program of the protection device. When the type or number of resources of the protection device changes, the protection configuration management software needs to be upgraded accordingly. The upgrade process requires a lot of manpower and time, resulting in increased maintenance costs. In addition, a single version of the protection configuration management software is difficult to be compatible with other protection devices, and multiple versions need to be maintained to meet the needs of different devices, which increases the complexity of maintenance work.

[0003] The communication process between traditional protection configuration management software and protection devices is based on fixed memory space index and adopts question-and-answer communication. In this way, the response speed is affected by the amount of communication data. At the same time, the correctness of the protection device operating parameters displayed by the protection configuration management software mainly depends on human judgment. This method is inefficient when processing large amounts of data and is prone to human errors, affecting the reliability and safety of the system. Summary of the invention

[0004] In view of the problems of high coupling degree, poor compatibility, low communication efficiency and difficulty in ensuring parameter correctness in the existing relay protection host computer parameter management method, the present invention is proposed.

[0005] Therefore, the problem to be solved by the present invention is how to achieve decoupling of protection configuration management software from relay protection devices, and improve system compatibility, communication efficiency and accuracy of parameter management.

[0006] In order to solve the above technical problems, the present invention provides the following technical solutions:

[0007] In the first aspect, an embodiment of the present invention provides a relay protection parameter management method based on a twin data space, which includes creating a twin data space; registering a resource index pointer, and establishing a pointing relationship between the resource index pointer and the twin data space memory; parsing the twin data space through the resource index pointer, extracting key data and generating a tree menu structure page; based on the real-time data in the twin data space, instantiating page classes and combining function columns, and using a state loop scheduling mechanism to migrate page states; designing a communication method based on continuous memory fragments to transmit continuous memory fragments in the twin data space; optimizing the twin data space to complete relay protection parameter management.

[0008] As a preferred solution of the relay protection parameter management method based on twin data space described in the present invention, the creation of twin data space includes the following steps: integrating the code of the configuration file parsing module in the underlying program of the protection device into a dynamic link library, and transplanting the dynamic link library into the protection configuration management software; obtaining the configuration file through handshake between the upper computer and the protection device; running the same method as the underlying program of the protection device in the upper computer to parse the configuration file and open up data space; creating configuration items in the data space, and defining the corresponding information structure for each configuration item; the protection configuration management software extracts the information of the data space through the row index pointer to obtain a twin data space corresponding to the data space of the protection device.

[0009] As a preferred scheme of the relay protection parameter management method based on twin data space described in the present invention, wherein: establishing a pointing relationship between a resource index pointer and the twin data space memory includes: creating a resource index pointer pool; traversing all configuration items in the twin data space and creating a resource index table for each configuration item; initializing the resource index table of each configuration item and establishing a mapping relationship between it and the corresponding memory address in the twin data space; traversing the resource index table of each configuration item and registering the resource index pointer to the resource index pointer pool; establishing a direct pointing relationship between the resource index pointer and the twin data space memory; verifying the validity of the registered resource index pointer; dynamically adjusting the allocation and release of the resource index pointer according to the actual usage of the configuration item, and generating a resource index report.

[0010] As a preferred solution of the relay protection parameter management method based on twin data space described in the present invention, wherein: dynamically adjusting the allocation and release of resource index pointers according to the actual usage of the configuration items includes a resource index pointer preloading strategy, and the resource index pointer preloading strategy includes evaluating the importance score of each configuration item; counting the access frequency of each configuration item within a preset time window, and calculating the average access frequency of each configuration item; calculating the static occupied space of each configuration item in the memory; analyzing the logical dependencies between the configuration items; comprehensively evaluating the importance score, average access frequency, static occupied space and logical dependencies of each configuration item, calculating the preloading priority score of each configuration item, and determining the preloading order; judging whether the current system resources allow preloading operations, and if the system resources allow, loading the resource index pointer according to the preloading order.

[0011] As a preferred solution of the relay protection parameter management method based on twin data space described in the present invention, wherein: generating a tree menu structure includes initializing the tree data structure and setting the project name as the root node; using the resource index pointer to access the twin data space, extracting the device name, and setting the device name as the child node of the root node; traversing the configuration items in the twin data space, and when the configuration item member is not empty, setting the configuration item as the child node of the corresponding device name node; for each configuration item node, traversing its associated page name; performing filtering and deduplication operations on the page name, when the page name is not zero, performing deduplication processing and merging duplicate page names; when there is a valid page name, setting the page name as the child node of the corresponding configuration item node to constitute the last node of the tree structure; and hierarchically optimizing the generated tree structure.

[0012] As a preferred solution of the relay protection parameter management method based on twin data space described in the present invention, wherein: instantiating the page class and combining the function columns includes the following steps: traversing all configuration items in the twin data space; creating a corresponding page class instance for each configuration item; parsing the configuration information in the twin data space, dynamically combining the function columns according to the parsed configuration information, and combining the function columns into a two-dimensional table; setting the header and data part of the two-dimensional table, binding the data in the twin data space to the table control, and generating an operable page; creating a dynamic state loop object, and managing the page state through the dynamic state loop object; if a user interaction event or data change is detected, triggering the dynamic state loop to perform state migration; responding to state migration, updating the page display content.

[0013] As a preferred solution of the relay protection parameter management method based on twin data space described in the present invention, wherein: verifying the validity of the registered resource index pointer includes traversing all pointers in the resource index pointer pool; checking whether the memory address of each resource index pointer is within the valid range, and verifying whether the data structure pointed to by the resource index pointer conforms to the predefined format; testing the read and write permissions of the resource index pointer, and performing a null pointer check on each resource index pointer; checking whether the type match of the resource index pointer is correct; recording invalid or abnormal resource index pointers, and marking or removing invalid resource index pointers.

[0014] In the second aspect, an embodiment of the present invention provides a relay protection parameter management system based on a twin data space, which includes a twin data space creation module, which is used to parse the configuration file in the same way as the underlying program of the relay protection device to create a twin data space; a pointer registration module, which is used to register a resource index pointer and establish a pointing relationship between the resource index pointer and the twin data space memory; a menu structure generation module, which is used to parse the twin data space through the resource index pointer, extract key data and generate a tree menu structure; a page structure generation module, which is used to instantiate page classes and combine function columns based on real-time data in the twin data space. A page state migration module, which uses a state loop scheduling mechanism to migrate page states; a communication transmission module, which is used to design a communication method based on continuous memory fragments and transmit continuous memory fragments in the twin data space; an optimization module, which is used to optimize the twin data space and complete relay protection parameter management.

[0015] In a third aspect, an embodiment of the present invention provides a computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: when the computer program instructions are executed by the processor, the steps of the relay protection parameter management method based on the twin data space of the first aspect of the present invention are implemented.

[0016] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium on which a computer program is stored, wherein: when the computer program instructions are executed by a processor, the steps of the relay protection parameter management method based on the twin data space of the first aspect of the present invention are implemented.

[0017] The beneficial effects of the present invention are as follows: the present invention adopts the same parsing method as the underlying program, constructs a twin data space that is completely corresponding to the data space of the protection device, realizes the decoupling between the upper and lower computers, and can adapt itself when the protection resources are changed, ensuring the consistency and synchronization of the data. A resource index pointer pool is established, resource preloading and release are dynamically optimized, and memory allocation is automatically adjusted according to the frequency of use and importance, which greatly improves the response speed and memory utilization efficiency of the system. Based on the tree menu structure and page class instance generated by the twin data space, the page intuitively presents the parameter configuration information and provides a visual function column combination, which greatly improves the user's operating experience. The content transmitted by the communication frame is a continuous memory fragment in the data space, which ensures the synchronization of the two data spaces and improves the efficiency of data retrieval and parsing. A parameter internal abbreviation mechanism is introduced in the twin data space, which can automatically identify and process the parameter content and import automatic logic judgment and visual drawing advanced function modules, while supporting real-time free configuration, improving the intelligence level and adaptability of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0019] Figure 1 This is a framework flow chart of the relay protection parameter management method based on twin data space.

[0020] Figure 2 Schematic diagram of developing twin data space for relay protection parameter management method based on twin data space.

[0021] Figure 3 Schematic diagram of establishing resource index for relay protection parameter management method based on twin data space.

[0022] Figure 4 Schematic diagram of the adaptive generation menu for the relay protection parameter management method based on twin data space.

[0023] Figure 5 Schematic diagram of the adaptive generation page of the relay protection parameter management method based on the twin data space.

[0024] Figure 6 This is the logic block diagram of the state loop scheduling mechanism of the relay protection parameter management method based on twin data space.

[0025] Figure 7 The present invention is a schematic diagram of data communication and analysis method based on twin data space for the relay protection parameter management method based on twin data space.

[0026] Figure 8 A schematic diagram of high-level functional parameter visualization of the relay protection parameter management method based on twin data space.

[0027] Fig. 9 Schematic diagram of tool containerization of relay protection parameter management method based on twin data space. DETAILED DESCRIPTION

[0028] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the accompanying drawings.

[0029] In the following description, many specific details are set forth to facilitate a full understanding of the present invention, but the present invention may also be implemented in other ways different from those described herein, and those skilled in the art may make similar generalizations without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below.

[0030] Secondly, the term "one embodiment" or "embodiment" as used herein refers to a specific feature, structure, or characteristic that may be included in at least one implementation of the present invention. The term "in one embodiment" that appears in different places in this specification does not necessarily refer to the same embodiment, nor does it refer to a separate or selective embodiment that is mutually exclusive with other embodiments.

[0031] Example 1

[0032] Reference Figures 1 to 9 , which is the first embodiment of the present invention, and provides a relay protection parameter management method based on twin data space, including:

[0033] S1: Parse the configuration file in the same way as the underlying program of the relay protection device to create a twin data space.

[0034] Specifically, the following steps are included:

[0035] S1.1: Integrate the code of the configuration file parsing module in the underlying program of the protection device into a dynamic link library, and transplant the dynamic link library into the protection configuration management software.

[0036] S1.2: Obtain the configuration file through handshake between the host computer and the protection device.

[0037] The configuration file is in the bin file format converted from a CSV table.

[0038] S1.3: Run the same method as the underlying program of the protection device in the host computer to parse the configuration file and open up data space.

[0039] The index of the data space is based on the number of rows in the CSV table.

[0040] S1.4: Create fixed configuration items in the data space.

[0041] It should be noted that the configuration file is composed of multiple parts of protection resource configuration. The name of the resource configuration table is configuration item. In the twin data space, the name of "configuration item" is a fixed item, which are configuration version, parameter setting, protection setting, internal setting, protection pressure plate, analog display, switch display, analog recording, switch recording, action event, alarm event, telesignaling, sign, analog input, weak current input, strong current input, tripping output, signal output, panel light, and action report.

[0042] Among them, the definition information of each protection set in the protection set table includes page name string, matching code string, index identification string, internal name string, value type, maximum value, minimum value, default value, unit, and step size; the definition information of each internal set in the internal set table includes page name string, matching code string, index identification string, internal name string, value type, maximum value, minimum value, default value, unit, and step size; the definition information of each protection pressure plate in the protection pressure plate table includes page name string, matching code string, index identification string, internal name string, value type, hard pressure plate mode, and hard pressure plate associated input index identification; the definition information of the analog display in the analog display table includes page name string, matching code string, index identification string, internal name string, value type, unit, print control word, and upload control word; the definition information of each switch display in the switch display table includes page name string, matching code string, index identification string, internal name string, value type, print control word, and upload control word.

[0043] Further, the definition information of each analog quantity recording in the analog quantity recording table includes a page name string, a matching code string, an index identification string, an internal name string, a value type, a unit, a print control word, and an upload control word; the definition information of each switch quantity recording in the switch quantity recording table includes a page name string, a matching code string, an index identification string, an internal name string, a value type, a unit, a print control word, and an upload control word; the definition information of each action event in the action event table includes a page name string, a matching code string, an index identification string, an internal name string, whether to keep the control word, and an action parameter string; the definition information of each alarm event in the alarm event table includes a page name string, a matching code string, an index identification string, an internal name string, whether to keep the control word, and an action parameter string; the definition information of each analog quantity input in the analog quantity input table includes a page name string, a matching code string, an index identification string, an internal name string, an internal sequence, and a channel selection constant index identification;

[0044] Furthermore, the definition information of each weak-current input in the weak-current input table includes a page name string, an optional code string, an index identification string, an internal name string, an internal sequence, a de-bouncing time, a refresh rate, whether to record waves, a recording index identification, and a channel selection constant index identification; the definition information of each strong-current input in the strong-current input table includes a page name string, an optional code string, an index identification string, an internal name string, an internal sequence, a de-bouncing time, a refresh rate, whether to record waves, a recording index identification, and a channel selection constant index identification; the definition information of each tripping output in the tripping output table includes a page name string, an optional code string, an index identification string, an internal name string, an internal sequence, and a channel selection constant index identification; the definition information of each signal output in the signal output table includes a page name string, an optional code string, an index identification string, an internal name string, an internal sequence, and a channel selection constant index identification; the definition information of each panel light in the panel light table includes a page name string, an optional code string, an index identification string, an internal name string, and an internal sequence.

[0045] S1.5: Define the corresponding information structure for each configuration item.

[0046] It should be noted that the information structure includes but is not limited to page name string, option code string, index identification string, internal name string, value type, maximum value, minimum value, default value, unit, step size, etc. The specific information structure depends on the configuration item type.

[0047] S1.6: The protection configuration management software extracts the information of the data space through the row index pointer to obtain a twin data space corresponding to the protection device data space.

[0048] It should be noted that the data space structure of the protection configuration management software corresponds to the data space structure of the protection device, and the twin data space contains the storage location and data format of all protection device configuration parameters.

[0049] S2: Register the resource index pointer, establish the pointing relationship between the resource index pointer and the twin data space memory, and determine the number and validity of parameters.

[0050] Specifically, the following steps are included:

[0051] S2.1: Create a resource index pointer pool to uniformly manage resource index pointers of all configuration items.

[0052] S2.2: Traverse all configuration items in the twin data space and create a resource index table for each configuration item.

[0053] S2.3: Initialize the resource index table for each configuration item and establish a mapping relationship between it and the corresponding memory address in the twin data space.

[0054] S2.4: Traverse the resource index table of each configuration item and register the resource index pointer into the resource index pointer pool.

[0055] S2.5: Establish a direct pointing relationship between the resource index pointer and the twin data space memory.

[0056] S2.6: Verify the validity of the registered resource index pointer.

[0057] Specifically, traverse all pointers in the resource index pointer pool; check whether the memory address of each resource index pointer is within the valid range, and verify whether the data structure pointed to by the resource index pointer conforms to the predefined format; test the read and write permissions of the resource index pointer, and perform a null pointer check on each resource index pointer; verify the consistency of the resource index pointer with the corresponding data in the twin data space; check whether the type match of the resource index pointer is correct; record invalid or abnormal resource index pointers, and mark or remove invalid resource index pointers.

[0058] S2.7: Count the number of parameters of each configuration item and store the statistical results in the resource index pointer pool.

[0059] It should be noted that there are dozens of types of relay protection parameters, and the number is thousands. The actual operation is to configure a base pointer p for each type, know the start and end, and index in the form of p+i. After completing the initialization of the menu and dozens of pages, the page will be placed in the container waiting for instantiation, and the pointer will be placed in the original memory for use. When the handshake with the relay protection device is reconnected online, or the user performs the "check data space / resynchronize interface" operation, the new pointer will be deleted and regenerated.

[0060] S2.8: Dynamically adjust the allocation and release of resource index pointers based on the actual usage of the configuration items.

[0061] Preferably, the method comprises the following steps:

[0062] S2.8.1: Set the usage threshold of the resource index pointer to determine the activity level of the resource index pointer.

[0063] It should be noted that the use threshold includes a high-frequency threshold and a low-frequency threshold, and these two thresholds can be dynamically adjusted according to actual application scenarios.

[0064] S2.8.2: Periodically analyze the resource index pointer usage of each configuration item.

[0065] Specifically, all pointers in the resource index pointer pool are traversed and the access frequency of each pointer is counted; for resource index pointers whose access frequency exceeds the high-frequency threshold, the cache quantity of the pointer in the twin data space is increased and the state is marked as a resident state; for resource index pointers whose access frequency is lower than the low-frequency threshold, the state is marked as a releasable state.

[0066] S2.8.3: Use a priority-based resource index pointer preloading strategy to perform a delayed release operation of the resource index pointer.

[0067] Among them, the resource index pointer preloading strategy includes: evaluating the importance score of each configuration item, and assigning different importance scores according to the degree of impact of the item on system stability, key functions and user experience; counting the access frequency of each configuration item within the preset time window, and calculating the average access frequency of each configuration item; calculating the static space occupied by each configuration item in the memory, and preloading configuration items whose static space occupied is greater than the memory occupation threshold; analyzing the logical dependencies between the configuration items, and preloading upstream items that are accessed by other configuration items more than the dependency threshold; comprehensively evaluating the importance score, average access frequency, memory space and logical dependencies of each configuration item, calculating the preloading priority score of each configuration item, and determining the preloading order; judging whether the current system resources allow the preloading operation, if the system resources allow, loading the resource index pointer according to the preloading order; performing a delayed release operation of the resource index pointer to ensure that these resources can be quickly accessed when needed.

[0068] S2.8.4: Record the dynamic adjustment history of resource index pointers.

[0069] S2.9: Generate a resource index report, which includes the number of parameters, validity status and memory usage of each configuration item.

[0070] S3: Parse the twin data space through resource index pointers, extract key data and generate a tree menu structure.

[0071] Specifically, initialize the tree data structure and set the project name as the root node; use the resource index pointer to access the twin data space, extract the device name, and set the device name as the child node of the root node; traverse the configuration items in the twin data space, and when the configuration item member is not empty, set the configuration item as the child node of the corresponding device name node; for each configuration item node, traverse its associated page name; perform filtering and deduplication operations on the page name, when the page name is none, do not generate the corresponding child node, when the page name is not none, perform deduplication processing, and merge duplicate page names; when there is a valid page name, set the page name as the child node of the corresponding configuration item node to form the last node of the tree structure; when the node is the last node, associate the signal slot with the last node and link it with the corresponding interface; perform hierarchical optimization on the generated tree structure so that the logical relationship between nodes conforms to the predefined hierarchical structure; convert the optimized tree structure into a visual menu format to protect the navigation function of the configuration management software.

[0072] It should be noted that when traversing the page names associated with the configuration items, if a page name is not empty, it is regarded as a valid page name.

[0073] S4: Based on the real-time data in the twin data space, the page class is instantiated and the function columns are combined, and the state loop scheduling mechanism is used to migrate the page state.

[0074] Specifically, traverse all configuration items in the twin data space; for each configuration item, create a corresponding page class instance; parse the configuration information in the twin data space, dynamically combine the function columns according to the parsed configuration information, and combine the function columns into a two-dimensional table; set the header and data part of the two-dimensional table, and bind the data in the twin data space to the table control; create a dynamic state loop object to manage the page status; if a user interaction event or data change is detected, trigger the dynamic state loop to perform state migration; respond to state migration and update the page display content; if the data in the twin data space changes, get the latest data from the twin data space and update the page.

[0075] For example, the function columns include serial number column, parameter name column, current value column, initial value column, fixed value comparison column, bit parameter column, unit column, value range column, step column, time column, investment and withdrawal status column, data conversion column, logical judgment column, data type column, status display column, action parameter column, action event column, and embedded control column (button, text box, drop-down box).

[0076] S5: Design a communication method based on continuous memory fragments to transmit continuous memory fragments in the twin data space, so that the data space of the protection device and the host computer can be synchronized and control instructions can be transmitted.

[0077] Preferably, the communication method between the protection configuration management software and the protection device is designed so that the content transmitted by the communication frame is a continuous memory segment in the data space. The host computer and the protection device have the same data space, which makes it easy to retrieve and parse the memory segment data.

[0078] S6: Optimize the twin data space and complete the relay protection parameter management.

[0079] Preferably, under the premise of decoupling the protection configuration management software from the device, some parameters are agreed upon in the data space with internal abbreviations (aliases), which are used for the identification and classification of the content transmitted by the communication frame by the specific functions of the upper computer, and are unrelated to the operation of the relay protection equipment and the protection configuration management software. For example, "GD-ID" represents the differential action current of the generator, and "GD-IZ" represents its braking current. The alias is defined in the configuration file and edited and written by the developer. In the case where the alias is not defined, the protection configuration management software provides real-time free configuration options.

[0080] It should be noted that the present invention defines the communication frame format and specification between the protection configuration management software and the protection device. It mainly includes: switching fixed value area frame, which is used to set the fixed value area of ​​CPU operation; reading multiple status data frames such as analog display, protection fixed value, parameter fixed value, internal fixed value, etc.; writing soft pressure plate, parameter fixed value, protection fixed value, internal fixed value and other configuration data frames; reading soft pressure plate, hard pressure plate, input and output, signal, indicator light and other status data frames; reporting frames for active reporting of actions and alarm events by the protection device.

[0081] At the same time, the present invention requires that the protection configuration management software can correctly parse these communication frames and can provide feedback records on the frame execution status, including success, unauthorized, arithmetic error, illegal format, memory access exception and other types, to ensure the reliability and robustness of the communication process.

[0082] Furthermore, the present embodiment also provides a relay protection parameter management system based on twin data space, including a twin data space creation module, which is used to parse the configuration file in the same way as the underlying program of the relay protection device to create a twin data space; a pointer registration module, which is used to register the resource index pointer and establish a pointing relationship between the resource index pointer and the twin data space memory; a menu structure generation module, which is used to parse the twin data space through the resource index pointer, extract key data and generate a tree menu structure; a page structure generation module, which is used to instantiate page classes and combine function columns based on real-time data in the twin data space. A page state migration module, which uses a state loop scheduling mechanism to migrate page states; a communication transmission module, which is used to design a communication method based on continuous memory fragments to transmit continuous memory fragments in the twin data space; an optimization module, which is used to optimize the twin data space and complete relay protection parameter management.

[0083] This embodiment also provides a computer device, which is suitable for the case of a relay protection parameter management method based on twin data space, including a memory and a processor; the memory is used to store computer executable instructions, and the processor is used to execute computer executable instructions to implement the relay protection parameter management method based on twin data space proposed in the above embodiment.

[0084] The computer device may be a terminal, and the computer device includes a processor, a memory, a communication interface, a display screen and an input device connected via a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, an operator network, NFC (near field communication) or other technologies. The display screen of the computer device may be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device may be a touch layer covering the display screen, or a key, trackball or touchpad provided on the housing of the computer device, or an external keyboard, touchpad or mouse, etc.

[0085] This embodiment also provides a storage medium on which a computer program is stored. When the program is executed by a processor, the method for managing relay protection parameters based on the twin data space proposed in the above embodiment is implemented.

[0086] In summary, the present invention adopts the same parsing method as the underlying program to construct a twin data space that completely corresponds to the data space of the protection device, realizes the decoupling between the upper and lower computers, and can adapt when the protection resources change, ensuring the consistency and synchronization of the data. A resource index pointer pool is established to dynamically optimize resource preloading and release, and automatically adjust memory allocation according to the frequency of use and importance, which greatly improves the response speed and memory utilization efficiency of the system. Based on the tree menu structure and page class instance generated by the twin data space, the page intuitively presents the parameter configuration information and provides a visual function column combination, which greatly improves the user's operating experience. The content transmitted by the communication frame is a continuous memory fragment in the data space, which ensures the synchronization of the two data spaces and improves the efficiency of data retrieval and parsing. A parameter internal abbreviation mechanism is introduced in the twin data space, which can automatically identify and process the parameter content and import automatic logic judgment and visual drawing advanced function modules, while supporting real-time free configuration, improving the intelligence level and adaptability of the system.

[0087] Example 2

[0088] Reference Figures 1 to 9 , which is the second embodiment of the present invention, provides a relay protection parameter management method based on twin data space. In order to verify the beneficial effects of the present invention, scientific demonstration is carried out through economic benefit calculation and simulation experiments.

[0089] The present invention proposes a relay protection host computer parameter management method based on a twin data space. The protection configuration management software and the relay protection device have the same data space, which is reflected in the fact that the parsing method of the configuration file is completely consistent, and the structure of constructing the data space is completely consistent. It is the basis for realizing the decoupling of the protection configuration management software and the protection device. After obtaining the configuration instructions, the protection device and the protection configuration management software are simultaneously launched. On the basis of the twin data space, the protection device configures the software and hardware configuration according to the content of the data space, registers the protection function, and starts the scheduling cycle. The protection configuration management software adaptively generates various menus and interfaces according to the content of the data space, and configures advanced functions. In response to different needs, the device and the protection configuration management software are launched in their respective application directions, and the method is as shown in the attached figure. Figure 2 shown.

[0090] In the resource indexing stage, first obtain the base address of resources such as parameter constants, protection constants, and internal constants from the data space, and obtain the number of each type of resources. The protection configuration management software analyzes the above data to locate the starting position and range of each type of resource as the basis for subsequent resource processing. Initialize the index pointer, starting from the base address of each resource, and traverse all resource items one by one according to the number of resources to ensure that each resource is checked and processed. In the process of traversing the resource items, perform a validity check on each resource item to ensure that the resource object exists. At the same time, check the enabled status of the resources. Through the validity check, filter out resources that do not need to be processed to improve the efficiency of the program. Finally, establish a pointing relationship between the resource index pointer and the running space memory. The protection configuration management software locates the resource through the resource index pointer and obtains the required information. The process of establishing a resource index mapping is shown in the attached figure. Figure 3 shown.

[0091] In the menu adaptive generation stage, the boot menu of the protection configuration management software is generated in a tree structure, with the "project name" in the data space as the root node and the "device name" as its child. The next level node of the "device name" is taken from the "configuration item" type in the data space structure, such as: parameter setting, protection setting, internal setting, analog display, etc. The child item of the "configuration item" is the "page name". A screening module is designed, and the same items are merged as the last level node. The same "page name" members under the same "configuration item" in the data space are constructed and merged as the corresponding child node names under the "configuration item". If the page name is "None", no child node is generated. The last level contact is associated with the signal slot, and the page associated with it can be opened. The process of generating a menu according to the data space is shown in the attached figure. Figure 4 shown.

[0092] In the page adaptive generation stage, the functional interface of the protection configuration management software is generated according to the "configuration item" members in the data space, which is a visual display of the data in the twin data space. Using an object-oriented design method, each "configuration item" type is designed with a class of corresponding functions, which is instantiated according to the data space. The main function of the "function page class" is to dynamically generate an interface, display the parameters in the data space, and provide an operation interface for the user. The function page adopts a flexible composition method. Each page is composed of multiple "function columns", and each column corresponds to a parameter type in the data space. In the interface generation stage, the "function column" is combined according to the type of members under each "configuration item" in the data space to form a complete page, which is specifically presented as a two-dimensional table, divided into two parts: the header and the data in the table. The header is the name of the function column, and the display and processing form of the data in the table are determined by the function of the column. Through the row and column indexes of the two-dimensional array, specific interface elements can be locked to facilitate data operations and interface updates. The process of combining "function columns" into an interface is shown in the attached figure. Figure 5 As shown. Refreshing a large amount of data on the page will cause jamming, and the communication, management, calculation, and display of the protection configuration management software will be placed in different threads. Use thread pool optimization. The function of the thread pool is to manage, reuse, and recycle a group of threads, control the number of threads, and avoid frequent creation and destruction of threads and waste of resources. The page as a whole uses a state loop scheduling mechanism, sending a handshake frame every 500ms. At the same time, it comprehensively analyzes the current working status and trigger conditions of the host computer, migrates to the new page state, and performs function management, data synchronization, frame control, and exception handling. The logic block diagram of the state loop scheduling mechanism is shown in the attached Figure 6 shown.

[0093] Based on the twin data space, the communication and data parsing methods are designed. The content transmitted by the frame is the memory fragment of the relay protection device or the host computer data space. The protection configuration management software and the protection device have the same data space, which makes it easy to retrieve and parse the memory fragment data. The essence of a memory fragment is a series of bits with content of 0 or 1, and the data type interpreted depends on how the data is used. Using the starting offset address and the ending offset address as indexes, the protection device and the protection configuration management software insert the transmitted data into the twin data space, that is, interpret the original data in the same way. The memory fragment itself has encryption properties, which enhances the security of the communication process. The structural diagram of moving memory fragments and performing data indexing and parsing based on the twin data space is shown in the attached figure. Figure 7 shown.

[0094] In the advanced function configuration stage, under the premise of decoupling the protection configuration management software from the device, the index of the parameter is no longer related to its name. Some parameters are agreed upon in the data space with internal abbreviations (aliases) for the specific functions of the upper computer to identify and classify the content transmitted by the communication frame. The data identified by the alias has nothing to do with the actual parameter name, such as "GDID" for the generator differential action current, and "GDIZ" for the braking current. The parsed data is collected and classified, and the image of the relevant relay protection module is drawn with the corresponding constant value to dynamically display the current protection parameters. The real-time data in the protection device data space is analyzed and processed, and displayed in the drawing module to visualize the abstract data, which is one of the interactive designs of the protection configuration management software. The data loaded on the page is an intuitive display of the content of the data space. In addition to judging the visual data type by judging the alias, the user can also select it on the page of the relevant protection module and drag the page data into the receiving slot of the visualization interface to associate the data with the drawing module and draw real-time drawings based on the associated data. The structural diagram of the protection data visualization is shown in the attached figure. Figure 8 As shown. The upload, display, setting, modification and downloading of the setting parameters of the protection device are important functions of the protection configuration management software, and their reliability should be guaranteed. With the opening of parameters such as the transformer polarity control word and the trip matrix control word, the setting has the characteristics of mixed data types (including binary, decimal, hexadecimal, etc.), which may confuse novices and setting calculation personnel who lack engineering experience, and is a threat to the normal operation of the protection device. Therefore, the configuration bit parameter visualization module displays the objects contained in each bit of each control word, and the user can intuitively understand the corresponding changes in the mode of action after the setting value is changed. The display of operating parameters has important applications in factory debugging, commissioning and grid connection. It parses the communication frame to obtain protection data, triggers the corresponding slot function, indexes the range constraints corresponding to the data in the twin data space, and intelligently judges the correctness of the operating parameters of the protection device. It can be applied to the voltage and current increase and grid connection observation stage at the commissioning site.

[0095] Adopting the containerized design concept, offline functions and online functions are sorted out into some independent sub-functions of separate applications, and placed in the main menu in the form of sub-tools. Reduce the number of independent tools and integrate the current debugging tools together to facilitate engineering debugging and modular development and integration of subsequent functions. The containerized design structure diagram is as follows Fig. 9 shown.

[0096] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention, which should all be included in the scope of the claims of the present invention.

Claims

1. A relay protection parameter management method based on twin data space, characterized in that: include, Create a twin data space; Register a resource index pointer and establish a pointing relationship between the resource index pointer and the twin data space memory; Parsing the twin data space through the resource index pointer, extracting key data and generating a tree menu structure page; Based on the real-time data in the twin data space, the page class is instantiated and the function columns are combined, and the state loop scheduling mechanism is used to migrate the page state; Designing a communication method based on continuous memory fragments to transfer continuous memory fragments in the twin data space; The twin data space is optimized to complete the relay protection parameter management.

2. The relay protection parameter management method based on twin data space according to claim 1, characterized in that: The creation of the twin data space includes the following steps: Integrate the code of the configuration file parsing module in the bottom program of the protection device into a dynamic link library, and transplant the dynamic link library into the protection configuration management software; Obtain the configuration file through handshake between the host computer and the protection device; The same method as the underlying program of the protection device is run in the host computer to parse the configuration file and open up data space; Creating configuration items in the data space and defining a corresponding information structure for each configuration item; The protection configuration management software extracts information from the data space through a row index pointer to obtain a twin data space corresponding to the protection device data space.

3. The relay protection parameter management method based on twin data space according to claim 2 is characterized in that: The establishing of the pointing relationship between the resource index pointer and the twin data space memory includes: Create a resource index pointer pool; Traverse all configuration items in the twin data space and create a resource index table for each configuration item; Initialize the resource index table for each configuration item and establish a mapping relationship between it and the corresponding memory address in the twin data space; Traverse the resource index table of each configuration item and register the resource index pointer to the resource index pointer pool; Establish a direct pointing relationship between the resource index pointer and the twin data space memory; Verify the validity of the registered resource index pointer; Dynamically adjust the allocation and release of resource index pointers according to the actual usage of the configuration items, and generate a resource index report.

4. The relay protection parameter management method based on twin data space according to claim 3 is characterized in that: The dynamically adjusting the allocation and release of resource index pointers according to the actual usage of the configuration items includes a resource index pointer preloading strategy, and the resource index pointer preloading strategy includes: Assess the importance score of each configuration item; Count the access frequency of each configuration item within the preset time window and calculate the average access frequency of each configuration item; Calculate the static memory footprint of each configuration item; Analyze the logical dependencies between configuration items; Comprehensively evaluate the importance score, average access frequency, static space usage, and logical dependencies of each configuration item, calculate the preloading priority score of each configuration item, and determine the preloading order; Determine whether the current system resources allow preloading operations. If system resources allow, resource index pointers are loaded according to the preload order.

5. The relay protection parameter management method based on twin data space according to claim 1, characterized in that: The generated tree menu structure includes: Initialize the tree data structure and set the project name as the root node; Access the twin data space using the resource index pointer, extract the device name, and use the device name as a child node of the root node; Traversing the configuration item members in the twin data space, and when the configuration item member is not empty, setting the configuration item as a child node of the corresponding device name node; For each configuration item node, traverse its associated page name; Performing screening and deduplication operations on the page names, and when the page names are not absent, performing deduplication processing and merging duplicate page names; When there is a valid page name, the page name is set as a child node of the corresponding configuration item node to form the last node of the tree structure; The generated tree structure is hierarchically optimized.

6. The relay protection parameter management method based on twin data space according to claim 1, characterized in that: The instantiation of the page class and combination of the function columns comprises the following steps: Traverse all configuration items in the twin data space; For each configuration item, create a corresponding page class instance; Parsing the configuration information in the twin data space, dynamically combining the function columns according to the parsed configuration information, and combining the function columns into a two-dimensional table; Setting the header and data part of the two-dimensional table, binding the data in the twin data space to the table control, and generating an operable page; Create a dynamic state loop object and manage the page state through the dynamic state loop object; If a user interaction event or data change is detected, the dynamic state loop is triggered to perform state migration; Respond to state transitions and update page display content.

7. The relay protection parameter management method based on twin data space according to claim 3 is characterized in that: The validity verification of the registered resource index pointer includes: Traverse all pointers in the resource index pointer pool; Check whether the memory address of each resource index pointer is within the valid range, and verify whether the data structure pointed to by the resource index pointer conforms to the predefined format; Test the read and write permissions of the resource index pointer and perform a null pointer check on each resource index pointer; check whether the type match of the resource index pointer is correct; Record invalid or abnormal resource index pointers, and mark or remove invalid resource index pointers.

8. A relay protection parameter management system based on twin data space, based on the relay protection parameter management method based on twin data space according to any one of claims 1 to 7, characterized in that: Also includes, A twin data space creation module is used to parse the configuration file in the same way as the underlying program of the relay protection device to create a twin data space; A pointer registration module is used to register a resource index pointer and establish a pointing relationship between the resource index pointer and the twin data space memory; A menu structure generation module, used to parse the twin data space through the resource index pointer, extract key data and generate a tree menu structure; A page structure generation module, used for instantiating page classes and combining function columns based on real-time data in the twin data space; The page state migration module uses the state ring scheduling mechanism to migrate the page state; A communication transfer module, used to design a communication method based on continuous memory fragments to transfer continuous memory fragments in the twin data space; The optimization module is used to optimize the twin data space and complete the relay protection parameter management.

9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the relay protection parameter management method based on the twin data space described in any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the relay protection parameter management method based on the twin data space described in any one of claims 1 to 7 are implemented.