Voltage sag detection method and apparatus, electronic device, and storage medium
By combining a composite voltage sag detection technology with an all-pass filter, a band-stop filter, and a low-pass filter, the accuracy problem of voltage sag detection under multiple operating conditions is solved, ensuring stable power supply to the UPS system under extreme conditions and reducing economic losses caused by voltage sags.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGZHOU ZHIGUANG ELECTRIC CO LTD
- Filing Date
- 2022-04-27
- Publication Date
- 2026-06-09
AI Technical Summary
Existing technologies struggle to detect voltage dips quickly and accurately under various operating conditions, especially under extreme conditions, leading to power quality issues that affect the stable operation of industries such as semiconductors, data centers, and smart manufacturing.
A composite voltage sag detection technology combining a first voltage sag detection module and a second voltage sag detection module is adopted. Through the combination of a full-pass filter, a band-stop filter and a low-pass filter, and synchronous rotating coordinate transformation, the multi-condition detection of grid voltage is realized, including single-phase, two-phase and three-phase grid voltage drops, as well as grid voltage phase shifts and flips.
It achieves fast and accurate voltage sag detection under various operating conditions, and can even effectively detect voltage dips under extreme conditions, ensuring that the energy storage UPS system can quickly switch power supply modes when the grid voltage dips, thereby reducing economic losses.
Smart Images

