Firmware upgrading method, vehicle, computer equipment and computer program product

By receiving FOTA tasks from the server and automatically performing multiple rounds of firmware upgrades, the problem of requiring users to interact and confirm multiple times in existing technologies has been solved, achieving highly efficient automation of firmware upgrades.

CN118981329APending Publication Date: 2024-11-19SHANGHAI JIDU AUTOMOBILE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411195010.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-28
Publication Date
2024-11-19

AI Technical Summary

Technical Problem

In existing technologies, firmware upgrades require users to perform step-by-step operations, which makes the upgrade process cumbersome and inefficient, especially when the current version differs from the target version by several versions, requiring users to interact and confirm multiple times.

Method used

A firmware upgrade method is provided, which receives an FOTA task sent by a server, downloads the firmware package and performs the upgrade. In the case of a bridging task, the upgrade request is automatically resent to the server until the target version is reached, simplifying the user operation.

Benefits of technology

After users only need to enter the confirmation upgrade command once, subsequent upgrades for multiple versions will be executed automatically, improving firmware upgrade efficiency and simplifying the user operation process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118981329A_ABST
    Figure CN118981329A_ABST
Patent Text Reader

Abstract

The invention provides a firmware upgrading method, a vehicle, computer equipment and a computer program product, and the method comprises the steps: sending an upgrading request to a server, and receiving a firmware remote upgrade FOTA task sent by the server; wherein the upgrading request carries current firmware version information of the terminal equipment, the FOTA task carries version information and a task type identifier of a firmware software package to be downloaded, and the task type identifier is used for indicating whether the FOTA task is a bridging task or not; the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal equipment; downloading a firmware software package based on the version information, and performing firmware upgrading based on the downloaded firmware software package; and after the firmware upgrading of the current round is successful, returning to execute the step of sending the upgrading request to the server under the condition that the task type identifier indicates that the FOTA task is a bridge crossing task, so as to execute the firmware upgrading of the next round until the firmware of the terminal equipment is upgraded to a target version.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, and in particular to a firmware upgrade method, a vehicle, a computer device, and a computer program product. Background Art

[0002] Firmware Over The Air (FOTA) is a method of updating device firmware over a wireless network, commonly used in smartphones, tablets, and other mobile devices. FOTA transfers new firmware to the device over the Internet to update and fix errors and problems in the device. This method is more convenient and faster than traditional update methods.

[0003] Generally, when performing a firmware upgrade, the upgrade program is inside the upgrade agent (UA). The previous version of the firmware package has the upgrade program of the next version of the firmware package. Therefore, when upgrading, if the current version differs from the first version by multiple versions, the user needs to upgrade step by step, which is relatively cumbersome. Summary of the invention

[0004] The embodiments of the present disclosure at least provide a firmware upgrade method, a vehicle, a computer device, and a computer program product.

[0005] In a first aspect, an embodiment of the present disclosure provides a firmware upgrade method, including:

[0006] Send an upgrade request to a server, and receive a firmware remote upgrade FOTA task sent by the server; wherein the upgrade request carries the current firmware version information of the terminal device, and the FOTA task carries the version information of the firmware software package to be downloaded and a task type identifier, the task type identifier is used to indicate whether the FOTA task is a bridge task, and the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal device;

[0007] Downloading a firmware package based on the version information, and performing a firmware upgrade based on the downloaded firmware package; wherein, in multiple rounds of firmware upgrades for the bridge task, only the first round of firmware upgrade is performed after the user inputs a confirmation upgrade instruction;

[0008] After the current round of firmware upgrade is successful, when the task type identifier indicates that the FOTA task is a bridge task, return to the step of sending an upgrade request to the server to perform the next round of firmware upgrade until the firmware of the terminal device is upgraded to the target version.

[0009] In a possible implementation manner, the FOTA task also carries a target bridge round; wherein the target bridge round is determined based on the version information of the target version and the firmware version information of the terminal device before the first upgrade;

[0010] When the task type identifier indicates that the FOTA task is a bridge task, returning to execute the step of sending an upgrade request to the server includes:

[0011] In the case where the task type identifier indicates that the FOTA task is a bridge task, determining the currently completed bridge round, and in the case where the currently completed bridge round does not reach the target bridge round, returning to the step of sending an upgrade request to the server;

[0012] The currently completed bridge rounds are the number of interval versions between the current firmware version information of the terminal device and the firmware version information before the first upgrade.

[0013] In a possible implementation, after the user inputs a confirmation upgrade instruction and before the firmware upgrade is performed for the first time based on the firmware software package, the method further includes:

[0014] Determine the current network environment and remaining power of the terminal device;

[0015] When the network environment and the remaining power meet the upgrade conditions, the firmware upgrade is performed based on the downloaded firmware software package.

[0016] In a possible implementation, after the user inputs a confirmation upgrade instruction and before the firmware upgrade is performed for the first time based on the firmware software package, the method further includes:

