TW202109336A - Method and apparatus for upgrading system in internet of things device, device, and storage medium - Google Patents

Method and apparatus for upgrading system in internet of things device, device, and storage medium Download PDF

Info

Publication number
TW202109336A
TW202109336A TW109118079A TW109118079A TW202109336A TW 202109336 A TW202109336 A TW 202109336A TW 109118079 A TW109118079 A TW 109118079A TW 109118079 A TW109118079 A TW 109118079A TW 202109336 A TW202109336 A TW 202109336A
Authority
TW
Taiwan
Prior art keywords
program
upgrade
internet
predetermined threshold
upgrades
Prior art date
Application number
TW109118079A
Other languages
Chinese (zh)
Inventor
李燕瓊
Original Assignee
香港商阿里巴巴集團服務有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 香港商阿里巴巴集團服務有限公司 filed Critical 香港商阿里巴巴集團服務有限公司
Publication of TW202109336A publication Critical patent/TW202109336A/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/61Installation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/4401Bootstrapping
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

Disclosed in embodiments of the present invention are a method and apparatus for upgrading a system in an Internet of Things device, a device, and a storage medium. The method comprises: checking whether an upgrade identifier exists; when an upgrade identifier exists, determining whether the upgrade count exceeds a first predetermined threshold; when determined that the upgrade count exceeds the first predetermined threshold, starting up a first system, and/or when determined that the upgrade count does not exceed the first predetermined threshold, attempting to start up a second system, the second system being a new system to be upgraded, and the version of the first system being lower than that of the second system. Thus, a previous version may be automatically rolled back to when a system cannot be upgraded.

Description

物聯網設備中的系統升級方法、裝置、設備及儲存媒體System upgrade method, device, equipment and storage medium in Internet of things equipment

本揭露涉及物聯網領域,特別涉及物聯網設備中的系統升級方法、裝置、設備及儲存媒體。This disclosure relates to the field of Internet of Things, and in particular to system upgrade methods, devices, equipment and storage media in Internet of Things equipment.

隨著物聯網的縱深發展,數十億甚至數百億的物聯網設備通過聯網存取雲服務網,與此同時物聯網設備開發週期、新功能的發佈逐漸加快,聯網設備的售後成本問題也越來越突出,促使利用OTA(Over-the-Air Technology,空中下載技術)對物聯網設備進行遠端升級變得越來越迫切。 然而當前物聯網設備升級方案比較匱乏,普遍使用原地升級,這種升級方式造成的安全問題非常突出,若升級新版本系統軟體後新版本不工作,系統存在變磚永遠無法恢復的風險。 因此,需要一種能夠應對物聯網設備的升級風險的升級方案。With the in-depth development of the Internet of Things, billions or even tens of billions of Internet of Things devices access the cloud service network through the Internet. At the same time, the development cycle of Internet of Things devices and the release of new functions are gradually accelerating, and the after-sales cost of Internet devices is problematic. It is also becoming more and more prominent, prompting the use of OTA (Over-the-Air Technology, over-the-air download technology) to remotely upgrade IoT devices becomes more and more urgent. However, the current Internet of Things equipment upgrade solutions are relatively scarce, and in-situ upgrades are commonly used. The security problems caused by this upgrade method are very prominent. If the new version of the system software does not work after upgrading the new version of the system software, there is a risk that the system will never be restored after being bricked. Therefore, there is a need for an upgrade solution that can deal with the upgrade risk of IoT devices.

