CN114489730A - Remote upgrading method, terminal equipment and computer readable storage medium - Google Patents

Remote upgrading method, terminal equipment and computer readable storage medium Download PDF

Info

Publication number
CN114489730A
CN114489730A CN202210095855.1A CN202210095855A CN114489730A CN 114489730 A CN114489730 A CN 114489730A CN 202210095855 A CN202210095855 A CN 202210095855A CN 114489730 A CN114489730 A CN 114489730A
Authority
CN
China
Prior art keywords
equipment
data packet
remote
terminal
sequence group
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210095855.1A
Other languages
Chinese (zh)
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.)
Hangzhou Tuya Information Technology Co Ltd
Original Assignee
Hangzhou Tuya Information Technology 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 Hangzhou Tuya Information Technology Co Ltd filed Critical Hangzhou Tuya Information Technology Co Ltd
Priority to CN202210095855.1A priority Critical patent/CN114489730A/en
Publication of CN114489730A publication Critical patent/CN114489730A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

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)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application discloses a remote upgrading method, terminal equipment and a computer readable storage medium, wherein the method comprises the following steps: responding to a remote upgrading instruction, and acquiring a remote upgrading data packet; acquiring an equipment sequence group, wherein the equipment sequence group comprises a plurality of terminal equipment; and issuing a remote upgrading data packet to a plurality of terminal equipment in the equipment sequence group by adopting a multicast technology so that the terminal equipment is upgraded by utilizing the remote upgrading data packet. The remote upgrading method can be used for specifically upgrading one type of equipment, greatly shortens the total time of remote upgrading of all equipment under the condition of large-scale terminal equipment, and improves the stability of remote upgrading of the large-scale terminal equipment and the reliability of data reporting.

Description