[0017] Determining the remaining power of the terminal device, and performing a firmware upgrade based on the downloaded firmware software package when the remaining power of the terminal device exceeds a preset power;

[0018] When the task type identifier indicates that the FOTA task is a bridge task, before returning to execute the step of sending an upgrade request to the server, the method further includes:

[0019] Determining the current network environment of the terminal device;

[0020] When the network environment satisfies the downloading condition, the process returns to the step of sending an upgrade request to the server.

[0021] In a possible implementation manner, the method further includes:

[0022] When the currently completed bridge crossing round reaches the target bridge crossing round, an upgrade result is sent to the server.

[0023] In a possible implementation manner, before sending the upgrade request to the server for the first time, the method further includes:

[0024] Receiving target version information sent by the server;

[0025] When the target version information is different from the current firmware version information of the terminal device, an upgrade request is sent to the server.

[0026] In a possible implementation manner, the method further includes:

[0027] After receiving the FOTA task, upgrade prompt information is displayed, where the upgrade prompt information is used to prompt the target bridge rounds for upgrading to the target version.

[0028] In a second aspect, an embodiment of the present disclosure further provides a vehicle for executing the steps of the first aspect or any possible implementation method of the first aspect.

[0029] In a third aspect, an embodiment of the present disclosure further provides a computer device, comprising: a processor and a memory, wherein the memory stores machine-readable instructions executable by the processor, and when the computer device is running, the machine-readable instructions are executed by the processor to perform the steps of the above-mentioned first aspect, or any possible implementation of the first aspect.

[0030] In a fourth aspect, an embodiment of the present disclosure further provides a computer program product, including a computer program, which, when executed, implements the method described in the above-mentioned first aspect, or any possible implementation manner of the first aspect.

[0031] The disclosed embodiments provide a firmware upgrade method, vehicle, computer device, and computer program product, which can download a firmware package after receiving a FOTA task sent by a server, and then automatically resend an upgrade request to the server after performing a firmware upgrade based on the firmware package, if the FOTA task is a bridge task, to upgrade the next version. In this way, the user only needs to enter a confirmation upgrade instruction when performing a firmware upgrade for the first time, and subsequent upgrades of multiple versions are automatically executed, which simplifies user operations and improves the efficiency of firmware upgrades.

[0032] In order to make the above-mentioned objectives, features and advantages of the present disclosure more obvious and easy to understand, preferred embodiments are specifically cited below and described in detail with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the following is a brief introduction to the drawings required for use in the embodiments. The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present disclosure and are used together with the specification to illustrate the technical solutions of the present disclosure. It should be understood that the following drawings only illustrate certain embodiments of the present disclosure and should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can also be obtained based on these drawings without creative work.

[0034] Figure 1 A flowchart of a firmware upgrade method provided by an embodiment of the present disclosure is shown;

[0035] Figure 2 An architectural diagram of a firmware upgrade method provided by an embodiment of the present disclosure is shown;

[0036] Figure 3 A schematic diagram of the architecture of a firmware upgrade device provided by an embodiment of the present disclosure is shown;

[0037] Figure 4 A schematic diagram of the structure of a computer device provided by an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0038] In order to make the purpose, technical solutions and advantages of the embodiments of the present disclosure clearer, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, rather than all of the embodiments. The components of the embodiments of the present disclosure generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present disclosure provided in the drawings is not intended to limit the scope of the present disclosure claimed for protection, but merely represents selected embodiments of the present disclosure.

[0039] Research has found that when performing a firmware upgrade, the upgrade program is inside the Update Agent (UA). The previous version of the firmware package has the upgrade program for the next version of the firmware package. Therefore, when upgrading, if the current version differs from the first version by multiple versions, the user needs to upgrade step by step, which is more cumbersome.

[0040] For example, if the current firmware version of the terminal device (here refers to the user device) is version 1.0, and the target version is version 3.0, then when the terminal device is upgraded, the operator needs to push version 2.0 to the user first, and then after the user clicks to confirm the upgrade, the terminal device's firmware is first upgraded to version 2.0, and then the operator pushes version 3.0 to the user, and then the user needs to click again to confirm the upgrade, and then the terminal device's firmware can be upgraded from version 2.0 to version 2.0. In this process, the operator needs to push firmware versions to the terminal device multiple times, and the user needs to interact multiple times to confirm the upgrade, which has low upgrade efficiency and cumbersome operations.

[0041] Based on the above research, the present disclosure provides a firmware upgrade method, vehicle, computer equipment and computer program product, which can download the firmware software package after receiving the FOTA task sent by the server, and then after the firmware upgrade is performed based on the firmware software package, when the FOTA task is a bridge task, automatically resend the upgrade request to the server to upgrade the next version. In this way, the user only needs to enter the confirmation upgrade instruction when performing the firmware upgrade for the first time, and the subsequent upgrades of multiple versions are automatically executed, which simplifies the user operation and improves the efficiency of firmware upgrade.

