Method, system and readable storage medium for rapid identification of power outage

By using FIR low-pass filtering and power-off voltage comparison waveform data comparison methods in power management, the problems of slow power-off identification speed and poor accuracy in the existing technology are solved, and fast and accurate power-off identification is achieved. Applicable to a variety of power systems.

CN113937874BActive Publication Date: 2024-10-15SMARTGEN TECH
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202111103091.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-18
Publication Date
2024-10-15
Estimated Expiration
2041-09-18

AI Technical Summary

Technical Problem

Existing technology cannot quickly and accurately identify single-phase or two-phase power outages, and relies on preset power outage thresholds, which affects the accuracy and efficiency of identification.

Method used

Use the preset sampling frequency to continuously sample the real-time waveform data of the power supply, generate power-off voltage comparison waveform data through FIR low-pass filtering, and compare it with the real-time waveform data, and identify whether the power supply is in a power-off state based on the comparison results.

Benefits of technology

It achieves fast and accurate power outage identification to ensure that the load is not powered off when dual power supplies are switched. It is suitable for three-phase four-wire and single-phase AC systems. It has low cost and low CPU occupancy, and is suitable for embedded systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113937874B_ABST
    Figure CN113937874B_ABST
Patent Text Reader

Abstract

The present invention provides a method, system and readable storage medium for quickly identifying power outages, the method comprising the following steps: step 1, for each phase of real-time waveform data in an AC power supply to be tested, at each identification period T0, the sampled real-time waveform data is stored in a recursive array ac[], and a data recording completion flag is set; step 2, in response to the read data recording completion flag, the real-time waveform data in the recursive array ac[] is subjected to FIR low-pass filtering to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested as an array fir[]; step 3, the signal frequency of the discrete FIR data in the array fir[] is calculated; step 4, power-off voltage comparison waveform data is generated, and the power-off voltage comparison waveform data is stored in the array outstage[]; step 5, the recursive array ac[] is compared with the array outstage[], and whether each phase in the AC power supply to be tested is in a power-off state is identified according to the comparison result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of power management, and in particular to a method, system and readable storage medium for quickly identifying power failure. Background Art

[0002] At present, electric energy is becoming more and more important to the development of human society. In industries such as petrochemicals, semiconductors, and data centers, the requirements for power quality are becoming higher and higher. These industries basically use multiple power supplies for mutual backup or UPS to ensure uninterrupted power supply.

[0003] It should be noted that whether switching from an abnormal power supply to a normal power supply or from an abnormal power supply to a UPS, it is necessary to be able to quickly identify a power outage so as to perform a power switch; therefore, how to quickly and accurately identify whether a power outage is occurring is crucial.

[0004] Current identification methods include DP transformation method, three-phase absolute value sum method, etc., but these identification methods cannot quickly detect single-phase or two-phase power outages, and these identification methods need to rely on preset power outage thresholds. The preset power outage thresholds are relatively abstract and will affect the accuracy and efficiency of identification.

[0005] In order to solve the above problems, people have been seeking an ideal technical solution. Summary of the invention

[0006] The object of the present invention is to address the deficiencies of the prior art and thereby provide a method, system and readable storage medium for quickly identifying power outages.

[0007] In order to achieve the above object, the technical solution adopted by the present invention is:

[0008] A first aspect of the present invention provides a method for quickly identifying a power outage, characterized in that it comprises the following steps:

[0009] Step 1, continuously and uninterruptedly sampling the real-time waveform data of the AC power supply to be tested at a preset sampling frequency, for each phase of the real-time waveform data in the AC power supply to be tested, at each interval identification period T0, the sampled real-time waveform data is stored in a preset recursive array ac[], and a data recording completion flag is set;

[0010] Step 2, in response to the read data record completion flag, perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, and store them in a preset array fir[].

[0011] Step 3, calculating the signal frequency of the discrete FIR data in the array fir[];

[0012] Step 4, generate power-off voltage comparison waveform data, and store the power-off voltage comparison waveform data into the array outstage[];

[0013] Step 5, compare the recursive array ac[] obtained in step 1 with the array outstage[] obtained in step 4, and identify whether each phase of the AC power supply to be tested is in a power-off state according to the comparison result.

[0014] A second aspect of the present invention provides a rapid identification system for power outages, the rapid identification system for power outages comprising a sampling management unit, a flag determination unit, a filtering management unit, a frequency calculation unit, a comparison waveform generation unit and a power outage determination unit, wherein:

