BootLoader program online upgrade method, control unit and new energy vehicle

By borrowing the storage address area in the application layer program area to download and verify the BootLoader program, the problems of inconvenient, long cycle and low reliability of BootLoader program upgrade in the existing technology are solved, achieving higher reliability and simple upgrade. process.

CN116302021BActive Publication Date: 2024-08-27HANGZHOU EV TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310225053.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-06
Publication Date
2024-08-27
Estimated Expiration
2043-03-06

AI Technical Summary

Technical Problem

The existing BootLoader program upgrade method is inconvenient, has a long cycle and low reliability, and can easily cause the electronic control unit to become "bricked".

Method used

Borrow the third storage address area in the application layer program area of ​​​​the flash area to download, temporarily store and verify the target BootLoader program. Ensure that the verification is successful before copying it to the BootLoader program area to avoid power outage or communication failure during the erasure process. resulting damage.

Benefits of technology

It improves the reliability of BootLoader program updates, avoids the risk of the electronic control unit becoming "bricked", simplifies the upgrade process, and reduces operation time and complexity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116302021B
    Figure CN116302021B
Patent Text Reader

Abstract

A BootLoader program online upgrade method, a control unit and a new energy vehicle are proposed, which relate to the field of control unit program upgrade. The method includes S20: downloading the target BootLoader program to the third storage address area of ​​the flash area; S40: verifying the target BootLoader program in the third storage address area, if the verification is successful, then entering step S60, if the verification fails, then entering step S20; S60: erasing the BootLoader program in the first storage address area of ​​the flash area; S80: copying the target BootLoader program in the third storage address area to the first storage address area. By using the third storage address area Address3 in the application layer program area as the area for downloading, temporarily storing and verifying the target BootLoader program, the reliability of the BootLoader program update is greatly improved, and it is convenient and has a short cycle.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of control unit program upgrade, and in particular to a BootLoader program online upgrade method. Background Art

[0002] With the development of technology and market demand, electronic control products have more and more functions and are becoming more and more complex. Therefore, the software updates of electronic control units are becoming more and more frequent. In order to avoid large-scale recalls and provide regular maintenance, the ability to perform safe and reliable program updates is becoming increasingly important.

[0003] With the development of automotive electronic technology, especially new energy vehicles, so do vehicle electronic control units.

[0004] The BootLoader program is the first code to run after the system is powered on or reset. It can guide the electronic control unit to run the application and update the application, so its reliability and stability become particularly important. However, it is difficult to ensure that the design of the BootLoader program is stable and reliable, especially in the development stage, which requires frequent updates to ensure that the products delivered to customers are stable and reliable.

[0005] For new energy vehicles, the following two methods are generally used to update the BootLoader program:

[0006] Method 1: Open the shell of the electronic control unit, and then use the burner to download the BootLoader target program to implement the update. Generally, the OEM will allow this operation during bench testing. If it is on a complete vehicle, the common practice in the industry is to remove the electronic control unit, re-update the bootloader program firmware, complete the test, and then return it to the OEM. This method is inconvenient and has a long cycle, so the BootLoader program is not updated unless there are special circumstances, which affects the customer experience.

[0007] Method 2: Update the BootLoader program online. First, erase the BootLoader program in the BootLoader program area, then download the BootLoader target program to the BootLoader program area to complete the update. This method does not require disassembling the shell, is very convenient to operate, and takes a short update time. However, it is required that no abnormalities occur when downloading the BootLoader target program. If power failure or communication failure occurs, the program in the BootLoader area will be damaged, causing the electronic control unit to become a "brick", making the reliability of the BootLoader program update low.

[0008] Therefore, the industry is in urgent need of a BootLoader program upgrade method that is convenient, has a short cycle, and has high reliability. Summary of the invention

[0009] The above-mentioned problems of inconvenient upgrade of BootLoader program, long cycle and low reliability are addressed.

