A method and apparatus for rapidly generating BMS simulated front-end drivers

By obtaining preset configuration information and using pseudocode templates to generate BMS simulated front-end drivers, the problems of high development complexity and quality dependence on engineers' abilities are solved, and high-quality drivers are generated quickly.

CN115794114BActive Publication Date: 2026-06-30CHINA FAW CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA FAW CO LTD
Filing Date
2022-11-23
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

In existing technologies, BMS-simulated front-end driver development is highly complex, time-consuming, and its quality depends on the engineer's ability. Furthermore, the code review is not thorough, leading to inconsistent quality.

Method used

This paper provides a method for rapidly generating BMS simulation front-end drivers. By obtaining preset general configuration, command configuration, function description and timing configuration information, the driver is generated using pseudocode templates, ensuring consistent development quality and review quality.

Benefits of technology

This significantly shortened the development cycle, ensured consistent development quality of drivers, and improved the quality of code reviews.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115794114B_ABST
    Figure CN115794114B_ABST
Patent Text Reader

Abstract

This invention discloses a method and apparatus for rapidly generating a BMS simulated front-end driver. The method includes: acquiring general configuration information configured by a preset general configuration module, command configuration information preset by a preset command configuration module, function description information preset by a preset function description module, and timing configuration information preset by a preset timing configuration module; and generating a BMS simulated front-end driver based on the general configuration information, command configuration information, function description information, and timing configuration information. The rapid generation method for BMS simulated front-end drivers provided in this application describes each module using a fixed pseudocode template and then uses a code generation module for automatic code generation, significantly shortening the development cycle and ensuring consistent development quality. Furthermore, the pseudocode review process improves review quality, thereby enhancing the overall development quality of the driver.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of BMS simulated front-end driver development technology, and in particular to a method and apparatus for rapidly generating BMS simulated front-end drivers. Background Technology

[0002] Among the many complex drivers in a battery management system, the development of the simulation front-end is the most complex. Therefore, developers need the most time to develop the driver, and the quality of the simulation front-end driver largely determines the quality of the entire BMS product. However, the development methods of the same simulation front-end driver developed by different engineers vary widely, and the development quality is also inconsistent. This relies too much on the engineer's ability. Code reviewers do not conduct in-depth reviews of the driver code without relevant experience or prior reading of the manual, and the review quality is even more difficult to guarantee when the source code is not readable.

[0003] Therefore, there is a need for a technical solution to address or at least mitigate the aforementioned shortcomings of existing technologies. Summary of the Invention

[0004] The purpose of this invention is to provide a method for rapidly generating BMS simulated front-end drivers to at least solve one of the aforementioned technical problems.

[0005] This invention provides the following solution:

[0006] According to one aspect of the present invention, a method for rapidly generating BMS simulated front-end drivers is provided, the method comprising:

[0007] Obtain the general configuration information configured by the preset general configuration module, the command configuration information preset by the preset command configuration module, the function description information preset by the preset function description module, and the timing configuration information preset by the preset timing configuration module;

[0008] Generate a BMS simulation front-end driver based on general configuration information, command configuration information, function description information, and timing configuration information.

[0009] Optionally, the general configuration information includes the analog front-end hardware configuration and basic chip information;

[0010] The command configuration information includes configuring the simulated front-end command format;

[0011] The function description information includes command sequence information;

[0012] The timing configuration information includes the state machine and internal mode transitions.

[0013] Optionally, the analog front-end hardware configuration and chip basic information include cell channel configuration information, temperature channel configuration information, node number configuration information, overvoltage threshold configuration information, overtemperature threshold configuration information, and communication API information configuration information.

[0014] The simulated front-end command format includes command name and command function description, command type, command data composition, command length, verification algorithm, command length, and bus frequency.

[0015] Optionally, the preset function description information of the preset function description module is set using the following method:

[0016] The functional description module is used to generate the framework of the functional function. Commands defined in the preset command configuration module need to be added to the functional description module. By adding commands and filling in the corresponding command data, a valid command can be generated. When generating code, this command will be generated as a local variable. The SPI transmit API configured by the general module is added after the command; and...