本揭露要解決的一個技術問題是,提供一種能夠應對物聯網設備的升級風險的升級方案。 根據本揭露的第一個態樣,提出了一種物聯網設備中的系統升級方法,包括:檢查是否存在升級標識;在存在升級標識的情況下,判斷升級次數是否超過第一預定臨限值;在判定升級次數超過第一預定臨限值的情況下,啟動第一系統,並且/或者在判定升級次數未超過第一預定臨限值的情況下,嘗試啟動第二系統,其中,第二系統為待升級的新系統,第一系統的版本低於第二系統。 可選地,該系統升級方法還包括:在不存在升級標識的情況下,啟動第一系統。 可選地,該系統升級方法還包括:在嘗試啟動第二系統的情況下,將升級次數加一。 可選地,該系統升級方法還包括:在成功啟動第二系統的情況下,清除升級標識及/或升級次數。 可選地,該系統升級方法還包括:設置計時器,計時器用於回應於計時超過第二預定臨限值觸發系統升級方法的執行,或者觸發第一系統的啟動。 可選地,該系統升級方法還包括:在成功啟動第二系統的情況下,迴圈執行如下操作:在計時器的計時超過第二預定臨限值之前,重置計時。 可選地,該系統升級方法還包括:回應於接收到伺服器下發的升級檔或升級指令,產生升級標識。 可選地,啟動第一系統的步驟包括:啟動升級前運行的系統;或者根據系統穩定性,從第二系統之前多個版本的系統中選擇一個版本的系統進行啟動。 可選地,物聯網設備為以下至少一項:車輛;個人數位助理終端;感測器;智慧家居設備。 可選地,物聯網設備的儲存區被劃分為第一區、第二區、第三區以及第四區,第一區用於儲存引導載入程式,引導載入程式用於執行系統升級方法,第二區用於儲存第一系統,第三區用於儲存第二系統;第四區用於儲存升級標識及/或升級次數。 根據本揭露的第二個態樣,還提出了一種物聯網設備中的系統升級方法,包括:設置引導載入程式,引導載入程式被配置為:回應於物聯網設備上電啟動,執行如本揭露第一個態樣述及的系統升級方法。 根據本揭露的第三個態樣,還提出了一種物聯網設備中的系統升級方法,包括:回應於系統升級請求,嘗試啟動第二系統;在第二系統啟動失敗或者第二系統啟動失敗次數超過第一預定臨限值的情況下,啟動第一系統,其中,第二系統為待升級的新系統,第一系統的版本低於第二系統。 根據本揭露的第四個態樣,還提出了一種物聯網設備中的程式升級方法,包括:檢查是否存在升級標識;在存在升級標識的情況下,判斷升級次數是否超過第一預定臨限值;在判定升級次數超過第一預定臨限值的情況下,啟動第一程式,並且/或者在判定升級次數未超過第一預定臨限值的情況下,嘗試啟動第二程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。 根據本揭露的第五個態樣,還提出了一種物聯網設備中的程式升級方法,包括:設置引導載入程式,引導載入程式被配置為:回應於物聯網設備上電啟動,執行如本揭露第四個態樣述及的程式升級方法。 根據本揭露的第六個態樣,還提出了一種物聯網設備中的程式升級方法,包括:回應於程式升級請求,嘗試啟動第二程式;在第二程式啟動失敗或者第二程式啟動失敗次數超過第一預定臨限值的情況下,啟動第一程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。 根據本揭露的第七個態樣,還提出了一種物聯網設備中的系統升級裝置,包括:檢查模組,用於檢查是否存在升級標識;判斷模組,用於在存在升級標識的情況下,判斷升級次數是否超過第一預定臨限值;第一啟動模組,用於在判斷模組判定升級次數超過第一預定臨限值的情況下,啟動第一系統,及/或第二啟動模組,用於在判斷模組判定升級次數未超過第一預定臨限值的情況下,嘗試啟動第二系統,其中,第二系統為待升級的新系統,第一系統的版本低於第二系統。 根據本揭露的第八個態樣,還提出了一種物聯網設備中的系統升級裝置,包括:設置模組,用於設置引導載入程式,引導載入程式被配置為:回應於物聯網設備上電啟動,執行如本揭露第一個態樣述及的系統升級方法。 根據本揭露的第九個態樣,還提出了一種物聯網設備中的系統升級裝置,包括:第二啟動模組,用於回應於系統升級請求,嘗試啟動第二系統;第一啟動模組,用於在第二系統啟動失敗或者第二系統啟動失敗次數超過預定臨限值的情況下,啟動第一系統,其中,第二系統為待升級的新系統,第一系統的版本低於第二系統。 根據本揭露的第十個態樣,還提出了一種物聯網設備中的程式升級裝置,包括:檢查模組,用於檢查是否存在升級標識;判斷模組,用於在存在升級標識的情況下,判斷升級次數是否超過第一預定臨限值;第一啟動模組,用於在判斷模組判定升級次數超過第一預定臨限值的情況下,啟動第一程式,及/或第二啟動模組,用於在判斷模組判定升級次數未超過第一預定臨限值的情況下,嘗試啟動第二程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。 根據本揭露的第十一個態樣,還提出了一種物聯網設備中的程式升級裝置,包括:設置模組,用於設置引導載入程式,引導載入程式被配置為:回應於物聯網設備上電啟動,執行如本揭露第四個態樣述及的程式升級方法。 根據本揭露的第十二個態樣,還提出了一種物聯網設備中的程式升級裝置,包括:第二啟動模組,用於回應於程式升級請求,嘗試啟動第二程式;第一啟動模組,用於在第二程式啟動失敗或者第二程式啟動失敗次數超過第一預定臨限值的情況下,啟動第一程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。 根據本揭露的第十三個態樣,還提出了一種計算設備,包括:處理器;以及記憶體,其上儲存有可執行代碼,當可執行代碼被處理器執行時,使處理器執行如本揭露第一個態樣至第六個態樣中任一個態樣述及的方法。 根據本揭露的第十四個態樣,還提出了一種非暫時性機器可讀儲存媒體,其上儲存有可執行代碼,當可執行代碼被電子設備的處理器執行時,使處理器執行如本揭露第一個態樣至第六個態樣中任一個態樣述及的方法。 本揭露支援物聯網設備中的系統升級,並可以在系統升級失敗或升級次數超過預定臨限值時,自動回滾到之前版本,從而可以消除物聯網設備的升級風險。A technical problem to be solved by this disclosure is to provide an upgrade solution that can deal with the upgrade risk of IoT devices. According to the first aspect of the present disclosure, a system upgrade method in an IoT device is proposed, which includes: checking whether there is an upgrade mark; if there is an upgrade mark, judging whether the number of upgrades exceeds a first predetermined threshold; In the case where it is determined that the number of upgrades exceeds the first predetermined threshold, the first system is started, and/or in the case where it is determined that the number of upgrades does not exceed the first predetermined threshold, the second system is tried to be started, wherein the second system For the new system to be upgraded, the version of the first system is lower than that of the second system. Optionally, the system upgrade method further includes: in the case that there is no upgrade identifier, starting the first system. Optionally, the system upgrade method further includes: in the case of trying to start the second system, adding one to the number of upgrades. Optionally, the system upgrade method further includes: in the case of successfully starting the second system, clearing the upgrade identifier and/or the number of upgrades. Optionally, the system upgrade method further includes: setting a timer, and the timer is used to trigger the execution of the system upgrade method in response to the timing exceeding the second predetermined threshold, or to trigger the activation of the first system. Optionally, the system upgrade method further includes: in the case of successfully starting the second system, performing the following operations in a loop: resetting the timing before the timing of the timer exceeds the second predetermined threshold. Optionally, the system upgrade method further includes: generating an upgrade identifier in response to receiving an upgrade file or an upgrade instruction issued by the server. Optionally, the step of starting the first system includes: starting the system that was running before the upgrade; or according to the stability of the system, selecting a version of the system from the previous versions of the second system to start. Optionally, the IoT device is at least one of the following: a vehicle; a personal digital assistant terminal; a sensor; a smart home device. Optionally, the storage area of the Internet of Things device is divided into a first area, a second area, a third area, and a fourth area. The first area is used to store the boot loader, and the boot loader is used to execute the system upgrade method. , The second area is used to store the first system, the third area is used to store the second system; the fourth area is used to store the upgrade identification and/or the number of upgrades. According to the second aspect of this disclosure, a system upgrade method in an IoT device is also proposed, which includes: setting a boot loader, the boot loader is configured to respond to the startup of the IoT device and execute such as The system upgrade method mentioned in the first aspect of this disclosure. According to the third aspect of the present disclosure, a system upgrade method in an IoT device is also proposed, which includes: responding to a system upgrade request, trying to start the second system; when the second system fails to start or the number of times the second system fails to start When the first predetermined threshold is exceeded, the first system is started, where the second system is a new system to be upgraded, and the version of the first system is lower than the second system. According to the fourth aspect of this disclosure, a program upgrade method in IoT devices is also proposed, which includes: checking whether there is an upgrade mark; if there is an upgrade mark, judging whether the number of upgrades exceeds the first predetermined threshold ; When it is determined that the number of upgrades exceeds the first predetermined threshold, the first program is started, and/or when it is determined that the number of upgrades does not exceed the first predetermined threshold, try to start the second program, where the second The program is a new program to be upgraded, and the version of the first program is lower than the second program. According to the fifth aspect of this disclosure, a program upgrade method in IoT devices is also proposed, which includes: setting a boot loader. The boot loader is configured to respond to the startup of the IoT device and execute such as The program upgrade method mentioned in the fourth aspect of this disclosure. According to the sixth aspect of this disclosure, a program upgrade method in IoT devices is also proposed, including: responding to a program upgrade request, attempting to start the second program; when the second program fails to start or the number of times the second program fails to start When the first predetermined threshold is exceeded, the first program is started, where the second program is a new program to be upgraded, and the version of the first program is lower than the second program. According to the seventh aspect of this disclosure, a system upgrade device in an Internet of Things device is also proposed, which includes: a check module for checking whether there is an upgrade mark; a judgment module for when there is an upgrade mark , Determine whether the number of upgrades exceeds the first predetermined threshold; the first activation module is used to activate the first system and/or the second activation when the judgment module determines that the number of upgrades exceeds the first predetermined threshold The module is used to try to start the second system when the module determines that the number of upgrades does not exceed the first predetermined threshold, where the second system is a new system to be upgraded, and the version of the first system is lower than the first Two systems. According to the eighth aspect of this disclosure, a system upgrade device in an IoT device is also proposed, including: a setting module for setting a boot loader, and the boot loader is configured to respond to the IoT device Power on and start, and execute the system upgrade method described in the first aspect of this disclosure. According to the ninth aspect of the present disclosure, a system upgrade device in an Internet of Things device is also proposed, which includes: a second activation module for responding to a system upgrade request to try to activate the second system; and a first activation module , Used to start the first system when the second system fails to start or the number of times the second system fails to start exceeds a predetermined threshold, where the second system is a new system to be upgraded, and the version of the first system is lower than the first system Two systems. According to the tenth aspect of this disclosure, a program upgrade device in Internet of Things equipment is also proposed, including: a check module for checking whether there is an upgrade logo; a judging module for when there is an upgrade logo , To determine whether the number of upgrades exceeds the first predetermined threshold; the first activation module is used to activate the first program and/or the second activation when the judgment module determines that the number of upgrades exceeds the first predetermined threshold The module is used to try to start the second program when the module determines that the number of upgrades does not exceed the first predetermined threshold, where the second program is a new program to be upgraded, and the version of the first program is lower than the first Two programs. According to the eleventh aspect of the present disclosure, a program upgrade device in the Internet of Things device is also proposed, including: a setting module for setting a boot loader, the boot loader is configured to respond to the Internet of Things The device is powered on and starts, and executes the program upgrade method described in the fourth aspect of this disclosure. According to the twelfth aspect of this disclosure, a program upgrade device in an Internet of Things device is also proposed, which includes: a second activation module, which is used to respond to a program upgrade request and try to activate the second program; and the first activation module Group, used to start the first program when the second program failed to start or the number of second program failed to start exceeds the first predetermined threshold, where the second program is a new program to be upgraded, the version of the first program Lower than the second formula. According to the thirteenth aspect of the present disclosure, a computing device is also proposed, including: a processor; and a memory, on which executable code is stored. When the executable code is executed by the processor, the processor executes such as This disclosure discloses the method described in any one of the first aspect to the sixth aspect. According to the fourteenth aspect of the present disclosure, a non-transitory machine-readable storage medium is also proposed, on which executable code is stored. When the executable code is executed by the processor of the electronic device, the processor executes such as This disclosure discloses the method described in any one of the first aspect to the sixth aspect. This disclosure supports system upgrades in IoT devices, and can automatically roll back to the previous version when the system upgrade fails or the number of upgrades exceeds a predetermined threshold, thereby eliminating the upgrade risk of IoT devices.