[0015] The sampling management unit is used to continuously and uninterruptedly sample the real-time waveform data of the AC power supply to be tested at a preset sampling frequency, and for each phase of the real-time waveform data of the AC power supply to be tested, the sampled real-time waveform data is stored in a preset recursive array ac[] at each interval identification period T0, and a data recording completion flag is set;

[0016] The flag determination unit is used to determine whether the data recording completion flag is read, and in response to the read data recording completion flag, trigger the FIR low-pass filter logic;

[0017] The filter management unit is used to perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, and store them in a preset array fir[].

[0018] The frequency calculation unit is used to calculate the signal frequency of the discrete FIR data in the array fir[];

[0019] The comparison waveform generating unit is used to generate power-off voltage comparison waveform data and store the power-off voltage comparison waveform data into the array outstage[].

[0020] The power-off determination unit is used to compare the recursive array ac[] and the array outstage[], and to identify whether each phase of the AC power supply to be tested is in a power-off state according to the comparison result.

[0021] A third aspect of the present invention provides a readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method for rapid identification of power failure as described above.

[0022] The present invention has outstanding substantive features and significant progress compared to the prior art, specifically:

[0023] 1) The present invention proposes a method and system for quickly identifying power failure, generating power failure voltage comparison waveform data in real time, comparing the power failure voltage comparison waveform data with the sampled real-time waveform data, and identifying whether each phase of the AC power supply to be tested is in a power failure state according to the comparison result;

[0024] Fast identification speed, ensuring that the load will not be powered off when dual power supply is switched;

[0025] 2) The present invention compares the power-off voltage comparison waveform data of each sampling point with the sampled real-time waveform data, and since there is an error in the calculation during this period near the zero-crossing position, the identification delay is not accumulated near the zero-crossing position, and no comparison is made within the zero-crossing interval, thereby improving the identification efficiency while ensuring the identification accuracy;

[0026] 3) The method for quickly identifying power failure proposed by the present invention can be used for both three-phase four-wire and single-phase AC systems, and has a wide range of applications;

[0027] 4) The present invention has the characteristics of low cost and adjustable power-off threshold. It adopts task scheduling of embedded system, with extremely low CPU occupancy, which is convenient for processing other tasks. Only one MCU is needed to complete all functional requirements. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 It is a flow chart of the method for quickly identifying power failure of the present invention;

[0029] Figure 2 It is a structural schematic diagram of a rapid identification system for power failure of the present invention;

[0030] Figure 3 It is a schematic diagram of a real-time waveform sampled by the present invention;

[0031] Figure 4 It is a schematic diagram of the waveform after FIR low-pass filtering of the present invention;

[0032] Figure 5 is a schematic diagram of a power-off comparison waveform generated by the present invention;

[0033] Figure 6 It is a schematic diagram comparing the sampled real-time signal and the generated power-off comparison waveform of the present invention;

[0034] Figure 7 It is a schematic diagram of waveform comparison results of the present invention. DETAILED DESCRIPTION

[0035] The technical solution of the present invention is further described in detail below through specific implementation methods.

[0036] Example 1

[0037] As attached Figure 1 As shown, a method for quickly identifying power failure includes the following steps:

[0038] Step 1, continuously and uninterruptedly sampling the real-time waveform data of the AC power supply to be tested at a preset sampling frequency, for each phase of the real-time waveform data in the AC power supply to be tested, at each interval identification period T0, the sampled real-time waveform data is stored in a preset recursive array ac[], and a data recording completion flag is set;

[0039] Step 2, in response to the read data record completion flag, perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, and store them in a preset array fir[].

[0040] Step 3, calculating the signal frequency of the discrete FIR data in the array fir[];

[0041] Step 4, generate power-off voltage comparison waveform data, and store the power-off voltage comparison waveform data into the array outstage[];

[0042] Step 5, compare the recursive array ac[] obtained in step 1 with the array outstage[] obtained in step 4, and identify whether each phase of the AC power supply to be tested is in a power-off state according to the comparison result.

[0043] It should be noted that, each phase of the AC power supply to be tested corresponds to a recursive array ac[], an array fir[] and an array outstage[], and the recursive array ac[], the array fir[] and the array outstage[] are automatically and dynamically updated following the sampling progress; therefore, the present invention can obtain the latest power-off status through the continuously and dynamically updated recursive array ac[] and array outstage[], with strong real-time performance and high efficiency.

[0044] In a specific implementation, the AC power supply to be tested is a three-phase four-wire AC power supply, and a recursive array ac[]_A, a recursive array ac[]_B, and a recursive array ac[]_C, as well as an array fir[]_A, an array fir[]_B, and an array fir[]_C, and an array outstage[]_A, an array outstage[]_B, and an array outstage[]_C are preset;

