A capacitance measurement and control instrument data processing method and device
By generating detailed event log records at key nodes of the intelligent capacitor measuring instrument, combined with the dual verification mechanism of CRC and RS codes, the traceability and reliability problems of data processing in traditional measuring instruments under high-frequency transient faults are solved, the transparency and operation and maintenance efficiency of fault analysis are improved, and the resource limitations of edge-side equipment is adapted.
Patent Information
- Application Number
- CN202510585062.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-08
- Publication Date
- 2025-09-02
- Estimated Expiration
- 2045-05-08
AI Technical Summary
Traditional smart capacitor measuring and control instruments lack traceability in high-frequency transient fault scenarios, are susceptible to electromagnetic interference and have limited resources, resulting in difficulty in fault analysis and reduced data reliability.
Generate event log records at key nodes, including timestamps, event types, event descriptions and CRC check codes, adopt a dual verification mechanism (CRC and RS codes), and saves through non-volatile memory, providing a standard communication interface to support remote access and flexible configuration of logging levels.
It realizes traceability and reliability of data processing processes in complex electromagnetic environments, improves the transparency and operation and maintenance efficiency of fault analysis, reduces resource consumption, and meets the real-time requirements of high-frequency transient faults.
Smart Images

Figure CN120104429B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of capacitance measurement and control instrument data processing, and in particular to a capacitance measurement and control instrument data processing method and device. Background Art
[0002] In the complex operating environment of modern smart substations, smart capacitor measurement and control instruments, as critical edge devices, have a direct impact on the safety and stability of the power grid through their data processing capabilities. Especially when high-frequency transient faults occur, the measurement and control instruments must quickly and reliably record and process relevant data for fault analysis and accountability. However, traditional smart capacitor measurement and control instruments face numerous challenges in handling such scenarios.
[0003] First, the data processing process of existing measurement and control instruments often lacks transparency. Once a failure occurs, operations and maintenance personnel struggle to accurately trace the data processing details before and after the failure, making it difficult to analyze the cause and assign responsibility. To improve substation reliability and maintainability, a technology that can effectively track the data processing process of measurement and control instruments is urgently needed.
[0004] Secondly, the electromagnetic environment within smart substations is extremely complex, with high-frequency electromagnetic interference being prevalent. This interference can easily compromise the reliability of data transmission and storage, leading to data errors or loss. The electromagnetic environment is particularly harsh during high-frequency transient faults, further exacerbating the threat to data integrity. Therefore, ensuring the reliability of data processing in such harsh electromagnetic environments has become a pressing issue.
[0005] Furthermore, the computing resources of intelligent electronic devices at the edge are typically limited. Complex logging mechanisms can overconsume the device's computing and storage resources, impacting normal data processing capabilities and even reducing the real-time nature of data processing. Achieving effective data processing traceability on resource-constrained edge devices while avoiding excessive resource consumption is a key consideration when designing logging functionality for intelligent capacitor measurement and control instruments.
[0006] Furthermore, the current level of intelligent substation operation and maintenance still has room for improvement. When conducting fault analysis, operators often lack detailed data support, making it difficult to quickly locate the root cause. Providing a mechanism to record in detail the data processing process of measurement and control instruments when a fault occurs would greatly improve operation and maintenance efficiency and fault handling capabilities, providing strong support for intelligent substation operation and maintenance.
[0007] Finally, existing data verification methods may not provide adequate protection in high-frequency transient fault scenarios. Simple verification methods may not effectively resist high-frequency electromagnetic interference, while overly complex verification methods can lead to excessive resource overhead and time delays. Therefore, it is necessary to design a resource-efficient and interference-resistant data verification mechanism tailored to the characteristics of high-frequency transient faults in smart substations to ensure traceability and reliability of data processing. Summary of the Invention
[0008] The purpose of the present invention is to provide a capacitance measurement and control instrument data processing method and device, which solves the problems that the data processing process of traditional intelligent capacitor measurement and control instruments lacks traceability and is susceptible to electromagnetic interference, and faces resource constraints. Under the premise of ensuring the real-time performance of data processing, the data processing process can be effectively traced, and the integrity and reliability of the data in complex electromagnetic environments can be improved.
[0009] In a first aspect, the present invention provides a capacitance measurement and control instrument data processing method, comprising the following steps:
[0010] Obtain capacitor operation data;
[0011] Based on the capacitor operation data, key nodes of the data processing process are monitored; the key nodes include the data collection start node, the filtering process completion node, and the fault judgment completion node;
[0012] When the key node is monitored, a corresponding event log record is generated according to the preset log record level; the event log record includes a timestamp, event type, event description and data verification information; the timestamp accuracy is microsecond level; the event type is used to identify the data processing stage; the event description is used to record the details of the processing steps; the data verification information includes a CRC checksum using a cyclic redundancy check, and different log record levels correspond to CRC checksums of different lengths;
[0013] The event log records are stored in a local non-volatile memory in chronological order, and a standard communication interface is provided to support remote access and reading of the event log records, and to allow operation and maintenance personnel to remotely configure the log record level according to needs.
[0014] The capacitance measurement and control instrument data processing method provided by the present invention performs event log recording in the intelligent capacitor measurement and control instrument, and presets multiple log recording levels, such as "standard log", "enhanced log" and "simplified log". The event log recording module monitors the key nodes of the data processing flow. At each key node, the event log recording module automatically generates a log record containing a timestamp, event type, event description and data verification information according to the preset log recording level. Different log levels correspond to CRC check codes of different lengths. For example, the "enhanced log" level uses a longer CRC check code to improve data reliability, and the "simplified log" level uses a shorter CRC check code to reduce resource consumption. The "standard log" level uses a compromise CRC check code length. It meets the traceability requirements of the data processing process in high-frequency transient fault scenarios, realizes effective tracing of the data processing process, and improves the integrity and reliability of data in complex electromagnetic environments.
[0015] Furthermore, when the key node is monitored, the step of generating a corresponding event log record according to a preset log record level includes:
[0016] A. Determine the current key nodes monitored and implement the following:
[0017] A1. If it is the data collection start node, the preset phase-locked loop synchronization mechanism is activated to calibrate the timestamp to ensure microsecond accuracy.
[0018] A2. If the filtering process is completed at the node, the mean square error of the data before and after filtering is calculated, and when the mean square error exceeds a first preset threshold, an abnormal flag is added to the event type;
[0019] A3. If the fault diagnosis is complete, analyze the sensitivity of the input data to electromagnetic interference using a preset fault diagnosis algorithm. Based on the analysis results, mark the input data with a sensitivity exceeding a second preset threshold as a key parameter susceptible to interference in the event description. The input data is the capacitor operating data input to the fault diagnosis algorithm.
[0020] B. Select the CRC check code length according to the logging level; the logging level includes high, medium and low. The high logging level corresponds to the selection of a 32-bit CRC check code, the medium logging level corresponds to the selection of a 16-bit CRC check code, and the low logging level corresponds to the selection of an 8-bit CRC check code;
[0021] C. Obtain the event log record based on the calibrated timestamp, the event type including the abnormality flag, the event description including the key parameters, and the selected CRC check code.
[0022] By selecting CRC check codes of different lengths according to different log record levels, you can ensure data verification strength while taking into account resource consumption, achieving a balance between data reliability and resource utilization.
[0023] Furthermore, the step of obtaining the event log record according to the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters and the selected CRC check code includes:
[0024] Using a predefined binary format, a preliminary event log record is constructed by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum.
[0025] Based on the RS code, the preliminary event log record is subjected to anti-interference encoding to obtain a final event log record.
[0026] This dual-check mechanism combines the error detection capability of cyclic redundancy check code and the error correction capability of RS code, which can more effectively deal with data interference problems in complex electromagnetic environments and improve the reliability of data processing.
[0027] Furthermore, using a predefined binary format, the steps of constructing a preliminary event log record by combining a calibrated timestamp, an event type including an abnormality flag, an event description including key parameters, and a selected CRC checksum include:
[0028] Load the calibrated timestamp, event type including abnormality flag, event description including key parameters, and selected CRC check code into the corresponding data buffer respectively;
[0029] According to the predefined binary format, in the order of timestamp, event type, event description, and CRC check code, the data of each data buffer is read, the preset separator is inserted, and then written to the target storage area to finally form a preliminary event log record.
[0030] The log records constructed by this method have a clear structure and are easy to parse, providing strong support for subsequent log analysis and fault tracing.
[0031] Furthermore, the steps of performing anti-interference encoding on the preliminary event log record based on RS code to obtain the final event log record include:
[0032] Determining encoding parameters of the RS code; the encoding parameters include a codeword length, an information bit length, and an error correction capability coefficient; wherein the codeword length is determined based on the length of the preliminary event log record, the information bit length is determined based on the sum of the data lengths of the timestamp, the event type, and the event description, and the error correction capability coefficient is calculated based on the codeword length and the information bit length;
[0033] Generate a generating polynomial of the RS code according to the determined RS code encoding parameters;
[0034] The timestamp, event type and event description in the preliminary event log record are regarded as information bits, and multiple zeros are filled after the information bits to form a data sequence to be encoded;
[0035] Using the generator polynomial, RS encoding is performed on the data sequence to be encoded to obtain a plurality of check bits, wherein the number of the check bits is the same as the number of zeros padded with the information bits;
[0036] After all the check bits are appended to the information bits, the final event log record including the timestamp, event type, event description and check bits is formed.
[0037] In a second aspect, the present invention provides a capacitance measurement and control instrument data processing device, comprising:
[0038] An acquisition module, used for acquiring capacitor operation data;
[0039] A monitoring module, configured to monitor key nodes of a data processing flow according to the capacitor operation data; the key nodes include a data acquisition start node, a filtering process completion node, and a fault determination completion node;
[0040] A generation module is configured to generate a corresponding event log record according to a preset log record level when the key node is monitored; the event log record includes a timestamp, an event type, an event description, and data verification information; the timestamp accuracy is microsecond level; the event type is used to identify the data processing stage; the event description is used to record the details of the processing steps; the data verification information includes a cyclic redundancy check (CRC) check code, and different log record levels correspond to CRC check codes of different lengths;
[0041] The storage module is used to store the event log records in a local non-volatile memory in chronological order, and provides a standard communication interface to support remote access and reading of the event log records, and allows operation and maintenance personnel to remotely configure the logging level according to needs.
[0042] The capacitance measurement and control instrument data processing device provided by the present invention records key events including detailed information and data integrity checks. This method provides a robust and traceable record for data processing within the capacitor control instrument, solving the problems of transparency, data reliability in complex electromagnetic environments, and resource constraints.
[0043] Furthermore, when the key node is detected, the generation module generates a corresponding event log record according to a preset log record level and executes:
[0044] A. Determine the current key nodes monitored and implement the following:
[0045] A1. If it is the data collection start node, the preset phase-locked loop synchronization mechanism is activated to calibrate the timestamp to ensure microsecond accuracy.
[0046] A2. If the filtering process is completed at the node, the mean square error of the data before and after filtering is calculated, and when the mean square error exceeds a first preset threshold, an abnormal flag is added to the event type;
[0047] A3. If the fault diagnosis is complete, analyze the sensitivity of the input data to electromagnetic interference using a preset fault diagnosis algorithm. Based on the analysis results, mark the input data with a sensitivity exceeding a second preset threshold as a key parameter susceptible to interference in the event description. The input data is the capacitor operating data input to the fault diagnosis algorithm.
[0048] B. Select the CRC check code length according to the logging level; the logging level includes high, medium and low. The high logging level corresponds to the selection of a 32-bit CRC check code, the medium logging level corresponds to the selection of a 16-bit CRC check code, and the low logging level corresponds to the selection of an 8-bit CRC check code;
[0049] C. Obtain the event log record based on the calibrated timestamp, the event type including the abnormality flag, the event description including the key parameters, and the selected CRC check code.
[0050] Furthermore, the generation module is used to execute the following when obtaining the event log record based on the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters, and the selected CRC check code:
[0051] Using a predefined binary format, a preliminary event log record is constructed by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum.
[0052] Based on the RS code, the preliminary event log record is subjected to anti-interference encoding to obtain a final event log record.
[0053] Furthermore, the generation module is executed when constructing a preliminary event log record using a predefined binary format by combining a calibrated timestamp, an event type including an exception flag, an event description including key parameters, and a selected CRC checksum:
[0054] Load the calibrated timestamp, event type including abnormality flag, event description including key parameters, and selected CRC check code into the corresponding data buffer respectively;
[0055] According to the predefined binary format, in the order of timestamp, event type, event description, and CRC check code, the data of each data buffer is read, the preset separator is inserted, and then written to the target storage area to finally form a preliminary event log record.
[0056] Furthermore, when the generating module is used to perform anti-interference encoding on the preliminary event log record based on the RS code to obtain the final event log record, the following steps are executed:
[0057] Determining encoding parameters of the RS code; the encoding parameters include a codeword length, an information bit length, and an error correction capability coefficient; wherein the codeword length is determined based on the length of the preliminary event log record, the information bit length is determined based on the sum of the data lengths of the timestamp, the event type, and the event description, and the error correction capability coefficient is calculated based on the codeword length and the information bit length;
[0058] Generate a generating polynomial of the RS code according to the determined RS code encoding parameters;
[0059] The timestamp, event type and event description in the preliminary event log record are regarded as information bits, and multiple zeros are filled after the information bits to form a data sequence to be encoded;
[0060] Using the generator polynomial, RS encoding is performed on the data sequence to be encoded to obtain a plurality of check bits, wherein the number of the check bits is the same as the number of zeros padded with the information bits;
[0061] After all the check bits are appended to the information bits, the final event log record including the timestamp, event type, event description and check bits is formed.
[0062] As can be seen from the above, the capacitor measurement and control instrument data processing method provided by the present invention automatically generates detailed event logs at key nodes of the intelligent capacitor measurement and control instrument, fully recording all aspects of data processing. This provides a reliable data basis for fault analysis, responsibility tracing, and compliance auditing, significantly improving the reliability of smart substation operations. The event logging process is designed to be lightweight, resource-efficient, and minimally impacts normal data processing. Microsecond-level timestamps ensure the time accuracy of event records, meeting the real-time requirements for rapid processing of high-frequency transient faults. Furthermore, by introducing data verification information (CRC checksum) into the log records, the log data's resistance to electromagnetic interference is effectively improved, ensuring its integrity and reliability, and ensuring the accuracy of log records even in the complex electromagnetic environment of the substation. Furthermore, through a hierarchical logging mechanism, the data verification strength can be flexibly adjusted according to needs, achieving a balance between data reliability and resource consumption. Finally, the event logging method fully considers the resource constraints of edge-side intelligent electronic devices in its design, resulting in simple module deployment and controllable resource consumption. By selecting the appropriate logging level, resource consumption can be minimized while ensuring data traceability, adapting to the resource constraints of edge-side devices.
[0063] Other features and advantages of the present invention will be described in the following description, and in part will become apparent from the description, or will be understood by practicing the embodiments of the present invention. The purposes and other advantages of the present invention can be realized and obtained by the structures particularly pointed out in the written description and the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0064] Figure 1 A flow chart of a data processing method for a capacitance measurement and control instrument provided in an embodiment of the present invention.
[0065] Figure 2 A schematic structural diagram of a capacitance measurement and control instrument data processing device provided in an embodiment of the present invention.
[0066] Description of labels:
[0067] 100, acquisition module; 200, monitoring module; 300, generation module; 400, storage module. DETAILED DESCRIPTION
[0068] The technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. The components of the embodiments of the present invention generally described and shown in the drawings herein can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present invention.
[0069] It should be noted that similar reference numerals and letters represent similar items in the following drawings. Therefore, once an item is defined in one drawing, it does not need to be further defined or explained in subsequent drawings. At the same time, in the description of the present invention, the terms "first", "second", etc. are used only to distinguish the description and should not be understood as indicating or implying relative importance.
[0070] Reference Attachment Figure 1 The present invention provides a capacitance measurement and control instrument data processing method, comprising the following steps:
[0071] Obtain capacitor operation data;
[0072] Based on the capacitor operation data, monitor the key nodes of the data processing process; the key nodes include the data collection start node, the filtering processing completion node and the fault judgment completion node;
[0073] When a key node is monitored, a corresponding event log record is generated according to the preset log record level; the event log record contains a timestamp, event type, event description, and data verification information; the timestamp accuracy is microsecond level; the event type is used to identify the data processing stage; the event description is used to record the details of the processing steps; the data verification information includes a cyclic redundancy check (CRC) checksum, and different log record levels correspond to different CRC checksum lengths;
[0074] The event log records are stored in local non-volatile memory in chronological order, and a standard communication interface is provided to support remote access and reading of event log records, and allow operation and maintenance personnel to remotely configure the logging level according to needs.
[0075] The core of this approach lies in the generation of event logs at key nodes. Capturing capacitor operating data is an initial step, providing data input for subsequent processing and monitoring. This can be achieved through sensors connected to the capacitors, which periodically send data readings to the control system. Key monitoring nodes are specific points in the data processing flow where data acquisition begins, filtering is completed, and fault diagnosis is completed. These nodes represent important stages in the data processing process. Node monitoring is implemented by inserting flags or triggers at designated locations in the data processing software. When the program executes at these points, the monitoring mechanism is activated. When a critical node is monitored, an event log is generated based on the preset log level. The log content includes: a timestamp, which records the precise time of the event. Microsecond-level accuracy is crucial for high-frequency transient fault analysis. A high-precision real-time clock, such as one using a phase-locked loop (PLL) synchronization mechanism, can provide microsecond-level timestamps; an event type, which identifies the data processing stage and can be represented by a numeric code or a descriptive string to facilitate log classification and filtering; an event description, which provides detailed information about the processing steps to enhance process transparency. The event description can be dynamically generated based on the event context and include relevant parameters or intermediate results; and a CRC checksum, which provides data verification information. A cyclic redundancy check (CRC) is used. Different log levels correspond to different CRC lengths to balance reliability and resource usage. The CRC checksum is calculated based on the log data before storage. The CRC code length, such as 8, 16, or 32 bits, is selected based on the preset log level. Event logs are stored in chronological order in non-volatile memory for durability. Non-volatile memory, such as flash memory, ensures data is not lost in the event of a power outage. Standard communication interfaces, such as Ethernet or serial ports, are provided for remote access and reading. Remote access is achieved through Modbus or TCP / IP protocols. Operations and maintenance personnel can remotely adjust the log level as needed. This remote configuration is achieved through a network interface, allowing operations and maintenance personnel to send commands to change the log level settings.
[0076] Specifically, this data processing method aims to improve the transparency and reliability of capacitor controllers, especially in complex electromagnetic environments. First, capacitor operating data is acquired. Then, predefined key nodes in the data processing process are monitored, including the start of data acquisition, completion of filtering, and completion of fault diagnosis. These nodes are selected because they represent important stages in data processing. When a key node is detected, an event log is automatically generated. This event log fully records every step of the data processing, providing reliable data for fault analysis, accountability, and compliance audits, significantly enhancing the operational credibility of smart substations. The event logging process is designed to be lightweight, resource-efficient, and minimize impact on normal data processing. Log content depends on the predefined log level, such as "standard log," "enhanced log," or "reduced log." Each log entry includes a microsecond-precision timestamp, ensuring accurate time-based event tracking. This is crucial for analyzing fast transient faults and meets the real-time requirements of high-frequency transient fault processing. Event types clearly identify the data processing stage, providing context for the log. Event descriptions provide detailed information about the specific processing steps performed at that node, enhancing transparency in the data processing process. Furthermore, by introducing data verification information (CRC) into log records, the log data's resistance to electromagnetic interference is effectively improved, ensuring its integrity and reliability, even in the complex electromagnetic environment of substations. Furthermore, a hierarchical logging mechanism allows for flexible adjustment of data verification strength based on demand, striking a balance between data reliability and resource consumption. Higher log levels utilize longer CRC codes for greater reliability, while lower levels use shorter codes to conserve resources. Generated event logs are stored in chronological order in non-volatile memory, ensuring log persistence even during power outages. A standard communication interface is provided, enabling maintenance personnel to remotely access these logs for diagnostics and analysis. Furthermore, log levels can be remotely configured, allowing operators to adjust the level of logging detail based on current needs and resource availability. This dynamic adjustment ensures that sufficient log information is provided when needed without unnecessarily burdening the system during normal operation. This event logging approach takes into account the resource constraints of edge intelligent electronic devices, enabling simple module deployment and manageable resource consumption. By selecting the appropriate logging level, we can minimize resource consumption while ensuring data traceability, adapting to the resource constraints of edge devices. By recording key events with detailed information and data integrity checks, this approach provides a robust and traceable record of data processing within the capacitor controller, addressing issues of transparency, data reliability in complex electromagnetic environments, and resource constraints.
[0077] In some embodiments, the logging system is configured with three levels: "Low," "Medium," and "High." When the data acquisition process begins, the "Data Acquisition Started" node is triggered. If the log level is set to "Medium," an event log is generated. This log includes a timestamp obtained from the PLL-synchronized real-time clock, an event type set to "Data Acquisition Started," an event description (e.g., "Data Acquisition for Capacitor Bank A Started"), and a 16-bit CRC calculated over the timestamp, event type, and event description. This log entry is then appended to the event log file stored in flash memory. Subsequently, if the filtering process completes and the "Filtering Completed" node is triggered, and the log level is still "Medium," another log entry is created. This entry includes a new timestamp, event type "Filtering Completed," a description (e.g., "Moving average filter applied, standard deviation before filtering: 2.5, after filtering: 0.5"), and another 16-bit CRC. This entry is also stored in flash memory, chronologically following the previous entry. If a fault is detected during the fault diagnosis phase, the "Fault Diagnosis Completed" node is reached, and the log level is set to "High," a more detailed log is generated. This log includes a timestamp, event type "Fault determination complete," a detailed event description (e.g., "Overvoltage fault detected, voltage reading: 1.2kV, threshold: 1.1kV, input data EMI sensitivity: high (parameters: voltage, current)"), and a 32-bit CRC checksum for enhanced data integrity. When the log level is set to "High," this detailed log and longer CRC provide maximum information and reliability for critical events. Throughout the process, remote operators can use the standard Modbus TCP interface to read the stored log or change the log level to "Low" for reduced redundancy during normal operation, or back to "High" for detailed diagnostics during troubleshooting.
[0078] In some embodiments, when a key node is monitored, the step of generating a corresponding event log record according to a preset log record level includes:
[0079] A. Determine the current key nodes monitored and implement the following:
[0080] A1. If it is the data collection start node, the preset phase-locked loop synchronization mechanism is activated to calibrate the timestamp to ensure microsecond accuracy.
[0081] A2. If the filtering process is completed at the node, the mean square error of the data before and after filtering is calculated, and when the mean square error exceeds the first preset threshold, an abnormal flag is added to the event type;
[0082] A3. If the fault diagnosis is complete, the node uses a preset fault diagnosis algorithm to analyze the sensitivity of the input data to electromagnetic interference. Based on the analysis results, the input data with a sensitivity exceeding a second preset threshold is marked as a key parameter susceptible to interference in the event description. The input data is the capacitor operating data input into the fault diagnosis algorithm.
[0083] B. Select the CRC checksum length based on the logging level. Logging levels include high, medium, and low. High logging level corresponds to a 32-bit CRC checksum, medium logging level corresponds to a 16-bit CRC checksum, and low logging level corresponds to an 8-bit CRC checksum.
[0084] C. Obtain the event log record based on the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters, and the selected CRC check code.
[0085] In step A, for the data collection start node, the phase-locked loop synchronization mechanism is started to calibrate the timestamp, and the timestamp accuracy reaches the microsecond level; for the filtering completion node, the mean square error of the data before and after filtering is calculated, and the mean square error is compared with the first preset threshold. When the mean square error exceeds the first preset threshold, an abnormal flag is added to the event type; for the fault judgment completion node, the preset fault judgment algorithm is used to analyze the sensitivity of the input data to electromagnetic interference. The analysis result is used to determine whether the sensitivity of the input data exceeds the second preset threshold. If it exceeds, the input data whose sensitivity exceeds the second preset threshold is marked as a key parameter susceptible to interference in the event description.
[0086] In step B, the logging level is used as the basis for selecting the CRC check code length. The logging level is divided into three levels: high, medium and low. The high logging level corresponds to a 32-bit CRC check code, the medium logging level corresponds to a 16-bit CRC check code, and the low logging level corresponds to an 8-bit CRC check code.
[0087] In step C, the calibrated timestamp, the event type including the abnormality flag, the event description including the key parameters, and the selected CRC check code are combined to form an event log record.
[0088] Specifically, in response to the problem of reduced traceability of the data processing process caused by electromagnetic interference in high-frequency transient fault scenarios in smart substations, the event log record generation method proposed in this application generates detailed event log records at key nodes in the data processing process, thereby enhancing the traceability of the data processing process. At the beginning of data acquisition, the phase-locked loop synchronization mechanism is started to ensure the microsecond accuracy of the timestamp, providing an accurate time reference for subsequent data analysis. After the filtering process is completed, the calculation of the mean square error and the comparison with the threshold can effectively detect data anomalies that may be introduced by the filtering process, and the anomalies are recorded in the event log, which helps to promptly discover and solve problems in the data preprocessing stage. When the fault judgment is completed, the sensitivity of the input data to electromagnetic interference is analyzed, and the sensitive parameters are marked in the event description to provide reference information on the impact of electromagnetic interference for fault analysis. In addition, by selecting CRC check codes of different lengths according to different log record levels, it is possible to balance data verification strength while taking into account resource consumption, achieving a balance between data reliability and resource utilization. The final event log record contains key information such as timestamp, event type, event description and CRC checksum, providing comprehensive and reliable data support for operation and maintenance personnel to conduct fault analysis and responsibility tracing.
[0089] In some specific embodiments, during the data processing of the capacitance measurement and control instrument, when the data acquisition start node is detected, the phase-locked loop synchronization mechanism is immediately activated, the system time is calibrated to the microsecond level, and an event log record containing a precise timestamp is generated. The event type is set to "data acquisition start" and the event description may include information such as "data acquisition started." The corresponding CRC checksum length is selected based on the preset logging level. When the filtering completion node is detected, the system calculates the mean square error of the data before and after filtering. If the mean square error exceeds a preset first threshold, an "abnormal" flag is added to the event type. For example, the event type can be set to "filtering completed - abnormal." The event description may include information such as "mean square error exceeds threshold" and the specific mean square error value. The CRC checksum length is selected based on the logging level. When a fault diagnosis completion node is detected, the fault diagnosis algorithm analyzes the sensitivity of the input data to electromagnetic interference. If the sensitivity of certain input data exceeds a second preset threshold, the data is marked as "critical parameters susceptible to interference" in the event description. For example, the event description may include information such as "Parameter X and Parameter Y are critical parameters susceptible to interference." The event type can be set to "Fault diagnosis completed," and the CRC checksum length is selected based on the logging level. Ultimately, these event log records, which contain timestamps, event types, event descriptions, and CRC checksums of corresponding lengths, are stored in local non-volatile memory in chronological order and can be remotely accessed and read through standard communication interfaces.
[0090] In some embodiments, the step of obtaining an event log record based on the calibrated timestamp, the event type including the abnormality flag, the event description including the key parameters, and the selected CRC check code includes:
[0091] Using a predefined binary format, a preliminary event log record is constructed by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum.
[0092] Based on RS code, the preliminary event log record is encoded with anti-interference technology to obtain the final event log record.
[0093] For constructing preliminary event log records, a binary format can be predefined that specifies the order and data type of timestamps, event types, event descriptions, and cyclic redundancy check codes in the data structure. For example, timestamps can be defined as 64-bit unsigned integers, event types can be defined as 8-bit enumeration types, event descriptions can be defined as strings of variable length, and the length of the cyclic redundancy check code is determined by the logging level, which can be 8 bits, 16 bits, or 32 bits. When combining this information, they can be arranged in the order of timestamp, event type, event description, and cyclic redundancy check code and written to a pre-allocated data buffer. In order to distinguish different data fields, preset delimiters, such as specific byte sequences, can be inserted between fields so that the data of each field can be accurately identified and extracted when the log records are subsequently parsed.
[0094] After obtaining the preliminary event log records, Reed-Solomon (RS) codes are introduced for encoding to enhance data anti-interference capabilities. Specifically, the RS code encoding parameters must first be determined, including the codeword length, information bit length, and error correction coefficient. The codeword length can be determined based on the length of the preliminary event log records, while the information bit length depends on the combined length of the timestamp, event type, and event description. The error correction coefficient is calculated from the codeword length and information bit length and determines the number of errors the RS code can correct. After determining the encoding parameters, the RS code generator polynomial must be generated, typically using mathematical operations based on Galois fields. The encoding process treats the timestamp, event type, and event description in the preliminary event log records as information bits, padding them with zeros to form the data sequence to be encoded. The data sequence is then RS-encoded using the generator polynomial. A linear feedback shift register and modulo-2 division are used to generate a certain number of check bits. The number of these check bits is equal to the number of zero padding bits. Finally, all check bits are appended to the information bits to form the final event log record containing timestamp, event type, event description and check bits.
[0095] Specifically, by combining the various components of the event log record in a predefined binary format, structured data integration is achieved, facilitating subsequent data processing and storage. The introduction of RS code for anti-interference coding provides a higher level of data protection based on the cyclic redundancy check code. The cyclic redundancy check code is mainly used to detect errors that occur during data transmission or storage, while the RS code can not only detect errors but also correct them within a certain range. As a result, even in environments with relatively harsh electromagnetic interference, the final event log record has stronger anti-interference capabilities, which can effectively reduce the bit error rate and ensure the integrity and accuracy of the event log record. This dual verification mechanism combines the error detection capability of the cyclic redundancy check code and the error correction capability of the RS code, and can more effectively deal with data interference problems in complex electromagnetic environments and improve the reliability of data processing.
[0096] In some specific embodiments, assuming a predefined binary format, the timestamp occupies 8 bytes, the event type occupies 1 byte, the event description length is variable, occupies a maximum of 255 bytes, and the cyclic redundancy check code is selected as 16 bits, occupying 2 bytes. When the filtering process is detected, the event type is marked as 0x02, the event description is recorded as "the mean square error after filtering exceeds the threshold", the calibrated timestamp is the current microsecond timestamp, and a 16-bit cyclic redundancy check code is calculated. These data are combined in a predefined order to form a preliminary event log record. Furthermore, the RS (255, 239) code is selected for anti-interference encoding, where the codeword length is 255 bytes and the information bit length is 239 bytes, which can correct up to 8 bytes of errors. The preliminary event log record is used as the information bit, padded with 16 bytes of zeros, and RS encoding is performed to generate 16 bytes of check bits. After appending to the information bits, the final event log record is obtained. In this way, the event log record can still maintain high reliability and integrity in harsh electromagnetic environments.
[0097] In some embodiments, the steps of constructing a preliminary event log record using a predefined binary format by combining a calibrated timestamp, an event type including an anomaly flag, an event description including key parameters, and a selected CRC checksum include:
[0098] Load the calibrated timestamp, event type including abnormality flag, event description including key parameters, and selected CRC check code into the corresponding data buffer respectively;
[0099] According to the predefined binary format, in the order of timestamp, event type, event description, and CRC check code, the data of each data buffer is read, the preset separator is inserted, and then written to the target storage area to finally form a preliminary event log record.
[0100] The process of constructing preliminary event log records implements structured and efficient data assembly. Log information components such as timestamps, event types, event descriptions, and CRC checksums are loaded into separate data buffers. This data block management method facilitates subsequent data assembly, improving data processing efficiency and maintainability. A predefined binary format is used, with timestamps, event types, event descriptions, and CRC checksums arranged in a fixed order. During data reading, data is read from each data buffer, and predefined delimiters are inserted between adjacent data blocks. Delimiters clearly delimit different data fields in the resulting binary data stream, which is crucial for subsequent data parsing and extraction. The complete data stream with delimiters is written to the target storage area, forming a preliminary event log record. By utilizing data buffers, predefined formats, fixed order, and delimiters, a structured, standardized, and easily parsable preliminary event log record is constructed, laying the foundation for subsequent anti-interference encoding and effective utilization of log data. The data buffer is used for data block management to improve efficiency; the predefined format and fixed order ensure the structuring and consistency of log records; the separator is used to clearly divide data fields to facilitate subsequent parsing.
[0101] Specifically, a predefined binary format is used to construct preliminary event log records, ensuring a standardized log data structure. Key information, including timestamp, event type, event description, and CRC checksum, is arranged in a predetermined order: timestamp first, followed by event type, event description, and finally CRC checksum. This fixed order makes log records predictable and facilitates subsequent data parsing. During data assembly, each component, namely the timestamp, event type, event description, and CRC checksum, is first loaded into its own data buffer. A data buffer can be thought of as a reserved storage area in memory for temporarily storing data segments awaiting processing. The use of data buffers allows for more independent and efficient management of each data segment. After data loading is complete, data is read from each data buffer in a predefined binary format and fixed order. Predefined delimiters are inserted between adjacent data blocks. Delimiters mark the boundaries between different data fields in a continuous binary data stream. For example, a specific byte sequence, such as "0xFF 0xFE," can be used as a delimiter. Finally, the complete data stream with delimiters is written to the target storage area, which can be a non-volatile storage medium such as flash memory or a hard drive. This completes the initial event log. This method creates a clearly structured and easy-to-parse log, providing strong support for subsequent log analysis and fault tracing.
[0102] In some specific embodiments, the process of constructing a preliminary event log record for capacitance measurement and control instrument data processing can be implemented as follows. First, assume that the timestamp is a 64-bit integer, the event type is an 8-bit enumeration type, the event description is a string with a maximum length of 256 bytes, and the CRC checksum is a 16-bit integer. Four data buffers are allocated in memory for these four data components: a timestamp buffer, an event type buffer, an event description buffer, and a CRC checksum buffer. When an event log record is constructed, the calibrated timestamp data is written to the timestamp buffer, the event type data is written to the event type buffer, the event description string is written to the event description buffer, and the calculated CRC checksum is written to the CRC checksum buffer. The predefined binary format is: timestamp (8 bytes) + delimiter (2 bytes) + event type (1 byte) + delimiter (2 bytes) + event description (variable length, maximum 256 bytes) + delimiter (2 bytes) + CRC checksum (2 bytes). The delimiter is the byte sequence "0xFF 0xFE". Following this format, data is read from each buffer sequentially, and delimiters are inserted. For example, 8 bytes of data are first read from the timestamp buffer, followed by "0xFF 0xFE". Next, 1 byte of data is read from the event type buffer, followed by "0xFF 0xFE". This continues until the data in the CRC checksum buffer is read and the last delimiter is inserted. Finally, the resulting binary data stream is written to a pre-allocated target storage area, such as a flash memory area. This flash memory area is used to store event log records. Through these steps, a structured preliminary event log record is constructed, providing the data foundation for subsequent anti-tampering encoding and remote access. By using a data buffer, predefined format, and delimiters, log record structuring and parsing efficiency are ensured.
[0103] In some embodiments, the steps of performing anti-interference encoding on the preliminary event log record based on the RS code to obtain the final event log record include:
[0104] Determine the encoding parameters of the RS code; the encoding parameters include codeword length, information bit length, and error correction capability coefficient; the codeword length is determined based on the length of the preliminary event log record, the information bit length is determined based on the sum of the timestamp, event type, and event description data length, and the error correction capability coefficient is calculated according to the following formula: ;in, is the error correction capability coefficient, is the codeword length, , is the order of the Galois Field, is the information bit length;
[0105] Generate a generating polynomial of the RS code according to the determined RS code encoding parameters;
[0106] Treat the timestamp, event type, and event description in the preliminary event log record as information bits and fill in the information bits zeros, forming the data sequence to be encoded;
[0107] Using the generating polynomial, the data sequence to be encoded is RS-encoded to obtain The number of check bits is the same as the number of zeros filled with the information bits;
[0108] After all check bits are appended to the information bits, the final event log record containing timestamp, event type, event description and check bits is formed.
[0109] Determining the encoding parameters lays the foundation for subsequent RS encoding, ensuring that the RS code can be configured based on the actual event log record. The codeword length is determined based on the length of the preliminary event log record, ensuring that the RS code can handle event log records of various lengths. The information bit length is determined based on the sum of the timestamp, event type, and event description data lengths, clarifying the effective data range for RS code encoding. The error correction coefficient is calculated based on the codeword length and information bit length, providing a theoretical basis for the error correction capability of the RS code. Generating the generator polynomial for the RS code is the core step of RS encoding. The generator polynomial is the mathematical foundation of RS encoding and determines the encoding and decoding characteristics of the RS code. The timestamp, event type, and event description in the preliminary event log record are treated as information bits, and are padded with multiple zeros to form the data sequence to be encoded. This is the data preparation stage of RS encoding and ensures that the RS code can protect the critical information in the event log record. Using the generator polynomial, the data sequence to be encoded is RS encoded to generate multiple check bits, a key step in RS encoding. RS encoding converts the original information bits into a codeword containing check bits, which are used for subsequent error detection and correction. The number of check bits matches the number of zeros padded to the information bits, ensuring the error correction capability of the RS code. After all check bits are appended to the information bits, a final event log record is formed, containing the timestamp, event type, event description, and check bits. The final event log record contains the original event information as well as the check information used for anti-interference, thereby improving the reliability of event logging in complex electromagnetic environments.
[0110] Specifically, by determining encoding parameters such as codeword length, information bit length, and error correction coefficient, RS codes can be flexibly configured for preliminary event log records of varying lengths. Generator polynomials, the mathematical foundation of RS coding, provide theoretical support for subsequent encoding and decoding processes. Timestamps, event types, and event descriptions are protected as information bits, ensuring that critical information in event log records is not easily lost or corrupted in harsh electromagnetic environments. The RS encoding process utilizes generator polynomials to process the data sequence to be encoded, generating check bits for error detection and correction. The addition of check bits enhances the event log record's robustness against interference and reduces the probability of data errors during transmission or storage. The resulting event log record, because it includes checksum information, maintains high reliability and integrity even in electromagnetic interference environments, ensuring traceability of the data processing process. This enables efficient and reliable RS code anti-interference encoding even in resource-constrained edge devices and complex electromagnetic environments, reducing the high bit error rates caused by data corruption due to electromagnetic interference.
[0111] In some specific embodiments, assuming the initial event log record length is 255 bytes, with the timestamp occupying 8 bytes, the event type occupying 2 bytes, and the event description occupying 200 bytes, the information bit length is 210 bytes. The codeword length is determined to be 255 bytes, and the error correction coefficient is calculated using the codeword length and the information bit length. Based on the determined encoding parameters, a generating polynomial for the RS (255, 210) code is generated. The timestamp, event type, and event description are considered information bits, and 45 zero bytes are padded after the information bits to form a 255-byte data sequence to be encoded. Using the generated RS code generating polynomial, the data sequence to be encoded is RS-encoded to obtain 45 check bytes. These 45 check bytes are appended to the 210-byte information bits to form a final 255-byte event log record. The final event log record contains the timestamp, event type, event description, and a 45-byte RS check code, improving data reliability in complex electromagnetic environments.
[0112] In some embodiments, the step of generating a generator polynomial of the RS code according to the determined RS code encoding parameters includes:
[0113] Initialize the Galois field according to the determined RS code encoding parameters;
[0114] Generate the generating polynomial of RS code based on Galois Field.
[0115] In this embodiment, initializing the Galois field can be implemented as follows: first, according to the RS code encoding parameters, the order of the Galois field is determined, and the order is usually a power of 2, such as 2 to the power of 8, that is, 256. Then, an irreducible polynomial on the binary field is selected, and the order of the irreducible polynomial is the same as the determined power. For example, when the order is 256, an irreducible polynomial of order 8 can be selected. The selection of irreducible polynomials is pre-set and can be selected according to application requirements and computing resources. Subsequently, based on the selected irreducible polynomials, the elements and operation rules of the Galois field are constructed, including addition and multiplication operations. The generating polynomial for generating the RS code can be implemented as follows: after completing the initialization of the Galois field, according to the error correction capability coefficient of the RS code, the roots of the generating polynomial are determined. The roots of the generating polynomial are elements in the Galois field, and continuous power elements of the Galois field are usually selected as roots. For example, assuming the error correction capability coefficient is , you can choose of Power, of Power, until of The power is the root, where It is the original element of the Galois Field. is the preset offset. Thus, the generating polynomial can be obtained by multiplying linear polynomials with these roots. Polynomial multiplication is performed in a Galois Field, ensuring that the coefficients of the generating polynomial are also elements of the Galois Field.
[0116] Specifically, based on the Galois Field, the generator polynomial of the RS code is generated by the following steps:
[0117] D1. Select primitive polynomial , the primitive polynomial is a polynomial of a specified order (for example, m order) and satisfies the Galois field All elements on can be represented by the roots of primitive polynomials;
[0118] D2. Based on the primitive polynomial, determine the continuous roots (i.e. the above 、 … ), the root is calculated by the primitive elements of the Galois field and the error correction capability coefficient;
[0119] D3. Based on the determination of continuous roots, the generating polynomial is obtained, which is specifically expressed as:
[0120] ;
[0121] in, For about The generating polynomial of is a formal variable, is the primitive element of the Galois Field, that is, the root of the primitive polynomial. is the preset offset, is the error correction capability coefficient.
[0122] It should be noted that in the generating polynomial of the RS code, is a formal variable that doesn't have a specific value. Instead, it serves as a placeholder in the polynomial to represent the different orders of the polynomial. In RS encoding, the coefficients of the polynomial are the actual values involved in the calculation, and these coefficients are taken from the Galois Field.
[0123] When calculating the generating polynomial, it is necessary to expand the above polynomial to obtain: ;in, 、 、 … are the coefficients of the polynomial, which are all elements in the Galois field.
[0124] In the RS encoding process, the data sequence to be encoded is represented as an information polynomial, and then the information polynomial is divided by the generator polynomial, and the remainder obtained is the check bit. It is still just a formal variable; what actually participates in the calculation are the coefficients of the polynomial.
[0125] Specifically, the steps for generating the generator polynomial of the RS code are designed to solve the problem of how to accurately and efficiently obtain the generator polynomial. By first initializing the Galois field, a mathematical foundation is provided for the subsequent generator polynomial, ensuring that all operations are performed within a predefined finite field, thus guaranteeing the mathematical correctness of the RS code. Subsequently, based on the Galois field, by selecting appropriate roots and multiplying the polynomials, a generator polynomial that meets the RS code encoding requirements is finally obtained. This step-by-step approach makes the process of generating the polynomial clearer and more standardized, and improves the reliability of the generating polynomial. Accurate and effective generating polynomials provide the necessary technical support for the subsequent RS encoding process, thereby improving the anti-interference ability of event logging.
[0126] In some specific implementations, for example, for an RS code with an error correction coefficient of 8, a Galois field of order 8 is first initialized. The process of initializing the Galois Field is: select the irreducible polynomial (In this polynomial, The highest power of is 8, with a coefficient of 1. The coefficients of the 4th, 3rd, and 2nd powers of x are 1. The coefficient of the constant term is 1. The coefficients of the remaining terms, namely the 7th, 6th, 5th, and 1st powers of x, are 0 and are not explicitly written in the polynomial. Based on this polynomial, a finite field of 256 elements is constructed and the addition and multiplication rules within the field are determined. Then, assuming the offset is 0, the roots of the generating polynomial are determined to be , ,…, The generating polynomial is calculated by Get. Polynomial multiplication in Completed within, and finally got the 16th order generating polynomial Thus, the process of generating polynomials is concretized and can be directly used in the subsequent RS encoding process to provide anti-interference capability for data verification information.
[0127] In some embodiments, the step of performing RS encoding on a data sequence to be encoded using a generator polynomial to obtain a plurality of check bits includes:
[0128] Inputting the generating polynomial and the data sequence to be encoded into a linear feedback shift register, and performing a modulo-2 division operation to obtain a remainder sequence; the linear feedback shift register is implemented based on a Galois field, and its initial state is set to all zeros;
[0129] The remainder sequence is bit-reversed to obtain multiple check bits.
[0130] The linear feedback shift register is configured to operate based on a Galois Field, ensuring the correct mathematical foundation of the RS encoding. The Galois Field is selected and configured based on the predetermined RS code parameters. The generator polynomial and the data sequence to be encoded are provided as input to the linear feedback shift register. The initial state of the linear feedback shift register is set to all zeros, ensuring a deterministic starting state for the encoding process. Modulo-2 division is performed in the linear feedback shift register, generating a remainder sequence. This remainder sequence directly reflects the parity information of the RS encoding. To adapt to a specific RS code standard or optimize the hardware implementation, the remainder sequence is then bit-reversed to produce the final multiple parity bits.
[0131] Specifically, during the RS encoding process, the generator polynomial and the data sequence to be encoded are first loaded into a linear feedback shift register. The registers and feedback paths within the linear feedback shift register are configured according to the Galois field operation rules. As the data sequence is shifted bit by bit into the linear feedback shift register, the register simultaneously performs a modulo-2 division operation. The result of the operation, i.e., the remainder sequence, is output after all data bits have been processed. As a preferred embodiment, a bit reversal operation is performed after the remainder sequence is output to generate a check bit that meets the requirements of a specific RS code format. For example, in a specific implementation of the linear feedback shift register, it can be constructed using an exclusive-OR gate and a shift register unit, and the connection method of the exclusive-OR gate and the number of shift register units are determined by the generator polynomial. The data sequence to be encoded can be input into the linear feedback shift register in a serial or parallel manner.
[0132] In some specific embodiments, consider an example of RS (255, 239) encoding applied to capacitance measurement and control instruments. The codeword length is set to 255 bytes, and the information bit length is 239 bytes, which can obtain 16 bytes of check bits. The generating polynomial is based on the Galois field. The linear feedback shift register (LFSR) consists of 16 8-bit registers and several XOR gates. The specific connection of the XOR gates is determined by the coefficients of the generating polynomial. The 239 bytes of data to be encoded are serially input into the LFSR byte by byte. After all data is input, the 16-byte remainder sequence stored in the LFSR is bit-reversed and output as the RS-encoded check bits. This is appended to the original information bits to form the final event log record containing the check information. This RS encoding process enhances the anti-interference capability of the event log record, ensuring reliable data transmission in complex electromagnetic environments.
[0133] Please refer to Figure 2 , Figure 2 In some embodiments of the present invention, a capacitance measurement and control instrument data processing device is provided. The capacitance measurement and control instrument data processing device is integrated into a back-end control device in the form of a computer program, and includes:
[0134] An acquisition module 100 is used to acquire capacitor operation data;
[0135] Monitoring module 200, used to monitor key nodes of the data processing process based on capacitor operation data; key nodes include data acquisition start node, filtering process completion node and fault judgment completion node;
[0136] The generation module 300 is used to generate corresponding event log records according to the preset log record level when a key node is monitored. The event log record includes a timestamp, event type, event description, and data verification information. The timestamp accuracy is microsecond level. The event type is used to identify the data processing stage. The event description is used to record the details of the processing steps. The data verification information includes a cyclic redundancy check (CRC) check code, and different log record levels correspond to different CRC check code lengths.
[0137] The storage module 400 is used to store event log records in a local non-volatile memory in chronological order, and provides a standard communication interface to support remote access and reading of event log records, and allows operation and maintenance personnel to remotely configure the logging level according to needs.
[0138] In some embodiments, the generation module 300 is configured to generate corresponding event log records according to a preset log record level when a key node is monitored, and executes:
[0139] A. Determine the current key nodes monitored and implement the following:
[0140] A1. If it is the data collection start node, the preset phase-locked loop synchronization mechanism is activated to calibrate the timestamp to ensure microsecond accuracy.
[0141] A2. If the filtering process is completed at the node, the mean square error of the data before and after filtering is calculated, and when the mean square error exceeds the first preset threshold, an abnormal flag is added to the event type;
[0142] A3. If the fault diagnosis is complete, the node uses a preset fault diagnosis algorithm to analyze the sensitivity of the input data to electromagnetic interference. Based on the analysis results, the input data with a sensitivity exceeding a second preset threshold is marked as a key parameter susceptible to interference in the event description. The input data is the capacitor operating data input into the fault diagnosis algorithm.
[0143] B. Select the CRC checksum length based on the logging level. Logging levels include high, medium, and low. High logging level corresponds to a 32-bit CRC checksum, medium logging level corresponds to a 16-bit CRC checksum, and low logging level corresponds to an 8-bit CRC checksum.
[0144] C. Obtain the event log record based on the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters, and the selected CRC check code.
[0145] In some embodiments, the generation module 300 performs the following when obtaining an event log record based on the calibrated timestamp, the event type including the abnormality flag, the event description including the key parameters, and the selected CRC check code:
[0146] Using a predefined binary format, a preliminary event log record is constructed by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum.
[0147] Based on RS code, the preliminary event log record is encoded with anti-interference technology to obtain the final event log record.
[0148] In some embodiments, the generation module 300 is configured to construct a preliminary event log record using a predefined binary format by combining a calibrated timestamp, an event type including an exception flag, an event description including key parameters, and a selected CRC checksum:
[0149] Load the calibrated timestamp, event type including abnormality flag, event description including key parameters, and selected CRC check code into the corresponding data buffer respectively;
[0150] According to the predefined binary format, in the order of timestamp, event type, event description, and CRC check code, the data of each data buffer is read, the preset separator is inserted, and then written to the target storage area to finally form a preliminary event log record.
[0151] In some embodiments, when the generating module 300 is used to perform anti-interference encoding on the preliminary event log record based on the RS code to obtain the final event log record, the generating module 300 performs the following steps:
[0152] Determine the encoding parameters of the RS code; the encoding parameters include codeword length, information bit length, and error correction capability coefficient; wherein the codeword length is determined based on the length of the preliminary event log record, the information bit length is determined based on the sum of the timestamp, event type, and event description data length, and the error correction capability coefficient is calculated based on the codeword length and information bit length;
[0153] Generate a generating polynomial of the RS code according to the determined RS code encoding parameters;
[0154] The timestamp, event type and event description in the preliminary event log record are regarded as information bits, and multiple zeros are filled after the information bits to form a data sequence to be encoded;
[0155] Using the generating polynomial, the data sequence to be encoded is RS-encoded to obtain multiple check bits; the number of check bits is the same as the number of zeros padded with the information bits;
[0156] After all check bits are appended to the information bits, the final event log record containing timestamp, event type, event description and check bits is formed.
[0157] In some embodiments, when the generating module 300 is used to generate a generator polynomial of the RS code according to the determined RS code encoding parameters, the generating module 300 performs:
[0158] Initialize the Galois field according to the determined RS code encoding parameters;
[0159] Generate the generating polynomial of RS code based on Galois Field.
[0160] In some embodiments, when the generating module 300 is used to perform RS encoding on a data sequence to be encoded using a generating polynomial to obtain multiple check bits, the following is executed:
[0161] Inputting the generating polynomial and the data sequence to be encoded into a linear feedback shift register, and performing a modulo-2 division operation to obtain a remainder sequence; the linear feedback shift register is implemented based on a Galois field, and its initial state is set to all zeros;
[0162] The remainder sequence is bit-reversed to obtain multiple check bits.
[0163] In this document, relational terms such as first and second, etc. are used merely to distinguish one entity or operation from another entity or operation, but do not necessarily require or imply any actual relationship or order between these entities or operations.
[0164] The foregoing description is merely an embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Those skilled in the art will readily appreciate that the present invention is susceptible to various modifications and variations. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention shall be included within the scope of protection of the present invention.
Claims
1. A capacitance measurement and control instrument data processing method, characterized in that: The following steps are involved: Obtain capacitor operation data; Monitoring key nodes of the data processing flow based on the capacitor operation data; The key nodes include a data collection start node, a filtering process completion node, and a fault judgment completion node; When the key node is monitored, a corresponding event log record is generated according to the preset log record level; the event log record includes a timestamp, event type, event description and data verification information; The timestamp accuracy is microseconds; the event type is used to identify the data processing stage; the event description is used to record the details of the processing steps; the data verification information includes a cyclic redundancy check (CRC) checksum, and different log record levels correspond to CRC checksums of different lengths; The event log records are stored in local non-volatile memory in chronological order, and a standard communication interface is provided to support remote access and reading of the event log records, and to allow operation and maintenance personnel to remotely configure the logging level as needed; When the key node is detected, the steps of generating a corresponding event log record according to a preset log record level include: A. Determine the current key nodes monitored and implement the following: A1. If it is the data collection start node, the preset phase-locked loop synchronization mechanism is activated to calibrate the timestamp to ensure microsecond accuracy. A2. If the filtering process is completed at the node, the mean square error of the data before and after filtering is calculated, and when the mean square error exceeds a first preset threshold, an abnormal flag is added to the event type; A3. If the fault diagnosis is complete, analyze the sensitivity of the input data to electromagnetic interference using a preset fault diagnosis algorithm. Based on the analysis results, mark the input data with a sensitivity exceeding a second preset threshold as a key parameter susceptible to interference in the event description. The input data is the capacitor operating data input to the fault diagnosis algorithm. B. Select the CRC check code length according to the logging level; the logging level includes high, medium and low. The high logging level corresponds to the selection of a 32-bit CRC check code, the medium logging level corresponds to the selection of a 16-bit CRC check code, and the low logging level corresponds to the selection of an 8-bit CRC check code; C. Obtain the event log record based on the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters, and the selected CRC check code; The steps of obtaining the event log record according to the calibrated timestamp, the event type including the abnormality flag, the event description including the key parameters and the selected CRC check code include: Using a predefined binary format, a preliminary event log record is constructed by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum. Based on the RS code, the preliminary event log record is subjected to anti-interference encoding to obtain a final event log record.
2. The capacitance measurement and control instrument data processing method according to claim 1, characterized in that: The steps to construct a preliminary event log record using a predefined binary format by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum include: Load the calibrated timestamp, event type including abnormality flag, event description including key parameters, and selected CRC check code into the corresponding data buffer respectively; According to the predefined binary format, in the order of timestamp, event type, event description, and CRC check code, the data of each data buffer is read, the preset separator is inserted, and then written to the target storage area to finally form a preliminary event log record.
3. A capacitance measurement and control instrument data processing device, characterized in that: include: An acquisition module is used to obtain capacitor operation data; A monitoring module, configured to monitor key nodes of a data processing flow based on the capacitor operation data; The key nodes include a data collection start node, a filtering process completion node, and a fault judgment completion node; A generation module is used to generate a corresponding event log record according to a preset log record level when the key node is monitored; the event log record includes a timestamp, event type, event description and data verification information; The timestamp accuracy is microseconds; the event type is used to identify the data processing stage; the event description is used to record the details of the processing steps; the data verification information includes a cyclic redundancy check (CRC) checksum, and different log record levels correspond to CRC checksums of different lengths; A storage module is used to store the event log records in a local non-volatile memory in chronological order, and provide a standard communication interface to support remote access and reading of the event log records, and allow operation and maintenance personnel to remotely configure the logging level as needed; The generation module is used to generate corresponding event log records according to the preset log record level when monitoring the key node: A. Determine the current key nodes monitored and implement the following: A1. If it is the data collection start node, the preset phase-locked loop synchronization mechanism is activated to calibrate the timestamp to ensure microsecond accuracy. A2. If the filtering process is completed at the node, the mean square error of the data before and after filtering is calculated, and when the mean square error exceeds a first preset threshold, an abnormal flag is added to the event type; A3. If the fault diagnosis is complete, analyze the sensitivity of the input data to electromagnetic interference using a preset fault diagnosis algorithm. Based on the analysis results, mark the input data with a sensitivity exceeding a second preset threshold as a key parameter susceptible to interference in the event description. The input data is the capacitor operating data input to the fault diagnosis algorithm. B. Select the CRC check code length according to the logging level; the logging level includes high, medium and low. The high logging level corresponds to the selection of a 32-bit CRC check code, the medium logging level corresponds to the selection of a 16-bit CRC check code, and the low logging level corresponds to the selection of an 8-bit CRC check code; C. Obtain the event log record based on the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters, and the selected CRC check code; The generation module is executed when obtaining the event log record based on the calibrated timestamp, the event type including the abnormal flag, the event description including the key parameters and the selected CRC check code: Using a predefined binary format, a preliminary event log record is constructed by combining a calibrated timestamp, an event type with an exception flag, an event description with key parameters, and a selected CRC checksum. Based on the RS code, the preliminary event log record is subjected to anti-interference encoding to obtain a final event log record.
4. The capacitance measurement and control instrument data processing device according to claim 3, characterized in that: The generation module is executed when it is used to construct a preliminary event log record using a predefined binary format by combining a calibrated timestamp, an event type with anomaly flags, an event description with key parameters, and a selected CRC checksum: Load the calibrated timestamp, event type including abnormality flag, event description including key parameters, and selected CRC check code into the corresponding data buffer respectively; According to the predefined binary format, in the order of timestamp, event type, event description, and CRC check code, the data of each data buffer is read, the preset separator is inserted, and then written to the target storage area to finally form a preliminary event log record.
Citation Information
Patent Citations
Dynamic backtracking method for data processing
CN107562768A