A method and device for metering security self-detection, analysis and step compensation

By implementing anomaly detection and power compensation methods in the AC data acquisition system, the problem of inaccurate data caused by metering anomalies in the power distribution system was solved, achieving rapid response and accurate power data acquisition, and reducing negative line losses.

CN116073515BActive Publication Date: 2026-05-22BEIJING SMARTCHIP MICROELECTRONICS TECHNOLOGY CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJING SMARTCHIP MICROELECTRONICS TECHNOLOGY CO LTD
Filing Date
2023-01-16
Publication Date
2026-05-22

AI Technical Summary

Technical Problem

In the existing power distribution system, abnormal operation of distribution equipment in the transformer area leads to inaccurate or lost power data collection, serious negative line loss, and the existing compensation methods are imperfect, affecting the stability and reliability of power data collection.

Method used

A self-testing method for metering safety is provided, which determines metering anomalies by judging whether the data transmission frames and preset conditions of the AC acquisition system are abnormal, and reports the anomaly information; at the same time, it determines the power compensation value based on the duration of the anomaly and the power compensation rules.

Benefits of technology

It enables rapid detection and processing of metering anomalies, improves the reliability and accuracy of data transmission, alleviates negative line loss problems, and enhances the stability and reliability of power data acquisition.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116073515B_ABST
    Figure CN116073515B_ABST
Patent Text Reader

Abstract

The embodiment of the present application provides a kind of metering security self-detection, analysis, ladder compensation method and device, belong to the field of measurement.The method comprises: whether the power grid basic data transmission data frame transmitted by the data acquisition device of alternating current acquisition system to the data processing device of alternating current acquisition system is abnormal or whether preset power grid basic acquisition data value meets the first preset condition to judge whether the metering abnormality determination mechanism needs to be started;In the case where the metering abnormality determination mechanism needs to be started, it is judged whether the metering abnormality event occurs in the alternating current acquisition system;And in the case where the metering abnormality event occurs, the abnormality related information about the metering abnormality event is reported, wherein the abnormality related information comprises at least one of the following: start time, end time and metering abnormality type.Thereby, the detection and processing of the abnormality of the metering function of alternating current acquisition system itself are realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of metrology, and more specifically to a method and apparatus for self-detection, analysis, and tiered compensation of metrological safety. Background Technology

[0002] With the development of distribution Internet of Things (IoT) technology, the "integration" and "smartification" of distribution areas are constantly advancing, and the distribution system is continuously innovating. Through the deep integration of new digital technologies and traditional power systems, based on power system data collection, and through the interconnection and interoperability between distribution equipment, a new digital power system that is "observable, describable, and controllable" is being constructed.

[0003] In power distribution networks, data acquisition is a cornerstone of intelligent power system construction and is indispensable. Numerous devices in power distribution networks possess data acquisition and metering capabilities, and the installation scenarios of these devices vary significantly across different regions. Currently, there are issues where malfunctions in distribution equipment lead to inaccurate or lost data, such as electricity consumption. Over time, this results in negative line losses in distribution area electricity statistics, affecting the stability and reliability of power data acquisition. Existing technical solutions lack effective mechanisms for detecting and handling malfunctions in the metering functions of the distribution-side devices. Furthermore, current methods for compensating for negative line losses are inadequate, typically relying on a single average value for a specific time period or manually set reference values, lacking scientific rigor and rationality. Summary of the Invention

[0004] The purpose of this invention is to provide a method and apparatus for self-detection, analysis, and tiered compensation of metrological safety, which can solve or at least partially solve the above-mentioned problems.

[0005] To achieve the above objectives, one aspect of the present invention provides a method for detecting metering anomalies in an AC data acquisition system. The method includes: determining whether a metering anomaly determination mechanism needs to be activated based on whether a power grid basic data transmission frame transmitted from the data acquisition device of the AC data acquisition system to the data processing device of the AC data acquisition system is abnormal or whether a preset power grid basic data acquisition value meets a first preset condition; if the metering anomaly determination mechanism needs to be activated, determining whether the AC data acquisition system has experienced a metering anomaly event; and if the metering anomaly event has occurred, reporting anomaly-related information concerning the metering anomaly event, wherein the anomaly-related information includes at least one of the following: start time, end time, and metering anomaly type.

[0006] Optionally, when determining whether to activate the metering anomaly determination mechanism based on whether the power grid basic data transmission data frame is checked for anomalies, the determination of whether the AC acquisition system has experienced the metering anomaly event includes determining based on at least one of the following: the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, whether the power grid basic data transmission data frame meets the second preset condition, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0007] Optionally, determining whether the metering anomaly event has occurred in the AC data acquisition system includes determining whether the metering anomaly event has occurred based on whether any of the following conditions are met: The data acquisition device's reset pin is not reset and the data acquisition device's operating voltage does not fluctuate, but the data acquisition device's reset pin is controlled to perform a reset operation, and the data acquisition device's device number or version information is incorrect; The data acquisition device's reset pin is not reset and the data acquisition device's operating voltage does not fluctuate, the data acquisition device's operating voltage is lower than or equal to a first threshold value, the data processing device experiences a soft reset, and the data acquisition device's device number or version information is incorrect; The data acquisition device's reset pin is not reset and the data acquisition device's operating voltage does not fluctuate, the data acquisition device's operating voltage is higher than the first threshold value, the power grid basic data transmission data frame meets the second preset condition, the data acquisition device's reset pin is controlled to perform a reset operation, and the data acquisition device's device number or version information is incorrect. The following conditions must be met: the data acquisition device's reset pin is not reset and the data acquisition device's operating voltage has not fluctuated; the data acquisition device's operating voltage is higher than the first threshold; the power grid basic data transmission frame does not meet the second preset condition; the data processing device's operating voltage is higher than the second threshold or the data processing device's operating voltage has not fluctuated; the data acquisition device's reset pin is controlled to perform a reset operation; and the data acquisition device's device number or version information is incorrect. Alternatively, the following conditions must be met: the data acquisition device's reset pin is not reset and the data acquisition device's operating voltage has not fluctuated; the data acquisition device's operating voltage is higher than the first threshold; the power grid basic data transmission frame does not meet the second preset condition; the data processing device's operating voltage is higher than the second threshold or the data processing device's operating voltage has not fluctuated; the data processing device has undergone a soft reset; and the data acquisition device's device number or version information is incorrect.

[0008] Optionally, when determining whether to activate the metering anomaly determination mechanism based on whether the preset power grid basic data acquisition value meets the first preset condition, the determination of whether the AC acquisition system has experienced the metering anomaly event includes determining based on at least one of the following: the operating status data of the data acquisition device, the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0009] Optionally, determining whether the metering anomaly event has occurred in the AC data acquisition system includes determining whether the metering anomaly event has occurred based on whether any of the following conditions are met: the operating status data is abnormal, the reset pin of the data acquisition device is controlled to perform a reset operation, and the device number or version information of the data acquisition device is incorrect; the operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device does not fluctuate, and the reset pin of the data acquisition device is controlled to perform a reset operation; the operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device does not fluctuate, the operating voltage of the data acquisition device is lower than or equal to a first threshold value, and the data processing device undergoes a soft reset; The following conditions are considered as follows: The operating status data is normal; the device number or version information of the data acquisition device is incorrect; the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated; and the reset pin of the data acquisition device is controlled to perform a reset operation. Alternatively, the following conditions are also considered as follows: The operating status data is normal; the device number or version information of the data acquisition device is incorrect; the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated; and the data processing device has undergone a soft reset.

[0010] Furthermore, another aspect of the present invention provides a method for determining the power compensation value for a metering anomaly event in an AC data acquisition system. The method includes: detecting whether the metering anomaly event has occurred in the AC data acquisition system, as described above; determining the abnormal duration of the metering anomaly event if it has occurred; and determining the power compensation value for the abnormal period during which the metering anomaly event occurred based on the abnormal duration and a preset power compensation rule.

[0011] Optionally, the preset power compensation rule is related to the relationship between the abnormal duration and the preset power statistics period.

[0012] Optionally, the preset power compensation rule includes: when the abnormal duration is less than or equal to a preset power statistics period, determining the power compensation value based on the power value of the most recent power statistics record point, the preset power statistics period, and the abnormal duration, wherein the most recent power statistics record point is the power statistics record point closest to the start time of the metering anomaly event; and / or when the abnormal duration is greater than the preset power statistics period, determining the power compensation value based on comparing the power data deviation of each power statistics record point with a preset power data deviation threshold, wherein the comparison power statistics record points include a preset number of power statistics record points before the start time, and the power data deviation of any power statistics record point is the deviation between the power value corresponding to the power statistics record point on the day the metering anomaly event occurred and the power value corresponding to the preset historical time.

[0013] Optionally, the preset power compensation rule is also related to the southbound device data statistics function of the AC acquisition system.

[0014] Optionally, when the preset power compensation rule includes determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold when the abnormal duration is greater than the preset power statistical period, the condition for determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold is that the abnormal duration is greater than the preset power statistical period but there is no southbound device data statistical function or the southbound device data statistical function is abnormal; the preset power compensation rule further includes: when the abnormal duration is greater than the preset power statistical period and there is a normal southbound device data statistical function, determining the power compensation value based on the power value of southbound devices within a preset statistical range during the abnormal period.

[0015] Optionally, determining the power compensation value based on the relationship between the power data deviation of each power statistical recording point in the comparison power data recording points and a preset power data deviation threshold includes: when the power data deviation of each power statistical recording point in the comparison power data recording points is less than or equal to the preset power data deviation threshold, determining the power compensation value according to the power value of the abnormal power statistical recording point on the current day and the power value corresponding to the preset historical time, wherein the abnormal power statistical recording point includes the power statistical recording point in the abnormal period; and / or the power data of at least one of the power statistical recording points in the comparison power statistical recording points. If the deviation is greater than the preset power data deviation threshold, and the power data deviation of the most recent power statistics record point is less than or equal to the preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistics record point on the current day and the power value at the preset historical time; and / or if the power data deviation of the most recent power statistics record point is greater than the preset power data deviation threshold, the power compensation value is determined based on the power value of the most recent power statistics record point on the current day and the power value at the preset historical time, and the power value of the abnormal power statistics record point at the preset historical time.

