Micro-grid control method and terminal device

CN122993043APending Publication Date: 2026-10-27BEIJING BEIKANG ENGINEERING TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611143599.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-30
Publication Date
2026-10-27

AI Technical Summary

Technical Problem

[0003]目前,针对冲击负荷的控制方案多为“被动响应”模式,即冲击负荷实际发生后储能或柴油机才开始调节动作,此时微电网频率和电压已发生跌落,微电网运行状态已偏离安全范围,导致电能质量下降甚至触发保护装置动作

Benefits of technology

利用作业计划提前获知冲击发生时刻,可以为冲击前预控制提供时间窗口,预控制时机更早、针对性更强。通过预测冲击负荷事件的目标参数并据此生成预告信号,可以实现对冲击强度的量化判断,为后续预控制指令的定量生成提供依据。在冲击负荷事件发生之前,生成预控制指令,并基于此控制目标设备运行,在冲击负荷事件发生之前就做好准备,将“被动响应”变为“主动防御”,可以从源头抑制冲击扰动对微电网的冲击,显著减小频率和电压跌落幅度。并且,在目标设备包括光伏设备、储能设备以及发电机中的多个情况下,实现多源协同预控,使微电网具备更强的整体抗扰能力。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122993043A_ABST
    Figure CN122993043A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of power grid control, and discloses a micro-grid control method and a terminal device, which are used for active defense before an impact occurs and improve the stability of a micro-grid when the micro-grid bears an impact load. The method comprises the following steps: obtaining an operation plan and operation data of a mine; determining whether an impact load event exists in a target time period based on the operation plan; if the impact load event exists, predicting a target parameter of the impact load event according to the operation plan and the operation data, and generating a pre-warning signal based on the target parameter; in response to the pre-warning signal, generating a pre-control instruction before the impact load event occurs, the pre-control instruction being used for adjusting the working state of a target device in the micro-grid, the target device comprising at least one of the following: a photovoltaic device, an energy storage device and a generator; and controlling the target device in the micro-grid to work based on the pre-control instruction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of power grid control technology, and in particular to a microgrid control method and terminal equipment. Background Technology

[0002] In mining microgrid scenarios, the frequent start-stop of high-power impact loads such as hoists and crushers poses a severe challenge to the frequency and voltage stability of the microgrid.

[0003] Currently, most control schemes for impact loads are in a "passive response" mode, meaning that the energy storage or diesel engine only starts to adjust after the impact load actually occurs. By this time, the microgrid frequency and voltage have already dropped, and the microgrid's operating state has deviated from the safe range, leading to a decline in power quality or even triggering the protection device to operate.

[0004] Therefore, a method is needed to proactively take measures before an impact occurs in order to improve the stability of microgrids when subjected to impact loads. Summary of the Invention

[0005] In view of this, embodiments of this application provide a microgrid control method and terminal equipment for proactive defense before an impact occurs, thereby improving the stability of the microgrid when subjected to impact loads.

[0006] In a first aspect, embodiments of this application provide a microgrid control method, including: Obtain the mine's operation plan and data; Based on the work plan, determine whether there are any impact load events within the target time period; If a shock load event exists, the target parameters of the shock load event are predicted based on the work plan and operating data, and a warning signal is generated based on the target parameters. In response to a warning signal, a pre-control command is generated before an impact load event occurs. The pre-control command is used to adjust the operating status of target devices in the microgrid, including at least one power supply device. Based on pre-control commands, the target devices in the microgrid are controlled to operate.

[0007] In some embodiments, the method further includes: determining the pre-control operation state of the microgrid based on pre-control instructions; using the pre-control operation state as the initial state and the impact load event as the disturbance input, performing simulation to obtain the simulation operation parameters of the microgrid; if the simulation operation parameters do not meet the safety conditions, regenerating the pre-control instructions and re-executing the simulation until the simulation operation parameters meet the safety conditions; and controlling the target equipment in the microgrid to operate based on the pre-control instructions, including: if the simulation operation parameters meet the safety conditions, controlling the target equipment in the microgrid to operate based on the pre-control instructions.

[0008] In some embodiments, the simulation operation parameters include at least one of the following: the minimum frequency of the microgrid, the photovoltaic bus voltage, the voltage recovery time, and the maximum power angle swing; the safety conditions include at least one of the following: the minimum frequency is not lower than a first frequency threshold, the photovoltaic bus voltage is within the voltage threshold range, the voltage recovery time does not exceed the time threshold, and the maximum power angle swing does not exceed the power angle threshold.

[0009] In some embodiments, regenerating the pre-control instruction includes: calculating the sensitivity of each parameter in the simulation operation parameters relative to each control parameter in the pre-control instruction; determining the correction direction of each control parameter in the pre-control instruction based on the sensitivity; and adjusting each control parameter in the pre-control instruction according to a preset step coefficient based on the correction direction to obtain the regenerated pre-control instruction.

[0010] In some embodiments, the power supply equipment is an energy storage device, a photovoltaic device, or a generator; the pre-control command includes at least one of the following: a first command, a second command, and a third command; the first command is used to increase the active power of the energy storage device, enhance the virtual inertia of the energy storage device, and control the energy storage device to operate in a manner that exceeds the rated current and the operating duration does not exceed a preset overload duration; the second command is used to reduce the output power of the photovoltaic device to a preset base value, and / or limit the output power of the photovoltaic device to below a preset power; the third command is used to adjust the voltage setting value of the generator, and / or adjust the speed setting value of the generator.

[0011] In some embodiments, the impact load event is used to characterize the start-up event of the impact load equipment. The target parameters include the target start-up time and peak power of the impact load equipment. Based on the work plan and operating data, the target parameters of the impact load event are predicted, including: determining the rated power, planned start-up time, and impact current multiple of the impact load equipment based on the work plan; determining the historical start-up delay of the impact load equipment based on the operating data; calculating the peak power based on the rated power and impact current multiple; and correcting the planned start-up time based on the historical start-up delay to obtain the target start-up time.

[0012] In some embodiments, generating pre-control instructions includes: determining the operating parameter setpoints for each target device based on the work plan and operating data, with the goal of minimizing the operating cost of the microgrid; determining the pre-compensation amount for each target device according to the target parameters; and generating pre-control instructions based on the operating parameter setpoints and the pre-compensation amount.