[0010] The present application proposes a BootLoader program online upgrade method, comprising: S20: downloading the target BootLoader program to a third storage address area of ​​a flash area, wherein the third storage address area is located in an application layer program area of ​​the flash area; S40: verifying the target BootLoader program in the third storage address area, if the verification succeeds, proceeding to step S60, if the verification fails, proceeding to step S20; S60: erasing the BootLoader program in the first storage address area of ​​the flash area, wherein the first storage address area is the BootLoader program area of ​​the flash area; S80: copying the target BootLoader program in the third storage address area to the first storage address area.

[0011] Optionally, before step S20, it also includes: S11: erasing the application program in the second storage address area of ​​the flash area, where the second storage address area is located in the application layer program area of ​​the flash area; S12: downloading the application layer BootLoader program into the second storage address area; S13: verifying the application layer BootLoader program in the second storage address area, if the verification is successful, entering step S14, if the verification fails, entering step S12; S14: jumping to the second storage address area and executing the application layer BootLoader program.

[0012] Optionally, executing the application layer BootLoader program in step S14 includes: S141: erasing the application layer program in the third storage address area under the application layer BootLoader program; S142: executing the steps S20, S40, S60 and S80 under the application layer BootLoader program.

[0013] Optionally, the verification in step S40 includes signature verification and compatibility verification.

[0014] Optionally, the verification in step S13 includes signature verification and compatibility verification.

[0015] Optionally, before step S11, the method further includes: SS1: entering a programming session, performing a reset, jumping from the application to the BootLoader program, determining whether there is an update flag, if so, entering step SS2, performing an upgrade program, if not, running the application under the current BootLoader program;

[0016] SS2: Execute security access so that the tool with access rights can perform the upgrade; SS3: Download the Flash write driver file; SS4: Verify the downloaded Flash write driver file, if the verification is successful, proceed to step S11, if the verification fails, proceed to step SS3.

[0017] Optionally, a pre-programming sequence is also included before step SS1, and the pre-programming sequence includes: S111: reading the version information of the electronic control unit to determine whether the BootLoader program needs to be updated, if so, entering step S112, if not, entering step S111; S112: entering the extended session, prohibiting the setting and storage of fault DTCs; S113: performing an upgrade condition check to determine whether the system status can perform a program update, if so, entering step SS1, if not, executing the current BootLoader program.

[0018] Optionally, after step S80, the method further includes: S91: verifying the BootLoader program in the first storage address area, if the verification succeeds, entering the post-programming sequence, if the verification fails, entering step S80.

[0019] Optionally, the post-programming sequence includes: S92: performing a compatibility check of the BootLoader program to check whether the BootLoader program in the first storage address area is compatible with the hardware version. If so, setting the program valid flag and entering step S93; if not, entering step S20; S93: performing a reset, the program enters the BootLoader program and determines whether the application is valid. If valid, enter the application; otherwise, remain in the BootLoader program.

[0020] Optionally, the check in step S91 is an integrity check.

[0021] Optionally, step S92 further includes erasing a valid flag of the application layer BootLoader program.

[0022] Optionally, the BootLoader program online upgrade method is executed in an electronic control unit of a new energy vehicle.

[0023] Optionally, the BootLoader program online upgrade method is executed based on the UDS protocol of the new energy vehicle.

[0024] The present application also proposes an electronic control unit that executes the above-mentioned BootLoader program online upgrade method.

[0025] The present application also proposes a new energy vehicle, comprising the above-mentioned electronic control unit.

[0026] The present application can achieve at least one of the following beneficial effects:

[0027] By using an address area in the application layer program area as the area for downloading, temporarily storing and verifying the target BootLoader program, the reliability of the BootLoader program update is greatly improved, and the risk of the electronic control unit becoming a "brick" is reduced. Online upgrades can avoid dismantling the electronic control unit and reduce the time it takes to pass between electronic product-related production units, so it is convenient and has a short cycle.