[0017] The function description module is used to receive data. The parsing of the data requires parsing the data format definition according to the preset command configuration module. The parsed data will establish a relationship with global variables or return values ​​through the preset command configuration module.

[0018] Optionally, the timing configuration information preset by the preset timing configuration module is preset in the following manner:

[0019] The timing configuration module is used to configure the state machine mode, and at the same time, the functions configured in the function description module are added to the corresponding state machine mode and sorted in the state machine mode.

[0020] Optionally, generating the BMS simulation front-end driver based on the user-generated information, general configuration information, command configuration information, function description information, and timing configuration information includes:

[0021] Obtain the configuration content from the general configuration module;

[0022] A header file is generated based on the configuration content in the general configuration module. Macro definitions are generated according to the channel configuration, number of nodes, and threshold configuration, and the header file in the configuration content is included, thus forming the first part of the program.

[0023] Optionally, generating the BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes:

[0024] Get the content from the function description module;

[0025] The source file is generated based on the content in the function description module, and the code is generated based on the content in the preset reference command configuration module. The function name is generated based on the preset function description module name, the input parameters are generated as function input parameters, the return value is generated as return parameters, and global variables are generated according to the configuration content. The commands defined in the preset function description module are generated in sequence, thus forming the second part of the program.

[0026] Optionally, generating the BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes:

[0027] Retrieve the contents of the preset command configuration module;

[0028] Based on the data format and specific data content defined in the command configuration module, the program will be generated according to the specific configuration content in the function description configuration module. For command sending and receiving, the standard API interface will be generated according to the API information in the preset general configuration module, thus generating the third part of the program.

[0029] Optionally, generating the BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes:

[0030] The annotation content is generated based on the command configuration information; wherein...

[0031] The first part of the program, the second part of the program, the third part of the program, and the comments constitute the BMS simulated front-end driver.

[0032] This application also provides a rapid generation device for BMS simulated front-end drivers, the rapid generation device for BMS simulated front-end drivers comprising:

[0033] A preset general configuration module is used to configure general configuration information;

[0034] A preset command configuration module, which is used to configure command configuration information;

[0035] A preset function description module is used to preset function description information;

[0036] A preset timing configuration module, wherein the preset timing configuration module is used to preset timing configuration information;

[0037] The program generation module is used to generate a BMS simulation front-end driver based on general configuration information, command configuration information, function description information, and timing configuration information.

[0038] The BMS simulation front-end driver rapid generation method provided in this application describes each module using a fixed pseudocode template and then uses a code generation module for automatic code generation, which greatly shortens the development cycle and ensures consistent development quality. At the same time, the pseudocode review process can improve the review quality, thereby improving the overall development quality of the driver. Attached Figure Description

[0039] Figure 1 This is a flowchart of a method for rapidly generating BMS simulated front-end drivers provided in one or more embodiments of the present invention.

[0040] Figure 2 This is a block diagram of an electronic device structure provided by one or more embodiments of the present invention for a method for rapidly generating BMS simulated front-end drivers.

[0041] Figure 3 This is a schematic diagram of the structure of a BMS simulated front-end driver rapid generation device according to an embodiment of this application. Detailed Implementation

[0042] The technical solution of the present invention will now be clearly and completely described with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0043] Figure 1 This is a flowchart of a method for rapidly generating BMS simulated front-end drivers provided in one or more embodiments of the present invention.

[0044] like Figure 1 The BMS emulation front-end driver rapid generation method shown includes:

[0045] Step 1: Obtain the general configuration information configured by the preset general configuration module, the command configuration information preset by the preset command configuration module, the function description information preset by the preset function description module, and the timing configuration information preset by the preset timing configuration module.

[0046] Step 2: Generate the BMS simulation front-end driver based on the general configuration information, command configuration information, function description information, and timing configuration information.