[0016] Accordingly, another aspect of the present invention provides an apparatus for detecting metering anomalies in an AC data acquisition system. The apparatus includes: a startup module, configured to determine whether a metering anomaly determination mechanism needs to be activated based on whether a power grid basic data transmission frame transmitted from the data acquisition device of the AC data acquisition system to the data processing device of the AC data acquisition system is abnormal or whether a preset power grid basic data acquisition value meets a first preset condition; a determination module, configured to determine whether a metering anomaly event has occurred in the AC data acquisition system if the metering anomaly determination mechanism needs to be activated; and a reporting module, configured to report anomaly-related information concerning the metering anomaly event if the metering anomaly event occurs, wherein the anomaly-related information includes at least one of the following: start time, end time, and metering anomaly type.

[0017] Optionally, when determining whether to activate the metering anomaly determination mechanism based on whether the power grid basic data transmission data frame is checked for anomalies, the determination module determines whether the AC acquisition system has experienced the metering anomaly event by judging based on at least one of the following: the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, whether the power grid basic data transmission data frame meets the second preset condition, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0018] Optionally, the determination module determines whether the metering anomaly event has occurred in the AC data acquisition system by determining whether the metering anomaly event has occurred based on whether any of the following conditions are met: The data acquisition device's reset pin is not reset and the data acquisition device's operating voltage does not fluctuate, but the data acquisition device's reset pin is controlled to perform a reset operation, and the data acquisition device's device number or version information is incorrect; The data acquisition device's reset pin is not reset and the data acquisition device's operating voltage does not fluctuate, the data acquisition device's operating voltage is lower than or equal to a first threshold value, the data processing device experiences a soft reset, and the data acquisition device's device number or version information is incorrect; The data acquisition device's reset pin is not reset and the data acquisition device's operating voltage does not fluctuate, the data acquisition device's operating voltage is higher than the first threshold value, the power grid basic data transmission data frame meets the second preset condition, the data acquisition device's reset pin is controlled to perform a reset operation, and the data acquisition device's... The following conditions must be met: the device number or version information is incorrect; the data acquisition device's reset pin is in an unreset state and the data acquisition device's operating voltage has not fluctuated; the data acquisition device's operating voltage is higher than the first threshold value; the power grid basic data transmission frame does not meet the second preset condition; the data processing device's operating voltage is higher than the second threshold value or the data processing device's operating voltage has not fluctuated; the data acquisition device's reset pin is controlled to perform a reset operation; and the data acquisition device's device number or version information is incorrect. Alternatively, the following conditions must be met: the data acquisition device's reset pin is in an unreset state and the data acquisition device's operating voltage has not fluctuated; the data acquisition device's operating voltage is higher than the first threshold value; the power grid basic data transmission frame does not meet the second preset condition; the data processing device's operating voltage is higher than the second threshold value or the data processing device's operating voltage has not fluctuated; the data processing device has undergone a soft reset; and the data acquisition device's device number or version information is incorrect.

[0019] Optionally, when determining whether to activate the metering anomaly determination mechanism based on whether the preset power grid basic data acquisition value meets the first preset condition, the determination module determines whether the metering anomaly event has occurred in the AC acquisition system by judging based on at least one of the following: the operating status data of the data acquisition device, the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0020] Optionally, the determination module determines whether the metering anomaly event has occurred in the AC acquisition system by determining whether the metering anomaly event has occurred based on whether any of the following conditions are met: the operating status data is abnormal, the reset pin of the data acquisition device is controlled to perform a reset operation, and the device number or version information of the data acquisition device is incorrect; the operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device does not fluctuate, and the reset pin of the data acquisition device is controlled to perform a reset operation; the operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device does not fluctuate, the operating voltage of the data acquisition device is lower than or equal to a first threshold value, and the data processing device has undergone a soft reset; The following conditions are met: the operating status data is normal; the device number or version information of the data acquisition device is incorrect; the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated; and the reset pin of the data acquisition device is controlled to perform a reset operation; and the following conditions are also met: the operating status data is normal; the device number or version information of the data acquisition device is incorrect; the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated; and the data processing device has undergone a soft reset.

[0021] Accordingly, another aspect of the present invention provides an apparatus for determining the power compensation value of a metering anomaly event in an AC data acquisition system. The apparatus includes: a detection module for detecting whether the AC data acquisition system has experienced a metering anomaly event according to the method described above; an anomaly duration determination module for determining the anomaly duration of the metering anomaly event if it occurs; and a power compensation value determination module for determining a power compensation value for the anomaly period during which the metering anomaly event occurs, based on the anomaly duration and a preset power compensation rule.

[0022] Optionally, the preset power compensation rule is related to the relationship between the abnormal duration and the preset power statistics period.

[0023] Optionally, the preset power compensation rule includes: when the abnormal duration is less than or equal to a preset power statistics period, determining the power compensation value based on the power value of the most recent power statistics record point, the preset power statistics period, and the abnormal duration, wherein the most recent power statistics record point is the power statistics record point closest to the start time of the metering anomaly event; and / or when the abnormal duration is greater than the preset power statistics period, determining the power compensation value based on comparing the power data deviation of each power statistics record point with a preset power data deviation threshold, wherein the comparison power statistics record points include a preset number of power statistics record points before the start time, and the power data deviation of any power statistics record point is the deviation between the power value corresponding to the power statistics record point on the day the metering anomaly event occurred and the power value corresponding to the preset historical time.

[0024] Optionally, the preset power compensation rule is also related to the southbound device data statistics function of the AC acquisition system.

[0025] Optionally, when the preset power compensation rule includes determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold when the abnormal duration is greater than the preset power statistical period, the condition for determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold is that the abnormal duration is greater than the preset power statistical period but there is no southbound device data statistical function or the southbound device data statistical function is abnormal; the preset power compensation rule further includes: when the abnormal duration is greater than the preset power statistical period and there is a normal southbound device data statistical function, determining the power compensation value based on the power value of southbound devices within a preset statistical range during the abnormal period.

[0026] Optionally, determining the power compensation value based on the relationship between the power data deviation of each power statistical recording point in the comparison power data recording points and a preset power data deviation threshold includes: when the power data deviation of each power statistical recording point in the comparison power data recording points is less than or equal to the preset power data deviation threshold, determining the power compensation value according to the power value of the abnormal power statistical recording point on the current day and the power value corresponding to the preset historical time, wherein the abnormal power statistical recording point includes the power statistical recording point in the abnormal period; and / or the power data of at least one of the power statistical recording points in the comparison power statistical recording points. If the deviation is greater than the preset power data deviation threshold, and the power data deviation of the most recent power statistics record point is less than or equal to the preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistics record point on the current day and the power value at the preset historical time; and / or if the power data deviation of the most recent power statistics record point is greater than the preset power data deviation threshold, the power compensation value is determined based on the power value of the most recent power statistics record point on the current day and the power value at the preset historical time, and the power value of the abnormal power statistics record point at the preset historical time.

[0027] Furthermore, another aspect of the present invention provides a data processing apparatus, which includes: the apparatus described above for detecting metering abnormal events in an AC data acquisition system; or the method described above for determining the power compensation value of a metering abnormal event in an AC data acquisition system.

[0028] In addition, another aspect of the present invention provides an AC acquisition system, which includes the data processing device described above.

[0029] Furthermore, another aspect of the present invention provides a machine-readable storage medium storing instructions that cause a machine to perform the above-described method.

[0030] In addition, another aspect of the present invention provides a processor for running a program, wherein the program is run to perform the above-described method.

[0031] Through the above technical solution, the system determines whether to activate a metering anomaly detection mechanism based on whether the power grid basic data transmission frame transmitted from the data acquisition device of the AC acquisition system to the data processing device of the AC acquisition system is abnormal or whether the preset power grid basic acquisition data value meets the first preset condition. If the metering anomaly detection mechanism needs to be activated, it determines whether a metering anomaly event has occurred in the AC acquisition system. If a metering anomaly event has occurred, it reports relevant information about the anomaly event. This achieves the detection and handling of anomalies in the metering function of the AC acquisition system itself by determining whether to activate the metering anomaly detection mechanism and whether a metering anomaly event has occurred, and by processing the reported anomaly information when an anomaly event occurs. Furthermore, based on the power grid basic... Whether the data frame of the data transmission is checked for abnormality or whether the preset basic power grid data value meets the first preset condition determines whether the metering anomaly judgment mechanism needs to be activated. This can determine whether the data transmission process is normal or whether the functional module is operating normally. If the metering anomaly judgment mechanism needs to be activated, then it can be determined whether a metering anomaly event has occurred. This can ensure the reliability of data transmission between modules within the AC acquisition system or the correctness of the operating status of each module. It can also ensure the reliability of transmitting large amounts of data in high real-time, and can quickly identify whether the metering anomaly judgment mechanism needs to be activated and respond quickly. By determining whether the data transmission process is normal or whether the functional module is operating normally, it can ensure the smooth progress and accuracy of the judgment for metering anomaly events.

[0032] Other features and advantages of the embodiments of the present invention will be described in detail in the following detailed description section. Attached Figure Description

[0033] The accompanying drawings are provided to further illustrate embodiments of the present invention and form part of the specification. They are used together with the following detailed description to explain the embodiments of the present invention, but do not constitute a limitation thereof. In the drawings:

[0034] Figure 1 This is a flowchart of a method for detecting metering anomaly events in an AC data acquisition system according to an embodiment of the present invention;

[0035] Figure 2 This is a schematic diagram of the structure of an AC data acquisition system provided in another embodiment of the present invention;

[0036] Figure 3 This is a logical schematic diagram of a method for handling metering abnormal events in an AC data acquisition system according to another embodiment of the present invention;

[0037] Figure 4 This is a logic diagram illustrating whether a metering anomaly event has occurred in an AC data acquisition system, provided in another embodiment of the present invention.

[0038] Figure 5 This is a logic diagram illustrating whether a metering anomaly event has occurred in an AC data acquisition system, provided in another embodiment of the present invention; and

[0039] Figure 6 This is a structural block diagram of a device for detecting metering abnormal events in an AC data acquisition system, provided in another embodiment of the present invention.

[0040] Explanation of reference numerals in the attached figures

[0041] 1. Startup module 2. Judgment module

[0042] 3 Reporting Module Detailed Implementation

[0043] The specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are for illustration and explanation only and are not intended to limit the scope of the present invention.

[0044] One aspect of this invention provides a method for detecting metering anomalies in an AC data acquisition system. Optionally, the AC data acquisition system may be an intelligent power distribution data acquisition device.

[0045] Figure 1 This is a flowchart of a method for detecting metering anomalies in an AC data acquisition system according to an embodiment of the present invention. Figure 1 As shown, the method includes the following.

[0046] In step S10, it is determined whether the metering anomaly determination mechanism needs to be activated. The metering anomaly determination mechanism refers to a method for determining whether a metering anomaly event has occurred; determining whether to activate the mechanism is equivalent to determining whether a metering anomaly event needs to be determined. Specifically, the activation of the metering anomaly determination mechanism can be determined based on whether the power grid basic data transmission frame transmitted from the data acquisition device of the AC acquisition system to the data processing device of the AC acquisition system is abnormal, or whether the preset power grid basic data acquisition value meets a first preset condition. The power grid basic data transmission frame can be voltage or current, etc.; the data acquisition device is the device in the AC acquisition system that acquires the power grid basic data transmission frame; the data processing device is the device in the AC acquisition system that processes the power grid basic data transmission frame acquired by the data acquisition device. Furthermore, the preset power grid basic data acquisition value can be a voltage value or a current value. Optionally, the first preset condition can be that the difference between the preset power grid basic data acquisition values ​​of two consecutive packets reaches a preset difference threshold. For example, the preset difference threshold can be 10%, 20%, etc., and the preset difference threshold can be determined according to specific circumstances. If it is necessary to activate the measurement anomaly determination mechanism, proceed to step S11; if it is not necessary to activate the measurement anomaly determination mechanism, proceed to step S10.

[0047] In step S11, it is determined whether a metering anomaly event has occurred in the AC data acquisition system. The AC data acquisition system can be any device with AC data acquisition capabilities; a metering anomaly event is an event in which the metering function of the AC data acquisition system itself malfunctions. If a metering anomaly event occurs, step S12 is executed; otherwise, step S11 is repeated.

[0048] In step S12, in the event of a metering anomaly, relevant information about the anomaly is reported. This information includes at least one of the following: start time, end time, and metering anomaly type. The metering anomaly type is a self-detection type, indicating that the AC data acquisition system itself has a metering function malfunction. For example, the report can be sent to the master station or the corresponding northbound equipment, enabling the master station or northbound equipment to monitor and handle metering anomalies in the AC data acquisition system. Reporting to the master station alleviates the inaccurate and untimely perception of metering anomalies in the AC data acquisition system by the distribution master station. It also mitigates the significant manpower and time required for analysis, troubleshooting, and data governance issues caused by such anomalies, which are difficult, complex, and challenging to pinpoint. This meets the accuracy requirements of the distribution IoT for metering data.

[0049] Through the above technical solution, the system determines whether to activate a metering anomaly detection mechanism based on whether the power grid basic data transmission frame transmitted from the data acquisition device of the AC acquisition system to the data processing device of the AC acquisition system is abnormal or whether the preset power grid basic acquisition data value meets the first preset condition. If the metering anomaly detection mechanism needs to be activated, it determines whether a metering anomaly event has occurred in the AC acquisition system. If a metering anomaly event has occurred, it reports relevant information about the anomaly event. This achieves the detection and handling of anomalies in the metering function of the AC acquisition system itself by determining whether to activate the metering anomaly detection mechanism and whether a metering anomaly event has occurred, and by processing the reported anomaly information when an anomaly event occurs. Furthermore, based on the power grid basic... Whether the data frame of the data transmission is checked for abnormality or whether the preset basic power grid data value meets the first preset condition determines whether the metering anomaly judgment mechanism needs to be activated. This can determine whether the data transmission process is normal or whether the functional module is operating normally. If the metering anomaly judgment mechanism needs to be activated, then it can be determined whether a metering anomaly event has occurred. This can ensure the reliability of data transmission between modules within the AC acquisition system or the correctness of the operating status of each module. It can also ensure the reliability of transmitting large amounts of data in high real-time, and can quickly identify whether the metering anomaly judgment mechanism needs to be activated and respond quickly. By determining whether the data transmission process is normal or whether the functional module is operating normally, it can ensure the smooth progress and accuracy of the judgment for metering anomaly events.

[0050] Optionally, in this embodiment of the invention, when determining whether to activate the metering anomaly determination mechanism based on whether the power grid basic data transmission data frame is checked for anomalies, determining whether a metering anomaly event has occurred in the AC acquisition system includes determining based on at least one of the following: the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, whether the power grid basic data transmission data frame meets the second preset condition, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0051] Optionally, in this embodiment of the invention, when determining whether to activate the metering anomaly determination mechanism based on whether the power grid basic data transmission data frame is abnormal, determining whether a metering anomaly event has occurred in the AC acquisition system includes determining whether a metering anomaly event has occurred based on whether any of the following conditions are met: The data acquisition device's reset pin is not in a reset state, the data acquisition device's operating voltage has not fluctuated but the data acquisition device's reset pin is controlled to perform a reset operation, or the data acquisition device's device number or version information is incorrect. Specifically, it may be that the data acquisition device's reset pin is controlled to perform a reset operation after the data acquisition device's reset pin is not in a reset state and the data acquisition device's operating voltage has not fluctuated. The conditions are met: the data acquisition device's reset pin is not in a reset state and the data acquisition device's operating voltage has not fluctuated; the data acquisition device's operating voltage is lower than or equal to a first threshold value; the data processing device experiences a soft reset; or the data acquisition device's device number or version information is incorrect. The following conditions must be met for the data acquisition device to meet the following criteria: the reset pin of the data acquisition device is not reset and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than a first threshold; the power grid basic data transmission frame meets a second preset condition; the reset pin of the data acquisition device is controlled to perform a reset operation; and the device number or version information of the data acquisition device is incorrect. The second preset condition can be determined according to specific circumstances. For example, it could be that all bytes in the power grid basic data transmission frame are identical, and all bytes in at least two consecutive power grid basic data transmission frames are identical. Specifically, the second preset condition could be that the data frame is an all-0x00 data frame or an all-0xFF data frame, and this is true for three consecutive frames. Alternatively, the following conditions must be met for the data acquisition device to meet the following criteria: the reset pin of the data acquisition device is not reset and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than a first threshold; the power grid basic data transmission frame does not meet the second preset condition; the operating voltage of the data processing device is higher than a second threshold or the operating voltage of the data processing device has not fluctuated; the reset pin of the data acquisition device is controlled to perform a reset operation; and the device number or version information of the data acquisition device is incorrect. Specifically, the reset pin of the data acquisition device may be controlled to perform a reset operation after the operating voltage of the data processing device is higher than the second threshold or the operating voltage of the data processing device has not fluctuated. The conditions for this reset operation include: the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold; the data frame of the power grid basic data transmission does not meet the second preset condition; the operating voltage of the data processing device is not higher than the second threshold or the operating voltage of the data processing device has not fluctuated; the data processing device has undergone a soft reset; and the device number or version information of the data acquisition device is incorrect.If any one of the above conditions is met, a measurement anomaly event is determined to have occurred; if none of the above conditions are met, a measurement anomaly event is determined to have not occurred.

[0052] Optionally, in this embodiment of the invention, when determining whether to activate the metering anomaly determination mechanism based on whether the preset power grid basic data acquisition value meets the first preset condition, determining whether a metering anomaly event has occurred in the AC data acquisition system includes determining based on at least one of the following: the operating status data of the data acquisition device, the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device. The operating status data can be obtained from a register.

[0053] Optionally, in this embodiment of the invention, determining whether a metering anomaly event has occurred in the AC data acquisition system includes determining whether a metering anomaly event has occurred based on whether any of the following conditions are met: Abnormal operating status data, the reset pin of the data acquisition device being controlled to perform a reset operation, and an error in the device number or version information of the data acquisition device. Specifically, the reset pin of the data acquisition device may be controlled to perform a reset operation after determining that the operating status data is abnormal. Normal operating status data, an error in the device number or version information of the data acquisition device, failure to meet the conditions that the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device has not fluctuated, and the reset pin of the data acquisition device is controlled to perform a reset operation. Specifically, the reset pin of the data acquisition device may be controlled to perform a reset operation after determining that the conditions that the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device has not fluctuated are met. Normal operating status data, an error in the device number or version information of the data acquisition device, a condition that the reset pin state of the data acquisition device is not reset and the operating voltage of the data acquisition device has not fluctuated, the operating voltage of the data acquisition device is lower than or equal to a first threshold value, and a soft reset of the data processing device. The following conditions are considered valid criteria for a metering anomaly: Normal operating status data, incorrect device number or version information of the data acquisition device, the data acquisition device's reset pin is in an unreset state and its operating voltage has not fluctuated, the data acquisition device's operating voltage is higher than a first threshold, the data processing device's operating voltage is higher than a second threshold or its operating voltage has not fluctuated, and the data acquisition device's reset pin is controlled to perform a reset operation. Specifically, the reset pin of the data acquisition device may be controlled to perform a reset operation after determining that the data processing device's operating voltage is higher than the second threshold or its operating voltage has not fluctuated. Alternatively, the following conditions may not be met: Normal operating status data, incorrect device number or version information of the data acquisition device, the data acquisition device's reset pin is in an unreset state and its operating voltage has not fluctuated, the data acquisition device's operating voltage is higher than a first threshold, the data processing device's operating voltage is higher than the second threshold or its operating voltage has not fluctuated, and the data processing device has undergone a soft reset. If any one of these conditions is met, a metering anomaly event is determined to have occurred; if none of these conditions are met, a metering anomaly event is determined to have occurred.

[0054] Furthermore, another aspect of the present invention provides a method for determining the power compensation value for a metering anomaly event in an AC data acquisition system. The method includes the following: detecting whether a metering anomaly event has occurred in the AC data acquisition system according to the method for detecting metering anomalies in the above embodiments; and, if a metering anomaly event has occurred, determining the abnormal duration of the metering anomaly event. The abnormal duration of the metering anomaly event refers to the time interval between the start and end times of the metering anomaly event, and is determined based on the time difference between the start and end times of the metering anomaly event. Optionally, in the embodiments of the present invention, the determination of whether the metering anomaly event has ended can be based on the following: Specifically, the AC data acquisition system includes a data acquisition device and a data processing device. When a metering anomaly event is determined to have occurred, the data processing device continuously reads the device number or version information of the data acquisition device. When the device number or version information read consecutively for a preset number of times (e.g., three consecutive times) is correct, the metering anomaly event is determined to have ended. Based on the abnormal duration and a preset power compensation rule, a power compensation value for the abnormal period of the metering anomaly event is determined. The abnormal period refers to the time from the start time of the metering anomaly event to the end time of the metering anomaly event. Optionally, in the embodiments of the present invention, the determined power compensation value can also be reported.

[0055] Through the above technical solution, in the event of a metering anomaly in the AC data acquisition system, the power compensation value for the abnormal period is determined based on the duration of the anomaly and preset power compensation rules. This enables the determination of power compensation values ​​to address anomalies. By determining power compensation values ​​to compensate for power losses, the problem of inaccurate or lost power and related data due to operational anomalies is mitigated, negative line losses in long-term accumulated power statistics for distribution substations are reduced, and the stability and reliability of power data acquisition in distribution substations are improved. Furthermore, by determining power compensation values ​​to compensate for power losses, more accurate compensation can be made for lost power, allowing on-site equipment to respond to metering anomalies reasonably and effectively. Determining the power compensation value for the abnormal period based on the duration of the anomaly and preset power compensation rules, rather than simply using an average value for a single period for all-time compensation or manually setting a reference value, improves the scientific and rational nature of the compensation.

[0056] Optionally, in this embodiment of the invention, the preset power compensation rule can be related to the relationship between the abnormal duration and the preset power statistics cycle. The preset power compensation rule can be set based on this relationship. The preset power statistics cycle is the time interval for calculating power consumption, such as 5 minutes, 10 minutes, etc., depending on the specific situation. Furthermore, when calculating power consumption every preset power statistics cycle, the time point for calculating the power consumption is called the power statistics recording point. Within a 24-hour day, starting from 0:00, power consumption is calculated every preset power statistics cycle. After one day's calculation is completed, a new day begins again from 0:00, with a 24-hour cycle as one period. Therefore, with a fixed preset power statistics cycle, the power statistics recording point is fixed, but the same power statistics recording point can correspond to different dates, and different power consumption values ​​may correspond to the same power statistics recording point on different dates. For example, the preset power consumption statistics cycle is 5 minutes, with a power consumption statistics recording point every 5 minutes, such as 0:05, 0:10, 0:15, 0:20... Power consumption statistics are performed at 0:05, 0:10, 0:15, 0:20... every day. For example, on October 24th, power consumption statistics are performed at 0:05, 0:10, 0:15, 0:20...; on October 25th, power consumption statistics are performed at 0:05, 0:10, 0:15, 0:20...

[0057] Specifically, when setting preset power compensation rules based on the relationship between the duration of the anomaly and the preset power consumption statistics period, the preset power compensation rules may include the following: When the duration of the anomaly is less than or equal to the preset power consumption statistics period, the power compensation value is determined based on the power consumption value of the most recent power consumption statistics record point, the preset power consumption statistics period, and the duration of the anomaly. The most recent power consumption statistics record point is the power consumption statistics record point closest to the start time of the metering anomaly event, or, in other words, the power consumption statistics record point within one preset power consumption statistics period from the start time of the metering anomaly event. Specifically, the power compensation value is calculated according to the following formula: ΔE=(E 最近电量统计记录点 / T)*Δt, where ΔE is the power compensation value, E 最近电量统计记录点The power consumption value is the most recent power consumption record point, Δt is the duration of the anomaly, and T is the preset power consumption statistics period. And / or, if the duration of the anomaly exceeds the preset power consumption statistics period, a power consumption compensation value is determined according to a stepped prediction algorithm. Specifically, the power consumption compensation value is determined based on the relationship between the power consumption data deviation of each power consumption record point and a preset power consumption data deviation threshold. The comparison power consumption record points include a preset number of power consumption record points before the start time. The power consumption data deviation of any power consumption record point is the deviation between the power consumption value corresponding to that power consumption record point on the day the metering anomaly event occurred and the power consumption value corresponding to that point at a preset historical time. Optionally, the preset number of power consumption record points can be consecutive or discontinuous. Furthermore, the preset value can be determined according to specific circumstances. Additionally, the preset historical time can be determined according to specific circumstances. For example, it could be the previous week, or the previous two weeks, or the previous three weeks, etc. For example, if the power consumption statistics record point is 13:15, and the day is Tuesday, October 25th, and the preset historical time is the previous week, the power consumption value at the power consumption statistics record point 13:15 on Tuesday, October 25th is the power consumption value corresponding to that day; the power consumption statistics record point 13:15 on Tuesday of the previous week is the power consumption value corresponding to the preset historical time.

[0058] Furthermore, the electricity consumption value corresponding to a preset historical time for a power consumption statistics recording point can be either the actual electricity consumption value obtained from statistical analysis or the electricity consumption value obtained after compensation in the event of a metering anomaly. Additionally, for any power consumption statistics recording point, the power consumption data deviation is the absolute value of the difference between the electricity consumption value corresponding to that recording point on the day of the metering anomaly and the electricity consumption value corresponding to that point at the preset historical time, divided by the electricity consumption value corresponding to that recording point on the day of the metering anomaly. Optionally, the preset power consumption data deviation threshold can be determined according to specific circumstances, for example, it could be 1%, 2%, etc.

[0059] Optionally, in this embodiment of the invention, the preset power compensation rule is also related to the southbound device data statistics function of the AC acquisition system. Specifically, it is further divided based on whether the AC acquisition system has a southbound device data statistics function and whether the southbound device data statistics function is abnormal when it does have such a function.

[0060] Optionally, in this embodiment of the invention, when the preset power compensation rule includes determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and a preset power data deviation threshold when the abnormal duration is greater than the preset power statistical period, the condition for determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold is that the abnormal duration is greater than the preset power statistical period but there is no southbound device data statistical function or the southbound device data statistical function is abnormal; the preset power compensation rule also includes: when the abnormal duration is greater than the preset power statistical period and there is a normal southbound device data statistical function, determining the power compensation value based on the power value of southbound devices within a preset statistical range during the abnormal period. Wherein, the preset statistical range is a pre-set control range of the AC acquisition system. Specifically, the power values ​​of southbound devices within the preset statistical range during the abnormal period are accumulated, and the accumulated power value is the power compensation value for the abnormal period.

[0061] Optionally, in this embodiment of the invention, determining the power compensation value based on the relationship between the power data deviation of each power statistical recording point in the power statistical recording points and a preset power data deviation threshold may include the following: When the power data deviation of each power statistical recording point in the power statistical recording points is less than or equal to the preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistical recording point on the current day and the power value at a preset historical time. The abnormal power statistical recording points include those in an abnormal time period. Specifically, for each power statistical recording point in the abnormal power statistical recording points, the absolute value of the difference between the power value of that power statistical recording point on the day the metering anomaly event occurred and the power value at the preset historical time is calculated. The absolute values ​​of the differences corresponding to each power statistical recording point in the abnormal power statistical recording points are summed to obtain the power compensation value for the abnormal time period. Furthermore, for abnormal power consumption statistics recording points, for example, if the preset power consumption statistics period is 5 minutes and the abnormal period is from 13:03 to 13:18 on October 25th, then the abnormal power consumption statistics recording points include 13:05, 13:10, and 13:15. And / or, if the power consumption data deviation of at least one of the power consumption statistics recording points is greater than a preset power consumption data deviation threshold, and if the power consumption data deviation of the most recent power consumption statistics recording point is less than or equal to the preset power consumption data deviation threshold, a power consumption compensation value is determined based on the power consumption value of the abnormal power consumption statistics recording point on the current day and the power consumption value corresponding to a preset historical time. Specifically, see the above content; and / or, if the power consumption data deviation of the most recent power consumption statistics recording point is greater than the preset power consumption data deviation threshold, a power consumption compensation value is determined based on the power consumption value of the most recent power consumption statistics recording point on the current day and the power consumption value corresponding to a preset historical time, as well as the power consumption value of the abnormal power consumption statistics recording point corresponding to a preset historical time. Optionally, the power compensation value is determined based on the ratio of the power consumption value of the most recent power consumption record point on the current day to the power consumption value at a preset historical time, and the power consumption value of abnormal power consumption record points at a preset historical time. Specifically, the power compensation value is calculated according to the following formula. Where ΔE is the power compensation value, t Start T is the earliest power consumption record point among the abnormal power consumption record points. end Let i be the latest power consumption statistics record point among the abnormal power consumption statistics record points, and E be the power consumption statistics record point. li E represents the electricity consumption value at point i within a preset historical time period. o最近电量统计记录点 E represents the current battery level corresponding to the most recent battery statistics record point. l最近电量统计记录点 This refers to the battery level at the most recent battery statistics point within a preset historical time period.

[0062] In this embodiment of the invention, detecting metering anomalies in the AC data acquisition system and determining the power compensation value for these anomalies are both processes for handling metering anomalies in the AC data acquisition system. The following is a combination of... Figures 2 to 4 This invention provides an exemplary description of the logic for handling metering anomalies in an AC data acquisition system, as provided in this embodiment, to illustrate the detection of metering anomalies and the determination of power compensation values. This embodiment proposes a method for monitoring, analyzing, and compensating for metering safety. When the AC data acquisition system on the distribution side experiences a metering function anomaly, it can identify the anomaly through its real-time self-detection function, record the time period of the anomaly, and report it to the main station. Simultaneously, the AC data acquisition system analyzes the power consumption for the corresponding period of the previous week, the power consumption curve before the anomaly on the current day, and the data collected from south-facing equipment within the acquisition range of the AC data acquisition system in the affected area. Based on the corresponding algorithm, it accurately compensates for the power consumption during the anomaly period to the greatest extent possible, thereby solving the problem of power loss caused by the AC data acquisition system's own anomaly. The metering safety monitoring, analysis, and compensation method proposed in this embodiment monitors the metering status of the distribution AC data acquisition system in real time and captures anomalies, enabling responses and compensation based on the anomalies, achieving the effect of reasonably responding to metering anomalies and greatly reducing power loss. The technical solution provided in this embodiment can be used on AC data acquisition systems with acquisition functions in distribution networks. Optionally, the AC data acquisition system includes a metering chip and a main control MCU, such as Figure 2 As shown, the AC data acquisition system primarily relies on a metering chip to collect basic power grid data frames such as voltage and current from external inputs. These raw data are then transmitted to the main control MCU of the AC data acquisition system for relevant data processing and applications, such as metering anomaly detection and / or calculation of power compensation values. In this embodiment, the data acquisition device is the metering chip, and the data processing device is the main control MCU. Furthermore, the AC data acquisition system may include southbound devices, such as… Figure 2 As shown, this function can be customized depending on the specific device application; for example, it may be an optional function such as a carrier / 485 / 4G module.

