CN108833128A - A kind of method that equipment updates - Google Patents
A kind of method that equipment updates Download PDFInfo
- Publication number
- CN108833128A CN108833128A CN201810343973.3A CN201810343973A CN108833128A CN 108833128 A CN108833128 A CN 108833128A CN 201810343973 A CN201810343973 A CN 201810343973A CN 108833128 A CN108833128 A CN 108833128A
- Authority
- CN
- China
- Prior art keywords
- update
- equipment
- data
- server
- updating
- 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.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 54
- 230000008569 process Effects 0.000 claims abstract description 26
- 238000004891 communication Methods 0.000 claims description 11
- 238000003860 storage Methods 0.000 claims description 7
- 238000004364 calculation method Methods 0.000 claims description 6
- 238000012545 processing Methods 0.000 description 7
- 230000006870 function Effects 0.000 description 6
- 230000005540 biological transmission Effects 0.000 description 4
- 238000010586 diagram Methods 0.000 description 3
- 230000007246 mechanism Effects 0.000 description 3
- 238000002360 preparation method Methods 0.000 description 3
- 238000012795 verification Methods 0.000 description 3
- 230000005856 abnormality Effects 0.000 description 2
- 238000004458 analytical method Methods 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 230000003993 interaction Effects 0.000 description 2
- 238000004519 manufacturing process Methods 0.000 description 2
- KKIMDKMETPPURN-UHFFFAOYSA-N 1-(3-(trifluoromethyl)phenyl)piperazine Chemical compound FC(F)(F)C1=CC=CC(N2CCNCC2)=C1 KKIMDKMETPPURN-UHFFFAOYSA-N 0.000 description 1
- 230000002159 abnormal effect Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000007405 data analysis Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011038 discontinuous diafiltration by volume reduction Methods 0.000 description 1
- 230000008676 import Effects 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 230000009191 jumping Effects 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000036632 reaction speed Effects 0.000 description 1
- 230000002441 reversible effect Effects 0.000 description 1
- 239000011265 semifinished product Substances 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/0803—Configuration setting
- H04L41/0813—Configuration setting characterised by the conditions triggering a change of settings
- H04L41/082—Configuration setting characterised by the conditions triggering a change of settings the condition being updates or upgrades of network functionality
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/085—Retrieval of network configuration; Tracking network configuration history
- H04L41/0859—Retrieval of network configuration; Tracking network configuration history by keeping history of different configuration generations or by rolling back to previous configuration versions
- H04L41/0863—Retrieval of network configuration; Tracking network configuration history by keeping history of different configuration generations or by rolling back to previous configuration versions by rolling back to previous configuration versions
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/16—Threshold monitoring
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L61/00—Network arrangements, protocols or services for addressing or naming
- H04L61/50—Address allocation
- H04L61/5053—Lease time; Renewal aspects
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/34—Network arrangements or protocols for supporting network services or applications involving the movement of software or configuration parameters
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Stored Programmes (AREA)
Abstract
The present invention provides a kind of method that equipment updates, it includes:When equipment executes starting up's process to first part's completion, which reads local ip address;The equipment and first server, which are established, to be communicated to connect;The equipment is downloaded from the first server and parses update plan corresponding with itself;The equipment downloads corresponding more new data according to the update plan, from the first server;According to this, more new data executes update to the equipment;The equipment executes the second part of starting up's process.The method that equipment provided by the invention updates, update can be realized without additionally switching in specific renewal model in equipment, the burden of server and network also is alleviated without restarting and reinitialize the normal starting that equipment can be realized, updating plan and updating data separating after the completion of updating.
Description
Technical Field
The invention relates to the field of software management, in particular to a method for updating equipment through a network.
Background
For electronic equipment, in the development stage, software (including firmware) and adjustment parameters of the electronic equipment need to be updated frequently to realize corresponding functions and solve problems; in the production stage, software and configuration required by the user side during use are required to be written into equipment; after shipment, the software and configuration also need to be continuously completed and updated to the remote device for new problem resolution and improved performance. Therefore, how to update the motherboard (or called bare board) that has not been assembled into the finished device and the assembled finished device is a constant consideration for software designers. Especially, how to update a large amount of equipment existing in different stages and geographical positions more quickly, flexibly and reliably is also an urgent problem to be solved in the industry.
In the prior art, equipment updating needs to be switched to a specific updating mode, and needs to be switched to a common starting mode after updating is completed, and then the equipment is restarted and reinitialized, so that the process is tedious and tedious to execute; when the equipment is updated remotely, a large amount of data is downloaded, and the burden on the server and the internal storage space of the equipment is large. In addition, most logs exist in the local equipment, and analysis processing needs to be manually copied and then performed, so that the analysis processing is inconvenient.
Therefore, it is necessary to design a new device upgrade method to overcome the above-mentioned drawbacks.
Disclosure of Invention
The invention aims to provide a method for updating equipment, which can overcome the defects and realize quick and reliable updating.
To achieve the above object, the present invention provides a method for device upgrade, which comprises the steps of,
A. when the equipment executes the starting process till the first part is finished, the equipment reads the local IP address;
B. the device establishes a communication connection with a first server;
C. the equipment downloads and analyzes an updating plan corresponding to the equipment from the first server;
D. the equipment downloads corresponding updating data from the first server according to the updating plan;
E. the equipment executes corresponding updating according to the updating data, and enters a step Z after the updating is finished;
z, the equipment executes the second part of the starting process;
the device can enter a working state after sequentially executing the first part and the second part of the starting process.
Preferably, step a further comprises:
A1. if the device does not successfully read the local IP address of the device, entering step Z or A2;
and step A2, the equipment sets the local IP address of the equipment as a temporary specific IP address and enters the step B.
Preferably, the method further comprises the following steps between the step B and the step C:
B1. if the device and the first server are not successfully connected, judging whether the number of times of trying to establish the communication connection reaches a threshold value, if so, entering a step Y, otherwise, entering a step B;
wherein, the step Y: and canceling the updating and entering the step Z.
Preferably, if the operation in any one of the steps C to E fails, go to step Y; wherein, the step Y: cancel the update and enter step Z.
Preferably, the method further comprises the following steps between step D and step E:
D1. the equipment calculates and obtains a check code according to a check calculation formula and the downloaded update data;
D2. the equipment judges whether the check code is consistent with the corresponding check code in the first server or not;
D3. if yes, the downloaded update data is determined to be complete and correct, and step E is entered.
Preferably, step C further comprises: after the device successfully analyzes, checking the self data version, comparing the self data version with the analyzed data version in the updating plan, if the data version in the updating plan is newer than the self data version, entering a step D, otherwise entering a step Y; or,
between step D and step E, further comprising: D4. the device checks its own data version and compares it with the data version in the update data, if the data version in the update data is newer than the own data version, then step E is entered, otherwise step Y is entered.
Preferably, in step C, the device downloads a common update plan from the first server, and parses an update plan corresponding to the device from the common update plan;
the common update plan includes at least one group of update plans, each group of update plans includes:
a local IP address or device ID of a device to be updated, or a local IP address range or device ID range of a group of devices to be updated; and the number of the first and second groups,
identification information of at least one sub-update data corresponding to the device to be updated and/or identification information of at least one sub-update data group corresponding to the device or the group of devices to be updated;
the identification information of the sub-update data group corresponds to a sub-update data group in the first server, the sub-update data group comprises identification information of at least one sub-update data, and the identification information of the sub-update data corresponds to a sub-update data in the first server.
Preferably, step Y or step Z further comprises: the device records corresponding information into a log;
wherein, the recording of the corresponding information to the log by the device at least comprises one of the following steps:
x1. the log is stored in the internal storage space of the device;
x2. the device is connected with a second device via a serial port and sends the corresponding information to the second device, and the second device stores and/or displays the obtained corresponding information;
x3. the device transmits the corresponding information to a second server via the network, the second server stores, displays and/or transmits the obtained corresponding information to a corresponding third device; wherein the second server is the same as or different from the first server.
Preferably, the common update plan includes at least one of: updating plans of software, firmware and configuration parameters; and, the update data includes at least one of: software data, firmware data, configuration parameters.
Preferably, the apparatus comprises: finished equipment, or motherboards; the main board is matched with corresponding accessories to realize the function of finished equipment.
Compared with the prior art, the method for updating the equipment integrates the process of updating data in the starting process of the equipment, the equipment can be updated without preparing updating resources in advance and switching into a specific updating mode additionally, and the normal starting of the equipment can be realized without restarting or reinitializing after the updating is finished, so that the method is higher in speed and easier to realize; the updating plan and the updating data are separated, and the burden of a server and a network is relieved.
Drawings
FIG. 1 is a system architecture diagram of a device update according to an embodiment of the present invention;
FIG. 2 is a flow chart of device update according to an embodiment of the present invention;
FIGS. 3A and 3B are flow diagrams of device updates according to another embodiment of the present invention;
fig. 4 is a flowchart illustrating verification in an apparatus updating process according to another embodiment of the present invention.
Detailed Description
In order to further understand the objects, structures, features and functions of the present invention, the following embodiments are described in detail.
Certain terms are used throughout the description and following claims to refer to particular components. As one of ordinary skill in the art will appreciate, manufacturers may refer to a component by different names. The present specification and claims do not intend to distinguish between components that differ in name but not function. In the following description and in the claims, the terms "include" and "comprise" are used in an open-ended fashion, and thus should be interpreted to mean "include, but not limited to.
Referring to fig. 1, a schematic diagram of a first embodiment of the device update system of the present invention is disclosed, which comprises a device 10 and a server 20, wherein the server 20 and the device 10 are connected by communication based on a server/client model. The server 20 is used for storing common update plans and update data related to equipment updates; the common updating plan at least comprises a data updating plan of the equipment needing to be updated; the update data includes a plurality of sub-update data file packages, the update data in the present invention includes device software update data, firmware update data, configuration parameters, and the like, and the corresponding update plan includes update plans of software, firmware, configuration parameters, and the like. The server 20 implements communication connection and data transmission interaction with each device based on a server/client model, which can communicate through various existing communication means 30, preferably, via ethernet, and can be implemented by server-side software based on HTTP, FTP or TFTP; preferably, the server 20 may be provided with a fixed IP address, which may be preset in the device or may be obtained by the device; further, the server 20 may include one server device or a plurality of server devices connected to one another through a network.
The device 10 may be an off-the-shelf device, a motherboard (or "bare board") that may be used with other accessories or test stands to perform off-the-shelf device functions, or a semi-finished product that includes a motherboard. For example, the device 10 may be a computer, a motherboard of a computer, a television, a control board of a television, a mobile terminal, etc., and the invention is not limited thereto.
Referring to fig. 2, an embodiment of the method for updating the device of the present invention is disclosed, which is implemented based on the above system architecture, and includes the following steps:
A. when a device is started to an initialization phase, the device reads the local IP address.
The invention combines the time for updating the equipment into the starting-up process, does not need to enter a special updating mode additionally, and does not need to frequently monitor the network and update information when the equipment normally operates, thereby improving the reaction speed of the equipment and not influencing the normal operation of the equipment.
Preferably, during the boot process of the device 10, the device update preparation for reading the local IP address is started after the initialization of the necessary resources, including but not limited to a power supply, a clock, a GPIO, an internal memory, a network, and the like. Preferably, the device update preparation for reading the local IP address is performed before loading the runtime environment.
B. The device establishes a communication connection with a first server.
The IP address of the first server may be stored on the device or obtained in a particular network device. The device may establish a communication connection via Ping the address of the first server.
C. The equipment downloads and analyzes the updating plan corresponding to the equipment from the first server.
After the device is successfully connected with the first server, an update plan at least comprising one device is downloaded from a corresponding storage location of the first server, which may also be referred to as a common update plan, and there may be one or more common update plans. The first server may send the download request to the first server, or the first server may actively provide data of the common update plan when connecting to the device. The common update plan is downloaded and stored in the internal storage space of the device, and preferably, the common update plan may be stored in a nonvolatile storage space such as NAND Flash, SRAM, FRAM, and the like, which is not limited in this respect.
The common update plan includes an update plan for at least one device, including: device information (e.g., local IP address of the device, device ID, device model, etc.), and an update schedule corresponding to each device. Preferably, the update plan further includes type information of each update plan, such as whether the update is a software update, a firmware update, or a configuration parameter update. Preferably, the common update plan may further include an update plan of at least one group of devices, and devices with the same update plan are grouped into one group, so as to greatly reduce the data volume of the common update plan, and facilitate data transmission and search query. Preferably, the update plan corresponding to each device or each group of devices may include one or more sub-update plans, may also include one or more sub-update plan groups, or includes both a sub-update plan and a sub-update plan group; the case of a sub-update plan in a group of sub-update plans may be illustrated in another file. In the common update plan, the sub-update plan (group) is presented with its identification information, which can query the identification information of the sub-update plan in the corresponding sub-update plan group and the update data content corresponding to the sub-update plan at the corresponding location of the first server.
The equipment analyzes the updating plan corresponding to the equipment from the public plan, and can analyze the updating plan by searching and matching the local IP address of the equipment, the equipment ID and other identifiers. The successful resolution indicates that the update plan corresponding to the equipment exists in the common update plan.
D. And the equipment downloads corresponding updating data from the first server according to the updating plan.
And if the local IP address of the equipment per se exists in a single equipment updating plan in the public updating plan or in the equipment group IP range of the equipment group updating plan in the public updating plan, the equipment continuously downloads the updating data corresponding to the updating plan from the first server. Preferably, when a plurality of sub-update plans and sub-update data exist, the device may download each sub-update data, or may download sub-update data in a package; when a sub-update plan group exists, the device may package and download the sub-update data groups in the sub-update plan group.
E. And the equipment executes updating according to the updating data, and enters the step Z after the updating is finished.
The device executes the update according to its own update plan and update data.
The device performs a second portion of the boot process.
And after the equipment is updated, continuing to execute the subsequent starting process. The first part and the second part of the starting-up process can form complete starting-up, namely the equipment can enter a working state after sequentially executing the first part and the second part. For example, the first part may include initialization of necessary resources in a boot process, the second part may include execution of loading of an operating environment of the device, the second part is executed after the first part is executed when the device is booted, and the device may enter a working state after the second part is completed. That is to say, the device updating process is embedded into the boot process, and the process of restarting or reinitializing is not needed after the updating is completed.
Preferably, when there is an abnormality in any one of the steps a to E (e.g., steps a1, a2, B1, C2, C4, C5, D5, E2, etc., illustrated in fig. 3A and 3B), the device may directly cancel the update and jump to step Z for the subsequent power-on startup flow (step Y). Preferably, when there is an abnormality, the device may repeat the operation of attempting the step until the success or the number of repeated operations reaches an upper limit value; and if the operation is successful, sequentially carrying out the operation of the next step, and if the repeated operation times reach an upper limit value, canceling the updating, and jumping to the step Z to carry out the subsequent starting process (step Y). One preferred embodiment is shown in particular in fig. 3A and 3B, wherein the symbols M1 and M1 'are received in each other and M2 and M2' are received in each other, thereby forming the complete implementation of this embodiment.
Preferably, step a further comprises:
A1. if the device does not successfully read the local IP address of the device, entering step Z or A2;
step A2, the equipment sets a local IP address of the equipment as a temporary specific IP address, and enters step B; wherein the common update plan includes an update plan corresponding to the specific IP address.
The device may have a situation that a local IP address is not set, for example, in an early development engineering prototype or a first empty board stage of a production line, a situation that an IP is not established sometimes occurs. Whether updating is needed or not can be determined according to actual requirements, and if not, the step Y is skipped; if necessary, it needs to be assigned a temporary specific IP address. This particular IP address may be temporarily set (e.g., 192.168.100.101) and defined in a common update plan or set rules, e.g., in a common update plan, this particular IP address corresponds to a default initial update. The specific IP address can be cleared after the updating is completed, so that the problem that a plurality of devices with the same IP address exist in the network at the same time is prevented.
Preferably, the method further comprises the following steps between the step B and the step C:
B1. if the device and the first server are not successfully connected, judging whether the number of times of trying to establish the communication connection reaches a threshold value, if so, entering a step Y, otherwise, entering a step B;
wherein, the step Y: and canceling the updating and entering the step Z.
In order to facilitate problem location when a problem is encountered and to facilitate quick problem solving, an auxiliary mechanism of logging is added after the update is completed or the update fails. Preferably, step Y or step Z further comprises: the device records corresponding information into a log; wherein, the recording of the corresponding information to the log by the device at least comprises one of the following steps:
x1. the log is stored in the internal storage space of the device;
x2. the device is connected with a second device via a serial port and sends the corresponding information to the second device, and the second device stores and/or displays the obtained corresponding information;
x3. the device transmits the corresponding information to a second server via the network, the second server stores, displays and/or transmits the obtained corresponding information to a corresponding third device; wherein the second server is the same as or different from the first server.
And D, recording a log in the step Y, wherein the log can be used for being carried out aiming at the equipment generating the update exception.
The second device in step X2 and the third device in step X3 may be devices related to the update maintenance person, and may be electronic devices such as a PC having data analysis processing capability.
The second server for recording the log and the first server for storing the common update plan and the update data may be independent servers, or may be associated with each other, or even be the same or a same group of server devices.
In order to further reduce the burden of the network and the server and eliminate the problems of subsequent installation and updating caused by errors of downloading files, an auxiliary mechanism of checking is added in the updating process.
Preferably, a verification operation is added after the downloading operation in step C or step D is completed, specifically:
the step C also comprises the following steps: C6. after the device successfully analyzes, checking the self data version, comparing the self data version with the analyzed data version in the updating plan, if the data version in the updating plan is newer than the self data version, entering a step D, otherwise entering a step Y; or,
between step D and step E, further comprising: D4. the device checks its own data version and compares it with the data version in the update data, if the data version in the update data is newer than the own data version, then step E is entered, otherwise step Y is entered.
Whether to execute the update of the older version or the current version can also be determined based on whether the demoble flag is set by the update plan of the device obtained by the parsing. In other words, when the update plan of the device obtained by parsing does not have a version reversible identifier, step C6 or D4 is executed (i.e., step C is followed by C6, and step D is followed by D4); when the update plan of the device obtained by parsing has the mark capable of being copied, even if the version of the data to be updated in the update plan is older or the same as the existing version of the data of the device, the device still proceeds to step E to further perform the update.
Preferably, the method further comprises the following steps between the step D and the step E:
D1. the equipment calculates and obtains a check code according to a check calculation formula and the downloaded update data;
D2. the equipment judges whether the check code is consistent with the corresponding check code in the first server or not;
D3. if yes, the downloaded update data is determined to be complete and correct, and step E is entered.
Preferably, a step D5 is further included between the step D2 and the step D3, if not, it is determined whether the number of downloads of the update data exceeds an upper limit, otherwise, the download of the update data from the first server is retried, and the process proceeds to a step D1; if yes, go to step Y.
Steps D1 through D3 occur in the first step after the download of step D is completed, which may serve as a criterion for whether the download was successful (i.e., the criterion of step D5).
As shown in fig. 4, at the first server, the entire content of the file itself (S110) is calculated as the original data of the check calculation by using an agreed check calculation method (e.g., CRC, MD5, etc.), so as to obtain a first check code (S120), and the first check code is stored in the first server. At the device side, when the device downloads a certain sub-update data or sub-update data group from the first server (S210), the same check calculation formula as that of the first server side is used, and the content of the downloaded file is used as the calculated source data, and the second check code is obtained (S220). The device initiates a command to the first server to acquire a first check code stored on the first server (S230), and compares the second check code with the first check code (S240); if the two values are the same, the update data related file obtained by local downloading is considered to be complete and correct; if the two are different, the downloading is considered to be abnormal, and errors need to be reported and the downloading needs to be retried. The above described verification mechanism may be performed for both the common update plan and the download of update data.
The common updating plan in the invention comprises updating plans of a plurality of devices, or at least one group of updating plans; each set of update plans includes:
device information such as the local IP address of the device, device ID, etc. In a set of update plans, the device information exists as device information of a device, or as a range of device information of a set of devices, for example, each set of the update plans includes a local IP address or device ID of a device to be updated, or a local IP address range or device ID range of a set of devices to be updated.
The identification information of the update data, for example corresponding to one or a group of devices, there is identification information of at least one sub-update data and/or identification information of at least one sub-update data group. The identification information of the sub-updating data corresponds to one sub-updating data in the first server; the identification information of the sub-update data group corresponds to a sub-update data group in the first server, and the sub-update data group includes identification information of at least one sub-update data. For example, the identification information of the sub-update data may correspond to a file of the corresponding sub-update data in the first server, and preferably, the file name is consistent with the identification information. For example, the identification information of the sub-update data group may correspond to a file of the corresponding sub-update data group or a data packet of the corresponding sub-update data group in the first server; the identification information of the included sub-update data exists in the file of the corresponding sub-update data group to correspond to the file of the corresponding sub-update data (i.e., the data packet of the sub-update data) in the first server.
Therefore, developers can develop and define more sub-items (sub-update plans) according to actual needs and platform capacity, and the update flexibility and customized services (such as personalized setting of specific equipment) of different equipment are effectively improved. Since the information in the common update plan is heavily combined and the actual update data is additionally stored in the first server, the file of the common update plan becomes very small, the network resources occupied during downloading are small, and even if a plurality of devices are downloaded simultaneously, the server and the network are not burdened. In addition, the device can easily and quickly retrieve and extract the self-updating plan after downloading. Furthermore, the updating of a plurality of devices according to different requirements can be met, the same device is updated according to different requirements every time, and the updating of software, firmware and configuration is more flexible.
For devices of different types or different models, only one common update file can be set, wherein the information of the type or model of the device is added, or for devices of the same type or model, one common update plan file is respectively set, the file name of the file indicates the relevant information of the type or model, or a guide directory exists to guide data interaction to the corresponding common update plan file; the invention is not limited thereto.
The common update plan file can adopt a txt file format, an xml file format or other file formats. The txt and xml file formats occupy less resources, and are beneficial to volume reduction and rapid transmission and processing of files.
For example, the format of the common update file may be as follows:
<Start>
ip 1#PLAN X#PLA NY#PLA NZ$$$
ip 2#PLAN A$$$
ip 3#PLAN B$$$
ip N#PLAN C$$$
ip_range 1#PLAN D#PLAN E#PLAN F$$$
ip_range 2#PLAN A$$$
ip_range 3#PLAN D$$$
ip_range N#PLAN G$$$
<End>
in the format exemplified above, the content of the entire common update file starts with "< Start >" and ends with "< End >". "$$$$" is a plan separator, and a "$$$$$$" symbol needs to be added at the end of the plan of each individual device or the plan of each group of devices; "#" is a child item (i.e., child update plan) delimiter inside each plan. "IP" in IP 1, IP 2, IP 3, IP N is taken as the planned start of an individual device, wherein 1, 2, 3, N represents a single local IP address value or a single device ID value; "IP _ range" in IP _ range1, IP _ range 2, IP _ range 3, and IP _ range N identifies a schedule of a group of devices, where 1, 2, 3, N respectively represents a local IP address range or a device ID value range of a group of devices, such as "IP _ range192.168.100.3-192.168.100.6, 192.168.100.8", indicating that the devices for which the update schedule of the group of devices is intended include 4 devices in a continuous local IP address range192.168.100.3-192.168.100.6 and a device with a discontinuous local IP address 192.168.100.8.
PLANX, PLANY, PLANZ, multiple sub-update schedules representing a single device ("ip 1"), and similarly PLAN D, PLAN E, PLAN F, multiple sub-update schedules representing a group of devices ("ip _ range 1"). Preferably, a type is defined for each (sub-) update plan, so that corresponding preparations are made when the device is updated, for example:
DL _ F file _ name: indicating that a separate software/firmware is to be updated individually, where file _ name is the name (or other identifier) of the software/firmware, and the update data file of the software/firmware is itself pre-located on the first server.
DL _ G group _ name: the update data file of the software/firmware corresponding to the group member name (or other identifier) contained in the group _ name.txt file is placed in the first server in advance, and the group _ name.txt file is also placed in the first server in advance.
SET _ F file _ name: it means that the configuration data is updated according to a certain configuration parameter, and the update data file of the configuration parameter is pre-placed on the first server.
And the SET _ G group _ name represents that a plurality of configuration parameter files are defined as a group, the group _ name is the group name of the group, and the information of the group members is recorded in a group _ name.txt (the group _ name.txt can be a file in other formats, but the invention is not limited to the file) file which is also placed on the first server in advance.
For example, ip _ range 192.168.100.3-192.168.100.5# DL _ F boot
Machines with local IP addresses 192.168.100.3, 192.168.100.4, 192.168.100.5 need to update both firmware, boot.
For another example, ip 192.168.100.2# DL _ GAll _ load # SET _ GAll _ config $ $
A device with a local IP address of 192.168.100.2 needs to update multiple software/firmware based on what is specified in all _ load.txt and needs to update configuration data based on what is specified in all _ config.txt.
For another example, ip 192.168.100.7# DL _ G modem _ load # SET _ F adb _ flag $ $ $ $ $ $ $
A device representing a local IP address of 192.168.100.7 would need to update multiple software/firmware based on what is specified in modem _ load.txt and would need to update configuration data based on what is specified in adb _ flag.txt.
In addition, the update plan for one device or a group of devices in the common update plan can also allow the corresponding device to update to the old version or the same version of software or configuration by setting the version-backed identifier.
In addition, the public updating plan can adopt a batch import mode and then carry out manual processing on individual data, so that the correctness and the processing speed of the file can be greatly improved.
In summary, the present invention provides a method for updating a device, which integrates a data updating process into a device boot process, and the device can be updated without preparing update resources in advance or switching to a specific update mode, and can be normally started without restarting or reinitializing after the update is completed, so that the method is faster and easier to implement. The device and the server are in communication connection in a server/client architecture, and simultaneous updating of multiple devices can be achieved. The updating plan and the updating data are separated and are downloaded respectively, so that the data downloading amount is greatly reduced, and the burden of a server and a network is relieved; the equipment with the same update plan is combined, and a plurality of update plans of the same equipment are combined, so that the file capacity is greatly reduced, the transmission and processing are facilitated, the flexible management and control of equipment update of which a large number of equipment are updated simultaneously according to needs are realized, and the expansion of the equipment functions and the improvement and the enhancement of the equipment performance are facilitated.
The present invention has been described in relation to the above embodiments, which are only exemplary of the implementation of the present invention. It should be noted that the disclosed embodiments do not limit the scope of the invention. Rather, it is intended that all such modifications and variations be included within the spirit and scope of this invention.
Claims (10)
1. A method for device update, comprising the steps of,
A. when the equipment executes the starting process till the first part is finished, the equipment reads the local IP address;
B. the device establishes a communication connection with a first server;
C. the equipment downloads and analyzes an updating plan corresponding to the equipment from the first server;
D. the equipment downloads corresponding updating data from the first server according to the updating plan;
E. the equipment executes corresponding updating according to the updating data, and enters a step Z after the updating is finished;
z, the equipment executes the second part of the starting process;
the device can enter a working state after sequentially executing the first part and the second part of the starting process.
2. The method for device update of claim 1, wherein step a further comprises:
A1. if the device does not successfully read the local IP address of the device, entering step Z or A2;
and step A2, the equipment sets the local IP address of the equipment as a temporary specific IP address and enters the step B.
3. The method for device update according to claim 1, further comprising between step B and step C:
B1. if the device and the first server are not successfully connected, judging whether the number of times of trying to establish the communication connection reaches a threshold value, if so, entering a step Y, otherwise, entering a step B;
wherein, the step Y: and canceling the updating and entering the step Z.
4. The method of device update of claim 1,
if the operation in any step from the step C to the step E fails to be executed, entering the step Y;
wherein, the step Y: cancel the update and enter step Z.
5. The method of device update of claim 1,
the method also comprises the following steps between the step D and the step E:
D1. the equipment calculates and obtains a check code according to a check calculation formula and the downloaded update data;
D2. the equipment judges whether the check code is consistent with the corresponding check code in the first server or not;
D3. if yes, the downloaded update data is determined to be complete and correct, and step E is entered.
6. The method of device update according to claim 3 or 4,
the step C also comprises the following steps: after the device successfully analyzes, checking the self data version, comparing the self data version with the analyzed data version in the updating plan, if the data version in the updating plan is newer than the self data version, entering a step D, otherwise entering a step Y; or,
between step D and step E, further comprising: D4. the device checks its own data version and compares it with the data version in the update data, if the data version in the update data is newer than the own data version, then step E is entered, otherwise step Y is entered.
7. The method of device update of claim 1,
in step C, the equipment downloads a public updating plan from the first server and analyzes an updating plan corresponding to the equipment from the public updating plan;
the common update plan includes at least one group of update plans, each group of update plans includes:
a local IP address or device ID of a device to be updated, or a local IP address range or device ID range of a group of devices to be updated; and the number of the first and second groups,
identification information of at least one sub-update data corresponding to the device to be updated and/or identification information of at least one sub-update data group corresponding to the device or the group of devices to be updated;
the identification information of the sub-update data group corresponds to a sub-update data group in the first server, the sub-update data group comprises identification information of at least one sub-update data, and the identification information of the sub-update data corresponds to a sub-update data in the first server.
8. The method of device update according to claim 3 or 4,
step Y or step Z further comprises: the device records corresponding information into a log;
wherein, the recording of the corresponding information to the log by the device at least comprises one of the following steps:
x1. the log is stored in the internal storage space of the device;
x2. the device is connected with a second device via a serial port and sends the corresponding information to the second device, and the second device stores and/or displays the obtained corresponding information;
x3. the device transmits the corresponding information to a second server via the network, the second server stores, displays and/or transmits the obtained corresponding information to a corresponding third device; wherein the second server is the same as or different from the first server.
9. The method of device update of claim 1,
the common update plan includes at least one of: updating plans of software, firmware and configuration parameters; and, the update data includes at least one of: software data, firmware data, configuration parameters.
10. The method of device update of claim 1,
the apparatus comprises: finished equipment, or motherboards; the main board is matched with corresponding accessories to realize the function of finished equipment.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810343973.3A CN108833128A (en) | 2018-04-17 | 2018-04-17 | A kind of method that equipment updates |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810343973.3A CN108833128A (en) | 2018-04-17 | 2018-04-17 | A kind of method that equipment updates |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108833128A true CN108833128A (en) | 2018-11-16 |
Family
ID=64154105
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810343973.3A Pending CN108833128A (en) | 2018-04-17 | 2018-04-17 | A kind of method that equipment updates |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108833128A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109413200A (en) * | 2018-11-26 | 2019-03-01 | Oppo(重庆)智能科技有限公司 | A kind of method, client, MES and electronic equipment that resource imports |
CN117648685A (en) * | 2024-01-24 | 2024-03-05 | 苏州元脑智能科技有限公司 | Verification method, device and equipment for server updating process and readable storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110016017A1 (en) * | 2009-05-11 | 2011-01-20 | Carlin James A | Interactive Internet Platform for Assessing and Executing Residential Energy Solutions |
CN102377821A (en) * | 2011-10-17 | 2012-03-14 | 邦讯技术股份有限公司 | Intelligent version updating method and device for network terminal equipment |
CN106598781A (en) * | 2016-11-30 | 2017-04-26 | 惠州华阳通用电子有限公司 | System software upgrading method |
CN106936630A (en) * | 2017-02-23 | 2017-07-07 | 烽火通信科技股份有限公司 | A kind of whole bag upgrade method of many card insert type equipment and upgrade-system |
-
2018
- 2018-04-17 CN CN201810343973.3A patent/CN108833128A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110016017A1 (en) * | 2009-05-11 | 2011-01-20 | Carlin James A | Interactive Internet Platform for Assessing and Executing Residential Energy Solutions |
CN102377821A (en) * | 2011-10-17 | 2012-03-14 | 邦讯技术股份有限公司 | Intelligent version updating method and device for network terminal equipment |
CN106598781A (en) * | 2016-11-30 | 2017-04-26 | 惠州华阳通用电子有限公司 | System software upgrading method |
CN106936630A (en) * | 2017-02-23 | 2017-07-07 | 烽火通信科技股份有限公司 | A kind of whole bag upgrade method of many card insert type equipment and upgrade-system |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109413200A (en) * | 2018-11-26 | 2019-03-01 | Oppo(重庆)智能科技有限公司 | A kind of method, client, MES and electronic equipment that resource imports |
CN109413200B (en) * | 2018-11-26 | 2021-04-23 | Oppo(重庆)智能科技有限公司 | Resource import method, client, MES and electronic equipment |
CN117648685A (en) * | 2024-01-24 | 2024-03-05 | 苏州元脑智能科技有限公司 | Verification method, device and equipment for server updating process and readable storage medium |
CN117648685B (en) * | 2024-01-24 | 2024-04-12 | 苏州元脑智能科技有限公司 | Verification method, device and equipment for server updating process and readable storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8719810B2 (en) | Program upgrade system and method for over the air-capable mobile terminal | |
US6553490B1 (en) | Computer system including local computer with capability to automatically update operating system or application program from network server | |
US20120117557A1 (en) | Method and system for upgrading wireless data card | |
US20070294685A1 (en) | Program upgrade system and method for ota-capable portable device | |
US20030221092A1 (en) | Method and system of switching between two or more images of firmware on a host device | |
US20040181790A1 (en) | System and method for maintaining installed software compliance with build standards | |
US20090077634A1 (en) | Firmware update method and system using the same | |
US20050060528A1 (en) | Booting and boot code update method and system thereof | |
CN111273924B (en) | Software updating method and device | |
CN110750280B (en) | Android platform-based application upgrading method and system and storage medium | |
CN110750286A (en) | Management method, device, system, equipment and medium for upgrading Mbn through OTA | |
CN110597545A (en) | Hot patch intelligent upgrading method and system based on OTA component | |
CN109002305B (en) | Method and system for updating equipment program | |
CN108833128A (en) | A kind of method that equipment updates | |
CN112363717A (en) | Method and terminal for loading different functions in single software | |
CN115543429A (en) | Project environment building method, electronic equipment and computer readable storage medium | |
CN112732285B (en) | Upgrading method and device suitable for cloud computing linux operating system and electronic equipment | |
WO2024131374A1 (en) | Cross-system upgrade method and apparatus for set-top box, set-top box, and storage medium | |
CN113064611B (en) | Method for realizing data analysis software upgrading aiming at wireless equipment and updating method thereof | |
CN108664259B (en) | Method and terminal for installing application | |
CN113656051A (en) | A method for automatic upgrade of Android system equipment | |
CN113377400A (en) | Software upgrading method and device, storage medium and electronic equipment | |
KR100429903B1 (en) | Method for updating images in home gateway system | |
CN110780943B (en) | Method and system for unifying firmware of slave equipment | |
KR101437837B1 (en) | Method and apparatus for downloading of content interlock between dynamic platform in a mobile communication system |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20181116 |
|
RJ01 | Rejection of invention patent application after publication |