[0045] The recursive array ac[]_A is used to store the A-phase waveform data, the array fir[]_A is used to store the discrete FIR data of the A-phase waveform data, and the array outstage[]_A is used to store the power-off voltage comparison waveform data of the A-phase waveform data;

[0046] The recursive array ac[]_B is used to store B-phase waveform data, the array fir[]_B is used to store discrete FIR data of the B-phase waveform data, and the array outstage[]_B is used to store power-off voltage comparison waveform data of the B-phase waveform data;

[0047] The recursive array ac[]_C is used to store C-phase waveform data, the array fir[]_C is used to store discrete FIR data of the C-phase waveform data, and the array outstage[]_C is used to store power-off voltage comparison waveform data of the C-phase waveform data;

[0048] Based on the recursive array ac[]_A, the array fir[]_A and the array outstage[]_A, the A phase power failure identification of the three-phase four-wire AC power supply is performed; based on the recursive array ac[]_B, the array fir[]_B and the array outstage[]_B, the B phase power failure identification of the three-phase four-wire AC power supply is performed; based on the recursive array ac[]_C, the array fir[]_C and the array outstage[]_C, the C phase power failure identification of the three-phase four-wire AC power supply is performed;

[0049] The A-phase power failure identification logic of the three-phase four-wire AC power supply, the B-phase power failure identification logic of the three-phase four-wire AC power supply and the C-phase power failure identification logic of the three-phase four-wire AC power supply do not affect each other and can be performed simultaneously; the present invention independently calculates the voltage of each phase to perform power failure identification, and does not require coordinated calculation of the three phases, so as to realize rapid power failure identification of each phase in the AC power supply to be tested.

[0050] It can be understood that the power failure identification logics of each phase of the AC power to be tested do not affect each other. The task scheduling of the embedded system is adopted, and the CPU occupancy rate is extremely low, which is convenient for processing other tasks. Only one MCU is needed to complete all functional requirements.

[0051] In another specific implementation, the AC power supply to be tested is a single-phase AC power supply, and a recursive array ac[], an array fir[] and an array outstage[] are preset; the recursive array ac[] is used to store single-phase waveform data, the array fir[] is used to store discrete FIR data of the single-phase waveform data, and the array outstage[] is used to store power-off voltage comparison waveform data of the single-phase waveform data; based on the recursive array ac[], the array fir[] and the array outstage[], power-off identification of the single-phase AC power supply is performed, thereby realizing rapid power-off identification of the single-phase AC standard system.

[0052] It can be understood that the preset sampling frequency must satisfy the Nyquist sampling theorem, that is, the sampling frequency must be greater than twice the signal frequency; the sampling speed is obtained according to the preset sampling frequency, and the ADC samples the real-time waveform data after the timing time is up. After the sampling is completed, the DMA transfers the real-time waveform data.

[0053] Specifically, the identification period T0 may be 1 / 8 of the period of the AC power supply (sinusoidal AC power) to be tested, but it does not necessarily have to be 1 / 8 of the period of the AC power supply to be tested. The faster the sampling speed, the more conducive it is to quickly identify power outages.

[0054] Furthermore, in step 2, when the real-time waveform data in the recursive array ac[] is subjected to FIR low-pass filtering to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, the following steps are performed: the library function provided by the ARM chip is called to perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to filter out high-order harmonics (3rd, 5th, 7th... harmonics), thereby preventing the high-order harmonics (3rd, 5th, 7th... harmonics) components from interfering with the frequency calculation and improving the accuracy of the frequency calculation in step 3.

[0055] In a specific implementation, the library function is arm_fir_f32(&S, firIn, firOut, MaxSampleNum), where S represents the filter structure, firIn represents the sampled real-time waveform data, firOut represents the discrete FIR data of the real-time waveform data, and MaxSampleNum represents the length of the calculated data.

[0056] Specifically, the step 3 specifically includes the following steps: after determining the number of interval sampling points N between two zero-crossing points of the discrete FIR data in the array fir[], the time interval ΔT between the two zero-crossing points is obtained according to the preset sampling frequency f0; wherein ΔT=N / f0;

[0057] Based on the time interval ΔT, the signal frequency F of the discrete FIR data of the real-time waveform data in the fir[] array is calculated, where F=1 / (2×ΔT).

[0058] It can be understood that the signal frequency F of the discrete FIR data is consistent with the frequency corresponding to the real-time waveform data.

[0059] In order to ensure that the calculated frequency is more accurate, the recursive array ac[] is configured to be an array that can store waveform data of more than 4 cycles, while ensuring that the recorded waveform is continuous.