[0042] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.

[0043] The term "and / or" herein only describes an association relationship, indicating that three relationships may exist. For example, A and / or B may represent the following three situations: A exists alone, A and B exist at the same time, and B exists alone. In addition, the term "at least one" herein represents any combination of at least two of any one or more of a plurality of. For example, including at least one of A, B, and C may represent including any one or more elements selected from the set consisting of A, B, and C.

[0044] It can be understood that before using the technical solutions disclosed in the embodiments of the present disclosure, the personal information involved in the present disclosure (including but not limited to attribute information, facial images, etc.) is obtained with the authorization of the user. Specifically, it can be through a pop-up window in the page, information push, etc., sending a prompt message requesting authorization to the user, and obtaining the above personal information after the user agrees to the authorization.

[0045] To facilitate understanding of the present embodiment, a firmware upgrade method disclosed in the embodiment of the present disclosure is first introduced in detail. The executor of the firmware upgrade method provided in the embodiment of the present disclosure is generally a vehicle terminal. Specifically, the electronic control unit (ECU) on the vehicle needs FOTA. The ECU mainly includes two categories. One is a domain controller. Each domain controller has an independent upgrade agent module for interacting with the FOTA main program (master). The other is a small ECU mounted under the microcontroller unit (MCU) of each domain controller. This type of ECU does not have an independent upgrade agent and requires the FOTA master to send a diagnostic command to upgrade it.

[0046] See also Figure 1 FIG. 1 is a flowchart of a firmware upgrade method provided by an embodiment of the present disclosure, wherein the method includes steps 101 to 103, wherein:

[0047] Step 101, sending an upgrade request to a server, and receiving a firmware remote upgrade FOTA task sent by the server; wherein the upgrade request carries the current firmware version information of the terminal device, and the FOTA task carries the version information of the firmware software package to be downloaded and a task type identifier, the task type identifier is used to indicate whether the FOTA task is a bridge task, and the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal device.

[0048] Step 102: download a firmware package based on the version information, and perform a firmware upgrade based on the downloaded firmware package; wherein, in multiple rounds of firmware upgrades for the bridge task, only the first round of firmware upgrade is performed after the user inputs a confirmation upgrade instruction.

[0049] Step 103: After the current round of firmware upgrade is successful, when the task type identifier indicates that the FOTA task is a bridge task, return to the step of sending an upgrade request to the server to perform the next round of firmware upgrade until the firmware of the terminal device is upgraded to the target version.

[0050] The following is a detailed description of the above steps.

[0051] For step 101,

[0052] The sending of the upgrade request to the server may be sent after receiving the target version information sent by the server.

[0053] Specifically, after a new version of the firmware software package is released, the operator can push the target version information of the new version of the firmware software package to each terminal device through the server. After receiving the target version information, the terminal device can first detect whether the current firmware version information of the terminal device is the target version information. If not, it can send an upgrade request to the server.

[0054] Here, the upgrade request may carry the current firmware version information of the terminal device, and the firmware may include one or more of the following firmware:

[0055] Power domain firmware, chassis domain firmware, body domain firmware, cockpit domain firmware, body gateway domain controller (BGM), body networking domain controller (Automotive Connectivity Unit, ACU), MCU, continuous damping control system (Continuous Damping Control, CDC).

[0056] After receiving the upgrade request sent by the terminal device, the server may determine the version information of the firmware software package to be downloaded based on the current firmware version information and the target version information of the terminal device.

[0057] Here, the target version information may be the version information of the latest released firmware. When the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal device and the target version information, the version information of the next version of the current firmware version of the terminal device may be used as the version information of the firmware software package to be downloaded. The version information of the firmware software package to be downloaded may be the version information of a version of the software package between the current firmware version and the target version, or may be the target version information.

[0058] Exemplarily, if the current firmware version information of the terminal device is 1.0 and the target version information is 4.0, the version information of the firmware software package to be downloaded may be 2.0; if the current firmware version information of the terminal device is 3.0 and the target version information is 4.0, the version information of the firmware software package to be downloaded may be 4.0.

[0059] The above-mentioned bridge task can be understood as a task that requires the execution of intermediate tasks in order to complete the final task. For example, if the final task is to upgrade the firmware version to the target version, the intermediate task that needs to be executed is to upgrade the firmware version to the intermediate version before the target version. Therefore, upgrading the firmware to the target version is a bridge task.

[0060] For step 102 and step 103,

[0061] The FOTA task may also include a download address of the firmware software package to be downloaded. After receiving the FOTA task, the terminal device may download the firmware software package of corresponding version information based on the download address.

[0062] After receiving the FOTA task, since multiple firmware upgrade processes may need to be performed, a prompt message can be displayed before the first firmware upgrade to prompt the user to confirm the upgrade. After receiving the upgrade confirmation instruction input by the user, the firmware upgrade can be performed based on the downloaded firmware software package.

