Memory Allocation Method, Device, System, Medium and Product of Battery Management System

By combining dynamic memory partitioning and static reserved memory allocation strategies, dynamic allocation of memory resources according to task type and priority, the problem of unreasonable memory allocation in the battery management system is solved, and system stability and memory utilization are improved.

CN119847768BActive Publication Date: 2025-07-04CONTEMPORARY AMPEREX TECHNOLOGY CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202510323434.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-19
Publication Date
2025-07-04
Estimated Expiration
2045-03-19

AI Technical Summary

Technical Problem

In the battery management system, unreasonable memory allocation leads to task out-of-bounds access and system stability, affecting battery management efficiency.

Method used

A memory allocation strategy combined with dynamic memory partitioning and static reservation is adopted to dynamically allocate memory resources according to task type and priority level, ensuring that static tasks prioritize sufficient memory, and dynamic tasks flexibly allocate memory.

Benefits of technology

It improves the rationality of memory resource allocation, reduces the risk of memory overflow, ensures the stability and flexibility of the system, and avoids memory waste.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119847768B_ABST
    Figure CN119847768B_ABST
Patent Text Reader

Abstract

The present application discloses a memory allocation method, device, system, medium and product for a battery management system. The method includes: in response to a memory allocation request, obtaining the task type of a battery management task; determining a second memory area corresponding to the task type of the battery management task from a first memory area of an operating system corresponding to the battery management system; allocating the second memory area to the battery management task by using a memory allocation strategy corresponding to the task type; in the case where there are multiple battery management tasks, for each battery management task, determining a memory allocation priority corresponding to the battery management task according to the task type of the battery management task; and determining the second memory area from the first memory area in the order of the memory allocation priorities of the battery management tasks from high to low. Through the solution provided by the present application, the rationality of memory resource allocation can be improved, thereby improving the stability of system operation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical field of battery management systems, and particularly to a method, device, system, medium, and product for memory allocation of a battery management system. Background Art

[0002] During the execution of tasks by application programs in the operating system corresponding to the battery management system, it is necessary to allocate memory for the execution of battery management tasks. If the memory allocation is unreasonable, it may lead to out-of-bounds access to tasks or continuous dynamic memory allocation, reducing the stability of the system operation, and thus affecting the operation efficiency of the battery management system. It can be seen that how to reasonably allocate system memory is of great significance for improving the operation stability of the system and further improving the management efficiency of the battery. Summary of the Invention

[0003] This application provides a method, device, system, medium, and product for memory allocation of a battery management system, which can improve the rationality of memory resource allocation and further improve the stability of system operation.

[0004] In a first aspect, this application provides a method for memory allocation of a battery management system. The method includes: in response to a memory allocation request, obtaining the task type of a battery management task; determining a second memory area corresponding to the task type of the battery management task from a first memory area of the operating system corresponding to the battery management system; and allocating the second memory area to the battery management task by using a memory allocation strategy corresponding to the task type.

[0005] Wherein, when there are multiple battery management tasks, for each battery management task, according to the task type of the battery management task, determining the memory allocation priority corresponding to the battery management task, wherein the memory allocation priority of static tasks is higher than that of dynamic tasks; and determining the second memory area from the first memory area in the order of the memory allocation priorities of the battery management tasks from high to low.

[0006] In the embodiments of this application, the memory area required for executing a task is determined according to the task type of the task, that is, different types of tasks use different memory areas, thereby reducing the risk of memory overflow caused by all tasks accessing the same memory area, and at the same time avoiding the problem of poor system stability caused by dynamic memory allocation for all tasks. In addition, in the embodiments of this application, the memory allocation area and the memory allocation strategy are determined according to the task type of the task, so that the allocated memory area can meet the execution requirements of the task and will not cause memory waste. Compared with the related art of allocating memory resources according to the operation stage of the device, the rationality of memory resource allocation is improved, and thus the stability of system operation is improved.

[0007] In addition, in the embodiments of the present application, the order of task allocation memory is determined according to the priority of the task, and memory is preferentially allocated to tasks with high priority to ensure the normal operation of tasks with higher priority, making the allocation of memory resources more reasonable, thereby improving the stability of system operation.

[0008] In some embodiments, obtaining the task type of the battery management task includes: obtaining the task identifier corresponding to the battery management task; determining the task type of the battery management task according to the task identifier corresponding to the battery management task.

[0009] By setting the task identifier to associate the task identifier with the task type, when creating a task, if it is necessary to adjust the task type, only the task identifier needs to be adjusted, without reconfiguring the task, thereby improving the efficiency of creating or configuring tasks. Moreover, when allocating memory resources to a task, the task type can be accurately determined according to the task identifier, and then memory can be accurately allocated to the task according to the task type, improving the rationality of task allocation.

[0010] In some embodiments, the task type includes static tasks and dynamic tasks. The static tasks include tasks for implementing data processing functions, and the dynamic tasks include tasks for implementing data acquisition functions.

[0011] Before allocating memory to the battery management task, the memory allocator determines the dynamic memory area or the static memory area as the second memory area according to the task type corresponding to the battery management task. Thus, during subsequent memory allocation, the memory resources in the second memory area are allocated to the battery management task to improve the rationality of memory allocation.

[0012] In some embodiments, the second memory area includes a memory area corresponding to the static task and / or a memory area corresponding to the dynamic task. Determining the second memory area from the first memory area according to the order of the memory allocation priority of the battery management task from high to low includes: according to the order of the memory allocation priority of the battery management task from high to low, determining the static memory area in the first memory area as the memory area corresponding to the static task, where the static memory area is the memory area in the first memory area with memory greater than the minimum memory required to execute the static task; determining the dynamic memory area in the first memory area as the memory area corresponding to the dynamic task, where the dynamic memory area is the remaining memory area in the first memory area after allocating memory for the static task.

[0013] When allocating memory to the battery management task, memory is preferentially allocated to static tasks, and then to dynamic tasks. Static memory is preferentially allocated to more important static tasks to allocate sufficient memory intervals for the execution of important tasks and ensure the normal execution of important tasks.