[0060] In a specific implementation manner, the sampled real-time waveform data is as shown in the attached Figure 3 The waveform data after FIR low-pass filtering is shown in the attached Figure 4As shown in the figure, if the amplitude of the power-off comparison waveform is 20% of the rated voltage, the power-off comparison waveform generated in real time is as shown in the attached figure. Figure 5 The comparison of the sampled real-time signal and the generated power-off comparison waveform is shown in the attached figure. Figure 6 The comparison results are shown in the attached Figure 7 As shown, Figure 7 The blank segment between t1 and t2 is the zero-crossing interval.

[0061] Example 2

[0062] This embodiment provides a specific implementation method for generating power-off voltage comparison waveform data:

[0063] In step 4, when generating the power-off voltage comparison waveform data, the following steps are performed:

[0064] Obtain the signal frequency obtained in step 3, and use the signal frequency as the frequency of the power-off voltage comparison waveform;

[0065] Based on the discrete FIR data of the real-time waveform data, the time interval DT from the last zero-crossing point to the starting sampling point is obtained;

[0066] Subtract the group delay time t0 of the FIR filter from the time interval DT to obtain the time interval DT' from the zero-crossing point corresponding to the real-time waveform to the starting sampling point;

[0067] Calculate the phase angle corresponding to the current sampling point according to the time interval DT', and use the phase angle as the phase angle of the power-off voltage comparison waveform;

[0068] Calculating the amplitude of the power-off voltage comparison waveform based on a preset power-off threshold;

[0069] Based on the frequency, phase angle and amplitude of the power-off voltage comparison waveform, power-off voltage comparison waveform data outstage is obtained.

[0070] It can be understood that the signal frequency f obtained in step 3 / preset sampling frequency f0=M, M represents the total number of sampling points in one cycle, the time interval Δt between two adjacent sampling points=1 / f0; 360° / M represents the phase angle change value between two adjacent sampling points.

[0071] Specifically, based on the discrete FIR data of the real-time waveform data, when the time interval DT between the last zero-crossing point and the starting sampling point is obtained, execute:

[0072] If the last zero-crossing point coincides with a sampling point, the sampling point position that coincides with the last zero-crossing point is the zero-crossing point position;

[0073] If the last zero-crossing point does not coincide with the sampling point, obtain the position data (time point and voltage value) of the left and right sampling points corresponding to the last zero-crossing point recorded:

[0074] (1) If the absolute value of the voltage corresponding to the left sampling point is equal to the absolute value of the voltage corresponding to the right sampling point, then the time point corresponding to the left sampling point + (time interval Δt / 2), or the time point corresponding to the right sampling point - (time interval Δt / 2), obtains the zero-crossing point position (time point);

[0075] (2) If the absolute values ​​of the voltages corresponding to the left and right sampling points are not equal, the equation of the straight line is obtained according to the position data (time point and voltage value) of the left and right sampling points, and the zero point of the straight line equation is taken as the zero-crossing point position;

[0076] Based on the calculated time interval between the zero-crossing point position and the start sampling point position, the time interval DT is calculated.

[0077] Specifically, when the phase angle corresponding to the current sampling point is calculated according to the time interval DT', the following is executed:

[0078] Based on the discrete FIR data of the real-time waveform data, determine whether the last zero-crossing point is on the rising edge or the falling edge. If it is on the rising edge, the phase angle Ѳ_zero corresponding to the last zero-crossing point is 0°. If it is on the falling edge, the phase angle Ѳ_zero corresponding to the last zero-crossing point is 180°.

