Firmware upgrading method, firmware upgrading device and chip

By acquiring and configuring firmware upgrade packages with multiple upgrade methods, the problem of low firmware upgrade efficiency was solved, enabling flexible and fast firmware upgrades and improving upgrade efficiency and user experience.

CN122152336APending Publication Date: 2026-06-05BEIJING SPREADTRUM HI TECH COMM TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
BEIJING SPREADTRUM HI TECH COMM TECH CO LTD
Filing Date
2026-03-13
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

In existing technologies, firmware upgrades are inefficient and cannot flexibly configure upgrade methods for multiple partitions, resulting in an inefficient firmware upgrade process for electronic devices.

Method used

This invention provides a firmware upgrade method that obtains the firmware upgrade package, determines the upgrade method for each image file, and deploys the image files according to the upgrade order. It supports multiple upgrade methods such as full package, differential, compression, and encryption, enabling flexible and fast firmware upgrades.

Benefits of technology

It improves the efficiency of firmware upgrades, allows for flexible configuration of upgrade methods for multiple partitions, and increases the success rate of firmware upgrades and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122152336A_ABST
    Figure CN122152336A_ABST
Patent Text Reader

Abstract

The application relates to a firmware upgrading method, a firmware upgrading device and a chip. The method comprises the following steps: obtaining a firmware upgrading package; determining, for each image file, an upgrading mode corresponding to the image file; and deploying each image file according to the upgrading modes and an upgrading sequence. The method can improve the firmware upgrading efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of chip technology, and in particular to a firmware upgrade method, a firmware upgrade device, and a chip. Background Technology

[0002] With the continuous development of software and hardware technologies and the increasing application scope of electronic devices, electronic devices have appeared in various scenarios. In daily life, electronic devices can provide users with a variety of rich, colorful, real-time and stable forms of entertainment. In industrial production, electronic devices can also be deployed in harsh production environments to achieve functions such as data monitoring.

[0003] Firmware plays a crucial role in electronic devices, acting as a bridge between hardware and upper-level software. It is the foundation for electronic devices to function properly, be controlled, and achieve their functions. Therefore, how to better upgrade firmware has become a concern for all parties. Summary of the Invention

[0004] Therefore, it is necessary to provide a firmware upgrade method, firmware upgrade device, and chip that can improve firmware upgrade efficiency in response to the above-mentioned technical problems.

[0005] In a first aspect, this application provides a firmware upgrade method applicable to terminal devices. The method includes: obtaining a firmware upgrade package, which includes multiple image files and an upgrade order for each image file; determining the corresponding upgrade method for each image file; and deploying each image file according to the upgrade method and upgrade order.

[0006] In one embodiment, the upgrade method includes at least one of the following: a full package upgrade method, which instructs the image file to contain an upgrade package containing a complete firmware image, and performs a full-coverage upgrade on the target firmware; a differential upgrade method, which instructs the image file to contain an upgrade package containing an incremental firmware image, and performs an incremental upgrade on the upgrade partition of the target firmware; a compressed upgrade method, which instructs the image file to be decompressed to obtain a decompressed image file, and deploys the decompressed image file; and an encrypted upgrade method, which instructs the target encrypted partition of the target firmware to be upgraded, or the encrypted upgrade method instructs the image file to be decrypted to obtain a decrypted image file, and deploys the decrypted image file.

[0007] In one embodiment, the method further includes: generating an upgrade success flag for each image file after successful deployment; generating an upgrade completion message based on the upgrade success flags of each image file; and displaying the upgrade completion message on the system interface.

[0008] In one embodiment, the method further includes: generating an upgrade failure flag for each image file after a deployment failure; generating an upgrade failure message based on the upgrade failure flags of each image file; and displaying the upgrade failure message on the system interface.

[0009] In one embodiment, obtaining the firmware upgrade package includes: receiving the firmware upgrade package sent by the upgrade device; decompressing the firmware upgrade package to obtain the decompressed firmware upgrade package; and extracting the image files and upgrade order included in the decompressed firmware upgrade package.

[0010] The aforementioned firmware upgrade method obtains the firmware upgrade package created and sent by the upgrade device. The firmware upgrade package includes multiple image files and the upgrade order of each image file. For each image file, the corresponding upgrade method is determined. By flexibly setting the image files and upgrade methods of multiple partitions, flexible and fast firmware upgrades are achieved. Then, according to each upgrade method and upgrade order, each image file is deployed to complete the firmware upgrade, thereby improving the efficiency of firmware upgrades.

[0011] Secondly, this application also provides a firmware upgrade device, including: an upgrade package acquisition module for acquiring a firmware upgrade package, wherein the firmware upgrade package includes multiple image files and an upgrade order of each image file; an upgrade method determination module for determining the upgrade method corresponding to each image file; and a file deployment module for deploying each image file according to each upgrade method and upgrade order.

[0012] Thirdly, this application provides another firmware upgrade method for upgrading devices. The method includes: generating a firmware upgrade package for the target firmware, wherein the firmware upgrade package includes multiple image files and the upgrade order of each image file; sending the firmware upgrade package to the terminal device; wherein the firmware upgrade package is used to enable the terminal device to deploy each image file according to the upgrade method and upgrade order corresponding to each image file.