下面將參照附圖更詳細地描述本揭露的優選實施方式。雖然附圖中顯示了本揭露的優選實施方式,然而應該理解,可以以各種形式實現本揭露而不應被這裡闡述的實施方式所限制。相反,提供這些實施方式是為了使本揭露更加透徹和完整,並且能夠將本揭露的範圍完整地傳達給本領域的技術人員。 圖1示出了物聯網設備與伺服器間的通信流程圖。 本揭露述及的物聯網設備100可以是但不限於PDA (Personal Digital Assistant,個人數位助理)智慧終端機、車輛(如無人汽車)、感測器、智慧家居設備(如可以包括但不限於智慧音箱、掃地機器人、智慧燈泡、智慧開關、智慧門鎖)等。其中PDA智慧終端機可以是但不限於快件跟蹤掃描記錄儀,用於實現零售開單、列印小票、盤點、資料上傳和日結等一種或多種功能的移動POS機。 物聯網(Internet of Things,簡稱IoT),即“萬物相連的網際網路”是網際網路基礎上的延伸和擴充的網路,將各種資訊感測設備與網際網路結合起來而形成的一個巨大網路,實現在任何時間、任何地點,人、機、物的互聯互通。物聯網設備100可以通過物聯網與伺服器通信,也可以通過物聯網與其他物聯網設備連接。 如圖1所示,物聯網設備100可以利用OTA(Over-the-Air Technology,空中下載技術)進行遠端升級。例如,物聯網設備100可以通過網路從伺服器200獲取更新檔,以實現物聯網設備100的遠端升級。其中網路可以是但不限於無線通訊網路、網際網路、私域網、區域網路、都會區網路、廣域網路或是蜂巢式資料網路等。 在物聯網設備100利用OTA進行遠端升級的過程中,不可避免地會出現因升級檔錯誤或其他原因導致升級失敗的情況發生。 為了使得系統升級失敗時,物聯網設備100能夠自動回滾到之前的版本,不影響設備的正常使用,本揭露提出了一種支援升級失敗自動回滾到之前版本的系統升級方案。本揭露主要是設置引導載入程式,基於引導載入程式引導系統升級並提供升級失敗情況下的應對處理。本揭露述及的引導載入程式可以視為設備加電後運行的第一段軟體代碼,其中引導載入程式可以實現為一種韌體,例如可以是Bootloader韌體。 物聯網設備上電啟動後,可以首先啟動引導載入程式,由引導載入程式執行本揭露的系統升級方法,實現系統升級及升級失敗情況下的應對處理。 圖2示出了物聯網設備的儲存區佈局結構示意圖。 如圖2所示,物聯網設備的儲存區可以劃分為第一區、第二區、第三區以及第四區。其中這裡述及的劃分不代表執行實際的劃分動作,而可以是指邏輯上的劃分。 第一區用於儲存引導載入程式,引導載入程式用於執行本揭露的系統升級方法,引導啟動整個系統。 第二區用於儲存第一系統,第三區用於儲存第二系統,其中第二系統為待升級的新系統,第一系統的版本低於第二系統,第一系統可以視為舊系統。第一系統可以是指升級新系統前設備運行過的系統,第二區可以儲存一個或多個版本低於第二系統的舊系統。 第四區用於儲存升級標識、升級次數等升級參數。其中,第四區定義的參數設計為引導載入程式和系統程式進行共用的資料橋樑,可以相互配合完成對系統啟動失敗的自動判斷。 作為示例,在新系統成功啟動後,可以將第二區中的舊系統替換為新系統,並清空第三區,以等待新的升級系統的到來。 另外在新系統成功啟動後,也可以在不刪除第二區中儲存的舊系統的情況下,將新系統添加到第二區,由此第二區中可以儲存多個設備運行過的系統。 圖3示出了根據本揭露一實施例的物聯網設備中的系統升級方法的示意性流程圖。 如圖3所示,物聯網設備上電啟動後,首先啟動引導載入程式,在引導載入程式的引導作用下,實現整個系統升級方法的執行。 在步驟S110,可以由引導載入程式設置計時器,也即初始化計時器。 計時器用於計時,並回應於計時超過預定臨限值(為了便於分區,可以稱為第二預定臨限值)觸發本揭露的系統升級方法的執行(也即觸發引導載入程式的重啟),或者觸發第一系統的啟動。其中計時器可以實現為一種硬體模組,如可以實現為硬體看門狗。 在本實施例中,第一系統可以是升級前運行的系統,如可以是第二系統的上一個版本的系統。另外第一系統也可以是從第二系統之前多個版本的系統中選擇的一個版本的系統,也即第一系統可以是從第二區儲存的多個舊系統中選擇的一個系統。 在步驟S120,檢查是否存在升級標識。 升級標識用於表徵物聯網設備當前是否存在升級需求,升級標識可以是回應於接收到伺服器下發的升級檔或升級指令而產生的識別字。關於升級標識的具體表示形式,本揭露不再贅述。 在不存在升級標識的情況下,表明物聯網設備當前無需升級,可以執行步驟S190,啟動第一系統。作為示例,在執行步驟S190時,可以啟動升級前運行的系統,也可以根據統計得到的各個版本的系統穩定性,從第二系統之前多個版本的系統中選擇穩定性較好的版本的系統進行啟動。 在存在升級標識的情況下,表明物聯網設備當前存在升級需求,可以執行步驟S130,判斷升級次數是否超過預定臨限值N(為了便於分區,可以稱為第一預定臨限值)。此處述及的升級次數是指嘗試啟動待升級的新系統的次數,也即失敗次數。第一預定臨限值的大小可以根據實際情況設定。 如上文結合圖1所述,第四區用於儲存升級標識、升級次數等參數,因此在執行步驟S120、步驟S130時,均可以從第四區獲取升級標識、升級次數,實現升級標識的尋找、升級次數的判斷等操作。 在判定升級次數超過第一預定臨限值的情況下,表明失敗次數過多,無法升級成功,此時可以執行步驟S190,啟動第一系統。 在判定升級次數不超過第一預定臨限值的情況下,可以執行步驟S140、步驟S150,將升級次數加1並嘗試啟動新系統。 在執行完步驟S150後,可以判斷是否成功啟動。 在第二系統能夠正常運行的情況下可以認為啟動成功,也即升級成功。在第二系統啟動過程中出錯(如拋出錯誤)或者啟動耗時(也即升級耗時)超過第三預定臨限值的情況下,可以認為啟動失敗。 在未成功啟動新系統的情況下,可以執行步驟S195,使計時器超時,進而觸發引導載入程式的重新開機。可選地,在未成功啟動的情況下,也可以通過執行步驟S195使計時器超時,觸發第一系統的啟動。 在成功啟動新系統的情況下,可以執行步驟S170,迴圈執行如下操作:在計時器的計時超過第二預定臨限值之前,重置計時。通過迴圈對計時器的計時清零,可以避免在新系統能夠正常運行的情況下,因計時器超時而重啟引導載入程式或回滾到第一系統。其中,在計時器是看門狗的情況下,步驟S170也即對看門狗進行自動餵狗。可選地,步驟S170可以由成功啟動後的新系統執行。 在本揭露中,可以在計時器的配合下實現系統升級失敗情況下本揭露的系統升級方法(也即引導載入程式)的重啟。可選地計時器還可以用於在第二系統的啟動耗時超過第二預定臨限值的情況下,自動回滾到第一系統。 另外在成功啟動的情況下,還可以執行步驟S180,清除升級標識及/或升級次數。由此,在執行完步驟S180後,成功啟動後的新系統就可以作為當前運行系統運行,此後在物聯網設備需要再次升級的情況下,當前運行的系統可以作為第一系統,待升級的新系統可以作為新的第二系統,再次執行圖3所示的流程,實現系統升級。 綜上,本揭露可以在引導載入程式的作用下初始化計時器,並引導啟動新系統,在成功啟動新系統後,可以迴圈重置計時器的計時,避免系統重啟。而在新系統啟動失敗時,可以由計時器觸發系統重啟,重新在引導載入程式的作用下執行本揭露的升級方法,在失敗次數(也即升級次數)超過第一預定臨限值時,自動回滾到舊系統。 本揭露還提出了另一種物聯網設備中的系統升級方法,包括:設置引導載入程式,引導載入程式被配置為:執行上文結合圖3所示的系統升級方法。 本揭露還提出了另一種物聯網設備中的系統升級方法,包括:回應於系統升級請求,嘗試啟動第二系統;在第二系統啟動失敗或者第二系統啟動失敗次數超過第一預定臨限值的情況下,啟動第一系統。關於第一系統、第二系統可以參見上文相關描述,此處不再贅述。系統升級請求也即物聯網設備的系統升級需求,可以通過檢查是否存在升級標識的方式判斷是否存在系統升級需求,關於升級標識可以參見上文相關描述,此處也不再贅述。 在第二系統啟動失敗的情況下,可以將失敗次數(也即上文述及的啟動次數)加1,然後再次嘗試啟動第二系統,如此在失敗次數超過第一預定臨限值時,不再嘗試啟動第二系統,而是啟動第一系統。 在本實施例中,可以在第二系統超過第三預定臨限值未啟動成功的情況下,判定第二系統啟動失敗。也即本揭露可以根據第二系統啟動耗時來觸發重新升級或回滾到第一系統。 作為示例,可以通過設置計時器,來實現系統第二系統啟動失敗或者第二系統啟動失敗次數超過預定臨限值時,自動回滾到第一系統。例如,計時器可以被設置為,回應於計時超過第二預定臨限值,觸發第一系統的啟動,引導載入程式可以在啟動第二系統失敗或者失敗次數超過第一預定臨限值時,使計時器超時,以回滾到第一系統。 以物聯網設備為快件跟蹤掃描記錄儀、移動POS機為例,上文述及的第一系統/第二系統可以是指即時作業系統(RTOS)。RTOS是指當外界事件或資料產生時,能夠接受並以足夠快的速度予以處理,其處理的結果又能在規定的時間之內來控制生產過程或對處理系統作出快速回應,並控制所有即時任務協調一致運行的作業系統。 至此,就本揭露的物聯網設備中的系統升級方法做了詳細說明。本揭露還可以實現為一種針對物聯網設備中的其他非系統程式的升級的程式升級方法。也即上文述及的第一系統/第二系統也可以替換為運行在物聯網設備中的第一程式/第二程式。 下面就本揭露的物聯網設備中的程式升級方法的流程進行示例性說明,關於方案涉及的細節均可以參見上文相關描述,此處不再贅述。 公開的物聯網設備中的程式升級方法,可以包括:檢查是否存在升級標識;在存在升級標識的情況下,判斷升級次數是否超過第一預定臨限值;在判定升級次數超過第一預定臨限值的情況下,啟動第一程式,並且/或者在判定升級次數未超過第一預定臨限值的情況下,嘗試啟動第二程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。也即本揭露還可以用於對物聯網設備中非系統程式的升級,其中關於方法涉及的細節可以參見上文相關描述,此處不再贅述。 公開的物聯網設備中的程式升級方法,還可以包括:設置引導載入程式,引導載入程式被配置為:執行上文述及的程式升級方法。 公開的物聯網設備中的程式升級方法,還可以包括:回應於程式升級請求,嘗試啟動第二程式;在第二程式啟動失敗或者第二程式啟動失敗次數超過第一預定臨限值的情況下,啟動第一程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。 圖4示出了根據本揭露一個實施例的物聯網設備中的升級裝置的結構示意圖。其中,升級裝置的功能模組可以由實現本揭露原理的硬體、軟體或硬體和軟體的結合來實現。本領域技術人員可以理解的是,圖4所描述的功能模組可以組合起來或者劃分成子模組,從而實現上述發明的原理。因此,本文的描述可以支持對本文描述的功能模組的任何可能的組合、或者劃分、或者更進一步的限定。 下面就升級裝置可以具有的功能模組以及各功能模組可以執行的操作做簡要說明,對於其中涉及的細節部分可以參見上文相關描述,這裡不再贅述。 參見圖4,升級裝置400包括檢查模組410、判斷模組420、第一啟動模組430及/或第二啟動模組440。 在本揭露的一個實施例中,升級裝置400用於實現物聯網設備中的系統升級。 檢查模組410用於檢查是否存在升級標識。 在不存在升級標識的情況下,可以由第一啟動模組430啟動第一系統。第一啟動模組430可以啟動升級前運行的系統,或者也可以根據系統穩定性,從第二系統之前多個版本的系統中選擇一個版本的系統進行啟動。 在存在升級標識的情況下,可以由判斷模組420判斷升級次數是否超過第一預定臨限值。 在判斷模組420判定升級次數超過第一預定臨限值的情況下,可以由第一啟動模組430啟動第一系統。 在判斷模組420判定升級次數未超過第一預定臨限值的情況下,可以由第二啟動模組440嘗試啟動第二系統。 升級裝置400還可以包括累加模組,用於在第二啟動模組440嘗試啟動第二系統的情況下,將升級次數加一。 升級裝置400還可以包括清除模組,用於在第二啟動模組440成功啟動第二系統的情況下,清除升級標識及/或升級次數。 升級裝置400還可以包括計時器,計時器用於回應於計時超過第二預定臨限值觸發系統升級方法的執行,或者觸發第一系統的啟動。 升級裝置400還可以包括重置模組,用於在第二啟動模組440成功啟動第二系統的情況下,迴圈執行如下操作:在計時器的計時超過第二預定臨限值之前,重置計時。 升級裝置400還可以包括產生模組,用於回應於接收到伺服器下發的升級檔或升級指令,產生升級標識。 在本揭露的另一個實施例中,升級裝置400用於實現物聯網設備中的程式升級。 檢查模組410用於檢查是否存在升級標識。 在不存在升級標識的情況下,可以由第一啟動模組430啟動第一程式。第一啟動模組430可以啟動升級前運行的程式,或者也可以根據程式穩定性,從第二程式之前多個版本的程式中選擇一個版本的程式進行啟動。 在存在升級標識的情況下,可以由判斷模組420判斷升級次數是否超過第一預定臨限值。 在判斷模組420判定升級次數超過第一預定臨限值的情況下,可以由第一啟動模組430啟動第一程式,第一程式為版本低於第二程式的程式。 在判斷模組420判定升級次數未超過第一預定臨限值的情況下,可以由第二啟動模組440嘗試啟動第二程式,第二程式為待升級的新程式。 升級裝置400還可以包括累加模組,用於在第二啟動模組440嘗試啟動第二程式的情況下,將升級次數加一。 升級裝置400還可以包括清除模組,用於在第二啟動模組440成功啟動第二程式的情況下,清除升級標識及/或升級次數。 升級裝置400還可以包括計時器,計時器用於回應於計時超過第二預定臨限值觸發系統升級方法的執行,或者觸發第一程式的啟動。 升級裝置400還可以包括重置模組,用於在第二啟動模組440成功啟動第二程式的情況下,迴圈執行如下操作:在計時器的計時超過第二預定臨限值之前,重置計時。 升級裝置400還可以包括產生模組,用於回應於接收到伺服器下發的升級檔或升級指令,產生升級標識。 本揭露還提出了另一種物聯網設備中的升級裝置。該升級裝置包括用於設置引導載入程式的設置模組。引導載入程式可以被配置為執行上文述及的系統升級方法,也可以被配置為執行上文述及的程式升級方法。 圖5示出了根據本揭露另一個實施例的物聯網設備中的升級裝置的結構示意圖。其中,升級裝置的功能模組可以由實現本揭露原理的硬體、軟體或硬體和軟體的結合來實現。本領域技術人員可以理解的是,圖4所描述的功能模組可以組合起來或者劃分成子模組,從而實現上述發明的原理。因此,本文的描述可以支持對本文描述的功能模組的任何可能的組合、或者劃分、或者更進一步的限定。 下面就升級裝置可以具有的功能模組以及各功能模組可以執行的操作做簡要說明,對於其中涉及的細節部分可以參見上文相關描述,這裡不再贅述。 參見圖5,升級裝置500包括第一啟動模組510和第二啟動模組520。 在本揭露的一個實施例中,升級裝置400用於實現物聯網設備中的系統升級。第二啟動模組520用於回應於系統升級請求,嘗試啟動第二系統。第一啟動模組510用於在第二系統啟動失敗或者第二系統啟動失敗次數超過第一預定臨限值的情況下,啟動第一系統,其中,第二系統為待升級的新系統,第一系統的版本低於第二系統。 在本揭露的另一個實施例中,升級裝置400用於實現物聯網設備中的程式升級。第二啟動模組520用於回應於程式升級請求,嘗試啟動第二程式。第一啟動模組510用於在第二程式啟動失敗或者第二程式啟動失敗次數超過第一預定臨限值的情況下,啟動第一程式,其中,第二程式為待升級的新程式,第一程式的版本低於第二程式。 圖6示出了根據本揭露一實施例可用於實現上述物聯網設備中的系統升級方法或程式方法的計算設備的結構示意圖。 參見圖6,計算設備600包括記憶體610和處理器620。 處理器620可以是一個多核的處理器,也可以包含多個處理器。在一些實施例中,處理器620可以包含一個通用的主處理器以及一個或多個特殊的輔助處理器,例如圖形處理器(GPU)、數位訊號處理器(DSP)等等。在一些實施例中,處理器620可以使用訂製的電路實現,例如特殊應用積體電路(ASIC,Application Specific Integrated Circuit)或者現場可程式設計邏輯閘陣列(FPGA,Field Programmable Gate Arrays)。 記憶體610可以包括各種類型的儲存單元,例如系統記憶體、唯讀記憶體(ROM),和永久儲存裝置。其中,ROM可以儲存處理器620或者電腦的其他模組需要的靜態資料或者指令。永久儲存裝置可以是可讀寫的儲存裝置。永久儲存裝置可以是即使電腦斷電後也不會失去儲存的指令和資料的非揮發性存放裝置。在一些實施方式中,永久性儲存裝置採用大型存放區裝置(例如磁或光碟、快閃記憶體)作為永久儲存裝置。另外一些實施方式中,永久性儲存裝置可以是可移除的存放裝置(例如軟碟、光碟機)。系統記憶體可以是可讀寫存放裝置或者揮發性可讀寫存放裝置,例如動態隨機存取記憶體。系統記憶體可以儲存一些或者所有處理器在運行時需要的指令和資料。此外,記憶體610可以包括任意電腦可讀儲存媒介的組合,包括各種類型的半導體儲存晶片(DRAM、SRAM、SDRAM、快閃記憶體、可程式設計唯讀記憶體),磁碟及/或光碟也可以採用。在一些實施方式中,記憶體610可以包括可讀及/或寫的可移除的存放裝置,例如雷射唱片(CD)、唯讀數位多功能光碟(例如DVD-ROM,雙層DVD-ROM)、唯讀藍光光碟、超密度光碟、快閃記憶體卡(例如SD卡、min SD卡、Micro-SD卡等等)、磁性軟碟等等。電腦可讀儲存媒介不包含載波和通過無線或有線傳輸的瞬間電子信號。 記憶體610上儲存有可執行碼,當可執行碼被處理器620處理時,可以使處理器620執行上文述及的物聯網設備中的系統升級方法或程式方法。 上文中已經參考附圖詳細描述了根據本揭露的物聯網設備中的系統或程式升級方法、裝置及設備。 此外,根據本揭露的方法還可以實現為一種電腦程式或電腦程式產品,該電腦程式或電腦程式產品包括用於執行本揭露的上述方法中限定的上述各步驟的電腦程式代碼指令。 或者,本揭露還可以實施為一種非暫時性機器可讀儲存媒體(或電腦可讀儲存媒體、或機器可讀儲存媒體),其上儲存有可執行代碼(或電腦程式、或電腦指令代碼),當所述可執行代碼(或電腦程式、或電腦指令代碼)被電子設備(或計算設備、伺服器等)的處理器執行時,使所述處理器執行根據本揭露的上述方法的各個步驟。 本領域技術人員還將明白的是,結合這裡的公開所描述的各種示例性邏輯塊、模組、電路和演算法步驟可以被實現為電子硬體、電腦軟體或兩者的組合。 附圖中的流程圖和方塊圖顯示了根據本揭露的多個實施例的系統和方法的可能實現的體系架構、功能和操作。在這點上,流程圖或方塊圖中的每個方塊可以代表一個模組、程式段或碼的一部分,所述模組、程式段或碼的一部分包含一個或多個用於實現規定的邏輯功能的可執行指令。也應當注意,在有些作為替換的實現中,方塊中所標記的功能也可以以不同於附圖中所標記的順序發生。例如,兩個連續的方塊實際上可以基本平行地執行,它們有時也可以按相反的循序執行,這依所涉及的功能而定。也要注意的是,方塊圖及/或流程圖中的每個方塊、以及方塊圖及/或流程圖中的方塊的組合,可以用執行規定的功能或操作的專用的基於硬體的系統來實現,或者可以用專用硬體與電腦指令的組合來實現。 以上已經描述了本揭露的各實施例,上述說明是示例性的,並非窮盡性的,並且也不限於所披露的各實施例。在不偏離所說明的各實施例的範圍和精神的情況下,對於所屬技術領域中具有通常知識者來說許多修改和變更都是顯而易見的。本文中所用用語的選擇,旨在最好地解釋各實施例的原理、實際應用或對市場中的技術的改進,或者使本技術領域的其它普通技術人員能理解本文披露的各實施例。Hereinafter, the preferred embodiments of the present disclosure will be described in more detail with reference to the accompanying drawings. Although the preferred embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to make the disclosure more thorough and complete, and to fully convey the scope of the disclosure to those skilled in the art. Figure 1 shows a flow chart of communication between IoT devices and servers. The IoT device 100 mentioned in this disclosure can be, but is not limited to, a PDA (Personal Digital Assistant, personal digital assistant) smart terminal, a vehicle (such as an unmanned car), a sensor, a smart home device (such as, but not limited to, smart Speakers, sweeping robots, smart bulbs, smart switches, smart door locks, etc. Among them, the PDA smart terminal can be, but is not limited to, a shipment tracking and scanning recorder, a mobile POS machine used to implement one or more functions such as retail billing, printing of small receipts, inventory, data uploading, and daily settlement. Internet of Things (Internet of Things, referred to as IoT), that is, the "Internet of Things Connected" is an extension and expansion network based on the Internet, which is formed by combining various information sensing devices with the Internet. The huge network realizes the interconnection of people, machines and things at any time and any place. The Internet of Things device 100 may communicate with a server through the Internet of Things, and may also be connected with other Internet of Things devices through the Internet of Things. As shown in FIG. 1, the Internet of Things device 100 can use OTA (Over-the-Air Technology, over-the-air technology) for remote upgrade. For example, the Internet of Things device 100 may obtain an update file from the server 200 through the network, so as to realize the remote upgrade of the Internet of Things device 100. The network can be, but is not limited to, a wireless communication network, the Internet, a private area network, a local area network, a metropolitan area network, a wide area network, or a cellular data network. In the process of remote upgrade of the Internet of Things device 100 using OTA, it is inevitable that the upgrade will fail due to an upgrade file error or other reasons. In order to enable the IoT device 100 to automatically roll back to the previous version when the system upgrade fails, without affecting the normal use of the device, this disclosure proposes a system upgrade solution that supports the automatic rollback of the upgrade failure to the previous version. This disclosure is mainly to set up a boot loader, based on the boot loader to guide the system upgrade and provide response processing in the case of an upgrade failure. The boot loader mentioned in this disclosure can be regarded as the first piece of software code that runs after the device is powered on, and the boot loader can be implemented as a kind of firmware, such as a bootloader firmware. After the Internet of Things device is powered on and started, the boot loader can be started first, and the boot loader executes the disclosed system upgrade method to realize the system upgrade and the handling in case of failure of the upgrade. Figure 2 shows a schematic diagram of the layout structure of the storage area of the Internet of Things device. As shown in Figure 2, the storage area of the IoT device can be divided into a first area, a second area, a third area, and a fourth area. The division mentioned here does not represent the execution of the actual division action, but may refer to the logical division. The first area is used to store the boot loader, and the boot loader is used to execute the disclosed system upgrade method to boot the entire system. The second area is used to store the first system, and the third area is used to store the second system. The second system is a new system to be upgraded. The version of the first system is lower than that of the second system. The first system can be regarded as the old system. . The first system can refer to the system where the equipment has been running before the new system is upgraded, and the second area can store one or more old systems whose versions are lower than the second system. The fourth area is used to store upgrade parameters such as upgrade identification and upgrade times. Among them, the parameters defined in the fourth area are designed as a data bridge shared by the boot loader and the system program, which can cooperate with each other to complete the automatic judgment of the system startup failure. As an example, after the new system is successfully started, the old system in the second zone can be replaced with the new system, and the third zone can be cleared to wait for the arrival of the new upgraded system. In addition, after the new system is successfully started, the new system can also be added to the second area without deleting the old system stored in the second area, so that the second area can store systems that have been run by multiple devices. Fig. 3 shows a schematic flowchart of a system upgrade method in an Internet of Things device according to an embodiment of the present disclosure. As shown in Figure 3, after the Internet of Things device is powered on, the boot loader is first started, and under the guidance of the boot loader, the implementation of the entire system upgrade method is realized. In step S110, the timer can be set by the boot loader, that is, the timer is initialized. The timer is used for timing, and in response to the timing exceeding a predetermined threshold (for ease of partitioning, it may be referred to as the second predetermined threshold) triggers the execution of the system upgrade method of the present disclosure (that is, triggers the restart of the boot loader), Or trigger the activation of the first system. The timer can be implemented as a hardware module, such as a hardware watchdog. In this embodiment, the first system may be a system running before the upgrade, for example, it may be a system of the previous version of the second system. In addition, the first system may also be a system of a version selected from multiple versions of systems before the second system, that is, the first system may be a system selected from a plurality of old systems stored in the second area. In step S120, it is checked whether there is an upgrade identifier. The upgrade identifier is used to characterize whether there is a current upgrade requirement for the Internet of Things device, and the upgrade identifier may be an identifier generated in response to receiving an upgrade file or an upgrade instruction issued by the server. Regarding the specific representation form of the upgrade logo, this disclosure will not repeat it. In the case that there is no upgrade identifier, it indicates that the IoT device does not currently need to be upgraded, and step S190 may be executed to start the first system. As an example, when step S190 is performed, the system that was running before the upgrade can be started, or the system with better stability can be selected from the systems of multiple versions before the second system according to the system stability of each version obtained by statistics. Start up. If there is an upgrade identifier, it indicates that the IoT device currently has upgrade requirements, and step S130 can be executed to determine whether the number of upgrades exceeds a predetermined threshold N (for ease of partitioning, it may be referred to as a first predetermined threshold). The number of upgrades mentioned here refers to the number of attempts to start the new system to be upgraded, that is, the number of failures. The size of the first predetermined threshold can be set according to actual conditions. As described above in conjunction with Figure 1, the fourth area is used to store parameters such as the upgrade identifier and the number of upgrades. Therefore, when step S120 and step S130 are performed, the upgrade identifier and the number of upgrades can be obtained from the fourth area to realize the search for the upgrade identifier. , Judging the number of upgrades and other operations. In the case where it is determined that the number of upgrades exceeds the first predetermined threshold, it indicates that the number of failures is too many and the upgrade cannot be successful. In this case, step S190 may be executed to start the first system. In the case where it is determined that the number of upgrades does not exceed the first predetermined threshold, step S140 and step S150 can be executed to increase the number of upgrades by 1 and try to start the new system. After step S150 is executed, it can be judged whether the startup is successful. In the case that the second system can run normally, it can be considered that the startup is successful, that is, the upgrade is successful. In the case that an error occurs during the startup of the second system (for example, an error is thrown) or the startup time (that is, the upgrade time) exceeds the third predetermined threshold, the startup may be regarded as a failure. In the case that the new system is not successfully started, step S195 can be executed to cause the timer to time out, thereby triggering the reboot of the boot loader. Optionally, in the case of unsuccessful startup, the timer can also be timed out by executing step S195 to trigger the startup of the first system. In the case that the new system is successfully started, step S170 may be executed, and the following operations are performed in a loop: reset the timing before the timing of the timer exceeds the second predetermined threshold. By resetting the timer's timing through the loop, it can avoid restarting the boot loader or rolling back to the first system due to the timer's timeout when the new system can run normally. Wherein, when the timer is a watchdog, step S170 is to automatically feed the watchdog. Optionally, step S170 may be executed by the new system after successful startup. In the present disclosure, the system upgrade method (that is, the boot loader) of the present disclosure can be restarted when the system upgrade fails with the cooperation of a timer. Optionally, the timer can also be used to automatically roll back to the first system in the case that the startup time of the second system exceeds the second predetermined threshold. In addition, in the case of successful startup, step S180 may also be executed to clear the upgrade identifier and/or the number of upgrades. Therefore, after performing step S180, the new system after successful startup can be run as the current running system. After that, if the IoT device needs to be upgraded again, the currently running system can be used as the first system, and the new system to be upgraded The system can be used as a new second system, and the process shown in Figure 3 is executed again to achieve system upgrades. In summary, this disclosure can initialize the timer under the action of the boot loader and boot the new system. After the new system is successfully started, the timer can be reset in a loop to avoid system restart. When the new system fails to start, the system restart can be triggered by a timer, and the upgrade method of this disclosure is executed again under the action of the boot loader. When the number of failures (that is, the number of upgrades) exceeds the first predetermined threshold, Automatically roll back to the old system. This disclosure also proposes another system upgrade method in the Internet of Things device, which includes: setting a boot loader, and the boot loader is configured to execute the system upgrade method shown in FIG. 3 above. This disclosure also proposes another system upgrade method in IoT devices, including: responding to a system upgrade request, attempting to start the second system; when the second system fails to start or the number of times the second system fails to start exceeds a first predetermined threshold In the case, start the first system. For the first system and the second system, please refer to the relevant description above, which will not be repeated here. The system upgrade request is the system upgrade requirement of the IoT device. It can be judged whether there is a system upgrade requirement by checking whether there is an upgrade identifier. For the upgrade identifier, please refer to the relevant description above, which will not be repeated here. In the case that the second system fails to start, the number of failures (that is, the number of startups mentioned above) can be increased by 1, and then try to start the second system again, so that when the number of failures exceeds the first predetermined threshold, no Try to start the second system again, but start the first system. In this embodiment, it may be determined that the second system has failed to start when the second system exceeds the third predetermined threshold and fails to start successfully. That is, the present disclosure can trigger a re-upgrade or rollback to the first system according to the time it takes for the second system to start. As an example, a timer can be set to implement automatic rollback to the first system when the second system fails to start or the number of times the second system fails to start exceeds a predetermined threshold. For example, the timer may be set to trigger the activation of the first system in response to the timing exceeding the second predetermined threshold. The bootloader may fail to activate the second system or the number of failures exceeds the first predetermined threshold, Time out the timer to roll back to the first system. Taking IoT devices as express tracking and scanning recorders and mobile POS machines as examples, the first system/second system mentioned above may refer to a real-time operating system (RTOS). RTOS means that when external events or data are generated, they can be accepted and processed quickly enough, and the results of the processing can control the production process or respond quickly to the processing system within the specified time, and control all real-time An operating system where tasks are coordinated. So far, the system upgrade method in the Internet of Things device disclosed in this disclosure has been described in detail. The disclosure can also be implemented as a program upgrade method for upgrading other non-system programs in the Internet of Things device. That is, the first system/second system mentioned above can also be replaced with the first program/second program running in the IoT device. The following is an exemplary description of the procedure of the program upgrade method in the Internet of Things device disclosed in the present disclosure. For the details involved in the solution, please refer to the relevant description above, which will not be repeated here. The disclosed program upgrade method in the Internet of Things device may include: checking whether there is an upgrade mark; if there is an upgrade mark, judging whether the number of upgrades exceeds a first predetermined threshold; after judging that the number of upgrades exceeds the first predetermined threshold Value, start the first program, and/or if it is determined that the number of upgrades does not exceed the first predetermined threshold, try to start the second program, where the second program is the new program to be upgraded, and the first program The version of is lower than the second program. That is to say, the present disclosure can also be used to upgrade non-system programs in the Internet of Things devices. For details about the method involved, please refer to the relevant description above, which will not be repeated here. The disclosed program upgrade method in the Internet of Things device may further include: setting a boot loader, and the boot loader is configured to execute the program upgrade method mentioned above. The disclosed program upgrade method in the Internet of Things device may also include: responding to the program upgrade request, attempting to start the second program; in the case that the second program fails to start or the number of times the second program fails to start exceeds the first predetermined threshold , Start the first program, where the second program is a new program to be upgraded, and the version of the first program is lower than the second program. Fig. 4 shows a schematic structural diagram of an upgrading apparatus in an Internet of Things device according to an embodiment of the present disclosure. Among them, the functional modules of the upgrade device can be implemented by hardware, software, or a combination of hardware and software that implement the principles of the disclosure. Those skilled in the art can understand that the functional modules described in FIG. 4 can be combined or divided into sub-modules to realize the principle of the above-mentioned invention. Therefore, the description herein can support any possible combination, or division, or further limitation of the functional modules described herein. The following briefly describes the functional modules that the upgrade device can have and the operations that can be performed by each functional module. For the details involved, please refer to the relevant description above, which will not be repeated here. Referring to FIG. 4, the upgrading apparatus 400 includes an inspection module 410, a judgment module 420, a first activation module 430 and/or a second activation module 440. In an embodiment of the present disclosure, the upgrading apparatus 400 is used to implement a system upgrade in an Internet of Things device. The checking module 410 is used to check whether there is an upgrade identifier. If there is no upgrade identifier, the first system can be activated by the first activation module 430. The first startup module 430 may start the system that was running before the upgrade, or may also select a version of the system from multiple versions of the system before the second system to start it according to the stability of the system. If there is an upgrade indicator, the judgment module 420 can determine whether the number of upgrades exceeds the first predetermined threshold. When the judgment module 420 determines that the number of upgrades exceeds the first predetermined threshold, the first activation module 430 may activate the first system. In the case that the judgment module 420 judges that the number of upgrades does not exceed the first predetermined threshold, the second activation module 440 may try to activate the second system. The upgrading apparatus 400 may further include an accumulation module, which is used to increase the number of upgrades by one when the second activation module 440 attempts to activate the second system. The upgrading apparatus 400 may further include a clearing module for clearing the upgrade identifier and/or the number of upgrades when the second activation module 440 successfully starts the second system. The upgrading apparatus 400 may further include a timer, which is used to trigger the execution of the system upgrading method in response to the time exceeding the second predetermined threshold, or to trigger the activation of the first system. The upgrade device 400 may also include a reset module, which is used to looply perform the following operations when the second activation module 440 successfully activates the second system: before the timer exceeds the second predetermined threshold, restart Set time. The upgrading apparatus 400 may further include a generation module for generating an upgrade identifier in response to receiving an upgrade file or an upgrade command issued by the server. In another embodiment of the present disclosure, the upgrading apparatus 400 is used to implement program upgrading in the Internet of Things device. The checking module 410 is used to check whether there is an upgrade identifier. In the case that there is no upgrade identifier, the first program can be activated by the first activation module 430. The first activation module 430 may activate the program that was running before the upgrade, or may also select a version of the program from multiple versions of the program before the second program to activate it according to the stability of the program. If there is an upgrade indicator, the judgment module 420 can determine whether the number of upgrades exceeds the first predetermined threshold. When the judgment module 420 determines that the number of upgrades exceeds the first predetermined threshold, the first activation module 430 can activate the first program, and the first program is a program whose version is lower than the second program. In the case that the determining module 420 determines that the number of upgrades does not exceed the first predetermined threshold, the second activation module 440 may try to activate the second program, and the second program is a new program to be upgraded. The upgrading device 400 may also include an accumulation module for increasing the number of upgrades by one when the second activation module 440 attempts to activate the second program. The upgrading apparatus 400 may further include a clearing module for clearing the upgrade identification and/or the number of upgrades when the second activation module 440 successfully activates the second program. The upgrade device 400 may further include a timer, which is used to trigger the execution of the system upgrade method in response to the timing exceeding the second predetermined threshold, or trigger the start of the first program. The upgrading device 400 may also include a reset module, which is used to looply perform the following operations when the second activation module 440 successfully starts the second program: before the timer exceeds the second predetermined threshold, restart Set time. The upgrading apparatus 400 may further include a generation module for generating an upgrade identifier in response to receiving an upgrade file or an upgrade command issued by the server. This disclosure also proposes another upgrade device in the Internet of Things equipment. The upgrade device includes a setting module for setting a boot loader. The boot loader can be configured to execute the system upgrade method described above, or it can be configured to execute the program upgrade method described above. Fig. 5 shows a schematic structural diagram of an upgrading apparatus in an Internet of Things device according to another embodiment of the present disclosure. Among them, the functional modules of the upgrade device can be implemented by hardware, software, or a combination of hardware and software that implement the principles of the disclosure. Those skilled in the art can understand that the functional modules described in FIG. 4 can be combined or divided into sub-modules to realize the principle of the above-mentioned invention. Therefore, the description herein can support any possible combination, or division, or further limitation of the functional modules described herein. The following briefly describes the functional modules that the upgrade device can have and the operations that can be performed by each functional module. For the details involved, please refer to the relevant description above, which will not be repeated here. Referring to FIG. 5, the upgrading apparatus 500 includes a first activation module 510 and a second activation module 520. In an embodiment of the present disclosure, the upgrading apparatus 400 is used to implement a system upgrade in an Internet of Things device. The second activation module 520 is used to respond to the system upgrade request and try to activate the second system. The first startup module 510 is used to start the first system when the second system fails to start or the number of times the second system fails to start exceeds the first predetermined threshold, where the second system is a new system to be upgraded, and the second system is a new system to be upgraded. The version of the first system is lower than that of the second system. In another embodiment of the present disclosure, the upgrading apparatus 400 is used to implement program upgrading in the Internet of Things device. The second activation module 520 is used to respond to the program upgrade request and try to activate the second program. The first startup module 510 is used to start the first program when the second program fails to start or the number of times the second program fails to start exceeds the first predetermined threshold, where the second program is a new program to be upgraded, and the second program is a new program to be upgraded. The version of one program is lower than that of the second program. FIG. 6 shows a schematic structural diagram of a computing device that can be used to implement the system upgrade method or program method in the above-mentioned Internet of Things device according to an embodiment of the present disclosure. Referring to FIG. 6, the computing device 600 includes a memory 610 and a processor 620. The processor 620 may be a multi-core processor, or may include multiple processors. In some embodiments, the processor 620 may include a general-purpose main processor and one or more special auxiliary processors, such as a graphics processing unit (GPU), a digital signal processor (DSP), and so on. In some embodiments, the processor 620 may be implemented using a customized circuit, such as an Application Specific Integrated Circuit (ASIC, Application Specific Integrated Circuit) or a field programmable logic gate array (FPGA, Field Programmable Gate Arrays). The memory 610 may include various types of storage units, such as system memory, read-only memory (ROM), and permanent storage. Among them, the ROM can store static data or instructions required by the processor 620 or other modules of the computer. The permanent storage device may be a readable and writable storage device. The permanent storage device may be a non-volatile storage device that does not lose stored instructions and data even after the computer is powered off. In some embodiments, the permanent storage device uses a large storage area device (such as a magnetic or optical disk, flash memory) as the permanent storage device. In other embodiments, the permanent storage device may be a removable storage device (such as a floppy disk, an optical disc drive). The system memory can be a readable and writable storage device or a volatile readable and writable storage device, such as dynamic random access memory. The system memory can store some or all of the instructions and data needed by the processor when it is running. In addition, the memory 610 may include any combination of computer-readable storage media, including various types of semiconductor storage chips (DRAM, SRAM, SDRAM, flash memory, programmable read-only memory), magnetic disks and/or optical disks Can also be used. In some embodiments, the memory 610 may include removable storage devices that can be read and/or written, such as compact discs (CDs), read-only multi-function optical discs (such as DVD-ROM, double-layer DVD-ROM) ), read-only Blu-ray discs, ultra-density discs, flash memory cards (such as SD cards, min SD cards, Micro-SD cards, etc.), magnetic floppy disks, etc. Computer-readable storage media does not contain carrier waves and instantaneous electronic signals that are transmitted wirelessly or wiredly. The memory 610 stores executable codes. When the executable codes are processed by the processor 620, the processor 620 can execute the system upgrade method or program method in the IoT device mentioned above. The method, device, and device for upgrading the system or program in the Internet of Things device according to the present disclosure have been described in detail above with reference to the accompanying drawings. In addition, the method according to the present disclosure can also be implemented as a computer program or computer program product. The computer program or computer program product includes computer program code instructions for executing the above-mentioned steps defined in the above-mentioned method of the present disclosure. Alternatively, the present disclosure can also be implemented as a non-transitory machine-readable storage medium (or computer-readable storage medium, or machine-readable storage medium) on which executable code (or computer program, or computer instruction code) is stored When the executable code (or computer program, or computer instruction code) is executed by the processor of the electronic device (or computing device, server, etc.), the processor is caused to execute the steps of the above-mentioned method according to the present disclosure . Those skilled in the art will also understand that the various exemplary logic blocks, modules, circuits, and algorithm steps described in conjunction with the disclosure herein can be implemented as electronic hardware, computer software, or a combination of both. The flowcharts and block diagrams in the accompanying drawings show the possible implementation architecture, functions, and operations of the system and method according to multiple embodiments of the present disclosure. In this regard, each block in the flowchart or block diagram can represent a module, program segment, or part of the code, and the module, program segment, or part of the code contains one or more logic for implementing the specified Executable instructions for the function. It should also be noted that in some alternative implementations, the functions marked in the block may also occur in a different order than the order marked in the drawings. For example, two consecutive blocks can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and/or flowchart, and the combination of blocks in the block diagram and/or flowchart, can be implemented by a dedicated hardware-based system that performs the specified functions or operations. It can be realized, or it can be realized by a combination of dedicated hardware and computer instructions. The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Without departing from the scope and spirit of the illustrated embodiments, many modifications and changes are obvious to those with ordinary knowledge in the technical field. The choice of terms used herein is intended to best explain the principles, practical applications, or improvements to the technology in the market for each embodiment, or to enable other ordinary skilled in the art to understand the various embodiments disclosed herein.