[0063] In this embodiment of the invention, the architecture of the AC acquisition system can be referred to Figure 2 As shown, for how to achieve metrological safety monitoring, analysis, and compensation in an AC data acquisition system, you can refer to... Figure 3As shown. First, the main control MCU performs real-time self-detection of the metering chip and its own status to determine if there is a metering anomaly, that is, to determine if a metering anomaly event has occurred in the AC data acquisition system. If a metering anomaly exists, the occurrence of the metering anomaly event is recorded, along with the type of metering anomaly and the start time of the metering anomaly event, and the recorded information is reported to the northbound device. Furthermore, in this embodiment of the invention, a metering anomaly event can also be determined to have occurred if a metering anomaly is detected and continues for the specified time. For example, if a metering anomaly is detected and has lasted for 3 seconds, a metering anomaly event is determined to have occurred. To determine if the metering anomaly has ended, specifically, in the case of a metering anomaly, the main control MCU continuously reads the device number or version information of the metering chip. If the device number or version information read three times consecutively is correct, the metering anomaly is determined to have ended. When the metering anomaly ends, the end time of the metering anomaly event is recorded, and the relationship between the duration of the anomaly event and the preset power consumption statistics period of 5 minutes is determined. The length of the anomaly duration corresponds to different compensation schemes. The compensation value is also affected by whether the AC data acquisition system itself has southbound device data statistics functions such as carrier wave, 485, or 4G. If the duration of the anomaly is less than or equal to 5 minutes, electricity compensation is applied to the abnormal period based on the electricity consumption recorded within the 5 minutes prior to the anomaly. If the duration of the anomaly is greater than 5 minutes, and if southbound equipment data statistics are available, the electricity compensation value for the abnormal period can be obtained from the southbound equipment. Specifically, meter readings are performed on the southbound equipment within the control range to calculate the electricity compensation value for the abnormal period. If southbound equipment data statistics are not available, the electricity compensation value is calculated using a tiered prediction algorithm. Specifically, the electricity consumption for the abnormal period is predicted using a tiered prediction algorithm, and the electricity compensation value for the abnormal period is calculated. Afterward, the end of the metering anomaly, its end time, the abnormal period, and the electricity compensation value are reported to the northbound equipment.

[0064] The above-mentioned methods for determining self-detection metering anomalies and for compensating for power anomalies will now be explained.

[0065] (1) Method for determining self-detection measurement anomalies

[0066] Depend on Figure 2 As can be seen, in an AC data acquisition system, the metering chip collects data frames of the externally input power grid basic data transmission, and the main control MCU processes and applies the data collected by the metering chip. Therefore, to ensure the safe operation of this AC data acquisition system, the operating status of the main control MCU, the metering chip, and the system itself should be monitored to determine whether an abnormal metering event has occurred. The self-detection metering anomaly determination method for AC data acquisition systems provided in this embodiment of the invention monitors its operating status, as detailed below. Figure 4 or Figure 5As shown. Among them, Figure 4 The content shown indicates whether to determine whether a metering anomaly event has occurred based on whether the power grid basic data transmission frame transmitted from the metering chip to the main control MCU has an anomaly. Figure 5 The content shown determines whether a metering anomaly event has occurred based on whether the basic power grid data values ​​meet a first preset condition. The first preset condition is that the difference between two consecutive sets of basic power grid data values ​​reaches 10%.

[0067] Figure 4 The content shown can be understood by referring to the following instructions. Figure 4 It is understood that the first step is to verify whether the power grid basic data transmission frame transmitted from the metering chip to the main control MCU is abnormal. When the verification of the power grid basic data transmission frame transmitted from the metering chip to the main control MCU is abnormal, the four judgment conditions ①, ③, the power grid basic data transmission frame meeting the second preset condition, and ④ are judged in order of priority. If an abnormality occurs, the corresponding judgment and processing are performed in sequence according to the content described in the embodiment of the present invention. It should be noted that in the embodiment of the present invention, it is not limited to judging in the order of ①, ③, the power grid basic data transmission frame meeting the second preset condition, and ④.

[0068] First, step ① is evaluated, meaning the main control MCU checks whether the metering chip's reset pin is in the correct state (not reset) and whether the metering chip's operating voltage has not fluctuated. In other words, the main control MCU checks whether the metering chip's reset pin is in a reset state or whether the metering chip's operating voltage has fluctuated. If step ① is incorrect, failing to meet the requirements of a correct reset pin state and no voltage fluctuation, then step ② is executed. In step ②, the main control MCU resets the metering chip's reset pin, and then executes step ⑧. In step ⑧, the main control MCU reads the metering chip's device number or version information and checks for errors. If an error exists, step ⑨ is executed, stopping the metering operation and determining that a metering self-detection anomaly event has occurred; if no error exists, it is determined that no self-detection anomaly event has occurred. Optionally, in step ⑧, the device number or version information of the metering chip may be read continuously for a preset number of times (e.g., three times in a row) to determine whether the device number or version information of the metering chip read each time is correct; if the device number or version information read once is incorrect, it is determined that a metering self-detection abnormal event has been generated; if the device number or version information read for the preset number of times is correct, it is determined that no self-detection abnormal event has been generated.

[0069] If step ① determines there are no abnormalities, and the metering chip's reset pin state is correct and the metering chip's operating voltage has not fluctuated, then step ③ is performed. This involves the main control MCU checking if the metering chip's operating voltage is correct, specifically whether it exceeds the first threshold. If the metering chip's operating voltage is not higher than the first threshold, step ⑩ is executed. In step ⑩, the metering chip records the corresponding cumulative number of abnormalities and reads the main control MCU's soft reset flag. This means accumulating the number of abnormalities where the metering chip's operating voltage is not higher than the first threshold and reading the main control MCU's soft reset flag. Then, step ⑥ is executed to determine whether a soft reset has occurred based on the main control MCU's soft reset flag. Specifically, this is determined by whether the soft reset flag is set to 1. If it is set to 1, a soft reset is considered to have occurred; otherwise, no soft reset has occurred. If no soft reset has occurred, step ⑦ is executed, performing a soft reset and then re-entering step ③. If a soft reset has occurred, step ⑧ is executed. In step ⑦, a soft reset operation is performed. Before the reset, the soft reset flag is set to 1, and the number of resets is accumulated.

[0070] If step ③ is correct, meaning the operating voltage of the metering chip is higher than the first threshold, determine whether the power grid basic data transmission frame meets the second preset condition. The second preset condition is that the data frame is either all 0x00 or all 0xFF, and this occurs for three consecutive frames. If the power grid basic data transmission frame meets the second preset condition, proceed to step ②. If the power grid basic data transmission frame does not meet the second preset condition, proceed to step ④, which checks whether the main control MCU's own operating voltage is correct (i.e., whether the main control MCU's operating voltage is higher than the second threshold; if it is higher, the operating voltage is correct; if it is lower, the operating voltage is incorrect) or whether the main control MCU's operating voltage has not fluctuated. If neither the main control MCU's operating voltage is correct nor has its operating voltage fluctuated, proceed to step ⑤. In step ⑤, the main control MCU generates its corresponding cumulative number of abnormalities, records them, and reads the main control MCU's soft reset flag. This means accumulating the number of abnormalities where the main control MCU's operating voltage is not higher than the second threshold and reading the main control MCU's soft reset flag. Subsequently, following the steps in step 10, steps 6, 7, and 8 are executed and judged.

[0071] If step ④ is correct and the main control MCU's operating voltage is correct or has not fluctuated, it proves that the abnormal data frame transmission of the power grid basic data transmission from the metering chip to the main control MCU is not caused by steps ①, ③, or ④. To eliminate other possible interference, the metering chip is reset, and the device number or version information of the metering chip is read to check the communication status, i.e., steps ② and ⑧ are executed. If there are no errors, it is determined that there is abnormal jitter and no self-detection abnormal event is recorded, which means that no metering abnormal event has occurred; if there is an abnormality, it is determined that a self-detection abnormality has occurred, which means that a metering abnormal event has occurred.

[0072] Figure 5 The content shown can be understood by referring to the following instructions. Figure 5 It can be seen that the first step is to determine whether the preset power grid basic data acquisition value meets the first preset condition. When the preset power grid basic data acquisition value meets the first preset condition, the five judgment conditions of chip operating status data abnormality, ⑧, ①, ③, and ④ are judged in order of priority. If the conditions are met, the corresponding judgment and processing are performed in sequence according to the content described in the embodiment of the present invention. It should be noted that in the embodiment of the present invention, it is not limited to judging in the order of chip operating status data abnormality, ⑧, ①, ③, and ④.

[0073] First, the chip's operating status data is read from the status register of the metering chip to determine if the data is abnormal. If the data is abnormal, step ② is executed. In step ②, the main control MCU resets the reset pin of the metering chip, and then executes step ⑧. In step ⑧, the main control MCU reads the device number or version information of the metering chip to determine if there is an error. If an error exists, step ⑨ is executed to stop the metering operation, indicating that a metering self-detection abnormality event has occurred; if no error exists, it is determined that no self-detection abnormality event has occurred. Optionally, in step ⑧, the device number or version information of the metering chip may be read continuously for a preset number of times (e.g., three times) to determine if the device number or version information read each time is correct; if the device number or version information read once is incorrect, it is determined that a metering self-detection abnormality event has occurred; if the device number or version information read in the preset number of times is correct, it is determined that no self-detection abnormality event has occurred.

[0074] If the chip's operating status data is normal, proceed to step ⑧. In step ⑧, the main control MCU reads the device number or version information of the metering chip and determines whether there is an error in the device number or version information. If no error is found, the process ends. If an error is found, proceed to step ①, which checks whether the metering chip's reset pin is in a correct state (not reset) and whether the metering chip's operating voltage has not fluctuated. In other words, the main control MCU checks whether the metering chip's reset pin is in a reset state or whether the metering chip's operating voltage has fluctuated. If step ① is abnormal, and the metering chip's reset pin is not in a correct state and the metering chip's operating voltage has not fluctuated (i.e., the metering chip's reset pin is in a reset state or the metering chip's operating voltage has fluctuated), proceed to step ②. In step ②, the main control MCU resets the metering chip's reset pin, and then proceeds to step ⑧. In step ⑧, the main control MCU reads the metering chip's device number or version information and determines whether there is an error in the device number or version information. If an error is found, proceed to step 9 to stop the metering operation and determine that a metering self-detection abnormal event has occurred; if no error is found, determine that no self-detection abnormal event has occurred.