[0013] In one embodiment, generating a firmware upgrade package for the target firmware includes: obtaining each image file and the upgrade method corresponding to each image file through an interactive interface; generating candidate upgrade packages corresponding to each image file according to each upgrade method; and generating a firmware upgrade package according to each candidate upgrade package.

[0014] In one embodiment, generating candidate upgrade packages corresponding to each image file according to each upgrade method includes: for each image file, determining a production strategy according to the upgrade method corresponding to the image file, the production strategy being used to characterize the production method of the candidate upgrade package; and generating candidate upgrade packages corresponding to the image file according to the production strategy and the image file.

[0015] In the other firmware upgrade method described above, the upgrade device creates a firmware upgrade package containing multiple image files and an upgrade order according to instructions, and sends the firmware upgrade package to the terminal device. By setting the upgrade method of each image file at the creation end, the upgrade method of each partition of the target firmware can be flexibly configured, thereby realizing the upgrade of multiple partitions at once, thus improving the firmware upgrade efficiency.

[0016] Fourthly, this application also provides another firmware upgrade device, including: an upgrade package generation module for generating a firmware upgrade package for the target firmware, wherein the firmware upgrade package includes multiple image files and the upgrade order of each image file; and an upgrade package sending module for sending the firmware upgrade package to a terminal device; wherein the firmware upgrade package is used to enable the terminal device to deploy each image file according to the upgrade method and upgrade order corresponding to each image file.

[0017] Fifthly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of the methods provided in the first and third aspects above.

[0018] Sixthly, this application also provides a chip, including a processor and a communication interface, wherein the processor is configured to cause the chip to perform the steps of the methods provided in the first and third aspects above.

[0019] In a seventh aspect, this application also provides a chip module, including a communication module, a power module, a storage module, and a chip, wherein: the power module is used to provide electrical energy to the chip module; the storage module is used to store data and instructions; the communication module is used to perform internal communication within the chip module, or to enable communication between the chip module and external devices; and the chip is used to perform the steps of the methods provided in the first and third aspects above.

[0020] Eighthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the methods provided in the first and third aspects above.

[0021] Ninthly, this application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the methods provided in the first and third aspects above. Attached Figure Description

[0022] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0023] Figure 1 This is a diagram illustrating the application environment of a firmware upgrade method in one embodiment.

[0024] Figure 2 This is a flowchart illustrating a firmware upgrade method in one embodiment;

[0025] Figure 3 This is a flowchart illustrating the successful deployment steps in one embodiment;

[0026] Figure 4 This is a flowchart illustrating the deployment failure steps in one embodiment;

[0027] Figure 5 This is a flowchart illustrating step 201 in one embodiment;

[0028] Figure 6 This is a timing flowchart of a firmware upgrade method in one embodiment;

[0029] Figure 7 This is a flowchart illustrating another firmware upgrade method in one embodiment;

[0030] Figure 8 This is a flowchart illustrating step 701 in one embodiment;

[0031] Figure 9 This is a flowchart illustrating the steps involved in creating a candidate upgrade package in one embodiment.

[0032] Figure 10 This is a structural block diagram of a firmware upgrade device in one embodiment;

[0033] Figure 11 This is a structural block diagram of another firmware upgrade device in one embodiment;

[0034] Figure 12 This is an internal structural diagram of a computer device in one embodiment;

[0035] Figure 13 This is an internal structure diagram of another computer device in one embodiment;

[0036] Figure 14 This is an internal structure diagram of a chip module in one embodiment. Detailed Implementation

[0037] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0038] It should be noted that the terms "first," "second," etc., used in this application can be used to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish the first element from the second element. The terms "comprising" and "having," and any variations thereof, used in this application, are intended to cover non-exclusive inclusion. The term "multiple" used in this application refers to two or more. The term "and / or" used in this application refers to one of the embodiments, or any combination of multiple embodiments.

[0039] The firmware upgrade method provided in this application embodiment can be applied to, for example, Figure 1 The application environment shown includes at least upgrade device 101 and terminal device 102.

[0040] The upgrade device 101 generates a firmware upgrade package based on external instructions and sends the firmware upgrade package to the terminal device 102. The upgrade device 101 can be a server, which can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing cloud computing services. The upgrade device 101 can also be configured with an interactive page, through which instructions can be input. Chips / chip modules can be configured in the server to implement the above functions.

[0041] Terminal device 102 receives firmware upgrade packages sent by upgrade device 101, determines the upgrade method and order corresponding to the image files in the firmware upgrade package, and deploys each image file according to the upgrade method and order to perform firmware upgrade. Terminal device 102 can be, but is not limited to, various personal computers, laptops, smartphones, tablets, drones, low-altitude aircraft, IoT devices, and portable wearable devices. IoT devices can include smart speakers, smart TVs, smart air conditioners, smart in-vehicle devices, projection devices, etc. Portable wearable devices can include smartwatches, smart bracelets, head-mounted devices, etc. Head-mounted devices can include virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, etc. Terminal device 102 can be configured with chips / chip modules to implement the above functions.