100:物聯網設備 200:伺服器 S110:步驟 S120:步驟 S130:步驟 S140:步驟 S150:步驟 S160:步驟 S170:步驟 S180:步驟 S190:步驟 S195:步驟 400:升級裝置 410:檢查模組 420:判斷模組 430:第一啟動模組 440:第二啟動模組 500:升級裝置 510:第一啟動模組 520:第二啟動模組 600:計算設備 610:記憶體 620:處理器100: IoT devices 200: server S110: Step S120: Step S130: Step S140: Step S150: Step S160: Step S170: Step S180: steps S190: Step S195: Step 400: Upgrade device 410: check module 420: Judgment Module 430: The first startup module 440: The second startup module 500: Upgrade device 510: The first startup module 520: The second startup module 600: Computing equipment 610: Memory 620: processor

通過結合附圖對本揭露示例性實施方式進行更詳細的描述,本揭露的上述以及其它目的、特徵和優勢將變得更加明顯,其中,在本揭露示例性實施方式中,相同的參考標號通常代表相同部件。 [圖1] 示出了物聯網設備與伺服器間的通信流程圖。 [圖2] 示出了物聯網設備的儲存區佈局結構示意圖。 [圖3] 示出了根據本揭露一實施例的物聯網設備中的系統升級方法的示意性流程圖。 [圖4] 示出了根據本揭露一個實施例的物聯網設備中的升級裝置的結構示意圖。 [圖5] 示出了根據本揭露另一個實施例的物聯網設備中的升級裝置的結構示意圖。 [圖6] 示出了根據本揭露一實施例的計算設備的結構示意圖。Through a more detailed description of the exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, the above and other objectives, features, and advantages of the present disclosure will become more apparent. Among them, in the exemplary embodiments of the present disclosure, the same reference numerals generally represent The same parts. [Figure 1] shows the communication flow chart between the IoT device and the server. [Figure 2] shows a schematic diagram of the layout structure of the storage area of the Internet of Things device. [Fig. 3] shows a schematic flowchart of a system upgrade method in an Internet of Things device according to an embodiment of the present disclosure. [Figure 4] shows a schematic structural diagram of an upgrade apparatus in an Internet of Things device according to an embodiment of the present disclosure. [Figure 5] shows a schematic structural diagram of an upgrade apparatus in an Internet of Things device according to another embodiment of the present disclosure. [Figure 6] shows a schematic structural diagram of a computing device according to an embodiment of the present disclosure.