[0014] In some embodiments, when the battery management task is a static task, a memory allocation strategy corresponding to the task type is adopted to allocate the second memory area to the battery management task, including: obtaining the minimum memory required to execute the static task from the task parameters of the battery management task; when there is a static memory area in the first memory area, obtaining the memory address corresponding to the static memory area, where the static memory area is a memory area in the first memory area with a memory greater than the minimum memory; allocating memory resources for the battery management task according to the memory address, so that the battery management task can access the static memory area.

[0015] Allocating memory for the static memory according to the minimum memory required to execute the static task can ensure the normal operation of the static task, and at the same time reduce the risk of waste of memory resources caused by excessive memory allocation, and improve the rationality of memory allocation.

[0016] In some embodiments, the memory allocation method of the battery management system further includes: obtaining the memory usage data of the second memory area; generating a warning prompt message when the memory usage data meets a preset condition, where the preset condition at least includes that the memory usage rate of the second memory area is higher than a preset memory usage rate threshold.

[0017] When the memory usage rate of the second memory area approaches the critical value, an alarm prompt is issued to remind the staff to handle the abnormality in time, and other systems can also adopt an optimization algorithm or suspend non-critical tasks to release the memory resources of non-critical tasks to ensure the stable operation of the vehicle system.

[0018] In some embodiments, the memory allocation method of the battery management system further includes: obtaining the execution frequency of the battery management task when the memory usage data meets a preset condition; when the execution frequency of the battery management task is lower than a preset frequency threshold and the battery management task is in a stopped state, compressing the target data required to execute the battery management task to obtain the compressed target data; when the battery management task is in an execution state, decompressing the compressed target data in the second memory area to obtain the target data.

[0019] Compressing the relevant data of tasks with a lower execution frequency can reduce the memory space occupied by the data; when the task needs to access these data, decompress these data to ensure the normal operation of the task.

[0020] In some embodiments, when the battery management task is a dynamic task, a memory allocation strategy corresponding to the task type is adopted to allocate the memory resources in the second memory area to the battery management task, including: dividing the second memory area into multiple memory blocks; determining at least one target memory block from the multiple memory blocks according to the required memory of the battery management task, wherein the total memory corresponding to the at least one target memory block is greater than or equal to the required memory; and allocating the at least one target memory block to the battery management task.

[0021] By allocating memory for dynamic tasks by dividing the second memory area into multiple memory blocks, not only can the normal execution of dynamic tasks be ensured, but also memory fragmentation can be reduced, waste of memory resources can be decreased, and the rationality of memory allocation can be improved.

[0022] In some embodiments, the memory allocation method of the battery management system further includes: when the battery management task is completed, releasing the at least one target memory block, so that other dynamic memory can continue to use this memory block, improving the utilization rate of the memory space.

[0023] In a second aspect, the present application also provides a memory allocation device for a battery management system, the device includes: a task acquisition module, configured to acquire the task type of the battery management task in response to a memory allocation request; a memory determination module, configured to determine a second memory area corresponding to the task type of the battery management task from the first memory area of the operating system; and a memory allocation module, configured to allocate the memory resources in the second memory area to the battery management task by adopting a memory allocation strategy corresponding to the task type.

[0024] In a third aspect, the present application provides a battery management system, the battery management system includes: a task executor, configured to create and execute a battery management task; a memory, connected to the task executor, configured to provide memory resources for the task executor to execute the battery management task, wherein the memory includes a first memory area of the operating system corresponding to the battery management system; and a memory allocator, connected to the task executor and the memory, configured to determine a second memory area corresponding to the first memory area from the first memory area according to the task type of the battery management task, and allocate the second memory area in the memory to the battery management task by adopting a memory allocation strategy corresponding to the task type.

[0025] In a fourth aspect, the present application provides a readable storage medium, on which computer program instructions are stored, and when the computer program instructions are executed by a processor, the memory allocation method of the battery management system as described in the first aspect is implemented.

[0026] Fifth aspect, the present application provides a computer program product. When the instructions in the computer program product are executed by a processor of an electronic device, the electronic device is caused to execute the memory allocation method of the battery management system as described in the first aspect.

[0027] The above description is only an overview of the technical solution of the present application. In order to be able to understand the technical means of the present application more clearly, it can be implemented in accordance with the content of the specification. And in order to make the above and other purposes, features and advantages of the present application more obvious and understandable, the following specifically illustrates the specific implementation manners of the present application. Description of the Drawings

[0028] The features, advantages and technical effects of the exemplary embodiments of the present application will be described below with reference to the drawings.

[0029] Figure 1 Schematic diagram of the structure of the battery management system according to an embodiment of the present application;

[0030] Figure 2 Flowchart of the memory allocation method of the battery management system according to an embodiment of the present application;

[0031] Figure 3 Flowchart of the method for determining the task type of the battery management task according to an embodiment of the present application;

[0032] Figure 4 Flowchart of the method for determining the second memory area according to an embodiment of the present application;

[0033] Figure 5 Flowchart of the memory resource allocation method under static tasks according to an embodiment of the present application;

[0034] Figure 6 Flowchart of the method for monitoring the memory usage situation according to an embodiment of the present application;

[0035] Figure 7 Flowchart of the memory adjustment method according to an embodiment of the present application;

[0036] Figure 8 Flowchart of the memory resource allocation method under dynamic tasks according to an embodiment of the present application;

[0037] Figure 9 Schematic diagram of the memory allocation device of the battery management system according to another embodiment of the present application.

[0038] In the drawings, the drawings are not necessarily drawn to actual scale. Detailed Description of the Invention

[0039] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are some, but not all, of the embodiments of this application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in this application without creative efforts shall fall within the scope of protection of this application.

[0040] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which this application belongs; the terms used herein are only for the purpose of describing specific embodiments and are not intended to limit this application; the terms "including" and "having" and any variations thereof in the specification and claims of this application and the above drawings are intended to cover non-exclusive inclusion.

[0041] In the description of the embodiments of this application, the technical terms "first", "second", etc. are only used to distinguish different objects and cannot be understood as indicating or implying relative importance or implicitly indicating the quantity, specific order, or primary-secondary relationship of the indicated technical features. In the description of the embodiments of this application, "a plurality of" means two or more unless otherwise specifically defined.