[0047] The BMS simulation front-end driver rapid generation method provided in this application describes each module using a fixed pseudocode template and then uses a code generation module for automatic code generation, which greatly shortens the development cycle and ensures consistent development quality. At the same time, the pseudocode review process can improve the review quality, thereby improving the overall development quality of the driver.

[0048] In this embodiment, the general configuration information includes the analog front-end hardware configuration and basic chip information;

[0049] Command configuration information includes configuring the format of the simulated front-end command;

[0050] Function description information includes command sequence information;

[0051] The timing configuration information includes the state machine and internal mode transitions.

[0052] In this embodiment, the analog front-end hardware configuration and chip basic information include cell channel configuration information, temperature channel configuration information, node number configuration information, overvoltage threshold configuration information, overtemperature threshold configuration information, communication API information configuration information, and low-power wake-up configuration information, etc. The low-power wake-up configuration information can be overvoltage fault wake-up threshold, overtemperature fault wake-up threshold, overheating rate wake-up threshold, and cell voltage rise rate wake-up threshold.

[0053] Specifically, the preset general module configuration of the analog front end requires configuration of cell channels, temperature channels, number of nodes, overvoltage threshold, overtemperature threshold, and communication API information.

[0054] The above-mentioned cell channel configuration and temperature channel configuration are configured according to binary numbers and described using hexadecimal numbers. The least significant bit represents the lowest serial number channel status of the chip, and the most significant bit represents the highest serial number status that the chip can support. 0 indicates disabled, and 1 indicates enabled.

[0055] For the above node quantity configuration, simply fill in the numbers in decimal.

[0056] For the above-mentioned overvoltage threshold configuration and overtemperature threshold configuration, the input chip voltage and temperature resolution, the conversion relationship between the physical values ​​of input voltage and temperature and digital quantities, and the description of the conversion relationship need to be input in accordance with the expression method of C language.

[0057] For the communication API information configuration, fill in the actual standard interface name and the header file name of the standard interface declaration.

[0058] In this embodiment, the simulated front-end command format includes command name and command function description, command type, command data structure, command length, verification algorithm, command length, and bus frequency.

[0059] Specifically, the command configuration module includes the command name and command function description, command type, command data composition, command length, verification algorithm, received data length, and bus frequency.

[0060] Command data composition includes the composition of sent command data and the methods for composing received data, including:

[0061] Command data is sent in register units, with each sub-function of the register arranged and displayed bit by bit. The interface is decomposed according to the sub-functions in the chip registers. Each sub-function has an independent enable switch. If the enable switch is turned on, the corresponding code will be generated; if it is not turned on, the code for that function will not be generated. The received data format is a two-dimensional array. The first dimension is the number of analog front-end nodes, and the second dimension is the data received by each corresponding analog front-end. The first dimension data can be defined according to project requirements, and the valid start bits of data such as actual cell voltage, temperature, and diagnostic information can be defined according to the analog front-end data receiving method.

[0062] Regarding the command names and function descriptions mentioned above, the simulated front-end commands can be named according to the developer's code style guidelines. The command function descriptions are mainly used as annotations for the simulated front-end commands, and the corresponding execution times in the simulated front-end manual need to be configured in this module.

[0063] Regarding the type of command to be sent, there are two categories: send commands and read commands. Send commands are further divided into broadcast commands and local commands.

[0064] Regarding the command data structure and verification algorithm, the main focus is on distinguishing the data format of sent and received commands, configuring the data area, verification area, and other characteristic flags, and also filling in the CRC verification algorithm corresponding to the simulated front end into the verification configuration item.

[0065] For the length of the sent command, the length of the received command, and the byte length, please refer to the specifications in the datasheet.

[0066] Based on the bus frequency and the lengths of the sent and received commands mentioned above, the transmission time of the sent and received commands is calculated according to the bus frequency. This time is expressed in the form of comments.

[0067] In this embodiment, the preset function description information of the preset function description module is set using the following method:

[0068] The function description module is used to generate the framework of the function. This framework is the function entity, mainly composed of the function name and function body. The function name is the name of the function, and the function name can optionally include a framework interface. This framework interface manifests as function parameters after code generation. If no parameters are selected, a parameterless function entity is automatically generated. The function description module needs to add commands defined in the preset command configuration module. The command data for the corresponding command is filled in after the command. This operation generates a valid command, which is generated as a variable during code generation. During code generation, the system automatically adds the SPI transmit API configured in the general module after the command. The parameters in the API are the aforementioned command data. The SPI transmit API interface has three parameters: the first is the length of the received data in bytes, the second is the transmit command parameter, and the third is the receive data parameter; and...

[0069] The functional description module is further used to receive data parsing. The parsing requires parsing the data format definition according to the preset command configuration module. The parsed data will establish a relationship with global variables or return values ​​through the preset command configuration module.

[0070] Specifically, the function selection module description can establish corresponding functional units according to the required functions, configure the function module name, input parameters and their data types, return parameters and their data types, global variables and their data types according to the coding specifications. This part can generate the framework of the function. In the module, commands defined in the command configuration module need to be added. By adding commands and filling in the command data of the corresponding commands, a valid command can be generated. When generating code, the command will be generated as a local variable. The SPI transmit API configured by the general module is added after the command. The parsing of received data needs to be parsed according to the data format definition of the command configuration module. The parsed data will establish a relationship with global variables or return values ​​through the configuration module.

[0071] In this embodiment, the timing configuration information preset by the preset timing configuration module is preset in the following manner:

[0072] The timing configuration module is used to configure the state machine mode. Specifically, the state machine mode is a simulated main scheduling state machine function of the front-end driver. The function name can be customized in the configuration module. The generated function type is a function with no return value and no parameters. The main state machine generated code is in the form of a C language switch statement. The switch statement includes the initialization state, sampling state, diagnosis state, balancing state, chip information reading state, and default state. Each state adds functions defined in the function description module as needed. The order in which the functions in the function description module are added determines the order in which the functions are executed in the corresponding statement.

[0073] The state machine is described using a switch case approach. Each case contains the functions configured in the function description module, and the jump conditions for each case are designed based on the variables configured in the function description module.

[0074] For the state machine pattern, this module can be named arbitrarily according to requirements, and a value needs to be assigned to the pattern.

[0075] In this embodiment, generating the BMS simulated front-end driver based on the user-generated information, general configuration information, command configuration information, function description information, and timing configuration information includes:

[0076] Retrieve the configuration content from the general configuration module;

[0077] A header file is generated based on the configuration content in the general configuration module. The source files generated by other modules (timing configuration module, command configuration module, and function description module) all include this header file by default. The code content generated in this header file is a macro definition generated according to the channel configuration, number of nodes, and threshold configuration, thus forming the first part of the program.

[0078] In this embodiment, generating the BMS simulated front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes:

[0079] Get the content from the function description module;

[0080] A source file named AfeFeatureCfg.c is generated based on the content in the functional description module. The code is generated by pre-setting the content in the reference command configuration module. Function names are generated based on the pre-set functional description module name, function input parameters are generated based on input parameters, return values ​​are generated based on return parameters, and global variables are generated according to the configuration content. The commands defined in the pre-set functional description module are generated in sequence, thus forming the second part of the program.

[0081] In this embodiment, generating the BMS simulated front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes:

[0082] Retrieve the contents of the preset command configuration module;

[0083] Based on the data format and specific data content defined in the command configuration module, the code generation module generates the code according to the specific configuration content in the function description configuration module. For functions added in the function description module, when generating code, the code generation module will identify the configuration parameters of the sub-functions in the registers defined in the command configuration module and the enable switch status to generate command parameters. After generating these parameters, the code generation module will generate the command parameters of the function in the function described in the function description module. By default, an SPI transmit API interface is automatically generated after the command parameters and automatically added to the SPI transmit API parameters with the command parameter name. For the data receiving part, the receive data parameters in the SPI API will be read directly. For command transmission, the standard API interface for receiving is generated according to the API information in the preset general configuration module, thus generating the third part of the program.