[0028] The above is a fairly broad overview of the features and technical advantages of the present application, so that the following detailed description of the present application can be better understood. The additional features and advantages of the present application will be described below, and they form the subject matter of the claims of the present application. It will be appreciated by those skilled in the art that the disclosed concepts and specific embodiments can be easily utilized as the basis for modifying or designing other structures or processes for realizing the same purpose of the present application. It will also be appreciated by those skilled in the art that such equivalent constructions do not depart from the spirit and scope of the present application as set forth in the appended claims. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] In order to more fully understand the present application and its advantages, reference is now made to the following description in conjunction with the accompanying drawings, in which:

[0030] Figure 1 A schematic diagram of the flash area in a conventional electronic control unit is shown;

[0031] Figure 2 A schematic diagram of a flash area in an electronic control unit according to an embodiment of the present application is shown;

[0032] Figure 3 A flowchart of a BootLoader program online upgrade method according to an embodiment of the present application is shown;

[0033] Figure 4 A flowchart of a BootLoader program online upgrade method according to another embodiment of the present application is shown;

[0034] Figure 5 A schematic diagram of a flash area in an electronic control unit according to another embodiment of the present application is shown;

[0035] Figure 6A schematic diagram of the main programming sequence flow of an embodiment of the present application is shown;

[0036] Figure 7 A schematic diagram of a BootLoader program online upgrade method according to an embodiment of the present application is shown.

[0037] Corresponding numerals and symbols in the different figures generally refer to corresponding parts unless otherwise indicated.The figures are drawn to clearly illustrate the relevant aspects of the various embodiments and are not necessarily drawn to scale. DETAILED DESCRIPTION

[0038] The following will be combined with the accompanying drawings to clearly and completely describe the technical solutions in this application. Obviously, the described embodiments are part of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0039] An embodiment of the present application provides a BootLoader program online upgrade method. The online upgrade can avoid dismantling the electronic control unit and reduce the time of transferring the electronic control unit between electronic product-related production units. Therefore, it is convenient and has a short cycle.

[0040] Figure 1 FIG. 1 shows a schematic diagram of the flash area in a conventional electronic control unit. Figure 1 As shown, the flash area in the electronic control unit generally includes a BootLoader program area 110 and an application layer program area 120. The BootLoader program area 110 is generally used to store the BootLoader program, which is generally located in the first storage address area Address1 of the flash area. The application layer program area 120 is generally used to store the application program of the electronic control unit, which is generally located in the second storage address area Address2 to the nth storage address area Addressn of the flash area.

[0041] After power-on reset, the BootLoader program is executed from the entry address first storage address area Address1. Under the BootLoader program, it is determined whether the application layer program is valid. If valid, it jumps to the second storage address area Address2 to run the application program. If invalid, it stays in the first storage address area Address1.

[0042] See also Figure 2 FIG. 1 is a schematic diagram of a flash area in an electronic control unit according to an embodiment of the present application. Figure 2 As shown, Figure 1Differently, one of the storage address areas in the application layer program area 120 is used as a target BootLoader program download backup area, such as Figure 2 Using the third storage address area Address3 as the target BootLoader program download backup area is only one embodiment, and other storage address areas of the application layer program area 120 may also be selected as the target BootLoader program download backup area.

[0043] See also Figure 3 The flowchart of the online upgrade method of the BootLoader program of an embodiment of the present application is shown in FIG. Figure 2 ,like Figure 3 As shown, the BootLoader program online upgrade method of an embodiment of the present application includes:

[0044] S20: downloading the target BootLoader program into a third storage address area Address3 of the flash area, wherein the third storage address area Address3 is located in the application layer program area 120 of the flash area;

[0045] S40: verifying the target BootLoader program in the third storage address area Address3, if the verification succeeds, proceeding to step S60, if the verification fails, proceeding to step S20;