[0013] In some embodiments, the method further includes: performing a first protection action if the energy storage device in the microgrid is detected to meet a first protection condition; performing a second protection action if the photovoltaic device in the microgrid is detected to meet a second protection condition; and performing a third protection action if the generator in the microgrid is detected to meet a third protection condition.

[0014] In some embodiments, the first protection condition includes at least one of the following: the output current of the energy storage device exceeds a first current threshold, the temperature exceeds a first temperature threshold, and the state of charge value exceeds a preset allowable range; the first protection action includes: reducing the output current of the energy storage device to a safe current threshold, and / or controlling the energy storage device to stop working; the second protection condition includes: the photovoltaic bus voltage exceeds a first voltage threshold, and / or the photovoltaic AC output current exceeds a second current threshold; the second protection action includes: reducing the output power of the photovoltaic device, and / or controlling the photovoltaic device to disconnect from the microgrid; the third protection condition includes at least one of the following: the frequency of the microgrid is lower than a second frequency threshold, the frequency of the microgrid is higher than a third frequency threshold, and the voltage of the microgrid is lower than a second voltage threshold; the third protection action includes: adjusting the operating state of the generator to maintain the voltage and / or frequency of the microgrid.

[0015] Secondly, embodiments of this application provide a microgrid control device, including: an acquisition module and a processing module; the acquisition module is used to acquire the mine's operation plan and operating data; the processing module is used to: determine whether there is an impact load event within a target time period based on the operation plan; if there is an impact load event, predict the target parameters of the impact load event according to the operation plan and operating data, and generate a warning signal based on the target parameters; in response to the warning signal, generate a pre-control command before the impact load event occurs, the pre-control command being used to adjust the operating state of target equipment in the microgrid, the target equipment including at least one power supply device; and control the operation of the target equipment in the microgrid based on the pre-control command.

[0016] Thirdly, embodiments of this application provide a terminal device including a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement any of the microgrid control methods in the first aspect.

[0017] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed on a processor, implements any of the microgrid control methods in the first aspect.

[0018] The embodiments of this application have the following beneficial effects: By utilizing work plans to anticipate the timing of impacts, a time window can be provided for pre-impact control, allowing for earlier and more targeted control. Predicting the target parameters of impact load events and generating warning signals based on these parameters enables a quantitative assessment of impact intensity, providing a basis for the quantitative generation of subsequent pre-control commands. Generating pre-control commands before the impact load event occurs and controlling the operation of target equipment accordingly allows for proactive defense, transforming "passive response" into "active defense." This can suppress the impact of impact disturbances on the microgrid at the source, significantly reducing frequency and voltage drops. Furthermore, in cases where target equipment includes photovoltaic devices, energy storage devices, and generators, multi-source coordinated pre-control can be achieved, giving the microgrid stronger overall disturbance immunity.

[0019] In summary, this application utilizes the advance prediction of impact load events driven by mining operation plans to complete the pre-control of target equipment in the microgrid before the impact occurs, transforming the traditional "post-event compensation" mode into a "pre-event active defense" mode. This significantly reduces the frequency and voltage drop amplitude of the microgrid when impact loads are connected, and improves the stability of the mining microgrid under impact disturbances. Attached Figure Description

[0020] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0021] Figure 1 This paper shows an architecture diagram of a microgrid system to which a microgrid control method provided in an embodiment of this application is applicable; Figure 2 A flowchart of a microgrid control method provided in an embodiment of this application is shown; Figure 3 This paper presents a schematic diagram of the overall process of a microgrid control method provided in an embodiment of this application. Figure 4 A schematic diagram of the structure of a microgrid control device provided in an embodiment of this application is shown. Detailed Implementation

[0022] The technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments.

[0023] The components of the embodiments of this application described and illustrated in the accompanying drawings can be arranged and designed in a variety of different configurations. Therefore, the following detailed description of the embodiments of this application provided in the drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.

[0024] In the following text, the terms "comprising," "having," and their cognates, which may be used in various embodiments of this application, are intended only to indicate a particular feature, number, step, operation, element, component, or combination thereof, and should not be construed as primarily excluding the presence of one or more other features, numbers, steps, operations, elements, components, or combinations thereof, or adding the possibility of one or more combinations thereof. Furthermore, the terms "first," "second," "third," etc., are used only for distinguishing descriptions and should not be construed as indicating or implying relative importance.

[0025] Unless otherwise specified, all terms used herein (including technical and scientific terms) shall have the same meaning as commonly understood by one of ordinary skill in the art to which the various embodiments of this application pertain. Terms (such as those defined in commonly used dictionaries) shall be interpreted as having the same meaning as in their contextual meaning in the relevant technical field and shall not be construed as having an idealized or overly formal meaning, unless clearly defined in the various embodiments of this application.

[0026] As described in the background section, current control schemes for impact loads are mostly "passive response" modes, resulting in insufficient stability of microgrids under impact loads. Therefore, a method is needed that can proactively take measures before an impact occurs to improve the stability of microgrids under impact loads.

[0027] Based on this, this application provides a microgrid control method that predicts impact load events driven by mining operation plans in advance and generates and issues pre-control commands for multiple devices before the impact occurs, realizing the transformation from "passive response after the event" to "active defense before the event". This significantly reduces the frequency and voltage drop amplitude of the microgrid when impact loads are connected, and improves the stability of the mining microgrid under impact disturbances.

[0028] The microgrid control method provided in this application is applicable to microgrid systems in non-ferrous mining scenarios.

[0029] like Figure 1 As shown, the microgrid system 1 includes a central control unit 10, a power supply device 20 that establishes a communication connection with the central control unit 10, and an impact load device 30.

[0030] The central control unit 10 can consist of a server, a communication interface card, and a database, and is used to realize functions such as economic scheduling of model predictive control (MPC), shock load prediction, feedforward pre-control command generation, dynamic safety verification, and closed-loop feedback iteration.

[0031] Specifically, the central control unit 10 can be a microgrid central controller (MCC), an energy management system (EMS), or the like.

[0032] The microgrid system 1 may have one or more power supply devices 20. For example, the power supply devices 20 included in the microgrid system 1 may be energy storage devices, photovoltaic devices, generators, etc.