[0084] In this embodiment, generating the BMS simulated front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes:

[0085] The annotation content is generated based on the command configuration information; wherein...

[0086] The first part of the program, the second part of the program, the third part of the program, and the comments constitute the BMS simulated front-end driver.

[0087] Specifically, it is necessary to identify the configuration content of each module and generate C language code based on the configuration content of each module.

[0088] A header file will be generated for the configuration content in the above-mentioned preset general configuration module. Macro definitions will be generated according to the channel configuration, number of nodes, and threshold configuration, and the header file of the configuration content will be included.

[0089] Comments will be generated for the content in the above-mentioned preset command configuration module for design and review reference.

[0090] The above-mentioned preset function description module will generate a source file. It is necessary to reference the content in the command configuration module to generate code. The preset function description module name will be generated into a function name, the input parameters will be generated into function input parameters, the return parameters will be generated into return values, and global variables will be generated according to the configuration content. The commands defined in the preset function description module will be generated in sequence.

[0091] For the above commands, the command code will be generated according to the data format defined in the preset command configuration module and the specific data content will be generated according to the specific configuration content in the preset function description configuration module. For command sending and receiving, the standard API interface will be generated according to the API information in the preset general configuration module.

[0092] See Figure 3 This application also provides a rapid generation device for BMS simulated front-end drivers. The device includes a preset general configuration module, a preset command configuration module, a preset function description module, a preset timing configuration module, and a program generation module. The preset general configuration module is used to configure general configuration information; the preset command configuration module is used to configure command configuration information; the preset function description module is used to preset function description information; the preset timing configuration module is used to preset timing configuration information; and the program generation module is used to generate a BMS simulated front-end driver based on the general configuration information, command configuration information, function description information, and timing configuration information.

[0093] In this embodiment, the program generation module generates the BMS simulated front-end driver based on general configuration information, command configuration information, function description information, and timing configuration information as follows:

[0094] Code is generated by combining general configuration information, command configuration information, function description information, and timing configuration information. The specific generation order is as follows: first, the configuration module code is generated, then the timing configuration code, then the command configuration module code, and finally the function description code. These codes are combined to form the BMS simulation front-end driver of this application.

[0095] Specifically, the preset general configuration module is used to configure the external circuit configuration information of the analog front-end chip, configure the alarm thresholds for cell voltage and temperature, set the number of analog front-end nodes on the daisy chain, and import the life header files of the external driver interfaces that need to be called.

[0096] The preset command configuration module is used to configure commands according to the commands defined in the simulation front-end manual. The configuration content includes command name and command function description, command type, command data composition, command length, verification algorithm, received data length, and bus frequency.

[0097] The preset function description module is used to configure function names, related parameters, referenced commands, and referenced standard function API interfaces.

[0098] The preset timing configuration module is used to configure the mode and reference the function modules configured in the function description module in the corresponding mode. At the same time, the mode jump conditions are configured, so as to generate the overall scheduling mode of the simulated front-end function.

[0099] Figure 2 This is a block diagram of an electronic device structure provided by one or more embodiments of the present invention.

[0100] like Figure 2 As shown, this application also discloses an electronic device, including: a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the rapid development method of the vehicle APP backend interface program.

[0101] This application also provides a computer-readable storage medium storing a computer program executable by an electronic device, which, when run on the electronic device, causes the electronic device to perform the steps of a rapid development method for an in-vehicle APP backend interface program.

[0102] The communication bus mentioned in the above electronic devices can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into address bus, data bus, control bus, etc. For ease of illustration, only one thick line is used to represent it in the diagram, but this does not mean that there is only one bus or one type of bus.

[0103] The electronic device comprises a hardware layer, an operating system layer running on top of the hardware layer, and an application layer running on the operating system. The hardware layer includes hardware such as a central processing unit (CPU), a memory management unit (MMU), and memory. The operating system can be any one or more computer operating systems that control the electronic device through processes, such as Linux, Unix, Android, iOS, or Windows. Furthermore, in this embodiment of the invention, the electronic device can be a smartphone, tablet computer, or other handheld device, or a desktop computer, portable computer, or other electronic device; there is no particular limitation in this embodiment.