[0042] In one exemplary embodiment, such as Figure 2 As shown, a firmware upgrade method is provided, which can be applied to... Figure 1Terminal devices or applications Figure 1 The following steps are used as an example of a chip / chip module with data processing capabilities, including steps 201 to 203.

[0043] Step 201: Obtain the firmware upgrade package.

[0044] In this application, the firmware upgrade package is a file package used for firmware upgrades. The firmware upgrade package includes one or more image files, which can be used to upgrade the configuration in the firmware partition to achieve higher version functionality. The firmware upgrade package includes multiple image files and the upgrade order of these image files. In addition, the firmware upgrade package may also include multiple upgrade configuration files, each of which may include multiple image files. Each upgrade configuration file can be upgraded according to the method provided in this application to handle scenarios where multiple firmware are upgraded simultaneously; details will not be elaborated further here.

[0045] During implementation, the upgrade device generates a firmware upgrade package based on multiple image files, upgrade order, and / or upgrade sequence according to external instructions, and sends the firmware upgrade package to the terminal device; the terminal device receives the firmware upgrade package sent by the upgrade device.

[0046] During the process of creating firmware upgrade packages for upgraded devices, different firmware partitions may require different upgrade methods. Upgrade methods can be: full package, differential, compression, and encryption. Different upgrade methods correspond to different upgrade package creation strategies. The upgrade method corresponding to each image file can be determined according to external instructions, and candidate upgrade packages corresponding to each image file can be generated. Firmware upgrade packages are then generated based on each candidate upgrade package.

[0047] Step 202: For each image file, determine the corresponding upgrade method.

[0048] In this application, the upgrade method refers to the deployment method corresponding to the image file. During the firmware upgrade process, some version upgrades may be major version upgrades, which may require a full package upgrade, and the corresponding upgrade method is the full package upgrade method. Some version upgrades may be minor version upgrades, which may require a differential upgrade, and the corresponding upgrade method is the differential upgrade method. Some firmware has limited storage space, which may require compression of the upgrade package, and the corresponding upgrade method is the compressed upgrade method. Some firmware may have encrypted partitions, which may require encrypted upgrades, and the corresponding upgrade method is the encrypted upgrade method. Furthermore, it is also possible to upgrade multiple firmwares in the terminal device. The upgrade methods corresponding to different firmwares may be different. The specific upgrade methods can also be the full package, differential, compressed, and encrypted methods mentioned above, realizing the simultaneous performance of multiple different upgrade modes of firmware upgrades and improving the efficiency of firmware upgrades.

[0049] In one optional implementation provided by this application, the upgrade method includes at least one of the following: a full package upgrade method, which instructs the image file to contain an upgrade package with a complete firmware image, and performs a full-coverage upgrade of the target firmware; a differential upgrade method, which instructs the image file to contain an upgrade package with an incremental firmware image, and performs an incremental upgrade of the upgrade partition of the target firmware; a compressed upgrade method, which instructs the image file to be decompressed to obtain a decompressed image file, and deploys the decompressed image file; and an encrypted upgrade method, which instructs the target encrypted partition of the target firmware to be upgraded, or the encrypted upgrade method instructs the image file to be decrypted to obtain a decrypted image file, and deploys the decrypted image file. For example, a full package upgrade directly flashes the partition, a differential upgrade applies a patch, a compressed and decompressed upgrade is performed, and an encrypted and decrypted upgrade is performed. In this case, a full package upgrade is a complete image update, and a differential upgrade generates a new image incrementally based on the terminal's base version and the differential package, and flashes it into the flash memory.

[0050] During implementation, for each image file, the terminal device determines the corresponding upgrade configuration method; during execution, the terminal device can determine the upgrade method based on the image file's tags. For example, the upgrade method can be determined based on the image file's name.

[0051] Step 203: Deploy each image file according to the upgrade method and upgrade order.

[0052] During implementation, the terminal device deploys each image file sequentially according to the upgrade method and upgrade order corresponding to each image file to upgrade the firmware; during execution, the terminal device can execute the image file and write the configuration file in the image file to the corresponding partition to update the old version of the configuration file.

[0053] Among them, the full package upgrade method can be an overwrite upgrade of the complete firmware image based on the image file; the differential upgrade method can be an incremental upgrade of the incremental firmware image based on the image file; the compressed upgrade method can be to first decompress the image file and then deploy the decompressed image file; the encrypted upgrade method can be to upgrade the encrypted partition based on the image file, or to first decrypt the image file and then deploy the decrypted image file.

[0054] Furthermore, different upgrade processes can be set for different upgrade methods, and terminal devices can call different upgrade processes to deploy image files according to the upgrade method.

[0055] In the above firmware upgrade method, the firmware upgrade package created and sent by the upgrade device is obtained. The firmware upgrade package includes multiple image files and the upgrade order of each image file. For each image file, the corresponding upgrade method is determined. By flexibly setting the image files and upgrade methods of multiple partitions, flexible and fast firmware upgrade is achieved. Then, according to each upgrade method and upgrade order, each image file is deployed to complete the firmware upgrade, thereby improving the efficiency of firmware upgrade.

