A method for developing an energy management system and an energy management system

Through code decoupling, modular design and plug-in technology, the serious and repetitive development of existing energy management systems are solved, and a more efficient, flexible and scalable energy management system is achieved.

CN119556920BActive Publication Date: 2025-05-30SUZHOU RCT POWER ENERGY TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510127513.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-05
Publication Date
2025-05-30
Estimated Expiration
2045-02-05

AI Technical Summary

Technical Problem

The existing energy management system has shortcomings in reusability, uniformity of graphical user interface design and personalization of functional requirements, resulting in serious customization and repeated development problems.

Method used

Improve system flexibility and reusability through code decoupling, functional modularity and plug-in design. The system is divided into independent modules such as device access, human-computer interface and control strategy, and the configuration file-driven interface is customized and plug-in design is used to dynamically load the required functional modules and control strategies.

Benefits of technology

It significantly improves the flexibility, reusability and customization of the system, reduces development costs and time, and improves the overall performance and reliability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119556920B_ABST
    Figure CN119556920B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for developing an energy management system and an energy management system, aiming to improve the flexibility, reusability, customizability, and scalability of the industrial and commercial energy storage management system, and reduce the development cost and time. The present invention divides the energy management system into independent modules such as device access, control strategy, and human-machine interface, realizes code decoupling, reduces the coupling between functional modules, and facilitates the expansion and maintenance of the system. Adopting a plug-in design, different functions are encapsulated as independent plug-ins, and the required plug-ins are dynamically loaded according to the configuration at runtime, thereby supporting flexible function combinations and customized configurations. At the same time, the system is driven by a configuration file, dynamically loads interface elements, and adjusts the layout and interaction mode according to requirements. In the control strategy part, the separation of the state module and the mode module simplifies the implementation and modification of the strategy, and enhances the customizability of the system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of software development, and particularly relates to a method for developing an energy management system and an energy management system. Background Art

[0002] As an important solution for optimizing energy management, industrial and commercial energy storage systems can not only effectively balance the supply and demand relationship, but also provide economic benefits for enterprises when electricity prices fluctuate. In this process, the role of the energy management system becomes increasingly important. It is responsible for multiple functions such as real-time monitoring of energy storage devices, data collection and processing, status assessment, and strategy management. In the current market, there are numerous solutions for energy management systems, and the competition among various technologies and products is becoming increasingly fierce, promoting the continuous evolution of related technologies.

[0003] However, existing energy management software still has many deficiencies in actual applications. Firstly, many systems perform poorly in terms of reusability, resulting in a large amount of customized development for each project. This not only increases the development cost but also extends the project implementation cycle. Secondly, the design of the graphical user interface often lacks unity, and developers need to redraw the interface in different projects, causing waste of resources. In addition, due to the diversity and complexity of the application scenarios of industrial and commercial energy storage products, as well as the differences in device access, networking methods, and control strategies, the functional requirements of the energy management system show a high degree of personalization, further exacerbating the difficulty of software development.

[0004] In this context, there is an urgent need for a new technical solution to solve problems such as serious customization and repeated development in existing energy management systems. Summary of the Invention

[0005] To solve the above technical problems, the present invention provides a method for developing an energy management system and an energy management system, aiming to improve the flexibility and reusability of the industrial and commercial energy storage energy management system through means such as code decoupling, functional modularization, and plug-inization, so as to achieve more efficient energy management and scheduling. Through these technological innovations, not only can the development cost and time be reduced, but also the reliability and overall performance of the system can be improved, contributing to the sustainable development of the industrial and commercial energy storage industry.

[0006] The technical solution provided by the present invention is as follows:

[0007] A method for developing an energy management system, comprising:

[0008] Code decoupling: dividing the energy management system into independent functional units, each functional unit being included in a different software package; the functional units include a device access unit, a human-machine interface unit, and a control strategy unit;

