CN107835088B - Air upgrading method and system for LoRa terminal equipment - Google Patents

Air upgrading method and system for LoRa terminal equipment Download PDF

Info

Publication number
CN107835088B
CN107835088B CN201710881253.8A CN201710881253A CN107835088B CN 107835088 B CN107835088 B CN 107835088B CN 201710881253 A CN201710881253 A CN 201710881253A CN 107835088 B CN107835088 B CN 107835088B
Authority
CN
China
Prior art keywords
upgrading
upgrade
terminal equipment
lora terminal
lora
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710881253.8A
Other languages
Chinese (zh)
Other versions
CN107835088A (en
Inventor
陈祖江
钟景维
石庆
张治宇
马保军
俞浩
刘立明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Emaga Interconnect Technologies Co ltd
Original Assignee
Emaga Interconnect Technologies Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Emaga Interconnect Technologies Co ltd filed Critical Emaga Interconnect Technologies Co ltd
Priority to CN201710881253.8A priority Critical patent/CN107835088B/en
Publication of CN107835088A publication Critical patent/CN107835088A/en
Application granted granted Critical
Publication of CN107835088B publication Critical patent/CN107835088B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • H04L41/082Configuration setting characterised by the conditions triggering a change of settings the condition being updates or upgrades of network functionality
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/12Arrangements for detecting or preventing errors in the information received by using return channel
    • H04L1/16Arrangements for detecting or preventing errors in the information received by using return channel in which the return channel carries supervisory signals, e.g. repetition request signals
    • H04L1/18Automatic repetition systems, e.g. Van Duuren systems
    • H04L1/1812Hybrid protocols; Hybrid automatic repeat request [HARQ]
    • H04L1/1816Hybrid protocols; Hybrid automatic repeat request [HARQ] with retransmission of the same, encoded, message
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/12Arrangements for detecting or preventing errors in the information received by using return channel
    • H04L1/16Arrangements for detecting or preventing errors in the information received by using return channel in which the return channel carries supervisory signals, e.g. repetition request signals
    • H04L1/18Automatic repetition systems, e.g. Van Duuren systems
    • H04L1/1829Arrangements specially adapted for the receiver end
    • H04L1/1848Time-out mechanisms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W8/00Network data management
    • H04W8/22Processing or transfer of terminal data, e.g. status or physical capabilities
    • H04W8/24Transfer of terminal data
    • H04W8/245Transfer of terminal data from a network towards a terminal

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention provides an air upgrading method and system for LoRa terminal equipment, and belongs to the field of LoRa application. The method comprises the following steps: the method comprises the steps that a server obtains the positions of a movable upgrading device and LoRa terminal equipment needing upgrading; finding out idle frequency points, dividing the idle frequency points into upgrading frequency bands, and transmitting the idle frequency points and initial receiving and transmitting frequency points of LoRa terminal equipment to a movable upgrading device; controlling the movable upgrading device to move to a specified coordinate point; sending an upgrading instruction to LoRa terminal equipment; the server sends an upgrade starting instruction to the movable upgrading device, and the movable upgrading device sends a receiving and transmitting frequency point switching instruction to the LoRa terminal equipment after receiving the upgrade starting instruction, so that the LoRa terminal equipment is switched to an upgrade frequency point; and the LoRa terminal equipment receives the upgrading firmware of the movable upgrading device for upgrading. The invention has the beneficial effects that: the special upgrading frequency band is adopted, so that the communication performance of the whole system cannot be influenced in the upgrading process.

Description

Air upgrading method and system for LoRa terminal equipment
Technical Field
The invention relates to the field of LoRa application, in particular to an air upgrading method for LoRa terminal equipment, and further relates to a system for realizing the air upgrading method for LoRa terminal equipment.
Background
Due to the low data rate characteristic of the LoRa communication and the constraint of duty ratio for the channel use of the terminal device, there are a series of technical problems in upgrading the firmware of the terminal device, and the following three points are highlighted:
(1) most of the time when LoRa terminal equipment normally works is in dormancy, and upgrading by using a self network is unrealistic.
(2) If the number of terminal devices to be upgraded is large, congestion of the whole LoRa network may be caused, and communication performance of the whole system may be affected.
(3) For terminal equipment powered by a battery, if the air upgrading means is unreasonable, the power consumption can be greatly increased, and the service life of the battery is reduced.
Disclosure of Invention
In order to solve the problems in the prior art, the invention provides an air upgrading method for LoRa terminal equipment and a system for realizing the air upgrading method for LoRa terminal equipment.
The air upgrading method of the LoRa terminal equipment comprises the following steps:
s1: the server receives the upgrading requirement and acquires the LoRa terminal equipment information needing upgrading;
s2: acquiring or calculating the positions of the movable upgrading device and LoRa terminal equipment needing upgrading;
s3: finding out unused and available frequency points in an upgrading area, dividing the frequency points into upgrading frequency bands, and transmitting the frequency bands and initial receiving and transmitting frequency points of LoRa terminal equipment to a movable upgrading device;
s4: the server finds out an initial position in the upgrading area and sends the coordinates to the movable upgrading device, and the movable upgrading device is controlled to move to the specified coordinate point;
s5: the server sends an upgrading instruction to the LoRa terminal equipment needing upgrading, and the LoRa terminal equipment enters an upgrading mode;
s6: the server sends an upgrade starting instruction to the movable upgrading device, and the movable upgrading device sends a receiving and transmitting frequency point switching instruction to the LoRa terminal equipment after receiving the upgrade starting instruction, so that the LoRa terminal equipment is switched to an upgrade frequency point;
s7: and the LoRa terminal equipment receives the upgrading firmware of the movable upgrading device for upgrading.
The invention is further improved, and the method also comprises the step S8: and after the LoRa terminal equipment is upgraded successfully, feeding the result back to the server, and adjusting the position of the movable upgrading device by the server according to the upgrading quality or the result.
The present invention is further improved in that in step S5, after receiving the upgrade instruction from the server, the LoRa terminal device obtains an initial transceiving frequency point in the upgrade instruction, sets the transmission power and the data rate to be maximum, sets the initial receiving frequency point as the frequency point provided by the server, and opens and receives the transceiving frequency point instruction of the mobile upgrade apparatus.
The present invention further improves, in step S6, the LoRa terminal device determines whether a receiving and transmitting frequency point switching instruction of the mobile upgrade apparatus is received, and if so, changes the receiving and transmitting frequency point and receives a data packet of the upgrade firmware.
In step S7, after receiving the upgrade package of the removable upgrade apparatus, the LoRa terminal apparatus executes the following steps:
s71: judging whether an upgrade package is received from the movable upgrade device, if not, continuing to receive, if so, detecting whether the frame header is legal, if not, abandoning the upgrade package, and continuing to receive the upgrade package of the movable device; if the code is legal, executing the next step;
s72: judging whether CRC check is successful, if so, executing the next step, if not, giving up the upgrade package, and continuously receiving the upgrade package of the movable device;
s73: detecting whether the received upgrade package is a repeated frame, if so, abandoning the upgrade package, and continuing to receive the upgrade package of the movable device, if not, writing the upgrade package to the corresponding position of the program backup area according to the frame number of the data package in sequence, and adding 1 to the effective frame number;
s74: comparing the total frame number in the upgrade package with the actually received effective frame number to judge whether the upgrade is finished, if so, setting an update mark to be 1, writing the update mark to a corresponding position of a program backup area, then executing the next step, if not, judging whether the last upgrade package is received or the reception is overtime, if so, counting the lost package, sending the frame number of the lost package and the LoRa terminal equipment ID to the movable upgrade device at regular time to retransmit the mobile upgrade device next time, then receiving the upgrade package sent by the movable upgrade device, and if not, continuing to receive the upgrade package sent by the movable upgrade device;
s75: and receiving all the upgrade packages and upgrading.
In a further improvement of the present invention, the step S75 includes:
s751: the method comprises the steps that LoRa terminal equipment is in soft reset and enters BootLoader, the value of an updating mark is read, whether the value is 1 or not is judged, if yes, firmware area data of a program backup area are copied to a program to run, the updating mark is set to be 0, then step S752 is executed, and if not, step S753 is executed;
s752: judging whether the checking is successful, if so, executing step S753, otherwise, re-copying, and circularly executing step S752;
s753: skipping to program operation for execution;
s754: after the execution is finished, the LoRa terminal equipment enters a normal communication mode and uploads an upgrading result to the server;
s755: and the server receives the data uploaded by the LoRa terminal equipment and shows that the upgrade is successful.
In a further improvement of the present invention, in step S6, the step of processing the upgrade opening command received by the mobile upgrade apparatus from the server includes:
a61: judging whether an upgrading instruction of a server is received or not, if so, reading upgrading firmware of a self storage medium, if so, segmenting the upgrading firmware, packaging the upgrading firmware into upgrading packets according to formats, numbering the upgrading packets according to the sequence, then executing the next step, and if not, feeding back information of reading failure to the server;
a62: setting the sending frequency point as an initial receiving frequency point of LoRa terminal equipment, and setting the receiving frequency point as an initial sending frequency point of the LoRa terminal equipment;
a63: broadcasting the upgrade packages in sequence, judging whether the package loss information reported by LoRa terminal equipment is received or not after all the upgrade packages are sent out, if not, finishing the upgrade and feeding back to a server, and if so, executing the next step;
a64: and counting lost data packets of each LoRa terminal device, retransmitting the data packets and feeding the data packets back to the server, and then executing the step A62.
The invention also provides a system for realizing the air upgrading method of the LoRa terminal equipment, which comprises a server, the LoRa terminal equipment and a movable upgrading device, wherein the server is connected with the LoRa terminal equipment through a LoRa gateway, the server acquires information of the LoRa terminal equipment to be upgraded, finds out unused and available frequency points in an upgrading area, divides the unused and available frequency points into upgrading frequency bands, transmits the upgrading frequency bands and initial receiving and transmitting frequency points of the LoRa terminal equipment to the movable upgrading device, and then controls the movable upgrading device to move to a specified position to upgrade the LoRa terminal equipment through the upgrading frequency bands.
The invention is further improved, the movable upgrading device comprises an MCU, a storage medium, a motion execution unit, a plurality of LoRa transceiver units and a navigation unit, wherein the MCU is respectively connected with the storage medium, the motion execution unit, the LoRa transceiver units and the navigation unit, and the LoRa transceiver units comprise a plurality of transceiver modules for upgrading LoRa terminal equipment and a LoRa transceiver for communicating with a server.
The invention is further improved, the MCU is respectively connected with the LoRa transceiver and each transceiver module through the SPI adapter, wherein, the transceiver module comprises 1 LoRa digital baseband chip and 2 LoRa RF transceiver chips.
Compared with the prior art, the invention has the beneficial effects that: the upgrading special frequency band automatically divided by the server is adopted, the frequency band used by the current LoRa communication is avoided, and the effects that the normal communication of other terminal equipment and the communication performance of the whole system are not influenced when the LoRa terminal equipment is upgraded in the air are achieved; the method can upgrade a plurality of terminal devices simultaneously in a broadcasting mode, supports breakpoint retransmission and well-targeted retransmission strategies, effectively reduces power consumption in the upgrading process of some terminal devices and increases upgrading efficiency; the dynamic control effectively solves the problem that the upgrading quality and speed are influenced because the distance between the upgrading device and the upgraded equipment is long.
Drawings
FIG. 1 is a schematic structural view of the present invention;
FIG. 2 is a schematic diagram of a mobile upgrade apparatus;
FIG. 3 is a flow chart of the method of the present invention;
FIG. 4 shows a Flash partition of a LoRa terminal device;
fig. 5 is a flowchart of an air upgrade process of the LoRa terminal device;
FIG. 6 is a flowchart of an upgrade process for a mobile upgrade device;
fig. 7 is an upgrade package format uploaded to the LoRa terminal device by the mobile upgrade apparatus;
fig. 8 shows a data packet format uploaded to the mobile upgrade apparatus by the LoRa terminal device;
fig. 9 is a process flow diagram of a server over-the-air upgrade process.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples.
As shown in fig. 1, the upgrade system of the present invention includes a server, a LoRa terminal device (hereinafter referred to as a terminal device) and a mobile upgrade apparatus (hereinafter referred to as an upgrade apparatus), wherein the server is connected to the LoRa terminal device through a LoRa gateway, the server obtains information of the LoRa terminal device to be upgraded, finds out unused and available frequency points in an upgrade area, divides the upgrade area into upgrade frequency bands, transmits the upgrade frequency bands and initial transceiving frequency points of the LoRa terminal device to the mobile upgrade apparatus, and then controls the mobile upgrade apparatus to move to a designated location to upgrade the LoRa terminal device through the upgrade frequency bands.
As shown in fig. 2, the mobile upgrade apparatus includes a high-performance MCU (micro control unit), a storage medium, a motion execution unit, a plurality of LoRa transceiver units, and a navigation unit, and the MCU is connected to the storage medium, the motion execution unit, the plurality of LoRa transceiver units, and the navigation unit, respectively.
The LoRa transceiver unit of this example is divided into two parts, one part is specialized in carrying on the staging with LoRa terminal installation communication, each LoRa transceiver unit is made up of 1 LoRa digital baseband chip and 2 LoRa RF transceiver chips and peripheral circuit, LoRa digital baseband chip can be SX1301 or SX1308, etc. SX13xx series chip, LoRa RF transceiver chip can be SX1255 or SX1257, etc., multiple SX13xx can guarantee to receive and dispatch in parallel and carry on the multiple batch staging at the same time; another part of the LoRa transceiver, dedicated to communicate with the LoRa gateway in the LoRa communication system, may be an IC of the SX127x series, interacting with the server as the role of another terminal device. The LoRa digital baseband chip of this example can process 8 channels of data simultaneously, and can be configured by a user as required.
The mobile upgrading device of the embodiment further comprises an SPI (serial peripheral interface), and the MCU is respectively connected with the LoRa transceiver and each transceiver module through the SPI. The SPI (serial peripheral interface) switching interface can be a USB to an SPI or an SPI of an MCU directly.
The navigation unit in this example may be GPS, GLONASS, Galileo, beidou, etc., and is responsible for sports navigation. The motion execution unit can be an unmanned aerial vehicle, an unmanned vehicle and the like. The storage medium of the embodiment is connected with the MCU through a USB interface, can be a U disk and the like, and is used for storing upgrading firmware.
Before upgrading, the terminal equipment and the upgrading device need to be registered in the server in advance, and the upgrading firmware is stored in the USB storage medium of the upgrading device in advance. The upgrading firmware can also be transmitted to the upgrading device by the server through the IP network in advance by expanding IP network communication at the movable upgrading device.
As shown in fig. 3, the air upgrade method for the LoRa terminal device includes the following steps:
s1: the server receives the upgrading requirement and acquires the LoRa terminal equipment information needing upgrading;
s2: acquiring or calculating the positions of the movable upgrading device and LoRa terminal equipment needing upgrading;
s3: finding out unused and available frequency points in an upgrading area, dividing the frequency points into upgrading frequency bands, and transmitting the frequency bands and initial receiving and transmitting frequency points of LoRa terminal equipment to a movable upgrading device;
s4: the server finds out an initial position in the upgrading area and sends the coordinates to the movable upgrading device, and the movable upgrading device is controlled to move to the specified coordinate point;
s5: the server sends an upgrading instruction to the LoRa terminal equipment needing upgrading, and the LoRa terminal equipment enters an upgrading mode;
s6: the server sends an upgrade starting instruction to the movable upgrading device, and the movable upgrading device sends a receiving and transmitting frequency point switching instruction to the LoRa terminal equipment after receiving the upgrade starting instruction, so that the LoRa terminal equipment is switched to an upgrade frequency point;
s7: and the LoRa terminal equipment receives the upgrading firmware of the movable upgrading device for upgrading.
Further, step S8 may be further included: and after the LoRa terminal equipment is upgraded successfully, feeding the result back to the server, and adjusting the position of the movable upgrading device by the server according to the upgrading quality or the result.
As shown in fig. 4, Flash of the central processing unit of the terminal device in this embodiment is composed of BootLoader, a program operating area, and a program backup area, and Flash is one of the memory chips, and data in the Flash can be modified by a specific program. When the terminal equipment is reset, the BootLoader is firstly executed; the program backup area is used for storing an upgrading mark and actual firmware; the program execution area is used for executing the program.
As shown in fig. 5, in the air upgrade process of this embodiment, the execution steps of the terminal device are as follows: and during resetting, the BootLoader is firstly started, the upgrading mark of the program backup area is detected to see whether the firmware needs to be updated, if so, the firmware stored in the program backup area is copied to the program operation area, and then the program operation area is jumped to, if not, the program operation area is directly jumped to execute, and then the program operation area is jumped to and then the normal communication mode is started.
The detailed implementation process of the embodiment comprises the following steps:
in step S5, after receiving the upgrade instruction from the server, the LoRa terminal device obtains an initial transceiving frequency point in the upgrade instruction, sets the transmission power and the data rate to be maximum, sets the initial receiving frequency point to a frequency point provided by the server, and starts receiving the transceiving frequency point instruction of the mobile upgrade device.
In step S6, the LoRa terminal device determines whether a transceiver frequency point switching instruction of the mobile upgrade apparatus is received, and if so, changes the transceiver frequency point and receives a data packet of the upgrade firmware.
In step S7, the format of the upgrade packet uploaded to the terminal device by the upgrade apparatus in this embodiment is as shown in fig. 7, and includes a frame header, a frame number, a total frame number, a payload (payload), and a CRC (cyclic redundancy check code), and after receiving the upgrade packet of the mobile upgrade apparatus, the LoRa terminal device executes the following steps:
s71: judging whether an upgrade package is received from the movable upgrade device, if not, continuing to receive, if so, detecting whether the frame header is legal, if not, abandoning the upgrade package, and continuing to receive the upgrade package of the movable device; if the code is legal, executing the next step;
s72: judging whether CRC check is successful, if so, executing the next step, if not, giving up the upgrade package, and continuously receiving the upgrade package of the movable device;
s73: detecting whether the received upgrade package is a repeated frame, if so, abandoning the upgrade package, continuing to receive the upgrade package of the movable device, if not, writing payload to the corresponding position of the program backup area in sequence according to the frame number of the data package, and adding 1 to the effective frame number;
s74: comparing the total frame number in the upgrade package with the actually received effective frame number to judge whether the upgrade is finished, if so, setting an update mark to be 1, writing the update mark to a corresponding position of a program backup area, then executing the next step, if not, judging whether the last upgrade package is received or the reception is overtime, if so, counting the lost package, sending the frame number of the lost package and the LoRa terminal equipment ID to the movable upgrade device at regular time to retransmit the mobile upgrade device next time, then receiving the upgrade package sent by the movable upgrade device, and if not, continuing to receive the upgrade package sent by the movable upgrade device; as shown in fig. 8, the format of the data packet uploaded to the upgrade apparatus by the terminal device includes: frame header, terminal device ID, total number of missing frames, payload, and CRC, where payload includes a list of missing specific frames.
S75: and receiving all the upgrade packages and upgrading.
The processing procedure of step S75 specifically includes:
s751: the method comprises the steps that LoRa terminal equipment is in soft reset and enters BootLoader, the value of an updating mark is read, whether the value is 1 or not is judged, if yes, firmware area data of a program backup area are copied to a program to run, the updating mark is set to be 0, then step S752 is executed, and if not, step S753 is executed;
s752: judging whether the checking is successful, if so, executing step S753, otherwise, re-copying, and circularly executing step S752;
s753: skipping to program operation for execution;
s754: after the execution is finished, the LoRa terminal equipment enters a normal communication mode and uploads an upgrading result to the server;
s755: and the server receives the data uploaded by the LoRa terminal equipment and shows that the upgrade is successful.
In the air upgrading process, the upgrading device of the embodiment is mainly responsible for two threads, wherein the first thread is mainly responsible for receiving and processing the instruction transmitted by the server and controlling the motion of the upgrading device; the second thread is dedicated to processing the upgrade flow and reporting information to the server.
As shown in fig. 6, in step S6, after the removable upgrade apparatus receives an upgrade start instruction from the server, the processing step of the second thread includes:
a61: judging whether an upgrading instruction of a server is received or not, if so, reading upgrading firmware of a self storage medium, if so, segmenting the upgrading firmware, packaging the upgrading firmware into upgrading packets according to formats, numbering the upgrading packets according to the sequence, then executing the next step, and if not, feeding back information of reading failure to the server;
a62: setting the sending frequency point as an initial receiving frequency point of LoRa terminal equipment, and setting the receiving frequency point as an initial sending frequency point of the LoRa terminal equipment;
a63: broadcasting the upgrade packages in sequence, judging whether the package loss information reported by LoRa terminal equipment is received or not after all the upgrade packages are sent out, if not, finishing the upgrade and feeding back to a server, and if so, executing the next step;
a64: and counting lost data packets of each LoRa terminal device, retransmitting the data packets and feeding the data packets back to the server, and then executing the step A62.
As shown in fig. 9, as an embodiment of the present invention, the detailed execution process of the server in this embodiment is as follows:
c1: judging whether upgrading requirements of a client and the like are received or not, if so, acquiring or calculating the positions of an upgrading device and terminal equipment needing upgrading;
c2: counting frequency points which are used up currently by combining with the frequency bands of the regional specification, and finding out an idle frequency band to be used as an upgrading frequency band;
c3: searching an initial position point of the upgrading device and sending a control instruction to indicate the upgrading device to move to a specified position by combining the distribution of the terminal equipment to be upgraded and the maximum communication distance of LoRa;
c4: respectively sending an upgrading starting instruction to the terminal equipment and the upgrading device;
c5: judging whether the server receives data uploaded after the terminal equipment which enters the upgrading mode is upgraded, and if so, indicating that the corresponding terminal equipment is upgraded;
c6: judging whether terminal equipment which is not upgraded exists or updating failure feedback information of the upgrading device is received, if not, returning to the step C1, if so, judging whether upgrading instructions are improved according to the number of the terminal equipment which is upgraded at the present time, if so, returning to the step C5, and if not, controlling the upgrading device to move to the terminal equipment distribution area which is not upgraded;
c7: and sending a receiving and sending frequency point switching instruction to the upgrading device for next round upgrading.
The invention has the following outstanding advantages:
(1) the upgrading special frequency band automatically divided by the server is adopted, the frequency band used by the current LoRa communication is avoided, and the effects that the normal communication of other terminal equipment and the communication performance of the whole system are not influenced when the LoRa terminal equipment is upgraded in the air are achieved;
(2) the method can upgrade a plurality of terminal devices simultaneously in a broadcasting mode, supports breakpoint retransmission and well-targeted retransmission strategies, effectively reduces power consumption in the upgrading process of some terminal devices and increases upgrading efficiency;
(3) the mobility of the upgrading device and the self-contained navigation system are combined with the comprehensive decision and dynamic control of the server to ensure that all terminal equipment is successfully completed, and the problem that the upgrading quality and speed are influenced due to the long distance between the upgrading device and the upgraded equipment is effectively solved;
(4) the server can effectively avoid the influence on the upgrading quality caused by the interference of a communication channel or poor quality by dynamically adjusting the position of the receiving and transmitting frequency point switching and upgrading device during retransmission, and meanwhile, the frequency conversion can also ensure the upgrading safety to a certain extent.
The above-described embodiments are intended to be illustrative, and not restrictive, of the invention, and all changes that come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein.

Claims (10)

1. An air upgrading method of LoRa terminal equipment is characterized by comprising the following steps:
s1: the server receives the upgrading requirement and acquires the LoRa terminal equipment information needing upgrading;
s2: acquiring or calculating the positions of the movable upgrading device and LoRa terminal equipment needing upgrading;
s3: finding out unused and available frequency points in an upgrading region by combining the frequency bands of the regional specification, dividing the frequency points into upgrading frequency bands, and transmitting the upgrading frequency bands and the initial receiving and transmitting frequency points of LoRa terminal equipment to a movable upgrading device;
s4: the server finds out an initial position in the upgrading area and sends the coordinates to the movable upgrading device, and the movable upgrading device is controlled to move to the specified coordinate point;
s5: the server sends an upgrading instruction to the LoRa terminal equipment needing upgrading, and the LoRa terminal equipment enters an upgrading mode;
s6: the server sends an upgrade starting instruction to the movable upgrading device, and the movable upgrading device sends a receiving and transmitting frequency point switching instruction to the LoRa terminal equipment after receiving the upgrade starting instruction, so that the LoRa terminal equipment is switched to an upgrade frequency point;
s7: and the LoRa terminal equipment receives the upgrading firmware of the movable upgrading device for upgrading.
2. The air upgrade method of LoRa terminal equipment according to claim 1, characterized in that: further comprising step S8: and after the LoRa terminal equipment is upgraded successfully, feeding the result back to the server, and adjusting the position of the movable upgrading device by the server according to the upgrading quality or the result.
3. The air upgrade method of LoRa terminal equipment according to claim 1 or 2, characterized in that: in step S5, after receiving the upgrade instruction from the server, the LoRa terminal device obtains an initial transceiving frequency point in the upgrade instruction, sets the transmission power and the data rate to be maximum, sets the initial receiving frequency point to a frequency point provided by the server, and receives a frequency point switching instruction of the mobile upgrade device.
4. The air upgrade method of LoRa terminal equipment according to claim 3, characterized in that: in step S6, the LoRa terminal device determines whether a transceiver frequency point switching instruction of the mobile upgrade apparatus is received, and if so, changes the transceiver frequency point and receives a data packet of the upgrade firmware.
5. The air upgrade method of LoRa terminal equipment according to claim 4, characterized in that: in step S7, after receiving the upgrade package of the removable upgrade apparatus, the LoRa terminal device executes the steps of:
s71: judging whether an upgrade package is received from the movable upgrade device, if not, continuing to receive, if so, detecting whether the frame header is legal, if not, abandoning the upgrade package, and continuing to receive the upgrade package of the movable device; if the code is legal, executing the next step;
s72: judging whether CRC check is successful, if so, executing the next step, if not, giving up the upgrade package, and continuously receiving the upgrade package of the movable device;
s73: detecting whether the received upgrade package is a repeated frame, if so, abandoning the upgrade package, and continuing to receive the upgrade package of the movable device, if not, writing the upgrade package to the corresponding position of the program backup area according to the frame number of the data package in sequence, and adding 1 to the effective frame number;
s74: comparing the total frame number in the upgrade package with the actually received effective frame number to judge whether the upgrade is finished, if so, setting an update mark to be 1, writing the update mark to a corresponding position of a program backup area, then executing the next step, if not, judging whether the last upgrade package is received or the reception is overtime, if so, counting the lost package, sending the frame number of the lost package and the LoRa terminal equipment ID to the movable upgrade device at regular time to retransmit the mobile upgrade device next time, then receiving the upgrade package sent by the movable upgrade device, and if not, continuing to receive the upgrade package sent by the movable upgrade device;
s75: and receiving all the upgrade packages and upgrading.
6. The air upgrade method of LoRa terminal equipment according to claim 5, characterized in that: the step S75 includes the steps of:
s751: the method comprises the steps that LoRa terminal equipment is in soft reset and enters BootLoader, the value of an updating mark is read, whether the value is 1 or not is judged, if yes, firmware area data of a program backup area are copied to a program to run, the updating mark is set to be 0, then step S752 is executed, and if not, step S753 is executed;
s752: judging whether the checking is successful, if so, executing step S753, otherwise, re-copying, and circularly executing step S752;
s753: skipping to program operation for execution;
s754: after the execution is finished, the LoRa terminal equipment enters a normal communication mode and uploads an upgrading result to the server;
s755: and the server receives the data uploaded by the LoRa terminal equipment and shows that the upgrade is successful.
7. The air upgrade method of LoRa terminal equipment according to claim 1 or 2, characterized in that: the processing step of the mobile upgrade apparatus receiving the upgrade opening instruction of the server in step S6 includes:
a61: judging whether an upgrading instruction of a server is received or not, if so, reading upgrading firmware of a self storage medium, if so, segmenting the upgrading firmware, packaging the upgrading firmware into upgrading packets according to formats, numbering the upgrading packets according to the sequence, then executing the next step, and if not, feeding back information of reading failure to the server;
a62: setting the sending frequency point as an initial receiving frequency point of LoRa terminal equipment, and setting the receiving frequency point as an initial sending frequency point of the LoRa terminal equipment;
a63: broadcasting the upgrade packages in sequence, judging whether the package loss information reported by LoRa terminal equipment is received or not after all the upgrade packages are sent out, if not, finishing the upgrade and feeding back to a server, and if so, executing the next step;
a64: and counting lost data packets of each LoRa terminal device, retransmitting the data packets and feeding the data packets back to the server, and then executing the step A62.
8. An upgrade system for implementing the air upgrade method of the LoRa terminal device according to any one of claims 1 to 7, wherein: including server, loRa terminal equipment and portable upgrading device, wherein, the server passes through the loRa gateway and links to each other with loRa terminal equipment, the server acquires the loRa terminal equipment information that needs the upgrading, combines regional normative frequency channel, finds out the upgrading region and not used and available frequency point, divides the upgrading frequency channel to initial receiving and dispatching frequency point with upgrading frequency channel and loRa terminal equipment passes portable upgrading device, then it is right to control portable upgrading device to remove the assigned position through the upgrading frequency channel loRa terminal equipment upgrades.
9. The upgrade system according to claim 8, wherein: the movable upgrading device comprises an MCU, a storage medium, a motion execution unit, a plurality of LoRa receiving and sending units and a navigation unit, wherein the MCU is respectively connected with the storage medium, the motion execution unit, the LoRa receiving and sending units and the navigation unit, and the LoRa receiving and sending units comprise a plurality of receiving and sending modules used for upgrading LoRa terminal equipment and a LoRa transceiver used for communicating with a server.
10. The upgrade system according to claim 9, wherein: MCU passes through the SPI switching mouth and links to each other with loRa transceiver and every transceiver module respectively, wherein, transceiver module includes 1 loRa digital baseband chip and 2 loRa RF transceiver chips.
CN201710881253.8A 2017-09-26 2017-09-26 Air upgrading method and system for LoRa terminal equipment Active CN107835088B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710881253.8A CN107835088B (en) 2017-09-26 2017-09-26 Air upgrading method and system for LoRa terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710881253.8A CN107835088B (en) 2017-09-26 2017-09-26 Air upgrading method and system for LoRa terminal equipment

Publications (2)

Publication Number Publication Date
CN107835088A CN107835088A (en) 2018-03-23
CN107835088B true CN107835088B (en) 2020-10-23

Family

ID=61644020

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710881253.8A Active CN107835088B (en) 2017-09-26 2017-09-26 Air upgrading method and system for LoRa terminal equipment

Country Status (1)

Country Link
CN (1) CN107835088B (en)

Families Citing this family (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108664262A (en) * 2018-05-09 2018-10-16 顺丰科技有限公司 Firmware batch upgrading method, system and the storage medium of wireless sorting device
CN108810936A (en) * 2018-05-24 2018-11-13 新华三技术有限公司 A kind of configuration method and device of LoRa terminals
CN108874422B (en) * 2018-06-15 2022-03-01 合肥美的电冰箱有限公司 Software online upgrading method for refrigerator electric control board, refrigerator electric control board and refrigerator
CN109002319B (en) * 2018-07-25 2022-07-08 东信和平科技股份有限公司 LORA protocol-based patch upgrading method, device and system
CN110855462A (en) * 2018-08-21 2020-02-28 深圳瑞利声学技术股份有限公司 Bluetooth OTA firmware upgrading device
CN109857436A (en) * 2019-01-16 2019-06-07 浙江天地人科技有限公司 Equipment room diffusion type method for upgrading software under a kind of line
CN109857435B (en) * 2019-01-16 2022-07-19 浙江天地人科技有限公司 Diffusion type software upgrading method between offline devices
CN111831311A (en) * 2019-04-18 2020-10-27 东莞新能安科技有限公司 Application program upgrading method, electronic equipment and storage medium
CN111970136B (en) * 2019-05-20 2022-12-30 深圳长城开发科技股份有限公司 Firmware upgrading method, loRa gateway, loRa system and computer readable storage medium
CN110769411B (en) * 2019-10-23 2022-10-21 厦门四信通信科技有限公司 Method, device, equipment and system for stably realizing batch OTA (over the air) upgrade of terminal equipment
CN111417112B (en) * 2020-02-19 2023-02-07 成都四相致新科技有限公司 Distributed OTA gateway networking and terminal access method and OTA upgrading system
CN111459528B (en) * 2020-04-01 2024-01-09 Tcl移动通信科技(宁波)有限公司 Frequency band upgrading method, system, storage medium and mobile terminal
CN114339723B (en) * 2020-10-10 2024-01-26 深圳长城开发科技股份有限公司 Air upgrading method and system based on LoRa
CN114020304A (en) * 2022-01-06 2022-02-08 杭州字节信息技术有限公司 LoRaWan-based OTA implementation method, terminal device and computer storage medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20080051221A (en) * 2006-12-05 2008-06-11 삼성전자주식회사 Broadcasting receiving apparatus and control method the same
US8428649B2 (en) * 2008-08-20 2013-04-23 Sandisk Technologies Inc. Memory device upgrade
CN102006510A (en) * 2010-11-26 2011-04-06 康佳集团股份有限公司 Set-top box as well as method and device for set-top box software upgrading
CN102761599A (en) * 2012-05-10 2012-10-31 Ut斯达康通讯有限公司 Scalable file distribution method used in distributed system
CN103995723B (en) * 2014-05-26 2018-08-03 惠州华阳通用电子有限公司 A kind of method and apparatus upgrading IVI system firmwares based on movable storage device
CN106972960A (en) * 2017-03-17 2017-07-21 杭州全视软件有限公司 A kind of adaptation networking detector, the method for controller

Also Published As

Publication number Publication date
CN107835088A (en) 2018-03-23

Similar Documents

Publication Publication Date Title
CN107835088B (en) Air upgrading method and system for LoRa terminal equipment
US20230199889A1 (en) Methods and apparatus for processing beam failure of a secondary cell
US10187905B2 (en) Target wake time (TWT) scheduling for orthogonal frequency-division multiple access (OFDMA) channelization
US10165581B2 (en) Machine type communication scheduling method, base station, and user equipment
TWI590635B (en) Communication device and method for transmiting packets
US20230309114A1 (en) Method and device for processing downlink control information
US20220295343A1 (en) System selection for high-throughput wireless communications
EP2996417A1 (en) Timing adjustment method and device
US20230081816A1 (en) HARQ Process Based Data Transmission Method and Terminal
CN111770578A (en) Resource determination method, device, network element and system
US20210410184A1 (en) Apparatus and method for multefire industry release (mfir)
CN113518450A (en) Transmission method and device for uplink channel
EP3113374A1 (en) Communication device and communication system using same
CN102138295B (en) Communication system, dependent station thereof and dependent-station relay transmission method
EP3316606A1 (en) Beacon sensor advertisement frame
US20220174688A1 (en) Data transmission method and device
WO2021056583A1 (en) Uplink transmission method and apparatus
CN109802800B (en) Communication method and device
US11991713B2 (en) Data scheduling method, apparatus, and system
EP3993296A1 (en) Method, device and system for determining sidelink resource
CN115603881A (en) Auxiliary indication of resource reservation in sidelink
CN113485735A (en) Equipment upgrading method and device, storage medium and electronic device
CN102869102A (en) Asynchronous adaptive relative timeslot distribution method based on chirp spread spectrum (CSS) technology
JP6859838B2 (en) Wireless communication system
EP4199401A1 (en) Data transmission method and communications apparatus

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