[0033] In some regions with weak power grids, the grid infrastructure is inadequate, resulting in low power supply reliability and difficulty in meeting the huge electricity demands of non-ferrous metal mines. Therefore, it is necessary to construct microgrid systems primarily powered by photovoltaic (PV) and energy storage, leveraging the mines' own solar resources. Energy storage devices form the core of the microgrid system, utilizing their rapid response characteristics to mitigate the randomness and instability of PV power generation. Generators serve as backup power, activating when PV and energy storage cannot meet load demands, thus balancing power supply reliability and operational economy.

[0034] Energy storage devices can consist of batteries, inverters, and local controllers to enable charging and discharging functions.

[0035] Photovoltaic equipment can consist of a photovoltaic array, a photovoltaic inverter, and a local controller, and is used to convert light energy into electrical energy.

[0036] A generator can consist of a synchronous generator, an excitation regulator, a speed governor, and a local controller, and is used to generate electricity. Specifically, a generator can be a diesel generator.

[0037] The impact load equipment 30 can specifically include mine hoists, crushers, ball mills, fans, water pumps, compressors, etc.

[0038] The start-up and shutdown of the impact load device 30 can impact the stability of the microgrid. Therefore, the microgrid control method provided in this application needs to perform multi-device collaborative pre-control before the impact occurs. Based on this, the microgrid system 1 can adopt a hierarchical distributed control architecture, from top to bottom as follows: The first layer is the Economic Scheduling Layer (MPC), which can be deployed in the central control unit and is responsible for global economic operation scheduling and multi-source coordination optimization. The Economic Scheduling Layer has a second-level response time, such as 1~3 seconds.

[0039] The second layer is the coordination and control layer, which can be distributed among the central control unit and the local controllers of each target device. It is responsible for transient response, feedforward pre-control, and dynamic verification. The coordination and control layer is a millisecond-level response layer, for example, 10~50ms.

[0040] The third layer: the device protection layer, can be deployed in the local controller of each target device to achieve rapid device-level protection and fault isolation. The response speed of the device protection layer can be no more than 1 millisecond.

[0041] The microgrid control method will now be described in detail with reference to the accompanying drawings and some specific embodiments. Unless otherwise specified, the following embodiments and features can be combined with each other.

[0042] Figure 2 A flowchart of a microgrid control method according to an embodiment of this application is shown. The method includes the following steps: S101. Obtain the mine's operation plan and data.

[0043] The central control unit can obtain the start-up schedule of impact load equipment for a future period of time (such as the next minute) from the mine's production execution system (MES) or digital mining platform.

[0044] The central control unit can also acquire real-time operating data such as the device's current power, current, and frequency through sensors deployed in the device.

[0045] S102. Based on the work plan, determine whether there are any impact load events within the target time period.

[0046] Impact load events are used to characterize the start-up events of equipment subjected to impact loads.

[0047] The target time period is a period of time in the future, such as 3 minutes or 1 minute later.

[0048] For example, the central control unit uses a hybrid prediction model pre-built with a Long Short-Term Memory (LSTM) network and a rule engine, based on mine operation plan data, to predict the high-power impact load that will start in the next minute.

[0049] After obtaining the job plan, construct the input feature vector. : .

[0050] in, The planned start time, Rated power, This is a multiple of the impact current. For device type encoding, Codes for process stages, This represents historical startup delay statistics.

[0051] Input the vector into a pre-built hybrid prediction model .in, This represents the predicted impact load parameters. This represents a mixed prediction model, where t represents the time variable.

[0052] When the work plan contains deterministic information, a weighted fusion method is used. Comprehensive judgment; when work plan information is missing or uncertain, based on .in, This indicates the final prediction result. This represents the prediction result of the LSTM model, and 0.3 represents the LSTM weight. This represents the prediction result of the rule engine, and 0.7 represents the weight of the rule engine. The specific values ​​of the LATM weight and the rule engine weight can be adjusted according to the actual situation.

[0053] If the hybrid prediction model outputs There are non-zero prediction results within the target time period, i.e., including the start time. and peak power If so, it is determined that an impact load event exists within the target time period.

[0054] S103. If an impact load event exists, predict the target parameters of the impact load event based on the work plan and operating data, and generate a warning signal based on the target parameters.

[0055] In some embodiments, the target parameters include the target start-up time and peak power of the impact load equipment; step S103 can be specifically implemented as follows: based on the work plan, determine the rated power, planned start-up time, and impact current multiple of the impact load equipment; based on the operating data, determine the historical start-up delay of the impact load equipment; based on the rated power and impact current multiple, calculate the peak power; based on the historical start-up delay, correct the planned start-up time to obtain the target start-up time.

[0056] Peak power is based on rated power and impact current multiple The calculation is as follows: .

[0057] Based on real-time operating data of photovoltaic equipment, the continuous grey prediction model GM(1,1) can be used to predict the photovoltaic output within the next 60 seconds: ; Where 'a' is the development coefficient, which reflects the changing trend of the photovoltaic treatment sequence and can be identified online using the least squares method from the historical data of the most recent 60 seconds; and 'u' is the gray action quantity, which reflects the disturbance term of the photovoltaic treatment sequence and can be identified online using the least squares method from the historical photovoltaic output data of the most recent 60 seconds. This represents the measured photovoltaic output at the current time t. For the future t+ The predicted value of photovoltaic power output; To predict the step size, we can take 1 second; the prediction time domain is 60 steps (60 seconds).

[0058] By combining the predicted impact load and the predicted photovoltaic output, a set of target parameters for the impact load event is obtained, which includes at least the start-up time and peak power, and may also include rated power, impact current multiple, and the predicted photovoltaic output sequence within the next 60 seconds.

[0059] Based on the target parameters, a standardized "impact load warning signal" message is generated, such as a message conforming to the IEC 61850 extended information model. The warning signal may include the following fields: event ID (used to uniquely identify this impact load event), predicted start time, rated power, impact current multiple, current photovoltaic output, photovoltaic output sequence for the next 60 seconds, confidence level (used to characterize the reliability of this prediction), etc.

[0060] The warning signal can be sent to the central control unit 3 seconds before the impact load occurs, serving as the triggering basis for subsequent feedforward control.

[0061] By correcting the planned start time by using historical start-up delays, the inherent deviation between the actual equipment start-up time and the planned schedule in mining production can be effectively eliminated. The peak power is calculated based on the rated power and the multiple of the impact current, which can more accurately reflect the impact intensity than simply using the rated power. This provides a more accurate triggering timing and amplitude basis for subsequent feedforward control, effectively avoiding premature or late pre-control due to prediction deviations.