[0009] Module Decomposition: The device access unit is decomposed into independent functional modules, including a device module and a communication module. The device module is used to access hardware devices, and the communication module includes communication interfaces for all accessed devices and corresponding communication protocols. The human-machine interface unit is decomposed into independent functional modules, including a display interface and a control interface. The display interface is used to display the energy storage station, and the control interface is used for function switching and operations. The control strategy unit is decomposed into independent functional modules, including a status module and a mode module. The status module is used to obtain the operating status of the energy storage station, and the mode module calls corresponding control strategies according to the operating status of the energy storage station.

[0010] Interface Customization: The human-machine interface unit loads different interface elements according to the configuration file, and each interface element corresponds to an accessed device or functional module.

[0011] Pluginization: Different functional modules, devices, and strategies are encapsulated into independent plugins and dynamically loaded according to the configuration file during system operation.

[0012] Furthermore:

[0013] Multiple operating states of the energy storage station are defined in the status module. The status module continuously collects and updates the status information of the energy storage station through data sensors, determines the current operating state of the energy storage station based on this status information, and sends it to the mode module.

[0014] The mode module contains a set of specific control strategies, which describe how the energy storage station should perform control operations in the current operating state. After receiving the status signal, the mode module selects an appropriate control strategy according to the current state and starts to execute it.

[0015] Furthermore, the configuration file contains the interface elements required to be displayed on the interface, and defines the appearance, interaction method, and associated data and methods of each interface element in the interface. When the system starts, it will read and parse the configuration file, dynamically generate and display the corresponding interface elements according to the information in the configuration, and bind the corresponding data sources and control methods.

[0016] Furthermore, the control strategy of the interface element is specified in the configuration file. During system operation, the corresponding control strategy will be dynamically loaded and executed according to the definition in the configuration file. The interaction operations of the user on the interface will trigger the execution of the control strategy.

[0017] Furthermore, the layout information of the interface element is set in the configuration file, including the size and position on devices with different screen resolutions. When the system starts, each interface element adaptively adjusts its own layout according to the layout information in the configuration file and the current device.

[0018] Furthermore, the plug-in approach includes device driver plug-in and operation policy plug-in:

[0019] Device plug-in: Encapsulate device drivers of different brands and models into independent plug-ins, and provide communication and control interfaces for the corresponding devices in the plug-ins; Users specify the required device plug-ins through a configuration file, and the system loads the required plug-ins at runtime according to the configuration file and calls the interfaces provided by the plug-ins to manage and control the devices;

[0020] Policy plug-in: Customize control policies according to different scenario requirements and encapsulate them as independent plug-ins. Users specify the required policy plug-ins through a configuration file, and the system loads the required plug-ins at runtime according to the configuration file and switches different control policies according to the requirements.

[0021] An energy management system developed based on the above method includes a device access unit, a human-machine interface unit, and a control policy unit, as well as a configuration file, several device plug-ins, and policy plug-ins;

[0022] The device access unit includes a device module and a communication module. The device module is used to access hardware devices, and the communication module includes communication interfaces and corresponding communication protocols for all accessed devices; The device plug-ins include device drivers of different brands and models and provide communication and control interfaces for the corresponding devices; Users specify the required device plug-ins in the configuration file;

[0023] The human-machine interface unit includes a display interface and a control interface. The display interface is used to display the energy storage station, and the control interface is used for function switching and operation; Users define the appearance, layout, interaction methods, and associated data and methods of each interface element in the interface through a configuration file;

[0024] The control policy unit includes a status module and a mode module. The status module is used to obtain the operating status of the energy storage station, and the mode module calls the corresponding control policy according to the operating status of the energy storage station; The status module includes multiple operating statuses of the energy storage station, and the mode module includes multiple corresponding control policies. The operating status and its corresponding control policy are customized by the policy plug-ins specified by the user through the configuration file.

[0025] Preferably, it further includes several interface element plug-ins, and users select and match the interface elements to be displayed for the human-machine interface unit through a configuration file.

[0026] Preferably, it further includes a log module for recording information during the system operation, including user operation information, warning information, and error information.

[0027] Compared with the prior art, the present invention has at least the following beneficial effects:

[0028] Through innovative means such as code decoupling, modular design, plug-in architecture, and interface customization, the present invention significantly enhances the flexibility, reusability, and customizability of the system, presenting significant advantages compared to existing technologies. Firstly, by dividing the system into independent modules such as device access, human-machine interface, and control strategies, the coupling between different functions is reduced, enabling each module to be independently updated and expanded. This reduces the need for frequent code modifications during development, lowering development costs and time. Secondly, the plug-in design further enhances the system's flexibility. The system can dynamically load the required plug-ins according to the configuration to meet the personalized needs of different scenarios, while reducing memory occupancy and optimizing system performance. In addition, through the dynamic loading of interface elements and configuration file-driven operation, the system can adaptively adjust the interface layout and control strategies in different devices and scenarios, providing a higher level of customization capabilities.

[0029] Overall, the present invention not only improves the overall performance and reliability of the energy management system but also provides an efficient, flexible, and scalable solution for the industrial and commercial energy storage field. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] The drawings are used to provide a further understanding of the present invention and form a part of the specification. They are used in conjunction with the embodiments of the present invention to explain the present invention and do not constitute a limitation to the present invention.

[0031] Figure 1 It is a schematic diagram of the system software package provided by an embodiment of the present invention;

[0032] Figure 2 It is a schematic diagram of the system module composition provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0033] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions 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 some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the protection scope of the present invention.

[0034] Embodiment 1

[0035] This embodiment provides a method for developing an energy management system.

[0036] The energy management system of an industrial and commercial energy storage station can generally be divided into three parts: device access, networking method, and control strategy. Device access is to connect devices such as energy storage cabinets, photovoltaic systems, and loads to the station. These devices form a network according to a specific networking method, and the station operates according to a specific control strategy to achieve the safe and stable operation of the station.

[0037] In view of the serious customization of the industrial and commercial energy storage energy management system, the following development solution is adopted in this embodiment:

[0038] 1. Code decoupling

[0039] The energy management system of industrial and commercial energy storage is functionally divided into three major units, namely device access, interaction interface, and control strategy. As Figure 1 shown, the entire energy management system software consists of three packages: the Device package for device access, the MicroGrid package for the interaction interface, and the Strategy package for the control strategy.

[0040] The Device package: contains all the access device types in industrial and commercial energy storage and the communication interfaces of these devices.

[0041] The MicroGrid package: contains the composition method of the system interface and the corresponding composition methods of each graphic element on the interface.

[0042] The Strategy package: contains the control strategies when the devices in the industrial and commercial energy management system are networked and operated, including the states and the control modes corresponding to each state.

[0043] Code decoupling is achieved from these three major aspects. The role of decoupling is to separate the system functionally. When the devices accessed in a project are different while others are the same, only the code of the accessed devices needs to be modified, and the codes of the interaction interface and the control strategy can remain unchanged. Similarly, the codes of the other two major functional modules can also be modified due to differences.

[0044] 2. Function decomposition

[0045] According to the above three major functional units, the system code is further decomposed into smaller software modules.

[0046] As Figure 2 shown, the code of the entire system is functionally divided into the following six modules, namely:

[0047] DEV: That is, the device module. All the device types accessed by the stations are included in this module. If the same devices are used in different stations, the device code can be reused, reducing the workload of repeated development.

[0048] COM: That is, the communication module. The communication module contains the communication interfaces of all devices, including various corresponding protocols, such as Modbus, CAN, etc. The same protocol is completely reused in different devices.

[0049] HMI: That is, the human-machine interface, which realizes the display interface and human-machine interaction control interface of the station. The main interface displays the overall interface of the station, and the human-machine interaction control interface realizes the operation and switching of functions.

[0050] MODE: That is, the mode module. The policy modes of all stations are formulated according to the control requirements of the station. When the control requirements are different, the mode codes are different. Conversely, the mode codes can be reused.

[0051] STATE: That is, the state module. The state module indicates the state of the station. Together with the MODE module, it forms the control strategy unit of the station. When the station is in different states, different modes will run. The state codes in the same state can be reused in different stations.

[0052] LOG: That is, the log module. The log module combines with any other module to realize information reminder and information recording.

[0053] When the software is implemented, these modules are implemented according to the corresponding components, as Figure 2 shown in the software component diagram. Then, the components are implemented using the corresponding classes.