[0063] For example, if the current firmware version of the terminal device is 1.0 (here refers to the version before the firmware upgrade), and the target version is 4.0, the terminal device needs to be upgraded to 2.0 first, then upgraded from 2.0 to 3.0, and then upgraded from 3.0 to 4.0. After the terminal device receives the FOTA task, it first downloads the 2.0 version of the firmware package, and then before upgrading the current firmware of the terminal device from 1.0 to 2.0, it can first display a prompt message to the user to prompt the user to upgrade. After receiving the confirmation upgrade instruction input by the user, the firmware upgrade is performed based on the 2.0 version of the firmware package. When performing firmware upgrades for subsequent 3.0 and 4.0 versions of the firmware package, the user does not need to enter the confirmation upgrade instruction again.

[0064] In a possible implementation, after the user inputs a confirmation upgrade instruction, before performing the firmware upgrade based on the firmware software package for the first time, it is also necessary to confirm whether the current environment information of the terminal device meets the upgrade conditions.

[0065] Specifically, the current network environment and remaining power of the terminal device may be determined, and when the network environment and remaining power meet the upgrade conditions, the firmware upgrade is performed based on the downloaded firmware software package.

[0066] In actual applications, since the upgrade process may involve the download of multiple versions of firmware software packages and multiple firmware upgrades, it is necessary to first determine whether the remaining power of the terminal device is sufficient to support the upgrade; and since the firmware software package needs to be downloaded during the upgrade process, the current network environment of the terminal device also needs to be able to support the download during the upgrade process.

[0067] Optionally, the remaining power of the terminal device may be characterized by a state of charge (SOC) of the terminal device, and the network environment of the terminal device may be characterized by a download speed of the terminal device.

[0068] The network environment and remaining power satisfying the upgrade conditions may mean that the SOC of the terminal device is greater than a first preset value, and the network download speed satisfies the download conditions, such as being able to download data of a preset size within a preset time, for example, downloading 10 megabytes (MB) of data within 6 seconds.

[0069] It should be noted here that compared with the judgment of power in the related art, since a complete upgrade process in the related art only needs to perform a firmware upgrade based on a firmware software package, the requirement for the remaining power is relatively low, while in the present disclosure, a complete upgrade process may include multiple firmware upgrade processes and at least one firmware software package download process, so the requirement for the remaining power in the present disclosure is relatively high. In addition, since a complete upgrade process in the related art only needs to perform a firmware upgrade based on a firmware software package, the firmware software package will be downloaded before the firmware upgrade, so in the related art, there is no requirement for the network environment during the firmware upgrade process; while in the present disclosure, since the upgrade process may involve the download of the firmware software package, the network environment needs to be detected before the firmware upgrade in the present disclosure.