Remote upgrading method, terminal equipment and computer readable storage medium
Technical Field
The present application relates to the field of computer technologies, and in particular, to a remote upgrade method, a terminal device thereof, and a computer-readable storage medium.
Background
In recent years, wireless communication technology has become more and more important in the development of the internet of things. Under the epidemic situation, the wireless communication technology is widely applied to the fields of various internet of things such as smart homes, smart cities, smart agriculture and smart traffic due to the advantages of no contact, high reliability, single-point multi-control and the like. The Zigbee wireless communication technology plays an increasingly important role in the transmission layer and the perception layer of the Internet of things by virtue of the characteristics of low power consumption and low complexity, and the capability of establishing a huge wireless Internet of things network.
The principle of OTA (Over the air) technology is to perform remote firmware upgrade management on a terminal device based on wireless communication. With more and more Zigbee single nodes being put into use, the firmware upgrade of large-scale Zigbee single nodes still adopts the single-point OTA technology, and the requirements of synchronous and rapid upgrade of large-scale terminal equipment firmware cannot be met due to high repeatability, high time consumption and long-term instability of the operation.
Disclosure of Invention
In view of this, an object of the present application is to provide a remote upgrade method, which can upgrade a class of devices in a targeted manner, greatly shorten the total time for remotely upgrading all devices under a large-scale terminal device condition, and improve the stability of remote upgrade of the large-scale terminal device and the reliability of data reporting.
In order to solve the above technical problem, a first technical solution provided by the present application is: a remote upgrading method is provided, and comprises the following steps:
responding to a remote upgrading instruction, and acquiring a remote upgrading data packet;
acquiring an equipment sequence group, wherein the equipment sequence group comprises a plurality of terminal equipment;
and issuing a remote upgrading data packet to a plurality of terminal equipment in the equipment sequence group by adopting a multicast technology so as to enable the terminal equipment to be upgraded by utilizing the remote upgrading data packet.
The remote upgrading method further comprises the following steps:
issuing a remote upgrade notification to a plurality of terminal devices in the device sequence group to enable the terminal devices to enter a remote upgrade state;
wherein the remote upgrade notification includes at least one of: upgrade mode information, multicast protocol version, remote upgrade firmware key information, multi-bit enable bit.
The device sequence group further comprises a plurality of routers, and each router is in communication connection with at least one terminal device.
The sending the remote upgrade data packet to a plurality of terminal devices in the device sequence group by adopting a multicast technology comprises the following steps:
the remote upgrading data packet is issued to the router in the equipment sequence group by adopting the multicast technology;
and forwarding the remote upgrading data packet to a plurality of terminal devices through the router.
The sending a remote upgrade data packet to a plurality of terminal devices in the device sequence group by using a multicast technology includes:
acquiring communication information of a plurality of terminal devices in the device sequence group;
distributing the packet sending time of the terminal equipment according to the communication information of the terminal equipment by adopting a multicast technology;
and issuing the remote upgrading data packet according to the packet sending time of the plurality of terminal devices.
After the multicast technology is adopted to issue the remote upgrade data packet to the plurality of terminal devices in the device sequence group, the remote upgrade method includes:
issuing a missing query instruction to the terminal equipment;
acquiring missing sub-data packet serial numbers uploaded by the plurality of terminal devices based on the missing query instruction;
and transmitting the sub-data packet corresponding to the sub-data packet serial number to the plurality of terminal devices by adopting a multicast technology.
Wherein, the acquiring of the device sequence group includes:
acquiring a device management queue;
traversing the terminal equipment in the equipment management queue in a semaphore blocking waiting mode, and adding the terminal equipment into the equipment sequence group;
and traversing the terminal equipment which fails to join the equipment sequence group again until the traversal times reach the preset times.
The remote upgrading method further comprises the following steps:
responding to a group setting instruction of a cloud end, and creating the equipment sequence group based on the group equipment instruction;
and acquiring the grouping progress for creating the equipment sequence group, and sending the grouping progress to a mobile client so that the mobile client can visualize the grouping progress.
In order to solve the above technical problem, a second technical solution provided by the present application is: the remote upgrading method is applied to a remote upgrading system, and the remote upgrading system comprises a gateway end and an equipment end.
The gateway end responds to a remote upgrading instruction of a cloud end to obtain a remote upgrading data packet;
the gateway terminal acquires an equipment sequence group, wherein the equipment sequence group comprises a plurality of equipment terminals;
the gateway terminal issues a remote upgrading data packet to a plurality of equipment terminals in the equipment sequence group by adopting a multicast technology;
and the equipment terminal utilizes the remote upgrading data packet to upgrade.
After the gateway sends a remote upgrade data packet to a plurality of device terminals in the device sequence group by using a multicast technology, the remote upgrade method further includes:
the gateway terminal issues a missing query instruction to the equipment terminal;
the equipment side uploads the missing sub-data packet serial number based on the missing query instruction;
the gateway terminal issues the sub data packet corresponding to the sub data packet serial number to the device terminal by adopting a multicast technology;
and the equipment end judges whether the sub data packet is lost or not, discards the non-lost sub data packet and writes the lost sub data packet.
In order to solve the above technical problem, a third technical solution provided by the present application is: there is provided a terminal device comprising a processor for implementing a remote upgrade method as described above when executing a computer program stored in a memory.
In order to solve the above technical problem, a third technical solution provided by the present application is: there is provided a computer readable storage medium, which when executed by a processor, implements a remote upgrade method as described above.
The beneficial effect of this application is: the remote upgrading method can respond to the remote instruction to obtain the upgrading data packet, further obtain the equipment sequence group comprising the plurality of terminal equipment, and send the remote upgrading data packet to the plurality of equipment in the equipment sequence group by adopting the multicast technology, so that the upgrading of the plurality of terminal equipment is realized. The method can be used for specifically upgrading one type of equipment, greatly shortens the total time of remote upgrading of all equipment under the condition of large-scale terminal equipment, and improves the stability of remote upgrading of the large-scale terminal equipment and the reliability of data reporting.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts. Wherein:
FIG. 1 is a schematic flow chart diagram illustrating a first embodiment of a remote upgrade method provided in the present application;
FIG. 2 is a flowchart illustrating a second embodiment of a remote upgrade method provided in the present application;
FIG. 3 is a schematic workflow diagram of a remote upgrade system provided herein;
FIG. 4 is an interaction diagram of an embodiment of a remote upgrade system provided herein;
fig. 5 is a schematic structural diagram of an embodiment of a terminal device provided in the present application;
fig. 6 is a schematic structural diagram of a computer-readable storage medium provided in the present application.
Detailed Description
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.
The core of the application is to provide a remote upgrading method, which is used for solving the problem that the single-point OTA technology cannot meet the requirement of synchronous and rapid upgrading of the firmware of the large-scale terminal equipment due to high repeatability, high time consumption and long-term instability of the operation.
The present application will be described in detail with reference to the accompanying drawings and examples.
The terminal equipment of the application can be a server, and can also be a system in which the server and a local terminal are matched with each other. Accordingly, each part, for example, each unit, sub-unit, module, and sub-module, included in the terminal device of the present application may be all disposed in the server, or may be disposed in the server and the local terminal, respectively.
Further, the server may be hardware or software. When the server is hardware, it may be implemented as a distributed server cluster formed by multiple servers, or may be implemented as a single server. When the server is software, it may be implemented as a plurality of software or software modules, for example, software or software modules for providing distributed servers, or as a single software or software module, and is not limited herein. In some possible implementations, the remote upgrade method of the embodiments of the present application may be implemented by a processor calling computer-readable instructions stored in a memory. Specifically, the terminal device in the embodiment of the present application may specifically be a gateway end, and the following description takes the gateway end as a protection subject of the remote upgrade method.
As shown in fig. 1, fig. 1 is a schematic flow diagram of a first embodiment of a remote upgrade method provided by the present application, and the specific steps of the remote upgrade method according to the embodiment of the present application are as follows:
step S11: and responding to the remote upgrading instruction, and acquiring a remote upgrading data packet.
In the embodiment of the application, a user can initiate an upgrading request to the cloud end through the mobile client, and the cloud end receives an instruction of the upgrading request and then issues a remote upgrading instruction to the gateway end. The gateway end can respond to the remote upgrading instruction of the cloud end to obtain a remote upgrading data packet required by the equipment end.
Step S12: and acquiring a device sequence group, wherein the device sequence group comprises a plurality of terminal devices.
In the embodiment of the application, a remote upgrade data packet can be issued to an equipment end by adopting a multicast technology for a subsequent gateway end, so that the equipment end can be upgraded by using the remote upgrade data packet. The gateway terminal may obtain a device sequence group, where the device sequence group includes a plurality of terminal devices.
It should be noted that the multicast technology refers to a network communication in which a single sender corresponds to multiple receivers. In the multicast technology, by transmitting a single information stream to a plurality of receivers, the network communication flow under the condition that the plurality of receivers listen to or view the same resource at the same time can be reduced. In the embodiment of the application, the gateway can issue the remote upgrade data packet to the device by using a multicast technology.
Specifically, the gateway can establish a memory management linked list for the device sequence to perform group management on the devices. In the embodiments of the present application, the number of groups is not limited, and for example, the number of groups may be one group, or may be two or more groups.
In other embodiments, the device sequence group may further include a plurality of routers, wherein each router is communicatively connected to at least one terminal device. As can be understood, for the device end closer to the gateway end, the gateway end can directly perform communication connection with the device end; however, for the device end far away from the gateway end, in general, the device end needs to establish communication connection with the router first, and then perform communication connection with the gateway end through the router. Therefore, the gateway acquires the equipment sequence comprising a plurality of routers so as to realize communication with the equipment end with a longer distance, and further realize grouping.
Preferably, in order to enable the terminal device to be upgraded to enter into the group, in other embodiments, the gateway may further obtain a device management queue, where the device management queue includes a plurality of terminal devices to be grouped. Further, the gateway terminal traverses the terminal devices in the device management queue in a semaphore blocking waiting manner to add the terminal devices to the device sequence group. And for the terminal equipment which fails to enter the group, the gateway terminal traverses the terminal equipment which fails to join the equipment sequence group again until the traversal times reach the preset times.
It should be noted that the semaphore block waiting is a state where a program waits for a message, and the mechanism is a semaphore block waiting mechanism if a waiter cannot do anything other than waiting for the message in the whole waiting process. If present in a program, that is, the program is always blocked from further execution at the function call. In the embodiment of the present application, a plurality of device sides can only wait for traversal of the gateway side in sequence to join the group. If the equipment end fails to enter the group, the gateway end traverses the equipment end again to enable the equipment end to join the group.
Further, the preset number of traversal is not limited in the present application, for example, the number of traversal may be three, in this embodiment of the present application, for an equipment end that has failed to enter a group after traversing three times through a gateway end, the gateway end does not perform traversal any more, and considers that the equipment end fails to enter the group.
Preferably, in other embodiments, the gateway can create the device sequence group based on the group device instruction after responding to the group setting instruction of the cloud.
Specifically, the gateway end can actively report the respective remote upgrade attributes of the gateway end and the device end to the cloud end every time the gateway end is powered on again, and the attributes indicate whether the gateway end and the device end have the remote upgrade capability. The cloud terminal sends a group setting instruction to the gateway terminal after receiving the respective remote upgrading attributes of the gateway terminal and the equipment terminal sent by the gateway terminal, wherein the group comprises a plurality of equipment terminals meeting the remote upgrading capability.
Preferably, in order to enable the user to view the grouping progress of the device side through the mobile client. The gateway terminal can also obtain the grouping progress of creating the equipment sequence group, and the grouping progress is sent to the mobile client so that the mobile client can visualize the grouping progress.
Specifically, the gateway terminal can start the report timer of the group entry progress so as to proportionally display the group entry progress at the mobile client terminal, thereby enriching man-machine interaction. After the device end group entering action starts, the gateway end group entering progress reporting timer is started immediately, and the success or failure result of the group entering is reported to the cloud periodically, so that the pressure of the cloud for frequently receiving and sending data is relieved.
Step S13: and issuing the remote upgrading data packet to a plurality of terminal equipment in the equipment sequence group by adopting a multicast technology so that the plurality of terminal equipment are upgraded by utilizing the remote upgrading data packet.
In the embodiment of the application, after acquiring the device sequence group including the plurality of terminal devices, the gateway issues the remote upgrade data packet to the plurality of terminal devices in the device sequence group by using a multicast technology, so that the plurality of terminal devices are upgraded by using the remote upgrade data packet.
Based on the above embodiment, the gateway may also issue a remote upgrade data packet to the router in the device sequence group by using a multicast technology, so as to forward the remote upgrade data packet to the plurality of terminal devices through the router, thereby implementing the upgrade of the plurality of terminal devices by using the remote upgrade data packet.
Specifically, the gateway may first obtain communication information of a plurality of terminal devices in the device sequence group, then distribute packet sending time of the terminal devices according to the communication information of the device terminal by using a multicast technology, and finally issue a remote upgrade data packet to the terminal devices according to the packet sending time of the terminal devices.
It can be understood that when the gateway and the device communicate with each other, the two devices may interact with each other frequently through heartbeats, and meanwhile, since the gateway continuously broadcasts and sends the remote upgrade data packet to the device, and a large amount of signal energy of the gateway data source and the multicast data are forwarded between the routers at high frequency, it is very easy to encounter a CCA (Clear Channel Assessment) threshold problem of a collision avoidance mechanism, which causes the remote upgrade data packet to be sent unsuccessfully and lost by the IEEE 802.15.4 physical layer. Therefore, in order to utilize the occupied channel bandwidth to the maximum extent, analyze a large amount of firmware upgrading experiment frequency spectrums and the successful packet receiving rate of the equipment end, the gateway end can obtain the optimal packet sending time of the terminal equipment and send packets to the terminal equipment according to the communication information of the equipment end.
Note that CCA (Clear Channel Assessment) is a Channel Assessment. In a wireless communication system, before an apparatus needs to transmit data on a certain frequency channel, the apparatus firstly receives the data on the frequency channel, and if a given time passes, no other apparatus is found to transmit data on the frequency channel, the apparatus starts to transmit; if other devices are found to be transmitting data, the process is retried again after randomly avoiding for a period of time. The method can effectively avoid collisions on the wireless channel, also called carrier frequency interception multiple access with collision avoidance. In the embodiment of the application, if the transmission frequency from the gateway to the device exceeds the CCA threshold, collision of wireless channels is very likely to occur, and further, the remote upgrade data packet is failed to be transmitted and lost.
Therefore, in order to prevent the situation of data packet transmission failure caused by the CCA threshold problem, the gateway may obtain the optimal packet sending time of the terminal device according to the communication information of the device, and send the packet to the terminal device.
Preferably, the gateway end may adopt a dynamic interval time allocation method to circumvent this problem. The dynamic interval time allocation method is to adjust the communication time in the state when a line of a certain system works online, that is, communication is performed, so as to avoid the situation that the uplink and downlink traffic demands among a plurality of lines conflict. In the embodiment of the application, the gateway can adjust the packet sending time by adopting a dynamic interval time allocation method according to the communication information of the equipment end so as to send the packet to the equipment end according to the optimal packet sending time, thereby avoiding the condition of data packet sending failure caused by the CCA threshold problem.
It should be noted that the remote upgrade data packet is sent from the cloud to the gateway, and the gateway performs local storage operation on the remote upgrade data packet and then sends the remote upgrade data packet to the device.
Preferably, the gateway may analyze the url (uniform resource locator) link according to the remote upgrade data packet sent by the cloud and store the url link. Further, the gateway terminal can also perform local verification operation on the stored remote upgrade data packet.
Preferably, after the gateway end completes the local verification operation of the remote upgrade data packet, the gateway end may further issue a remote upgrade notification to a plurality of terminal devices in the device sequence group, so that the plurality of terminal devices enter a remote upgrade state.
It should be noted that, in the present application, information included in the remote upgrade notification is not limited, and may be, for example, upgrade mode information, a multicast protocol version, remote upgrade firmware key information, a multi-bit enable bit, and the like.
On the basis of the above embodiment, the gateway terminal issues the remote upgrade notification to the device terminals in the device sequence group, so that after the terminal devices enter the remote upgrade state, the gateway terminal can further send the remote upgrade data packet to the terminal devices. Because it can not be guaranteed that all terminal devices can receive the complete remote upgrade data packet, the remote upgrade data packet can be identified, so that the terminal devices can search missing data packets.
Preferably, the gateway end may read a locally stored remote upgrade data packet to construct load content, and then send the remote upgrade data packet to the device end. Because the maximum tolerance of a single remote upgrade data packet is 128B, the length of the APS frame header data is removed, the effective load 60B in the load content is adopted each time, and meanwhile, the information such as the control instruction type, the sub-packet equipment serial number, the data check bit and the like is added, so that the remote upgrade data packet is issued to the terminal equipment in the equipment sequence group by adopting the multicast technology.
Further, as shown in fig. 2, fig. 2 is a schematic flowchart of a second embodiment of the remote upgrade method provided in the present application. After the gateway sends the remote upgrade data packet to a plurality of terminal devices in the device sequence group by using a multicast technology, the gateway can further send a missing query instruction to the terminal devices to query whether the device fails to be upgraded.
Step S21: and issuing a missing query instruction to a plurality of terminal devices.
In the embodiment of the application, the gateway terminal issues a missing query instruction to a plurality of terminal devices to query whether the device terminal fails to be upgraded.
Step S22: and acquiring missing sub-data packet serial numbers uploaded by a plurality of terminal devices based on the missing query instruction.
In the embodiment of the application, for the device side which fails to be upgraded, the missing sub-packet serial number of the device side can be uploaded to the gateway side based on the missing query instruction.
Step S23: and transmitting the sub-data packet corresponding to the sub-data packet serial number to a plurality of terminal devices by adopting a multicast technology.
In the embodiment of the application, the gateway obtains the missing sub-packet serial numbers respectively uploaded by the terminal devices which fail to upgrade, and issues the sub-packets corresponding to the missing sub-packet serial numbers to the device terminals in the device sequence group by using a multicast technology.
Preferably, all the equipment terminals in the group receive the sub-data packets issued by the gateway terminal and judge whether the equipment terminals are missing, and for the equipment terminals missing the sub-data packets, the missing data packets are written into the cache; and for the device end which does not lack the sub-data packets, namely is upgraded successfully, discarding the data packets received later.
It can be understood that the gateway performs the report supplementing operation on the device side by using the multicast packet supplementing mode, the gateway presents an exponential decreasing trend for the number of traversed device packet supplementing, and meanwhile, the traversing, inquiring, responding and packet supplementing speed of the gateway is faster and faster, so that the execution speed of the group-rising data packet is greatly improved.
Preferably, when the gateway obtains the missing sub-packet serial numbers uploaded by the terminal device that fails to upgrade, the gateway is limited to the maximum 128B data tolerance of its single transmission, and the gateway may communicate with the device end in a differential cyclic response mode using the MF flag bit.
The MF flag bit is the lowest bit in the flag field in data transmission, and by setting the MF flag bit instead of the entire flag field, the receiver of the data can know the entire flag field where the flag bit is located, that is, the arrival time of the data packet, only through the MF flag bit.
Preferably, in order to reduce the task overhead of dynamic memory allocation in the whole transmission process, the gateway end may use a static memory allocation mode to record the missing sub-packet sequence of the device end, and may use a global offset as a supplementary packet identifier.
It should be noted that, the static memory allocation is to allocate the required memory space for the gateway automatically by the system, and when the data packet is used up in the active domain, the system will automatically release the occupied memory space for the gateway; the global offset is an analysis means of manual encryption, and the task overhead of dynamic memory allocation in the whole transmission process can be effectively reduced by setting a static memory allocation mode and a global offset means.
Referring to fig. 3, fig. 3 is a schematic view of a work flow of the remote upgrade system provided in the present application. As shown in fig. 3, a user sends an upgrade request to the cloud terminal through the mobile client, and the cloud terminal receives an instruction of the upgrade request and issues a notification of group establishment to the gateway terminal. And the gateway receives the group establishing instruction of the cloud and issues the group establishing instruction to the equipment end so as to establish the equipment end group, and the result is displayed to the user in a visualized manner through the mobile client.
Further, the gateway receives a remote upgrade data packet issued by the cloud, analyzes the remote upgrade data packet, and performs local cache operation and verification operation on the remote upgrade data packet through the analyzed url link.
Further, the gateway end broadcasts the remote upgrade data packet to the equipment end to realize the remote upgrade of the equipment end. The gateway end can start a group upgrade progress reporting timer, and the group upgrade progress and the required remaining time of the equipment end are displayed in a proportional mode through the mobile client. After the equipment end cluster is upgraded, the gateway end can further issue a missing query instruction to the terminal equipment to query whether the equipment end fails to be upgraded. All the equipment terminals in the group receive the sub-data packets issued by the gateway terminal and judge whether the equipment terminals are missing, and for the equipment terminals missing the sub-data packets, the missing data packets are written into a cache; and for the device end which does not lack the sub-data packets, namely is upgraded successfully, discarding the data packets received later. Furthermore, the gateway traverses and reports the current firmware versions of all the devices, so that the upgrading structure of the device side can be judged after cloud background inspection, and meanwhile, the result can be displayed at the mobile client side, and the user can conveniently check the result.
Further, after the group upgrading process is finished, the gateway end can report a finishing mark to the cloud end, the cloud end receives the finishing mark instruction and then conducts operations of group breaking and resource releasing, and the mobile client end is informed to conduct other operations for the user.
The remote upgrading method can be used for remotely upgrading large-scale terminal equipment in a centralized mode, the iteration threshold of product firmware of Zigbee nodes used in a large-scale mode by manual operation is reduced, and meanwhile, the CCA threshold collision problem caused in the packet sending process of the gateway end and the upgrading failure problem caused by the fact that the equipment end is influenced by network environment interference are avoided in a hundred percent mode by adopting an expected query response group packet supplementing mode. The gateway end communicates with the device end by using a multicast technology, and can perform data management on a plurality of devices needing group upgrading in a targeted manner. The realization of the multiple optimization modes greatly shortens the total time of successful remote upgrading of all equipment under large-scale terminal equipment, improves the stability of remote upgrading of the large-scale equipment, and greatly improves the control of the large-scale equipment, the reliability of data reporting and other performances.
Continuing to refer to fig. 4, fig. 4 is an interaction diagram of an embodiment of a remote upgrade system provided by the present application. The remote upgrade method according to the embodiment of the present application is applied to a remote upgrade system 300, where the remote upgrade system 300 includes a gateway end 33 and an equipment end 34. Further, the remote upgrade system may further include a mobile client 31 and a cloud 32.
In the embodiment of the present application, a user sends an upgrade request to the cloud end 32 through the mobile client 31, and the cloud end 32 receives an instruction of the upgrade request and sends a remote upgrade instruction to the gateway end 33. The gateway 33 responds to the remote upgrade instruction of the cloud 32, and obtains a remote upgrade data packet for the device 34 to upgrade. In addition, the gateway 33 obtains and labels a device sequence group through the device 34, where the device sequence group includes a plurality of device terminals 34. Further, the gateway 33 issues a remote upgrade data packet to a plurality of device terminals 34 in the device sequence group by using a multicast technology, so that the device terminals 34 perform upgrade by using the remote upgrade data packet.
Further, the gateway 33 may issue a missing query instruction to the device 34 to query whether the device 34 fails to upgrade. All the device ends 34 in the group receive the sub-data packets issued by the gateway end 33 and judge whether the device ends themselves are missing, and for the device end 34 missing the sub-data packet, the missing data packet is written into the cache; for the device end 34 that does not lack the sub-packets, i.e. that is successfully upgraded, the later received data packets are discarded.
With continuing reference to fig. 5, fig. 5 is a schematic structural diagram of an embodiment of a terminal device provided in the present application. The terminal device comprises a memory 41 and a processor 42 connected to each other.
The memory 41 is used to store the remote upgrade method implemented as described above.
Processor 42 is operative to execute program instructions stored in memory 41.
The processor 42 may also be referred to as a CPU (Central Processing Unit). Processor 42 may be an integrated circuit chip having the processing capability for signaling. The processor 42 may also be a general purpose processor, a Digital Signaling Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 41 may be a memory bank, a TF card, etc., and may store all information in the terminal device, including the input raw data, the computer program, the intermediate operation result, and the final operation result, all stored in the memory. It stores and retrieves information based on the location specified by the controller. With the memory, the system can only have the memory function to ensure the normal operation. The storage of the system is classified into a main storage (memory) and an auxiliary storage (external storage) according to the use, and also into an external storage and an internal storage. The external memory is usually a magnetic medium, an optical disk, or the like, and can store information for a long period of time. The memory refers to a storage component on the main board, which is used for storing data and programs currently being executed, but is only used for temporarily storing the programs and the data, and the data is lost when the power is turned off or the power is cut off.
In the several embodiments provided in the present application, it should be understood that the disclosed method and apparatus may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, a division of a module or a unit is merely a logical division, and an actual implementation may have another division, 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.
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 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 system server, a network device, or the like) or a processor (processor) to execute all or part of the steps of the method of the embodiments of the present application.
Referring to fig. 6, fig. 6 is a schematic structural diagram of a computer-readable storage medium according to the present application. The storage medium of the present application stores a program file 51 capable of implementing all the above remote upgrading methods, wherein the program file 51 may be stored in the storage medium in the form of a software product, and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor (processor) to execute all or part of the steps of the methods according to the embodiments of the present application. The aforementioned storage device includes: a U-disk, a portable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, or various media capable of storing program codes, or a computer, a server, a mobile phone, a tablet, or the like.
The above embodiments are merely examples and are not intended to limit the scope of the present disclosure, and all modifications, equivalents, and flow charts using the contents of the specification and drawings of the present disclosure or those directly or indirectly applied to other related technical fields are intended to be included in the scope of the present disclosure.