Claims (24)

一種物聯網設備中的系統升級方法,其特徵在於,包括: 檢查是否存在升級標識; 在存在所述升級標識的情況下,判斷升級次數是否超過第一預定臨限值; 在判定所述升級次數超過所述第一預定臨限值的情況下,啟動第一系統,並且/或者在判定所述升級次數未超過所述第一預定臨限值的情況下,嘗試啟動第二系統,其中,所述第二系統為待升級的新系統,所述第一系統的版本低於所述第二系統。A system upgrade method in Internet of Things equipment, characterized in that it includes: Check whether there is an upgrade logo; In the case of the upgrade identifier, determining whether the number of upgrades exceeds a first predetermined threshold; When it is determined that the number of upgrades exceeds the first predetermined threshold, the first system is activated, and/or when it is determined that the number of upgrades does not exceed the first predetermined threshold, an attempt is made to activate the first system. A second system, wherein the second system is a new system to be upgraded, and the version of the first system is lower than that of the second system. 根據請求項1所述的系統升級方法,其中,還包括: 在不存在所述升級標識的情況下,啟動所述第一系統。The system upgrade method according to claim 1, which further includes: In the case that the upgrade identifier does not exist, start the first system. 根據請求項1所述的系統升級方法,其中,還包括: 在嘗試啟動所述第二系統的情況下,將所述升級次數加一。The system upgrade method according to claim 1, which further includes: In the case of attempting to start the second system, the number of upgrades is increased by one. 根據請求項1所述的系統升級方法,其中,還包括: 在成功啟動所述第二系統的情況下,清除所述升級標識及/或所述升級次數。The system upgrade method according to claim 1, which further includes: In the case of successfully starting the second system, clear the upgrade identifier and/or the number of upgrades. 根據請求項1所述的系統升級方法,其中,還包括: 設置計時器,所述計時器用於回應於計時超過第二預定臨限值觸發所述系統升級方法的執行,或者觸發所述第一系統的啟動。The system upgrade method according to claim 1, which further includes: A timer is set, and the timer is used to trigger the execution of the system upgrade method in response to the timing exceeding a second predetermined threshold, or trigger the activation of the first system. 根據請求項5所述的系統升級方法,其中,還包括: 在成功啟動所述第二系統的情況下,迴圈執行如下操作:在所述計時器的計時超過所述第二預定臨限值之前,重置所述計時。The system upgrade method according to claim 5, which further includes: In the case of successfully starting the second system, the loop performs the following operations: reset the timing before the timing of the timer exceeds the second predetermined threshold. 根據請求項1所述的系統升級方法,其中,還包括: 回應於接收到伺服器下發的升級檔或升級指令,產生所述升級標識。The system upgrade method according to claim 1, which further includes: In response to receiving the upgrade file or upgrade command issued by the server, the upgrade identifier is generated. 根據請求項1所述的系統升級方法,其中,所述啟動第一系統的步驟包括: 啟動升級前運行的系統;或者 根據系統穩定性,從所述第二系統之前多個版本的系統中選擇一個版本的系統進行啟動。The system upgrade method according to claim 1, wherein the step of starting the first system includes: Start the system that was running before the upgrade; or According to the stability of the system, a system of one version is selected from the previous versions of the second system to start. 根據請求項1所述的系統升級方法,其中,所述物聯網設備為以下至少一項: 車輛; 個人數位助理終端; 感測器; 智慧家居設備。The system upgrade method according to claim 1, wherein the Internet of Things device is at least one of the following: vehicle; Personal digital assistant terminal; Sensor Smart home equipment. 根據請求項1至9中任一項所述的系統升級方法,其中,所述物聯網設備的儲存區被劃分為第一區、第二區、第三區以及第四區, 所述第一區用於儲存引導載入程式,所述引導載入程式用於執行所述系統升級方法, 所述第二區用於儲存所述第一系統, 所述第三區用於儲存所述第二系統; 所述第四區用於儲存所述升級標識及/或所述升級次數。The system upgrade method according to any one of claim items 1 to 9, wherein the storage area of the Internet of Things device is divided into a first area, a second area, a third area, and a fourth area, The first area is used to store a boot loader, and the boot loader is used to execute the system upgrade method, The second area is used to store the first system, The third area is used to store the second system; The fourth area is used to store the upgrade identifier and/or the number of upgrades. 一種物聯網設備中的系統升級方法,其特徵在於,包括:設置引導載入程式,所述引導載入程式被配置為: 回應於所述物聯網設備上電啟動,執行請求項1至10中任一項所述的系統升級方法。A system upgrade method in an Internet of Things device is characterized in that it comprises: setting a boot loader, the boot loader is configured as: In response to the power-on and startup of the Internet of Things device, the system upgrade method described in any one of request items 1 to 10 is executed. 一種物聯網設備中的系統升級方法,其特徵在於,包括: 回應於系統升級請求,嘗試啟動第二系統; 在所述第二系統啟動失敗或者所述第二系統啟動失敗次數超過第一預定臨限值的情況下,啟動第一系統,其中,所述第二系統為待升級的新系統,所述第一系統的版本低於所述第二系統。A system upgrade method in Internet of Things equipment, characterized in that it includes: In response to the system upgrade request, try to start the second system; In the case that the second system fails to start or the number of times the second system fails to start exceeds the first predetermined threshold, the first system is started, wherein the second system is a new system to be upgraded, and the first system The version of one system is lower than that of the second system. 根據請求項12所述的系統升級方法,其中,還包括: 在所述第二系統超過第三預定臨限值未啟動成功的情況下,判定所述第二系統啟動失敗。The system upgrade method according to claim 12, which further includes: If the second system exceeds the third predetermined threshold and fails to start successfully, it is determined that the second system has failed to start. 一種物聯網設備中的程式升級方法,其特徵在於,包括: 檢查是否存在升級標識; 在存在所述升級標識的情況下,判斷升級次數是否超過第一預定臨限值; 在判定所述升級次數超過所述第一預定臨限值的情況下,啟動第一程式,並且/或者在判定所述升級次數未超過所述第一預定臨限值的情況下,嘗試啟動第二程式,其中,所述第二程式為待升級的新程式,所述第一程式的版本低於所述第二程式。A program upgrade method in Internet of Things equipment, characterized in that it includes: Check whether there is an upgrade logo; In the case of the upgrade identifier, determining whether the number of upgrades exceeds a first predetermined threshold; In the case where it is determined that the number of upgrades exceeds the first predetermined threshold, the first program is started, and/or in the case where it is determined that the number of upgrades does not exceed the first predetermined threshold, try to start the first program. Two programs, wherein the second program is a new program to be upgraded, and the version of the first program is lower than the second program. 一種物聯網設備中的程式升級方法,其特徵在於,包括:設置引導載入程式,所述引導載入程式被配置為: 回應於所述物聯網設備上電啟動,執行請求項14所述的程式升級方法。A program upgrade method in an Internet of Things device is characterized in that it comprises: setting a boot loader program, the boot loader program is configured as: In response to the startup of the Internet of Things device, the program upgrade method described in request item 14 is executed. 一種物聯網設備中的程式升級方法,其特徵在於,包括: 回應於程式升級請求,嘗試啟動第二程式; 在所述第二程式啟動失敗或者所述第二程式啟動失敗次數超過第一預定臨限值的情況下,啟動第一程式,其中,所述第二程式為待升級的新程式,所述第一程式的版本低於所述第二程式。A program upgrade method in Internet of Things equipment, characterized in that it includes: In response to the program upgrade request, try to activate the second program; In the case that the second program fails to start or the number of times the second program fails to start exceeds a first predetermined threshold, the first program is started, wherein the second program is a new program to be upgraded, and the first program The version of one program is lower than the second program. 一種物聯網設備中的系統升級裝置,其特徵在於,包括: 檢查模組,用於檢查是否存在升級標識; 判斷模組,用於在存在所述升級標識的情況下,判斷升級次數是否超過第一預定臨限值; 第一啟動模組,用於在所述判斷模組判定所述升級次數超過所述第一預定臨限值的情況下,啟動第一系統,及/或第二啟動模組,用於在所述判斷模組判定所述升級次數未超過所述第一預定臨限值的情況下,嘗試啟動第二系統,其中,所述第二系統為待升級的新系統,所述第一系統的版本低於所述第二系統。A system upgrade device in Internet of Things equipment, which is characterized in that it includes: Check module, used to check whether there is an upgrade logo; The judging module is used for judging whether the number of upgrades exceeds a first predetermined threshold when the upgrade identifier exists; The first activation module is used to activate the first system and/or the second activation module when the judgment module determines that the number of upgrades exceeds the first predetermined threshold. If the determining module determines that the number of upgrades does not exceed the first predetermined threshold, it attempts to start a second system, where the second system is a new system to be upgraded, and the version of the first system Lower than the second system. 一種物聯網設備中的系統升級裝置,其特徵在於,包括:設置模組,用於設置引導載入程式,所述引導載入程式被配置為: 回應於所述物聯網設備上電啟動,執行請求項1至10中任一項所述的系統升級方法。A system upgrade device in Internet of Things equipment, characterized by comprising: a setting module for setting a boot loader, the boot loader is configured as: In response to the power-on and startup of the Internet of Things device, the system upgrade method described in any one of request items 1 to 10 is executed. 一種物聯網設備中的系統升級裝置,其特徵在於,包括: 第二啟動模組,用於回應於系統升級請求,嘗試啟動第二系統; 第一啟動模組,用於在所述第二系統啟動失敗或者所述第二系統啟動失敗次數超過第一預定臨限值的情況下,啟動第一系統,其中,所述第二系統為待升級的新系統,所述第一系統的版本低於所述第二系統。A system upgrade device in Internet of Things equipment, which is characterized in that it includes: The second activation module is used to respond to the system upgrade request and try to activate the second system; The first activation module is configured to activate the first system when the activation of the second system fails or the number of failed activations of the second system exceeds a first predetermined threshold, wherein the second system is a standby In the upgraded new system, the version of the first system is lower than that of the second system. 一種物聯網設備中的程式升級裝置,其特徵在於,包括: 檢查模組,用於檢查是否存在升級標識; 判斷模組,用於在存在所述升級標識的情況下,判斷升級次數是否超過第一預定臨限值; 第一啟動模組,用於在所述判斷模組判定所述升級次數超過所述第一預定臨限值的情況下,啟動第一程式,及/或第二啟動模組,用於在所述判斷模組判定升級次數未超過所述第一預定臨限值的情況下,嘗試啟動第二程式,其中,所述第二程式為待升級的新程式,所述第一程式的版本低於所述第二程式。A program upgrade device in Internet of Things equipment, which is characterized in that it includes: Check module, used to check whether there is an upgrade logo; The judging module is used for judging whether the number of upgrades exceeds a first predetermined threshold when the upgrade identifier exists; The first activation module is used to activate the first program and/or the second activation module when the judgment module determines that the number of upgrades exceeds the first predetermined threshold. If the determining module determines that the number of upgrades does not exceed the first predetermined threshold, it attempts to start a second program, where the second program is a new program to be upgraded, and the version of the first program is lower than The second formula. 一種物聯網設備中的程式升級裝置,其特徵在於,包括:設置模組,用於設置引導載入程式,所述引導載入程式被配置為: 回應於所述物聯網設備上電啟動,執行請求項14所述的程式升級方法。A program upgrade device in an Internet of Things device is characterized by comprising: a setting module for setting a boot loader program, the boot loader program is configured as: In response to the startup of the Internet of Things device, the program upgrade method described in request item 14 is executed. 一種物聯網設備中的程式升級裝置,其特徵在於,包括: 第二啟動模組,用於回應於程式升級請求,嘗試啟動第二程式; 第一啟動模組,用於在所述第二程式啟動失敗或者所述第二程式啟動失敗次數超過第一預定臨限值的情況下,啟動第一程式,其中,所述第二程式為待升級的新程式,所述第一程式的版本低於所述第二程式。A program upgrade device in Internet of Things equipment, which is characterized in that it includes: The second activation module is used to respond to the program upgrade request and try to activate the second program; The first startup module is used to start the first program when the second program fails to start or the number of times the second program fails to start exceeds a first predetermined threshold, wherein the second program is waiting For the upgraded new program, the version of the first program is lower than that of the second program. 一種計算設備,包括: 處理器;以及 記憶體,其上儲存有可執行代碼,當所述可執行代碼被所述處理器執行時,使所述處理器執行如請求項1至16中任何一項所述的方法。A computing device including: Processor; and The memory has executable code stored thereon, and when the executable code is executed by the processor, the processor is caused to execute the method according to any one of the request items 1 to 16. 一種非暫時性機器可讀儲存媒體,其上儲存有可執行代碼,當所述可執行代碼被電子設備的處理器執行時,使所述處理器執行如請求項1至16中任一項所述的方法。A non-transitory machine-readable storage medium with executable code stored thereon. When the executable code is executed by a processor of an electronic device, the processor is caused to execute as described in any one of request items 1 to 16 The method described.
TW109118079A 2019-08-28 2020-05-29 Method and apparatus for upgrading system in internet of things device, device, and storage medium TW202109336A (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910799751.7 2019-08-28
CN201910799751.7A CN112527322A (en) 2019-08-28 2019-08-28 System upgrading method, device, equipment and storage medium in Internet of things equipment

Publications (1)

Publication Number Publication Date
TW202109336A true TW202109336A (en) 2021-03-01

Family

ID=74684117

Family Applications (1)

Application Number Title Priority Date Filing Date
TW109118079A TW202109336A (en) 2019-08-28 2020-05-29 Method and apparatus for upgrading system in internet of things device, device, and storage medium

Country Status (3)

Country Link
CN (1) CN112527322A (en)
TW (1) TW202109336A (en)
WO (1) WO2021036917A1 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113157303A (en) * 2021-05-27 2021-07-23 盈合(深圳)机器人与自动化科技有限公司 Upgrading method, embedded system, terminal and computer storage medium
CN114237722B (en) * 2021-11-19 2023-09-01 湖南三一智能控制设备有限公司 System starting method, device, equipment and engineering vehicle
CN114741119A (en) * 2022-03-22 2022-07-12 深圳数马电子技术有限公司 System starting method and device, computer equipment and storage medium
CN115904450A (en) * 2022-11-02 2023-04-04 易科奇通信技术(深圳)有限公司 Embedded equipment firmware upgrading device and method, embedded equipment and storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10402273B2 (en) * 2016-12-14 2019-09-03 Microsoft Technology Licensing, Llc IoT device update failure recovery
WO2018120213A1 (en) * 2016-12-30 2018-07-05 深圳配天智能技术研究院有限公司 Firmware updating method and controller
CN107220091B (en) * 2017-06-08 2020-06-26 成都欧飞凌通讯技术有限公司 Upgrading and switching method for 100G CFP (circulating fluid protocol) main/standby image file
CN108549539A (en) * 2018-01-23 2018-09-18 青岛海尔科技有限公司 A kind of method and device carrying out equipment remote upgrade
CN109189445B (en) * 2018-10-12 2022-03-15 武汉微智创大科技有限公司 Method for upgrading program of equipment of Internet of things

Also Published As

Publication number Publication date
CN112527322A (en) 2021-03-19
WO2021036917A1 (en) 2021-03-04

Similar Documents

Publication Publication Date Title
WO2021036917A1 (en) Method and apparatus for upgrading system in internet of things device, device, and storage medium
JP6291248B2 (en) Firmware upgrade error detection and automatic rollback
JP2010541105A (en) Firmware image update and management
CN107291510B (en) Rapid starting method for Linux vehicle-mounted information system
CN110837388B (en) Software upgrading method of robot, upgrading server, robot and storage medium
WO2015147981A1 (en) Initialization trace of a computing device
CN112612524A (en) Method, device and equipment for starting Linux system and storage medium
CN109101247A (en) The method, apparatus and server of driver are installed
CN111459524A (en) Software upgrading method, device and system
CN114020340B (en) Server system and data processing method thereof
CN113806139B (en) Operating system recovery method, operating system recovery device, storage medium and computer program product
TW202131170A (en) Firmware corruption recovery
JP2017078998A (en) Information processor, log management method, and computer program
CN105868038B (en) Memory error processing method and electronic equipment
CN115951920A (en) Mobile equipment upgrading method and device, storage unit and mobile equipment
CN110688130A (en) Physical machine deployment method, physical machine deployment device, readable storage medium and electronic equipment
CN111208949B (en) Method for determining data rollback time period in distributed storage system
CN103473081A (en) Operant method after system updating of terminal and terminal
CN111124459B (en) Method and device for updating service logic of FPGA cloud server
CN104750579A (en) Method and device for manufacturing memory mirroring
CN110740382A (en) Method, device, television and medium for avoiding undesired automatic restart of television
US20230350755A1 (en) Coordinated operating system rollback
US20240020103A1 (en) Parallelizing data processing unit provisioning
US20240036896A1 (en) Generating installation images based upon dpu-specific capabilities
US12014185B2 (en) Unified boot image for multiple operating systems