[0056] Based on the above exemplary embodiment, the following provides a firmware upgrade method in one or more exemplary embodiments, which is applied to... Figure 1 Taking the terminal device in the example, the explanation includes the following content.

[0057] In real-world scenarios, the deployment of image files may result in either success or failure. Similarly, firmware upgrades may also result in either success or failure. For each image file, an upgrade result flag can be generated based on the deployment result, and an upgrade success message or upgrade failure message can be generated based on the upgrade result flags of each image file. In one optional implementation provided in this application, such as... Figure 3 As shown, the method further includes steps 301 to 302:

[0058] Step 301: For each image file, generate an upgrade success marker after successful deployment.

[0059] During implementation, for each image file, the terminal device generates an upgrade success marker after the image file is successfully deployed to indicate that the image file has been successfully deployed.

[0060] Step 302: Generate an upgrade completion message based on the upgrade success markers for each image file, and display the upgrade completion message on the system interface.

[0061] During implementation, if all image files have a corresponding upgrade success marker, an upgrade completion message is generated based on the upgrade success marker of each image file and displayed on the system interface.

[0062] Furthermore, there is also the possibility of upgrade failure. In this case, failure of any image file to complete the upgrade will result in firmware upgrade failure. One optional implementation provided in this application is as follows: Figure 4 As shown, the method further includes steps 401 to 402:

[0063] Step 401: For each image file, generate an upgrade failure flag after a deployment failure.

[0064] During implementation, for each image file, if the terminal device detects that the deployment of the image file has failed, an upgrade failure flag is generated for that image file.

[0065] In real-world scenarios, the upgrade order of each image file may be fixed, and subsequent image files may be highly dependent on the deployment status of the current image file. To address this, the terminal device can generate an upgrade failure message and display it on the system interface after detecting an upgrade failure flag.

[0066] In addition, the upgrade configurations of each image file may not have dependencies, meaning that the success or failure of the current image file does not affect the deployment of the next image file. In this regard, the terminal device can continue to deploy the next image file after detecting the upgrade failure flag.

[0067] Step 402: Generate an upgrade failure message based on the upgrade failure flags of each image file, and display the upgrade failure message on the system interface.

[0068] During implementation, the terminal device acquires upgrade failure flags for all image files, generates upgrade failure messages for the corresponding image files based on each flag, and displays these messages on the system interface to inform the user which firmware upgrades were successful and which failed. Optionally, the upgrade failure message may include upgrade success messages for the image files corresponding to the success flags.

[0069] One optional implementation provided in this application improves user perception by generating upgrade success or upgrade failure messages by marking the upgrade as successful or failed after the image file upgrade is completed.

[0070] In the process of obtaining the firmware upgrade package, to save network resources, a compressed package may be sent. The compressed package can be decompressed to obtain the firmware upgrade package. In one optional implementation provided in this application, such as... Figure 5 As shown, step 201 includes steps 501 to 502:

[0071] Step 501: Receive the firmware upgrade package sent by the upgrade device, and decompress the firmware upgrade package to obtain the decompressed firmware upgrade package.

[0072] During the process, the upgrade device compresses the initial firmware upgrade package and sends it to the terminal device; the terminal device receives the firmware upgrade package sent by the upgrade device, decompresses the firmware upgrade package, and obtains the decompressed firmware upgrade package.

[0073] Step 502: Extract the image files and upgrade order included in the decompressed firmware upgrade package.

[0074] During implementation, the terminal device extracts the image files included in the decompressed firmware upgrade package and reads the upgrade order of each image file.

[0075] One optional implementation method provided in this application transmits the firmware upgrade package through compressed transmission, which saves network resources, thereby accelerating transmission efficiency and improving firmware upgrade efficiency.

[0076] The above one or more embodiments can be executed by a terminal device, and the following one or more embodiments of another firmware upgrade method can be executed by an upgrade device. The two can cooperate with each other during execution. Therefore, when reading the above one or more embodiments executed by a terminal device, one or more embodiments executed by an upgrade device can be referred to below. The embodiments of the two can be combined according to usage requirements to form new embodiments.

[0077] In one embodiment, see Figure 6 The diagram illustrates a timing flow of a firmware upgrade method provided in an embodiment of this application. This firmware upgrade method can be applied to... Figure 1 In the terminal device shown. For example... Figure 6 As shown, the firmware upgrade method may include the following steps:

[0078] Step 606: Receive the firmware upgrade package sent by the upgrade device, and decompress the firmware upgrade package to obtain the decompressed firmware upgrade package.

[0079] Step 607: Extract the image files and upgrade order included in the decompressed firmware upgrade package.

[0080] Step 608: For each image file, determine the corresponding upgrade method and deploy each image file according to the upgrade method and upgrade order.

[0081] Step 609: For each image file, generate an upgrade success flag after successful deployment, or generate an upgrade failure flag after deployment failure.