[0075] If step ① determines there are no abnormalities, and the metering chip's reset pin state is correct and the metering chip's operating voltage has not fluctuated, then step ③ is performed. This involves the main control MCU checking if the metering chip's operating voltage is correct, specifically whether it exceeds the first threshold. If the metering chip's operating voltage is not higher than the first threshold, step ⑩ is executed. In step ⑩, the metering chip records the corresponding cumulative number of abnormalities and reads the main control MCU's soft reset flag. This means accumulating the number of abnormalities where the metering chip's operating voltage is not higher than the first threshold and reading the main control MCU's soft reset flag. Then, step ⑥ is executed to determine whether a soft reset has occurred based on the main control MCU's soft reset flag. Specifically, this is determined by whether the soft reset flag is set to 1. If it is set to 1, a soft reset is considered to have occurred; otherwise, no soft reset has occurred. If no soft reset has occurred, step ⑦ is executed, performing a soft reset and then re-entering step ③. If a soft reset has occurred, step ⑧ is executed. In step ⑧, the main control MCU reads the device number or version information of the metering chip and determines whether there is an error in the device number or version information. If an error exists, step ⑨ is executed to stop the metering operation and determine that a metering self-detection abnormal event has occurred; if no error exists, it is determined that no self-detection abnormal event has occurred. In step ⑦, a soft reset operation is performed. Before the reset, the soft reset flag is set to 1, and the number of resets is accumulated.

[0076] If step ③ is correct, meaning the operating voltage of the metering chip is higher than the first threshold, then proceed to step ④, which checks whether the main control MCU's own operating voltage is correct (i.e., whether the main control MCU's operating voltage is higher than the second threshold; if it is higher, the operating voltage is considered correct; if it is lower, the operating voltage is considered incorrect) or whether the main control MCU's operating voltage has not fluctuated. If neither the main control MCU's operating voltage is correct nor has fluctuated, then proceed to step ⑤. In step ⑤, the main control MCU generates and records the corresponding cumulative number of abnormalities and reads the main control MCU's soft reset flag. This means accumulating the number of abnormalities where the main control MCU's operating voltage is not higher than the second threshold and reading the main control MCU's soft reset flag. Subsequently, referring to the subsequent operations of step ⑩, steps ⑥, ⑦, and ⑧ are executed and judged.

[0077] If step ④ is correct and the main control MCU's operating voltage is correct or has not fluctuated, it proves that the abnormal data frame transmission of the power grid basic data transmission from the metering chip to the main control MCU is not caused by steps ①, ③, or ④. To eliminate other possible interference, the metering chip is reset, and the device number or version information of the metering chip is read to check the communication status, i.e., steps ② and ⑧ are executed. If there are no errors, it is determined that there is abnormal jitter and no self-detection abnormal event is recorded, which means that no metering abnormal event has occurred; if there is an abnormality, it is determined that a self-detection abnormality has occurred, which means that a metering abnormal event has occurred.

[0078] (2) Segmented compensation method and corresponding algorithm

[0079] The battery level is recorded at fixed intervals, such as every 5 minutes, forming a battery level record point. The method is explained below using 5 minutes as an example.

[0080] ① The duration of the abnormality is no more than 5 minutes.

[0081] If the duration of the anomaly is no more than 5 minutes, compensation for the anomaly period is made based on the electricity consumption records from the electricity consumption points within 5 minutes prior to the start time of the metering anomaly, as shown in the following formula: ΔE=(E o5 / T)*Δt, where ΔE is the power compensation value, E o5 The power consumption value is the power consumption value of the power consumption statistics record point within 5 minutes before the start time (the power consumption value of the most recent power consumption statistics record point), T is the preset power consumption statistics period of 5 minutes, and △t is the abnormal duration.

[0082] ② The abnormal duration is greater than 5 minutes

[0083] When the duration of the anomaly exceeds 5 minutes, it is necessary to differentiate between different equipment application scenarios and determine which compensation method to use based on whether the AC acquisition system where the metering anomaly event occurred has southbound equipment data statistics functions (carrier, 485, 4G modules, etc.).

[0084] ★ Possesses southbound equipment data statistics function and the southbound equipment data statistics function is normal.

[0085] If the AC acquisition system has a southbound device data statistics function, it will capture the power values ​​of all southbound devices within the preset statistical range of the AC acquisition system during the abnormal period and synthesize them (that is, sum them up). The synthesized power value will be used as the power compensation value of the AC acquisition system for the abnormal period.

[0086] ★The southbound equipment data statistics function is not available or is malfunctioning.

[0087] If the AC data acquisition system does not have the function of southbound equipment data statistics or the southbound equipment data statistics function is abnormal, then the power consumption compensation for abnormal periods will be performed according to the step prediction algorithm. The power consumption step prediction algorithm is explained below.

[0088] Every day, a power consumption statistics record point is generated every 5 minutes. The power consumption value is recorded for each record point, forming a power consumption compensation curve. This results in a power consumption compensation curve of 288 points (taking 5 minutes as an example) every day. Every week, a complete power consumption statistics report is generated (including 7 power consumption compensation curves). The weekly power consumption statistics report serves as the basis for compensation for metering anomalies in the following week. The AC data acquisition system needs to store the complete power consumption records for the week preceding the day of the metering anomaly (the current anomaly date). Furthermore, based on the previous week's power consumption statistics, the power consumption values ​​for the next week's records can be optimized based on power consumption data deviations. This allows for greater optimization and better compensation for metering anomalies. Specifically, the weekly power consumption statistics are optimized as follows: At the beginning of the next week, for any power consumption statistics record point, the current power consumption value at that record point is compared with the corresponding power consumption value on the same day of the previous week. If the electricity consumption data deviation is less than or equal to 1%, the average of the current electricity consumption value at the electricity consumption record point and the corresponding electricity consumption value on the same day last week is calculated, and this average value is recorded as the current electricity consumption value for that electricity consumption record point. If the deviation is greater than 1%, the current electricity consumption value at the electricity consumption record point is replaced with the corresponding electricity consumption value on the same day last week. Optionally, different methods for generating electricity consumption compensation curves are used depending on whether a metering anomaly event occurs on a particular day. For each day, two electricity consumption compensation curves are generated: one is the electricity consumption compensation curve corresponding to the actual electricity consumption value, and the other is the electricity consumption compensation curve obtained through the deviation calculation above. If no metering anomaly event occurs on a given day, the electricity consumption compensation curve corresponding to the actual electricity consumption value is discarded, and the electricity consumption compensation curve obtained through the deviation calculation above is retained for later use. If a metering anomaly event occurs on a given day, the compensated electricity consumption value of the electricity consumption record point in the abnormal period is replaced with the actual electricity consumption value in the electricity consumption compensation curve corresponding to the actual electricity consumption value. After replacement, the deviation calculation above is performed based on the electricity consumption compensation curve corresponding to the actual electricity consumption value to obtain an electricity consumption compensation curve, which is used as the electricity consumption compensation curve for the day in which the metering anomaly event occurred, for later use. For details on how to determine the compensated electricity value of the electricity statistics record point during abnormal periods, please refer to the relevant content described in the embodiments of this invention.

[0089] If the duration of the anomaly is greater than 5 minutes, the electricity values ​​of the 12 consecutive electricity statistics recording points (number of points recorded in 1 hour) before the start time of the metering anomaly event on the day the metering anomaly event occurred will be compared with the electricity values ​​of the same day in the previous week. The electricity data deviation of these 12 electricity statistics recording points will be calculated, and the electricity data deviation of the 12 electricity statistics recording points will be compared with 1%.

[0090] When the deviation of electricity data at all electricity statistics points is less than 1%, the electricity value on the electricity compensation curve for the same day of the previous week is used to compensate for the electricity consumption during the abnormal period. Specifically, for each electricity statistics point in the abnormal electricity statistics points, the absolute value of the difference between the electricity value corresponding to the day the metering anomaly occurred and the corresponding electricity value on the electricity compensation curve for the same day of the previous week is calculated. The absolute values ​​of the differences corresponding to each electricity statistics point in the abnormal electricity statistics points are summed to obtain the electricity compensation value for the abnormal period. For each electricity statistics point in the abnormal electricity statistics points, the electricity value corresponding to the same electricity compensation curve of the previous week is replaced with the current corresponding actual electricity value.

[0091] If the electricity data deviation at one or more electricity statistics points exceeds 1%, the electricity data deviation at the nearest electricity statistics point (within 5 minutes of the start time before the start time of the metering anomaly) is calculated and compared to 1%. If the electricity data deviation is less than 1%, the electricity value on the electricity compensation curve of the previous week is used to compensate for the electricity consumption during the abnormal period. For details, please refer to the above explanation. If the electricity data deviation exceeds 1%, the deviation ratio between the electricity value of the nearest electricity statistics point before the start time of the metering anomaly on the day the anomaly occurred and the electricity value of the same day of the previous week is calculated. Based on the electricity compensation curve of the same day of the previous week, this ratio is applied to the electricity values ​​of all electricity statistics points within the abnormal period to obtain the final electricity compensation value for the abnormal period. Specifically, the electricity compensation value is calculated according to the following formula: Where △E is the power compensation value, T start With T end These are the earliest and latest electricity consumption statistics record points during the abnormal period, respectively, where i is the electricity consumption statistics record point and E is the latest. li Let E be the electricity value corresponding to electricity compensation curve for the same day of the previous week at electricity statistics record point i. o5 E represents the electricity consumption value recorded within 5 minutes prior to the start time of the metering anomaly event on the day the anomaly event occurred. lo5 To measure the electricity consumption data for the 5 minutes preceding the start time of the abnormal event, the corresponding electricity consumption value on the electricity compensation curve for the same day of the previous week is used. Furthermore, for each electricity consumption data point in the abnormal electricity consumption data collection, the compensation electricity consumption can be calculated using the following formula: The compensation electricity consumption for electricity consumption data point i is...

