Brushing method and device for battery management software

By monitoring and verifying the integrity of the flashing files in real time, and automatically handling flashing errors in the battery management software, the problem of high error rate and low efficiency in the flashing process in the existing technology is solved, thereby improving the flashing success rate of the battery management software and battery safety.

CN119292617AInactive Publication Date: 2025-01-10CHERY AUTOMOBILE CO LTD

Patent Information

Application Number
CN202411394015.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-08
Publication Date
2025-01-10
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

In existing technologies, the software flashing process of battery management systems is easily affected by equipment or parameter settings, resulting in a high error rate, low efficiency, and the need for users to manually handle errors, which affects battery safety and lifespan.

Method used

The host computer monitors and verifies the flashing files in real time, detects errors in real time, and automatically controls the battery management software to stop or resume the flashing process, including data recovery and reset steps, to ensure the integrity and security of the flashing files.

Benefits of technology

It improves the success rate and efficiency of flashing battery management software, reduces the impact of errors, ensures battery safety and lifespan, and avoids the need for users to manually handle errors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119292617A_ABST
    Figure CN119292617A_ABST
Patent Text Reader

Abstract

The invention discloses a flashing method and device for battery management software, and relates to the technical field of battery management, the method comprises the following steps: obtaining a flashing file, the flashing file being a file used when an upper computer controls the battery management software corresponding to a first vehicle to perform software flashing; checking and encrypting the flash file to obtain a preprocessed file; sending a flashing instruction and the preprocessing file to the first vehicle; the flashing process of the battery management software is monitored in real time, and the execution progress of the flashing process and the condition that flashing errors exist in the flashing process are determined; in response to a flashing error in the flashing process, the battery management software is controlled to execute a corresponding flashing management step, and the flashing management step comprises at least one of a flashing stopping step, a data recovery step and a flashing resetting step. By verifying and encrypting the flashing file, the error rate in the flashing process is reduced, flashing errors are monitored in real time and processed in time, and the flashing efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of battery management technology, and in particular to a method and device for flashing battery management software. Background Art

[0002] The battery management system (BMS system) is a key system in electric vehicles for monitoring and managing battery packs. The BMS system needs to be regularly rewritten to update the algorithms in the software, fix known errors, etc., which can enhance battery safety and extend battery life.

[0003] In the related art, the BMS software flashing process is implemented through a host computer, which is a terminal device that can control the BMS system to flash. The host computer sends the firmware package required for flashing to the BMS system and sends instructions in real time to control the BMS to complete the flashing. The flashing process is susceptible to errors due to the influence of equipment or parameter settings.

[0004] However, the host computer can only report the flashing error to the user, and the user needs to manually solve the flashing error and restart the flashing process, which results in low flashing efficiency. Summary of the invention

[0005] The embodiment of the present application provides a flashing method and device for battery management software, which can reduce the error rate in the flashing process by verifying and encrypting the flashing file, monitor the errors in the flashing process in real time and handle them in time, and improve the flashing efficiency. The technical solution is as follows:

[0006] On the one hand, a method for flashing battery management software is provided, the method being executed by a host computer, and the method comprising:

[0007] Obtaining a flash file, wherein the flash file refers to a file used by the host computer to control the battery management software corresponding to the first vehicle to perform software flashing, wherein software flashing refers to a process of updating the battery management software and fixing errors;

[0008] Sending a flashing instruction and the flashing file to the first vehicle, wherein the flashing instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the flashing file;

[0009] Monitor the flashing process of the battery management software in real time and determine the flashing monitoring result, wherein the flashing monitoring result includes the execution progress of the flashing process and the existence of flashing errors in the flashing process;

[0010] In response to a flashing error occurring during the flashing process, controlling the battery management software to stop flashing;

[0011] Based on the flash monitoring result, the battery management software is controlled to automatically execute a flash management step, and the flash management step includes at least one of a data recovery step and a flash reset step.

[0012] On the other hand, a device for flashing battery management software is provided, the device comprising:

[0013] An acquisition module, used for acquiring a flash file, wherein the flash file refers to a file used by the host computer to control the battery management software corresponding to the first vehicle to perform software flashing, wherein software flashing refers to a process of updating the battery management software and fixing errors;

[0014] A sending module, used for sending a flashing instruction and the flashing file to the first vehicle, wherein the flashing instruction is used for instructing the battery management software corresponding to the first vehicle to perform software flashing based on the flashing file;

[0015] A monitoring module, used for monitoring the flashing process of the battery management software in real time and determining a flashing monitoring result, wherein the flashing monitoring result includes the execution progress of the flashing process and the existence of a flashing error in the flashing process;

[0016] A control module, configured to control the battery management software to stop flashing in response to a flashing error in the flashing process;

[0017] The control module is further used to control the battery management software to automatically execute a flash management step based on the flash monitoring result, and the flash management step includes at least one of a data recovery step and a flash reset step.

[0018] In an optional embodiment, the control module is also used to respond to a first flash error during the flash process, record the first flash error in a flash log and control the battery management software to stop flashing, the flash log being used to record the steps and the execution progress corresponding to the flash process; obtain the first execution progress corresponding to the first flash error from the flash log; and control the battery management software to automatically execute the flash management steps based on the first execution progress.

[0019] In an optional embodiment, the control module is also used to control the battery management software to automatically execute the flash reset step in response to the first execution progress being less than a preset progress threshold; or, in response to the first execution progress being greater than or equal to the preset progress threshold, control the battery management software to automatically execute the data recovery step.

[0020] In an optional embodiment, the flashing monitoring result includes the error type of the flashing error;

[0021] The control module is also used to obtain a management step comparison table, which contains the correspondence between the error type and the type of the flash management step; determine the type of the flash management step from the management step comparison table based on the error type indicated by the flash monitoring result; and control the battery management software to automatically execute the flash management step.

[0022] In an optional embodiment, the sending module is also used to perform a cyclic redundancy check on the flash file to obtain a first check value, wherein the flash file is marked with a second check value, and the matching relationship between the first check value and the second check value is used to verify the integrity of the flash file; when the first check value and the second check value match, an encryption key is obtained based on the flash file; the flash file is encrypted based on the encryption key to obtain a preprocessed file, and the preprocessed file meets preset file quality requirements; the flash instruction and the preprocessed file are sent to the first vehicle, and the flash instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the preprocessed file.

[0023] In an optional embodiment, the sending module is also used to receive a random number setting operation, the random number setting operation is used to obtain a random number when generating the encryption key, and the random number is a multi-digit number; receive a key generation operation, the key generation operation is used to indicate the method and time of generating the encryption key; based on the key generation operation, the random number is split into multiple digital segments, and the random number is inserted into the first verification value in a preset order to obtain the encryption key.

[0024] In an optional embodiment, the monitoring module is also used to display a flash log during real-time monitoring of the flashing process of the battery management software, and the flash log is used to record the steps corresponding to the flashing process and the execution progress; when the flash log indicates that the execution progress has not been completed, based on the fact that the recorded information in the flash log meets the preset recording requirements, it is determined that there is a flashing error in the flashing process.