Claims (11)

1. A remote upgrading method is characterized by comprising the following steps:
responding to a remote upgrading instruction, and acquiring a remote upgrading data packet;
acquiring an equipment sequence group, wherein the equipment sequence group comprises a plurality of terminal equipment;
and issuing a remote upgrading data packet to a plurality of terminal equipment in the equipment sequence group by adopting a multicast technology so that the terminal equipment is upgraded by utilizing the remote upgrading data packet.
2. The remote upgrade method according to claim 1, further comprising:
issuing a remote upgrade notification to a plurality of terminal devices in the device sequence group to enable the terminal devices to enter a remote upgrade state;
wherein the remote upgrade notification includes at least one of: upgrade mode information, multicast protocol version, remote upgrade firmware key information, multi-bit enable bit.
3. The remote upgrade method according to claim 1 or 2,
the equipment sequence group also comprises a plurality of routers, and each router is in communication connection with at least one terminal equipment;
the sending the remote upgrade data packet to a plurality of terminal devices in the device sequence group by adopting a multicast technology comprises the following steps:
the remote upgrading data packet is issued to the router in the equipment sequence group by adopting the multicast technology;
and forwarding the remote upgrading data packet to a plurality of terminal devices through the router.
4. The remote upgrade method according to claim 1,
the sending the remote upgrade data packet to a plurality of terminal devices in the device sequence group by adopting a multicast technology comprises the following steps:
acquiring communication information of a plurality of terminal devices in the device sequence group;
distributing the packet sending time of the terminal equipment according to the communication information of the terminal equipment by adopting a multicast technology;
and issuing the remote upgrading data packet according to the packet sending time of the plurality of terminal devices.
5. The remote upgrade method according to claim 1,
after the multicast technology is adopted to issue the remote upgrading data packet to a plurality of terminal devices in the device sequence group, the remote upgrading method comprises the following steps:
issuing a missing query instruction to the terminal equipment;
acquiring missing sub-data packet serial numbers uploaded by the plurality of terminal devices based on the missing query instruction;
and transmitting the sub-data packet corresponding to the sub-data packet serial number to the plurality of terminal devices by adopting a multicast technology.
6. The remote upgrade method of claim 1, wherein the obtaining of the set of device sequences comprises:
acquiring a device management queue;
traversing the terminal equipment in the equipment management queue in a semaphore blocking waiting mode, and adding the terminal equipment into the equipment sequence group;
and traversing the terminal equipment which fails to join the equipment sequence group again until the traversal times reach the preset times.
7. The remote upgrade method according to claim 6, further comprising:
responding to a group setting instruction of a cloud end, and creating the equipment sequence group based on the group equipment instruction;
and acquiring the grouping progress for creating the equipment sequence group, and sending the grouping progress to a mobile client so that the mobile client can visualize the grouping progress.
8. A remote upgrading method is characterized in that the remote upgrading method is applied to a remote upgrading system, and the remote upgrading system comprises a gateway end and an equipment end; wherein the content of the first and second substances,
the gateway terminal responds to a remote upgrading instruction of the cloud terminal to obtain a remote upgrading data packet;
the gateway terminal acquires an equipment sequence group, wherein the equipment sequence group comprises a plurality of equipment terminals;
the gateway terminal issues a remote upgrading data packet to a plurality of equipment terminals in the equipment sequence group by adopting a multicast technology;
and the equipment terminal utilizes the remote upgrading data packet to upgrade.
9. The remote upgrade method according to claim 8, wherein after the gateway issues a remote upgrade data packet to a plurality of device terminals in the device sequence group by using a multicast technology, the remote upgrade method further includes:
the gateway terminal issues a missing query instruction to the equipment terminal;
the equipment side uploads the missing sub-data packet serial number based on the missing query instruction;
the gateway terminal issues the sub data packet corresponding to the sub data packet serial number to the device terminal by adopting a multicast technology;
and the equipment end judges whether the sub data packet is lost or not, discards the non-lost sub data packet and writes the lost sub data packet.
10. A terminal device comprising a processor, a memory coupled to the processor, wherein the memory stores program instructions; the processor is configured to execute the program instructions stored in the memory to implement the remote upgrade method of any one of claims 1 to 9.
11. A computer-readable storage medium storing program instructions which, when executed, implement the remote upgrade method of any one of claims 1 to 9.
CN202210095855.1A 2022-01-26 2022-01-26 Remote upgrading method, terminal equipment and computer readable storage medium Pending CN114489730A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210095855.1A CN114489730A (en) 2022-01-26 2022-01-26 Remote upgrading method, terminal equipment and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210095855.1A CN114489730A (en) 2022-01-26 2022-01-26 Remote upgrading method, terminal equipment and computer readable storage medium