[0082] Step 610: Generate an upgrade result message based on the upgrade failure flag and / or upgrade success flag of each image file, and display the upgrade result message on the system interface.

[0083] It should be noted that any one or more of steps 606 to 610 can be combined to form a new implementation method according to the needs of implementation and deployment. Furthermore, any one or more technical features in the technical solution composed of steps 606 to 610 can also be combined to form a new implementation method according to the actual deployment needs, or technical features in one or more optional implementations provided by one or more of the above embodiments can be combined to form a new implementation method. These will not be elaborated on here.

[0084] It should also be noted that steps 606 to 610 above can be executed by the terminal device, while steps 601 to 605 below can be executed by the upgrade device. The two can cooperate with each other during execution. Therefore, when reading steps 606 to 610 above, you can refer to steps 601 to 605 below executed by the upgrade device, and vice versa.

[0085] In one exemplary embodiment, such as Figure 7 As shown, another firmware upgrade method is provided, which can be applied to... Figure 1 Upgraded equipment or applications Figure 1 The following steps are used as an example of a chip / chip module with data processing capabilities, including steps 701 to 702.

[0086] Step 701: Generate the firmware upgrade package for the target firmware.

[0087] During the implementation process, the upgrade device generates a firmware upgrade package for the target firmware according to external instructions; the firmware upgrade package includes multiple image files and the upgrade order of each image file.

[0088] During the process, each image file has a different upgrade method. The upgrade device can generate a firmware upgrade package for the target firmware based on the upgrade method, upgrade order, and each image file.

[0089] Step 702: Send the firmware upgrade package to the terminal device.

[0090] During implementation, the upgrade device sends a firmware upgrade package to the terminal device; the firmware upgrade package is used to enable the terminal device to deploy each image file according to the upgrade method and upgrade order corresponding to each image file.

[0091] Another firmware upgrade method provided in this application involves an upgrade device creating a firmware upgrade package containing multiple image files and an upgrade order according to instructions, and sending the firmware upgrade package to the terminal device. By setting the upgrade method of each image file at the creation end, the upgrade method of each partition of the target firmware can be flexibly configured, thereby enabling upgrades to multiple partitions at once and improving firmware upgrade efficiency.

[0092] Based on the above exemplary embodiment, another firmware upgrade method is provided in one or more exemplary embodiments below, in which the method is applied to Figure 1 Taking the upgraded equipment in the example, the following content will be explained.

[0093] During the firmware upgrade package generation process, users can input each image file through an interactive interface and enter the corresponding upgrade method for each image file. The upgrade device can then create the firmware upgrade package based on the input. In one optional implementation provided in this application, such as... Figure 8 As shown, step 701 includes steps 801 to 802:

[0094] Step 801: Obtain each image file and the corresponding upgrade method through the interactive interface.

[0095] During implementation, users input each image file through the interactive interface and select / input the upgrade method for each image file; the upgrade device obtains each image file and its corresponding upgrade method through the interactive interface.

[0096] Step 802: Generate candidate upgrade packages corresponding to each image file according to each upgrade method, and generate firmware upgrade packages according to each candidate upgrade package.

[0097] During the implementation process, the upgrade device generates candidate upgrade packages corresponding to each image file according to each upgrade method, and packages each candidate upgrade package to generate a firmware upgrade package.

[0098] One optional implementation method provided in this application generates candidate upgrade packages for each image file by performing targeted upgrades and packaging for each image file, and integrates the candidate upgrade packages to obtain a firmware upgrade package. This integrates multiple upgrade methods, thereby improving firmware upgrade efficiency.

[0099] During the generation of candidate upgrade packages, different production strategies are used for different upgrade methods for each image file. Candidate upgrade packages can be generated based on the production strategy and the image file. One optional implementation provided in this application is as follows: Figure 9 As shown, the process of creating a candidate upgrade package includes steps 901 to 902:

[0100] Step 901: For each image file, determine the production strategy based on the upgrade method corresponding to the image file.

[0101] During implementation, for each image file, the upgrade device queries the creation strategy of the corresponding upgrade method; the creation strategy is used to characterize the creation method of the candidate upgrade package.

[0102] Step 902: Based on the production strategy and the image file, generate the candidate upgrade package corresponding to the image file.

[0103] During implementation, candidate upgrade packages corresponding to the image file are generated based on the production strategy and the image file.

[0104] It should be noted that the candidate upgrade packages can be produced in parallel, thereby improving the efficiency of upgrade package production.

[0105] One optional implementation method provided in this application is to create different candidate upgrade packages according to the upgrade method, and then perform firmware upgrades for multiple different upgrade modes through a single firmware upgrade package, thereby improving firmware upgrade efficiency.

[0106] In one embodiment, see Figure 6 The diagram illustrates a timing flow of a firmware upgrade method provided in an embodiment of this application. This firmware upgrade method can be applied to... Figure 1 The upgrade equipment shown. For example... Figure 6 As shown, the firmware upgrade method may include the following steps:

[0107] Step 601: Obtain each image file and the corresponding upgrade method through the interactive interface.

[0108] Step 602: For each image file, determine the production strategy based on the upgrade method corresponding to the image file.