[0079] ((time interval between the current sampling point SP_i and the starting sampling point position) - time interval DT') ÷ real-time waveform signal cycle × 360°, to obtain the phase angle change value ΔѲ between the last zero-crossing point and the current sampling point SP_i;

[0080] The phase angle Ѳ_i corresponding to the current sampling point SP_i is obtained by adding the phase angle change value ΔѲ to the phase angle Ѳ_zero corresponding to the last zero-crossing point;

[0081] The phase angle Ѳ_i corresponding to the current sampling point SP_i is used as the phase angle of the power-off voltage comparison waveform.

[0082] Specifically, based on the frequency, phase angle and amplitude of the power-off voltage comparison waveform, the power-off voltage comparison waveform data outstage is obtained: outstage[i]= Vset * sin(2πf+Ѳ+Angle[i]),

[0083] Wherein, i represents the i-th sampling point SP_i, Vset represents the amplitude of the power-off voltage comparison waveform, f represents the frequency of the power-off voltage comparison waveform, Ѳ represents the phase angle change value ΔѲ, and Angle[i] represents the phase angle Ѳ_zero corresponding to the last zero crossing point.

[0084] It can be understood that the power-off voltage comparison waveform data is waveform data with the same phase and frequency as the sampled real-time waveform.

[0085] Specifically, the preset power-off threshold is a percentage of the rated voltage, which can be set through the module front panel and can be changed according to the needs of customers in different occasions; therefore, the present invention has the characteristic of being able to set the power-off threshold.

[0086] Further, the step 5 comprises the following steps:

[0087] Step 5.1, start counting the identification time of this power outage;

[0088] Step 5.2, compare the absolute value of the power-off voltage comparison waveform data in the array outstage[] corresponding to each sampling point with the waveform data in the recursive array ac[].

[0089] When the absolute value of the power-off voltage comparison waveform data in the array outstage[] is greater than the waveform data in the recursive array ac[], the power-off counting starts; if a zero-crossing interval is encountered, the comparison is not performed, the identification time is paused, and the power-off count value is saved. After the zero-crossing interval, the comparison and identification time are continued, and the counting is continued based on the saved power-off count value;

[0090] When the identification time of this power failure reaches the specified duration, the total number of power failures is counted;

[0091] Step 5.3, determine whether the total power-off count is greater than a preset value. If so, determine that the corresponding phase in the tested AC power supply is in a power-off state; otherwise, clear the total power-off count and restart counting.

[0092] It should be noted that, since the real-time waveform data of the AC power supply to be tested sampled after power failure will become 0, while the power failure voltage comparison waveform data will still maintain the original amplitude, frequency and phase for a certain period of time; it can be understood that the conditions for triggering the power failure to start counting are different depending on whether the power failure occurs in the positive half cycle or the negative half cycle;

[0093] That is to say, the comparison between the recursive array ac[] obtained in step 1 and the array outstage[] obtained in step 4 can be divided into two cases: (1) If the AC power supply to be tested is powered off in the positive half cycle, then when the power-off count dropdown++ starts, the waveform data in the recursive array ac[] at the corresponding time point will be smaller than the power-off voltage comparison waveform data in the array outstage[]. (2) If the AC power supply to be tested is powered off in the negative half cycle, then when the power-off count dropdown++ starts, the waveform data in the recursive array ac[] at the corresponding time point will be larger than the power-off voltage comparison waveform data in the array outstage[].

[0094] Furthermore, when determining the zero-crossing interval, the following operations are performed:

[0095] Determine the last zero-crossing point position of the power-off voltage comparison waveform data, and extract two sampling points before and after the zero-crossing point;

[0096] According to the preset sampling frequency, the time points corresponding to the two sampling points are calculated;

[0097] The time point corresponding to one of the sampling points is taken as the minimum value of the zero-crossing interval, and the time point corresponding to the other sampling point is taken as the maximum value of the zero-crossing interval; the zero-crossing interval range is obtained according to the minimum value of the zero-crossing interval and the maximum value of the zero-crossing interval.

[0098] It should be noted that the two sampling points before and after the last zero-crossing point of the power-off voltage comparison waveform data refer to the left sampling point and the right sampling point of the last zero-crossing point. These two sampling points can be adjacent sampling points or non-adjacent sampling points.

[0099] Specifically, the zero-crossing point interval refers to an angle range to the left and right of the zero-crossing point, for example, ±5 degrees.

[0100] It should be noted that when identifying a power failure, if a zero-crossing interval is encountered, no comparison will be made; this is because the voltage near the zero-crossing point is also 0, and it is impossible to determine whether the voltage is abnormal at this time, resulting in an error in the calculation of the zero-crossing interval range during this period; therefore, when performing power failure identification, the present invention will identify that the delay will not be accumulated near the zero-crossing position to increase the identification efficiency and shorten the identification time.

[0101] It should be noted that in each identification time interval, the waveform data points of the latest sampled identification period T0 are calculated, and the ac[i] data is compared with the outstage[i] data, where i refers to the i-th sampling point; if the continuous dropdown value is less than the preset value, the counting starts again. If a zero-crossing interval is encountered (the range of 10 degrees before and after the zero-crossing point can be taken), no comparison is made, and the dropdown is counted again; when the dropdown exceeds the set value, it is considered that the power supply is off at this time, and the status of other phase power supplies can be detected in the same way.

[0102] It can be understood that according to the power-off moments of different phases (power-off time at different phase angles) and the identification period T0, for both the three-phase four-wire system and the single-phase system, the overall identification time does not exceed half a period; through experiments, the dropdown timing should be more than 5 milliseconds (referring to the identification time of power failure, which can be used as the comparison time), that is, the identification time of a power failure is preferably 5 milliseconds.

[0103] It should be noted that the total time from the real-time voltage waveform abnormality to the controller giving a power-off signal is less than 10ms. Whether a power outage occurs can be determined in less than 10 milliseconds, and the identification speed is fast.

[0104] Example 3

[0105] As attached Figure 2 As shown, based on Example 1, this example provides a specific implementation of a system for quickly identifying power outages;

[0106] The power outage rapid identification system comprises a sampling management unit, a flag determination unit, a filtering management unit, a frequency calculation unit, a comparison waveform generation unit and a power outage determination unit, wherein:

[0107] The sampling management unit is used to continuously and uninterruptedly sample the real-time waveform data of the AC power supply to be tested at a preset sampling frequency, and for each phase of the real-time waveform data of the AC power supply to be tested, the sampled real-time waveform data is stored in a preset recursive array ac[] at each interval identification period T0, and a data recording completion flag is set;

[0108] The flag determination unit is used to determine whether the data recording completion flag is read, and in response to the read data recording completion flag, trigger the FIR low-pass filter logic;

[0109] The filter management unit is used to perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, and store them in a preset array fir[].

[0110] The frequency calculation unit is used to calculate the signal frequency of the discrete FIR data in the array fir[];

[0111] The comparison waveform generating unit is used to generate power-off voltage comparison waveform data and store the power-off voltage comparison waveform data into the array outstage[].

[0112] The power-off determination unit is used to compare the recursive array ac[] and the array outstage[], and to identify whether each phase of the AC power supply to be tested is in a power-off state according to the comparison result.

[0113] Furthermore, the filtering management unit is specifically used to call the library function of the ARM chip to perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to filter out high-order harmonics (3, 5, 7... harmonics), thereby preventing high-order harmonics (3, 5, 7... harmonics) components from interfering with the frequency calculation and improving the accuracy of the frequency calculation in step 3.

[0114] In a specific implementation, the library function is arm_fir_f32(&S, firIn, firOut, MaxSampleNum), where S represents the filter structure, firIn represents the sampled real-time waveform data, firOut represents the discrete FIR data of the real-time waveform data, and MaxSampleNum represents the length of the calculated data.

[0115] Further, the frequency calculation unit is specifically used to: after determining the number of interval sampling points N between two zero-crossing points of the discrete FIR data in the array fir[], obtain the time interval ΔT between the two zero-crossing points according to the preset sampling frequency f0; wherein ΔT=N / f0;

[0116] Based on the time interval ΔT, the signal frequency F of the discrete FIR data of the real-time waveform data in the fir[] array is calculated, where F=1 / (2×ΔT).

[0117] Furthermore, the comparison waveform generating unit is specifically used for:

[0118] Acquire the signal frequency calculated by the frequency calculation unit, and use the signal frequency as the frequency of the power-off voltage comparison waveform;

[0119] Based on the discrete FIR data of the real-time waveform data, the time interval DT from the last zero-crossing point to the starting sampling point is obtained; the group delay time t0 of the FIR filter is subtracted from the time interval DT to obtain the time interval DT' from the zero-crossing point corresponding to the real-time waveform to the starting sampling point; the phase angle corresponding to the current sampling point is calculated according to the time interval DT', and the phase angle is used as the phase angle of the power-off voltage comparison waveform;

[0120] Calculating the amplitude of the power-off voltage comparison waveform based on a preset power-off threshold;

[0121] Based on the frequency, phase angle and amplitude of the power-off voltage comparison waveform, power-off voltage comparison waveform data outstage is obtained.

[0122] Furthermore, the power-off determination unit is specifically configured to:

[0123] The identification time of this power outage starts counting;

[0124] Compare the power-off voltage in the array outstage[] corresponding to each sampling point and the absolute value of the waveform data with the waveform data in the recursive array ac[].

[0125] When the absolute value of the power-off voltage comparison waveform data in the array outstage[] is greater than the waveform data in the recursive array ac[], the power-off counting starts; if a zero-crossing interval is encountered, the comparison is not performed, the identification time is paused, and the power-off count value is saved. After the zero-crossing interval, the comparison and identification time are continued, and the counting is continued based on the saved power-off count value;

[0126] When the identification time of this power failure reaches the specified duration, the total number of power failures is counted;

[0127] It is determined whether the total power-off count is greater than a preset value. If so, it is determined that the corresponding phase in the AC power supply to be tested is in a power-off state; otherwise, the total power-off count is cleared.

[0128] Example 4

[0129] This embodiment provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the method for quickly identifying power failure as described above are implemented.

[0130] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0131] In the embodiments provided in the present application, it should be understood that the disclosed system can be implemented in other ways. For example, the system embodiments described above are only schematic, for example, the division of the above modules is only a logical function division, and there may be other division methods in actual implementation, such as multiple units can be combined or integrated into another system, or some features can be ignored or not executed.