[0062] S104. In response to the warning signal, a pre-control command is generated before the occurrence of the impact load event. The pre-control command is used to adjust the operating status of the target equipment in the microgrid.

[0063] The target equipment includes at least one power supply device. This power supply device can be a photovoltaic device, an energy storage device, a generator, etc. The following examples will use three devices—a photovoltaic device, an energy storage device, and a generator—as examples for detailed explanation.

[0064] In some embodiments, generating pre-control instructions includes: determining the operating parameter setpoints for each target device based on the work plan and operating data, with the goal of minimizing the operating cost of the microgrid; determining the pre-compensation amount for each target device according to the target parameters; and generating pre-control instructions based on the operating parameter setpoints and the pre-compensation amount.

[0065] For example, based on the Model Predictive Control (MPC) rolling optimization framework, the base value of photovoltaic output is simultaneously optimized and calculated with the objective function of minimizing the overall operating cost of the microgrid system. Photovoltaic load reduction margin Base value of energy storage charging and discharging power Generator start-stop plan and output base value .

[0066] The objective function is: .

[0067] Where J is the total operating cost and N is the number of prediction time-domain steps (for example, 60 steps, corresponding to a 60-second prediction time-domain). The time step is k (e.g., 1 second), and k is the step index (e.g., k=0, 1, ..., N-1). For the unit fuel cost of generators, For the generator to generate active power, The unit cycle degradation cost of energy storage charging and discharging. The absolute value of energy storage capacity. Penalty cost per unit for photovoltaic load reduction To reduce the load on photovoltaic power, For generator start-up and shutdown costs, The generator is in start / stop state. This indicates a change in start / stop status. For example, the value is 1 if the status changes from 0 to 1 (start) or from 1 to 0 (stop), and 0 otherwise.