[0025] In an optional embodiment, the monitoring module is also used to record the feedback information in the flash log in response to receiving feedback information sent by the battery management software, and the feedback information is used to indicate the status of the vehicle battery of the first vehicle during the flashing process of the battery management software, wherein the battery management software is used to manage the vehicle battery of the first vehicle; in response to the feedback information in the flash log not meeting the preset recording requirements, it is determined that a flashing error exists in the flashing process.

[0026] In an optional embodiment, the monitoring module is also used to determine that there is a flashing error in the flashing process in response to first flag information contained in the flashing log when the flashing log indicates that the execution progress has ended, wherein the first flag information is used to indicate that the flashing process has failed.

[0027] On the other hand, a computer device is provided, comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement a method for flashing battery management software as described in any of the above-mentioned embodiments of the present application.

[0028] On the other hand, a computer-readable storage medium is provided, in which at least one instruction, at least one program, a code set or an instruction set is stored, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement a method for flashing battery management software as described in any of the above-mentioned embodiments of the present application.

[0029] On the other hand, a computer program product or a computer program is provided, the computer program product or the computer program includes computer instructions, the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the flashing method of the battery management software described in any of the above embodiments.

[0030] The beneficial effects brought by the technical solution provided by the embodiment of the present application include at least:

[0031] By flashing files to control the battery management software to execute the software flashing process and monitoring the process in real time, it is possible to detect and process errors that may occur in the process, and interrupt the error flashing process in time. After the error is found, the error is automatically repaired or reset to prevent the battery management software from flashing wrong data into the software and affecting the safety of the vehicle battery, thereby improving the success rate of the flashing process. Compared with the related art, the user needs to analyze the errors reported by the host computer and manually start the data recovery or flashing reset steps, which can improve the flashing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0033] Figure 1 is a schematic diagram of a flash writing system provided by an exemplary embodiment of the present application;

[0034] Figure 2 This is a schematic diagram of the overall architecture of a host computer executing a flashing process provided by an exemplary embodiment of the present application;

[0035] Figure 3 is a flow chart of a flashing method of battery management software provided by an exemplary embodiment of the present application;

[0036] Figure 4 It is a structural block diagram of a flash writing device for battery management software provided by an exemplary embodiment of the present application;

[0037] Figure 5 It is a structural block diagram of a computer device provided by an exemplary embodiment of the present application. DETAILED DESCRIPTION

[0038] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.

[0039] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are merely examples of devices and methods consistent with some aspects of the present application as detailed in the appended claims.

[0040] The terms used in this application are for the purpose of describing specific embodiments only and are not intended to limit this application. The singular forms of "a", "said" and "the" used in this application and the appended claims are also intended to include plural forms unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.

[0041] It should be noted that the information and data involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0042] It should be understood that, although the terms first, second, etc. may be used in the present application to describe various information, these information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present application, the first parameter may also be referred to as the second parameter, and similarly, the second parameter may also be referred to as the first parameter. Depending on the context, the word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".

[0043] First, a brief introduction is given to the terms involved in the embodiments of this application:

[0044] Battery Management System (BMS): An electronic system used to monitor and manage battery cells or battery packs. It plays a vital role in a variety of battery-driven devices such as new energy vehicles, power tools, and energy storage systems. The main functions of BMS include: monitoring the battery voltage to ensure that the voltage is within a safe range; managing the battery's charge and discharge current to avoid damage to the battery due to excessive current; estimating the battery's remaining capacity and health status to provide a basis for battery maintenance and replacement; monitoring the battery's temperature to prevent the battery from overheating.

[0045] Among them, the BMS system includes a hardware part and a software part. In this application, the battery management software of the first vehicle is taken as an example for explanation. The battery management software (BMS software) that needs to be flashed is the software part of the BMS system of the first vehicle.

[0046] Host computer: usually refers to the control computer or host at the upper level in a distributed system. In industrial automation, data acquisition, monitoring and control systems, the host computer is responsible for processing data, issuing control instructions, and interacting with users or other systems. In this application, the host computer for flashing the BMS software is a computer system or terminal device, which communicates with the BMS to send the flash file (also known as firmware package) and control instructions required for flashing to complete the flashing process. The host computer plays the role of a control center in the flashing process. It is not only responsible for sending firmware data, but also for monitoring the entire flashing process to ensure the correctness and integrity of the flashing.

[0047] Firmware package: refers to a group of files that contain the BMS system software, which are packaged together for distribution and installation. In the context of the BMS system, the firmware package usually contains software programs that control battery charging and discharging, monitor battery status, perform battery balancing and other tasks. The firmware package can be used to update or repair the software in the BMS system to ensure the performance and safety of the battery management system. Among them, the flash file in this application refers to the firmware package, which is sent by the host computer to the BMS system, and the BMS software is updated and errors are fixed based on the flash file.

[0048] Cyclic Redundancy Check (CRC): is a commonly used technology for detecting errors in data transmission or storage. It calculates the check value of the data block through a mathematical algorithm and appends it to the end of the data or saves it in a specific place. After the data is transmitted or stored, the value recalculated by the same algorithm can be compared with the original check value to verify the integrity of the data.

[0049] CAN (Controller Area Network): A serial communication protocol. In the automotive field, CAN signals are used to transmit data. The CAN bus allows different vehicle electronic control units to communicate and exchange data. This networked structure helps to simplify the wiring inside the car and improves the reliability and flexibility of data communication. The main features of CAN include: (1) Multi-master control: Multiple devices can exist on the network at the same time, they share the bus, and can compete for control of the bus based on the priority of the message. (2) High reliability: The CAN protocol has error detection and correction functions to ensure the accuracy of data transmission. (3) Real-time: The CAN protocol supports real-time data transmission and is suitable for control systems that require fast response. (4) Support remote requests: Data from other nodes can be requested by sending remote frames.

[0050] The battery management system is a critical component in new energy vehicles / electric vehicles, responsible for monitoring and controlling the working status of the battery pack to ensure the safety and performance of the battery. In order to maintain the optimal performance and safety of the battery system and to resolve possible defects in the software, it is necessary to regularly flash the software, that is, regularly update and fix errors in the software part of the BMS system. This process involves optimizing the algorithms in the BMS system and fixing known software defects, thereby improving the safety of the battery, extending its service life, and maintaining the stability of battery performance.

[0051] The software flashing of the BMS system depends on the host computer, which is a terminal device that has the ability to control the BMS system to flash the software. During the flashing process, the host computer is responsible for transmitting the firmware package to the BMS system and sending control instructions in real time to guide the BMS system to complete the flashing operation. This process requires a stable and reliable communication connection between the host computer and the BMS system to ensure that the firmware package can be accurately transmitted to the BMS system.