[0104] In this embodiment of the invention, the executing entity for electronic device control can be an electronic device itself, or a functional module within an electronic device capable of calling and executing a program. The electronic device can obtain the firmware corresponding to the storage medium. This firmware is provided by the supplier, and different storage media may have the same or different firmware; no limitation is made here. After obtaining the firmware corresponding to the storage medium, the electronic device can write this firmware into the storage medium; specifically, it burns the firmware corresponding to the storage medium into the storage medium. The process of burning the firmware into the storage medium can be implemented using existing technology, and will not be elaborated upon in this embodiment of the invention.

[0105] Electronic devices can also obtain reset commands corresponding to the storage media. The reset commands corresponding to the storage media are provided by the supplier. The reset commands corresponding to different storage media can be the same or different, and no restrictions are imposed here.

[0106] At this time, the storage medium of the electronic device is a storage medium on which the corresponding firmware has been written. The electronic device can respond to the reset command corresponding to the storage medium on which the corresponding firmware has been written, thereby resetting the storage medium on which the corresponding firmware has been written according to the reset command. The process of resetting the storage medium according to the reset command can be implemented by existing technology and will not be described in detail in this embodiment of the invention.

[0107] For ease of description, the above devices are described separately by function as various units and modules. Of course, in implementing this application, the functions of each unit and module can be implemented in one or more software and / or hardware.

[0108] It will be understood by those skilled in the art that, unless otherwise defined, all terms used herein (including technical and scientific terms) have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. It should also be understood that terms such as those defined in general dictionaries should be understood to have the meaning consistent with their meaning in the context of the prior art, and should not be interpreted in an idealized or overly formal sense unless specifically defined.

[0109] For the sake of simplicity, the method embodiments are described as a series of actions. However, those skilled in the art should understand that the embodiments of the present invention are not limited to the described order of actions, because according to the embodiments of the present invention, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are preferred embodiments, and the actions involved are not necessarily essential to the embodiments of the present invention.

[0110] As can be seen from the above description of the embodiments, those skilled in the art can clearly understand that this application can be implemented by means of software plus necessary general-purpose hardware platforms. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in various embodiments or some parts of the embodiments of this application.

[0111] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features; and these modifications or substitutions 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 invention.

Claims

1. A method for rapidly generating BMS-simulated front-end drivers, characterized in that, The method for rapidly generating BMS-simulated front-end drivers includes: Obtain the general configuration information configured by the preset general configuration module, the command configuration information preset by the preset command configuration module, the function description information preset by the preset function description module, and the timing configuration information preset by the preset timing configuration module; Obtain vehicle parameter information provided by the user; A BMS simulation front-end driver is generated based on vehicle parameter information, general configuration information, command configuration information, function description information, and timing configuration information. The general configuration information includes the analog front-end hardware configuration and basic chip information; The command configuration information includes configuring the simulated front-end command format; The function description information includes command sequence information; The timing configuration information includes the state machine and internal mode transitions; The analog front-end hardware configuration and chip basic information include cell channel configuration information, temperature channel configuration information, node number configuration information, overvoltage threshold configuration information, overtemperature threshold configuration information, communication API information configuration information, and low-power wake-up configuration information. The simulated front-end command format includes command name and command function description, command type, command data composition, command length, verification algorithm, received data length, and bus frequency; The preset function description information of the preset function description module is set using the following method: The functional description module is used to generate the framework part of the functional function; The functional description module is further used to receive data parsing. The data parsing needs to be parsed according to the data format definition defined by the preset command configuration module. The parsed data will establish a relationship with global variables or return values ​​through the preset command configuration module. The timing configuration information preset by the preset timing configuration module is preset in the following manner: The timing configuration module is used to configure the state machine mode; The BMS simulation front-end driver is generated based on the user's information to be generated, general configuration information, command configuration information, function description information, and timing configuration information, including: Obtain the configuration content from the general configuration module; A header file is generated based on the configuration content in the general configuration module. The source files generated by other modules all include this header file by default. The code content generated in this header file is a macro definition generated according to the channel configuration, the number of nodes, and the threshold configuration, thus forming the first part of the program. Generating a BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes: Get the content from the function description module; The source file is generated based on the content in the function description module, and the code is generated based on the content in the preset reference command configuration module. The function name is generated based on the preset function description module name, the input parameters are generated as function input parameters, the return value is generated as return parameters, and global variables are generated according to the configuration content. The commands defined in the preset function description module are generated in sequence to form the second part of the program. Generating a BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes: Retrieve the contents of the preset command configuration module; The program generates the third part by generating the data according to the data format and specific data content defined in the command configuration module and the specific configuration content in the function description configuration module. The standard API interface for sending and receiving commands is generated according to the API information in the preset general configuration module. Generating a BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes: The annotation content is generated based on the command configuration information; wherein... The first part of the program, the second part of the program, the third part of the program, and the comments constitute the BMS simulated front-end driver.