Publications (1)

Publication Number Publication Date
CN114489730A true CN114489730A (en) 2022-05-13

Family

ID=81475777

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210095855.1A Pending CN114489730A (en) 2022-01-26 2022-01-26 Remote upgrading method, terminal equipment and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN114489730A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115001932A (en) * 2022-06-29 2022-09-02 无锡路通视信网络股份有限公司 Method and system for recovering or modifying equipment parameters in batches

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115001932A (en) * 2022-06-29 2022-09-02 无锡路通视信网络股份有限公司 Method and system for recovering or modifying equipment parameters in batches

Similar Documents

Publication Publication Date Title
CN108270732B (en) A kind of Streaming Media processing method and system
US9693092B2 (en) Method and system for transmitting network video
CN107979592B (en) Method and device for sending service request message
US11251981B2 (en) Communication method and apparatus
CN105991412B (en) Information push method and device
US20170164231A1 (en) Data transmission method and base station
JP2009544259A (en) Method and apparatus for policy enforcement in a wireless communication system
JP6598771B2 (en) Distributed data transmission in data networks
JP2016502778A (en) Device registration and sounding in time division multiple access networks
WO2017148446A1 (en) Network resource scheduling method, device and system, and network node
US20180109996A1 (en) Network accessing method
EP1914933B1 (en) Method and apparatus for retransmission request reduction in a network
CN103716230B (en) Message sending method, device and server
CN105933453A (en) Data transmission method and system
CN114489730A (en) Remote upgrading method, terminal equipment and computer readable storage medium
US11799576B2 (en) Data sending method and apparatus, and FlexE switching system
CN106559236B (en) Equipment resource management method and device of service board, main control board and frame type equipment
CN111294358B (en) Message processing method and device
CN117082054A (en) Data transmission method, device, system and medium
US9992767B2 (en) Data transmission method and device
CN106850153B (en) Data retransmission method and system
CN107231567B (en) Message transmission method, device and system
WO2017165999A1 (en) Network service implementation method, service controller, and communication system
CN103067280A (en) Method and device of message processing
CN114666846A (en) Communication method and gateway equipment

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