Figure CN114814341B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of power grid voltage fluctuation detection technology, and in particular to a voltage sag detection method, device, electronic equipment, and storage medium. Background Technology
[0002] As more and more applications, such as chip semiconductors, data centers, and smart manufacturing, require high power supply stability, the market size of uninterruptible power supplies (UPS) is also expanding accordingly.
[0003] Energy storage UPS systems can ensure a stable power supply to electrical facilities, and can also be connected to the grid to participate in peak shaving and valley filling. This can reduce the cost of energy storage UPS systems and optimize their configuration, giving them huge market potential.
[0004] Voltage sags are a major power quality issue faced by industries such as semiconductors, data centers, and smart manufacturing. However, given the randomness and rapidity of voltage sags, achieving rapid and accurate detection is a key technical challenge for energy storage UPS systems. Summary of the Invention
[0005] This application provides a voltage sag detection method, apparatus, electronic device, and storage medium to achieve accurate detection of voltage sags under multiple operating conditions.
[0006] The embodiments of this application adopt the following technical solutions:
[0007] In a first aspect, embodiments of this application provide a voltage sag detection method for an energy storage UPS system. The method includes: detecting a first voltage sag result using a first voltage sag detection module when the grid voltage drops or the grid voltage undergoes a phase change; detecting a second voltage sag result using a second voltage sag detection module when the grid voltage drops or the grid voltage undergoes a phase change; and performing logical operations on the first voltage sag result and the second voltage sag result to obtain a final voltage sag detection result.
[0008] Secondly, embodiments of this application also provide a voltage sag detection device, which is used in an energy storage UPS system. The device includes: a first voltage sag detection module, used to detect a first voltage sag result when the grid voltage drops or the grid voltage undergoes a phase change; a second voltage sag detection module, used to detect a second voltage sag result when the grid voltage drops or the grid voltage undergoes a phase change; and a voltage sag detection result output module, used to perform logical operations on the first voltage sag result and the second voltage sag result to obtain a final voltage sag detection result.
[0009] Thirdly, embodiments of this application also provide an electronic device, including: a processor; and a memory arranged to store computer-executable instructions, which, when executed, cause the processor to perform the above-described method.
[0010] Fourthly, embodiments of this application also provide a computer-readable storage medium that stores one or more programs, which, when executed by an electronic device including multiple applications, cause the electronic device to perform the above-described method.
[0011] The above-described technical solutions adopted in the embodiments of this application can achieve the following beneficial effects:
[0012] The first voltage sag detection module and the second voltage sag detection module obtain a first voltage sag result and a second voltage sag result, respectively. Logical operations are then performed on the first and second voltage sag results to obtain the final voltage sag detection result. This enables accurate voltage sag detection under multiple operating conditions. Attached Figure Description
[0013] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0014] Figure 1 This is a schematic flowchart of the voltage sag detection method in the embodiments of this application;
[0015] Figure 2 This is a schematic diagram of the voltage sag detection device in the embodiments of this application;
[0016] Figure 3 This is a schematic diagram of the energy storage UPS system in the embodiments of this application;
[0017] Figure 4 This is a schematic diagram illustrating the voltage sag detection implementation principle in the embodiments of this application;
[0018] Figures 5(a) and 5(b) show the three-phase grid voltage U when the phase a voltage drops to 0.895 times the rated grid voltage in the embodiment of this application using the voltage sag detection method. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0019] Figures 6(a) and 6(b) show the three-phase grid voltage U when the voltage of phases a and b drops to 0.895 times the rated grid voltage in the embodiments of this application, using the voltage sag detection method. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0020] Figures 7(a) and 7(b) show the three-phase grid voltage U when the voltage of phases a, b, and c drops to 0.895 times the rated grid voltage in the embodiments of this application, using the voltage sag detection method. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0021] Figures 8(a) and 8(b) show the three-phase grid voltage U when the voltage of phase a drops to 0 under the voltage sag detection method in the embodiment of this application. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0022] Figures 9(a) and 9(b) show the three-phase grid voltage U when phases a and b drop to 0 under voltage sag detection in the embodiments of this application. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0023] Figures 10(a) and 10(b) show the three-phase grid voltage U when the voltage of phases a, b, and c drops to 0 under the voltage sag detection method in the embodiments of this application. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0024] Figures 11(a) and 11(b) show the three-phase grid voltage U when the voltage sag detection method is used under the condition of 90° voltage deviation of phase a in the embodiments of this application. ga U gb U gc A waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0025] Figures 12(a) and 12(b) show the voltage reversal of phase a by 180° in the embodiment of this application. 0 Three-phase grid voltage U under operating conditions using voltage sag detection method ga U gb U gcA waveform diagram of the voltage sag detection result (Sag) from the mains grid.
[0026] Figure 13 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Detailed Implementation
[0027] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0028] As the core of the information technology industry, the semiconductor industry is a fundamental and leading industry supporting national economic and social development. The semiconductor industry belongs to the high-end manufacturing sector, using a large number of high-precision instruments and equipment, making it highly susceptible to power quality issues. Power quality problems leading to equipment downtime can cause direct and indirect economic losses of up to hundreds of millions of yuan. Furthermore, with the development of 5G and the Industrial Internet, the internet is further integrating with traditional industries, and data centers will become a fundamental and leading industry for various sectors. Data centers have extremely high requirements for power quality; power quality problems causing equipment downtime and business interruptions can result in huge losses for enterprises. In addition, the intelligent manufacturing industry has flourished in recent years under the impetus of industry trends and national policies, becoming an important tool for the country to build a manufacturing powerhouse. The intelligent manufacturing industry involves continuous production processes; production stoppages due to power quality problems incur enormous downtime costs. Therefore, voltage sags and voltage interruptions are the most significant power quality problems faced by the semiconductor, data center, and intelligent manufacturing industries.
[0029] During their research, the inventors discovered that energy storage UPS systems, while ensuring stable power supply to electrical facilities, can also participate in peak shaving and valley filling by connecting to the grid. This reduces the cost of energy storage UPS systems and optimizes their configuration, giving them enormous market potential. The main technical challenge facing energy storage UPS systems is the rapid and accurate detection of voltage dips under various operating conditions, thereby minimizing the economic losses caused by voltage dips.
[0030] Furthermore, much research has been conducted on voltage sag detection in related technologies. Among some methods, a three-phase voltage sag detection method has been disclosed. This method uses an equivalent filter network to filter the output of the conventional dq algorithm, avoiding harmonic amplification and achieving rapid tracking and detection of the grid voltage.
[0031] Among other methods, a voltage sag detection method based on a synchronous rotating coordinate system is proposed. This method cancels the second harmonic component generated by the synchronous rotating coordinate transformation under three-phase unbalanced voltage sag conditions by using differentiation, thereby realizing the detection of voltage drops in any phase.
[0032] Other methods disclose a fast detection method for grid voltage dips based on phase shift. This method constructs three new sets of symmetrical three-phase voltages by delaying the phase of an all-pass filter, and uses the conventional dq algorithm to quickly determine the asymmetrical three-phase voltage dips of the grid.
[0033] In other methods, voltage sag detection results are prone to deviation and inaccuracy when the grid voltage experiences phase shift or phase reversal. Furthermore, this method cannot effectively detect voltage sags under extreme conditions, i.e., when the grid voltage of any phase drops to 0.895 times the rated grid voltage.
[0034] Other methods include a voltage sag detection method based on a synchronous rotating coordinate system. However, this method uses differential operations and is sensitive to voltage harmonics. When the three-phase grid voltage drops simultaneously or when the grid voltage experiences phase shift or phase reversal, the sag detection results are prone to deviation and inaccuracy.
[0035] In addition, some methods are ineffective in detecting phase shifts or phase reversals in the grid voltage.
[0036] In response, the embodiments of this application provide a multi-condition voltage sag detection method based on an energy storage UPS system, which can quickly and accurately detect voltage sags under various operating conditions.
[0037] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.
[0038] This application provides a method for detecting voltage sags, such as... Figure 1 The diagram shows a schematic flow chart of a voltage sag detection method in an embodiment of this application. The method includes at least the following steps S110 to S140:
[0039] Step S110: When the grid voltage drops or the grid voltage phase changes, the first voltage sag detection module detects the first voltage sag result.
[0040] The phase shifting in the above-mentioned method can be achieved through a full-pass filter. Since it is not sensitive to voltage harmonics and adopts a filtering method that combines a band-stop filter and a low-pass filter, the voltage sag detection results are more accurate when the three-phase grid voltage drops simultaneously or when the grid voltage experiences phase shift or phase reversal.
[0041] The first voltage sag detection module includes, but is not limited to, a combination of a full-pass filter, a band-stop filter, and a low-pass filter, and the output of the first voltage sag detection module is then compared.
[0042] Step S120: When the grid voltage drops or the grid voltage phase changes, the second voltage sag detection module detects the second voltage sag result.
[0043] The second voltage sag detection module uses a full-pass filter to virtually generate three sets of three-phase grid voltages based on the A, B, and C phase grid voltages. The voltage amplitudes of the A, B, and C phase grids are obtained through synchronous rotating coordinate transformation and low-pass filtering, and then the second voltage sag result is detected.
[0044] Step S130: Perform logical operations on the first voltage sag result and the second voltage sag result to obtain the final voltage sag detection result.
[0045] In this step, the final voltage sag detection result of the grid voltage can be obtained by performing related logical operations on the first grid voltage sag detection result and the second grid voltage sag detection result.
[0046] In some embodiments, the method further includes: controlling a fast switch in the energy storage UPS system to disconnect the power grid based on the final voltage sag detection result; and controlling the energy storage UPS system to supply power to the load for continuous power supply in the power grid voltage sag mode.
[0047] In specific implementation, such as Figure 3 The diagram shown is a block diagram of an energy storage UPS system. When the grid voltage drops or is interrupted, the system quickly identifies and controls the fast switch to disconnect the grid using the voltage sag detection algorithm provided in this application. At the same time, it controls the energy storage UPS system to supply power to the load, so as to achieve high-quality, continuous and stable power supply under grid voltage sag mode.
[0048] Preferably, the grid voltage drop includes at least one of the following conditions: single-phase grid voltage drop, two-phase grid voltage drop, and three-phase grid voltage drop, and the grid voltage phase change includes one of the following conditions: grid voltage phase shift and grid voltage phase reversal.
[0049] Preferably, the method further includes: voltage sag detection for any one or more extreme operating conditions where the single-phase grid voltage drops to 0.895 times the rated grid voltage, the two-phase grid voltage drops to 0.895 times the rated grid voltage, and the three-phase grid voltage drops to 0.895 times the rated grid voltage. 0.9 is a commonly preset multiple of the rated grid voltage threshold. That is, even under extreme operating conditions such as a single-phase grid voltage dropping to 0.895 times the rated grid voltage, a two-phase grid voltage dropping to 0.895 times the rated grid voltage, and a three-phase grid voltage dropping to 0.895 times the rated grid voltage, the method of this application can still accurately and effectively detect grid voltage sags.
[0050] Based on the above, the method of this application employs a composite voltage sag detection technology combining a first voltage sag detection module and a second voltage sag detection module. This technology can rapidly and accurately detect voltage sags under various operating conditions, including single-phase grid voltage dips, two-phase grid voltage dips, three-phase grid voltage dips, grid voltage phase shifts, and grid voltage phase reversals. Furthermore, it can even accurately and effectively detect voltage sags under extreme operating conditions such as single-phase grid voltage dips to 0.895 times the rated grid voltage, two-phase grid voltage dips to 0.895 times the rated grid voltage, and three-phase grid voltage dips to 0.895 times the rated grid voltage.
[0051] In one embodiment of this application, the grid voltage includes three-phase grid voltage. A first voltage sag detection module detects a first voltage sag result when the grid voltage drops or undergoes a phase change. This includes: passing the q-axis component of the three-phase grid voltage through an all-pass filter to obtain a target q-axis component of the three-phase grid voltage after a preset phase shift, and superimposing it with the d-axis component of the three-phase grid voltage to obtain the target amplitude of the three-phase grid voltage; inputting the target amplitude of the three-phase grid voltage into a band-stop filter, and obtaining a first amplitude of the three-phase grid voltage after filtering; inputting the first amplitude of the three-phase grid voltage into a low-pass filter, and obtaining a second amplitude of the three-phase grid voltage after filtering; comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold to detect the first voltage sag result.
[0052] In specific implementation, the step of passing the q-axis component of the three-phase grid voltage through an all-pass filter to obtain the target q-axis component of the three-phase grid voltage after preset phase shifting, and then superimposing it with the d-axis component of the three-phase grid voltage to obtain the target voltage amplitude of the three-phase grid voltage, specifically involves: transforming the actual value U of the three-phase grid voltage sampled in the preprocessing step into a synchronous rotating coordinate transformation. ga U gb U gc Transformation of the three-phase grid voltage d-axis component U in a rotating coordinate system gd and the q-axis component of the three-phase power grid voltage Ugq ,
[0053] Preferably, the calculation formula is:
[0054]
[0055] It should be noted that the preprocessing includes, but is not limited to:
[0056] First, sample the actual value of the three-phase grid voltage and record it as U. ga U gb U gc ;
[0057] Then, for the sampled actual value U of the three-phase grid voltage ga U gb U gc To obtain the phase θ of the three-phase grid voltage through phase-locked loop, in order to minimize the delay caused by the filtering stage, the PLL phase-locked loop adopts a single synchronous coordinate system software phase-locked loop.
[0058] Then, the actual value U of the sampled three-phase grid voltage is transformed by synchronous rotating coordinate transformation. ga U gb U gc Transformation of the three-phase grid voltage d-axis component U in a rotating coordinate system gd and the q-axis component of the three-phase power grid voltage U gq The following formula can be used for calculation:
[0059]
[0060] The step of inputting the target amplitude of the three-phase grid voltage into a band-stop filter, and obtaining the first amplitude of the three-phase grid voltage after filtering, specifically includes:
[0061] The q-axis component U of the three-phase grid voltage is obtained by passing a full-pass filter. gq The q-axis component U of the three-phase grid voltage after a 90° phase shift is obtained. gq1 The purpose of using a full-pass filter for phase shifting is to avoid the influence of voltage harmonics on the sag detection results and ensure the accuracy of the sag detection results.
[0062] Preferably, the all-pass filter transfer function H is used apf1(s) The expression is:
[0063]
[0064] Where ω apf1 =200π;
[0065] Then, it is also necessary to shift the q-axis component U of the three-phase grid voltage after a 90° phase shift. gq1The obtained three-phase grid voltage d-axis component U gd The three-phase power grid voltage amplitude U is obtained by superposition. gm .
[0066] Finally, the obtained three-phase grid voltage amplitude U gm The three-phase grid voltage amplitude U after band-stop filtering is obtained by filtering out harmonics using a band-stop filter. gm1 The purpose of using a band-stop filter is to filter out as much of the material as possible. Preferably, the transfer function H of the band-stop filter used is... bsf1(s) The expression is:
[0067]
[0068] Where ω bsf1 =600π, B p1 =83π;
[0069] The step of inputting the first amplitude of the three-phase grid voltage into a low-pass filter, and obtaining the second amplitude of the three-phase grid voltage after filtering, specifically includes:
[0070] The obtained three-phase grid voltage amplitude U after band-stop filtering gm1 The higher harmonics are further filtered out by a low-pass filter to obtain the three-phase grid voltage amplitude U after band-stop-low-pass filtering. gm2 .
[0071] Preferably, the low-pass filter used is a Butterworth low-pass filter. To minimize filter delay, a first-order Butterworth low-pass filter is used, with a transfer function H. lpf1(s) The expression is:
[0072]
[0073] Where ω lpf1 =200π;
[0074] Finally, by comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold, the first voltage sag result is detected. That is, the three-phase grid voltage amplitude U after band-stop-low-pass filtering... gm2 The voltage sag detection result Sag1 under voltage sag detection module 1 is obtained by comparing it with the threshold of the grid voltage sag.
[0075] In one embodiment of this application, the step of comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold and detecting the first voltage sag result includes: when the second amplitude of the three-phase grid voltage is less than the preset three-phase grid voltage sag threshold, the first voltage sag result is detected as 1, indicating that a grid voltage sag has occurred; when the second amplitude of the three-phase grid voltage is greater than or equal to the preset three-phase grid voltage sag threshold, the first voltage sag result is detected as 0, indicating that no grid voltage sag has occurred.
[0076] In practice, the threshold for grid voltage sag is typically chosen to be 90% of the rated grid voltage amplitude. gm2 When the voltage is below the threshold of the mains voltage sag, Sag1 = 1, and a mains voltage sag occurs; when U gm2 When the voltage sag is greater than or equal to the threshold of the grid voltage sag, Sag1 = 0, indicating that no grid voltage sag has occurred.
[0077] In one embodiment of this application, the grid voltage includes three-phase grid voltages of phase A, phase B, and phase C. A second voltage sag detection module detects a second voltage sag result when the grid voltage drops or undergoes a phase change. This includes: passing the sampled actual value of the phase A grid voltage through an all-pass filter to obtain a phase-shifted actual value of the phase A grid voltage; constructing a virtual three-phase grid voltage based on the phase A grid voltage using the phase A grid voltage as a reference; and obtaining the result based on the virtual three-phase grid voltage using the phase A grid voltage as a reference. The third amplitude of the three-phase grid voltage is obtained; the third amplitude of the three-phase grid voltage is input into a low-pass filter, and the fourth amplitude of the three-phase grid voltage is obtained after filtering; the fourth amplitude of the three-phase grid voltage is compared with a preset three-phase grid voltage sag threshold to detect the second voltage sag result of the A-phase grid voltage; similarly, the second voltage sag result of the B-phase grid voltage and the second voltage sag result of the C-phase grid voltage are detected; the second voltage sag result of the A-phase grid voltage, the B-phase grid voltage, and the C-phase grid voltage are logically operated to obtain the second voltage sag result.
[0078] In practice, the actual value of the three-phase power grid voltage is sampled and recorded as U. ga U gb U gc The actual value U of the sampled phase A grid voltage is filtered through an all-pass filter. ga The actual value U of the A-phase grid voltage after a 90° phase shift is obtained. ga1 .
[0079] Based on the sampled actual value of phase A grid voltage U gaThe actual value of the A-phase grid voltage U after a 90° phase shift ga1 A virtual three-phase grid voltage U is constructed based on the A-phase grid voltage. aga U agb U agc .
[0080] Furthermore, the virtual three-phase grid voltage U constructed above, based on the A-phase grid voltage, is transformed using synchronous rotating coordinate transformation. aga U agb U agc Transformed into a virtual three-phase grid voltage d-axis component U based on the A-phase grid voltage in a rotating coordinate system agd and the q-axis component of the virtual three-phase grid voltage U agq .
[0081] The virtual three-phase grid voltage d-axis component U, obtained from the above steps and based on the A-phase grid voltage, is... agd and the q-axis component of the virtual three-phase grid voltage U agq The amplitude U of the A-phase grid voltage was obtained through calculation. agm .
[0082] The amplitude U of the obtained phase A grid voltage agm The high-order harmonics are filtered out by a low-pass filter to obtain the low-pass filtered A-phase grid voltage amplitude U. agm1 The low-pass filter used is a Butterworth low-pass filter. To minimize filter delay, a first-order Butterworth low-pass filter is employed.
[0083] The voltage amplitude U of phase A of the power grid after low-pass filtering agm1 The voltage sag detection result Sag_a for phase A is obtained by comparing it with the threshold of the grid voltage sag. The threshold of the grid voltage sag is usually selected as 90% of the rated grid voltage amplitude. When U agm1 When the voltage is below the threshold for a grid voltage sag, Sag_a = 1, and a grid voltage sag occurs; when U agm1 When the voltage sag is greater than or equal to the threshold of the grid voltage sag, Sag_a = 0, and no grid voltage sag has occurred.
[0084] Following the same method as phase A, the voltage sag detection results for phase B (Sag_b) and phase C (Sag_c) can be obtained. These results are then logically ORed with the previously obtained voltage sag detection result for phase A (Sag_a) to obtain the voltage sag detection result for phase B (Sag_b) under voltage sag detection module 2 (Sag_c).
[0085] This application embodiment also provides a voltage sag detection device 200, such as Figure 2The diagram shows a schematic of the voltage sag detection device in an embodiment of this application. The voltage sag detection device 200 includes at least: a first voltage sag detection module 210, a second voltage sag detection module 220, and a voltage sag detection result output module 230, wherein:
[0086] The first voltage sag detection module 210 is used to detect the first voltage sag result when the grid voltage drops or the grid voltage phase changes.
[0087] The second voltage sag detection module 220 is used to detect the second voltage sag result when the grid voltage drops or the grid voltage phase changes.
[0088] The voltage sag detection result output module 230 is used to perform logical operations on the first voltage sag result and the second voltage sag result to obtain the final voltage sag detection result.
[0089] In one embodiment of this application, the first voltage sag detection module 210 is specifically used to: perform phase shifting through a full-pass filter. Since it is not sensitive to voltage harmonics and adopts a filtering method combining a band-stop filter and a low-pass filter, the voltage sag detection result is more accurate when the three-phase grid voltage drops simultaneously or when the grid voltage experiences phase shift or phase reversal.
[0090] The first voltage sag detection module includes, but is not limited to, a combination of a full-pass filter, a band-stop filter, and a low-pass filter, and the output of the first voltage sag detection module is then compared.
[0091] In one embodiment of this application, the second voltage sag detection module 220 is specifically used to: virtually generate three sets of three-phase grid voltages based on the A, B, and C phase grid voltages through an all-pass filter, obtain the A, B, and C phase grid voltage amplitudes through synchronous rotating coordinate transformation and low-pass filtering, and then detect the second voltage sag result.
[0092] In one embodiment of this application, the voltage sag detection result output module 230 is specifically used to: obtain the final voltage sag detection result of the power grid voltage by performing related logical operations on the first power grid voltage sag detection result and the second power grid voltage sag detection result in the step.
[0093] Preferably, the grid voltage drop includes at least one of the following conditions: single-phase grid voltage drop, two-phase grid voltage drop, and three-phase grid voltage drop, and the grid voltage phase change includes one of the following conditions: grid voltage phase shift and grid voltage phase reversal.
[0094] Preferably, the method further includes: voltage sag detection for any one or more extreme operating conditions where the single-phase grid voltage drops to 0.895 times the rated grid voltage, the two-phase grid voltage drops to 0.895 times the rated grid voltage, and the three-phase grid voltage drops to 0.895 times the rated grid voltage. 0.9 is a commonly preset multiple of the rated grid voltage threshold. That is, even under extreme operating conditions such as a single-phase grid voltage dropping to 0.895 times the rated grid voltage, a two-phase grid voltage dropping to 0.895 times the rated grid voltage, and a three-phase grid voltage dropping to 0.895 times the rated grid voltage, the method of this application can still accurately and effectively detect grid voltage sags.
[0095] Based on the above, the method of this application employs a composite voltage sag detection technology combining a first voltage sag detection module and a second voltage sag detection module. This technology can rapidly and accurately detect voltage sags under various operating conditions, including single-phase grid voltage dips, two-phase grid voltage dips, three-phase grid voltage dips, grid voltage phase shifts, and grid voltage phase reversals. Furthermore, it can even accurately and effectively detect voltage sags under extreme operating conditions such as single-phase grid voltage dips to 0.895 times the rated grid voltage, two-phase grid voltage dips to 0.895 times the rated grid voltage, and three-phase grid voltage dips to 0.895 times the rated grid voltage.
[0096] It is understood that the voltage sag detection device described above can implement each step of the voltage sag detection device method provided in the foregoing embodiments. The relevant explanations of the voltage sag detection method are applicable to the voltage sag detection device, and will not be repeated here.
[0097] To better understand the above voltage sag detection method, the following explanation of the technical solution is provided in conjunction with preferred embodiments, but it is not intended to limit the technical solution of the embodiments of the present invention.
[0098] like Figure 4 The diagram shown is a block diagram of the voltage sag detection principle, which includes three parts: voltage sag detection module 1, voltage sag detection module 2, and voltage sag detection result output.
[0099] Specifically, the voltage sag detection module 1 includes the following calculation steps:
[0100] Step 1: Sample the actual value of the three-phase grid voltage and record it as U. ga U gb U gc ;
[0101] Step 2, the actual value U of the three-phase grid voltage sampled in Step 1 ga U gb U gcTo obtain the phase θ of the three-phase grid voltage through phase-locked loop, in order to minimize the delay caused by the filtering stage, the PLL phase-locked loop adopts a single synchronous coordinate system software phase-locked loop.
[0102] Step 3: Transform the actual three-phase grid voltage U sampled in Step 1 into synchronous rotating coordinates. ga U gb U gc Transformation of the three-phase grid voltage d-axis component U in a rotating coordinate system gd and the q-axis component of the three-phase power grid voltage U gq The formula for its calculation is:
[0103]
[0104] Step 4: The q-axis component U of the three-phase grid voltage obtained in Step 3 is filtered through an all-pass filter. gq The q-axis component U of the three-phase grid voltage after a 90° phase shift is obtained. gq1 The purpose of using a phase-shifting all-pass filter is to avoid the influence of voltage harmonics on the sag detection results and ensure the accuracy of the sag detection results. The transfer function H of the all-pass filter used is... apf1 The expression for (s) is:
[0105]
[0106] Where ω apf1 =200π;
[0107] Step 5, convert the q-axis component U of the three-phase grid voltage obtained in Step 4 after a 90° phase shift. gq1 The d-axis component U of the three-phase grid voltage obtained in step 3 gd The three-phase power grid voltage amplitude U is obtained by superposition. gm ;
[0108] Step 6, convert the three-phase grid voltage amplitude U obtained in step 5 to... gm The third-phase grid voltage amplitude U is obtained by filtering out the 6th harmonic using a band-stop filter. gm1 The reason is that the actual power grid mainly contains 5th and 7th harmonics, which are transformed into 6th harmonics after synchronous rotating coordinate transformation. The purpose of using a band-stop filter is to filter them out as much as possible. The transfer function of the band-stop filter used is H. bsf1 The expression for (s) is:
[0109]
[0110] Where ω bsf1 =600π, B p1 =83π;
[0111] Step 7: Calculate the amplitude U of the three-phase grid voltage after band-stop filtering obtained in Step 6. gm1 The higher harmonics are further filtered out by a low-pass filter to obtain the three-phase grid voltage amplitude U after band-stop-low-pass filtering. gm2 The low-pass filter used is a Butterworth low-pass filter. To minimize filter delay, a first-order Butterworth low-pass filter is employed, with a transfer function H. lpf1 The expression for (s) is:
[0112]
[0113] Where ω lpf1 =200π;
[0114] Step 8, convert the three-phase grid voltage amplitude U obtained in step 7 after band-stop-low-pass filtering. gm2 The voltage sag detection result Sag1 under voltage sag detection module 1 is obtained by comparing it with the threshold of the grid voltage sag. The threshold of the grid voltage sag is usually selected as 90% of the rated grid voltage amplitude. When U gm2 When the voltage is below the threshold of the mains voltage sag, Sag1 = 1, and a mains voltage sag occurs; when U gm2 When the voltage sag is greater than or equal to the threshold of the grid voltage sag, Sag1 = 0, indicating that no grid voltage sag has occurred.
[0115] The voltage sag detection module 2 includes:
[0116] Step 1: Sample the actual value of the three-phase grid voltage and record it as U. ga U gb U gc ;
[0117] Step 2: The actual value U of the A-phase grid voltage sampled in Step 1 is filtered through an all-pass filter. ga The actual value U of the A-phase grid voltage after a 90° phase shift is obtained. ga1 The transfer function H of the all-pass filter used apf2 The expression for (s) is:
[0118]
[0119] Where ω apf2 =100π;
[0120] Step 3, based on the actual value U of the A-phase grid voltage sampled in Step 1. ga The actual value U of the A-phase grid voltage after a 90° phase shift obtained in step 2. ga1 A virtual three-phase grid voltage U is constructed based on the A-phase grid voltage. aga U agb Uagc The construction formula used is:
[0121]
[0122] Step 4: Transform the virtual three-phase grid voltage U constructed in Step 3, which is based on the A-phase grid voltage, into a synchronous rotating coordinate system. aga U agb U agc Transformed into a virtual three-phase grid voltage d-axis component U based on the A-phase grid voltage in a rotating coordinate system agd and the q-axis component of the virtual three-phase grid voltage U agq The formula for its calculation is:
[0123]
[0124] Step 5: Calculate the d-axis component U of the virtual three-phase grid voltage obtained in Step 4, based on the A-phase grid voltage. agd and the q-axis component of the virtual three-phase grid voltage U agq The amplitude U of the A-phase grid voltage was obtained through calculation. agm The formula for its calculation is:
[0125]
[0126] Step 6, take the amplitude U of the A-phase grid voltage obtained in Step 5. agm The high-order harmonics are filtered out by a low-pass filter to obtain the low-pass filtered A-phase grid voltage amplitude U. agm1 The low-pass filter used is a Butterworth low-pass filter. To minimize filter delay, a first-order Butterworth low-pass filter is employed, with a transfer function H. lpf2 The expression for (s) is:
[0127]
[0128] Where ω lpf2 =260π;
[0129] Step 7: Calculate the low-pass filtered A-phase grid voltage amplitude U obtained in Step 6. agm1 The voltage sag detection result Sag_a for phase A is obtained by comparing it with the threshold of the grid voltage sag. The threshold of the grid voltage sag is usually selected as 90% of the rated grid voltage amplitude. When U agm1 When the voltage is below the threshold for a grid voltage sag, Sag_a = 1, and a grid voltage sag occurs; when U agm1 When the voltage sag is greater than or equal to the threshold of the grid voltage sag, Sag_a = 0, and no grid voltage sag has occurred.
[0130] Step 8: Following the same steps as phase A (steps 2-7), the voltage sag detection results of phase B grid Sag_b and phase C grid Sag_c can be obtained. These results are then logically ORed with the voltage sag detection result of phase A grid Sag_a obtained in step 7 to obtain the voltage sag detection result of grid Sag2 under voltage sag detection module 2.
[0131] The voltage sag detection result output includes:
[0132] The grid voltage sag detection result Sag1 under voltage sag detection module 1 and the grid voltage sag detection result Sag2 under voltage sag detection module 2 are logically ORed to obtain the grid voltage sag detection result Sag under this method.
[0133] The results of specific experiments based on the above voltage sag detection method include:
[0134] Figure 5(a) , 5(b) The three-phase grid voltage U is the voltage U when phase a voltage drops to 0.895 times the rated grid voltage in the embodiments of this application, using the voltage sag detection method. ga U gb U gc The waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can effectively detect grid voltage sags, and the detection time is 7.25ms.
[0135] Figure 6(a) , 6(b) The three-phase grid voltage U is the voltage U when the voltages of phases a and b drop to 0.895 times the rated grid voltage in the embodiments of this application, using the voltage sag detection method. ga U gb U gc The waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can effectively detect grid voltage sags, and the detection time is 7.25ms.
[0136] Figure 7(a) , 7(b) The three-phase grid voltage U when the voltages of phases a, b, and c drop to 0.895 times the rated grid voltage in the embodiments of this application, using the voltage sag detection method. ga U gb U gcThe waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can effectively detect grid voltage sags, and the detection time is 4.125ms.
[0137] Figure 8(a) , 8(b) In this embodiment, the three-phase grid voltage U is used when the voltage sag detection method is applied under the condition that the voltage of phase a drops to 0. ga U gb U gc The waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can quickly and effectively detect grid voltage sags with a detection time of 0.375ms.
[0138] Figure 9(a) , 9(b) The three-phase grid voltage U is the voltage U when phases a and b drop to 0 in the embodiments of this application, and voltage sag detection is used. ga U gb U gc The waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can quickly and effectively detect grid voltage sags with a detection time of 0.375ms.
[0139] Figure 10(a) , 10(b) The three-phase grid voltage U is the voltage sag detection method used when the voltages of phases a, b, and c drop to 0 in the embodiments of this application. ga U gb U gc The waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can quickly and effectively detect grid voltage sags with a detection time of 0.25ms.
[0140] Figure 11(a) , 11(b) The three-phase grid voltage U is the voltage sag detection method used when phase a voltage deviation is 90° in the embodiments of this application. ga U gb U gcThe waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can quickly and effectively detect grid voltage sags with a detection time of 0.375ms.
[0141] Figure 12(a) , 12(b) In this embodiment of the application, the voltage of phase a is flipped 180°. 0 Three-phase grid voltage U under operating conditions using voltage sag detection method ga U gb U gc The waveform diagram of the grid voltage sag detection result Sag is shown. In the simulation, the fundamental effective value of the three-phase grid line voltage is 400V, containing 2% of the 5th harmonic and 2% of the 7th harmonic. The sampling frequency of the three-phase grid voltage is 8kHz. This method can quickly and effectively detect grid voltage sags with a detection time of 0.25ms.
[0142] Figure 13 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Please refer to it. Figure 13 At the hardware level, the electronic device includes a processor, and optionally also includes an internal bus, a network interface, and memory. The memory may include main memory, such as high-speed random-access memory (RAM), or non-volatile memory, such as at least one disk drive. Of course, the electronic device may also include other hardware required for other business operations.
[0143] The processor, network interface, and memory can be interconnected via an internal bus, which can be an ISA (Industry Standard Architecture) bus, a PCI (Peripheral Component Interconnect) bus, or an EISA (Extended Industry Standard Architecture) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 13 The symbol is represented by a single double-headed arrow, but this does not mean that there is only one bus or one type of bus.
[0144] Memory is used to store programs. Specifically, programs may include program code, which includes computer operation instructions. Memory may include main memory and non-volatile memory, and provides instructions and data to the processor.
[0145] The processor reads the corresponding computer program from non-volatile memory into main memory and then runs it, forming a voltage sag detection device at the logical level. The processor executes the program stored in memory and specifically performs the following operations:
[0146] The first voltage sag detection module detects the first voltage sag result when the grid voltage drops or the grid voltage phase changes.
[0147] The second voltage sag detection module detects the second voltage sag result when the grid voltage drops or the grid voltage phase changes.
[0148] The first voltage sag result and the second voltage sag result are logically processed to obtain the final voltage sag detection result.
[0149] The above is as stated in this application. Figure 1 The method executed by the voltage sag detection device disclosed in the illustrated embodiment can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by integrated logic circuits in the processor's hardware or by instructions in software form. The processor can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), etc.; it can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly embodied as being executed by a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software module can reside in a mature storage medium in the field, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, or registers. This storage medium is located in memory, and the processor reads information from the memory and, in conjunction with its hardware, completes the steps of the above method.
[0150] The electronic device can also perform Figure 1The method for implementing a voltage sag detection device, and the realization of the voltage sag detection device in... Figure 1 The functions of the embodiments shown are not described in detail here.
[0151] This application also proposes a computer-readable storage medium that stores one or more programs, the programs including instructions that, when executed by an electronic device including multiple applications, enable the electronic device to perform... Figure 1 The method executed by the voltage sag detection device in the illustrated embodiment is specifically used to perform:
[0152] The first voltage sag detection module detects the first voltage sag result when the grid voltage drops or the grid voltage phase changes.
[0153] The second voltage sag detection module detects the second voltage sag result when the grid voltage drops or the grid voltage phase changes.
[0154] The first voltage sag result and the second voltage sag result are logically processed to obtain the final voltage sag detection result.
[0155] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention 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.
[0156] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. 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 illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0157] 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.
[0158] 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.
[0159] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0160] Memory may include non-persistent storage 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.
[0161] 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.
[0162] 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 a process, method, article, or apparatus. Without further limitation, 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 said element.
[0163] 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.
[0164] The above description is merely an embodiment of this application and is 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 detecting voltage sags, wherein, For use in energy storage UPS systems, the method includes: The first voltage sag detection module detects the first voltage sag result when the grid voltage drops. The grid voltage includes the three-phase grid voltage. The first voltage sag detection module detects the first voltage sag result when the grid voltage drops, including: The q-axis component of the three-phase grid voltage is passed through an all-pass filter to obtain the target q-axis component of the three-phase grid voltage after a preset phase shift, and then superimposed with the d-axis component of the three-phase grid voltage to obtain the target voltage amplitude of the three-phase grid. The target amplitude of the three-phase grid voltage is input into a band-stop filter, and the first amplitude of the three-phase grid voltage is obtained after filtering. The first amplitude of the three-phase grid voltage is input into a low-pass filter, and the second amplitude of the three-phase grid voltage is obtained after filtering. By comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold, the first voltage sag result is detected. The step of comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold to detect the first voltage sag result includes: When the second amplitude of the three-phase grid voltage is less than the preset three-phase grid voltage sag threshold, and the first voltage sag result is detected as 1, a grid voltage sag occurs. If the second amplitude of the three-phase grid voltage is greater than or equal to the preset three-phase grid voltage sag threshold, and the first voltage sag result is detected as 0, then no grid voltage sag has occurred. The second voltage sag detection module detects the second voltage sag result when the grid voltage drops. The first voltage sag result and the second voltage sag result are logically processed to obtain the final voltage sag detection result.
2. The method as described in claim 1, wherein, It also includes: controlling the fast switch in the energy storage UPS system to disconnect the power grid based on the final voltage sag detection result; and Control the energy storage UPS system to supply power to the load, so as to provide continuous power supply in the grid voltage sag mode.
3. The method as described in claim 1 or 2, wherein, The voltage dip in the power grid includes at least one of the following conditions: single-phase voltage dip, two-phase voltage dip, and three-phase voltage dip.
4. The method as described in claim 3, wherein, It also includes voltage sag detection for any one or more extreme operating conditions, such as the single-phase grid voltage dropping to 0.895 times the rated grid voltage, the two-phase grid voltage dropping to 0.895 times the rated grid voltage, and the three-phase grid voltage dropping to 0.895 times the rated grid voltage.
5. The method as described in claim 1, wherein, The grid voltage includes the three-phase grid voltages of phase A, phase B, and phase C. The second voltage sag detection module detects the second voltage sag result when the grid voltage drops, including: The sampled actual value of the A-phase grid voltage is passed through an all-pass filter to obtain the actual value of the A-phase grid voltage after preset phase shifting; Based on the actual value of the A-phase grid voltage and the actual value of the A-phase grid voltage after preset phase shifting, a virtual three-phase grid voltage is constructed with the A-phase grid voltage as the reference. Based on the virtual three-phase grid voltage with the A-phase grid voltage as a reference, the third amplitude of the A-phase grid voltage is obtained; The third amplitude of the three-phase grid voltage is input into a low-pass filter, and the fourth amplitude of the three-phase grid voltage is obtained after filtering. By comparing the fourth amplitude of the three-phase grid voltage with the preset three-phase grid voltage sag threshold, the second voltage sag result of phase A grid voltage is detected; Similarly, the second voltage sag of the B-phase grid voltage and the second voltage sag of the C-phase grid voltage were detected. The second voltage sag result of the A-phase grid voltage, the second voltage sag result of the B-phase grid voltage, and the second voltage sag result of the C-phase grid voltage are logically processed to obtain the second voltage sag result.
6. A voltage sag detection device, wherein, For use in energy storage UPS systems, the device includes: The first voltage sag detection module is used to detect the first voltage sag result when the grid voltage drops. The grid voltage includes the three-phase grid voltage. The first voltage sag detection module detects the first voltage sag result when the grid voltage drops, including: The q-axis component of the three-phase grid voltage is passed through an all-pass filter to obtain the target q-axis component of the three-phase grid voltage after a preset phase shift, and then superimposed with the d-axis component of the three-phase grid voltage to obtain the target voltage amplitude of the three-phase grid. The target amplitude of the three-phase grid voltage is input into a band-stop filter, and the first amplitude of the three-phase grid voltage is obtained after filtering. The first amplitude of the three-phase grid voltage is input into a low-pass filter, and the second amplitude of the three-phase grid voltage is obtained after filtering. By comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold, the first voltage sag result is detected. The step of comparing the second amplitude of the three-phase grid voltage with a preset three-phase grid voltage sag threshold to detect the first voltage sag result includes: When the second amplitude of the three-phase grid voltage is less than the preset three-phase grid voltage sag threshold, and the first voltage sag result is detected as 1, a grid voltage sag occurs. If the second amplitude of the three-phase grid voltage is greater than or equal to the preset three-phase grid voltage sag threshold, and the first voltage sag result is detected as 0, then no grid voltage sag has occurred. The second voltage sag detection module is used to detect the second voltage sag result when the grid voltage drops. The voltage sag detection result output module is used to perform logical operations on the first voltage sag result and the second voltage sag result to obtain the final voltage sag detection result.
7. An electronic device, comprising: processor; as well as A memory configured to store computer-executable instructions, which, when executed, cause the processor to perform the method of any one of claims 1 to 5.
8. A computer-readable storage medium storing one or more programs, which, when executed by an electronic device including a plurality of applications, cause the electronic device to perform the method of any one of claims 1 to 5.