[0054] 3. Interface entity customization

[0055] Interface entity customization means that in the human-machine interface (HMI) of the energy management system, different primitives (interface elements) are dynamically loaded according to a specific configuration file. These primitives represent various entities in the system (such as devices, sensors, control strategies, etc.). In this way, the system can quickly customize and display the interface in different scenarios, ensuring that the interface content and interaction methods match the user requirements and application scenarios, while reducing development and maintenance costs.

[0056] Specifically, interface entity customization is achieved through the following steps and technologies:

[0057] 3.1 Configuration file-driven interface entity customization

[0058] The configuration file (such as YAML, JSON, or XML) contains information about the entities and primitives to be displayed on the interface. Each primitive corresponds to a device or function module. The configuration file defines the appearance, interaction method, associated data, and methods of the primitive in the interface. The configuration file can support the definition of different types of interface elements (such as icons, buttons, display boxes, charts, etc.).

[0059] The entity information in the configuration file includes:

[0060] Entity type: Such as photovoltaic inverter, energy storage device, load, etc.

[0061] Primitive types: such as icons, progress bars, line charts, dashboards, etc.

[0062] Position and layout: Specify the position, size, display style, etc. of each primitive in the interface.

[0063] Data binding: Define the data structure and methods bound to each primitive.

[0064] Interaction behaviors: such as clicks, drags, button click events, etc.

[0065] Control strategy association: Configure the association between primitives and control methods and strategies.

[0066] The following gives an example of a configuration file (JSON format):

[0067] {

[0068] "entities":

[0069] {

[0070] "type": "inverter",

[0071] "id": "PV1",

[0072] "icon": "icon_pv.png",

[0073] "layout": {"x": 100, "y": 150, "width": 200, "height": 100},

[0074] "data": {

[0075] "voltage": "sensor_voltage_PV1",

[0076] "current": "sensor_current_PV1",

[0077] "power": "sensor_power_PV1"

[0078] },

[0079] "methods": {

[0080] "start": "start_inverter_PV1",

[0081] "stop": "stop_inverter_PV1"

[0082] },

[0083] "control_strategy": "charging_mode"

[0084] },

[0085] {

[0086] "type": "battery",

[0087] "id": "BAT1",

[0088] "icon": "icon_battery.png",

[0089] "layout": {"x": 400, "y": 150, "width": 200, "height": 100},

[0090] "data": {

[0091] "state_of_charge": "sensor_soc_BAT1",

[0092] "temperature": "sensor_temp_BAT1"

[0093] },

[0094] "methods": {

[0095] "charge": "charge_battery_BAT1",

[0096] "discharge": "discharge_battery_BAT1"

[0097] },

[0098] "control_strategy": "balancing_mode"

[0099] }

[0101] }

[0102] 3.2 Dynamic loading of interface primitives

[0103] (1)Load the configuration file when the interface starts

[0104] ​At system startup, the interface component will read the configuration file and parse the entity definitions therein, and dynamically generate and display corresponding interface elements according to the information in the configuration. The graphic primitives of each entity (such as the icon of a photovoltaic inverter, the battery icon of an energy storage device, etc.) are dynamically placed according to the layout information in the configuration, and the corresponding data sources and control methods are bound.

[0105] When the graphic primitive is loaded, the appearance, data, and interaction behavior of the graphic primitive are initialized through the settings in the configuration file. The interface does not require hard coding and can flexibly change according to different scenarios and requirements.

[0106] (2)Binding and Update of Entity Graphic Primitives

[0107] Each graphic primitive is bound to a specific data structure (such as device data, sensor information, etc.). For example, the graphic primitive of a photovoltaic inverter may be bound to data such as the voltage, current, and power of the photovoltaic inverter, while the battery graphic primitive is bound to data such as the charging state of the battery, the battery temperature, and the SOC (State of Charge).

[0108] Data Binding: The interface updates the display content of the graphic primitive in real time through data binding technology (such as using the DataBinding framework). For example, when the current of the photovoltaic inverter changes, the graphic primitive will automatically update to display the current current value.