[0068] By adjusting the weighting coefficients of these four costs (i.e. , , , The central control unit can then find the optimal balance between economy, equipment lifespan, new energy utilization rate and system stability.

[0069] The objective function is optimized under the following constraints: 1. Power balance constraint: This is used to ensure that the sum of the output of photovoltaics, energy storage, and generators equals the predicted load demand at any given time. Among them, This represents the actual output power of the photovoltaic device at time t. The charging and discharging power of the energy storage device at time t. Let be the active power output of the generator at time t. Let t be the predicted microgrid load demand at time t.

[0070] 2. Energy storage SOC constraints: ,and ,in, Improve the charging efficiency of energy storage devices. The discharge efficiency of energy storage devices. The rated capacity of the energy storage device, Let be the charging power of the energy storage device at time t. Let be the discharge power of the energy storage device at time t. This represents the lower limit of the energy storage state of charge. This represents the upper limit of the energy storage state of charge. This represents the state of charge (SOC) of the energy storage device at time t. The SOC constraint is used to ensure that the energy storage device always operates within a safe range.

[0071] 3. Generator gradeability constraint: This is used to limit the rate of change in generator output to avoid mechanical wear. Among them, This is the generator's maximum gradeability, which is the maximum allowable rate of change in output per unit time.

[0072] 4. Photovoltaic output constraints: This is used to ensure that the photovoltaic output does not exceed the maximum power tracking point and to specify the load shedding margin. Among them, This represents the maximum power output of the photovoltaic device under the current illumination conditions at time t. Let be the base output value of the photovoltaic equipment at time t. This represents the load reduction margin for the photovoltaic equipment at time t.

[0073] 5. Rotational spare constraint: ,in, This is the load reserve factor (for example, a value of 0.15 to 0.25). Let t be the load reduction power of the photovoltaic equipment at the current time t.

[0074] Upon receiving the warning signal, the central control unit extracts the target parameters from the warning signal 1 to 3 seconds before the impact occurs, and calculates the pre-compensation amount for each target device: 1. Pre-compensation amount for energy storage equipment: (1) Output preset value ,in, For energy storage feedforward coefficient, For the rated capacity of energy storage, This represents the predicted peak power of the impact load.

[0075] Output compensation amount is .

[0076] (2) Increase virtual inertia ,in The rated inertia of the virtual synchronous generator. The inertia enhancement factor is... This is the sum of the rated power of each power source.

[0077] The virtual inertia compensation amount is .

[0078] (3) Unlock short-time overload mode, overload current limit ,in, This is the overload factor.

[0079] Overload current limit compensation amount is .

[0080] The duration of current overload can be allowed to exceed 2 seconds.

[0081] 2. Generator pre-compensation amount: (1) AVR reference point: ,in, This is the rated excitation reference voltage. For AVR adjustment factor, This refers to the generator's rated capacity.

[0082] AVR reference voltage bias .

[0083] (2) Regulator frequency offset: ,in, This is the feedforward coefficient of the speed governor. This refers to the rated power of the diesel generator.

[0084] If the generator is currently in a shutdown state, the pre-compensation amount is a start command to put it into hot standby state; if it is in operation state, the above bias amount is added to the AVR and governor reference point.

[0085] 3. Photovoltaic equipment pre-compensation amount: Obtain current photovoltaic output With photovoltaic power output base value ,when > At that time, the pre-compensation amount is a fast load reduction command, which smoothly reduces the load to [a certain value] within 200ms through a second-order low-pass filter. After load reduction, enter the rapid power limiting mode and set the power limit value. Additionally, reserve an emergency load reduction channel, for example, 5% to 10% of the rated power.

[0086] By determining the economic operating baseline value of each target device and then superimposing the feedforward pre-compensation amount for the characteristics of the impact load, a coordinated pre-control command of "base value to ensure economy and compensation to resist impact" is formed. This enables the microgrid to take into account the optimal economy of fuel consumption, energy storage life and photovoltaic utilization during normal operation. At the same time, it actively adjusts the operating parameters of each target device before the impact occurs, effectively improving the microgrid's preparedness response capability to impact power.

[0087] In some embodiments, the pre-control command includes at least one of the following: a first command, a second command, and a third command; the first command is used to increase the active power of the energy storage device, enhance the virtual inertia of the energy storage device, and control the energy storage device to operate in a manner that exceeds the rated current and the operating duration does not exceed a preset overload duration; the second command is used to reduce the output power of the photovoltaic device to a preset base value, and / or limit the output power of the photovoltaic device to below a preset power; the third command is used to adjust the voltage setting value of the generator, and / or adjust the speed setting value of the generator.

[0088] The energy storage device (BESS) operates in grid-connected mode and adopts a virtual synchronous generator (VSG) control strategy; the photovoltaic equipment has fast power limiting capability with a response time of ≤200ms; the generator adopts improved droop characteristics for auxiliary regulation.

[0089] 1. Regarding the first instruction: The energy storage inverter uses VSG control to simulate the inertia and damping characteristics of a synchronous generator. Its active-frequency control equation is as follows: ,in, This is a virtual moment of inertia (which can be increased to 1.5 to 2 times the rated value when the impact load is pre-controlled). This is the virtual damping coefficient. For the output angular frequency, The rated angular frequency, This is a reference value for active power. This represents the actual output active power.

[0090] The reactive power-voltage control equation is: Where E is the output voltage amplitude reference. This is the rated voltage amplitude. This is the reactive power droop factor. This is a reference value for reactive power. This represents the actual output reactive power.

[0091] Enhancing the virtual inertia of energy storage devices specifically means: increasing the virtual inertia value. Substituting into the active-frequency control equation of the energy storage VSG .

[0092] Improving the active power of energy storage equipment specifically means: increasing the reference output value. Substituting into the same equation .

[0093] The energy storage inverter calculates the rate of change of angular frequency in real time according to the equation and adjusts the output to realize virtual inertia enhancement and pre-active power preparation.

[0094] Overload current limit This is used to set the upper limit of the current inner loop saturation, ensuring that the energy storage device outputs power according to this limit and the overload duration does not exceed 2 seconds. Reactive power voltage support is achieved by the reactive power-voltage control equation.

[0095] 2. Regarding the second instruction: The photovoltaic inverter employs a fast power limiting strategy based on the closed-loop voltage of the photovoltaic grid connection point. Upon receiving a feedforward pre-control command, the photovoltaic equipment switches its output from maximum power point tracking (MPPT) mode to the given power mode within 200 milliseconds, smoothly reducing the output to the preset base value. The power switching process uses a first-order low-pass filter for a smooth transition. ,in, This is the smoothing time constant (which can be 50 milliseconds).

[0096] Reducing the output power of photovoltaic equipment to a preset baseline value specifically involves: Substitute into the power smoothing transition formula According to this formula, the photovoltaic inverter smoothly switches its output from maximum power point following mode to a given power mode within 200 milliseconds, eventually stabilizing. This achieves a smooth reduction in power to avoid secondary impacts on the microgrid.

[0097] Limiting the output power of photovoltaic equipment to below a preset power level specifically involves setting a power upper limit. ,in To reserve a power margin for emergency load shedding (which can be 5% to 10% of the rated power), the photovoltaic equipment simultaneously enters a fast power limiting mode, with the actual output not exceeding [a certain percentage]. An emergency load reduction channel is reserved for transient processes.

[0098] 3. Regarding the third instruction: Feedforward adjustment is introduced into the generator AVR excitation reference voltage: ,in, For the new AVR excitation reference voltage, This is the rated excitation reference voltage. For AVR adjustment factor, This is the pre-controlled voltage bias.

[0099] The generator voltage setting is adjusted specifically based on the peak power prediction value. Calculate the pre-control voltage bias Substitute into the AVR excitation feedforward adjustment formula The excitation reference voltage is raised in advance to enhance transient voltage support.

[0100] The generator employs an improved droop characteristic, introducing a feedforward compensation term based on the traditional active-frequency droop: ,in, Here, f is the droop factor, and f is the actual frequency. The rated frequency is 50Hz. This is the feedforward compensation power (set to standby boost bias during the pre-control phase).

[0101] The specific steps for adjusting the generator speed setpoint are: calculating the feedforward compensation power based on the peak power prediction value. Substitute into the improved droop control equation Increase the active power output reference value in advance before the actual frequency drop, and shorten the generator transient response lag time.

[0102] By decomposing pre-control commands into three differentiated categories—energy storage, photovoltaic (PV), and generator—precise feedforward regulation with multi-source coordination is achieved. The first command increases the preset output value of energy storage devices, enhances virtual inertia, and unlocks short-term overload capacity, effectively suppressing the frequency drop depth and rate of change during the impact. The second command controls PV devices to quickly and smoothly reduce load and sets a power upper limit, proactively reserving system adjustment margin before the impact occurs to avoid interference from PV fluctuations on transient response. The third command adjusts the AVR voltage setpoint and governor frequency offset of generators in advance, shortening the lag time from receiving disturbances to output response. The three types of commands are issued in parallel, each performing its own function, jointly achieving multi-source coordinated pre-control before the impact occurs—"energy storage increases margin, PV clears the path, and diesel engines prepare"—significantly improving the microgrid system's preparedness response capability to impact loads and providing sufficient power support and adjustment reserves for transient processes.

[0103] Photovoltaic equipment participates in pre-control with ≤200ms rapid power limiting, forming a three-source linkage with energy storage overload and generator hot standby. With photovoltaic load reduction pre-control, the energy storage capacity requirement can be reduced by 15% to 20%, and the frequency of generator start-up and shutdown can be reduced.

[0104] S105. Based on pre-control commands, control the operation of target devices in the microgrid.

[0105] In some embodiments, the pre-control operation state of the microgrid is determined based on the pre-control command; the pre-control operation state is used as the initial state, and the impact load event is used as the disturbance input to perform simulation to obtain the simulation operation parameters of the microgrid; if the simulation operation parameters do not meet the safety conditions, the pre-control command is regenerated and the simulation is re-executed until the simulation operation parameters meet the safety conditions; correspondingly, if the simulation operation parameters meet the safety conditions, step S104 is executed.

[0106] The simulation operation parameters include at least one of the following: the minimum frequency of the microgrid, the photovoltaic bus voltage, the voltage recovery time, and the maximum power angle swing; the safety conditions include at least one of the following: the minimum frequency is not lower than the first frequency threshold, the photovoltaic bus voltage is within the voltage threshold range, the voltage recovery time does not exceed the time threshold, and the maximum power angle swing does not exceed the power angle threshold.

[0107] Specifically, the first frequency threshold is calculated based on the current short-circuit ratio and / or load factor of the microgrid; the voltage threshold range is calculated based on the short-circuit ratio of the photovoltaic equipment in the microgrid; the time threshold is calculated based on the current short-circuit ratio and / or power quality factor of the microgrid; and the power angle threshold is calculated based on the current short-circuit ratio of the microgrid.

[0108] Optionally, if the simulation parameters still do not meet safety conditions when the preset number of simulation iterations is reached, the simulation iteration process can be terminated to avoid unlimited iteration. For example, the maximum number of iterations is 5.

[0109] The simulation process is actually a safety verification process, which is carried out about 200 milliseconds before the actual impact occurs.

[0110] First frequency threshold: ;in, The rated frequency (e.g., 50Hz). For reference frequency deviation, Given the current short-circuit ratio, The rated short-circuit ratio, Rated load rate, This is the short-circuit ratio adjustment factor. This is the load factor adjustment coefficient.

[0111] Voltage threshold range: , ,in, Rated voltage, This is the lower limit of the voltage threshold range. This represents the upper limit of the voltage threshold range.

[0112] Time threshold: ,in, As the baseline recovery time, This is the short-circuit ratio adjustment factor.

[0113] Work angle threshold: ,in, As the reference power angle amplitude, This is the power angle adjustment coefficient; the heavier the load, the stricter the power angle restriction must be to ensure transient stability.

[0114] The simulation uses a reduced-order dynamic model of the microgrid with a step size of 1ms and a time domain of 2s. If the simulation results simultaneously meet the constraints of frequency, voltage, power angle, and photovoltaic voltage, the verification passes, meaning the safety conditions are met. All pre-control commands are locked and executed, the impact load is smoothly connected, the system enters stable operation, and the next control cycle begins; otherwise, the simulation fails.

[0115] Through a complete verification chain of "pre-control state determination → adaptive threshold calculation → rapid time-domain simulation → safety condition criterion → closed-loop feedback iteration," the effectiveness of pre-control commands is proactively verified before the actual impact occurs, avoiding the instability risk that open-loop pre-control may cause under extreme operating conditions or prediction deviations. The constraint thresholds for safety conditions are not fixed values ​​but are dynamically and adaptively generated based on the current short-circuit ratio, load factor, and power quality factor of the microgrid. This allows the safety criteria to adjust in real-time according to changes in the operating state of the weak grid, avoiding the drawbacks of traditional fixed thresholds being too risky in weak grids and too conservative in strong grids. By introducing an adaptive dynamic constraint threshold mechanism, based on SCR, load characteristics, power quality level, and... Dynamically generate safety boundaries; when SCR decreases from 10 to 3 By tightening the frequency from 49.8Hz to 49.3Hz, a dynamic balance between safety and economy was achieved.

[0116] In some embodiments, regenerating the pre-control instruction can be specifically implemented by: calculating the sensitivity of each parameter in the simulation operation parameters relative to each control parameter in the pre-control instruction; determining the correction direction of each control parameter in the pre-control instruction based on the sensitivity; and adjusting each control parameter in the pre-control instruction according to a preset step coefficient based on the correction direction to obtain the regenerated pre-control instruction.

[0117] Calculate each simulation running parameter separately Relative to each control parameter in the pre-control command Sensitivity: Among them, control parameters This can include the penalty weight of the objective function, the energy storage output coefficient, the photovoltaic load shedding depth, and the generator thermal reserve capacity, etc.

[0118] Based on sensitivity The numerical value is used to identify the control parameter that has the greatest impact on the constraint that does not meet the safety conditions, and this parameter is identified as the dominant instability factor. For example, if the minimum frequency value does not meet the requirements, the control parameter that has the greatest impact on the frequency (such as the energy storage output coefficient or the generator thermal reserve capacity) is identified as the focus of correction.

[0119] Based on sensitivity The sign of the control parameter determines the direction of correction: if Increasing this control parameter can improve the corresponding simulation running parameters; if If so, the control parameter needs to be reduced. After determining the correction direction, the control parameter is adjusted stepwise according to the preset step correction coefficient λ (taken as 0.1 to 0.3), including: adjusting the penalty weight in the objective function (such as increasing the energy storage degradation cost or photovoltaic load reduction penalty cost), adjusting the energy storage output feedforward coefficient, adjusting the photovoltaic load reduction depth, and adjusting the diesel engine hot reserve capacity, etc.

[0120] The corrected control parameters are used as new inputs to perform rolling optimization again, generating updated pre-control instructions. Then, dynamic safety verification is performed again (i.e., re-simulation and judgment of safety conditions). If the conditions are still not met, the above steps are repeated until the simulation parameters meet the safety conditions (convergence) or the maximum number of iterations is reached (outputting a feasible solution).

[0121] This implementation quantitatively assesses the degree and direction of the impact of each control parameter on safety constraints using a sensitivity matrix. When safety verification fails, it can accurately locate the dominant instability factor, avoiding blind adjustments. Based on this, it automatically adjusts the objective function, penalty weight, energy storage output coefficient, photovoltaic load shedding depth, and generator thermal reserve capacity according to step correction coefficients, driving re-optimization and iterative verification. This forms a closed-loop chain of "verification failure → sensitivity analysis → parameter correction → re-optimization → re-verification," enabling pre-control commands to automatically converge to the safe and feasible region under prediction deviations or extreme operating conditions.

[0122] By introducing a dynamic safety check and closed-loop feedback iteration mechanism, the instability factors are automatically located and parameters are corrected through sensitivity analysis, driving the objective function to re-optimize. The convergence probability exceeds 95% after ≤5 iterations, significantly enhancing robustness.

[0123] In some embodiments, if the energy storage device in the microgrid is detected to meet the first protection condition, a first protection action is performed; if the photovoltaic device in the microgrid is detected to meet the second protection condition, a second protection action is performed; and if the generator in the microgrid is detected to meet the third protection condition, a third protection action is performed.

[0124] The first protection condition includes at least one of the following: the output current of the energy storage device exceeds a first current threshold, the temperature exceeds a first temperature threshold, and the state of charge value exceeds a preset allowable range; the first protection action includes: reducing the output current of the energy storage device to a safe current threshold, and / or controlling the energy storage device to stop working; the second protection condition includes: the photovoltaic bus voltage exceeds a first voltage threshold, and / or the photovoltaic AC output current exceeds a second current threshold; the second protection action includes: reducing the output power of the photovoltaic device, and / or controlling the photovoltaic device to disconnect from the microgrid; the third protection condition includes at least one of the following: the frequency of the microgrid is lower than a second frequency threshold, the frequency of the microgrid is higher than a third frequency threshold, and the voltage of the microgrid is lower than a second voltage threshold; the third protection action includes: adjusting the operating state of the generator to maintain the voltage and / or frequency of the microgrid.

[0125] For example, energy storage device protection: when an overcurrent is detected Overheating Or SOC exceeding limits When this happens, the energy storage converter immediately limits the current to a safe value, and if this continues for more than 1 second, it triggers a hard protection shutdown.

[0126] Photovoltaic equipment protection: When DC bus overvoltage is detected , communication flow In the case of islanding, the photovoltaic inverter immediately implements active power reduction at a rate of ≥500kW / s; if the fault lasts for more than 500 milliseconds, it will implement grid disconnection protection.

[0127] Generator protection: Equipped with seamless switching control logic, when the microgrid frequency is detected to be below 49Hz or above 51Hz, or the voltage is below 85% of the rated value, the diesel generator automatically switches from hot standby to constant voltage / frequency control mode (V / f) (maintaining a constant ratio of output voltage amplitude to output frequency), with a switching time of ≤20 milliseconds. It serves as the last voltage / frequency support source for the microgrid and is also equipped with black start capability.

[0128] By setting these protection conditions and actions, independent protection trigger conditions and differentiated protection actions are configured for energy storage, photovoltaics and generators respectively, realizing rapid backup for the safety of the equipment itself. The three layers of protection are independent of each other and do not interfere with each other, avoiding the risk of a single equipment failure spreading to the entire system.

[0129] Optionally, the central control unit will also monitor the frequency, voltage, current harmonic distortion rate, etc. of the microgrid PCC point in real time. When the frequency deviation exceeds ±1Hz, the voltage deviation exceeds ±15%, and the THD exceeds 8%, an alarm will be triggered and reported.

[0130] In summary, as Figure 3 As shown below, the solution of this application is described from the perspective of the overall process: S1. Load forecasting and disturbance extraction, generating impact load forecast signals; S2. Pre-control commands are generated through a multi-source feedforward pre-control mechanism before impact; S3. Perform dynamic safety verification on pre-control commands and conduct rapid time-domain simulation; S4. If the verification passes, the pre-control command is locked and executed, and the microgrid operates stably. S5. If the verification fails, iterative optimization is performed, and the pre-control instructions are re-predicted and generated.

[0131] By proactively issuing pre-control commands 1-3 seconds before the impact, the system coordinates photovoltaic load reduction, energy storage output enhancement and overload unlocking, and diesel generator hot standby, forming an active control system of "prediction → feedforward → pre-adjustment"; taking the enhancement of virtual inertia of energy storage VSG as an example. After being increased to 1.5 to 2 times, the frequency change rate decreased significantly, and the lowest frequency point increased by more than 0.3 Hz.

[0132] To address the issue of insufficient adaptability to weak power grids, this paper adapts to weak power grids from three levels: architecture, strategy, and constraints. Under the worst-case operating conditions with SCR=3 and inrush current multiple of 7, the frequency drop is controlled within 0.5Hz and the voltage drop is less than 5%.

[0133] Through a complete closed-loop workflow of "prediction → feedforward → verification → feedback → correction → execution", a comprehensive technological leap has been achieved, from passive response to proactive response, from fixed threshold to adaptive boundary, from single-source regulation to three-source linkage, from open-loop control to closed-loop iteration, and from conventional power grid to weak power grid adaptation. This has significantly improved the transient stability and economy of non-ferrous mining microgrids under impact loads.

[0134] Figure 4 A schematic diagram of a microgrid control device according to an embodiment of this application is shown. Exemplarily, the microgrid control device 200 includes an acquisition module 201 and a processing module 202.

[0135] The acquisition module 201 is used to acquire the mine's operation plan and running data; the processing module 202 is used to: determine whether there is an impact load event within the target time period based on the operation plan; if there is an impact load event, predict the target parameters of the impact load event based on the operation plan and running data, and generate a warning signal based on the target parameters; in response to the warning signal, generate a pre-control command before the impact load event occurs, the pre-control command is used to adjust the working state of the target equipment in the microgrid, the target equipment includes at least one power supply device; and control the operation of the target equipment in the microgrid based on the pre-control command.

[0136] In some embodiments, the processing module 202 is further configured to: determine the pre-control operation state of the microgrid based on the pre-control command; use the pre-control operation state as the initial state and the impact load event as the disturbance input to perform simulation to obtain the simulation operation parameters of the microgrid; if the simulation operation parameters do not meet the safety conditions, regenerate the pre-control command and re-execute the simulation until the simulation operation parameters meet the safety conditions; specifically, the processing module 202 is configured to: if the simulation operation parameters meet the safety conditions, control the target equipment in the microgrid to work based on the pre-control command.

[0137] In some embodiments, the processing module 202 is specifically used to: calculate the sensitivity of each parameter in the simulation operation parameters relative to each control parameter in the pre-control command; determine the correction direction of each control parameter in the pre-control command based on the sensitivity; and adjust each control parameter in the pre-control command according to a preset step coefficient based on the correction direction to obtain a regenerated pre-control command.

[0138] In some embodiments, the processing module 202 is specifically used to: determine the rated power, planned start time, and impact current multiple of the impact load equipment based on the work plan; determine the historical start delay of the impact load equipment based on the operating data; calculate the peak power based on the rated power and impact current multiple; and correct the planned start time based on the historical start delay to obtain the target start time.

[0139] In some embodiments, the processing module 202 is specifically used to: determine the operating parameter setpoints for each target device based on the work plan and operating data, with the goal of minimizing the operating cost of the microgrid; determine the pre-compensation amount for each target device according to the target parameters; and generate pre-control instructions according to the operating parameter setpoints and the pre-compensation amount.

[0140] In some embodiments, the processing module 202 is further configured to: execute a first protection action if the energy storage device in the microgrid is detected to meet the first protection condition; execute a second protection action if the photovoltaic device in the microgrid is detected to meet the second protection condition; and execute a third protection action if the generator in the microgrid is detected to meet the third protection condition.

[0141] It is understood that the device in this embodiment corresponds to the microgrid control method in the above embodiments, and the options in the above embodiments are also applicable to this embodiment, so they will not be described again here.

[0142] This application also provides a terminal device, exemplary of which includes a processor and a memory, wherein the memory stores a computer program, and the processor executes the computer program to enable the terminal device to perform the functions of the various modules in the microgrid control method or the microgrid control device described above.

[0143] The processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, including at least one of a Central Processing Unit (CPU), Graphics Processing Unit (GPU), Network Processor (NP), Digital Signal Processor (DSP), Application-Specific Integrated Circuit (ASIC), Field-Programmable Gate Array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor can be a microprocessor or any conventional processor, capable of implementing or executing the methods, steps, and logic block diagrams disclosed in the embodiments of this application.

[0144] The memory can be, but is not limited to, Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), etc. The memory is used to store computer programs, and the processor can execute the computer programs accordingly after receiving execution instructions.