[0052] However, the software flashing process may be interfered by a variety of factors, affecting the success rate of the flashing process. For example, if the configuration parameters of the host computer or BMS system are not set properly, it may cause communication failures or data transmission errors. Electromagnetic interference may also affect the flashing process, especially in scenarios with complex electromagnetic environments. Furthermore, if the firmware package itself contains data errors or incomplete data, this will directly lead to flashing failure. Once any error occurs during the flashing process, the entire flashing process may need to be restarted, which not only reduces work efficiency, but may also cause unnecessary pressure on the battery system.

[0053] In order to improve the reliability and efficiency of the flashing process, timely discover and solve errors that occur during the flashing process, this application provides a flashing method for battery management software, which ensures the smooth progress of the flashing process from aspects such as device verification, file verification, transmission encryption, real-time monitoring of the flashing process, error detection, and error handling. By verifying the flashing file, the file quality of the flashing file is guaranteed, and the data of the flashing file is encrypted to avoid tampering with the data of the flashing file during the flashing process based on the flashing file by the battery management software, thereby reducing the error rate during the flashing process. Monitor the progress of the flashing process in real time, detect and handle errors that may occur in the process, interrupt the erroneous flashing process in time, and automatically repair and reset the steps to avoid the battery management software flashing erroneous data into the software to affect the safety of the vehicle battery, and improve the flashing efficiency and the success rate of the flashing process.

[0054] Next, the flash writing system involved in the embodiment of the present application is described. For illustration, please refer to Figure 1 The flashing system involves a host computer 110 and a first vehicle 120, and there is a communication connection between the host computer 110 and the first vehicle 120. The first vehicle 120 includes a BMS system, and the software part of the BMS system is a battery management software, which needs to be flashed.

[0055] After obtaining the flash file, the host computer 110 verifies the flash file to verify the integrity and correctness of the flash file to avoid errors in the flash file that lead to the failure of the flash process. After successful verification, the flash file is encrypted to obtain an encrypted file.

[0056] Before the host computer 110 instructs the battery management software to be flashed, the BMS system needs to be verified, and the host computer 110 sends verification information to the first vehicle 120, and the first vehicle 120 sends the verification information to the BMS system through the vehicle signal, and the BMS system sends feedback information based on the verification information, and the first vehicle 120 transmits the feedback information to the host computer 110 for device verification. This verification process is used to determine whether the object that needs to be flashed is wrong.

[0057] In the present application, the process of the host computer 110 sending data / files / instructions to the first vehicle 120 may be referred to as the process of the host computer 110 sending data / files / instructions to the BMS system, both of which represent the process of the host computer 110 controlling the battery management software to execute software flashing.

[0058] When the verification is successful, the host computer 110 sends a flashing instruction to the BMS system, indicating that the BMS system can proceed to the accurate stage before flashing, and sends an encrypted flashing file to the BMS system.

[0059] The battery management software performs flashing based on the flashing file and the control instructions sent in real time by the host computer 110. The records generated in the process will be recorded in the flashing log and displayed on the user interface of the host computer 110 so that the user can view the flashing progress. When the host computer 110 detects an error, it automatically performs at least one of the following operations according to the error type: stop flashing, data recovery, flashing reset, and perform error analysis based on the error information recorded in the flashing log so that the user can determine the cause of the flashing error.

[0060] The host computer 110 includes the following modules, and the functions of each module correspond to different stages in the flashing process: (1) Communication module: responsible for data exchange between the host computer 110 and the BMS device (first vehicle 120), and supports CAN communication. It has high-speed data transmission capability, supports real-time communication and batch data transmission, and ensures data integrity and timeliness during the flashing process. (2) Data processing module: parses, processes and stores the received data, including firmware package parsing, parameter configuration, log recording, etc. It has powerful data processing capabilities, can process large amounts of data and provide real-time feedback on the progress and results of the flashing.

[0061] (3) User interface module: provides an intuitive and easy-to-use operating interface to support users in firmware selection, parameter setting, flash control and other operations. It has the characteristics of friendly interface and easy operation. (4) Security management module: responsible for security control of the entire flash process, including device authentication, data encryption, error detection and recovery, etc. It uses advanced security technology to ensure the security of the flash process and the confidentiality of data.

[0062] The host computer 110 establishes a connection with the first vehicle 120 (BMS system) through the communication interface, and performs device authentication to ensure that the flashing object (battery management software) is correct. The user selects the flashing file to be flashed through the user interface, and loads it into the host computer 110, and configures the flashing parameters such as baud rate, communication protocol, etc. according to actual needs. The host computer 110 transmits the flashing file to the BMS system through the communication interface, and controls the battery management software to perform the flashing operation. During this process, the host computer 110 monitors the flashing progress in real time and displays relevant information on the user interface, such as a progress bar, remaining time, etc. After the flashing is completed, the host computer 110 automatically performs a verification operation to ensure that the software is correctly flashed and can run normally.

[0063] like Figure 2 As shown, Figure 2 It is a schematic diagram of the overall architecture of the host computer executing the flashing process, including the following units.

[0064] 1. Start the initialization unit 201: Perform initialization operation before starting the host computer each time to ensure that the host computer can run normally and end the last flashing.

[0065] Exemplarily, the functional architecture of the startup initialization unit 201 includes the following parts: (1) Initialization of functions and properties: Initialization of various functions and properties of the host computer; (2) Loading configuration files: The configuration files are used to configure the system type when the host computer is running, and the system is used to realize the control of the host computer when flashing the BMS system; (3) Hardware parameters and connections: Setting the hardware parameters of the host computer to ensure the stability of the connection between the host computer and other devices; (4) Initialization of communication interface; (5) Initialization of global functions;

[0066] (6) Clear the cache; (7) Refresh the page; (8) Initialize the log; (9) Initialize the main interface.

[0067] 2. User interface unit 202: provides an interface for users to operate the host computer and receive user instructions.

[0068] Exemplarily, the functional architecture of the user interface unit 202 includes the following parts: (1) file processing; (2) editing UDS (Unified Diagnostic Services, automotive diagnostic communication protocol): users can edit diagnostic description files; (3) signature tool; (4) hardware configuration; (5) CRC calculation; (6) sending data; (7) CAN parsing: understanding and processing data passing through the CAN bus; (8) path configuration; (9) authorization configuration.

[0069] 3. Communication interaction unit 203: establishes a communication connection between the host computer and other devices or systems to achieve communication interaction and data transmission.

[0070] Exemplarily, the functional architecture of the communication interaction unit 203 includes the following parts: (1) communication connection; (2) disconnection; (3) sending data; (4) receiving data; (5) delay waiting; (6) locking synchronization; (7) channel setting.

[0071] 4. Error handling and recovery unit 204: When an error is detected during the flashing process, the error is handled in a timely manner and the flashing process is recovered so that the flashing can continue.