[0109] Method Binding: In addition to data binding, the graphic primitive can also be bound to specific control methods. For example, the graphic primitive of a photovoltaic inverter may have "start" and "stop" buttons, which are bound to the corresponding control methods (such as start_inverter_PV1 and stop_inverter_PV1). When the user clicks the button, the control method will be triggered, and then the corresponding device control strategy (such as starting or stopping the inverter) will be called.

[0110] (3)Update and Event Response

[0111] Real-time Update: The display of the graphic primitive will be updated in real time as the system state changes. For example, the battery state (SOC) of the energy storage device changes during the charging and discharging process, and the battery graphic primitive on the interface will be updated accordingly to display the current battery charging percentage.

[0112] User Interaction: The interface provides interaction functions (such as buttons, sliders, switches, etc.). When the user performs an operation, the associated method between the graphic primitive and the control strategy will be called, and then the behavior of the device will be triggered. For example, clicking the "start" button will trigger the start_inverter_PV1 method to control the photovoltaic inverter to start working.

[0113] 3.2 Association of Control Strategies and Methods

[0114] (1)Dynamic binding of control strategies and graphic elements

[0115] Each graphic element can not only bind data but also corresponding control strategies. In the configuration file, each entity graphic element can specify its corresponding control strategy. For example, a photovoltaic inverter may be associated with "charging mode", and a battery may be associated with "balancing mode".

[0116] When a graphic element is associated with a control strategy, interactive operations on the interface (such as button clicks, slider adjustments, etc.) will trigger the execution of the control strategy. For example, when the user clicks the "Start" button, the interface will call the bound control method (such as start_inverter_PV1), and at the same time adjust the operation mode according to the specified control strategy (such as entering the "charging mode").

[0117] (2)Dynamic invocation of strategies and control methods

[0118] When the system is running, each graphic element will dynamically load and execute the corresponding control strategy according to the definition in its configuration file. For example, the configuration file of the photovoltaic inverter graphic element specifies the "charging mode" control strategy and associates it with the control method charge_inverter_PV1 for charging.

[0119] The control strategy itself can be dynamically loaded. For example, by introducing a plug-in mechanism, users can be allowed to select different strategies according to different operating scenarios and requirements. For example, some projects may need to introduce the "maximum power point tracking (MPPT)" control strategy, while other projects use a simple voltage-based charging strategy.

[0120] 3.3 Dynamic interaction and custom interface functions

[0121] (1)Custom interface functions

[0122] In addition to basic data and method binding, users are also allowed to dynamically customize the interactive functions of graphic elements through the configuration file. For example, users can choose whether to display the status information of the device, whether to enable the alarm function, whether to provide remote control of the device, etc. Users can also customize the color, icon, animation effect, etc. of the graphic element according to their needs, making the interface more flexible and personalized.

[0123] (2)Adaptive interface layout

[0124] The "layout" section in the configuration file can specify information such as the position and size of the graphic element, and automatically adjust the layout on different screen resolutions or devices. In this way, no matter whether the user uses a mobile phone, a tablet or a desktop, the interface can be adaptively adjusted according to the device characteristics to ensure a good user experience.

[0125] Through the customization of interface entities driven by configuration files, the system can dynamically load and adjust the interface content according to different requirements at runtime, achieving a high degree of flexibility and customizability. The binding of graphic elements with device data, control methods, and control strategies ensures the tight integration of the interface with the system functions, simplifies the development and maintenance processes, reduces the workload of hard coding, and significantly improves the scalability of the system.

[0126] 4. Combination of State Machine and Modes

[0127] In a complex energy management system, the design of control strategies must be flexible and customizable enough to adapt to different devices, environments, and control requirements. To achieve the efficiency, maintainability, and scalability of control strategies, the control strategy unit can be divided into two main parts: the state module and the mode module.

[0128] The state module is responsible for continuously monitoring the operating state of the system and judging the overall condition of the current system based on this state information. Each state represents the "situation" in which the system is at a specific moment. The state module defines multiple operating states of the system, which are closely related to the actual operating conditions of the system and are continuously collected and updated in real time through data sensors. The state module is also responsible for judging the state transition conditions according to specific rules. For example, when the photovoltaic power generation exceeds the set value, the state module can change the system state from "standby" to "charging" state; or when the state of charge (SOC) of the battery reaches the upper limit, the system state changes from "charging" to "standby" state.