[0042] Referring to "embodiments" in the embodiments of this application means that the specific features, structures, or characteristics described in connection with the embodiments may be included in at least one embodiment of this application. The phrase does not necessarily refer to the same embodiment when it appears in various positions in the specification, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those skilled in the art explicitly and implicitly understand that the embodiments described in the embodiments of this application may be combined with other embodiments.

[0043] In the description of the embodiments of this application, the term "and / or" is merely a description of the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B may represent: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " herein generally represents an "or" relationship between the associated objects before and after.

[0044] Software-defined vehicle is an automotive architecture centered around software. It can endow vehicles with the capabilities of intelligence, connectivity, and personalization by integrating the hardware functions and software systems of the vehicle. In the general trend of software-defined vehicles, the combination of chips, operating systems, middleware, application algorithm software, and data is the key to achieving vehicle intelligence. The operating system is the soul of the development of the vehicle ecosystem. Among them, the AUTOSAR operating system is a commonly used operating system in vehicles.

[0045] In the related art, the AUTOSAR operating system typically uses static memory allocation to allocate memory for tasks in a vehicle's battery management system. This method can reduce the need for dynamic memory allocation, thereby improving the stability and predictability of the system. However, for static memory allocation, if the memory allocation is unreasonable, problems such as memory buffer overflow and out-of-bounds access will occur, thus limiting the flexibility and scalability of the system. Although dynamic memory allocation can solve the problems of memory overflow and out-of-bounds access, frequent dynamic memory allocation will reduce the stability and predictability of the system.

[0046] In view of the problems existing in the related art, embodiments of the present application provide a memory allocation method, device, system, medium, and product for a battery management system. In the memory allocation method for the battery management system provided by the embodiments of the present application, a combination of dynamic memory partitioning and static reservation is used to achieve memory allocation.

[0047] Specifically, the battery management system adopts a memory allocation strategy that combines dynamic memory partitioning and static reservation to allocate memory for related tasks (such as data acquisition tasks and data calculation tasks) of the battery management system according to the real-time memory requirements of application programs (such as application programs for battery service life assessment and battery state assessment) and the memory resource usage of the operating system. For different types of tasks, different memory regions are used for allocation and different memory allocation strategies are adopted to allocate memory, so as to improve the rationality of memory allocation and further improve the stability of system operation.

[0048] It should be noted that the battery management system (Battery Management System, BMS) in the present application is used to implement at least one of the functions of state monitoring, state analysis, charge and discharge control, safety protection, information management, thermal management, and high-voltage power distribution for battery cells. In addition, the battery management system in the present application can also implement the functions of a controller in an electrical device, such as implementing the functions of a vehicle control unit (VCU), a motor control unit (MCU), etc. The present application does not limit this.

[0049] It should be noted that the battery management system in the present application can be integrated as a controller in a battery device, such as integrated in a battery pack or an energy storage electrical box;

[0050] The battery management system in the present application can also be integrated as a controller in an electrical device, such as integrated in a vehicle or a vehicle chassis;

[0051] The battery management system in the present application can also be integrated as a controller in a charging device, such as integrated in a charging device or a battery swapping device;

[0052] The battery management system in this application can also be deployed as control software in a server. The server can be an independent physical server, a server cluster or a distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms, such as vehicle networking cloud, APP background, etc.

[0053] In an embodiment of this application, the battery management system can execute the memory allocation method of the battery management system provided by this application embodiment. The battery management system is equipped with a vehicle operating system, which is different from the AUTOSAR operating system and can be used not only to implement static memory allocation but also to implement dynamic memory allocation.

[0054] The following introduces the memory allocation method of the battery management system provided by this application embodiment in combination with the battery management system. The vehicle operating system runs in the vehicle and can interact with task executors, memories, etc. in the BMS (Battery Management System) to allocate and manage memory for battery management tasks (such as battery safety monitoring tasks, emergency fault handling tasks, battery state estimation tasks, balancing control tasks, etc.) executed by the task executors.

[0055] In one embodiment, Figure 1 shows a schematic structural diagram of the battery management system, as Figure 1 shown, the battery management system includes: a task executor 10, a memory 20, and a memory allocator 30.

[0056] In an embodiment of this application, the task executor 10 can be used to create and execute battery management tasks. Among them, the task executor 10 can be a control chip capable of creating and running battery management tasks, which can be composed of a control unit, an arithmetic logic unit, registers, etc. to implement the creation and execution of tasks.

[0057] The memory 20 can be connected to the task executor 10 and is used to provide memory resources for the task executor 10 to execute battery management tasks.

[0058] In an embodiment of this application, the storage space corresponding to the memory 20 is the first memory area of the operating system corresponding to the battery management system.

[0059] The memory allocator 30, connected to the task executor 10 and the memory 20, is used to determine a second memory area from the first memory area according to the task type of the battery management task, and allocate the second memory area in the memory to the battery management task by using a memory allocation strategy corresponding to the task type. Wherein, the first memory area is the storage space corresponding to the memory 20, and the second memory area is a partial area in the first memory area.

[0060] In the embodiment of the present application, the memory allocator 30 can be any one of a buddy allocator and a Slab allocator.

[0061] The following takes the memory allocator in the battery management system as the execution subject to introduce the method provided by the embodiment of the present application.

[0062] In one embodiment, Figure 2 The flowchart of the memory allocation method of the battery management system is shown, as Figure 2 shown, the method may include the following steps S201 to step S203:

[0063] Step S201, in response to a memory allocation request, obtain the task type of the battery management task.

[0064] In step S201, when the vehicle's vehicle controller controls the BMS to execute a task, the task in the BMS can apply for memory from the vehicle operating system. After receiving the memory allocation request sent by the BMS, the memory allocator allocates memory resources for the BMS by using the method provided by the embodiment of the present application.