[0072] Exemplarily, the functional architecture of the error handling and recovery unit 204 includes the following parts: (1) real-time error detection; (2) error logging; (3) error analysis; (4) error response; (5) user notification; and (6) error prevention.

[0073] 5. Flashing completion and verification unit 205: When the battery management software reports that the flashing is completed, the flashing result is verified to ensure that the flashing is correct.

[0074] 6. Log recording and reporting unit 206: records the flashing process in the flashing log, and displays the flashing progress and correct completion status to the user according to the content in the flashing log.

[0075] 7. Close and exit unit 207: exit the flashing process.

[0076] 8. Export process unit 208: export the flash file and send it to the BMS system.

[0077] 9. Import process unit 209: import the flash file from the specified platform or application to the host computer.

[0078] 10. Data storage unit 210: stores data generated after the host computer is turned on, for example, data generated during the flashing process of the battery management software controlled by the host computer.

[0079] 11. Configuration management unit 211: configures the parameters of the host computer, for example, the system version of the host computer, the flashing script, etc. The flashing script instructs the host computer how to control the battery management software to flash, and contains multiple instructions.

[0080] In summary, the above-mentioned flashing system can reduce the error rate in the flashing process by verifying and encrypting the flashing files, monitor the errors occurring in the flashing process in real time and handle them in a timely manner, thereby improving the flashing efficiency.

[0081] Combined with the above-mentioned noun introduction and application scenarios, the flashing method of the battery management software provided by this application is described. The method is executed by the host computer, such as Figure 3 As shown, Figure 3The flowchart of a flashing method of battery management software provided by an exemplary embodiment of the present application includes the following steps.

[0082] Step 310, obtaining the flash file.

[0083] The flash file refers to a file used by the host computer to flash the battery management software corresponding to the first vehicle, and software flashing refers to the process of updating the battery management software and fixing errors. The flash file is also called a firmware package.

[0084] Optionally, methods of obtaining the flash file include but are not limited to the following.

[0085] 1. Online download: When the host computer has network connection capability, it can directly connect to the Internet and download the flash file from the server or related platform.

[0086] 2. Transfer from other devices: (1) Wired transfer: Transfer the flash file from another computer device via a wired connection such as a USB (Universal Serial Bus) data cable, serial port, Ethernet cable, etc. (2) Wireless transfer: Transfer the flash file from other devices such as laptops, mobile phones, etc. via wireless technologies such as Wi-Fi, Bluetooth, NFC, etc.

[0087] 3. Physical media: Use physical media such as a mobile hard disk or SD card (Secure Digital card) to copy the flash file from one device to the host computer.

[0088] 4. Email or file sharing: Get the flash file via email attachment or network file sharing service.

[0089] 5. Manual input: Users can manually input data as a flash file and load it into the host computer through the interactive window provided by the host computer.

[0090] After the host computer obtains the flash file, it will be stored locally. In some embodiments, the host computer locally stores multiple candidate flash files, each of which is suitable for software flashing of different types of battery management software.

[0091] For example, the host computer locally stores five candidate flash files, which correspond to the battery management software in vehicles with vehicle models 1 to 5 respectively.

[0092] The host computer includes a display screen, and a user operation interface is displayed on the display screen. The user operation interface can receive various user instructions and perform corresponding operations. Among them, the user can select the flashing file to be flashed in the user operation interface. After the selection is completed, the host computer imports the flashing file and verifies whether the flashing file can instruct the battery management software of the first vehicle to perform software flashing.

[0093] Step 320: Send a flashing instruction and a flashing file to the first vehicle.

[0094] The flashing instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the flashing file.

[0095] In some embodiments, after the host computer obtains the flash file, it verifies and encrypts the flash file to obtain a pre-processed file.

[0096] The preprocessed file meets the preset file quality requirement, which means that the flash file is complete and does not contain erroneous data.

[0097] Optionally, a cyclic redundancy check is performed on the flash file to obtain a first check value.

[0098] The flash file is marked with a second check value, and the matching relationship between the first check value and the second check value is used to verify the integrity of the flash file. The second check value is a value marked when the flash file is developed.

[0099] In the case where the first verification value and the second verification value match, the encryption key is obtained based on the flash file.

[0100] Exemplarily, the second check value of the flash file is a check value generated by performing a cyclic redundancy check on the newly developed flash file. When the first check value and the second check value are the same, it means that the first check value and the second check value match, and at this time, the flash file is complete and there is no data error.

[0101] Among them, the methods of obtaining the encryption key include but are not limited to at least one of the following: (1) extracting numbers from the flash file as the encryption key, or extracting numbers from information related to the flash file as the encryption key; (2) using a user-defined random number as the encryption key; (3) the host computer uses an application or algorithm that can provide encryption key generation services to randomly generate an encryption key; (4) any combination of the above three methods to generate an encryption key.

[0102] Optionally, a random number setting operation is received, where the random number setting operation is used to obtain a random number when generating an encryption key, where the random number is a multi-digit number.

[0103] For example, the user types a string of random numbers in the user operation interface as the random number when generating an encryption key; or, after the user operation interface receives a random number setting operation, the host computer randomly generates a string of random numbers according to the random number device operation as the random number when generating an encryption key.

[0104] In some embodiments, the user types in a custom random number, and the host computer performs further operations on the custom random number, and the resulting string of numbers is used as the random number used to generate the encryption key.

[0105] For example, hashing a custom random number, that is, using a hash algorithm to convert the number into a hash value of a fixed length. The hash value is random and irreversible. Using the hash value obtained by hashing as a random number can improve the security of the encryption key and reduce the risk of encryption key leakage.

[0106] A key generation operation is received, where the key generation operation indicates how and when to generate an encryption key.

[0107] The key generation operation is used to instruct the host computer how to generate an encryption key based on a random number, and to indicate the time when the host computer starts to generate the encryption key.

[0108] Exemplarily, based on the key generation operation, the random number is split into multiple digital segments, and the random number is inserted into the first verification value in a preset order to obtain the encryption key.

[0109] For example, the first check value contains a 64-bit number, the random number contains a 32-bit number, the random number is split into 7 digital segments in sequence, and the length of the numbers contained in each digital segment is: 1, 3, 5, 4, 7, 9, 3 respectively.

[0110] The random number is [23456621138749264926291076364920], which is split into the following 7 segments: [2],

[345] ,

[66211] ,

[3874] , [9264926], [291076364], and

[920] .

[0112] Insert the digital segment [2] after the 5th digit of the first check value, insert the digital segment

[345] after the 8th digit of the first check value, insert the digital segment

[66211] after the 10th digit of the first check value, insert the digital segment

[3874] after the 13th digit of the first check value, insert the digital segment [9264926] after the 47th digit of the first check value, insert the digital segment [291076364] after the 36th digit of the first check value, and insert the digital segment

[920] after the 54th digit of the first check value.

[0113] Based on the above insertion method, an encryption key containing 64+32=96 digits is obtained.