[0070] In another possible implementation, after sending the upgrade request, there is no need to download the firmware software package when the firmware upgrade is performed for the first time (because the firmware software package has been downloaded before the upgrade, and the user's input confirmation of the upgrade instruction can be regarded as the start of the upgrade process), therefore, after the user enters the confirmation of the upgrade instruction, before the first firmware upgrade is performed based on the firmware software package, the remaining power of the terminal device can be determined. When the remaining power of the terminal device exceeds the preset power, the firmware upgrade is performed directly based on the downloaded firmware software package.

[0071] Furthermore, when the task type identifier indicates that the FOTA task is a bridge task, before returning to execute the step of sending an upgrade request to the server, determine the current network environment of the terminal device, and when the network environment meets the download conditions, return to execute the step of sending an upgrade request to the server.

[0072] After returning to execute and sending the upgrade request to the server, it means that there is a download demand (ie, downloading a new firmware package) at this time. Therefore, judging the network environment at this time can ensure that the firmware package can be downloaded smoothly.

[0073] In one possible implementation, when the task type identifier indicates that the FOTA task is a bridge task, an upgrade request can be sent directly to the server. At this time, the firmware version information carried in the upgrade request is the firmware version information after the terminal device is upgraded. If the upgraded firmware version information is still not the target version information, the server can generate a new FOTA task and send it to the terminal device. The terminal device can perform the firmware upgrade again according to the method provided in the above embodiment; if the firmware version information carried in the upgrade request is the target version information, the server can send an update completion message to the terminal device to instruct the terminal device to stop requesting the upgrade.

[0074] In another possible implementation, the server can also determine the target bridging rounds to be executed in advance based on the target version information and the firmware version information of the terminal device, and then the terminal device can record the completed bridging rounds, and when the completed bridging rounds reach the target bridging rounds, stop requesting updates.

[0075] Specifically, the FOTA task may also carry a target bridge round; wherein the target bridge round is determined based on the version information of the target version and the firmware version information of the terminal device before the first upgrade.

[0076] In the case where the task type identifier indicates that the FOTA task is a bridge task, returning to execute the step of sending an upgrade request to the server may include: in the case where the task type identifier indicates that the FOTA task is a bridge task, determining the currently completed bridge rounds, and in the case where the currently completed bridge rounds do not reach the target bridge rounds, returning to execute the step of sending an upgrade request to the server; wherein the currently completed bridge rounds are the number of interval versions between the current firmware version information of the terminal device and the firmware version information before the first upgrade.

[0077] Here, the currently completed bridge rounds may refer to the number of versions between the current firmware version information of the terminal device and the firmware version information before the first upgrade, or may refer to the currently completed upgrade number minus 1. For example, if the current firmware version of the terminal device is 2.0, the firmware version before the first upgrade is 1.0, and the number of versions between the two is 0, then the currently completed bridge rounds are 0; if the current firmware version of the terminal device is 3.0, the firmware version before the first upgrade is 1.0, and the number of versions between the two is 1, then the currently completed bridge rounds are 1.

[0078] Optionally, the target bridging round number may be the number of versions between the firmware version of the terminal device before the first upgrade and the target version. For example, if the target version is 3.0, the firmware version of the terminal device before the upgrade is 1.0, and there is a 2.0 version in between, then the target bridging round number is 1.

[0079] Exemplarily, if the target version is 3.0, the firmware version of the terminal device before upgrading is 1.0, and the target bridging round is 1, after the terminal device receives the FOTA task, the FOTA task carries the version information and download address of version 2.0, as well as the target bridging round 1. After the terminal device downloads the firmware software package of version 2.0 according to the download address, it can perform a firmware upgrade based on the firmware software package, and determine the currently completed bridging round -0. Since the currently completed bridging round has not reached the target bridging round, it can send an upgrade request to the server again. At this time, the server sends a FOTA task to the terminal device again. The FOTA task carries the version information and download address of version 3.0, as well as the target bridging round 1. After the terminal device downloads the firmware software package of version 3.0 according to the download address, it can perform a firmware upgrade based on the firmware software package, and record the currently completed bridging round -1. Since the currently completed bridging round has reached the target bridging round, it can stop sending upgrade requests to the server.

[0080] In another possible implementation, the FOTA task may also carry the remaining bridge rounds. Here, the remaining bridge rounds can be determined based on the version information of the target version and the firmware version information of the terminal device before the current round of upgrade (that is, the current firmware version information of the terminal device). Accordingly, before returning to execute the step of sending an upgrade task request to the server, it can be determined whether the remaining bridge rounds in the currently received FOTA task are 0. If it is 0, stop sending the upgrade task request to the server. If it is not 0, return to execute the step of sending the upgrade task request to the server.

[0081] Optionally, the remaining bridge rounds can be the number of versions between the current firmware version of the terminal device and the target version. In multiple bridge rounds of the bridge task, the remaining bridge rounds carried in each FOTA task sent by the server are different. For example, the remaining bridge rounds carried in the currently sent FOTA task can be the remaining bridge rounds carried by the last sent FOTA task minus 1.

[0082] For example, if the target version is 3.0, and the firmware version of the terminal device before the upgrade is 1.0, during the first upgrade, the remaining bridging rounds carried in the FOTA task issued by the server is 1, and the terminal device can perform the firmware upgrade after receiving the FOTA task. The firmware version of the terminal device is upgraded to 2.0, and the remaining bridging rounds are 1 (not 0), then the upgrade request is resent to the server, and the server can send the FOTA task to the terminal device again, and carry the remaining bridging rounds of 0. The terminal device can perform the firmware upgrade again after receiving the FOTA task, and the firmware version of the terminal device is upgraded to 3.0. At this time, since the remaining bridging rounds received are 0, the upgrade request to the server can be stopped.

[0083] In this way, the terminal device can determine by itself when to stop sending upgrade requests to the server, avoiding sending unnecessary requests and wasting transmission resources.

[0084] Alternatively, in another possible implementation, since the server first sends the target version information to the terminal device before the terminal device sends the upgrade request for the first time, the terminal device can first determine whether the current firmware version information of the terminal device is the target version information before returning to execute the upgrade request to the server. If not, it returns to the step of sending the upgrade request to the server.

[0085] Optionally, after receiving the FOTA task, upgrade prompt information can also be displayed. The upgrade prompt information is used to prompt the target bridge rounds for upgrading to the target version. In this way, users can grasp the upgrade progress in real time and improve user experience.

[0086] In another possible implementation, if the currently completed bridging round reaches the target bridging round, it means that the current firmware of the terminal device has been upgraded to the target version, so the upgrade result can be sent to the server to indicate that the current upgrade is completed.

[0087] Optionally, during the firmware upgrade process, it may include firmware upgrades of the power domain, chassis domain, body domain, and cockpit domain, and may include upgrades of BGM, MCU, ACU, CDC, etc.

[0088] The firmware upgrade method provided by the present disclosure will be described below in conjunction with the overall architecture. Figure 2 As shown, it is an architecture diagram of a firmware upgrade method provided by an embodiment of the present disclosure, which mainly includes the following steps:

[0089] First, the terminal device upgrades the firmware version and uploads it to the cloud (i.e., server), for example, by sending an upgrade request. Then, after receiving the first round of FOTA tasks, the software package is downloaded. Before the first firmware update, interaction with the user is required. After the user enters and confirms the upgrade command, a pre-upgrade is performed first. During the pre-upgrade process, the software package can be parsed and processed.

[0090] After the upgrade, the four-domain upgrade (firmware upgrade of the power domain, chassis domain, body domain, and cockpit domain) is performed first. If successful, the high-voltage components such as BGM and MCU are upgraded. After the upgrade is successful, the low-voltage components such as ACU and CDC are upgraded. After the upgrade is completed, it is determined whether the FOTA task has a bridge crossing mark (that is, whether the FOTA task is a bridge crossing task). If so, it is determined whether the target bridge crossing round is reached. If not, it returns to the process of version collection and uploading to the cloud, and receives the second round of FOTA tasks sent by the cloud.

[0091] If any firmware upgrade fails, the subsequent upgrade process can still be performed, but it can be determined that the firmware upgrade has failed.

[0092] For detailed description of the above steps, please refer to the above embodiments and will not be described in detail here.

[0093] The firmware upgrade method provided by the embodiment of the present disclosure can download the firmware software package after receiving the FOTA task sent by the server, and then after performing the firmware upgrade based on the firmware software package, when the FOTA task is a bridge task, automatically resend the upgrade request to the server to upgrade to the next version. In this way, the user only needs to enter the confirmation upgrade instruction when performing the firmware upgrade for the first time, and the subsequent upgrades of multiple versions are all automatically executed, which simplifies the user operation and improves the efficiency of the firmware upgrade.

[0094] Those skilled in the art will appreciate that, in the above method of specific implementation, the order in which the steps are written does not imply a strict execution order and does not constitute any limitation on the implementation process. The specific execution order of the steps should be determined by their functions and possible internal logic.

[0095] Based on the same inventive concept, a firmware upgrade device corresponding to the firmware upgrade method is also provided in the embodiment of the present disclosure. Since the principle of solving the problem by the device in the embodiment of the present disclosure is similar to the above-mentioned firmware upgrade method in the embodiment of the present disclosure, the implementation of the device can refer to the implementation of the method, and the repeated parts will not be repeated.

[0096] Reference Figure 3, which is a schematic diagram of the architecture of a firmware upgrade device provided by an embodiment of the present disclosure, the device includes: a communication module 301, an upgrade module 302, and a circulation module 303; wherein,

[0097] The communication module 301 is used to send an upgrade request to a server and receive a firmware remote upgrade FOTA task sent by the server; wherein the upgrade request carries the current firmware version information of the terminal device, and the FOTA task carries the version information of the firmware software package to be downloaded and a task type identifier, wherein the task type identifier is used to indicate whether the FOTA task is a bridge task, and the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal device;

[0098] An upgrade module 302 is used to download a firmware package based on the version information, and perform a firmware upgrade based on the downloaded firmware package; wherein, in multiple rounds of firmware upgrades of the bridge task, only the first round of firmware upgrade is performed after the user inputs a confirmation upgrade instruction;

[0099] The loop module 303 is used to return to the step of sending an upgrade request to the server after the current round of firmware upgrade is successful, when the task type identifier indicates that the FOTA task is a bridge task, to perform the next round of firmware upgrade until the firmware of the terminal device is upgraded to the target version.

[0100] In a possible implementation manner, the FOTA task also carries a target bridge round; wherein the target bridge round is determined based on the version information of the target version and the firmware version information of the terminal device before the first upgrade;

[0101] The circulation module 303 is used for:

[0102] In the case where the task type identifier indicates that the FOTA task is a bridge task, determining the currently completed bridge round, and in the case where the currently completed bridge round does not reach the target bridge round, returning to the step of sending an upgrade request to the server;

[0103] The currently completed bridge rounds are the number of interval versions between the current firmware version information of the terminal device and the firmware version information before the first upgrade.

[0104] In a possible implementation, the upgrade module 302 is used to:

[0105] Determine the current network environment and remaining power of the terminal device;

[0106] When the network environment and the remaining power meet the upgrade conditions, the firmware upgrade is performed based on the downloaded firmware software package.

[0107] In a possible implementation, the upgrade module 302 is used to:

[0108] Determining the remaining power of the terminal device, and performing a firmware upgrade based on the downloaded firmware software package when the remaining power of the terminal device exceeds a preset power;

[0109] The loop module 303 is used to:

[0110] Determining the current network environment of the terminal device;

[0111] When the network environment satisfies the downloading condition, the process returns to the step of sending an upgrade request to the server.

[0112] In a possible implementation manner, the communication module 301 is further used for:

[0113] When the currently completed bridge crossing round reaches the target bridge crossing round, an upgrade result is sent to the server.

[0114] In a possible implementation manner, the communication module 301 is further used for:

[0115] Receiving target version information sent by the server;

[0116] When the target version information is different from the current firmware version information of the terminal device, an upgrade request is sent to the server.

[0117] In a possible implementation manner, the communication module 301 is further used for:

[0118] After receiving the FOTA task, upgrade prompt information is displayed, where the upgrade prompt information is used to prompt the target bridge rounds for upgrading to the target version.

[0119] For descriptions of the processing flow of each module in the device and the interaction flow between each module, reference may be made to the relevant descriptions in the above method embodiment, which will not be described in detail here.

[0120] Based on the same technical concept, the embodiment of the present disclosure also provides a computer device. Figure 4As shown, it is a schematic diagram of the structure of a computer device 400 provided in an embodiment of the present disclosure, including a processor 401, a memory 402, and a bus 403. Among them, the memory 402 is used to store execution instructions, including a memory 4021 and an external memory 4022; the memory 4021 here is also called an internal memory, which is used to temporarily store the operation data in the processor 401, and the data exchanged with the external memory 4022 such as a hard disk. The processor 401 exchanges data with the external memory 4022 through the memory 4021. When the computer device 400 is running, the processor 401 communicates with the memory 402 through the bus 403, so that the processor 401 executes the following instructions:

[0121] Send an upgrade request to a server, and receive a firmware remote upgrade FOTA task sent by the server; wherein the upgrade request carries the current firmware version information of the terminal device, and the FOTA task carries the version information of the firmware software package to be downloaded and a task type identifier, the task type identifier is used to indicate whether the FOTA task is a bridge task, and the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal device;

[0122] Downloading a firmware package based on the version information, and performing a firmware upgrade based on the downloaded firmware package; wherein, in multiple rounds of firmware upgrades for the bridge task, only the first round of firmware upgrade is performed after the user inputs a confirmation upgrade instruction;

[0123] After the current round of firmware upgrade is successful, when the task type identifier indicates that the FOTA task is a bridge task, return to the step of sending an upgrade request to the server to perform the next round of firmware upgrade until the firmware of the terminal device is upgraded to the target version.

[0124] In a possible implementation, in the instruction executed by the processor 401, the FOTA task also carries a target bridge round; wherein the target bridge round is determined based on the version information of the target version and the firmware version information of the terminal device before the first upgrade;

[0125] When the task type identifier indicates that the FOTA task is a bridge task, returning to execute the step of sending an upgrade request to the server includes:

[0126] In the case where the task type identifier indicates that the FOTA task is a bridge task, determining the currently completed bridge round, and in the case where the currently completed bridge round does not reach the target bridge round, returning to the step of sending an upgrade request to the server;

[0127] The currently completed bridge rounds are the number of interval versions between the current firmware version information of the terminal device and the firmware version information before the first upgrade.

[0128] In a possible implementation manner, in the instructions executed by the processor 401, after the user inputs a confirmation upgrade instruction and before the firmware upgrade is performed for the first time based on the firmware software package, the method further includes:

[0129] Determine the current network environment and remaining power of the terminal device;

[0130] When the network environment and the remaining power meet the upgrade conditions, the firmware upgrade is performed based on the downloaded firmware software package.

[0131] In a possible implementation manner, the instructions executed by the processor 401, after the user inputs a confirmation upgrade instruction and before the firmware upgrade is performed for the first time based on the firmware software package, further include:

[0132] Determining the remaining power of the terminal device, and performing a firmware upgrade based on the downloaded firmware software package when the remaining power of the terminal device exceeds a preset power;

[0133] When the task type identifier indicates that the FOTA task is a bridge task, before returning to execute the step of sending an upgrade request to the server, the method further includes:

[0134] Determining the current network environment of the terminal device;

[0135] When the network environment satisfies the downloading condition, the process returns to the step of sending an upgrade request to the server.

[0136] In a possible implementation manner, in the instruction executed by the processor 401, the method further includes:

[0137] When the currently completed bridge crossing round reaches the target bridge crossing round, an upgrade result is sent to the server.

[0138] In a possible implementation manner, the instructions executed by the processor 401, before sending the upgrade request to the server for the first time, further include:

[0139] Receiving target version information sent by the server;

[0140] When the target version information is different from the current firmware version information of the terminal device, an upgrade request is sent to the server.

[0141] In a possible implementation manner, the instructions executed by the processor 401 further include:

[0142] After receiving the FOTA task, upgrade prompt information is displayed, where the upgrade prompt information is used to prompt the target bridge rounds for upgrading to the target version.

[0143] The embodiments of the present disclosure also provide a vehicle, which can be used to execute the steps of the firmware upgrade method described in the above method embodiment.

[0144] The embodiment of the present disclosure also provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the steps of the firmware upgrade method described in the above method embodiment are executed. The storage medium can be a volatile or non-volatile computer-readable storage medium.

[0145] The embodiments of the present disclosure also provide a computer program product, which carries a program code. The instructions included in the program code can be used to execute the steps of the firmware upgrade method described in the above method embodiment. For details, please refer to the above method embodiment, which will not be repeated here.

[0146] The computer program product may be implemented in hardware, software or a combination thereof. In one optional embodiment, the computer program product is implemented as a computer storage medium. In another optional embodiment, the computer program product is implemented as a software product, such as a software development kit (SDK).

[0147] Those skilled in the art can clearly understand that, for the convenience and simplicity of description, the specific working process of the system and device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here. In the several embodiments provided in the present disclosure, it should be understood that the disclosed system, device and method can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, and the indirect coupling or communication connection of the device or unit can be electrical, mechanical or other forms.

[0148] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0149] In addition, each functional unit in each embodiment of the present disclosure may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.