[0132] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0133] If the above-mentioned integrated module is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The above-mentioned computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the above-mentioned computer program includes computer program code, and the above-mentioned computer program code can be in source code form, object code form, executable file or some intermediate form, etc.

[0134] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, ordinary technicians in the field should understand that the specific implementation methods of the present invention can still be modified or some technical features can be replaced by equivalents without departing from the spirit of the technical solution of the present invention, which should be included in the scope of the technical solution for protection of the present invention.

Claims

1. A method for quickly identifying power outages, characterized in that: The following steps are involved: Step 1, continuously and uninterruptedly sampling the real-time waveform data of the AC power supply to be tested at a preset sampling frequency, for each phase of the real-time waveform data in the AC power supply to be tested, at each interval identification period T0, the sampled real-time waveform data is stored in a preset recursive array ac[], and a data recording completion flag is set; Step 2, in response to the read data record completion flag, perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, and store them in a preset array fir[]. Step 3, calculating the signal frequency of the discrete FIR data in the array fir[]; Step 4, generate power-off voltage comparison waveform data, and store the power-off voltage comparison waveform data into the array outstage[]; In step 4, when generating the power-off voltage comparison waveform data, the following steps are performed: Obtain the signal frequency obtained in step 3, and use the signal frequency as the frequency of the power-off voltage comparison waveform; Based on the discrete FIR data of the real-time waveform data, the time interval DT from the last zero-crossing point to the starting sampling point is obtained; the group delay time t0 of the FIR filter is subtracted from the time interval DT to obtain the time interval DT' from the zero-crossing point corresponding to the real-time waveform to the starting sampling point; the phase angle corresponding to the current sampling point is calculated according to the time interval DT', and the phase angle is used as the phase angle of the power-off voltage comparison waveform; Calculating the amplitude of the power-off voltage comparison waveform based on a preset power-off threshold; Based on the frequency, phase angle and amplitude of the power-off voltage comparison waveform, obtaining power-off voltage comparison waveform data outstage; Step 5, compare the recursive array ac[] obtained in step 1 with the array outstage[] obtained in step 4, and identify whether each phase of the AC power supply to be tested is in a power-off state according to the comparison result.