[0114] In some embodiments, the number obtained by performing other calculation operations on the number string obtained after inserting the digital field can also be used as an encryption key, for example, key expansion, multiple iterative hash processes, etc. This embodiment is not limited to this.

[0115] The flash file is encrypted based on the encryption key to obtain a pre-processed file.

[0116] The encrypted flash file is not easily lost or damaged during the transmission process, which can improve the security of the transmission process and ensure the correctness and integrity of the flash file.

[0117] A flashing instruction and a preprocessing file are sent to the first vehicle, where the flashing instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the preprocessing file.

[0118] Before sending the flashing instruction and the preprocessing file, the object to be flashed needs to be verified, that is, to determine whether the battery management software of the first vehicle needs to be flashed.

[0119] Optionally, a communication connection is established with the first vehicle, the communication connection comprising at least one of a wired connection and a wireless connection.

[0120] For example, a USB data cable is used to connect the first vehicle and the host computer, and two ends of the USB data cable are respectively connected to the host computer and the first vehicle.

[0121] The purpose of establishing a communication connection between the first vehicle and the host computer is to successfully establish a communication connection between the BMS system and the host computer, so that the host computer can transmit data and instructions to the BMS system and control the battery management software in the BMS system through instructions.

[0122] In some embodiments, the BMS system includes hardware and software parts, and a communication connection between the BMS system and the host computer can be directly established after the BMS system is removed from the first vehicle.

[0123] Device verification information is sent to the first vehicle based on the communication connection, and the device verification information is used to verify whether the battery management software corresponding to the first vehicle needs to be flashed.

[0124] Receive verification feedback information sent by the first vehicle, where the verification feedback information refers to information fed back by the battery management software based on the device verification information, and the verification feedback information is used to describe the status and identity of the battery management software.

[0125] In response to the verification feedback information meeting the preset flash object requirement, it is determined that the battery management software corresponding to the first vehicle needs to be flashed.

[0126] Exemplarily, the device verification information is used to request the BMS system for the current firmware version information, battery status, system health status and other data of the battery management software. The verification feedback information includes the current firmware version information, battery status, system health status and other data of the battery management software in the BMS system.

[0127] The preset flash object requires that the current firmware version information of the battery management software is not the latest version, that is, the flash file required to guide the battery management software to perform software flash is different from the firmware version currently owned by the battery management software. The flash file obtained by the host computer is the latest version of the firmware.

[0128] The preset flash object requirements also include that the probability of performance degradation in the battery status and system health status reaches a preset probability threshold. For example, the preset probability threshold is 50%. The upper computer analyzes the current battery status and system health status of the battery management software indicated in the verification feedback information, and determines that the probability of performance degradation in the battery status and system health status is 60%, which reaches the preset probability threshold.

[0129] When the verification feedback information meets at least one of the preset flash object requirements, it is determined that the battery management software corresponding to the first vehicle needs to be flashed.

[0130] During the process of flashing the battery management software based on the preprocessing file, the host computer will send control instructions in real time to guide the specific steps of the battery management software.

[0131] Optionally, the host computer obtains a flash control script, and the flash control script is used to instruct the host computer to control the battery management software to perform flashing.

[0132] Methods for obtaining control scripts include but are not limited to: (1) the user sends the edited control script to the host computer through other devices, and the host computer imports it to the local computer; (2) the user directly types information into the environment provided by the host computer to generate a control script; (3) the host computer has the function of connecting to the Internet. When connected to the Internet platform, the host computer downloads the preset control script from the Internet platform.

[0133] When the battery management software starts to flash the software, a corresponding control instruction is sent to the first vehicle based on the flash control script, wherein the control instruction is used to instruct the battery management software to perform steps when flashing the software based on the preprocessing file.

[0134] Exemplarily, the flashing script includes the following control instructions: (1) initialization instruction; (2) barcode reading instruction: read the barcode on the vehicle battery and verify its correctness; (3) progress update instruction: receive the progress data fed back by the BMS system / battery management software in real time and update the flashing progress on the user interface; (4) instruction to generate a logistics data file; (5) parameter comparison instruction: read the logistics data file and compare it with the preset logistics data parameters to verify the correctness of the flashing.

[0135] Step 330, monitor the flashing process of the battery management software in real time and determine the flashing monitoring result.

[0136] The flash monitoring result includes the execution progress of the flash process and the existence of flash errors during the flash process.

[0137] During the flashing process of the real-time monitoring battery management software, the flashing log is displayed, and the flashing log is used to record the steps and execution progress corresponding to the flashing process.

[0138] The host computer displays the flash log in the display area of ​​the user operation interface. The flash log contains all records generated from the beginning to the end of the flash process, which is used to show the user the completion progress of the software flash process and whether there are errors in each flash step.

[0139] When at least one of the following information appears in the flash log, it indicates that there may be a flash error in the flash process: 1. Error code: A specific error code appears in the flash log. The error code is used to indicate a specific error type or problem. 2. Timeout information: If a step in the flash process exceeds the predetermined time limit, a timeout information will be recorded in the flash log, indicating that the process was not completed within the expected time. 3. Communication error: The flash log will record communication interruption or instability, which may be caused by hardware connection problems or signal interference. 4. Data verification failure: If the verification process or cyclic redundancy check value of the flash data does not meet expectations, the flash log will record data verification failure information. 5. Hardware failure: The flash log may record hardware failures, such as power problems, sensor failures, etc. 6. Operation failure: The flash log may record the failure of a specific operation step, such as failure to start the flash process, failure to read barcodes, failure to generate logistics data files, etc. 7. User operation interface prompt: When there is a problem in the flash process, the user operation interface will automatically provide error prompt information to the operator, and the error prompt information will be recorded in the flash log. 8. Abnormal system status: The flash log may record abnormalities in the system BMS status, such as battery voltage or temperature outside the normal range. 9. Incomplete log file: If the flash log ends suddenly or is incomplete at a certain point, this may indicate that an error occurred when generating the flash log.

[0140] By analyzing the recorded information in the flash log, you can determine whether an error occurred during the flash process and take appropriate troubleshooting and repair measures.

[0141] The recorded information in the flash log will be stored locally on the host computer for subsequent analysis of the cause of the error, so that users can view it at any time and promptly troubleshoot potential problems with the host computer or BMS system.

[0142] Optionally, when the flash log indicates that the execution progress has not been completed, based on the fact that the recorded information in the flash log meets the preset recording requirements, it is determined that there is a flash error in the flash process.

[0143] Exemplarily, in response to receiving feedback information sent by the battery management software, the feedback information is recorded in a flash log, the feedback information being used to indicate a status of a vehicle battery of the first vehicle during the flashing process of the battery management software, wherein the battery management software is used to manage the vehicle battery of the first vehicle.

[0144] In response to feedback information in the flash log not meeting a preset record requirement, it is determined that a flash error exists in the flash process.