[0109] Step 603: Based on the production strategy and the image file, generate the candidate upgrade package corresponding to the image file.

[0110] Step 604: Generate firmware upgrade packages based on each candidate upgrade package.

[0111] Step 605: Send the firmware upgrade package to the terminal device.

[0112] It should be noted that any one or more of steps 601 to 605, or any combination of steps 701 to 702 provided in the above embodiments, can be selected to form a new implementation method according to the needs of implementation and deployment. Furthermore, any one or more technical features in the technical solution composed of steps 601 to 605 can also be selected to form a new implementation method according to the actual deployment needs, or technical features from one or more optional implementations provided in one or more of the above embodiments can be selected to form a new implementation method. These will not be elaborated on here.

[0113] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages in other steps. It is understood that the steps in different embodiments can be freely combined as needed, and all non-contradictory solutions formed by such combinations are within the scope of protection of this application.

[0114] Based on the same inventive concept, this application also provides a firmware upgrade apparatus for implementing the firmware upgrade method described above. This apparatus can be applied to or integrated into a chip or chip module, for example. The solution provided by this apparatus is similar to the implementation scheme described in the above method; therefore, the specific limitations in one or more firmware upgrade apparatus embodiments provided below can be found in the limitations of the firmware upgrade method described above, and will not be repeated here.

[0115] In one exemplary embodiment, such as Figure 10 As shown, a firmware upgrade device is provided, including: an upgrade package acquisition module 1001, an upgrade method determination module 1002, and a file deployment module 1003, wherein: the upgrade package acquisition module 1001 is used to acquire a firmware upgrade package, which includes multiple image files and the upgrade order of each image file; the upgrade method determination module 1002 is used to determine the upgrade method corresponding to each image file; and the file deployment module 1003 is used to deploy each image file according to each upgrade method and upgrade order.

[0116] In one embodiment, the apparatus further includes an upgrade success unit and a completion message generation unit, wherein: the upgrade success unit is used to generate an upgrade success flag for each image file after successful deployment; the completion message generation unit is used to generate an upgrade completion message based on the upgrade success flag of each image file and display the upgrade completion message on the system interface.

[0117] In one embodiment, the apparatus further includes an upgrade failure unit and a failure message generation unit, wherein: the upgrade failure unit is used to generate an upgrade failure flag for each image file after deployment failure; the failure message generation unit is used to generate an upgrade failure message based on the upgrade failure flag of each image file and display the upgrade failure message on the system interface.

[0118] In one embodiment, the upgrade package acquisition module 1001 includes a receiving unit and an extraction unit, wherein: the receiving unit is used to receive the firmware upgrade package sent by the upgrade device, and decompress the firmware upgrade package to obtain the decompressed firmware upgrade package; the extraction unit is used to extract the image files and upgrade order included in the decompressed firmware upgrade package.

[0119] Based on the same inventive concept, this application also provides another firmware upgrade apparatus for implementing the aforementioned firmware upgrade method. This apparatus can be applied to or integrated into a chip or chip module, for example. The solution provided by this apparatus is similar to the implementation described in the above method; therefore, the specific limitations in one or more firmware upgrade apparatus embodiments provided below can be found in the limitations of the firmware upgrade method described above, and will not be repeated here.

[0120] In one exemplary embodiment, such as Figure 11 As shown, another firmware upgrade device is provided, including: an upgrade package generation module 1101, used to generate a firmware upgrade package for the target firmware, the firmware upgrade package including multiple image files and the upgrade order of each image file; and an upgrade package sending module 1102, used to send the firmware upgrade package to the terminal device; wherein, the firmware upgrade package is used to enable the terminal device to deploy each image file according to the upgrade method and upgrade order corresponding to each image file.

[0121] In one embodiment, the upgrade package generation module 1101 includes an upgrade method acquisition unit and an upgrade package creation unit, wherein: the upgrade method acquisition unit is used to acquire each image file and the upgrade method corresponding to each image file through an interactive interface; the upgrade package creation unit is used to generate candidate upgrade packages corresponding to each image file according to each upgrade method, and generate firmware upgrade packages according to each candidate upgrade package.

[0122] In one embodiment, the upgrade package production unit includes a production strategy determination unit and a candidate upgrade package generation unit, wherein: the production strategy determination unit is used to determine a production strategy for each image file according to the upgrade method corresponding to the image file, and the production strategy is used to characterize the production method of the candidate upgrade package; the candidate upgrade package generation unit is used to generate a candidate upgrade package corresponding to the image file according to the production strategy and the image file.