2. The method for quickly identifying power outage according to claim 1, characterized in that: The step 5 comprises the following steps: Step 5.1, start counting the identification time of this power outage; Step 5.2, compare the absolute value of the power-off voltage comparison waveform data in the array outstage[] corresponding to each sampling point with the waveform data in the recursive array ac[]. When the absolute value of the power-off voltage comparison waveform data in the array outstage[] is greater than the waveform data in the recursive array ac[], the power-off counting starts; if a zero-crossing interval is encountered, the comparison is not performed, the identification time is paused, and the power-off count value is saved. After the zero-crossing interval, the comparison and identification time are continued, and the counting is continued based on the saved power-off count value; When the identification time of this power failure reaches the specified duration, the total number of power failures is counted; Step 5.3, determine whether the total power-off count is greater than a preset value, if so, determine that the corresponding phase in the tested AC power supply is in a power-off state; otherwise, clear the total power-off count to zero.

3. The method for quickly identifying power outage according to claim 2, characterized in that: When determining the zero-crossing interval, do the following: Determine the last zero-crossing point position of the power-off voltage comparison waveform data, and extract two sampling points before and after the zero-crossing point; The time point corresponding to one of the sampling points is taken as the minimum value of the zero-crossing interval, and the time point corresponding to the other sampling point is taken as the maximum value of the zero-crossing interval.