2. A rapid generation device for BMS simulated front-end drivers, characterized in that, The BMS simulated front-end driver rapid generation device includes: A preset general configuration module is used to configure general configuration information; A preset command configuration module, which is used to configure command configuration information; A preset function description module is used to preset function description information; A preset timing configuration module, wherein the preset timing configuration module is used to preset timing configuration information; The program generation module is used to generate a BMS simulation front-end driver based on general configuration information, command configuration information, function description information, and timing configuration information. The general configuration information includes the analog front-end hardware configuration and basic chip information; The command configuration information includes configuring the simulated front-end command format; The function description information includes command sequence information; The timing configuration information includes the state machine and internal mode transitions; The analog front-end hardware configuration and chip basic information include cell channel configuration information, temperature channel configuration information, node number configuration information, overvoltage threshold configuration information, overtemperature threshold configuration information, communication API information configuration information, and low-power wake-up configuration information. The simulated front-end command format includes command name and command function description, command type, command data composition, command length, verification algorithm, received data length, and bus frequency; The preset function description information of the preset function description module is set using the following method: The functional description module is used to generate the framework part of the functional function; The functional description module is further used to receive data parsing. The data parsing needs to be parsed according to the data format definition defined by the preset command configuration module. The parsed data will establish a relationship with global variables or return values ​​through the preset command configuration module. The timing configuration information preset by the preset timing configuration module is preset in the following manner: The timing configuration module is used to configure the state machine mode; The BMS simulation front-end driver is generated based on the user's information to be generated, general configuration information, command configuration information, function description information, and timing configuration information, including: Obtain the configuration content from the general configuration module; A header file is generated based on the configuration content in the general configuration module. The source files generated by other modules all include this header file by default. The code content generated in this header file is a macro definition generated according to the channel configuration, the number of nodes, and the threshold configuration, thus forming the first part of the program. Generating a BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes: Get the content from the function description module; The source file is generated based on the content in the function description module, and the code is generated based on the content in the preset reference command configuration module. The function name is generated based on the preset function description module name, the input parameters are generated as function input parameters, the return value is generated as return parameters, and global variables are generated according to the configuration content. The commands defined in the preset function description module are generated in sequence to form the second part of the program. Generating a BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes: Retrieve the contents of the preset command configuration module; The program generates the third part by generating the data according to the data format and specific data content defined in the command configuration module and the specific configuration content in the function description configuration module. The standard API interface for sending and receiving commands is generated according to the API information in the preset general configuration module. Generating a BMS simulation front-end driver based on the contents of the preset general configuration module, preset command configuration module, preset function description module, and preset timing configuration module further includes: The annotation content is generated based on the command configuration information; wherein... The first part of the program, the second part of the program, the third part of the program, and the comments constitute the BMS simulated front-end driver.