[0145] For example, the preset recording requirements mean that the voltage of the vehicle battery does not exceed the preset voltage threshold, the temperature of the vehicle battery does not exceed the preset temperature threshold, the battery status of the vehicle battery is the same as that displayed on the BMS system and the host computer, and the battery pack of the vehicle battery can be awakened from a sleep state.

[0146] When at least one of the feedback information does not meet the preset recording requirements, it is determined that there is a flashing error in the flashing process.

[0147] For example, the preset voltage threshold is 200V, and the voltage of the vehicle battery is 250V, which exceeds the preset voltage threshold; or, the preset temperature threshold is 50 degrees Celsius, and the temperature of the vehicle battery is 56 degrees Celsius, which exceeds the preset temperature threshold; or, the battery status of the vehicle battery is displayed as 50% remaining on the BMS system and 60% remaining on the host computer, and the battery status displayed on the BMS system and the host computer is different; or, the battery pack of the vehicle battery cannot be awakened from a sleep state during the flashing process.

[0148] Optionally, when the flash log indicates that the execution progress has ended, in response to first flag information included in the flash log, it is determined that there is a flash error in the flash process, wherein the first flag information is used to indicate that the flash process has failed.

[0149] For example, the first flag information is text information: flashing failure, indicating that an error occurs during the flashing process.

[0150] For example, the first flag information is parameter comparison information. The first column / row of the parameter comparison information displays the expected parameter value, and the second column / row displays the actual parameter value. When the expected parameter value is different from the actual parameter value, it indicates that there is an error in the flashing process.

[0151] For example, the first flag information is an error code. The flash log contains the error code and the meaning of the error code, and is displayed in a highlighted form, indicating that an error exists in the flash process.

[0152] In some embodiments, whether there is an error in the flashing process can also be determined by the fact that the flashing log contains the second flag information.

[0153] Optionally, when the flash log indicates that the execution progress is finished, in response to the flash log containing second flag information, it is determined that there is no flash error in the flash process, wherein the second flag information is used to indicate that the flash process is successful.

[0154] For example, the second flag information is text information: flashing is successful, indicating that there is no error in the flashing process.

[0155] For example, the second flag information is parameter comparison information. The first column / row of the parameter comparison information displays the expected parameter value, and the second column / row displays the actual parameter value. When the expected parameter value is exactly the same as the actual parameter value, it indicates that there is no error in the flashing process.

[0156] Step 340, in response to a flashing error during the flashing process, controlling the battery management software to stop flashing.

[0157] When the flashing is stopped, the host computer interrupts the current flashing process and performs error analysis based on the record information displayed in the flashing log to determine the error type.

[0158] Step 350, controlling the battery management software to automatically execute the flash management step based on the flash monitoring result.

[0159] The flash management step includes at least one of a data recovery step and a flash reset step.

[0160] When the host computer executes the data recovery step, the error that occurs is repaired based on the error type, and the flashing process is resumed after the repair is completed.

[0161] When the host computer executes the flash reset step, the data generated by the failed flash process is cleared, and the relevant parameters of the host computer and BMS system are initialized, and the flash process is restarted.

[0162] Optionally, in response to a first flashing error during the flashing process, the first flashing error is recorded in a flashing log and the battery management software is controlled to stop flashing, and the flashing log is used to record the steps and execution progress corresponding to the flashing process.

[0163] Exemplarily, the first flash error refers to the interruption of the communication connection during the flash process, resulting in an error code appearing in the flash log. At this time, the upper computer immediately stops flashing after detecting that an error has occurred during the flash process, and the flash log records the time when the error code appears and the corresponding execution progress.

[0164] A first execution progress corresponding to the first flashing error is obtained from the flashing log.

[0165] The battery management software is controlled to automatically execute the flash management step based on the first execution progress.

[0166] Exemplarily, whether the battery management software executes a data recovery step or a flash reset step is determined based on a size relationship between the first execution progress and a preset progress threshold.

[0167] In response to the first execution progress being less than a preset progress threshold, the battery management software is controlled to automatically execute a flashing and resetting step.

[0168] For example, the progress threshold is 50%, and the first execution progress is 30%, which is less than the preset progress threshold, and the battery management software is controlled to execute the flashing and resetting step.

[0169] In response to the first execution progress being greater than or equal to a preset progress threshold, the battery management software is controlled to automatically execute a data recovery step.

[0170] For example, the progress threshold is 50%, and the first execution progress is 55%, which is greater than the preset progress threshold, and the battery management software is controlled to execute the data recovery step.

[0171] In some embodiments, steps corresponding to different error types may be set in advance, and the battery management software may be determined to perform a data recovery step or a flash reset step according to the error type that occurs during the flashing process.

[0172] Optionally, a management step comparison table is obtained, wherein the management step comparison table includes a correspondence between the error type and the type of the flash management step.

[0173] The type of the flash management step is determined from the management step comparison table based on the error type indicated by the flash monitoring result.

[0174] Control the battery management software to automatically execute the flash management step.

[0175] For example, when the management step comparison table indicates that the error type is one of the following types, the flash reset step is performed: (1) the flash file version is wrong; (2) the flash file is damaged; (3) the vehicle battery status indicates that the power is lower than the preset power threshold.

[0176] When the management step comparison table indicates the error type is one of the following, perform data recovery operations:

[0177] (1) The communication connection between the battery management software and the host computer is disconnected; (2) The vehicle battery temperature exceeds the preset temperature threshold; (3) The host computer fails to read the instructions in the flash script.

[0178] The flash monitoring result indicates that the error type is a flash file corruption, and based on the management step comparison table, the flash management step is determined to be a flash reset step.

[0179] Exemplarily, when the host computer controls the battery management software to automatically execute the flash reset step, after initializing the host computer and the BMS system, the error type generated by the last flash process is retained, and other data generated by the last flash process is cleared.

[0180] The host computer obtains a backup file, which is a file that copies the flash file, and sends the backup file to the battery management software, and re-controls the battery management software to flash the software based on the backup file.

[0181] In summary, the software flashing of the host computer controlling the BMS system is a process involving software updates, configuration adjustments or firmware upgrades. The host computer waits for initialization to complete and verifies whether all necessary tools and resources are ready. Establish a connection with the corresponding hardware, check the current software version of the host computer, and confirm whether flashing is required. Check whether the hardware and software environment of the host computer meets the flashing requirements. Transfer the flashing file (firmware package) to the host computer, and the host computer runs the flashing script to install or replace the flashing file in the battery management software. The host computer monitors the flashing progress, the output and status of the key steps in real time and records them in the flashing log. During the flashing process, if the host computer captures any exceptions or errors, immediately analyze the cause of the error, record the error information and related information to the flashing log, and facilitate subsequent analysis and problem tracking. Test the basic functions and performance of the host computer to ensure that the system operates normally after flashing. The flashing process ends. If the flashing is successful and passes the verification, the process ends; if the flashing fails or fails the verification, choose to re-flash, restore the data or perform other processing according to the error situation.

