CN109669708B - Remote upgrading method for modular Internet of things terminal equipment - Google Patents

Remote upgrading method for modular Internet of things terminal equipment Download PDF

Info

Publication number
CN109669708B
CN109669708B CN201811301601.0A CN201811301601A CN109669708B CN 109669708 B CN109669708 B CN 109669708B CN 201811301601 A CN201811301601 A CN 201811301601A CN 109669708 B CN109669708 B CN 109669708B
Authority
CN
China
Prior art keywords
firmware
upgrade package
module
activation
upgrading
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN201811301601.0A
Other languages
Chinese (zh)
Other versions
CN109669708A (en
Inventor
王浩
胡中卫
林志蒙
赵继高
张维史
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Goldcard Smart Group Co Ltd
Original Assignee
Goldcard Smart Group Co Ltd
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 Goldcard Smart Group Co Ltd filed Critical Goldcard Smart Group Co Ltd
Priority to CN201811301601.0A priority Critical patent/CN109669708B/en
Publication of CN109669708A publication Critical patent/CN109669708A/en
Application granted granted Critical
Publication of CN109669708B publication Critical patent/CN109669708B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Abstract

The application provides a remote upgrading method for a modularized Internet of things terminal device, belongs to the field of Internet of things, and comprises the steps of generating and storing a firmware upgrading package. And enabling a main module in the terminal equipment to inquire whether the firmware upgrade package exists in the control equipment, if so, erasing files in an upgrade package downloading area in the terminal equipment, and downloading the firmware upgrade package to the erased upgrade package downloading area. And the main module is enabled to verify the downloaded firmware upgrade package, the verification result is sent to the control equipment, the control equipment sends an activation instruction including the integrity verification value of the firmware upgrade package to the terminal equipment when the verification is successful, and the terminal equipment receives the activation instruction sent by the control equipment to activate the upgrade program. By separately processing the firmware downloading step and the firmware activating step, the firmware upgrading operation can be selected or abandoned according to the specific downloading result after the firmware is downloaded, and the defect that the automatic activation and upgrading is easy to cause endless loop after the firmware is downloaded is avoided.

Description

Remote upgrading method for modular Internet of things terminal equipment
Technical Field
The application belongs to the field of Internet of things, and particularly relates to a remote upgrading method for modular Internet of things terminal equipment.
Background
Along with the requirement on product intellectualization, the functions of the internet of things equipment are more and more complex, equipment manufacturers generally use modularized design in consideration of product reliability, expandability and function reusability, namely, a certain part of functions are completed by special modules, and the multiple modules are matched together to realize the functions of the equipment.
In order to cope with program defects or new function addition of the internet of things equipment, firmware upgrading is inevitable, In the prior art, an In Application Programming (IAP) technology is combined with an upgrading tool to realize module upgrading, but a maintenance worker is still required to perform field processing, and the operation is complex and time-consuming.
The upgrading method commonly used by the terminal equipment of the internet of things at present is to automatically enter an activated upgrading process after an upgrading firmware is received, the upgrading method is easy to cause equipment upgrading failure due to firmware damage, and the equipment cannot be continuously used due to the fact that the equipment is trapped in a dead cycle due to the firmware damage.
Disclosure of Invention
In order to solve the defects and shortcomings in the prior art, the application provides the remote upgrading method for the modularized Internet of things terminal equipment, and the defect that the dead circulation is easily caused by automatic activation and upgrading after firmware is downloaded is overcome.
In order to achieve the above technical object, in one aspect, the present application provides a remote upgrade method for a modular terminal device of the internet of things, which is suitable for a control device to control a firmware upgrade process of the terminal device, where a master module and a slave module controlled by the master module are provided in the terminal device based on a side of the control device, and the remote upgrade method includes:
generating and storing a firmware upgrade package;
receiving query information of a main module in the terminal equipment, and sending a firmware upgrade package to the terminal equipment according to a download request sent by the main module;
receiving a verification result sent by the terminal equipment;
and when the verification is successful, sending an activation instruction including the integrity verification value of the firmware upgrade package to the terminal equipment, and receiving an activation result replied by the terminal equipment.
Optionally, the remote upgrade method further includes:
and when the verification fails, deleting the stored firmware upgrading packet.
On the other hand, the remote upgrading method for the terminal equipment of the modularized internet of things is suitable for the control equipment to control the firmware upgrading process of the terminal equipment, and based on the terminal equipment side, the remote upgrading method comprises the following steps:
enabling a main module in the terminal equipment to inquire whether a firmware upgrade package is stored in the control equipment or not;
if the firmware upgrade package exists, erasing files in an upgrade package downloading area in the terminal equipment, sending a downloading request to the control equipment, and downloading the firmware upgrade package to the erased upgrade package downloading area;
the main module checks the downloaded firmware upgrading packet and sends a checking result to the control equipment;
and when the verification is successful, receiving an activation instruction which is sent by the control equipment and comprises a firmware upgrade package integrity verification value, and activating an upgrade program based on the downloaded firmware upgrade package.
Optionally, the remote upgrade method includes:
and receiving the generated information of the firmware upgrade package pushed by the terminal equipment.
Optionally, the instructing the main module to check the downloaded firmware upgrade package, and send a check result to the control device includes:
enabling the main module to calculate the integrity check value of the firmware upgrade package;
comparing the integrity check value obtained by calculation with the integrity check value stored in the firmware upgrade package;
if the comparison result is consistent, the verification is successful;
if the comparison result is different, the verification is failed.
Optionally, the receiving an activation instruction including a firmware upgrade package integrity check value sent by the control device, and performing an activation upgrade program based on a downloaded firmware upgrade package includes:
comparing the integrity check value in the activation instruction with the integrity check value obtained by calculation;
and starting the firmware upgrading package to upgrade the firmware under the condition that the comparison result is consistent.
Optionally, the enabling the firmware upgrade package to perform firmware upgrade when the comparison result is consistent includes:
analyzing the module identification number of the file in the firmware upgrade package, and if the module identification number is the number of the main module, starting the main module from an IAP program;
after the IAP program is started, erasing files in the application program area, copying the firmware upgrade package stored in the upgrade package downloading area to the application program area, and verifying the copied firmware upgrade package again;
if the verification is passed, the firmware upgrade package is backed up to the upgrade package backup area,
the activation flag is set in the memory of the primary module as successfully activated after the backup is completed,
and guiding the firmware upgrading package in the application program area, inquiring the activation identifier after starting, and if the content of the activation identifier is successfully activated, sending the successfully activated activation result to the control equipment.
Optionally, the remote upgrade method further includes:
if the verification fails, erasing the firmware upgrade package copied to the application program area;
copying the firmware located in the upgrade package backup area to the application program area,
the activation flag is set in the memory of the master module as activation failure after the copying is completed,
and guiding a firmware upgrading package positioned in the application program area, inquiring the activation identifier after starting, and if the content of the activation identifier is activation failure, sending an activation result of the activation failure to the control equipment.
Optionally, the enabling of the firmware upgrade package for firmware upgrade if the comparison result is consistent includes:
analyzing the module identification number of the file in the firmware upgrade package, and if the module identification number is the serial number of the slave module, enabling the slave module to start an IAP program;
after the IAP program is started, erasing the files in the application program area, and sending ready information to the main module after the erasing is finished;
receiving a firmware upgrading packet from the main module, storing the firmware upgrading packet in the application program area, commanding the main module to start upgrading firmware by the auxiliary module, and verifying the received firmware upgrading packet again by the auxiliary module;
if the verification is passed, the slave module IAP program guides the enabled application program area to upgrade the firmware;
the master module diagnoses that the slave module works normally, and backs up the upgrade package of the upgrade package downloading area to the upgrade package backup area of the slave module;
the master module sends the activation result that the control device has been successfully activated.
Optionally, the remote upgrade method further includes:
if the verification fails, the master module diagnoses that the slave module works abnormally, the master module orders the slave module to erase the application program area of the slave module, and sends ready information to the master module after the erasing is finished;
and the master module restores the firmware of the backup area of the slave module upgrading pack to the slave module, and sends the activation result of the activation failure to the control equipment after the restoration is finished.
The beneficial effect that technical scheme that this application provided brought is:
1. by separately processing the firmware downloading step and the firmware activating step, the firmware upgrading operation can be selected or abandoned according to the specific downloading result after the firmware is downloaded, and the defect that the automatic activation and upgrading is easy to cause endless loop after the firmware is downloaded is avoided.
2. The main module of the terminal equipment of the internet of things can diagnose the running state of the slave module, if abnormal conditions such as power failure occur in the upgrading process, the corresponding module cannot run normally, and the main module can try to recover the module firmware after diagnosis.
3. The communication between the application programs can be realized by the IAP program, the application programs can inform the IAP program to start the upgrading firmware, and the IAP program can inform the application program of the upgrading firmware activation result.
Drawings
In order to more clearly illustrate the technical solutions of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings without creative efforts.
Fig. 1 is a schematic structural diagram of an internet of things device provided in the present application;
fig. 2 is a schematic flow chart of a remote upgrading method for a modular internet of things terminal device provided by the present application.
Detailed Description
To make the structure and advantages of the present application clearer, the structure of the present application will be further described with reference to the accompanying drawings.
Example one
The application provides a remote upgrading method for a modularized Internet of things terminal device, which is suitable for a control device to control the firmware upgrading process of the terminal device.
The method is applied to the Internet of things equipment comprising control equipment and terminal equipment. As shown in fig. 1, the terminal device includes a master module and a plurality of slave modules, at least one wireless communication module is present in the slave modules for implementing data interaction between the terminal device and external internet devices, the master module is connected with each slave module in a wired manner, and the master module has a control right of the whole terminal device.
The slave module can be a GPRS module, an NB-IoT module and other wide area network wireless modules, can be directly accessed to a telecommunication operator base station and is finally accessed to the Internet, and the Internet of things control equipment is certain equipment in the Internet; the slave module can also be a ZigBee module, a Wifi module and other local area network wireless modules, the internet of things control device is connected with the internet of things terminal device through the slave module 1 in a downlink mode, the internet of things control device can be connected with the internet of things terminal device in an uplink mode through a GPRS module, an NB-IoT module or a wired mode and the like, and the internet of things control device is controlled by one device in the internet.
Based on the above module introduction, a flowchart of the remote upgrade method is shown in fig. 2, and includes:
and S11, generating and storing the firmware upgrade package.
And S12, enabling the main module in the terminal device to inquire whether the firmware upgrade package exists in the control device.
And S13, receiving query information of a main module in the terminal equipment, and sending the firmware upgrade package to the terminal equipment according to a download request sent by the main module.
And S14, if the firmware upgrade package exists, erasing the file in the upgrade package downloading area in the terminal equipment, sending a downloading request to the control equipment, and downloading the firmware upgrade package to the erased upgrade package downloading area.
And S15, enabling the main module to verify the downloaded firmware upgrade package, and sending the verification result to the control equipment.
And S16, receiving the verification result sent by the terminal equipment.
And S17, when the verification is successful, sending an activation instruction including the integrity verification value of the firmware upgrade package to the terminal equipment, and receiving an activation result replied by the terminal equipment.
And S18, when the verification is successful, receiving an activation instruction including a firmware upgrade package integrity verification value sent by the control equipment, and activating an upgrade program based on the downloaded firmware upgrade package.
In implementation, the main step of the remote upgrade method is to generate a firmware upgrade package including an adapter module identification number, a firmware version number, a firmware size, and firmware integrity check information (such as a HASH value, CRC32, etc.) at the control device. Then, the main module in the terminal device is caused to send an inquiry request as to whether or not to generate the firmware upgrade package to the control module.
And at the moment, if the firmware upgrading packet exists in the control equipment, the firmware upgrading packet is sent to the main module in the terminal equipment. After receiving the firmware upgrade package, the main module firstly checks the integrity of the firmware upgrade package for the first time and sends a check result to the control equipment.
If the verification result shows that the firmware upgrading packet is complete, the control equipment is made to send an activation instruction to the main module, so that the main module can perform an upgrading process based on the firmware upgrading packet after receiving the activation instruction; and if the verification result shows that the firmware upgrading packet is incomplete, the control equipment deletes the stored firmware upgrading packet.
It should be noted that even if the verification result indicates that the firmware upgrade package is complete, the control device may select whether to perform the subsequent activation operation according to the actual situation, and the fact that the firmware upgrade package is complete does not mean that the subsequent activation operation must be performed.
In step S12, in addition to causing the main module to send an inquiry request to the control device to obtain the firmware upgrade package, the control device may further cause the control device to push information that the firmware upgrade package has been generated to the terminal device after generating the firmware upgrade package, and cause the main module to inquire whether the upgrade package is adapted to a certain module.
Optionally, the verification step proposed in step S15 includes:
s151, enabling the main module to calculate an integrity check value of the firmware upgrade package;
s152, comparing the integrity check value obtained by calculation with the integrity check value stored in the firmware upgrade package;
s153, if the comparison results are consistent, the verification is successful;
and S154, if the comparison results are different, indicating that the verification fails.
In practice, the integrity check used herein corresponds to a hash algorithm, sometimes also referred to as a hash in terms of transliteration. The hashing algorithm can transform data of an arbitrary size (raw data) into small data of a fixed size.
Hash algorithms are often used as integrity checks for files because of their irreversibility and resultant uniqueness.
Optionally, the step of activating the upgrade proposed by S18 includes:
s181, comparing the integrity check value in the activation instruction with the integrity check value obtained by calculation;
and S182, enabling the firmware upgrading package to upgrade the firmware under the condition that the comparison result is consistent.
In implementation, the firmware upgrading operation can be performed after an activation instruction sent by the control device is received. Before the firmware upgrade operation, the integrity check value in the activation command needs to be extracted and compared with the integrity check value calculated in step S15, that is, the integrity check of the firmware upgrade package needs to be performed again to ensure that the firmware upgrade operation can be performed correctly.
In particular, the method comprises the following steps of,
the main module can actively acquire an activation instruction on the Internet of things control equipment, or the Internet of things control equipment actively issues the activation instruction; and after receiving the activation instruction, checking an upgrade firmware integrity check value in the activation instruction, enabling the upgrade firmware if the upgrade firmware integrity check value is consistent with an upgrade firmware integrity check value of an 'upgrade package downloading area', and waiting for the next activation instruction or restarting upgrading if the upgrade firmware integrity check value is inconsistent with the upgrade firmware integrity check value of the 'upgrade package downloading area'.
The main module checks the module identification number adapted to the upgrade package of the 'upgrade package downloading area', and if the identification number is the main module, the next process is started; if the identification number is a certain slave module, the process of upgrading the slave module shown in the subsequent S1824-S1828 is entered.
The main module replies the activation result of the control equipment and the firmware version numbers of all the modules according to the firmware activation result, wherein the activation result comprises: the "activation success", "no activatable firmware", "the activation instruction does not match the upgrade firmware stored in the" upgrade package download area "of the main module", and "activation failure" and the like.
Optionally, if the adapter module is designated as the main module in the firmware upgrade package, the firmware upgrade step is:
s1821, analyzing the module identification number of the file in the firmware upgrade package, and if the module identification number is the number of the main module, enabling the main module to start an IAP program;
s1822, after the IAP program is started, erasing the files in the application program area, copying the firmware upgrade package stored in the upgrade package downloading area to the application program area, and verifying the copied firmware upgrade package again;
s1823, if the verification is passed, backing up the firmware upgrade package to the upgrade package backup area,
s1824, after the backup is completed, the activation flag is set in the memory of the primary module as successfully activated,
s1825, guiding the firmware upgrade package in the application program area, inquiring the activation identifier after starting, and if the activation identifier is successfully activated, sending the successfully activated activation result to the control device.
In contrast to the step S1823,
s1826, if the verification fails, erasing the firmware upgrade package copied to the application program area;
s1827, copying the firmware in the upgrade package backup area to the application program area,
s1828, after the copy is completed, setting the activation flag in the memory of the master module as activation failure,
s1829, guiding the firmware upgrade package in the application program area, inquiring the activation identifier after starting, and if the activation identifier is failed, sending the activation result of the activation failure to the control device.
In implementation, during the firmware upgrading process, an application program area and an upgrade package backup area in the main module are involved. The main module enters an In-Application Programming (IAP) program, the main module Application program sets an activation identifier (the identifier is not lost due to system restart) to a specific position of a memory (such as Flash and EEPROM), the main module is restarted, and the main module enters the IAP program;
copying the upgrade firmware to the application program area of the main module, setting up an IAP program check activation identifier, erasing the application program area of the main module, and copying the upgrade firmware of the upgrade package download area to the application program area of the main module;
verifying the upgrading firmware in the application program area, verifying whether the upgrading firmware integrity check value is matched with the integrity check value of the upgrading firmware in the upgrading packet downloading area after the upgrading firmware moves to the application program area, and entering the processes from S1823 to S1825 if the upgrading firmware integrity check value is matched with the integrity check value of the upgrading firmware in the upgrading packet downloading area; if not, the flow proceeds to the flows from S1826 to S1829;
backing up the upgrade package of the main module, and backing up the upgrade firmware of the ' upgrade package download area ' to the ' upgrade package backup area of the main module;
enabling a main module to upgrade firmware, setting an activation result identifier (the identifier is not lost due to system restart) to be successful by a main module IAP program to a specific position of a memory (such as Flash and EEPROM), guiding and enabling the firmware of an application program area of the main module by the main module IAP program, checking the activation result identifier to be successful after the main module application program is started, and informing a control device of successful activation;
the method comprises the steps of recovering an old firmware of a main module, erasing an application program area of the main module by an IAP (application program interface) program, copying the firmware of an upgrade package backup area of the main module to an application program area of the main module, setting an activation result identifier to be failed by the IAP program of the main module to a specific position of a memory (such as Flash and EEPROM), guiding and enabling the firmware of the application program area by the IAP program of the main module, checking the activation result identifier to be failed after the application program of the main module is started, and informing a control device of activation failure.
Optionally, if the adapter module is designated as the slave module in the firmware upgrade package, the firmware upgrade step is:
s1921, analyzing a module identification number of a file in the firmware upgrade package, and enabling the slave module to start an IAP program if the module identification number is the serial number of the slave module;
s1922, after the IAP program is started, erasing the files in the application program area, and sending ready information to the main module after the erasing is finished;
s1923, receiving the firmware upgrading packet from the master module, storing the firmware upgrading packet in the application program area, commanding the slave module to start upgrading firmware by the master module, and verifying the received firmware upgrading packet again by the slave module;
s1924, if the verification is passed, the IAP program of the slave module guides and enables the application program area upgrading firmware, the master module diagnoses that the slave module works normally, and an upgrading packet of the upgrading packet downloading area is backed up to the upgrading packet backup area of the slave module;
and S1925, activating the successfully activated control device by the master module.
S1926, if the verification fails, the master module diagnoses that the slave module works abnormally, the master module orders the slave module to erase the application program area of the slave module, and sends ready information to the master module after the erasing is finished;
and S1927, the master module restores the firmware of the slave module upgrade patch backup area to the slave module, and after restoration is completed, the master module sends an activation result of activation failure to the control equipment.
In implementation, similar to the upgrading step of the master module in the foregoing steps, the upgrading step of the slave module proposed in this embodiment is as follows:
the master module orders the slave module to enter an IAP program, and the slave module returns a confirmation and then enters the IAP program;
the master module orders the slave module to prepare to receive the upgrade package, the slave module erases the application program area of the slave module, replies confirmation and informs the master module of the readiness of the slave module;
the master module transmits the upgrade package to the slave module in a blocking transmission mode, after the slave module receives the upgrade package, the upgrade firmware is stored in an application program area and replies a confirmation, and after the master module receives the confirmation, the master module sends the next upgrade package until the upgrade package is transmitted;
the master module commands the slave module to activate the upgrade firmware, the slave module calculates the integrity check value of the upgrade firmware and compares the integrity check value with the integrity check value in the upgrade package, if the integrity check value is consistent with the integrity check value, the operation goes to S1924-S1925, and if the integrity check value is not consistent with the integrity check value, the operation goes to S1926-S1927;
upgrading the firmware from a module IAP program boot-up enabling 'application program area';
the master module backs up the upgrade package from the upgrade package downloading area to the upgrade package backup area of the slave module and informs the internet of things control module of successful activation;
the main module restores the firmware of the slave module in the slave module upgrade package backup area, and informs the Internet of things control module of failed activation after the restoration is completed.
In addition, the upgrading steps for the slave modules also comprise the following alternatives:
s2021, the master module orders the slave module to enter an IAP program, and the slave module replies confirmation and enters the IAP program;
s2022, the master module orders the slave module to prepare to receive the upgrade package, the slave module erases the application program area of the slave module, replies confirmation and informs the master module of the readiness of the slave module;
s2023, the master module transmits the upgrade package to the slave module in a blocking mode, after the slave module receives the upgrade package, the upgrade firmware is stored in an application program area and replies confirmation, and after the master module receives the confirmation, the master module sends the next upgrade package until the upgrade package is transmitted;
s2024, the master module commands the slave module to activate the upgrade firmware, the slave module calculates the integrity check value of the upgrade firmware and compares the integrity check value with the integrity check value in the upgrade package, if the integrity check value is consistent with the integrity check value, the operation goes to S2025-S2026, otherwise, the operation goes to S2027;
s2025, backing up an 'application program area' upgrade package from the module IAP program to an 'upgrade package backup area' of the slave module;
s2026, the slave module IAP program guides to start the 'application program area' to upgrade the firmware, the master module diagnoses that the slave module works normally, and informs the Internet of things control module of successful activation;
s2027, the master module diagnoses that the slave module works abnormally, instructs an IAP program of the slave module to recover the firmware of an 'upgrade package backup area' of the slave module, and after the recovery is completed, the master module diagnoses that the slave module works normally and informs the control module of the Internet of things of failure in activation.
The alternative main module memory shown in steps S2021 to S2027 does not need to backup the current operation of the slave module, thereby reducing the cost of the main module memory, and meanwhile, in the upgrading process, the power failure or the upgrading firmware transmission abnormality occurs, and the firmware recovery does not need to be downloaded from the main module memory, so that the firmware recovery speed is faster.
The application provides a remote upgrading method for modular Internet of things terminal equipment, which comprises the steps of generating and storing a firmware upgrading package. And enabling a main module in the terminal equipment to inquire whether a firmware upgrade package exists in the control equipment. And receiving query information of a main module in the terminal equipment, and sending the firmware upgrade package to the terminal equipment according to a download request sent by the main module. If the firmware upgrade package exists, the file in the upgrade package downloading area in the terminal equipment is erased, a downloading request is sent to the control equipment, and the firmware upgrade package is downloaded to the erased upgrade package downloading area. And enabling the main module to check the downloaded firmware upgrading package and sending a checking result to the control equipment. And receiving a verification result sent by the terminal equipment. And when the verification is successful, sending an activation instruction including the integrity verification value of the firmware upgrade package to the terminal equipment, and receiving an activation result replied by the terminal equipment. And the terminal equipment receives an activation instruction which is sent by the control equipment and comprises a firmware upgrade package integrity check value, and activates an upgrade program based on the downloaded firmware upgrade package. By separately processing the firmware downloading step and the firmware activating step, the firmware upgrading operation can be selected or abandoned according to the specific downloading result after the firmware is downloaded, and the defect that the automatic activation and upgrading is easy to cause endless loop after the firmware is downloaded is avoided.
The sequence numbers in the above embodiments are merely for description, and do not represent the sequence of the assembly or the use of the components.
The above description is only exemplary of the present application and should not be taken as limiting the present application, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (8)

1. The remote upgrading method for the modularized Internet of things terminal device is suitable for control equipment to control the firmware upgrading process of the terminal device, and is characterized in that a master module and a slave module controlled by the master module are arranged in the terminal device based on the side of the control equipment, and the remote upgrading method comprises the following steps:
generating and storing a firmware upgrade package;
receiving a request of inquiring whether a firmware upgrading package exists in a main module in the terminal equipment, and if the firmware upgrading package exists, sending the firmware upgrading package to the terminal equipment according to a downloading request sent by the main module;
receiving a verification result which is sent by the terminal equipment and used for verifying the downloaded firmware upgrading packet;
when the verification is successful, sending an activation instruction including a firmware upgrade package integrity verification value to the terminal equipment, and receiving an activation result of activating an upgrade program based on a downloaded firmware upgrade package replied by the terminal equipment;
the activating and upgrading program based on the downloaded firmware upgrading package comprises the following steps:
comparing the integrity check value in the activation instruction with the integrity check value obtained by calculation;
starting a firmware upgrading package to upgrade the firmware under the condition that the comparison result is consistent;
the enabling of the firmware upgrade package for firmware upgrade under the condition that the comparison result is consistent comprises the following steps:
analyzing the module identification number of the file in the firmware upgrade package, and if the module identification number is the number of the main module, starting the main module from an IAP program;
after the IAP program is started, erasing files in the application program area, copying the firmware upgrade package stored in the upgrade package downloading area to the application program area, and verifying the copied firmware upgrade package again;
if the upgrade patch copy passes the verification, backing up the firmware upgrade patch to an upgrade patch backup area;
after the backup is finished, setting an activation identifier in a memory of the main module as successful activation, guiding a firmware upgrade package in the application program area, inquiring the activation identifier after the startup, and if the content of the activation identifier is successful activation, sending an activation result of the successful activation to the control device.
2. The remote upgrading method for the modular internet of things terminal device according to claim 1, further comprising:
and when the verification fails, deleting the stored firmware upgrading packet.
3. The remote upgrading method for the modularized Internet of things terminal device is suitable for controlling the firmware upgrading process of the terminal device by the control device, and is characterized by comprising the following steps of based on the terminal device side:
enabling a main module in the terminal equipment to inquire whether a firmware upgrade package is stored in the control equipment or not;
if the firmware upgrade package exists, erasing files in an upgrade package downloading area in the terminal equipment, sending a downloading request to the control equipment, and downloading the firmware upgrade package to the erased upgrade package downloading area;
the main module checks the downloaded firmware upgrade package and sends the checking result to the control equipment;
when the verification is successful, receiving an activation instruction which is sent by the control equipment and comprises a firmware upgrade package integrity verification value, and activating an upgrade program based on a downloaded firmware upgrade package;
the receiving of the activation instruction including the integrity check value of the firmware upgrade package sent by the control device and the activation of the upgrade program based on the downloaded firmware upgrade package include:
comparing the integrity check value in the activation instruction with the integrity check value obtained by calculation;
starting a firmware upgrading package to upgrade the firmware under the condition that the comparison result is consistent;
the enabling of the firmware upgrade package for firmware upgrade under the condition that the comparison result is consistent comprises the following steps:
analyzing the module identification number of the file in the firmware upgrade package, and if the module identification number is the number of the main module, starting the main module from an IAP program;
after the IAP program is started, erasing files in the application program area, copying the firmware upgrade package stored in the upgrade package downloading area to the application program area, and verifying the copied firmware upgrade package again;
if the upgrade patch copy passes the verification, backing up the firmware upgrade patch to an upgrade patch backup area;
after the backup is completed, the activation mark is set in the memory of the main module to be successfully activated, the firmware upgrade package in the application program area is guided, the activation mark is inquired after the firmware upgrade package is started, and if the content of the activation mark is successfully activated, the successfully activated activation result is sent to the control equipment.
4. The remote upgrading method for the modular internet of things terminal equipment according to claim 3, wherein the remote upgrading method comprises the following steps:
and receiving the generated information of the firmware upgrade package pushed by the control equipment.
5. The remote upgrading method for the modular internet of things terminal device according to claim 3, wherein the enabling the main module to verify the downloaded firmware upgrade package and send the verification result to the control device comprises:
enabling the main module to calculate the integrity check value of the firmware upgrade package;
comparing the integrity check value obtained by calculation with the integrity check value stored in the firmware upgrade package;
if the comparison result is consistent, the verification is successful;
if the comparison result is different, the verification is failed.
6. The remote upgrading method for the modular internet of things terminal device according to claim 3, further comprising:
if the verification fails, erasing the firmware upgrade package copied to the application program area;
copying the firmware located in the upgrade package backup area to the application program area,
the activation flag is set in the memory of the master module as activation failure after the copying is completed,
and guiding a firmware upgrading package positioned in the application program area, inquiring the activation identifier after starting, and if the content of the activation identifier is activation failure, sending an activation result of the activation failure to the control equipment.
7. The remote upgrading method for the modular internet of things terminal device according to claim 3, wherein the enabling of the firmware upgrading package for firmware upgrading if the comparison result is consistent comprises:
analyzing the module identification number of the file in the firmware upgrade package, and if the module identification number is the serial number of the slave module, enabling the slave module to start an IAP program;
after the IAP program is started, erasing the files in the application program area, and sending ready information to the main module after the erasing is finished;
receiving a firmware upgrading packet from the master module, storing the firmware upgrading packet in an application program area, commanding the slave module to start upgrading firmware by the master module, and verifying the received firmware upgrading packet again by the slave module;
if the verification is passed, the slave module IAP program guides the enabled application program area to upgrade the firmware;
the master module diagnoses that the slave module works normally, and backs up the upgrade package of the upgrade package downloading area to the upgrade package backup area of the slave module;
the master module sends the activation result that has been successfully activated to the control device.
8. The remote upgrading method for the modular internet of things terminal device according to claim 7, further comprising:
if the verification fails, the master module diagnoses that the slave module works abnormally, the master module orders the slave module to erase the application program area of the slave module, and sends ready information to the master module after the erasing is finished;
and the master module restores the firmware of the backup area of the slave module upgrading pack to the slave module, and sends the activation result of the activation failure to the control equipment after the restoration is finished.
CN201811301601.0A 2018-11-02 2018-11-02 Remote upgrading method for modular Internet of things terminal equipment Active CN109669708B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811301601.0A CN109669708B (en) 2018-11-02 2018-11-02 Remote upgrading method for modular Internet of things terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811301601.0A CN109669708B (en) 2018-11-02 2018-11-02 Remote upgrading method for modular Internet of things terminal equipment

Publications (2)

Publication Number Publication Date
CN109669708A CN109669708A (en) 2019-04-23
CN109669708B true CN109669708B (en) 2022-08-12

Family

ID=66141742

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811301601.0A Active CN109669708B (en) 2018-11-02 2018-11-02 Remote upgrading method for modular Internet of things terminal equipment

Country Status (1)

Country Link
CN (1) CN109669708B (en)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110427201A (en) * 2019-07-25 2019-11-08 金卡智能集团股份有限公司 A kind of NB mould group upgrade method, device, equipment and storage medium
CN110543318A (en) * 2019-08-30 2019-12-06 珠海格力电器股份有限公司 control device program updating method and device, storage medium and control device
CN112860283B (en) * 2019-11-12 2024-04-02 深圳怡化电脑股份有限公司 SP upgrade package self-identification upgrade method and device and computer equipment
CN111459522B (en) * 2020-04-01 2021-09-14 珠海格力电器股份有限公司 Air conditioner and communication module upgrading method thereof
CN111818554B (en) * 2020-07-03 2023-01-06 杭州电子科技大学 Method for improving remote upgrade success rate of large-scale NB-IoT terminal
CN111880823B (en) * 2020-07-17 2024-01-30 合肥移瑞通信技术有限公司 Method, system and medium for upgrading communication module by system and computer equipment
CN114071660A (en) * 2020-07-31 2022-02-18 中国电信股份有限公司 Narrowband Internet of things terminal, firmware upgrading method thereof, base station and communication system
CN111998510B (en) * 2020-08-28 2022-02-18 海信(山东)空调有限公司 Air conditioner and control method thereof
CN112910714B (en) * 2021-03-05 2022-04-22 中国电子科技集团公司第三十八研究所 Remote firmware upgrading method for Internet of things terminal equipment with master-slave machine structure
CN113238779A (en) * 2021-05-24 2021-08-10 深圳市网是科技有限公司 High-reliability upgrading method for single embedded device composed of multiple modules
CN115904457B (en) * 2023-03-01 2024-01-30 江苏安世朗智能科技有限公司 Remote upgrading system and method for computer firmware based on Internet of things

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102314369A (en) * 2011-10-09 2012-01-11 杭州先锋电子技术股份有限公司 Self-upgrade method for equipment in remote online monitoring system
CN104503796A (en) * 2014-12-25 2015-04-08 浙江中控研究院有限公司 IAP (Internet Access Provider) based configurable full-network remote node firmware upgrading method
CN104572222A (en) * 2015-02-02 2015-04-29 深圳市新联锋科技有限公司 Main program upgrading method and device for supporting upgrading of main program
CN108337120A (en) * 2018-02-01 2018-07-27 北京安控科技股份有限公司 A kind of remote upgrade method of internet-of-things terminal equipment

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7904518B2 (en) * 2005-02-15 2011-03-08 Gytheion Networks Llc Apparatus and method for analyzing and filtering email and for providing web related services

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102314369A (en) * 2011-10-09 2012-01-11 杭州先锋电子技术股份有限公司 Self-upgrade method for equipment in remote online monitoring system
CN104503796A (en) * 2014-12-25 2015-04-08 浙江中控研究院有限公司 IAP (Internet Access Provider) based configurable full-network remote node firmware upgrading method
CN104572222A (en) * 2015-02-02 2015-04-29 深圳市新联锋科技有限公司 Main program upgrading method and device for supporting upgrading of main program
CN108337120A (en) * 2018-02-01 2018-07-27 北京安控科技股份有限公司 A kind of remote upgrade method of internet-of-things terminal equipment

Also Published As

Publication number Publication date
CN109669708A (en) 2019-04-23

Similar Documents

Publication Publication Date Title
CN109669708B (en) Remote upgrading method for modular Internet of things terminal equipment
CN111666081B (en) Git-based project version release method, device, equipment and medium
CN106843957B (en) System firmware upgrading method and device
CN110083374B (en) Upgrade rollback method, system and terminal equipment
CN103699421B (en) Embedded device method for upgrading system and its device
US11467818B2 (en) Software update device, software update method, and software update system
CN107193612B (en) Version upgrading method and device for mobile terminal
US20120117557A1 (en) Method and system for upgrading wireless data card
CN112910714B (en) Remote firmware upgrading method for Internet of things terminal equipment with master-slave machine structure
CN112559003B (en) Domain controller software upgrading method and device and domain controller
CN108334331B (en) Safe electric vehicle battery management system software upgrading method
CN105183515A (en) Cloud deck firmware updating method and device
CN110990036A (en) OTA upgrading method and device for power change cabinet, power change equipment and storage medium
US20240070026A1 (en) Method For Remote Upgrade and Rollback of Unmanned Aerial Vehicle (UAV) Software
CN103761131B (en) A kind of many board part automatic update methods and system based on memory sharing
CN105045640A (en) Software upgrading method and device and intelligent equipment
CN115454469A (en) Mirror image updating method and device, chip, electronic equipment and storage medium
CN108984200A (en) A kind of timing updates the method and device of firmware
CN109408099B (en) Remote FPGA firmware code updating system, method and medium
CN114489732A (en) Method and device for updating FPGA (field programmable Gate array) firmware of equipment and electronic equipment
CN112685068A (en) Method for remotely upgrading BOOT image file and computer readable medium
CN112804071A (en) On-line upgrading method, upgrading file providing method, equipment and storage medium
CN114090051A (en) eMMC firmware version online upgrading method, device, computer equipment and storage medium
US9529581B2 (en) Circuit and method for writing program codes of basic input/output system
CN112732301A (en) Vehicle upgrading method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant