CN109002319B - LORA protocol-based patch upgrading method, device and system - Google Patents
LORA protocol-based patch upgrading method, device and system Download PDFInfo
- Publication number
- CN109002319B CN109002319B CN201810827029.5A CN201810827029A CN109002319B CN 109002319 B CN109002319 B CN 109002319B CN 201810827029 A CN201810827029 A CN 201810827029A CN 109002319 B CN109002319 B CN 109002319B
- Authority
- CN
- China
- Prior art keywords
- node
- data
- verification
- server
- 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
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/60—Software deployment
- G06F8/65—Updates
- G06F8/656—Updates while running
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/71—Version control; Configuration management
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D30/00—Reducing energy consumption in communication networks
- Y02D30/70—Reducing energy consumption in communication networks in wireless communication networks
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The embodiment of the application discloses a patch upgrading method, a device and a system based on an LORA protocol, which comprises the following steps: sending a verification instruction to a node, so that the verification instruction and the node perform verification according to a version number and a secret key stored in the node, wherein the verification instruction comprises a version number to be verified and a secret key to be verified; and after receiving the verification success information sent by the node, issuing a data command to the node, so that the node writes the upgrading data in the data command into a corresponding space and enables the upgrading data to complete patch upgrading. The method and the device can remotely complete the function upgrade or problem repair of the LORA protocol product, greatly improve the speed of product repair and function upgrade and save the cost.
Description
Technical Field
The present application relates to the field of computer technologies, and in particular, to a patch upgrade method, apparatus, and system based on an LORA protocol.
Background
Because of the characteristics of long distance, low power consumption, multiple nodes and low cost, the LORA technology is more and more widely applied.
However, when the existing LORA protocol product is upgraded or repaired, a maintenance person or an engineer needs to be sent to the site to repair the product on the site or directly replace the product, which causes slow speed of product repair and function upgrade, increases labor cost, and if the product is directly replaced, wastes resources.
Disclosure of Invention
The embodiment of the application provides a patch upgrading method, a patch upgrading device and a patch upgrading system based on an LORA protocol, so that the function upgrading or problem repairing of an LORA protocol product can be completed remotely, the product repairing and function upgrading speed is greatly improved, and the cost is saved.
In view of this, a first aspect of the present application provides a patch upgrade method based on an LORA protocol, which is applied to a server and includes:
sending a verification instruction to a node, so that the verification instruction and the node perform verification according to a version number and a secret key stored in the node, wherein the verification instruction comprises a version number to be verified and a secret key to be verified;
and after receiving the verification success information sent by the node, issuing a data command to the node, so that the node writes the upgrading data in the data command into a corresponding space and enables the upgrading data to complete patch upgrading.
Preferably, the first and second electrodes are formed of a metal,
sending a data command to the node, so that the node stores upgrade data in the data command to a corresponding space and enables the upgrade data to complete patch upgrade specifically comprises:
and repeatedly sending a batch of data commands to the node for multiple times, comparing the received batch of data commands with the data commands existing in the node after the node receives the batch of data commands each time, storing the data commands which do not exist in the node, and writing the upgrade data in all the stored data commands into corresponding spaces and enabling the upgrade data to finish patch upgrade after the receiving times reach the preset times.
Preferably, the first and second electrodes are formed of a metal,
after receiving the verification success information sent by the node, before sending the data command to the node, the method further includes:
and sending a protocol agreement request to the node for agreement, and switching a channel according to the content of the agreement after receiving the successful agreement information sent by the node so as to communicate with the node for the next time through the switched channel.
A second aspect of the present application provides a patch upgrade apparatus based on an LORA protocol, which is applied to a server, and includes:
the first checking unit is used for sending a checking instruction to the node so that the node can check according to the version number and the key stored in the node, wherein the checking instruction comprises the version number to be checked and the key to be checked;
and the command issuing unit is used for issuing a data command to the node after receiving the verification success information sent by the node, so that the node writes the upgrading data in the data command into the corresponding space and enables the upgrading data to complete patch upgrading.
Preferably, the first and second electrodes are formed of a metal,
the command issuing unit is specifically configured to repeatedly send a batch of data commands to the node for multiple times, so that after each time a batch of data commands is received by the node, the received batch of data commands is compared with the existing data commands, the data commands which do not exist are stored, and then after the number of times of reception reaches a preset number of times, upgrade data in all the stored data commands is written into corresponding spaces and enabled, so as to complete patch upgrade.
Preferably, the first and second electrodes are formed of a metal,
the patch upgrading device based on the LORA protocol further comprises:
and the first protocol agreement unit is used for sending a protocol agreement request to the node for agreement, and switching a channel according to the content of the agreement after receiving the successful agreement information sent by the node so as to carry out next communication with the node through the switched channel.
A third aspect of the present application provides a patch upgrade method based on an LORA protocol, which is applied to a node, and includes:
receiving a verification instruction sent by a server, verifying according to the verification instruction, the version number stored by the node and the secret key, and sending verification success information to the server after verification is successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified;
and after the data command issued by the server is received, writing the upgrading data in the data command into a corresponding space and enabling the upgrading data to finish patch upgrading.
Preferably, the first and second electrodes are formed of a metal,
if the server repeatedly sends a batch of data commands for multiple times, after receiving the data commands issued by the server, writing the upgrade data in the data commands into corresponding spaces and enabling the data commands to complete patch upgrade specifically comprises:
after receiving a batch of data commands each time, comparing the received batch of data commands with the data commands existing in the batch of data commands, storing the data commands which do not exist in the batch of data commands, and writing the upgrading data in all the stored data commands into corresponding spaces and enabling the upgrading data after the receiving times reach the preset times so as to finish patch upgrading.
Preferably, the first and second electrodes are formed of a metal,
after the verification success information is sent to the server, before the data command sent by the server is received, the method further includes:
and receiving a protocol agreement request sent by the server, and then sending protocol agreement success information to the server, so that the server switches channels according to the content of protocol agreement after receiving the protocol agreement success information sent by the node, and then communicates with the server next time through the switched channels.
Preferably, the first and second electrodes are formed of a metal,
after receiving the data command issued by the server, before writing the upgrade data in the data command into the corresponding space and enabling, the method further includes:
integrating the upgrading data in the data command according to the upgrading data serial number in the data command, and judging whether the upgrading data is lost or not according to the quantity of the upgrading data in the data command;
and if the upgrade data are not lost, performing security verification on all the upgrade data so as to write the upgrade data in the data command into a corresponding space and enable the upgrade data after the security verification is successful.
In a fourth aspect of the present application, a patch upgrade apparatus based on an LORA protocol is applied to a node, and includes:
the second verification unit is used for receiving a verification instruction sent by the server, then verifying according to the verification instruction, the version number stored by the node and the secret key, and sending verification success information to the server after verification is successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified;
and the upgrading unit is used for writing the upgrading data in the data command into a corresponding space and enabling the upgrading data after receiving the data command issued by the server so as to finish patch upgrading.
Preferably, the first and second electrodes are formed of a metal,
if the server repeatedly sends a batch of data commands for multiple times, the upgrading unit is specifically configured to:
after receiving a batch of data commands each time, comparing the received batch of data commands with the data commands existing in the data commands, storing the data commands which do not exist in the data commands, and writing the upgrading data in all the stored data commands into corresponding spaces and enabling the upgrading data after the receiving times reach the preset times so as to complete patch upgrading.
Preferably, the first and second electrodes are formed of a metal,
the patch upgrading device based on the LORA protocol further comprises:
and the second protocol agreement unit is used for receiving the protocol agreement request sent by the server and then sending protocol agreement success information to the server, so that the server switches channels according to the content of the protocol agreement after receiving the protocol agreement success information sent by the node, and the next communication is carried out with the server through the switched channels.
Preferably, the first and second electrodes are formed of a metal,
the patch upgrading device based on the LORA protocol further comprises:
the integration unit is used for integrating the upgrading data in the data command according to the upgrading data serial number in the data command and judging whether the upgrading data is lost or not according to the quantity of the upgrading data in the data command;
and the safety verification unit is used for performing safety verification on all the upgrading data when the upgrading data is not lost so as to write the upgrading data in the data command into the corresponding space and enable the upgrading data after the safety verification is successful.
A fifth aspect of the present application provides a system comprising a server and a node;
the server is used for sending a check instruction to the node, so that the check instruction and the node can check according to the version number and the key stored in the server, and the check instruction comprises the version number to be checked and the key to be checked;
after receiving the verification success information sent by the node, sending a data command to the node, so that the node writes the upgrading data in the data command into a corresponding space and enables the upgrading data to complete patch upgrading;
the node is used for receiving a verification instruction sent by a server, then verifying according to the verification instruction, the version number stored by the node and a secret key, and sending verification success information to the server after verification is successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified;
and after the data command issued by the server is received, writing the upgrading data in the data command into a corresponding space and enabling the upgrading data to finish patch upgrading.
According to the technical scheme, the embodiment of the application has the following advantages:
in the embodiment of the application, a patch upgrading method, a patch upgrading device and a patch upgrading system based on an LORA protocol are provided, a server sends a verification instruction to a node, then the node verifies according to the verification instruction and the version number and the secret key stored by the node, and sends verification success information to the server after the verification is successful, wherein the verification instruction comprises the version number to be verified and the secret key to be verified; the server sends the data command to the node after receiving the verification success information sent by the node, so that the node writes the upgrade data in the data command into a corresponding space and enables the upgrade data to complete patch upgrade.
Drawings
Fig. 1 is a flowchart of a method of a first embodiment of a patch upgrade method based on a LORA protocol in an embodiment of the present application;
fig. 2 is a flowchart of a method of a second embodiment of a patch upgrade method based on a LORA protocol in an embodiment of the present application;
fig. 3 is a schematic structural diagram of a patch upgrade apparatus based on the LORA protocol in an embodiment of the present application;
fig. 4 is a flowchart of a method of a third embodiment of a patch upgrade method based on a LORA protocol in the embodiment of the present application;
fig. 5 is a flowchart of a method of a fourth embodiment of a patch upgrade method based on a LORA protocol in the embodiment of the present application;
fig. 6 is a schematic structural diagram of a patch upgrade apparatus based on the LORA protocol in an embodiment of the present application;
fig. 7 is a schematic diagram of an embodiment of a system in an embodiment of the present application.
Detailed Description
In order to make the technical solutions of the present application better understood, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In order to facilitate understanding of the technical solutions of the embodiments of the present application, the following descriptions are specifically made:
in the embodiment of the application, the communication between the server and the node is carried out based on the LORA protocol, function upgrading and problem repairing are carried out on the LORA protocol product through a manual site at present, and the embodiment of the application can remotely complete the function upgrading or problem repairing of the LORA protocol product, thereby greatly improving the speed of product repairing and function upgrading and saving the cost.
Referring to fig. 1, fig. 1 is a flowchart illustrating a method of a first embodiment of a patch upgrade method based on a LORA protocol according to the present application.
The embodiment of the application provides a first embodiment of a patch upgrading method based on a LORA protocol, which is applied to a server and comprises the following steps:
In the embodiment of the application, the purpose of sending the check instruction to the node is to request function upgrade or problem repair; the verification in the embodiment of the present application includes a version number verification part and a key verification part, and it should be noted that the sequence of the two verification processes is not limited, and the node allows the server to send verification success information only after both the version number verification and the key verification are successful.
In the embodiment of the application, it is assumed that version number verification is performed first, if the verification is successful, key verification is performed, and if the verification is unsuccessful, the object representing the patch upgrade is not a LORA protocol product in a node.
And 102, after receiving the verification success information sent by the node, issuing the data command to the node, so that the node writes the upgrade data in the data command into the corresponding space and enables the upgrade data to complete patch upgrade.
In this embodiment of the present application, the space in which the upgrade data is written may be a flash space or other storage spaces, and it can be understood that information such as a code execution address of the upgrade data needs to be written into the registry, and then, after the original LORA protocol product is executed to the reserved port, the program automatically jumps to the code execution address to execute the upgrade data, thereby completing patch upgrade.
In addition, in order to facilitate patch upgrade again, the version number stored locally by the node may also be updated.
It is understood that, in the embodiment of the present application, to implement batch upgrade of a product, the server may also send an instruction to multiple nodes simultaneously through corresponding gateways.
Referring to fig. 2, fig. 2 is a flowchart illustrating a second embodiment of a patch upgrade method based on the LORA protocol according to the present application.
The embodiment of the application provides a first embodiment of a patch upgrading method based on a LORA protocol, which is applied to a server and comprises the following steps:
Step 201 is the same as step 101 in the first embodiment of the present application, and specific description may refer to the content of step 101 in the first embodiment, which is not described herein again.
It should be noted that, in general, a plurality of products on a node communicate with a server by using a channel, and in order to avoid adverse effects on the operation of other products on the node caused by patch upgrade, in the embodiment of the present application, the channel is switched before a data command under the server, so that the server issues the data command through the switched channel.
It is understood that the agreed-upon contents of the protocol include configuration parameters of the protocol, and the purpose of changing the channel can be achieved by changing the configuration parameters of the protocol.
It should be noted that the communication based on the LORA protocol is wireless communication, and the wireless communication avoids the influence of packet loss on the patch upgrade process, and each batch of data commands is repeatedly sent many times, and after receiving a batch of data commands each time, the node only needs to store the data commands that do not exist, and can give up existing data commands.
In addition, the number of times of repeated transmission of a batch of data commands can be specifically set according to actual conditions.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a patch upgrade apparatus based on the LORA protocol according to an embodiment of the present application.
The embodiment of the application provides a patch upgrading device based on LORA agreement, is applied to the server, includes:
the first checking unit 100 is configured to send a checking instruction to the node, so that the node performs checking according to the version number and the key stored in the node, where the checking instruction includes the version number to be checked and the key to be checked;
and the command issuing unit 200 is configured to issue the data command to the node after receiving the verification success information sent by the node, so that the node writes the upgrade data in the data command into the corresponding space and enables the upgrade data to complete patch upgrade.
Further, the command issuing unit 200 may be specifically configured to repeatedly send a batch of data commands to the node for multiple times, so that after each time a batch of data commands is received by the node, the received batch of data commands is compared with the existing data commands, and the data commands that do not exist are stored, and then after the number of times of reception reaches a preset number of times, the upgrade data in all the stored data commands is written into the corresponding space and enabled, so as to complete patch upgrade.
Further, the patch upgrade apparatus based on LORA protocol may further include:
the first protocol agreement unit 300 is configured to send a protocol agreement request to the node for agreement, and after receiving successful agreement information sent by the node, switch a channel according to contents of the agreement, so as to perform next communication with the node through the switched channel.
Referring to fig. 4, fig. 4 is a flowchart illustrating a third embodiment of a patch upgrade method based on the LORA protocol according to the present application.
The embodiment of the present application provides a first embodiment of a patch upgrade method based on a LORA protocol, which is applied to a node and includes:
Step 301 is the same as step 101 in the first embodiment of the present application, and for specific description, reference may be made to the content of step 101 in the first embodiment, which is not described herein again.
Step 302 is the same as step 102 in the first embodiment of the present application, and specific description may refer to the content of step 102 in the first embodiment, which is not described herein again.
Referring to fig. 5, fig. 5 is a flowchart illustrating a fourth embodiment of a patch upgrade method based on the LORA protocol according to the present application.
The embodiment of the present application provides a second embodiment of a patch upgrade method based on a LORA protocol, which is applied to a node, and includes:
Step 401 is the same as step 201 in the second embodiment of the present application, and specific description may refer to the content of step 201 in the second embodiment, which is not described herein again.
Step 402 is the same as step 202 in the second embodiment of the present application, and specific description may refer to the content of step 202 in the second embodiment, which is not described herein again.
It should be noted that the execution of step 403 is proposed on the premise that the server repeatedly sends a batch of data commands.
And step 404, integrating the upgrading data in the data command according to the upgrading data serial number in the data command after the receiving times reach the preset times, and judging whether the upgrading data is lost or not according to the upgrading data quantity in the data command.
And 405, if the upgrade data is not lost, performing security check on all the upgrade data so as to write the upgrade data in the data command into a corresponding space and enable the upgrade data after the security check is successful.
If the upgrade data is lost, all the received data instructions can be directly deleted, and next patch upgrade is waited, so that the normal operation of the existing LORA protocol product on the node is not influenced.
The purpose of the security check is to verify the integrity of all received data, and if the security check fails, all received data instructions can be directly deleted, and next patch upgrade is waited, so that the normal operation of the existing LORA protocol product on the node is not affected.
And 406, writing the upgrade data in all the stored data commands into corresponding spaces and enabling the upgrade data to complete patch upgrade.
Step 406 is the same as step 203 in the second embodiment of the present application, and specific description may refer to the content of step 203 in the second embodiment, which is not described herein again.
Referring to fig. 6, a schematic structural diagram of a patch upgrade apparatus based on the LORA protocol in the embodiment of the present application is shown.
In a fourth aspect of the present application, a patch upgrade apparatus based on an LORA protocol is applied to a node, and includes:
and the second checking unit 400 is configured to receive a checking instruction sent by the server, then perform checking according to the checking instruction, the version number stored by the node according to the node and the key, and send checking success information to the server after the checking is successful, so that the server issues a corresponding data command, where the checking instruction includes the version number to be checked and the key to be checked.
And the upgrading unit 500 is configured to write upgrading data in the data command into a corresponding space and enable the corresponding space after receiving the data command issued by the server, so as to complete patch upgrading.
Further, if the server repeatedly sends a batch of data commands for multiple times, the upgrade unit 500 may be specifically configured to:
after receiving a batch of data commands each time, comparing the received batch of data commands with the data commands existing in the batch of data commands, storing the data commands which do not exist in the batch of data commands, and writing the upgrading data in all the stored data commands into corresponding spaces and enabling the upgrading data after the receiving times reach the preset times so as to finish patch upgrading.
Further, the patch upgrade apparatus based on LORA protocol may further include:
the second protocol agreement unit 600 is configured to receive a protocol agreement request sent by the server, and then send protocol agreement success information to the server, so that the server switches a channel according to the content of the protocol agreement after receiving the protocol agreement success information sent by the node, so as to perform next communication with the server through the switched channel.
Further, the patch upgrade apparatus based on LORA protocol may further include:
the integration unit 700 integrates the upgrade data in the data command according to the upgrade data serial number in the data command, and determines whether the upgrade data is lost according to the upgrade data number in the data command.
And the security verification unit 800 is configured to perform security verification on all upgrade data when no upgrade data is lost, so as to write the upgrade data in the data command into the corresponding space and enable the upgrade data after the security verification is successful.
Referring to fig. 7, fig. 7 is a schematic diagram of an embodiment of a system according to an embodiment of the present application.
The embodiment of the present application further provides a system, which includes a server 10 and a node 20;
the server 10 is configured to send a verification instruction to the node, so that the verification instruction and the node perform verification according to the version number and the key stored in the node, where the verification instruction includes a version number to be verified and a key to be verified;
after the verification success information sent by the node is received, the data command is issued to the node, so that the node writes the upgrading data in the data command into the corresponding space and enables the upgrading data to complete patch upgrading;
the node 20 is used for receiving a verification instruction sent by the server, then performing verification according to the verification instruction, the version number stored by the node and the secret key, and sending verification success information to the server after the verification is successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified;
after receiving a data command issued by the server, writing the upgrade data in the data command into the corresponding space and enabling the upgrade data to complete patch upgrade.
According to the embodiment of the application, the function upgrading or problem repairing of the LORA protocol product can be completed remotely, maintenance personnel or engineers are not needed to carry out function upgrading or problem repairing on the LORA protocol product on site, the product repairing and function upgrading speed is greatly improved, the user experience is improved, the existing LORA protocol product does not need to be replaced, and the cost is saved.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The terms "first," "second," "third," "fourth," and the like in the description of the application and the above-described figures, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application described herein are, for example, capable of operation in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
It should be understood that in the present application, "at least one" means one or more, "a plurality" means two or more. "and/or" for describing an association relationship of associated objects, indicating that there may be three relationships, e.g., "a and/or B" may indicate: only A, only B and both A and B are present, wherein A and B may be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" or similar expressions refer to any combination of these items, including any combination of single item(s) or plural items. For example, at least one (one) of a, b, or c, may represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", wherein a, b, c may be single or plural.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.
Claims (8)
1. A patch upgrading method based on LORA protocol is applied to a server and comprises the following steps:
sending a verification instruction to a node to enable the node to verify according to a version number and a secret key stored in the node, wherein the verification instruction comprises a version number to be verified and a secret key to be verified; when the version number verification and the key verification are both successful, the node sends verification success information to the server, and different keys correspond to different products in the node;
after receiving the verification success information sent by the node, sending a protocol agreement request to the node for agreement, and after receiving the protocol agreement success information sent by the node, switching a channel where a product to be upgraded is located according to the content of the agreement so as to carry out next communication with the product to be upgraded in the node through the switched channel; and issuing a data command to the node, so that the node writes the upgrading data in the data command into the corresponding storage space of the node and enables the upgrading data to complete patch upgrading.
2. The patch upgrade method based on the LORA protocol as claimed in claim 1, wherein sending a data command to the node, so that the node stores upgrade data in the data command to a corresponding space and enables the upgrade data to complete patch upgrade specifically includes:
and repeatedly sending a batch of data commands to the node for multiple times, comparing the received batch of data commands with the data commands existing in the node after the node receives the batch of data commands each time, storing the data commands which do not exist in the node, and writing the upgrade data in all the stored data commands into corresponding spaces and enabling the upgrade data to finish patch upgrade after the receiving times reach the preset times.
3. A patch upgrading device based on LORA protocol is characterized in that the patch upgrading device is applied to a server and comprises:
the first checking unit is used for sending a checking instruction to the node so that the node can check according to the version number and the key stored in the node, wherein the checking instruction comprises the version number to be checked and the key to be checked; only after the version number verification and the key verification are successful, the node sends verification success information to the server, and different keys correspond to different products in the node;
the command issuing unit is used for sending a protocol agreement request to the node for agreement after receiving the verification success information sent by the node, and switching a channel where a product to be upgraded is located according to the content of the agreement after receiving the agreement success information sent by the node so as to carry out next communication with the product to be upgraded in the node through the switched channel; and issuing a data command to the node, so that the node writes the upgrading data in the data command into a corresponding space and enables the upgrading data to finish patch upgrading.
4. A patch upgrading method based on LORA protocol is applied to nodes and comprises the following steps:
receiving a verification instruction sent by a server, verifying according to the verification instruction and the version number and the secret key stored by the node according to the node, and sending verification success information to the server after version number verification and secret key verification are both successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified, and different secret keys correspond to different products in the node;
receiving a protocol agreement request sent by the server, and then sending protocol agreement success information to the server, so that the server switches a channel where a product to be upgraded is located according to the content of the protocol agreement after receiving the protocol agreement success information sent by the node, so that the product to be upgraded communicates with the server next time through the switched channel; and after the data command sent by the server is received, writing the upgrading data in the data command into the corresponding storage space of the node and enabling the upgrading data to finish patch upgrading.
5. The patch upgrade method based on the LORA protocol as claimed in claim 4, wherein if the server repeatedly sends a batch of data commands for multiple times, after receiving the data commands issued by the server, writing upgrade data in the data commands into a corresponding space and enabling the upgrade data to complete patch upgrade specifically includes:
after receiving a batch of data commands each time, comparing the received batch of data commands with the data commands existing in the batch of data commands, storing the data commands which do not exist in the batch of data commands, and writing the upgrading data in all the stored data commands into corresponding spaces and enabling the upgrading data after the receiving times reach the preset times so as to finish patch upgrading.
6. The patch upgrade method based on the LORA protocol as claimed in claim 4, wherein after receiving the data command issued by the server, before writing the upgrade data in the data command into the corresponding space and enabling, further comprising:
integrating the upgrading data in the data command according to the upgrading data serial number in the data command, and judging whether the upgrading data is lost or not according to the quantity of the upgrading data in the data command;
and if the upgrade data are not lost, performing security verification on all the upgrade data so as to write the upgrade data in the data command into a corresponding space and enable the upgrade data after the security verification is successful.
7. A patch upgrading device based on LORA protocol is applied to a node, and comprises:
the second verification unit is used for receiving a verification instruction sent by the server, then verifying according to the verification instruction and the version number and the secret key stored by the node according to the second verification unit, and sending verification success information to the server after the version number verification and the secret key verification are both successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified, and different secret keys correspond to different products in the node;
receiving a protocol agreement request sent by the server, and then sending protocol agreement success information to the server, so that the server switches a channel where a product to be upgraded is located according to the content of the protocol agreement after receiving the protocol agreement success information sent by the node, so that the product to be upgraded communicates with the server next time through the switched channel; and the upgrading unit is used for writing the upgrading data in the data command into a corresponding space and enabling the upgrading data after receiving the data command issued by the server so as to finish patch upgrading.
8. A system comprising a server and a node;
the server is used for sending a verification instruction to the node so that the node performs verification according to the version number and the key stored in the node, wherein the verification instruction comprises the version number to be verified and the key to be verified; when the version number verification and the key verification are both successful, the node sends verification success information to the server, and different keys correspond to different products in the node;
after receiving the verification success information sent by the node, sending a protocol agreement request to the node for agreement, and after receiving the protocol agreement success information sent by the node, switching a channel where a product to be upgraded is located according to the content of the agreement so as to carry out next communication with the product to be upgraded in the node through the switched channel; issuing a data command to the node, so that the node writes the upgrading data in the data command into a corresponding space and enables the upgrading data to complete patch upgrading;
the node is used for receiving a verification instruction sent by a server, then verifying according to the verification instruction and the version number and the secret key stored by the node, and sending verification success information to the server after the version number verification and the secret key verification are both successful, so that the server issues a corresponding data command, wherein the verification instruction comprises the version number to be verified and the secret key to be verified;
receiving a protocol agreement request sent by the server, and then sending protocol agreement success information to the server, so that the server switches a channel where a product to be upgraded is located according to the content of the protocol agreement after receiving the protocol agreement success information sent by the node, so that the product to be upgraded communicates with the server next time through the switched channel; and after the data command issued by the server is received, writing the upgrading data in the data command into a corresponding space and enabling the upgrading data to finish patch upgrading.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810827029.5A CN109002319B (en) | 2018-07-25 | 2018-07-25 | LORA protocol-based patch upgrading method, device and system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810827029.5A CN109002319B (en) | 2018-07-25 | 2018-07-25 | LORA protocol-based patch upgrading method, device and system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109002319A CN109002319A (en) | 2018-12-14 |
CN109002319B true CN109002319B (en) | 2022-07-08 |
Family
ID=64597149
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810827029.5A Active CN109002319B (en) | 2018-07-25 | 2018-07-25 | LORA protocol-based patch upgrading method, device and system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109002319B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109769237A (en) * | 2019-01-28 | 2019-05-17 | 三维通信股份有限公司 | A kind of method and system upgraded based on bluetooth and Lora double mode |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107251531A (en) * | 2015-02-17 | 2017-10-13 | 罗伯特·博世有限公司 | For carrying out the method that wireless firmware updates in the wide area network |
CN107835088A (en) * | 2017-09-26 | 2018-03-23 | 深圳市亿兆互联技术有限公司 | A kind of LoRa terminal devices over-the-air upgrade method and system |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104125276A (en) * | 2014-07-21 | 2014-10-29 | 中兴通讯股份有限公司 | Upgrading method and device |
CN106411619A (en) * | 2016-12-02 | 2017-02-15 | 北京博大光通物联科技股份有限公司 | Wireless equipment upgrading method based on low-power-consumption wide area network |
CN107247604A (en) * | 2017-05-17 | 2017-10-13 | 杭州魔猫科技有限公司 | A kind of charger baby software firmware update system and its update method |
-
2018
- 2018-07-25 CN CN201810827029.5A patent/CN109002319B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107251531A (en) * | 2015-02-17 | 2017-10-13 | 罗伯特·博世有限公司 | For carrying out the method that wireless firmware updates in the wide area network |
CN107835088A (en) * | 2017-09-26 | 2018-03-23 | 深圳市亿兆互联技术有限公司 | A kind of LoRa terminal devices over-the-air upgrade method and system |
Also Published As
Publication number | Publication date |
---|---|
CN109002319A (en) | 2018-12-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107820603A (en) | A kind of firmware update and controller | |
CN106681766B (en) | Remote firmware upgrade control method and system | |
CN106648781B (en) | Method and system for upgrading remote firmware of communication equipment | |
CN105224362A (en) | Host computer carries out the method and system of program upgrade to slave computer | |
CN107783857A (en) | A kind of abnormal restorative procedure and device, computer installation, readable storage medium storing program for executing | |
CN105187444A (en) | Key information burning method and device | |
CN109284140B (en) | Configuration method and related equipment | |
CN105227321A (en) | Information processing method, server and client | |
CN106850241A (en) | A kind of vehicle-mounted OBD terminals and its remote upgrade method | |
CN108709290A (en) | networking method and device of air conditioning system, storage medium and processor | |
CN103475512A (en) | Internet of Things remote management platform migration method, device and Internet of Things terminal | |
CN108052094A (en) | A kind of extension card identification method, device and frequency converter | |
JP7356601B1 (en) | New portable program upgrade method | |
CN109002319B (en) | LORA protocol-based patch upgrading method, device and system | |
CN106790756B (en) | Automatic generation method and system for MAC address of power distribution terminal | |
CN105162769A (en) | Gateway authority transfer method and gateway authority transfer device | |
CN103067503B (en) | A kind of device of application of synchronized relation management platform | |
CN112788576B (en) | Equipment offline processing method and system, storage medium and electronic device | |
CN107169053A (en) | log information deriving method and device | |
CN105516219A (en) | Safe deactivation method and system for embedded intelligent card, and card management server for safe deactivation of embedded intelligent card | |
CN107995033B (en) | ONU configuration file upgrading method and device | |
CN107147698B (en) | Remote control system, method and device of intelligent switch | |
CN103179016B (en) | Method, system and server that a kind of many example terminal roaming configuration datas upgrade | |
CN104333856A (en) | Method for switching network of Java SIM card, SIM card, server and system | |
CN114465876A (en) | Fault processing method, device, equipment and storage medium |
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 |