[0092] In summary, the technical solutions provided by the embodiments of the present invention include: 1) a combined judgment method for metering anomalies in AC acquisition systems; 2) a metering anomaly compensation scheme for diverse scenarios; and 3) a segmented compensation-related algorithm, i.e., a power curve analysis and prediction scheme. The technical solutions provided by the embodiments of the present invention have the following technical advantages: 1) Proposing diversified combined metering anomaly judgment schemes and reporting responses, constructing a sound metering anomaly detection and judgment scheme, and reporting abnormal periods and metering anomaly types separately to northbound equipment, allowing northbound users to more quickly perceive the abnormal status and causes of on-site equipment; 2) Making targeted compensation actions based on different power distribution equipment types, such as whether they have southbound equipment data statistics functions; 3) Dividing compensation schemes according to the duration of anomalies, making different processing actions and calculation schemes for long-term and short-term anomalies, making the compensation schemes more reasonable; 4) For the power analysis and compensation scheme for long-term metering anomalies, drawing a method with a weekly cycle, a daily curve statistical period, and a fixed time for a power statistical record point, using deviation calculation and average value calculation schemes to continuously optimize the metering anomaly compensation curve, providing targeted compensation for power loss during metering anomalies.

[0093] Accordingly, another aspect of the present invention provides an apparatus for detecting metering anomalies in an AC data acquisition system.

[0094] Figure 6 This is a structural block diagram of a device for detecting metering anomalies in an AC data acquisition system, provided in another embodiment of the present invention. Figure 6 As shown, the device includes a startup module 1, a judgment module 2, and a reporting module 3. The startup module 1 is used to determine whether to activate the metering anomaly judgment mechanism based on whether the power grid basic data transmission frame transmitted from the data acquisition device of the AC acquisition system to the data processing device of the AC acquisition system is abnormal or whether the preset power grid basic acquisition data value meets a first preset condition. The judgment module 2 is used to determine whether a metering anomaly event has occurred in the AC acquisition system if the metering anomaly judgment mechanism needs to be activated. The reporting module 3 is used to report anomaly-related information regarding the metering anomaly event if it occurs, wherein the anomaly-related information includes at least one of the following: start time, end time, and metering anomaly type.

[0095] Optionally, in this embodiment of the invention, when determining whether to activate the metering anomaly determination mechanism based on whether the power grid basic data transmission data frame is checked for anomalies, the determination module determines whether a metering anomaly event has occurred in the AC acquisition system by judging based on at least one of the following: the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, whether the power grid basic data transmission data frame meets the second preset condition, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0096] Optionally, in this embodiment of the invention, the determination module determines whether a metering anomaly event has occurred in the AC data acquisition system by determining whether the following conditions are met: The data acquisition device's reset pin is not in a reset state and the data acquisition device's operating voltage does not fluctuate, but the data acquisition device's reset pin is controlled to perform a reset operation, or the data acquisition device's device number or version information is incorrect; The data acquisition device's reset pin is not in a reset state and the data acquisition device's operating voltage does not fluctuate, the data acquisition device's operating voltage is lower than or equal to a first threshold value, the data processing device experiences a soft reset, or the data acquisition device's device number or version information is incorrect; The data acquisition device's reset pin is not in a reset state and the data acquisition device's operating voltage does not fluctuate, the data acquisition device's operating voltage is higher than a first threshold value, the power grid basic data transmission data frame meets a second preset condition, or the data acquisition device's reset pin is controlled to perform a reset operation. The following conditions must be met: the data acquisition device's device number or version information is incorrect; the data acquisition device's reset pin is in an unreset state and the data acquisition device's operating voltage has not fluctuated; the data acquisition device's operating voltage is higher than the first threshold; the power grid basic data transmission frame does not meet the second preset condition; the data processing device's operating voltage is higher than the second threshold or the data processing device's operating voltage has not fluctuated; the data acquisition device's reset pin is controlled to perform a reset operation; and the data acquisition device's device number or version information is incorrect.

[0097] Optionally, in this embodiment of the invention, when determining whether to activate the metering anomaly determination mechanism based on whether the preset power grid basic data acquisition value meets the first preset condition, the determination module determines whether a metering anomaly event has occurred in the AC acquisition system by judging based on at least one of the following: the operating status data of the data acquisition device, the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

[0098] Optionally, in this embodiment of the invention, the determination module determines whether a metering anomaly event has occurred in the AC data acquisition system by determining whether the following conditions are met: abnormal operating status data, the reset pin of the data acquisition device being controlled to perform a reset operation, and an error in the device number or version information of the data acquisition device; normal operating status data, an error in the device number or version information of the data acquisition device, and the data acquisition device's reset pin being in an unreset state and the operating voltage of the data acquisition device not fluctuating, and the data acquisition device's reset pin being controlled to perform a reset operation; normal operating status data, an error in the device number or version information of the data acquisition device, and the data acquisition device's reset pin being in an unreset state and the operating voltage of the data acquisition device not fluctuating, the operating voltage of the data acquisition device being lower than or equal to a first threshold value, and data processing... The device has experienced a soft reset; the operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated, the operating voltage of the data acquisition device is higher than the first threshold, the operating voltage of the data processing device is higher than the second threshold or the operating voltage of the data processing device has not fluctuated, and the reset pin of the data acquisition device is controlled to perform a reset operation; and the operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated, the operating voltage of the data acquisition device is higher than the first threshold, the operating voltage of the data processing device is higher than the second threshold or the operating voltage of the data processing device has not fluctuated, and the data processing device has experienced a soft reset.

[0099] The specific working principle and benefits of the device for detecting metering abnormal events in an AC data acquisition system provided in this embodiment of the invention are similar to those of the method for detecting metering abnormal events in an AC data acquisition system provided in this embodiment of the invention, and will not be repeated here.

[0100] Accordingly, another aspect of the present invention provides an apparatus for determining the power compensation value of a metering anomaly event in an AC data acquisition system. The apparatus includes: a detection module for detecting whether a metering anomaly event has occurred in the AC data acquisition system according to the method for detecting metering anomaly events in the AC data acquisition system described in the above embodiments; an anomaly duration determination module for determining the anomaly duration of the metering anomaly event if it occurs; and a power compensation value determination module for determining the power compensation value for the anomaly period in which the metering anomaly event occurred based on the anomaly duration and a preset power compensation rule.

[0101] Optionally, in this embodiment of the invention, the preset power compensation rule is related to the magnitude of the abnormal duration and the preset power statistics period.

[0102] Optionally, in this embodiment of the invention, the preset power compensation rule includes: when the abnormal duration is less than or equal to a preset power statistics period, determining a power compensation value based on the power value of the most recent power statistics record point, the preset power statistics period, and the abnormal duration, wherein the most recent power statistics record point is the power statistics record point closest to the start time of the metering abnormal event; and / or when the abnormal duration is greater than the preset power statistics period, determining a power compensation value based on comparing the power data deviation of each power statistics record point with a preset power data deviation threshold, wherein the comparison power statistics record points include a preset number of power statistics record points before the start time, and the power data deviation of any power statistics record point is the deviation between the power value corresponding to the power statistics record point on the day the metering abnormal event occurred and the power value corresponding to the preset historical time.

[0103] Optionally, in this embodiment of the invention, the preset power compensation rule is also related to the southbound device data statistics function of the AC acquisition system.

[0104] Optionally, in this embodiment of the invention, when the preset power compensation rule includes determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold when the abnormal duration is greater than the preset power statistical period, the condition for determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold is that the abnormal duration is greater than the preset power statistical period but there is no southbound device data statistical function or the southbound device data statistical function is abnormal; the preset power compensation rule also includes: when the abnormal duration is greater than the preset power statistical period and there is a normal southbound device data statistical function, determining the power compensation value based on the power value of the southbound device in the abnormal period within the preset statistical range.

[0105] Optionally, in this embodiment of the invention, determining the power compensation value based on the relationship between the power data deviation of each power statistical recording point in the comparison power data recording points and a preset power data deviation threshold includes: when the power data deviation of each power statistical recording point in the comparison power data recording points is less than or equal to the preset power data deviation threshold, determining the power compensation value based on the power value of the abnormal power statistical recording point on the current day and the power value at a preset historical time, wherein the abnormal power statistical recording point includes the power statistical recording point in an abnormal period; and / or when the power data deviation of at least one power statistical recording point in the comparison power data recording points is greater than the preset power data deviation threshold, if the power data deviation of the most recent power statistical recording point is less than or equal to the preset power data deviation threshold, determining the power compensation value based on the power value of the abnormal power statistical recording point on the current day and the power value at a preset historical time; and / or if the power data deviation of the most recent power statistical recording point is greater than the preset power data deviation threshold, determining the power compensation value based on the power value of the most recent power statistical recording point on the current day and the power value at a preset historical time, and the power value of the abnormal power statistical recording point at a preset historical time.

[0106] The specific working principle and benefits of the device for determining the power compensation value of metering abnormal events in an AC data acquisition system provided in this embodiment of the invention are similar to the specific working principle and benefits of the method for determining the power compensation value of metering abnormal events in an AC data acquisition system provided in this embodiment of the invention, and will not be repeated here.

[0107] The device for detecting metering abnormal events in the AC acquisition system or the device for determining the power compensation value of metering abnormal events in the AC acquisition system both include a processor and a memory. The modules included in the two devices are stored as program units in the memory, and the processor executes the program units stored in the memory to realize the corresponding functions.

[0108] The processor contains a kernel, which retrieves the corresponding program units from memory. One or more kernels can be configured, and adjusting kernel parameters can detect whether the metering function of the AC data acquisition system itself is malfunctioning, or determine the power compensation value to handle any malfunctions.

[0109] The memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0110] Furthermore, another aspect of the present invention provides a data processing apparatus, which includes: the apparatus for detecting metering abnormal events in an AC data acquisition system as described in the above embodiments; or the method for determining the power compensation value of a metering abnormal event in an AC data acquisition system as described in the above embodiments.

[0111] In addition, another aspect of the present invention provides an AC acquisition system, which includes the data processing device described in the above embodiments.

[0112] In addition, another aspect of the present invention provides a machine-readable storage medium storing instructions that cause a machine to perform the methods described in the above embodiments.

[0113] Furthermore, another aspect of the present invention provides a processor for running a program, wherein the program is run to perform the methods described in the above embodiments.

[0114] Furthermore, another aspect of this invention provides a device, which includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, it implements the methods described in the above embodiments. The device in this document can be a server, PC, PAD, mobile phone, etc.

[0115] Furthermore, another aspect of the present invention provides a computer program product that, when executed on a data processing device, is adapted to execute a program that initializes the steps described in the above embodiments.

