Simulation test method and device through programmable logic controller
By using a programmable logic controller (PLC) for simulation tests in EMS testing, the problems of complicated equipment, cumbersome manual operations, limited accuracy and difficulty in coordination in traditional testing methods are solved, and efficient and accurate demand control function testing is achieved.
Patent Information
- Application Number
- CN202411996530.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-04-18
AI Technical Summary
The traditional EMS demand control function testing method is difficult to efficiently and accurately test the demand control function of the energy storage system due to complex equipment, cumbersome manual operation, limited accuracy and difficulty in coordination.
The simulation test method is realized through a programmable logic controller (PLC), the test tasks of the energy storage system are obtained, the simulated energy power is set, and the initial incoming power is calculated. Automatic operation replaces manual adjustment, reducing human error, and improving testing efficiency and accuracy.
It simplifies pre-test preparation, reduces equipment and site costs, and improves test efficiency and accuracy, avoids human error and coordination difficulties, and ensures the credibility of test results.
Smart Images

Figure CN119847118A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of data processing, and in particular to a simulation test method and device through a programmable logic controller. Background Art
[0002] As the global demand for refined energy management grows, the demand control function of EMS (energy management system) becomes increasingly important in the power supply network. In the past, in order to test it, it was usually necessary to build a test environment using a large number of professional equipment such as battery packs, energy storage converters (PCS), multi-function meters, and load simulators. In actual operation, it was only possible to increase the load gradually by manually adjusting the load equipment one by one, and then observe the response changes of the energy storage system.
[0003] This traditional testing method has many defects: first, many test equipments are not only expensive to purchase, but also occupy a large area of the site, which brings considerable challenges to site planning and equipment maintenance; second, manual operation makes the test process lengthy and cumbersome, easy to introduce human errors, and requires extremely high operator requirements; third, the output accuracy and measurement accuracy of the test equipment itself are difficult to guarantee, which seriously affects the credibility of the test results. Especially when the power grid is integrated into the photovoltaic system, the situation is more complicated, and additional photovoltaic simulation equipment must be added. At this time, the test often requires the collaboration of multiple people to adjust the power of the load equipment and the photovoltaic equipment respectively, which not only further increases the labor cost and operation difficulty, but also makes it easy to make mistakes due to the complexity of personnel coordination, reducing the test efficiency and accuracy. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a simulation test method and device through a programmable logic controller to solve the problem that the traditional EMS demand control function test method is difficult to efficiently and accurately test the demand control function of the energy storage system due to complicated equipment, cumbersome manual operation, limited accuracy and difficulty in coordination.
[0005] In a first aspect, an embodiment of the present invention provides a simulation test method through a programmable logic controller, the method comprising:
[0006] Obtaining a current test task of the energy storage system, wherein the test task includes a demand control target value and a planned power;
[0007] Setting a simulated energy power based on the test task through a programmable logic controller, and calculating an initial incoming line power based on the simulated energy power and the initial energy storage power, wherein the programmable logic controller is connected to the energy storage system;
[0008] Sending the simulated energy power and the initial incoming power to the energy storage system, the energy storage system analyzing the simulated energy power and the planned power to obtain an analysis result, using the analysis result to update the planned power, and sending the updated planned power to the programmable logic controller;
[0009] The updated planned power is received, and the final incoming power is calculated using the updated planned power and the simulated energy power. If the final incoming power is less than or equal to the demand control target value, it is determined that the test has passed.
[0010] Further, setting the simulated energy power based on the demand control target value by a programmable logic controller includes:
[0011] Determining a first setting range and a second setting range by using the demand control target value, wherein the first setting range is a setting range of simulated load power, and the second setting range is a setting range of simulated photovoltaic power;
[0012] Acquiring energy consumption change data of the energy storage system;
[0013] The energy consumption change data is used to determine a simulated load power from the first setting range, and a simulated photovoltaic power from the second setting range.
[0014] Furthermore, the obtaining of energy consumption change data of the energy storage system includes:
[0015] Obtaining geographical environment information and climate environment information of the area where the energy storage system is located;
[0016] Acquire a first influencing factor of the geographic environment information on energy consumption and a second influencing factor of the climate environment information on energy consumption;
[0017] The basic energy consumption data of the energy storage system is calculated using the first influencing factor and the second influencing factor to obtain the energy consumption change data.
[0018] Further, the calculating the initial incoming line power based on the simulated energy power and the initial energy storage power includes:
[0019] Calculating the sum of the simulated load power and the initial energy storage power;
[0020] The difference between the sum and the simulated photovoltaic power is calculated, and the difference is used as the initial in-line power.
[0021] Furthermore, before determining that the test is passed, the method further includes:
[0022] Marking the moment when the programmable logic controller sets the simulated energy power as the first moment;
[0023] Marking the moment when the energy storage system feeds back the updated planned power as the second moment;
[0024] Calculating the difference between the second moment and the first moment to determine the response time of the energy storage system;
[0025] If the response time is less than or equal to the preset time, it is determined that the test passes.
[0026] Further, the energy storage system analyzes the simulated energy power and the planned power to obtain an analysis result, and updates the planned power using the analysis result, including:
[0027] The energy storage system analyzes the difference between the initial incoming line power and the demand control target value;
[0028] If the difference is greater than a preset value, analyzing the correlation between the simulated energy power and the expected operation of the energy storage system, and obtaining the adjustment range of the planned power;
[0029] If the adjustment range satisfies an update condition, the planned power is updated based on the correlation.
[0030] Further, updating the planned power based on the correlation includes:
[0031] Determining an update direction according to a comparison result between the correlation and a preset threshold;
[0032] Based on a mapping relationship between a preset correlation and a preset ratio, an update ratio corresponding to the correlation is determined, and the planned power is updated using the update direction and the update ratio.
[0033] In a second aspect, an embodiment of the present invention provides a simulation test device through a programmable logic controller, the device comprising:
[0034] An acquisition module, used to acquire a current test task of the energy storage system, wherein the test task includes a demand control target value and a planned power;
[0035] A calculation module, used for setting a simulated energy power based on the test task through a programmable logic controller, and calculating an initial incoming line power based on the simulated energy power and the initial energy storage power, wherein the programmable logic controller is connected to the energy storage system;
[0036] A sending module, used for sending the simulated energy power and the initial incoming line power to the energy storage system, and the energy storage system updates the planned power based on the simulated energy power and the initial incoming line power, and sends the updated planned power to the programmable logic controller;
[0037] The judgment module is used to receive the updated planned power and calculate the final incoming power using the updated planned power and the simulated energy power. If the final incoming power is less than or equal to the demand control target value, it is determined that the test has passed.
[0038] In a third aspect, an embodiment of the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, the memory storing computer instructions, and the processor executing the method of the first aspect or any corresponding embodiment thereof by executing the computer instructions.
[0039] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the method of the first aspect or any corresponding embodiment thereof.
[0040] The embodiments of the present application simplify the preliminary preparations for the test, abandon the traditional practice of using battery packs, load simulators and other complicated equipment to build the environment, directly obtain the test tasks including the demand control target value and the planned power, and reduce the site and equipment costs. Secondly, with the help of a programmable logic controller, the simulated energy power is automatically set and the initial incoming power is calculated, and the cumbersome process of manually adjusting the load is replaced by automated operations, avoiding human errors and improving efficiency. Then, the energy storage system and the controller automatically transmit and analyze data, and the planned power is updated based on the analysis results. There is no need for multiple people to operate multiple devices in coordination, avoiding coordination difficulties and mistakes. Finally, the entire process relies on a precise control system, which is not limited by the accuracy of traditional test equipment, ensuring accurate testing. The final incoming power meets the standard and is determined to have passed the test. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0042] Figure 1 is a flow chart of a simulation test method through a programmable logic controller according to some embodiments of the present invention;
[0043] Figure 2 is a flow chart of another simulation test method through a programmable logic controller according to some embodiments of the present invention;
[0044] Figure 3 is a structural block diagram of a simulation test device through a programmable logic controller according to an embodiment of the present invention;
[0045] Figure 4 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0046] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0047] According to an embodiment of the present invention, a simulation test method and device through a programmable logic controller are provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0048] In this embodiment, a simulation test method using a programmable logic controller is provided. Figure 1 is a flow chart of a simulation test method through a programmable logic controller according to an embodiment of the present invention, such as Figure 1 As shown, the process includes the following steps:
[0049] Step S101, obtaining the current test task of the energy storage system, wherein the test task includes a demand control target value and a planned power.
[0050] In an embodiment of the present application, a programmable logic controller (PLC) first establishes a stable communication connection with the energy storage system. This connection is based on a preset communication protocol to ensure the accuracy and timeliness of data interaction. Afterwards, the PLC sends a request instruction to the energy storage system to obtain the test task, clearly indicating the need to obtain relevant task information including the demand control target value and the planned power. After receiving the request, the energy storage system will search its own storage area for the corresponding test task data that the user has set. These data are set based on a comprehensive consideration of multiple factors such as the application scenario of the energy storage system, the requirements of the power grid, and the expected operating effect. Subsequently, the energy storage system returns the extracted demand control target value and initial energy storage power data to the PLC in full in accordance with the communication protocol specifications.
[0051] Step S102, setting simulated energy power based on the test task through a programmable logic controller, and calculating the initial incoming line power based on the simulated energy power and the initial energy storage power, wherein the programmable logic controller is connected to the energy storage system.
[0052] After the PLC successfully obtains the demand control target value and planned power in the test task, it starts the built-in simulation power setting module. This module reasonably sets the simulated load power and simulated photovoltaic power based on the specific value of the demand control target value, combined with the power system operation rules pre-stored in the PLC, past simulation experience data and related power equipment characteristic parameters, so as to determine the simulated energy power. For example, according to the approximate load conditions of the system reflected by the demand control target value, the size of the simulated load power and the expected output value of the simulated photovoltaic power are adjusted accordingly. After completing the setting of the simulated energy power, the PLC's calculation unit is immediately called, and according to the established electrical calculation formula "Pinline = Pload + P PCS -P Photovoltaic", substitute the simulated energy power just set and the initial energy storage power obtained, and calculate rigorously and accurately to obtain the initial incoming power. In the calculation process, the data will be verified and corrected to ensure the reliability of the obtained initial incoming power, providing an accurate data basis for subsequent interaction with the energy storage system.
[0053] In an embodiment of the present application, setting the simulated energy power based on the demand control target value by a programmable logic controller includes the following steps A1-A3:
[0054] Step A1, determining a first setting range and a second setting range by using a demand control target value, wherein the first setting range is a setting range of simulated load power, and the second setting range is a setting range of simulated photovoltaic power;
[0055] In the embodiment of the present application, the key parameter of the demand control target value that has been obtained is first extracted, which carries the power-related requirements expected by the energy storage system in the current test or operation stage. Based on the demand control target value, combined with the professional power model pre-built into the corresponding control system (such as a programmable logic controller, etc.) and the data experience accumulated from a large number of actual operations in the past, two different setting ranges are determined. Among them, for the simulated load power, based on the overall system load expectations reflected by the initial energy storage power, the power consumption characteristics of different time periods, and the role of the energy storage system in the entire power network, etc., the corresponding first setting range is obtained after comprehensive weighing, and the reasonable range in which the simulated load power can be changed is clarified; similarly, for the simulated photovoltaic power, the renewable energy utilization expectations involved in the initial energy storage power, the local sunshine duration and intensity and other related conditions are considered, so as to determine the corresponding second setting range, limit the range in which the simulated photovoltaic power can take values, and lay the foundation for further accurate determination of the specific simulated power value in the future.
[0056] Step A2: Obtain energy consumption change data of the energy storage system.
[0057] In an embodiment of the present application, obtaining energy consumption change data of an energy storage system includes: obtaining geographical environment information and climate environment information of the area where the energy storage system is located; obtaining a first influencing factor of the geographical environment information on energy consumption and a second influencing factor of the climate environment information on energy consumption; and using the first influencing factor and the second influencing factor to calculate the basic energy consumption data of the energy storage system to obtain energy consumption change data.
[0058] First, through various professional geographic information collection methods (such as satellite positioning data, geographic surveying and mapping information, etc.) and meteorological monitoring equipment (such as temperature, humidity, light and other data collected by meteorological stations), the geographical environment information and climate environment information of the area where the energy storage system is located are obtained. This information covers many aspects such as topography, altitude, sunshine conditions, temperature change range, etc. Then, based on professional energy analysis theory and a large number of past research results on the energy consumption performance of energy storage systems under different geographical and climatic conditions, the first influencing factor of geographical environment information on energy consumption and the second influencing factor of climate environment information on energy consumption are analyzed. These influencing factors accurately quantify the degree of effect of environmental factors on the energy consumption of energy storage systems. Finally, using these influencing factors, combined with the basic energy consumption data of the energy storage system itself (such as the theoretical energy consumption value under standard environment, etc.), rigorous mathematical calculations are performed according to the established energy consumption calculation model, so as to obtain energy consumption change data that can reflect the energy consumption changes of the energy storage system in the current actual environment.
[0059] Step A3: using the energy consumption change data, determine the simulated load power from the first set range, and determine the simulated photovoltaic power from the second set range.
[0060] In an embodiment of the present application, for the simulated load power, the energy consumption change data is substituted into the analysis and judgment of the first setting range, and the relationship between the current energy consumption situation and the simulated load power setting range is comprehensively considered. For example, if the energy consumption change data shows that the current energy consumption is high, a lower simulated load power value is selected in the first setting range. Through such dynamic weighing and matching, the simulated load power that meets the current energy consumption actual situation is accurately determined from the first setting range; similarly, for the simulated photovoltaic power, based on the energy utilization demand reflected by the energy consumption change data and the impact of the environment on the photovoltaic power, combined with the second setting range, the most suitable simulated photovoltaic power value under the current energy consumption state is analyzed, so as to accurately determine the simulated photovoltaic power from the second setting range, so that the determination of the simulated load power and the simulated photovoltaic power can fully consider the key factor of energy consumption change, and provide more practical simulated power parameters for subsequent system testing or operation.
[0061] In an embodiment of the present application, the initial incoming line power is calculated based on the simulated energy power and the initial energy storage power, including: calculating the sum of the simulated load power and the initial energy storage power; calculating the difference between the sum and the simulated photovoltaic power, and using the difference as the initial incoming line power.
[0062] Step S103, sending the simulated energy power and the initial incoming line power to the energy storage system, the energy storage system analyzes the simulated energy power and the planned power to obtain an analysis result, uses the analysis result to update the planned power, and sends the updated planned power to the programmable logic controller.
[0063] In the embodiment of the present application, the PLC uses the established communication link with the energy storage system, and in accordance with the pre-agreed communication protocol, organizes and packages the determined simulated energy power and the calculated initial incoming power to form a standardized data message, and then sends it to the energy storage system accurately. After receiving these data, the energy storage system immediately activates its built-in data analysis and processing module, which integrates complex data analysis algorithms, power system operation status assessment models, and optimization strategies summarized based on a large number of actual operation cases. Through a comprehensive and in-depth analysis of the simulated energy power and the initial incoming power, considering factors such as the real-time load of the current power grid, the health of the energy storage system, and the power regulation target to be achieved, a detailed analysis result is obtained. Based on this analysis result, the intelligent decision-making module inside the energy storage system will further determine whether the planned power needs to be adjusted and the specific adjustment direction and amplitude, so as to accurately update the planned power. After the update is completed, the energy storage system will then transmit the updated planned power back to the PLC safely and stably through the same communication link in accordance with the communication protocol requirements.
[0064] In the embodiment of the present application, the energy storage system analyzes the simulated energy power and the planned power to obtain an analysis result, and updates the planned power using the analysis result, including the following steps B1-B3:
[0065] Step B1: The energy storage system analyzes the difference between the initial incoming power and the demand control target value.
[0066] Specifically, the two key data of the calculated initial incoming power and the pre-set demand control target value are obtained, and then the corresponding mathematical operation function is used to subtract the initial incoming power from the demand control target value according to the difference calculation rules, so as to obtain the accurate difference between the two. This difference can intuitively reflect the degree of deviation between the actual incoming power of the current system and the expected target value, providing an important basis for subsequent judgment on whether the system needs further adjustment.
[0067] Step B2: If the difference is greater than a preset value, the correlation between the planned power and the expected operation of the energy storage system is analyzed, and the adjustment range of the planned power is obtained.
[0068] Specifically, the calculated difference is compared with the preset value. If the difference is found to be greater than the preset value, it means that there is a large deviation between the current system's operating status and the expected target. At this time, the energy storage system will automatically activate the deep analysis function. On the one hand, the correlation analysis is carried out for the simulated energy power and the expected operation of the energy storage system. The simulated load power, simulated photovoltaic power and other elements contained in the simulated energy power will be comprehensively considered. The degree of fit between the expected operating conditions, such as the expected charging and discharging state, the expected contribution to the power balance of the power grid, and other requirements, will be comprehensively considered. With the help of professional data models and the accumulated operating experience in the past, the specific correlation value between the two is quantitatively analyzed. On the other hand, based on the performance boundaries of the energy storage system's own hardware (such as the maximum capacity of the battery, the charging and discharging power limit, etc.), combined with the real-time load carrying capacity of the external power grid, the possible impact of current energy market price fluctuations and many other factors, the built-in intelligent decision-making algorithm is used to accurately obtain the adjustment range of the planned power, and clarify the reasonable range of changes in the planned power under the current conditions.
[0069] Step B3: if the adjustment range meets the update condition, the planned power is updated based on the correlation.
[0070] In an embodiment of the present application, the planned power is updated based on the correlation, including: determining an update direction based on a comparison result between the correlation and a preset threshold; determining an update ratio corresponding to the correlation based on a mapping relationship between a preset correlation and a preset ratio, and updating the planned power using the update direction and the update ratio.
[0071] When it is determined that the adjustment range meets the update conditions, the planned power is updated based on the correlation. First, the update direction is determined based on the comparison result between the correlation and the preset threshold. For example, if the correlation is lower than a preset threshold and the expected operation is to increase the discharge power of the energy storage system, then the update direction may be to increase the value of the corresponding discharge part in the planned power. Next, based on the mapping relationship between the preset correlation and the preset ratio, the update ratio corresponding to the current correlation is found. For example, when the correlation is in a certain range, it corresponds to a certain proportion of the planned power adjustment range. Finally, using the determined update direction and update ratio, the planned power is accurately updated according to the established operation rules, so that the planned power can better fit the expected operating state of the energy storage system and ensure that the subsequent operation of the system is more in line with the expected goals.
[0072] Step S104, receiving the updated planned power, and calculating the final incoming power using the updated planned power and the simulated energy power. If the final incoming power is less than or equal to the demand control target value, it is determined that the test has passed.
[0073] In the embodiment of the present application, the updated planned power information from the energy storage system is accurately received through the communication interface. Subsequently, the PLC quickly transmits the updated planned power together with the previously set simulated energy power to its own computing unit. The computing unit once again enables "P in = P load + P PCS -P photovoltaic" calculation formula, but this time the updated planned power is substituted for calculation. The entire calculation process strictly follows the established calculation rules and accuracy requirements. After a rigorous calculation process, the final incoming power is obtained. Then, the judgment module in the PLC will carefully compare the final incoming power with the demand control target value obtained initially. If the final incoming power is less than or equal to the demand control target value, it means that the energy storage system has successfully achieved the expected control requirements after a series of simulation, calculation and adjustment operations during this test. The PLC will trigger the corresponding test pass judgment mechanism, such as generating a test pass identification information or sending a test pass notification to the external monitoring system, so as to determine that the test has passed; on the contrary, if the final incoming power is greater than the demand control target value, it means that the test requirements have not been met, and it is necessary to return to the corresponding link for investigation and adjustment, and then restart the entire test process.
[0074] In an embodiment of the present application, before determining that the test has passed, the method also includes: marking the moment when the programmable logic controller sets the simulated energy power as a first moment; marking the moment when the energy storage system feeds back the updated planned power as a second moment; calculating the difference between the second moment and the first moment to determine the response time of the energy storage system; if the response time is less than or equal to the preset time, determining that the test has passed.
[0075] Specifically, first, when the entire process starts to execute the operation of setting the simulated energy power by the programmable logic controller (PLC), the timing module inside the PLC will immediately start the relevant timing function and accurately mark this moment as the first moment. The record of this first moment is the starting point of the entire response time calculation. It relies on the high-precision clock mechanism of the PLC itself, which can be accurate to milliseconds or even smaller time units, ensuring the accuracy of time recording and providing reliable initial time data for subsequent comparative analysis.
[0076] Then, in the subsequent process, when the energy storage system completes the update of the planned power and feeds the updated planned power back to the programmable logic controller, the PLC calls the timing module again and marks the moment of receiving the updated planned power as the second moment. Similarly, the recording of this moment is also based on the precise clock function of the PLC, and is recorded strictly according to the actual situation of the time, ensuring that there is no deviation in the time mark.
[0077] Then, the PLC's computing unit will be activated, and the function module dedicated to calculating the response time will start working. It will obtain the previously recorded first and second time data, and according to the time difference calculation rules, subtract the first time from the second time to obtain the difference between the two, which is the response time of the energy storage system. The entire calculation process follows strict time calculation logic to ensure that the calculation results accurately reflect the time from the PLC setting the simulated energy power to the energy storage system feedback update of the initial energy storage power.
[0078] Finally, the PLC will compare the calculated response time with the preset time. The preset time is a time threshold that is pre-set based on multiple factors such as the design requirements of the energy storage system, overall performance indicators, and actual application scenarios. If the response time is found to be less than or equal to the preset time after comparison, this means that the energy storage system has completed the corresponding operation within the specified time and has achieved the expected response speed requirements. At this time, the PLC will determine that the test has passed and the entire process can be successfully completed; conversely, if the response time is greater than the preset time, it means that the response speed of the energy storage system does not meet the requirements, and it is necessary to return to the relevant links for the developer to troubleshoot possible problems, modify the program, and retest until the response time requirements are met.
[0079] As an example, Figure 2 As shown, the demand control target value and planned power are set in the EMS system. The PLC sets the simulated load (or photovoltaic) power in a single step / automatically, and the PLC records this moment tA:
[0080] The PLC sets the simulated load (or photovoltaic) power in single step or automatically. The PLC records the current time tA.
[0081] EMS sends PCS set power to PLC, and PLC records the change of set power tB: EMS sends PCS (power regulation system) set power to PLC. PLC records the time tB when the set power changes.
[0082] EMS system demand control response time Δt=tB-tA: Calculate the EMS system demand control response time Δt, the calculation formula is tB minus tA.
[0083] Determine whether Δt is less than or equal to the design requirement: If Δt is less than or equal to the design requirement, the process proceeds to the next step. If Δt is greater than the design requirement, return to "Developers modify the program and retest".
[0084] Test passed: If the conditions are met, the test passes and the process ends.
[0085] In the present embodiment, a simulation test device through a programmable logic controller is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceived.
[0086] This embodiment provides a simulation test device through a programmable logic controller, such as Figure 3 As shown, including:
[0087] An acquisition module 301 is used to acquire a current test task of the energy storage system, wherein the test task includes a demand control target value and a planned power;
[0088] A calculation module 302 is used to set the simulated energy power based on the test task through a programmable logic controller, and calculate the initial incoming line power based on the simulated energy power and the initial energy storage power, wherein the programmable logic controller is connected to the energy storage system;
[0089] The sending module 303 is used to send the simulated energy power and the initial incoming line power to the energy storage system, and the energy storage system updates the planned power based on the simulated energy power and the planned power, and sends the updated planned power to the programmable logic controller;
[0090] The judgment module 403 is used to receive the updated planned power and calculate the final incoming power using the updated planned power and the simulated energy power. If the final incoming power is less than or equal to the demand control target value, it is determined that the test is passed.
[0091] In an embodiment of the present application, the calculation module 302 is used to determine a first setting range and a second setting range using a demand control target value, wherein the first setting range is a setting range of a simulated load power, and the second setting range is a setting range of a simulated photovoltaic power; obtain energy consumption change data of the energy storage system; use the energy consumption change data to determine the simulated load power from the first setting range, and determine the simulated photovoltaic power from the second setting range.
[0092] In an embodiment of the present application, the calculation module 302 is used to obtain the geographical environment information and the climate environment information of the area where the energy storage system is located; obtain the first influencing factor of the geographical environment information on energy consumption and the second influencing factor of the climate environment information on energy consumption; use the first influencing factor and the second influencing factor to calculate the basic energy consumption data of the energy storage system to obtain energy consumption change data.
[0093] In the embodiment of the present application, the calculation module 302 is used to calculate the sum of the simulated load power and the initial energy storage power; calculate the difference between the sum and the simulated photovoltaic power, and use the difference as the initial incoming line power.
[0094] In an embodiment of the present application, the device also includes: a verification module, which is used to mark the moment when the programmable logic controller sets the simulated energy power as the first moment; mark the moment when the energy storage system feeds back the updated planned power as the second moment; calculate the difference between the second moment and the first moment to determine the response time of the energy storage system; if the response time is less than or equal to the preset time, it is determined that the test has passed.
[0095] In an embodiment of the present application, a sending module 303 is used for the energy storage system to analyze the difference between the initial incoming line power and the demand control target value; if the difference is greater than a preset value, the correlation between the planned power and the expected operating conditions of the energy storage system is analyzed, and the adjustment range of the planned power is obtained; if the adjustment range meets the update conditions, the planned power is updated based on the correlation.
[0096] In an embodiment of the present application, the sending module 303 is used to determine the update direction based on the comparison result between the correlation and the preset threshold; based on the mapping relationship between the preset correlation and the preset ratio, determine the update ratio corresponding to the correlation, and use the update direction and update ratio to update the planned power.
[0097] See also Figure 4 , Figure 4 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Figure 4As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 4 A processor 10 is taken as an example.
[0098] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be a dedicated integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.
[0099] The memory 20 stores instructions executable by at least one processor 10, so that the at least one processor 10 executes the method shown in the above embodiment.
[0100] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created by the use of a computer device based on the presentation of a small program landing page, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0101] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.
[0102] The computer device further comprises a communication interface 30 for the computer device to communicate with other devices or a communication network.
[0103] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.
[0104] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.
Claims
1. A simulation test method using a programmable logic controller, characterized in that: The method comprises: Obtaining a current test task of the energy storage system, wherein the test task includes a demand control target value and a planned power; Setting a simulated energy power based on the test task through a programmable logic controller, and calculating an initial incoming line power based on the simulated energy power and the initial energy storage power, wherein the programmable logic controller is connected to the energy storage system; Sending the simulated energy power and the initial incoming power to the energy storage system, the energy storage system analyzing the simulated energy power and the planned power to obtain an analysis result, using the analysis result to update the planned power, and sending the updated planned power to the programmable logic controller; The updated planned power is received, and the final incoming power is calculated using the updated planned power and the simulated energy power. If the final incoming power is less than or equal to the demand control target value, it is determined that the test has passed.
2. The method according to claim 1, characterized in that The step of setting the simulated energy power based on the test task by a programmable logic controller includes: Determining a first setting range and a second setting range by using the demand control target value, wherein the first setting range is a setting range of simulated load power, and the second setting range is a setting range of simulated photovoltaic power; Acquiring energy consumption change data of the energy storage system; The energy consumption change data is used to determine a simulated load power from the first setting range, and a simulated photovoltaic power from the second setting range.
3. The method according to claim 2, characterized in that The obtaining of energy consumption change data of the energy storage system includes: Obtaining geographical environment information and climate environment information of the area where the energy storage system is located; Acquire a first influencing factor of the geographic environment information on energy consumption and a second influencing factor of the climate environment information on energy consumption; The basic energy consumption data of the energy storage system is calculated using the first influencing factor and the second influencing factor to obtain the energy consumption change data.
4. The method according to claim 2, characterized in that: The calculating the initial incoming line power based on the simulated energy power and the initial energy storage power includes: Calculating the sum of the simulated load power and the initial energy storage power; The difference between the sum and the simulated photovoltaic power is calculated, and the difference is used as the initial in-line power.
5. The method according to claim 1, characterized in that Before determining that the test passes, the method further includes: Marking the moment when the programmable logic controller sets the simulated energy power as the first moment; Marking the moment when the energy storage system feeds back the updated planned power as the second moment; Calculating the difference between the second moment and the first moment to determine the response time of the energy storage system; If the response time is less than or equal to the preset time, it is determined that the test passes.
6. The method according to claim 1, characterized in that The energy storage system analyzes the simulated energy power and the planned power to obtain an analysis result, and updates the planned power using the analysis result, including: The energy storage system analyzes the difference between the initial incoming line power and the demand control target value; If the difference is greater than a preset value, analyzing the correlation between the simulated energy power and the expected operation of the energy storage system, and obtaining the adjustment range of the planned power; If the adjustment range satisfies an update condition, the planned power is updated based on the correlation.
7. The method according to claim 6, characterized in that The updating of the planned power based on the correlation comprises: Determining an update direction according to a comparison result between the correlation and a preset threshold; Based on the mapping relationship between the preset correlation and the preset ratio, the update ratio corresponding to the correlation is determined, and the planned power is updated using the update direction and the update ratio.
8. A simulation test device using a programmable logic controller, characterized in that: The device comprises: An acquisition module, used to acquire a current test task of the energy storage system, wherein the test task includes a demand control target value and a planned power; A calculation module, used for setting a simulated energy power based on the test task through a programmable logic controller, and calculating an initial incoming line power based on the simulated energy power and the initial energy storage power, wherein the programmable logic controller is connected to the energy storage system; A sending module, used for sending the simulated energy power and the initial incoming line power to the energy storage system, and the energy storage system updates the planned power based on the simulated energy power and the initial incoming line power, and sends the updated planned power to the programmable logic controller; The judgment module is used to receive the updated planned power and calculate the final incoming power using the updated planned power and the simulated energy power. If the final incoming power is less than or equal to the demand control target value, it is determined that the test has passed.
9. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the method according to any one of claims 1 to 7 by executing the computer instructions.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 7.