4. The method for rapid identification of power outage according to claim 1, characterized in that: The AC power supply to be tested is a three-phase four-wire AC power supply, and a recursive array ac[]_A, a recursive array ac[]_B and a recursive array ac[]_C, as well as an array fir[]_A, an array fir[]_B and an array fir[]_C, and an array outstage[]_A, an array outstage[]_B and an array outstage[]_C are preset; The recursive array ac[]_A is used to store the A-phase waveform data, the array fir[]_A is used to store the discrete FIR data of the A-phase waveform data, and the array outstage[]_A is used to store the power-off voltage comparison waveform data of the A-phase waveform data; based on the recursive array ac[]_A, the array fir[]_A and the array outstage[]_A, the A-phase power-off identification of the three-phase four-wire AC power supply is performed; The recursive array ac[]_B is used to store B-phase waveform data, the array fir[]_B is used to store discrete FIR data of the B-phase waveform data, and the array outstage[]_B is used to store power-off voltage comparison waveform data of the B-phase waveform data; based on the recursive array ac[]_B, the array fir[]_B and the array outstage[]_B, the B-phase power-off identification of the three-phase four-wire AC power supply is performed; The recursive array ac[]_C is used to store C-phase waveform data, the array fir[]_C is used to store discrete FIR data of the C-phase waveform data, and the array outstage[]_C is used to store power-off voltage comparison waveform data of the C-phase waveform data; based on the recursive array ac[]_C, the array fir[]_C and the array outstage[]_C, the C-phase power-off identification of the three-phase four-wire AC power supply is performed; The A-phase power failure identification logic of the three-phase four-wire AC power supply, the B-phase power failure identification logic of the three-phase four-wire AC power supply and the C-phase power failure identification logic of the three-phase four-wire AC power supply do not affect each other and can be performed simultaneously.

5. A rapid identification system for power outage, characterized in that: It includes a sampling management unit, a flag determination unit, a filtering management unit, a frequency calculation unit, a comparison waveform generation unit and a power-off determination unit, wherein: The sampling management unit is used to continuously and uninterruptedly sample the real-time waveform data of the AC power supply to be tested at a preset sampling frequency, and for each phase of the real-time waveform data of the AC power supply to be tested, the sampled real-time waveform data is stored in a preset recursive array ac[] at each interval identification period T0, and a data recording completion flag is set; The flag determination unit is used to determine whether the data recording completion flag is read, and in response to the read data recording completion flag, trigger the FIR low-pass filter logic; The filter management unit is used to perform FIR low-pass filtering on the real-time waveform data in the recursive array ac[] to obtain discrete FIR data of the real-time waveform data of each phase in the AC power supply to be tested, and store the data in a preset array fir[]. The frequency calculation unit is used to calculate the signal frequency of the discrete FIR data in the array fir[]; The comparison waveform generating unit is used to generate power-off voltage comparison waveform data and store the power-off voltage comparison waveform data into the array outstage[]. The comparison waveform generating unit is specifically used for: Acquire the signal frequency calculated by the frequency calculation unit, and use the signal frequency as the frequency of the power-off voltage comparison waveform; Based on the discrete FIR data of the real-time waveform data, the time interval DT from the last zero-crossing point to the starting sampling point is obtained; the group delay time t0 of the FIR filter is subtracted from the time interval DT to obtain the time interval DT' from the zero-crossing point corresponding to the real-time waveform to the starting sampling point; the phase angle corresponding to the current sampling point is calculated according to the time interval DT', and the phase angle is used as the phase angle of the power-off voltage comparison waveform; Calculating the amplitude of the power-off voltage comparison waveform based on a preset power-off threshold; Based on the frequency, phase angle and amplitude of the power-off voltage comparison waveform, obtaining power-off voltage comparison waveform data outstage; The power-off determination unit is used to compare the recursive array ac[] and the array outstage[], and to identify whether each phase of the AC power supply to be tested is in a power-off state according to the comparison result.

6. The rapid identification system for power outage according to claim 5, characterized in that: The power failure determination unit is specifically used for: The identification time of this power outage starts counting; Compare the power-off voltage in the array outstage[] corresponding to each sampling point and the absolute value of the waveform data with the waveform data in the recursive array ac[]. When the absolute value of the power-off voltage comparison waveform data in the array outstage[] is greater than the waveform data in the recursive array ac[], the power-off counting starts; if a zero-crossing interval is encountered, the comparison is not performed, the identification time is paused, and the power-off count value is saved. After the zero-crossing interval, the comparison and identification time are continued, and the counting is continued based on the saved power-off count value; When the identification time of this power failure reaches the specified duration, the total number of power failures is counted; It is determined whether the total power-off count is greater than a preset value. If so, it is determined that the corresponding phase in the AC power supply to be tested is in a power-off state; otherwise, the total power-off count is cleared.

7. A readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method for quickly identifying power failure according to any one of claims 1 to 4 are implemented.

Citation Information

Patent Citations

  • Motor and drive circuit and method therefor

    CN107465368A

  • Non-energy storage transient voltage support device and method with different-line power taking, and system of non-energy storage transient voltage support device

    CN110380508A

  • PWM power supplies using controlled feedback timing and methods of operating same

    US20040046456A1

  • Apparatus and method for controlling a transfer switch mechanism

    US20080100248A1