[0065] In step S201, the memory allocation request may include the task attribute information of the battery management task. Among them, the task attribute information may include information such as the function to be realized by the battery management task, the task type, the task identifier, and the task priority. The memory allocator can obtain the task type of the battery management task by parsing the memory allocation request. In the embodiment of the present application, the battery management tasks include but are not limited to data acquisition tasks (for example, data recording tasks), data processing tasks (for example, floating-point operation tasks, battery state estimation tasks, battery balancing control tasks).

[0066] Step S202, determine a second memory area corresponding to the task type of the battery management task from the first memory area of the operating system corresponding to the battery management system.

[0067] In step S202, the first memory area is the memory space possessed by the operating system, and the second memory area is a partial memory area in the memory space possessed by the operating system. In the embodiment of the present application, for different types of tasks, the memory allocator allocates the memory in different memory areas to the corresponding types of tasks.

[0068] As an example, in the embodiment of the present application, the first memory area includes a static memory area and a dynamic memory area. Among them, the dynamic memory area is used to provide memory resources for dynamic tasks such as data recording, while the static memory area is used to provide memory resources for static tasks, and the dynamic memory area is used to provide memory resources for dynamic tasks.

[0069] In one embodiment, the task types include static tasks and dynamic tasks. The static tasks include tasks for implementing data processing functions (for example, floating-point operation tasks), and the dynamic tasks include tasks for implementing data acquisition functions (for example, voltage acquisition tasks, current acquisition tasks, temperature acquisition tasks).

[0070] In the embodiment of the present application, the dynamic memory area and the static memory area constitute the memory space of the operating system. Before allocating memory for the battery management task, the memory allocator determines the dynamic memory area or the static memory area as the second memory area according to the task type corresponding to the battery management task, so that during subsequent memory allocation, the memory resources in the second memory area are allocated to the battery management task to improve the rationality of memory allocation.

[0071] Step S203: Allocate the second memory area to the battery management task by using a memory allocation strategy corresponding to the task type.

[0072] In step S203, the memory allocation strategies corresponding to different types of tasks are also different. For example, for static tasks for implementing functions such as data processing, a static memory allocation strategy can be adopted to allocate the memory resources of the minimum memory required to execute the task to the task from the static memory area; for dynamic tasks for implementing functions such as data acquisition, a dynamic memory allocation strategy can be adopted to obtain memory resources from the dynamic memory area and release the memory resources after the task completes data acquisition.

[0073] It should be noted that for the traditional AUTOSAR operating system, it usually adopts a static allocation method to allocate memory for tasks, which reduces the flexibility and scalability of the system. In the embodiment of the present application, allocating memory resources for tasks according to the memory allocation strategy corresponding to the task type improves the flexibility of memory allocation and can also reduce the problem of reduced system stability caused by frequent dynamic memory allocation.

[0074] Based on the solution defined in the above steps S201 to S203, it can be known that in the embodiment of the present application, the memory area required for executing a task is determined according to the task type of the task, that is, the memory areas used by different types of tasks are different, thereby reducing the risk of memory overflow caused by all tasks accessing the same memory area, and at the same time avoiding the problem of poor system stability caused by dynamic memory allocation for all tasks. In addition, in the embodiment of the present application, the memory allocation area and the memory allocation policy are determined according to the task type of the task, so that the allocated memory area can meet the execution requirements of the task, and at the same time, the problem of memory waste will not be caused. Compared with the related art where memory resources are allocated according to the running stage of the device, the rationality of memory resource allocation is improved, and thus the stability of system operation is improved.

[0075] The implementation process of the method provided in the embodiment of the present application will be introduced below.

[0076] In the embodiment of the present application, the memory allocator determines the memory area where the memory resources are located according to the task type of the battery management task. Before that, it is necessary to determine the task type of the battery management task. In one embodiment, the task type of the battery management task can be determined by the Figure 3 method shown, as Figure 3 shown, this process includes the following steps:

[0077] Step S301, obtain the task identifier corresponding to the battery management task;

[0078] Step S302, determine the task type of the battery management task according to the task identifier corresponding to the battery management task.

[0079] In step S301, each battery management task has a corresponding task identifier, and this task identifier can be set by the R & D personnel according to actual needs. In the embodiment of the present application, the task identifier is used to represent the function corresponding to the battery management task. For example, the task identifier 0001 indicates that this task can realize the acquisition of voltage data; the task identifier 0002 indicates that this task can realize the acquisition of current data; the task identifier 0003 indicates that this task can realize the operation of floating-point data.

[0080] In step S302, the memory allocator can determine the task type of the task according to the task identifier corresponding to the battery management task. For example, the memory allocator identifies the tasks with task identifiers 0001 and 0002 as dynamic tasks, and identifies the task with the task identifier 0003 as a static task.

[0081] Through steps S301 to S302, by setting a task identifier to associate the task identifier with the task type, when creating a task, if the task type needs to be adjusted, only the task identifier needs to be adjusted, without reconfiguring the task, thus improving the efficiency of creating or configuring a task. Moreover, when allocating memory resources for a task, the task type can be accurately determined according to the task identifier, and then memory can be accurately allocated to the task according to the task type, improving the rationality of task allocation.

[0082] Further, after determining the task type of the battery management task, the memory allocator can determine the memory area according to the task type.

[0083] In one embodiment, when there are multiple battery management tasks, the memory allocator uses the method shown in Figure 4 to determine the second memory area. Specifically, the process includes the following steps S401 to S402:

[0084] Step S401, for each battery management task, determine the memory allocation priority corresponding to the battery management task according to the task type of the battery management task.

[0085] In step S401, the memory allocation priority is used to represent the allocation order of the battery management tasks. In the embodiments of the present application, memory is preferentially allocated to tasks with a high memory allocation priority. Among them, the memory allocation priority of static tasks is higher than that of dynamic tasks.

[0086] Step S402, determine the second memory area from the first memory area according to the order of the memory allocation priorities of the battery management tasks from high to low.

[0087] It should be noted that through steps S401 to S402, the order of task memory allocation is determined according to the priority of the tasks, and memory is preferentially allocated to tasks with a high priority to ensure the normal operation of tasks with a higher priority.

[0088] In step S402, the determination method of the second memory area is also different for the task types corresponding to the battery management memory.