[0145] This application also provides a computer-readable storage medium for storing the computer program used in the aforementioned terminal device. For example, the computer-readable storage medium may include, but is not limited to, various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0146] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can also be implemented in other ways. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings show the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that, in alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and combinations of blocks in the block diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.

[0147] In addition, the functional modules or units in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.

[0148] If the aforementioned functions are implemented as software functional modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a smartphone, personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application.

[0149] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application.

Claims

1. A microgrid control method, characterized in that, include: Obtain the mine's operation plan and data; Based on the work plan, determine whether there are any impact load events within the target time period; If the impact load event exists, then based on the work plan and the operating data, the target parameters of the impact load event are predicted, and a warning signal is generated based on the target parameters; In response to the warning signal, a pre-control command is generated before the occurrence of the impact load event. The pre-control command is used to adjust the operating state of a target device in the microgrid, the target device including at least one power supply device. Based on the pre-control instructions, the target devices in the microgrid are controlled to operate.

2. The method according to claim 1, characterized in that, The method further includes: Based on the pre-control instructions, the pre-control operation status of the microgrid is determined; Using the pre-controlled operating state as the initial state and the impact load event as the disturbance input, simulation is performed to obtain the simulation operating parameters of the microgrid. If the simulation operation parameters do not meet the safety conditions, the pre-control instructions are regenerated and the simulation is re-executed until the simulation operation parameters meet the safety conditions. The step of controlling the target devices in the microgrid based on the pre-control command includes: If the simulation operation parameters meet the safety conditions, the target devices in the microgrid are controlled to operate based on the pre-control instructions.