[0123] Regarding the modules / units included in the various devices and products described in the above embodiments, they can be software modules / units, hardware modules / units, or a combination of both. For example, for various devices and products applied to or integrated into a chip, all of their modules / units can be implemented using hardware methods such as circuits, or at least some modules / units can be implemented using software programs that run on a processor integrated within the chip, while the remaining (if any) modules / units can be implemented using hardware methods such as circuits; for various devices and products applied to or integrated into a chip module, all of their modules / units can be implemented using hardware methods such as circuits, and different modules / units can be located in the same component (e.g., chip, circuit module, etc.) or different components of the chip module, or at least some modules / units can be implemented using hardware methods such as circuits. The components can be implemented using software programs that run on the processor integrated within the chip module. The remaining (if any) modules / units can be implemented using hardware methods such as circuits. For various devices and products applied to or integrated into the terminal, each of its components / units can be implemented using hardware methods such as circuits. Different modules / units can be located in the same component (e.g., chip, circuit module, etc.) or in different components within the terminal. Alternatively, at least some modules / units can be implemented using software programs that run on the processor integrated within the terminal, while the remaining (if any) modules / units can be implemented using hardware methods such as circuits.

[0124] In one exemplary embodiment, a computer device is provided, which may be a terminal, and its internal structure diagram may be as follows: Figure 12As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, Near Field Communication (NFC), or other technologies. When the computer program is executed by the processor, it implements a firmware upgrade method. The display unit is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of the computer device can be a touch layer covering the display screen, or buttons, trackballs, or touchpads set on the casing of the computer device, or external keyboards, touchpads, or mice, etc.

[0125] Those skilled in the art will understand that Figure 12 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0126] In one exemplary embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor executes the computer program to perform the following steps: obtaining a firmware upgrade package, the firmware upgrade package including multiple image files and an upgrade order of each image file; determining the upgrade method corresponding to each image file for each image file; and deploying each image file according to each upgrade method and upgrade order.

[0127] In one embodiment, when the processor executes the computer program, it further performs the following steps: for each image file, after successful deployment, generates an upgrade success flag; generates an upgrade completion message based on the upgrade success flags of each image file, and displays the upgrade completion message on the system interface.

[0128] In one embodiment, when the processor executes the computer program, it further performs the following steps: for each image file, generating an upgrade failure flag after a deployment failure; generating an upgrade failure message based on the upgrade failure flags of each image file, and displaying the upgrade failure message on the system interface.

[0129] In one embodiment, when the processor executes the computer program, it further performs the following steps: receiving a firmware upgrade package sent by the upgrade device, decompressing the firmware upgrade package to obtain a decompressed firmware upgrade package; and extracting the image files and upgrade order included in the decompressed firmware upgrade package.

[0130] In one exemplary embodiment, another computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 13 As shown, this computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operating system and computer programs stored in the non-volatile storage media. The database stores firmware upgrade data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When the computer program is executed by the processor, it implements a firmware upgrade method.

[0131] Those skilled in the art will understand that Figure 13 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0132] In an exemplary embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor executes the computer program to perform the following steps: generating a firmware upgrade package for a target firmware, the firmware upgrade package including multiple image files and an upgrade order for each image file; sending the firmware upgrade package to a terminal device; wherein the firmware upgrade package is used to enable the terminal device to deploy each image file according to the upgrade method and upgrade order corresponding to each image file.

[0133] In one embodiment, when the processor executes the computer program, it further performs the following steps: obtaining each image file and the upgrade method corresponding to each image file through an interactive interface; generating candidate upgrade packages corresponding to each image file according to each upgrade method; and generating firmware upgrade packages according to each candidate upgrade package.

[0134] In one embodiment, when the processor executes the computer program, it further performs the following steps: for each image file, determining a production strategy based on the upgrade method corresponding to the image file, wherein the production strategy is used to characterize the production method of the candidate upgrade package; and generating a candidate upgrade package corresponding to the image file based on the production strategy and the image file.

[0135] Based on the same inventive concept, this application also provides a chip, including a processor and a communication interface; the communication interface is used to receive or send data; the processor is configured to cause the chip to perform the following steps: obtaining a firmware upgrade package, the firmware upgrade package including multiple image files and the upgrade order of each image file; for each image file, determining the upgrade method corresponding to the image file; and deploying each image file according to each upgrade method and upgrade order.

[0136] In one embodiment, the processor is configured to cause the chip to perform the following steps: for each image file, generate an upgrade success flag after successful deployment; generate an upgrade completion message based on the upgrade success flags of each image file, and display the upgrade completion message on the system interface.

[0137] In one embodiment, the processor is configured to cause the chip to perform the following steps: for each image file, generate an upgrade failure flag after a deployment failure; generate an upgrade failure message based on the upgrade failure flags of each image file, and display the upgrade failure message on the system interface.

[0138] In one embodiment, the processor is configured to cause the chip to perform the following steps: receiving a firmware upgrade package sent by an upgrade device, decompressing the firmware upgrade package to obtain a decompressed firmware upgrade package; and extracting the image files and upgrade order included in the decompressed firmware upgrade package.

[0139] Based on the same inventive concept, this application also provides another chip, including a processor and a communication interface; the communication interface is used to receive or send data; the processor is configured to cause the chip to perform the following steps: generating a firmware upgrade package for a target firmware, the firmware upgrade package including multiple image files and the upgrade order of each image file; sending the firmware upgrade package to a terminal device; wherein, the firmware upgrade package is used to enable the terminal device to deploy each image file according to the upgrade method and upgrade order corresponding to each image file.