[0089] In the embodiments of the present application, the memory allocator determines the static memory area in the first memory area as the memory area corresponding to the static task according to the order of the memory allocation priorities of the battery management tasks from high to low, where the static memory area is the memory area in the first memory area with a memory greater than the minimum memory required to execute the static task;

[0090] The dynamic memory area in the first memory area is determined as the one corresponding to the dynamic task, where the dynamic memory area is the remaining memory area in the first memory area after allocating memory for the static task.

[0091] In the above embodiments, the second memory area includes a memory area corresponding to a static task, and / or a memory area corresponding to a dynamic task.

[0092] That is, in the embodiments of the present application, when allocating memory for battery management tasks, memory is preferentially allocated to static tasks, and then to dynamic tasks. Among them, static tasks are usually more important tasks such as data processing, while dynamic tasks are usually more frequent tasks such as data acquisition. For static tasks, taking the floating-point algorithm task as an example, static memory is preferentially allocated to the floating-point algorithm task to allocate sufficient memory intervals for the execution of important tasks and ensure the normal execution of important tasks.

[0093] In one example, during the program compilation stage, the compiler in the memory allocator pre-configures the static memory sizes corresponding to different tasks according to variable declarations, data structure definitions, and static memory requirements in the program code. Then, according to the functions of different tasks and the required static memory sizes, it is determined whether the task needs to dynamically allocate memory according to the configuration code bit TaskType of the task. After the BMS system is started and tasks are created, the memory allocator searches from the head of the free partition chain or table in the memory space of the operating system according to the configuration information of the task until a free partition with a size meeting the requirements is found. Then, a part of this partition is allocated to the task, and the remaining free partitions are still retained in the chain for subsequent dynamic memory allocation for other tasks.

[0094] In addition, in the embodiments of the present application, after allocating static memory for static tasks, during the execution of static tasks, the corresponding memory resources can also be dynamically adjusted according to the execution conditions of the static tasks. For example, for floating-point operation tasks, they usually involve the processing of a large amount of data, and the size and quantity of these data may not be fully determined when writing the program. Therefore, in order to more effectively manage memory and avoid unnecessary memory waste or shortage, during the execution of floating-point operation tasks, if the static memory is insufficient, dynamic memory can also be allocated to it.

[0095] The following separately introduces the memory allocation process for static tasks and dynamic tasks.

[0096] When the battery management task is a static task, the memory allocator allocates the memory resources in the second memory area to the battery management task by using the method as Figure 5 shown. Specifically, as Figure 5 shown, this method includes the following steps S501 to step S503:

[0097] Step S501, obtain the minimum memory required to execute the static task from the task parameters of the battery management task.

[0098] In step S501, the task parameters of the battery management task may include, but are not limited to, information such as task type, task identifier, minimum memory required to execute the task, task function, etc.

[0099] Step S502, when there is a static memory area in the first memory area, obtain the memory address corresponding to the static memory area.

[0100] In step S502, the static memory area is the memory area in the first memory area where the memory is greater than the minimum memory.

[0101] Step S503, allocate memory resources for the battery management task according to the memory address, so that the battery management task can access the static memory area.

[0102] In an example, taking the static task as a floating-point operation task, the memory allocator first determines the minimum static memory required to execute the floating-point operation task according to the task parameters of the floating-point operation task. For example, this minimum static memory can be the minimum memory required for the normal operation of the floating-point operation task, which is the basis for ensuring the normal operation of the floating-point operation task. Then, the memory allocator performs a memory status check to find a large enough continuous memory area in the first memory area to meet the execution of the floating-point operation task. After finding the memory area that meets the requirements of the floating-point operation task, obtain the memory address corresponding to this memory area, and mark this memory address to indicate that this memory area has been allocated, and then return this memory address to the floating-point operation task, so that the floating-point operation task can use this memory area.

[0103] Through steps S501 to S503, allocating memory for the static memory according to the minimum memory required to execute the static task can ensure the normal operation of the static task, and at the same time reduce the risk of memory resource waste caused by excessive memory allocation, and improve the rationality of memory allocation.

[0104] Furthermore, in order to ensure the normal execution of the static task, during the execution of the static task, the memory allocator also monitors the memory usage of the second memory area. Specifically, as Figure 6 shown, the memory monitoring process of the second memory area includes the following steps S601 to S602:

[0105] Step S601, the memory allocator obtains the memory usage data of the second memory area;

[0106] Step S602, when the memory usage data meets the preset conditions, generate a warning prompt message.

[0107] In step S601, the memory usage data may include but is not limited to memory utilization rate, memory usage amount, remaining memory amount, etc. In the embodiments of the present application, the memory utilization rate is taken as an example for introduction.

[0108] In one example, the memory allocator monitors in real time the memory resource usage status of the tasks using the memory resources of the second memory area, counts the total memory usage amount of all tasks using the memory resources of the second memory area, and calculates the sum of the memory usage amount and the total memory amount of the second memory area, so as to obtain the memory utilization rate of the second memory area.

[0109] In step S602, the preset conditions at least include that the memory utilization rate of the second memory area is higher than the preset memory utilization rate threshold. Among them, the memory utilization rate threshold can be determined according to the historical memory usage of the second memory area. For example, in the historical working condition, when the memory utilization rate of the second memory area reaches the first memory utilization rate, if there are other tasks applying for memory resources, it will cause the second memory area to overflow, then the first memory utilization rate can be determined as the memory utilization rate threshold.

[0110] In addition, in step S602, the warning prompt information may include prompt information such as sound, electricity, and light, and may also include the value corresponding to the code field representing memory abnormality.

[0111] It should be noted that through steps S601 to S602, when the memory utilization rate of the second memory area is close to the critical value, an alarm prompt is issued to remind the staff to handle the abnormality in time, and other systems can also adopt an optimization algorithm or suspend non-critical tasks to release the memory resources of non-critical tasks to ensure the stable operation of the vehicle system.

[0112] In one embodiment, when the memory usage data meets the preset conditions, the memory allocator can also Figure 7 perform memory adjustment on the second memory area through the memory adjustment method shown in Figure 7 As shown, this method includes the following steps S701 to S703:

[0113] Step S701, when the memory usage data meets the preset conditions, obtain the execution frequency of the battery management task.

[0114] In step S701, the execution frequency of the battery management task can be obtained by counting the total number of tasks using the second memory area within a preset time period and counting the number of occurrences of the task identifier corresponding to each task, and calculating the ratio of the number of occurrences of the task identifier to the total number of tasks.

[0115] Step S702: When the execution frequency of the battery management task is lower than the preset frequency threshold and the battery management task is in a stopped state, compress the target data required for executing the battery management task to obtain the compressed target data.

[0116] In step S702, the frequency threshold can be determined according to the task type, and each task type corresponds to a frequency threshold.

[0117] In addition, in step S702, the memory allocator compresses and stores the data of tasks with a lower execution frequency to reduce the memory space occupied by the data, so as to release a part of the memory space of the operating system. The released memory space can be allocated to other tasks to improve the utilization rate of memory resources.

[0118] Step S703: When the battery management task is in an execution state, decompress the compressed target data in the second memory area to obtain the target data.

[0119] In step S703, when the battery management task needs to be executed, the compressed target data can be decompressed to ensure the normal operation of the battery management task.

[0120] In an example, to ensure sufficient memory space, the memory allocator plans and reserves memory in advance. For example, when the system starts, dedicated memory areas are allocated for each static task, and the memory is dynamically adjusted. For example, according to the actual situation, the algorithm is adjusted and the memory compression technology is adopted. When the memory allocator detects that the memory pressure is large, the memory manager in the battery management system selects to compress inactive floating-point data pages so that they still remain in physical memory to reduce the occupied space; when accessing these compressed floating-point data, the memory allocator restores the data through decompression operations and re-establishes the address mapping relationship with the process to ensure the normal access and use of the data.

[0121] Through steps S701 to S703, compressing the relevant data of tasks with a lower execution frequency can reduce the memory space occupied by the data; when the task needs to access these data, decompress these data to ensure the normal operation of the task.

[0122] When the battery management task is a dynamic task, the memory allocator adopts the method as Figure 8 shown to allocate the memory resources in the second memory area to the battery management task. Specifically, as Figure 8 shown, this method includes the following steps S801 to S803:

[0123] Step S801: Divide the second memory area into multiple memory blocks.

[0124] In step S801, the memory allocator can use the memory pool technology to divide the second memory area into multiple memory blocks of a fixed size to meet the data acquisition requirements of different sizes.

[0125] In one example, the memory allocator can divide the second memory area into multiple memory blocks of equal size. Among them, the size and quantity of the memory blocks are determined according to the size of the memory resources requested by dynamic tasks under historical working conditions. For example, under historical working conditions, usually 3 dynamic tasks apply for dynamic memory in the same time period, and the memory capacity required by the 3 dynamic tasks is A. Then the memory allocator divides the second memory area into 3 memory blocks, and the memory capacity of each memory block is set to A.

[0126] In another example, the memory allocator can also divide the second memory area into multiple memory blocks with different memory sizes according to the size of the memory resources requested by dynamic memory under historical working conditions. For example, under historical working conditions, within the same time period, the intervals of the memory resources requested by dynamic tasks are usually [A, B], [B, C], [C, D]. Then the memory allocator divides the second memory area into three memory blocks, and the corresponding memory capacity sizes are B - A, C - B, and D - C respectively.

[0127] Step S802, determine at least one target memory block from multiple memory blocks according to the required memory of the battery management task.

[0128] In step S802, the total memory corresponding to at least one target memory block is greater than or equal to the required memory.

[0129] In one example, if there is a memory block larger than the memory requirement among multiple memory blocks, then this memory block is used as the target memory block. If there is no memory block larger than the memory requirement among multiple memory blocks, then multiple consecutive memory blocks can be merged to provide memory resources for the battery management task, and these memory blocks can be used as target memory blocks.

[0130] Step S803, allocate at least one target memory block to the battery management task.

[0131] In one example, for dynamic tasks, taking the data acquisition task as an example, for the small data block requirements of the data acquisition task, optimize the allocation strategy of the dynamic memory area to reduce memory fragmentation. The memory allocator can set the flag of dynamic memory allocation in the configuration information of the data acquisition task according to the function of the data acquisition task and the required static memory size. After the BMS system is started and when the data acquisition task is created, the memory allocator applies for dynamic memory for the data acquisition task according to the flag bit of the configuration information of the data acquisition task by using the memory pool technology. Using the memory pool technology can ensure that the data acquisition task can obtain memory quickly when needed, without causing task delay due to the uncertainty of dynamic memory allocation.

[0132] By steps S801 to S803, dividing the second memory area into multiple memory blocks to allocate memory for dynamic tasks can not only ensure the normal execution of dynamic tasks, but also reduce memory fragmentation, reduce the waste of memory resources, and improve the rationality of memory allocation.

[0133] In one embodiment, the memory allocator also releases at least one target memory block when the battery management task is completed, so that other dynamic memory can continue to use this memory block, improving the utilization rate of the memory space.

[0134] So far, the introduction of the method provided by the embodiments of the present application is completed.

[0135] As can be seen from the above introduction, in the embodiments of the present application, a memory allocation strategy corresponding to the task type is used to allocate appropriate memory for tasks, reducing the memory allocation limitations of the memory allocator, improving the memory utilization rate and system performance. Using static continuous memory to provide services for the execution of static tasks provides sufficient running memory for the execution of static tasks to reduce the risk of buffer overflow or out-of-bounds access problems. Dynamic tasks usually require less memory. Dynamically allocating memory for dynamic tasks makes full use of memory fragmentation and improves the memory utilization rate.

[0136] It should be understood that although the steps in the flowcharts involved in the above-described embodiments are shown in sequence according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless there is a clear indication in this article, the execution of these steps has no strict order limitation, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-described embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or alternately with at least a part of other steps or steps or stages in other steps.

[0137] In one embodiment, Figure 9 shows a schematic diagram of a memory allocation device of a battery management system. As Figure 9 can be seen, the device 900 includes: a task acquisition module 901, a memory determination module 902, and a memory allocation module 903.