3. The method according to claim 2, characterized in that, The simulation operating parameters include at least one of the following: the minimum frequency of the microgrid, the photovoltaic bus voltage, the voltage recovery time, and the maximum power angle swing. The safety conditions include at least one of the following: the minimum frequency value is not lower than a first frequency threshold, the photovoltaic bus voltage is within a voltage threshold range, the voltage recovery time does not exceed a time threshold, and the maximum power angle swing does not exceed a power angle threshold.

4. The method according to claim 2, characterized in that, The regeneration of pre-control instructions includes: Calculate the sensitivity of each parameter in the simulation operation parameters relative to each control parameter in the pre-control command; Based on the sensitivity, the correction direction of each control parameter in the pre-control command is determined respectively; Based on the correction direction, the control parameters in the pre-control command are adjusted according to a preset step coefficient to obtain a regenerated pre-control command.

5. The method according to claim 1, characterized in that, The power supply equipment is an energy storage device, a photovoltaic device, or a generator; the pre-control command includes at least one of the following: a first command, a second command, and a third command; The first instruction is used to increase the active power of the energy storage device, enhance the virtual inertia of the energy storage device, and control the energy storage device to operate in a manner that exceeds the rated current and the operating duration does not exceed a preset overload duration, at least one of the following: The second instruction is used to reduce the output power of the photovoltaic device to a preset base value, and / or limit the output power of the photovoltaic device to below a preset power. The third instruction is used to adjust the voltage setting value of the generator and / or adjust the speed setting value of the generator.