[0150] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a non-volatile computer-readable storage medium that is executable by a processor. Based on this understanding, the technical solution of the present disclosure, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present disclosure. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0151] Finally, it should be noted that the above-described embodiments are only specific implementation methods of the present disclosure, which are used to illustrate the technical solutions of the present disclosure, rather than to limit them. The protection scope of the present disclosure is not limited thereto. Although the present disclosure is described in detail with reference to the above-described embodiments, ordinary technicians in the field should understand that any technician familiar with the technical field can still modify the technical solutions recorded in the above-described embodiments within the technical scope disclosed in the present disclosure, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present disclosure, and should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.

Claims

1. A firmware upgrade method, characterized in that: include: Send an upgrade request to a server, and receive a firmware remote upgrade FOTA task sent by the server; wherein the upgrade request carries the current firmware version information of the terminal device, and the FOTA task carries the version information of the firmware software package to be downloaded and a task type identifier, the task type identifier is used to indicate whether the FOTA task is a bridge task, and the version information of the firmware software package to be downloaded is determined based on the current firmware version information of the terminal device; Downloading a firmware package based on the version information, and performing a firmware upgrade based on the downloaded firmware package; wherein, in multiple rounds of firmware upgrades for the bridge task, only the first round of firmware upgrade is performed after the user inputs a confirmation upgrade instruction; After the current round of firmware upgrade is successful, when the task type identifier indicates that the FOTA task is a bridge task, return to the step of sending an upgrade request to the server to perform the next round of firmware upgrade until the firmware of the terminal device is upgraded to the target version.