[0116] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0117] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0118] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0119] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0120] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0121] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0122] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0123] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0124] The above are merely embodiments of this application and are not intended to limit the scope of this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of the claims of this application.

Claims

1. A method for determining the power compensation value for metering anomalies in an AC data acquisition system, characterized in that, The method includes: Detect whether the AC data acquisition system has experienced the metering anomaly event; In the event of the aforementioned measurement anomaly, determine the duration of the anomaly; and Based on the abnormal duration and the preset power compensation rules, determine the power compensation value for the abnormal period when the metering abnormal event occurs; The preset power compensation rule is related to the magnitude of the abnormal duration and the preset power statistics period; The preset power compensation rules include: If the duration of the anomaly is less than or equal to a preset power consumption statistics period, the power compensation value is determined based on the power consumption value of the most recent power consumption statistics record point, the preset power consumption statistics period, and the duration of the anomaly, wherein the most recent power consumption statistics record point is the power consumption statistics record point closest to the start time of the metering anomaly event; and / or If the duration of the anomaly is greater than the preset power consumption statistics period, a power compensation value is determined based on the relationship between the power consumption data deviation of each power consumption statistics record point and the preset power consumption data deviation threshold. The power consumption statistics record points include a preset number of power consumption statistics record points before the start time. The power consumption data deviation of any power consumption statistics record point is the deviation between the power consumption value corresponding to that power consumption statistics record point on the day the metering anomaly event occurs and the power consumption value corresponding to that power consumption statistics record point at a preset historical time.

2. The method according to claim 1, characterized in that, The preset power compensation rule is also related to the southbound device data statistics function of the AC acquisition system.

3. The method according to claim 2, characterized in that, When the preset power compensation rule includes determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and a preset power data deviation threshold when the abnormal duration is greater than the preset power statistical period, the preset power compensation rule includes the following: The condition for determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold is that the abnormal duration is greater than the preset power statistical cycle but there is no southbound device data statistical function or the southbound device data statistical function is abnormal. The preset power compensation rule further includes: when the abnormal duration is greater than the preset power statistics period and there is normal southbound device data statistics function, the power compensation value is determined based on the power value of the southbound device in the abnormal period within the preset statistical range.

4. The method according to claim 1, characterized in that, The power compensation value is determined based on the relationship between the power data deviation at each power statistics recording point and a preset power data deviation threshold, including: If the power data deviation of each power statistical recording point in the comparison power statistical recording points is less than or equal to a preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistical recording point on the current day and the power value at the preset historical time. The abnormal power statistical recording points include those occurring during the abnormal time period; and / or If the deviation of the power data at at least one of the power statistics recording points is greater than the preset power data deviation threshold, then... If the power data deviation of the most recent power statistics record point is less than or equal to the preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistics record point on that day and the power value at the preset historical time; and / or If the power data deviation of the most recent power statistics record point is greater than the preset power data deviation threshold, the power compensation value is determined based on the power value of the most recent power statistics record point on the current day, the power value at the preset historical time, and the power value of the abnormal power statistics record point at the preset historical time.

5. The method according to claim 1, characterized in that, Detecting whether the AC data acquisition system has experienced the metering anomaly event includes: Based on whether the power grid basic data transmission data frame transmitted from the data acquisition device of the AC acquisition system to the data processing device of the AC acquisition system is abnormal or whether the preset power grid basic acquisition data value meets the first preset condition, it is determined whether the metering anomaly judgment mechanism needs to be activated. When it is necessary to activate the metering anomaly determination mechanism, determine whether the AC data acquisition system has experienced the metering anomaly event; and In the event of the aforementioned measurement anomaly, report the anomaly-related information concerning the measurement anomaly event, wherein the anomaly-related information includes at least one of the following: start time, end time, and measurement anomaly type; In the case where the determination of whether to activate the metering anomaly determination mechanism is to check whether the power grid basic data transmission data frame is abnormal, the determination of whether the metering anomaly event has occurred in the AC acquisition system includes determining based on at least one of the following: the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, whether the power grid basic data transmission data frame meets the second preset condition, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device; The determination of whether the measurement anomaly event has occurred in the AC acquisition system includes determining whether the measurement anomaly event has occurred based on whether any of the following conditions are met: The following conditions are not met: the reset pin of the data acquisition device is not in a reset state, the operating voltage of the data acquisition device does not fluctuate but the reset pin of the data acquisition device is controlled to perform a reset operation, and the device number or version information of the data acquisition device is incorrect. The following conditions must be met: the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device does not fluctuate; the operating voltage of the data acquisition device is lower than or equal to a first threshold value; the data processing device experiences a soft reset; and the device number or version information of the data acquisition device is incorrect. The following conditions must be met: the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device does not fluctuate; the operating voltage of the data acquisition device is higher than the first threshold value; the power grid basic data transmission data frame meets the second preset condition; the reset pin of the data acquisition device is controlled to perform a reset operation; and the device number or version information of the data acquisition device is incorrect. The following conditions must be met: the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the power grid basic data transmission frame does not meet the second preset condition; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated; the reset pin of the data acquisition device is controlled to perform a reset operation; and the device number or version information of the data acquisition device is incorrect. The following conditions must be met: the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the power grid basic data transmission frame does not meet the second preset condition; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated; the data processing device has undergone a soft reset; and the device number or version information of the data acquisition device is incorrect.

6. The method according to claim 5, characterized in that, When determining whether to activate the metering anomaly determination mechanism based on whether the preset power grid basic data acquisition value meets the first preset condition, the determination of whether the AC acquisition system has experienced the metering anomaly event includes determining based on at least one of the following: the operating status data of the data acquisition device, the reset pin status of the data acquisition device, the operating voltage of the data acquisition device, the operating voltage of the data processing device, the soft reset flag of the data processing device, and the device number or version information of the data acquisition device.

7. The method according to claim 6, characterized in that, The determination of whether the measurement anomaly event has occurred in the AC acquisition system includes determining whether the measurement anomaly event has occurred based on whether any of the following conditions are met: The operating status data is abnormal, the reset pin of the data acquisition device is controlled to perform a reset operation, and the device number or version information of the data acquisition device is incorrect. The operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin of the data acquisition device is not in a reset state and the operating voltage of the data acquisition device does not fluctuate, and the reset pin of the data acquisition device is controlled to perform a reset operation. The operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device does not fluctuate, the operating voltage of the data acquisition device is lower than or equal to the first threshold value, and the data processing device has experienced a soft reset. The operating status data is normal; the device number or version information of the data acquisition device is incorrect; the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated; the operating voltage of the data acquisition device is higher than the first threshold value; the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated and the reset pin of the data acquisition device is controlled to perform a reset operation; and The operating status data is normal, the device number or version information of the data acquisition device is incorrect, the reset pin of the data acquisition device is in an unreset state and the operating voltage of the data acquisition device has not fluctuated, the operating voltage of the data acquisition device is higher than the first threshold value, the operating voltage of the data processing device is higher than the second threshold value or the operating voltage of the data processing device has not fluctuated, and the data processing device has undergone a soft reset.

8. A device for determining the power compensation value for metering anomalies in an AC data acquisition system, characterized in that, The device includes: The detection module is used to detect whether the metering abnormality event has occurred in the AC acquisition system; An abnormal duration determination module is used to determine the abnormal duration of the metering abnormal event when the metering abnormal event occurs; and The power compensation value determination module is used to determine the power compensation value for the abnormal period when the metering abnormal event occurs, based on the abnormal duration and the preset power compensation rules. The preset power compensation rule is related to the magnitude of the abnormal duration and the preset power statistics period; The preset power compensation rules include: If the duration of the anomaly is less than or equal to a preset power consumption statistics period, the power compensation value is determined based on the power consumption value of the most recent power consumption statistics record point, the preset power consumption statistics period, and the duration of the anomaly, wherein the most recent power consumption statistics record point is the power consumption statistics record point closest to the start time of the metering anomaly event; and / or If the duration of the anomaly is greater than the preset power consumption statistics period, a power compensation value is determined based on the relationship between the power consumption data deviation of each power consumption statistics record point and the preset power consumption data deviation threshold. The power consumption statistics record points include a preset number of power consumption statistics record points before the start time. The power consumption data deviation of any power consumption statistics record point is the deviation between the power consumption value corresponding to that power consumption statistics record point on the day the metering anomaly event occurs and the power consumption value corresponding to that power consumption statistics record point at a preset historical time.

9. The apparatus according to claim 8, characterized in that, The preset power compensation rule is also related to the southbound device data statistics function of the AC acquisition system.

10. The apparatus according to claim 9, characterized in that, When the preset power compensation rule includes determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and a preset power data deviation threshold when the abnormal duration is greater than the preset power statistical period, the preset power compensation rule includes the following: The condition for determining the power compensation value based on the relationship between the power data deviation of each power statistical record point in the power statistical record point and the preset power data deviation threshold is that the abnormal duration is greater than the preset power statistical cycle but there is no southbound device data statistical function or the southbound device data statistical function is abnormal. The preset power compensation rule further includes: when the abnormal duration is greater than the preset power statistics period and there is normal southbound device data statistics function, the power compensation value is determined based on the power value of the southbound device in the abnormal period within the preset statistical range.

11. The apparatus according to claim 8, characterized in that, The power compensation value is determined based on the relationship between the power data deviation at each power statistics recording point and a preset power data deviation threshold, including: If the power data deviation of each power statistical recording point in the comparison power statistical recording points is less than or equal to a preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistical recording point on the current day and the power value at the preset historical time. The abnormal power statistical recording points include those occurring during the abnormal time period; and / or If the deviation of the power data at at least one of the power statistics recording points is greater than the preset power data deviation threshold, then... If the power data deviation of the most recent power statistics record point is less than or equal to the preset power data deviation threshold, the power compensation value is determined based on the power value of the abnormal power statistics record point on that day and the power value at the preset historical time; and / or If the power data deviation of the most recent power statistics record point is greater than the preset power data deviation threshold, the power compensation value is determined based on the power value of the most recent power statistics record point on the current day, the power value at the preset historical time, and the power value of the abnormal power statistics record point at the preset historical time.

12. An AC data acquisition system, characterized in that, The communication acquisition system includes: The apparatus according to any one of claims 8-11.

13. A machine-readable storage medium, characterized in that, The machine-readable storage medium stores instructions for causing the machine to perform the method of any one of claims 1-7.

14. A processor, characterized in that, Used to run a program, wherein the program is run to perform the method described in any one of claims 1-7.