[0129] The mode module contains a set of specific operating modes, which describe how the system should perform control operations in a specific state. Each mode represents a specific control behavior. The mode module is not directly responsible for judging the operating condition of the system, but executes specific control actions based on the state information provided by the state module. The mode module defines the control strategies for each state and dynamically selects appropriate control modes according to the changes in the state. Each operating mode can be customized and extended according to specific requirements. For example, in the "charging mode", there may be different control strategies, such as maximizing photovoltaic power generation, preferentially using grid power, or choosing to charge the energy storage battery, which are all handled by the mode module.

[0130] When the system is running, the status module continuously monitors and detects the real-time data of the system, such as device voltage, current, power, temperature, etc. When the status module detects specific conditions (for example, the battery power is lower than a certain threshold, or the photovoltaic power generation exceeds a predetermined range), it sends a signal to the mode module to indicate the current state of the system. After receiving the status signal, the mode module selects an appropriate control mode according to the current state and starts to execute. For example, when the system state is "charging", the mode module selects the "charging mode" and starts to adjust the charging power, switch the battery charging method, etc.

[0131] By decoupling the control strategy into two independent modules, namely status and mode, when adding new control strategies to the system, only the corresponding status or mode needs to be modified, rather than rewriting the entire policy logic. For example, if a new charging strategy (such as a charging strategy based on electricity price) is to be added for the "charging state", only the "charging mode" needs to be modified, without changing the code for the "standby" or "discharge" states. By separating the management of status and mode, code duplication can be minimized, avoiding the implementation of the same control logic in multiple locations, thereby reducing the code maintenance cost.

[0132] In different scenarios, the system may require different combinations of status and mode. Through this separated design, developers can customize the status and mode according to the needs of specific sites. For example, for different types of energy storage devices or photovoltaic systems, different control modes or status monitoring logics may be required, but due to the decoupling of status and mode, the customization process becomes more concise and efficient.

[0133] 5. Plug-in

[0134] As the name implies, plug-in means encapsulating different functional modules, device drivers, control strategies, etc. into independent plug-in files (such as dynamic link libraries DLL or shared libraries), and these plug-ins can be dynamically loaded according to the configuration file at runtime. The main program of the system is responsible for managing the loading, unloading, and interaction of the plug-ins to ensure the stable operation of the system. When a plug-in is loaded, the main program queries the interface of the plug-in and initializes the resources required by the plug-in. The plug-in provides functional interfaces according to the requests of the main program, such as device acquisition, control instructions, etc. When a certain plug-in is no longer needed, the main program calls the unloading interface to release the resources of the plug-in, avoiding memory leakage and resource waste.

[0135] The most significant advantage of plug-in is that it can dynamically load the required functional modules and flexibly customize functions according to the needs of different sites. For example, a certain site may only need to load the PCS plug-in of a certain brand, while another site may need to load the PCS plug-ins of different brands. Through configuration file management, the appropriate plug-ins can be selected according to the specific needs of the site at runtime, avoiding system redundancy and unnecessary resource occupation.

[0136] The plug-in architecture is very suitable for the extension and maintenance of the system. With the addition of new devices and control strategies, developers only need to create new plug-ins and interface them with the main program, without modifying the existing system code. For example, when a new PCS device needs to be connected, only a new PCS plug-in needs to be developed and loaded into the system, and the system can support the new device type.

[0137] In this embodiment, plug-inization includes device driver plug-inization and control strategy plug-inization:

[0138] (1) Device driver plug-inization

[0139] In the energy management system, the drivers of devices usually involve devices of different manufacturers and models. For example, PCS (photovoltaic inverter), energy storage devices, etc. In the plug-in design, the drivers of devices of different brands and models can be encapsulated into independent plug-ins. For example:

[0140] The PCS plug-in of Jingqing: Provides communication and control interfaces for Jingqing brand PCS devices.