[0182] In summary, the design of the host computer architecture for software flashing of the BMS system provided by this application comprehensively considers multiple aspects such as communication interface, functional module, data processing flow and security measures. By reasonably dividing the functional modules, designing efficient communication interfaces, formulating detailed data processing flow and adopting effective error handling mechanisms, a stable, reliable and user-friendly BMS flashing host computer platform is constructed. The flashing method of the battery management software provided in this application verifies the flashing file to ensure the file quality of the flashing file, encrypts the data of the flashing file, avoids the data of the flashing file being tampered with during the flashing process of the battery management software based on the flashing file, and reduces the error rate during the flashing process. Monitor the progress of the flashing process in real time, detect and handle the errors that may occur in the process, interrupt the error flashing process in time and automatically repair and reset the steps, avoid the battery management software flashing the wrong data into the software to affect the safety of the vehicle battery, and improve the flashing efficiency and the success rate of the flashing process.

[0183] Figure 4 is a structural block diagram of a flashing device for battery management software provided by an exemplary embodiment of the present application, such as Figure 4 As shown, the device includes the following parts.

[0184] An acquisition module 410 is used to acquire a flash file, wherein the flash file refers to a file used by the host computer to control the battery management software corresponding to the first vehicle to perform software flashing, wherein software flashing refers to a process of updating the battery management software and fixing errors;

[0185] A sending module 420, configured to send a flashing instruction and the flashing file to the first vehicle, wherein the flashing instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the flashing file;

[0186] The monitoring module 430 is used to monitor the flashing process of the battery management software in real time and determine the flashing monitoring result, wherein the flashing monitoring result includes the execution progress of the flashing process and the existence of flashing errors in the flashing process;

[0187] A control module 440, configured to control the battery management software to stop flashing in response to a flashing error in the flashing process;

[0188] The control module 440 is further used to control the battery management software to automatically execute a flash management step based on the flash monitoring result, and the flash management step includes at least one of a data recovery step and a flash reset step.

[0189] In an optional embodiment, the control module 440 is also used to respond to a first flash error during the flash process, record the first flash error in a flash log and control the battery management software to stop flashing, the flash log being used to record the steps and the execution progress corresponding to the flash process; obtain the first execution progress corresponding to the first flash error from the flash log; and control the battery management software to automatically execute the flash management steps based on the first execution progress.

[0190] In an optional embodiment, the control module 440 is also used to control the battery management software to automatically execute the flash reset step in response to the first execution progress being less than a preset progress threshold; or, in response to the first execution progress being greater than or equal to the preset progress threshold, control the battery management software to automatically execute the data recovery step.

[0191] In an optional embodiment, the flashing monitoring result includes the error type of the flashing error;

[0192] The control module 440 is also used to obtain a management step comparison table, which contains the correspondence between the error type and the type of the flash management step; determine the type of the flash management step from the management step comparison table based on the error type indicated by the flash monitoring result; and control the battery management software to automatically execute the flash management step.

[0193] In an optional embodiment, the sending module 420 is also used to perform a cyclic redundancy check on the flash file to obtain a first check value, wherein the flash file is marked with a second check value, and the matching relationship between the first check value and the second check value is used to verify the integrity of the flash file; when the first check value and the second check value match, obtain an encryption key based on the flash file; encrypt the flash file based on the encryption key to obtain a preprocessed file, and the preprocessed file meets the preset file quality requirements; send the flash instruction and the preprocessed file to the first vehicle, and the flash instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the preprocessed file.

[0194] In an optional embodiment, the sending module 420 is also used to receive a random number setting operation, the random number setting operation is used to obtain a random number when generating the encryption key, and the random number is a multi-digit number; receive a key generation operation, the key generation operation is used to indicate the method and time of generating the encryption key; based on the key generation operation, the random number is split into multiple digital segments, and the random number is inserted into the first check value in a preset order to obtain the encryption key.

[0195] In an optional embodiment, the monitoring module 430 is also used to display a flash log during real-time monitoring of the flashing process of the battery management software, and the flash log is used to record the steps corresponding to the flashing process and the execution progress; when the flash log indicates that the execution progress has not been completed, based on the fact that the recorded information in the flash log meets the preset recording requirements, it is determined that there is a flashing error in the flashing process.

[0196] In an optional embodiment, the monitoring module 430 is also used to record the feedback information in the flash log in response to receiving feedback information sent by the battery management software, and the feedback information is used to indicate the status of the vehicle battery of the first vehicle during the flashing process of the battery management software, wherein the battery management software is used to manage the vehicle battery of the first vehicle; in response to the feedback information in the flash log not meeting the preset recording requirements, it is determined that a flashing error exists in the flashing process.

[0197] In an optional embodiment, the monitoring module 430 is also used to determine that there is a flashing error in the flashing process in response to the first flag information contained in the flashing log when the flashing log indicates that the execution progress has ended, wherein the first flag information is used to indicate that the flashing process has failed.

[0198] In summary, the flashing device for battery management software provided by the present application can control the battery management software to execute the software flashing process through the flashing file, and monitor the process in real time, and can detect and process the errors that may occur in the process, and interrupt the error flashing process in time. And automatically repair or reset the error after the error is found, so as to avoid the battery management software flashing the wrong data into the software and affecting the safety of the vehicle battery, and improve the success rate of the flashing process. Compared with the related art, the user needs to analyze the errors reported by the host computer and manually start the steps of data recovery or flashing reset, which can improve the flashing efficiency.

[0199] It should be noted that the flashing device for battery management software provided in the above embodiment is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the flashing device for battery management software provided in the above embodiment and the flashing method embodiment of battery management software belong to the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.

[0200] Figure 5 The block diagram of the structure of a computer device 500 provided by an exemplary embodiment of the present application is shown. The computer device 500 may be: a smart phone, a tablet computer, an MP3 player (Moving Picture Experts Group Audio Layer III, Moving Picture Experts Group Audio Layer 3), an MP4 (Moving Picture Experts Group Audio Layer IV, Moving Picture Experts Group Audio Layer 4) player, a laptop computer or a desktop computer. The computer device 500 may also be called a user device, a portable terminal, a laptop terminal, a desktop terminal or other names.

[0201] Typically, the computer device 500 includes a processor 501 and a memory 502 .

[0202] The processor 501 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 501 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor 501 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 501 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 501 may also include an AI (Artificial Intelligence) processor, which is used to process computing operations related to machine learning.

[0203] The memory 502 may include one or more computer-readable storage media, which may be non-transitory. The memory 502 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 502 is used to store at least one instruction, which is used to be executed by the processor 501 to implement the flashing method of the battery management software provided in the method embodiment of the present application.

[0204] In some embodiments, the computer device 500 further includes some other components 503, and the type and quantity of the other components 503 can be selected based on the functional requirements of the computer device 500. Those skilled in the art will appreciate that Figure 5 The structure shown in the figure does not constitute a limitation on the computer device 500, and the computer device 500 may include more or less components than those shown in the figure, or combine some components, or adopt a different arrangement of components.