[0046] S60: Erasing the BootLoader program in the first storage address area Address1 of the flash area, where the first storage address area Address1 is the BootLoader program area 110 of the flash area;

[0047] S80: Copy the target BootLoader program in the third storage address area Address3 to the first storage address area Address1.

[0048] The upgrade of the BootLoader program includes two steps: erasing the BootLoader program and downloading the target BootLoader program to the BootLoader program area. Erasing the BootLoader program is very fast, usually in milliseconds, such as tens or hundreds of milliseconds; downloading the target BootLoader program is relatively slow, usually in seconds, such as tens of seconds. Usually, downloading the target BootLoader program accounts for more than 90% of the entire BootLoader program upgrade process.

[0049] In the prior art, the BootLoader program is first erased so that the BootLoader program in the electronic control unit no longer exists, and then the target BootLoader program is downloaded. It can be seen that if a power outage or communication failure occurs when downloading the BootLoader target program, the electronic control unit will become a "brick", and downloading the target BootLoader program accounts for more than 90% of the entire BootLoader program upgrade process.

[0050] As described above, the present application uses the third storage address area Address3 in the application layer program area 120 as an area for downloading, temporarily storing and verifying the target BootLoader program. Before erasing the BootLoader program, the target BootLoader program is first downloaded to the third storage address area Address3, and the verification is completed. Then, the target BootLoader program is copied to the BootLoader program area within the chip to complete the update.

[0051] Usually, downloading the BootLoader program and checking it take seconds, such as tens of seconds, and erasing the BootLoader program and copying it on chip usually take milliseconds, such as tens or hundreds of milliseconds. In this way, the downloading of the BootLoader program and the checking steps, which account for more than 90% of the upgrade process, are placed before erasing the BootLoader program. Even if power outages or communication failures occur during this process, the electronic control unit can be guaranteed not to become a "brick" because the BootLoader program in the BootLoader program area has not been erased. This greatly improves the reliability of the BootLoader program update.

[0052] That is, the online upgrade method of the BootLoader program provided in the present application does not require the electronic control unit to be removed for flashing, and does not require the installation of any additional equipment. Moreover, when power failure or communication failure occurs during the download and verification of the BootLoader program, the electronic control unit will not become a "brick", which solves the problems of inconvenient operation and long cycle, and greatly improves the safety and reliability of flashing.

[0053] See also Figure 4 The flowchart of the BootLoader program online upgrade method of another embodiment of the present application is shown in FIG. Figure 5 FIG. 1 is a schematic diagram of a flash area in an electronic control unit according to another embodiment of the present application. Figure 5 As shown, Figure 2 Differently, one of the storage address areas in the application layer program area 120 is used as the application layer BootLoader program area, such as Figure 5The second storage address area Address2 in.

[0054] Specifically, before step S20, the method further includes:

[0055] S11: erasing an application program in a second storage address area Address2 of the flash area, wherein the second storage address area Address2 is located in an application layer program area 120 of the flash area;

[0056] S12: Download the application layer BootLoader program to the second storage address area Address2;

[0057] S13: verifying the application layer BootLoader program in the second storage address area Address2, if the verification succeeds, proceeding to step S14, if the verification fails, proceeding to step S12;

[0058] S14: Jump to the second storage address area Address2 and execute the application layer BootLoader program.

[0059] The application layer BootLoader program of this embodiment is similar to the BootLoader program, and is a boot loader program for guiding the download and verification of the target BootLoader program through the third storage address area Address3, and copying the target BootLoader program into the BootLoader program area on the chip.

[0060] In one embodiment, the verification in step S13 includes signature verification and compatibility verification. In addition to performing FLASH integrity verification, the signature verification can also verify the identity of the upgrade file to ensure the authenticity of the upgrade file.

[0061] In one embodiment, the verification in step S40 also includes signature verification and compatibility verification, so as to ensure the authenticity of the upgrade file.

[0062] Specifically, the execution of the application layer BootLoader program in step S14 includes:

[0063] S141: erasing the application layer program in the third storage address area Address3 under the application layer BootLoader program;

[0064] S142: Execute the step S20, the step S40, the step S60 and the step S80 under the application layer BootLoader program.

[0065] It can be seen that the application layer BootLoader program can guide the following functions: erase the third storage address area Address3 and the first storage address area Address1, download the target BootLoader program to the third storage address area Address3, and copy the target BootLoader program in the third storage address area Address3 to the first storage address area Address1. That is, the application layer BootLoader program completes Figure 3 The BootLoader program online upgrade method shown in the figure.

[0066] That is, the present application simultaneously borrows the second storage address area Address2 and the third storage address area Address3 in the flash area application layer program area 120. Usually, the second storage address area Address2 and the third storage address area Address3 in the application layer program area 120 are used to store the application layer program. The present application borrows these two addresses when upgrading the BootLoader program. After the BootLoader program is upgraded, it is upgraded to the latest application layer program by upgrading the application layer program. Therefore, the online upgrade method of the BootLoader program does not affect the normal use of the application layer program area 120 and does not occupy the resources of the flash area.

[0067] like Figure 5 As shown, the first storage address area Address1, the second storage address area Address2 and the third storage address area Address3 are physically adjacent in the flash area, but the present application does not limit this, that is, their physical structures may not be adjacent.

[0068] In one embodiment, see Figure 6 The main programming sequence flow chart of an embodiment of the present application is shown in FIG. Figure 4 The step S11 shown also includes:

[0069] SS1: Enter the programming session, reset, jump from the application to the BootLoader program, determine whether there is an update flag, if yes, enter step SS2, perform the upgrade program, if no, run the application under the current BootLoader program;

[0070] SS2: Perform security access so that tools with access permissions can perform upgrades;

[0071] SS3: Download Flash write driver file;

[0072] SS4: Verify the downloaded Flash write driver file. If the verification succeeds, go to step S11; if the verification fails, go to step SS3.

[0073] Specifically, through step SS2: executing secure access, only tools with access rights can be executed, which can improve the security of program updates.

[0074] Specifically, the BootLoade program and the application BootLoader program do not contain the flash write driver file, and the flash erase and write operations cannot be performed. Through step SS3: downloading the Flash write driver file, it can be ensured that the flash area data will not be actively rewritten under non-upgrade conditions, thereby avoiding erroneous upgrades.

[0075] Specifically, the verification in step SS4 is a signature verification, which is the same as the above-mentioned signature verification and can ensure the integrity and authenticity of the upgrade file.

[0076] Furthermore, after step SS4, the steps of writing the update date, updating the tool number, etc. may be included to facilitate subsequent tracing.

[0077] in this way, Figure 6 The main programming sequence shown constitutes the core steps of the BootLoader program online upgrade method of the present application.

[0078] Furthermore, in one embodiment, a pre-programming sequence is further included before step SS1, and the pre-programming sequence includes:

[0079] S111: Read the version information of the electronic control unit to determine whether the BootLoader program needs to be updated. If so, proceed to step S112; if not, proceed to step S111;

[0080] S112: Entering the extended session, prohibiting the setting and storage of fault DTCs;

[0081] S113: Perform upgrade condition check to determine whether the system status can perform program update. If so, go to step SS1; if not, execute the current BootLoader program.

[0082] Specifically, step S112: enter the extended session, prohibit the setting and storage of fault DTCs, require all electronic control units not to set and store fault DTCs during this period, and prohibit communication except with the online upgrade protocol of the BootLoader program, so as to maximize the upgrade speed and reduce the update time.

[0083] In one embodiment, after the target BootLoader program in the third storage address area Address3 is copied to the first storage address area Address1, that is, after step S80, the following steps are further included:

[0084] S91: Verify the BootLoader program in the first storage address area Address1. If the verification succeeds, enter the post-programming sequence. If the verification fails, enter step S80.