2. The method according to claim 1, characterized in that The FOTA task also carries a target bridge round; wherein the target bridge round is determined based on the version information of the target version and the firmware version information of the terminal device before the first upgrade; When the task type identifier indicates that the FOTA task is a bridge task, returning to execute the step of sending an upgrade request to the server includes: In the case where the task type identifier indicates that the FOTA task is a bridge task, determining the currently completed bridge round, and in the case where the currently completed bridge round does not reach the target bridge round, returning to the step of sending an upgrade request to the server; The currently completed bridge rounds are the number of interval versions between the current firmware version information of the terminal device and the firmware version information before the first upgrade.

3. The method according to claim 1, characterized in that After the user inputs a confirmation upgrade instruction and before the firmware upgrade is performed for the first time based on the firmware software package, the method further includes: Determine the current network environment and remaining power of the terminal device; When the network environment and the remaining power meet the upgrade conditions, the firmware upgrade is performed based on the downloaded firmware software package.

4. The method according to claim 1, characterized in that: After the user inputs a confirmation upgrade instruction and before the firmware upgrade is performed for the first time based on the firmware software package, the method further includes: Determining the remaining power of the terminal device, and performing a firmware upgrade based on the downloaded firmware software package when the remaining power of the terminal device exceeds a preset power; When the task type identifier indicates that the FOTA task is a bridge task, before returning to execute the step of sending an upgrade request to the server, the method further includes: Determining the current network environment of the terminal device; When the network environment satisfies the downloading condition, the process returns to the step of sending an upgrade request to the server.

5. The method according to claim 2, characterized in that: The method further comprises: When the currently completed bridge crossing round reaches the target bridge crossing round, an upgrade result is sent to the server.

6. The method according to claim 1, characterized in that Before sending the upgrade request to the server for the first time, the method further includes: Receiving target version information sent by the server; When the target version information is different from the current firmware version information of the terminal device, an upgrade request is sent to the server.

7. The method according to claim 2, characterized in that The method further comprises: After receiving the FOTA task, upgrade prompt information is displayed, where the upgrade prompt information is used to prompt the target bridge rounds for upgrading to the target version.

8. A vehicle, characterized in that: The vehicle is used to execute the firmware upgrade method as described in any one of claims 1 to 7.

9. A computer device, characterized in that: include: A processor and a memory, wherein the memory stores machine-readable instructions executable by the processor, and when the computer device is running, the machine-readable instructions are executed by the processor to perform the steps of the firmware upgrade method according to any one of claims 1 to 7.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed, the steps of the firmware upgrade method according to any one of claims 1 to 7 are implemented.