[0205] Optionally, the computer readable storage medium may include: a read-only memory (ROM), a random access memory (RAM), a solid state drive (SSD), or an optical disk. Among them, the random access memory may include a resistance random access memory (ReRAM) and a dynamic random access memory (DRAM). The serial numbers of the above embodiments of the present application are only for description and do not represent the advantages and disadvantages of the embodiments.

[0206] An embodiment of the present application also provides a computer device, which includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement a method for flashing battery management software as described in any of the above embodiments of the present application.

[0207] An embodiment of the present application also provides a computer-readable storage medium, in which at least one instruction, at least one program, a code set or an instruction set is stored. The at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement a method for flashing battery management software as described in any of the above embodiments of the present application.

[0208] The embodiment of the present application also provides a computer program product or a computer program, which includes a computer instruction stored in a computer-readable storage medium. The processor of the computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the flashing method of the battery management software described in any of the above embodiments.

[0209] A person skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware or by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a disk or an optical disk, etc.

[0210] The above description is only an optional embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A method for flashing battery management software, characterized in that: The method is executed by a host computer, and the method includes: Obtaining a flash file, wherein the flash file refers to a file used by the host computer to control the battery management software corresponding to the first vehicle to perform software flashing, wherein software flashing refers to a process of updating the battery management software and fixing errors; Sending a flashing instruction and the flashing file to the first vehicle, wherein the flashing instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the flashing file; Monitor the flashing process of the battery management software in real time and determine the flashing monitoring result, wherein the flashing monitoring result includes the execution progress of the flashing process and the existence of flashing errors in the flashing process; In response to a flashing error occurring during the flashing process, controlling the battery management software to stop flashing; Based on the flash monitoring result, the battery management software is controlled to automatically execute a flash management step, and the flash management step includes at least one of a data recovery step and a flash reset step.

2. The method according to claim 1, characterized in that In response to a flashing error in the flashing process, controlling the battery management software to stop flashing includes: In response to a first flashing error in the flashing process, recording the first flashing error in a flashing log and controlling the battery management software to stop flashing, wherein the flashing log is used to record the steps corresponding to the flashing process and the execution progress; The step of controlling the battery management software to automatically execute the flash management step based on the flash monitoring result includes: Acquire a first execution progress corresponding to the first flashing error from the flashing log; The battery management software is controlled to automatically execute the flash management step based on the first execution progress.

3. The method according to claim 2, characterized in that The step of controlling the battery management software to automatically execute the flash management step based on the first execution progress includes: In response to the first execution progress being less than a preset progress threshold, controlling the battery management software to automatically execute the flashing and resetting step; or, In response to the first execution progress being greater than or equal to the preset progress threshold, controlling the battery management software to automatically execute the data recovery step.

4. The method according to any one of claims 1 to 3, characterized in that: The flashing monitoring result includes the error type of the flashing error; The step of controlling the battery management software to automatically execute the flash management step based on the flash monitoring result includes: Obtaining a management step comparison table, wherein the management step comparison table includes a correspondence between the error type and the type of the flash management step; Determining the type of the flash management step from the management step comparison table based on the error type indicated by the flash monitoring result; Control the battery management software to automatically execute the flash management step.

5. The method according to any one of claims 1 to 3, characterized in that: The sending the flashing instruction and the flashing file to the first vehicle includes: Performing a cyclic redundancy check on the flash file to obtain a first check value, wherein the flash file is marked with a second check value, and a matching relationship between the first check value and the second check value is used to verify the integrity of the flash file; When the first check value and the second check value match, obtaining an encryption key based on the flash file; Encrypting the flash file based on the encryption key to obtain a pre-processed file, wherein the pre-processed file meets the preset file quality requirements; The flashing instruction and the preprocessing file are sent to the first vehicle, where the flashing instruction is used to instruct the battery management software corresponding to the first vehicle to perform software flashing based on the preprocessing file.

6. The method according to claim 5, characterized in that The obtaining of the encryption key based on the flash file comprises: receiving a random number setting operation, wherein the random number setting operation is used to obtain a random number when generating the encryption key, wherein the random number is a multi-digit number; Receiving a key generation operation, the key generation operation being used to indicate a method and a time for generating the encryption key; Based on the key generation operation, the random number is split into multiple digital segments, and the random number is inserted into the first verification value in a preset order to obtain the encryption key.

7. The method according to any one of claims 1 to 3, characterized in that: The real-time monitoring of the flashing process of the battery management software and determining the flashing monitoring result includes: During the real-time monitoring of the flashing process of the battery management software, a flashing log is displayed, wherein the flashing log is used to record the steps corresponding to the flashing process and the execution progress; When the flash log indicates that the execution progress has not been completed, based on the fact that the recorded information in the flash log meets the preset recording requirements, it is determined that there is a flash error in the flash process.

8. The method according to claim 7, characterized in that The determining that there is a flashing error in the flashing process based on the fact that the recorded information in the flashing log meets the preset recording requirements includes: In response to receiving feedback information sent by the battery management software, recording the feedback information in the flash log, the feedback information being used to indicate a state of a vehicle battery of the first vehicle during the flashing process of the battery management software, wherein the battery management software is used to manage the vehicle battery of the first vehicle; In response to the feedback information in the flash log not meeting the preset record requirement, it is determined that a flash error exists in the flash process.

9. The method according to claim 7, characterized in that: The method further comprises: In the case where the flash log indicates that the execution progress is finished, in response to first flag information included in the flash log, it is determined that there is a flash error in the flash process, wherein the first flag information is used to indicate that the flash process has failed.

10. A flashing device for battery management software, characterized in that: The device comprises: An acquisition module, used for acquiring a flash file, wherein the flash file refers to a file used by the host computer to control the battery management software corresponding to the first vehicle to perform software flashing, wherein software flashing refers to a process of updating the battery management software and fixing errors; A sending module, used for sending a flashing instruction and the flashing file to the first vehicle, wherein the flashing instruction is used for instructing the battery management software corresponding to the first vehicle to perform software flashing based on the flashing file; A monitoring module, used for monitoring the flashing process of the battery management software in real time and determining a flashing monitoring result, wherein the flashing monitoring result includes the execution progress of the flashing process and the existence of a flashing error in the flashing process; A control module, configured to control the battery management software to stop flashing in response to a flashing error in the flashing process; The control module is further used to control the battery management software to automatically execute a flash management step based on the flash monitoring result, and the flash management step includes at least one of a data recovery step and a flash reset step.

Citation Information

Patent Citations

  • Vehicle-mounted controller parallel upgrading method and system and storage medium

    CN116991437A

  • Vehicle upgrading method and device, electronic equipment and storage medium

    CN117793080A

  • ECU program-flashing method and apparatus

    WO2023045440A1

Cited By

  • Control method and control device of battery management system and storage medium

    CN121486414A