[0085] In one embodiment, the check in step S91 is an integrity check. Since copying the target BootLoader program in the third storage address area Address3 to the first storage address area Address1 is only an on-chip operation in the flash area, only an integrity check is required, which improves the speed of the check.

[0086] As mentioned above, if the verification fails, the process proceeds to step S80 to copy the target BootLoader program in the third storage address area Address3 to the first storage address area Address1 again until the verification passes. If the verification succeeds, the process proceeds to the post-programming sequence and subsequent operations.

[0087] In one embodiment, the post-programming sequence includes:

[0088] S92: Execute a compatibility check of the BootLoader program to check whether the BootLoader program in the first storage address area Address1 is compatible with the hardware version (such as the version of the electronic control unit). If so, set the program valid flag and go to step S93; if not, go to step S20;

[0089] S93: Execute reset, the program enters the BootLoader program to determine whether the application is valid, if it is valid, enter the application, otherwise remain in the BootLoader program.

[0090] Specifically, in step S92, a compatibility check of the BootLoader program is performed. If yes, it means that the online upgrade of the BootLoader program is completed, and the program valid flag is set; if no, it means that the online upgrade of the BootLoader program fails, and it is necessary to enter step S20 for re-upgrade.

[0091] In one embodiment, after completing the online upgrade of the BootLoader program, that is, after step S91, it also includes erasing the application layer BootLoader program valid flag, which can usually be included in step S92, and releasing the function of the application layer BootLoader program area and restoring its function to the application layer program area.

[0092] See also Figure 7 The schematic diagram of the online upgrade method of the BootLoader program of an embodiment of the present application is shown, which includes the above-mentioned pre-programming sequence, main programming sequence and post-programming sequence.

[0093] In one embodiment, the electronic control unit may be an electronic control unit in any electronic product, and as long as it requires a BootLoader program, the solution provided in the present application may be adopted.

[0094] In a preferred embodiment, the electronic control unit is an electronic control unit of a new energy vehicle, and the BootLoader program online upgrade method is executed in the electronic control unit of the new energy vehicle.

[0095] UDS protocol is the abbreviation of Road Vehicle-Unified Diagnostic Services. It is a unified international standard developed by the ISO International Organization for Standardization to realize vehicle electronic system fault diagnosis services. The standard number is ISO14229.

[0096] In one embodiment, the above-mentioned online upgrade method of the BootLoader program is executed based on the UDS protocol of the new energy vehicle. Since the UDS upgrade protocol compatible with the whole vehicle is adopted, there is no need to design another protocol, which can ensure the compatibility of the electronic control unit communication protocol, improve the reliability of the online upgrade, and also ensure the authenticity of the upgrade file, and can improve the upgrade efficiency.

[0097] In one embodiment, the present application further provides an electronic control unit, which can be an electronic control unit in any electronic product, preferably an electronic control unit of a new energy vehicle. The electronic control unit executes the above-mentioned BootLoader program online upgrade method.

[0098] In one embodiment, the present application also provides a new energy vehicle, which includes the electronic control unit provided above in the present application.

[0099] Although the embodiments of the present application and its advantages have been described in detail, it should be understood that various changes, substitutions and alterations can be made herein without departing from the spirit and scope of the application as defined by the appended claims.

[0100] In addition, the scope of the present application is not limited to the specific embodiments of the processes, machines, manufactures, material compositions, modes, methods, and steps described in this specification. Those skilled in the art will readily understand from the disclosure of the present application that, according to the present application, currently existing or later to be developed processes, machines, manufactures, material compositions, modes, methods, or steps that perform substantially the same functions or achieve substantially the same results as the corresponding embodiments described herein may be utilized. Therefore, it is intended that the appended claims include such processes, machines, manufactures, material compositions, modes, methods, or steps within their scope.

Claims