6. The method according to claim 1, characterized in that, The impact load event is used to characterize the start-up event of the impact load equipment, and the target parameters include the target start-up time and peak power of the impact load equipment. The step of predicting the target parameters of the shock load event based on the work plan and the operational data includes: Based on the work plan, the rated power, planned start-up time, and impact current multiple of the impact load equipment are determined; Based on the operational data, the historical start-up delay of the impact load equipment is determined; The peak power is calculated based on the rated power and the impact current multiple. The planned start time is adjusted based on the historical start delay to obtain the target start time.

7. The method according to claim 1, characterized in that, The generation of pre-control instructions includes: Based on the work plan and the operation data, with the goal of minimizing the operating cost of the microgrid, the operating parameter settings for each of the target devices are determined. Based on the target parameters, determine the pre-compensation amount for each of the target devices; The pre-control command is generated based on the set values ​​of the operating parameters and the pre-compensation amount.

8. The method according to claim 1, characterized in that, The method further includes: If the energy storage device in the microgrid is detected to meet the first protection condition, the first protection action is executed; If the photovoltaic devices in the microgrid are detected to meet the second protection condition, the second protection action is executed; If the generator in the microgrid is detected to meet the third protection condition, the third protection action is executed.

9. The method according to claim 8, characterized in that, The first protection condition includes at least one of the following: the output current of the energy storage device exceeds a first current threshold, the temperature exceeds a first temperature threshold, and the state of charge value exceeds a preset allowable range; The first protection action includes: reducing the output current of the energy storage device to a safe current threshold, and / or controlling the energy storage device to stop working; The second protection condition includes: the photovoltaic bus voltage exceeds the first voltage threshold, and / or the photovoltaic AC output current exceeds the second current threshold; The second protection action includes: reducing the output power of the photovoltaic device, and / or controlling the photovoltaic device to disconnect from the microgrid; The third protection condition includes at least one of the following: the frequency of the microgrid is lower than the second frequency threshold, the frequency of the microgrid is higher than the third frequency threshold, and the voltage of the microgrid is lower than the second voltage threshold; The third protection action includes: adjusting the operating status of the generator to maintain the voltage and / or frequency of the microgrid.

10. A terminal device, characterized in that, It includes a processor and a memory, the memory storing a computer program, and the processor executing the computer program to implement the microgrid control method according to any one of claims 1-9.