[0141] The PCS plug-in of Enjiu: Provides communication and control interfaces for Enjiu brand PCS devices.

[0142] Through the configuration file, the user can specify the required device plug-ins. For example:

[0143] {

[0144] "devices":

[0145] {

[0146] "type": "PCS",

[0147] "brand": "EnJiu",

[0148] "plugin": "EnJiu_PCS.dll"

[0149] }

[0151] }

[0152] The system loads the required plug-ins at runtime according to the configuration file and calls the interfaces provided by the plug-ins to manage and control the devices.

[0153] (2) Control strategy plug-inization

[0154] ​In an energy management system, the control strategy is the core of the system operation. For example, charging strategy, discharging strategy, load balancing strategy, etc. Each strategy may need to be adjusted according to the requirements of different scenarios. In the plug-in design, each strategy can be encapsulated as an independent plug-in. For example, the charging strategy plug-in implements a specific charging algorithm for energy storage devices.

[0155] The configuration file specifies the control strategy plug-ins:

[0156] {

[0157] "strategies":

[0158] {

[0159] "type": "Charging",

[0160] "plugin": "ChargingStrategy.dll"

[0161] }

[0163] }

[0164] Through the selection and loading of plug-ins, the system can switch different control strategies according to requirements during operation.

[0165] Embodiment 2

[0166] Based on the above development method, this embodiment provides an energy management system for industrial and commercial energy storage, as Figure 2 described, the system mainly includes:

[0167] It includes a device access unit, a human-machine interface unit, and a control strategy unit, as well as a configuration file, several device plug-ins, and strategy plug-ins. Among them, the device access unit further includes a device module and a communication module. The device module is used to access hardware devices, and the communication module includes communication interfaces and corresponding communication protocols for all accessed devices. The device plug-ins include device drivers of different brands and models and provide communication and control interfaces for the corresponding devices. Users specify the required device plug-ins through the configuration file.

[0168] The human-machine interface unit can be divided into a display interface and a control interface. The display interface is used to display the energy storage station, and the control interface is used for function switching and operation. Users define the appearance, layout, interaction method, and associated data and methods of each interface element in the interface through the configuration file. In some embodiments, the interface elements can also be plug-inized, and users can select the interface elements to be displayed for the human-machine interface unit through the configuration file to achieve personalized interface customization.

[0169] ​The control strategy unit includes a status module and a mode module. The status module is used to obtain the operating status of the energy storage station, and the mode module calls the corresponding control strategy according to the operating status of the energy storage station. The status module includes multiple operating statuses of the energy storage station, and the mode module includes multiple corresponding control strategies. The operating status and its corresponding control strategy are customized by the policy plug-in specified by the user through the configuration file.

[0170] In some embodiments, the energy management system further includes a log module.

[0171] The log records the running conditions of the application program, including information on normal operation, warning information, and error information. By analyzing the log, the operation and maintenance personnel can monitor the health status of the system, discover potential problems in a timely manner, and take measures. When the system crashes or serious errors occur, the log module records key events and data, which are crucial for fault analysis and problem location. By viewing the log, developers can understand the status of the program before and after problems occur, so as to better understand the root cause of the problems.

[0172] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; under the idea of the present invention, the technical features in the above embodiments or different embodiments can also be combined, and the steps can be implemented in any order, and there are many other changes in different aspects of the present invention as described above. For the sake of brevity, they are not provided in detail; although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the various embodiments of the present application.

Claims