[0140] In one embodiment, the processor is configured to cause the chip to perform the following steps: obtain each image file and the upgrade method corresponding to each image file through an interactive interface; generate candidate upgrade packages corresponding to each image file according to each upgrade method; and generate firmware upgrade packages according to each candidate upgrade package.

[0141] In one embodiment, the processor is configured to cause the chip to perform the following steps: for each image file, determine a manufacturing strategy based on the upgrade method corresponding to the image file, the manufacturing strategy being used to characterize the manufacturing method of the candidate upgrade package; and generate a candidate upgrade package corresponding to the image file based on the manufacturing strategy and the image file.

[0142] It is understood that the chip involved in the embodiments of this application may be a field-programmable gate array (FPGA), may be an application-specific integrated circuit (ASIC), may be a system on chip (SoC), may be a central processor unit (CPU), may be a network processor (NP), may be a digital signal processor (DSP), may be a microcontroller unit (MCU), may be a programmable logic device (PLD), or other integrated chips, etc.

[0143] Based on the same inventive concept, this application also provides a chip module, such as... Figure 14 As shown, the chip module includes a communication module, a power module, a storage module, and a chip. Among them:

[0144] The power module is used to provide power to the chip module; the storage module is used to store data and instructions; the communication module is used for internal communication within the chip module, or for communication between the chip module and external devices; this chip corresponds to the chip in the above chip embodiment.

[0145] The implementation of this chip module can be found in the relevant content of the above-mentioned chip embodiment or another chip embodiment, and will not be repeated here.

[0146] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps in one embodiment of the firmware upgrade method described above, or the steps in another embodiment of the firmware upgrade method described above.

[0147] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in one embodiment of the firmware upgrade method described above, or the steps in another embodiment of the firmware upgrade method described above.

[0148] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of the relevant data must comply with relevant regulations.

[0149] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0150] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0151] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A firmware upgrade method, characterized in that, Applied to a terminal device, the method includes: Obtain a firmware upgrade package, which includes multiple image files and the upgrade order of each image file; For each of the image files, determine the corresponding upgrade method for that image file; Deploy each of the described image files according to the described upgrade method and upgrade order.

2. The method according to claim 1, characterized in that, The upgrade method includes at least one of the following: The full package upgrade method is used to indicate that the image file contains an upgrade package containing a complete firmware image, and to perform a full-coverage upgrade on the target firmware; The differential upgrade method is used to instruct the upgrade partition of the target firmware to be incrementally upgraded according to the upgrade package containing the incremental firmware image in the image file; A compression upgrade method, wherein the compression upgrade method is used to instruct the image file to be decompressed to obtain a decompressed image file, and to deploy the decompressed image file; An encrypted upgrade method is used to instruct the target encrypted partition of the target firmware to be upgraded, or the encrypted upgrade method is used to instruct the image file to be decrypted to obtain a decrypted image file and to deploy the decrypted image file.

3. The method according to claim 1, characterized in that, The method further includes: For each of the aforementioned image files, an upgrade success marker is generated upon successful deployment; An upgrade completion message is generated based on the upgrade success marker of each of the aforementioned image files, and the upgrade completion message is displayed on the system interface.

4. The method according to claim 1, characterized in that, The method further includes: For each of the aforementioned image files, an upgrade failure flag is generated upon deployment failure; An upgrade failure message is generated based on the upgrade failure flag of each of the aforementioned image files, and the upgrade failure message is displayed on the system interface.

5. The method according to claim 1, characterized in that, The process of obtaining the firmware upgrade package includes: Receive the firmware upgrade package sent by the upgrade device, and decompress the firmware upgrade package to obtain the decompressed firmware upgrade package; Extract the image files and upgrade order included in the decompressed firmware upgrade package.

6. A firmware upgrade method, characterized in that, Applied to upgrading equipment, the method includes: Generate a firmware upgrade package for the target firmware, wherein the firmware upgrade package includes multiple image files and the upgrade order of each image file; Send the firmware upgrade package to the terminal device; The firmware upgrade package is used to enable the terminal device to deploy each of the image files according to the upgrade method and the upgrade order corresponding to each image file.

7. The method according to claim 6, characterized in that, The firmware upgrade package for generating the target firmware includes: The image files and their corresponding upgrade methods can be obtained through the interactive interface. Candidate upgrade packages corresponding to each of the aforementioned image files are generated according to each of the aforementioned upgrade methods, and the firmware upgrade package is generated according to each of the aforementioned candidate upgrade packages.

8. The method according to claim 7, characterized in that, The step of generating candidate upgrade packages corresponding to each of the aforementioned image files according to each of the aforementioned upgrade methods includes: For each image file, a production strategy is determined based on the upgrade method corresponding to the image file. The production strategy is used to characterize the production method of the candidate upgrade package. Based on the production strategy and the image file, a candidate upgrade package corresponding to the image file is generated.

9. A firmware upgrade device, characterized in that, The device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps of the method according to any one of claims 1 to 8.

10. A chip, characterized in that, The device includes a processor and a communication interface, the processor being configured to cause the chip to perform the steps of the method described in any one of claims 1 to 8.