[0138] The task acquisition module 901 is configured to obtain the task type of the battery management task in response to a memory allocation request;

[0139] A memory determination module 902, configured to determine a second memory area corresponding to the task type of the battery management task from a first memory area of an operating system corresponding to the battery management system;

[0140] A memory allocation module 903, configured to allocate the second memory area to the battery management task by using a memory allocation policy corresponding to the task type.

[0141] In one embodiment, the task acquisition module is specifically configured to acquire a task identifier corresponding to the battery management task; and determine the task type of the battery management task according to the task identifier corresponding to the battery management task.

[0142] In one embodiment, the task types include static tasks and dynamic tasks. The static tasks include tasks for implementing data processing functions, and the dynamic tasks include tasks for implementing data acquisition functions.

[0143] In one embodiment, when there are multiple battery management tasks, the memory determination module includes: a priority determination module and a first memory determination module. The priority determination module is configured to, for each battery management task, determine the memory allocation priority corresponding to the battery management task according to the task type of the battery management task, where the memory allocation priority of the static task is higher than that of the dynamic task; the first memory determination module is configured to determine the second memory area from the first memory area in the order from high to low of the memory allocation priorities of the battery management tasks.

[0144] In one embodiment, the second memory area includes a memory area corresponding to the static task, and / or a memory area corresponding to the dynamic task. The first memory determination module is specifically configured to, in the order from high to low of the memory allocation priorities of the battery management tasks, determine the static memory area in the first memory area as the memory area corresponding to the static task, where the static memory area is the memory area in the first memory area whose memory is greater than the minimum memory required to execute the static task; and determine the dynamic memory area in the first memory area as the memory area corresponding to the dynamic task, where the dynamic memory area is the remaining memory area in the first memory area after the memory is allocated for the static task.

[0145] In one embodiment, when the battery management task is a static task, the memory allocation module is specifically configured to acquire the minimum memory required to execute the static task from the task parameters of the battery management task; when there is a static memory area in the first memory area, acquire the memory address corresponding to the static memory area, where the static memory area is the memory area in the first memory area whose memory is greater than the minimum memory; and allocate memory resources for the battery management task according to the memory address, so that the battery management task can access the static memory area.

[0146] In one embodiment, the memory allocation device of the battery management system further includes: a warning module, configured to obtain memory usage data of a second memory area; and generate a warning prompt message when the memory usage data meets a preset condition, where the preset condition at least includes that the memory usage rate of the second memory area is higher than a preset memory usage rate threshold.

[0147] In one embodiment, the memory allocation device of the battery management system further includes: a memory adjustment module, configured to obtain the execution frequency of a battery management task when the memory usage data meets a preset condition; compress target data required for executing the battery management task to obtain compressed target data when the execution frequency of the battery management task is lower than a preset frequency threshold and the battery management task is in a stopped state; and decompress the compressed target data in the second memory area to obtain the target data when the battery management task is in an execution state.

[0148] In one embodiment, when the battery management task is a dynamic task, the memory allocation module is specifically configured to divide the second memory area into multiple memory blocks; determine at least one target memory block from the multiple memory blocks according to the required memory of the battery management task, where the total memory corresponding to the at least one target memory block is greater than or equal to the required memory; and allocate the at least one target memory block to the battery management task.

[0149] In one embodiment, the memory allocation device of the battery management system further includes: a memory release module, configured to release at least one target memory block when the battery management task is completed.

[0150] In one embodiment, the present application further provides a readable storage medium, on which computer program instructions are stored, and when the computer program instructions are executed by a processor, the memory allocation method of the above-mentioned battery management system is implemented.

[0151] In one embodiment, the present application further provides a computer program product, and when the instructions in the computer program product are executed by a processor of an electronic device, the electronic device is caused to execute the memory allocation method of the above-mentioned battery management system.

[0152] It should be clear that the present application is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications, and additions, or change the order between steps after understanding the spirit of the present application.

[0153] The functional blocks shown in the above structural block diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a functional card, and so on. When implemented in software, the elements of the present application are programs or code segments used to perform the required tasks. The program or code segment can be stored in a machine-readable medium or transmitted via a data signal carried in a carrier wave over a transmission medium or a communication link. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical discs, hard disks, fiber optic media, radio frequency (RF) links, and so on. The code segment can be downloaded via a computer network such as the Internet, an intranet, and so on.

[0154] It should also be noted that the exemplary embodiments mentioned in the present application describe some methods or systems based on a series of steps or devices. However, the present application is not limited to the order of the above steps, that is, the steps can be executed in the order mentioned in the embodiments, can be different from the order in the embodiments, or several steps can be executed simultaneously.

[0155] The various aspects of the present application have been described above with reference to the flowcharts and / or block diagrams of the memory allocation method, device, system, medium, and product of the battery management system according to the embodiments of the present application. It should be understood that each block in the flowchart and / or block diagram, and the combination of each block in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device to generate a machine, such that the instructions executed by the processor of the computer or other programmable data processing device enable the implementation of the functions / actions specified in one or more blocks of the flowchart and / or block diagram. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field programmable logic circuit. It can also be understood that each block in the block diagram and / or flowchart, and the combination of the blocks in the block diagram and / or flowchart, can also be implemented by dedicated hardware that performs the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.

[0156] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application 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 described in the foregoing embodiments, or perform equivalent replacements for some or all of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application, and they should all be covered within the scope of the claims and the description of the present application. In particular, as long as there is no structural conflict, the technical features mentioned in each embodiment can be combined in any way. The present application is not limited to the specific embodiments disclosed in the text, but includes all technical solutions that fall within the scope of the claims.

Claims