1. A BootLoader program online upgrade method, characterized in that: include: S20: downloading the target BootLoader program into a third storage address area of ​​the flash area, wherein the third storage address area is located in an application layer program area of ​​the flash area; S40: Verify the target BootLoader program in the third storage address area. If the verification succeeds, proceed to step S60; if the verification fails, proceed to step S20; S60: Erasing the BootLoader program in the first storage address area of ​​the flash area, where the first storage address area is the BootLoader program area of ​​the flash area; S80: copying the target BootLoader program in the third storage address area into the first storage address area, wherein before step S20, the method further includes: S11: Erasing an application program in a second storage address area of ​​the flash area, where the second storage address area is located in an application layer program area of ​​the flash area; S12: Download the application layer BootLoader program to the second storage address area; S13: Verify the application layer BootLoader program in the second storage address area. If the verification succeeds, proceed to step S14; if the verification fails, proceed to step S12; S14: Jump to the second storage address area and execute the application layer BootLoader program.

2. The BootLoader program online upgrade method according to claim 1, characterized in that: The execution of the application layer BootLoader program in step S14 includes: S141: erasing the application layer program in the third storage address area under the application layer BootLoader program; S142: Execute the step S20, the step S40, the step S60 and the step S80 under the application layer BootLoader program.

3. The BootLoader program online upgrade method according to claim 1, characterized in that: The verification in step S40 includes signature verification and compatibility verification.

4. The BootLoader program online upgrade method according to claim 1, characterized in that: The verification in step S13 includes signature verification and compatibility verification.

5. The BootLoader program online upgrade method according to claim 1, characterized in that: Before step S11, the method further includes: SS1: Enter the programming session, reset, jump from the application to the BootLoader program, determine whether there is an update flag, if yes, enter step SS2, perform the upgrade program, if no, run the application under the current BootLoader program; SS2: Perform security access so that tools with access permissions can perform upgrades; SS3: Download Flash write driver file; SS4: Verify the downloaded Flash write driver file. If the verification succeeds, go to step S11; if the verification fails, go to step SS3.

6. The BootLoader program online upgrade method according to claim 5, characterized in that: Before step SS1, a pre-programming sequence is also included, and the pre-programming sequence includes: S111: Read the version information of the electronic control unit to determine whether the BootLoader program needs to be updated. If so, proceed to step S112; if not, proceed to step S111; S112: Entering the extended session, prohibiting the setting and storage of fault DTCs; S113: Perform upgrade condition check to determine whether the system status can perform program update. If so, go to step SS1; if not, execute the current BootLoader program.

7. The BootLoader program online upgrade method according to claim 1, characterized in that: After step S80, the method further includes: S91: Verify the BootLoader program in the first storage address area. If the verification succeeds, enter the post-programming sequence. If the verification fails, enter step S80.

8. The BootLoader program online upgrade method according to claim 7, characterized in that: The post-programming sequence includes: S92: Perform a compatibility check of the BootLoader program to check whether the BootLoader program in the first storage address area is compatible with the hardware version. If so, set the program valid flag and go to step S93; if not, go to step S20; S93: Execute reset, the program enters the BootLoader program and determines whether the application is valid. If it is valid, enter the application, otherwise remain in the BootLoader program.

9. The BootLoader program online upgrade method according to claim 7, characterized in that: The check in step S91 is an integrity check.

10. The BootLoader program online upgrade method according to claim 8, characterized in that: Step S92 also includes erasing the valid flag of the application layer BootLoader program.

11. The BootLoader program online upgrade method according to claim 1, characterized in that: The BootLoader program online upgrade method is executed in the electronic control unit of the new energy vehicle.

12. The BootLoader program online upgrade method according to claim 11, characterized in that: The BootLoader program online upgrade method is executed based on the UDS protocol of the new energy vehicle.

13. An electronic control unit, characterized in that: Execute the BootLoader program online upgrade method described in claim 1.

14. A new energy vehicle, characterized in that: Comprising the electronic control unit as claimed in claim 13.