1. A method for developing an energy management system, characterized in that: include: Code decoupling: The energy management system is divided into independent functional units, each of which is contained in a different software package; the functional units include a device access unit, a human-machine interface unit, and a control strategy unit; Module decomposition: decompose the device access unit into independent functional modules, including a device module and a communication module. The device module is used to access hardware devices, and the communication module contains the communication interfaces of all access devices and the corresponding communication protocols; decompose the human-machine interface unit into independent functional modules, including a display interface and a control interface. The display interface is used to display the energy storage station, and the control interface is used for function switching and operation; decompose the control strategy unit into independent functional modules, including a state module and a mode module. The state module is used to obtain the operating state of the energy storage station, and the mode module calls the corresponding control strategy according to the operating state of the energy storage station; Interface customization: The human-machine interface unit loads different interface elements according to the configuration file, and each interface element corresponds to an access device or functional module; Plug-in: Different functional modules, devices, and strategies are encapsulated into independent plug-ins, which are dynamically loaded according to the configuration file when the system is running. When the plug-in is loaded, the main program queries the plug-in interface and initializes the resources required by the plug-in. When a plug-in is no longer needed, the main program calls the uninstall interface to release the plug-in resources to avoid memory leaks and resource waste. The plug-in includes device driver plug-in and operation strategy plug-in; Device plug-in: Device drivers of different brands and models are encapsulated into independent plug-ins, which provide communication and control interfaces for corresponding devices. Users specify the required device plug-in through configuration files. The system loads the required plug-in at runtime according to the configuration files and calls the interface provided by the plug-in to manage and control the device. Strategy plug-in: Customize control strategies according to different scenario requirements and encapsulate them as independent plug-ins. Users specify the required strategy plug-in through the configuration file. The system loads the required plug-in at runtime according to the configuration file and switches different control strategies according to requirements.

2. The energy management system development method according to claim 1, characterized in that: The state module defines multiple operating states of the energy storage station. The state module continuously collects and updates the state information of the energy storage station through data sensors, determines the current operating state of the energy storage station based on the state information, and sends it to the mode module; The mode module includes a set of specific control strategies, which describe how the energy storage station should perform control operations under the current operating state; after receiving the state signal, the mode module selects an appropriate control strategy according to the current state and starts executing it.

3. The energy management system development method according to claim 1, characterized in that: The configuration file contains the interface elements that need to be displayed on the interface, and defines the appearance, interaction mode, and associated data and methods of each interface element in the interface; when the system starts, it will read and parse the configuration file, dynamically generate and display the corresponding interface elements according to the information in the configuration, and bind the corresponding data source and control method.

4. The energy management system development method according to claim 3, characterized in that: The control strategy of the interface elements is specified in the configuration file. When the system is running, it will dynamically load and execute the corresponding control strategy according to the definition in the configuration file; the user's interactive operations on the interface will trigger the execution of the control strategy.

5. The energy management system development method according to claim 3, characterized in that: The layout information of the interface elements is set in the configuration file, including the size and position on devices with different screen resolutions; when the system starts, each interface element adaptively adjusts its layout according to the layout information in the configuration file and the current device.

6. The energy management system development method according to claim 1, characterized in that: The format of the configuration file is YAML, JSON or XML; the plug-in is a dynamic link library or a shared library.

7. An energy management system developed based on the method according to any one of claims 1 to 6, characterized in that: It includes device access unit, human-machine interface unit and control strategy unit, as well as configuration files, several device plug-ins and strategy plug-ins; The device access unit includes a device module and a communication module. The device module is used to access hardware devices. The communication module contains the communication interfaces of all access devices and the corresponding communication protocols. The device plug-in includes device drivers of different brands and models and provides communication and control interfaces of corresponding devices. The user specifies the required device plug-in in the configuration file. The human-machine interface unit includes a display interface and a control interface. The display interface is used to display the energy storage station, and the control interface is used for function switching and operation. The user defines the appearance, layout, interaction mode, and associated data and methods of each interface element in the interface through a configuration file; The control strategy unit includes a state module and a mode module. The state module is used to obtain the operating state of the energy storage station, and the mode module calls the corresponding control strategy according to the operating state of the energy storage station. The state module includes multiple operating states of the energy storage station, and the mode module includes multiple corresponding control strategies. The operating state and its corresponding control strategy are customized by the user through the strategy plug-in specified by the configuration file.

8. The energy management system according to claim 7, characterized in that: It also includes several interface element plug-ins, and users can select the interface elements to be displayed for the human-machine interface unit through the configuration file.

9. The energy management system according to claim 7, characterized in that: It also includes a log module for recording information during system operation, including user operation information, warning information and error information.

Citation Information

Patent Citations

  • Energy storage energy management system and method

    CN113537843A

  • Human-computer interaction interface configuration system based on plug-in

    CN118051255A