1. A memory allocation method for a battery management system, characterized in that, Including: In response to a memory allocation request, obtain the task type of the battery management task; Determine a second memory area corresponding to the task type of the battery management task from a first memory area of an operating system corresponding to the battery management system; Allocate the second memory area to the battery management task by using a memory allocation policy corresponding to the task type; When there are multiple battery management tasks, the determining a second memory area corresponding to the task type of the battery management task from a first memory area of an operating system corresponding to the battery management system includes: for each battery management task, determine a memory allocation priority corresponding to the battery management task according to the task type of the battery management task, where the memory allocation priority of a static task is higher than that of a dynamic task; determine the second memory area from the first memory area in the order of the memory allocation priorities of the battery management tasks from high to low; The second memory area includes a memory area corresponding to the static task and / or a memory area corresponding to the dynamic task. The determining the second memory area from the first memory area in the order of the memory allocation priorities of the battery management tasks from high to low includes: determining a static memory area in the first memory area as the memory area corresponding to the static task in the order of the memory allocation priorities of the battery management tasks from high to low, where the static memory area is a memory area in the first memory area with a memory greater than the minimum memory required to execute the static task; Determine a dynamic memory area in the first memory area as the memory area corresponding to the dynamic task, where the dynamic memory area is the remaining memory area in the first memory area after allocating memory for the static task.

2. The method according to claim 1, wherein The obtaining the task type of the battery management task includes: Obtain a task identifier corresponding to the battery management task; Determine the task type of the battery management task according to the task identifier corresponding to the battery management task.

3. The method according to claim 2, wherein The task type includes a static task and a dynamic task. The static task includes a task for implementing a data processing function, and the dynamic task includes a task for implementing a data acquisition function.

4. The method according to any one of claims 1 to 3, characterized in that, When the battery management task is the static task, the allocating the second memory area to the battery management task by using a memory allocation policy corresponding to the task type includes: Obtain the minimum memory required to execute the static task from the task parameters of the battery management task; When there is a static memory area in the first memory area, obtain the memory address corresponding to the static memory area, where the static memory area is a memory area in the first memory area with a memory greater than the minimum memory; Allocate memory resources for the battery management task according to the memory address so that the battery management task can access the static memory area.

5. The method according to claim 4, characterized in that The method further includes: Obtain memory usage data of the second memory area; Generate a warning prompt message when the memory usage data meets a preset condition, where the preset condition at least includes that the memory usage rate of the second memory area is higher than a preset memory usage rate threshold.

6. The method according to claim 5, wherein The method further includes: When the memory usage data meets the preset condition, obtain the execution frequency of the battery management task; When the execution frequency of the battery management task is lower than a preset frequency threshold and the battery management task is in a stopped state, compress the target data required to execute the battery management task to obtain the compressed target data; When the battery management task is in an execution state, decompress the compressed target data in the second memory area to obtain the target data.

7. The method according to any one of claims 1 to 3, characterized in that, When the battery management task is the dynamic task, the step of adopting a memory allocation strategy corresponding to the task type to allocate the memory resources in the second memory area to the battery management task includes: Divide the second memory area into multiple memory blocks; Determine at least one target memory block from the multiple memory blocks according to the required memory of the battery management task, where the total memory corresponding to the at least one target memory block is greater than or equal to the required memory; Allocate the at least one target memory block to the battery management task.

8. The method according to claim 7, characterized in that The method further includes: When the battery management task is completed, release the at least one target memory block.

9. A battery management system, characterized in that, Includes: A task executor for creating and executing a battery management task; A memory, connected to the task executor, for providing memory resources for the task executor to execute the battery management task, where the memory includes a first memory area of the operating system corresponding to the battery management system; A memory allocator, connected to the task executor and the memory, for determining a second memory area from the first memory area according to the task type of the battery management task, and adopting a memory allocation strategy corresponding to the task type to allocate the second memory area in the memory to the battery management task; When there are multiple battery management tasks, the memory allocator is used to determine the memory allocation priority corresponding to each battery management task according to the task type of the battery management task, where the memory allocation priority of the static task is higher than that of the dynamic task; determine the second memory area from the first memory area in the order of the memory allocation priorities of the battery management tasks from high to low; The second memory area includes a memory area corresponding to the static task and / or a memory area corresponding to the dynamic task. The memory allocator is further configured to determine, in the order of decreasing memory allocation priority of the battery management task, the static memory area in the first memory area as the memory area corresponding to the static task, where the static memory area is the memory area in the first memory area with a memory greater than the minimum memory required to execute the static task; and determine the dynamic memory area in the first memory area as the memory area corresponding to the dynamic task, where the dynamic memory area is the remaining memory area in the first memory area after allocating memory for the static task.

10. A memory allocation device for a battery management system, characterized in that, Comprising: A task acquisition module, configured to acquire the task type of the battery management task in response to a memory allocation request; A memory determination module, configured to determine a second memory area corresponding to the task type of the battery management task from a first memory area of an operating system corresponding to the battery management system; A memory allocation module, configured to allocate the second memory area to the battery management task by using a memory allocation strategy corresponding to the task type; When there are multiple battery management tasks, the memory determination module includes: a priority determination module, configured to, for each battery management task, determine the memory allocation priority corresponding to the battery management task according to the task type of the battery management task, where the memory allocation priority of the static task is higher than that of the dynamic task; a first memory determination module, configured to determine the second memory area from the first memory area in the order of decreasing memory allocation priority of the battery management task; The second memory area includes a memory area corresponding to the static task and / or a memory area corresponding to the dynamic task. The first memory determination module is further configured to determine, in the order of decreasing memory allocation priority of the battery management task, the static memory area in the first memory area as the memory area corresponding to the static task, where the static memory area is the memory area in the first memory area with a memory greater than the minimum memory required to execute the static task; and determine the dynamic memory area in the first memory area as the memory area corresponding to the dynamic task, where the dynamic memory area is the remaining memory area in the first memory area after allocating memory for the static task.

11. A readable storage medium, characterized in that, Computer program instructions are stored on a readable storage medium, and when the computer program instructions are executed by a processor, the memory allocation method of the battery management system according to any one of claims 1-8 is implemented.

12. A computer program product, characterized in that, When the instructions in the computer program product are executed by a processor of an electronic device, the electronic device is caused to execute the memory allocation method of the battery management system according to any one of claims 1-8.

Citation Information

Patent Citations

  • Memory allocation method and system, electronic equipment and storage medium

    CN115344391A