A remote update method for Internet of Things devices and Internet of Things system
By setting up coordinators and terminal devices in the Internet of Things system, remote updates of IoT devices are solved, and the problems of complexity and inefficiency of traditional update methods are improved, and update efficiency and communication reliability are improved.
Patent Information
- Application Number
- CN202510132495.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-06
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2045-02-06
AI Technical Summary
It is difficult for the existing technology to achieve remote update of IoT devices. Traditional methods require on-site operation by technicians, with large workloads and complex update processes.
By setting up a coordinator and terminal equipment in the Internet of Things system, the terminal equipment reports the version number in the specified time unit. The coordinator generates update task instructions based on the version number, and broadcasts update task instructions through the wireless communication module. The target terminal equipment receives and performs updates on the specified time slice.
Remote updates of IoT devices are realized, update efficiency and communication bandwidth are improved, interference risks are reduced, and communication reliability is ensured.
Smart Images

Figure CN119583345B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of Internet of Things, and in particular to a remote updating method for Internet of Things devices and an Internet of Things system. Background Art
[0002] In the industrial Internet application scenario, IoT devices are widely used for data collection, monitoring and control. IoT devices usually achieve mutual connection and data transmission through wireless communication technology, such as ZigBee.
[0003] With the promotion and popularization of various IoT devices, various IoT devices are booming. Currently, many IoT devices are far apart and there are many of them. After the IoT devices are put into use, the device programs need to be updated due to program vulnerabilities or new user needs. The traditional update method is that relevant technicians go to the site to update the devices with code burning tools, which is labor-intensive and the update process is complicated. Therefore, how to achieve remote update of IoT devices has become a difficult problem that technicians in this field are concerned about. Summary of the invention
[0004] The purpose of the present invention is to provide an Internet of Things device remote update method and an Internet of Things system to improve the above-mentioned problems.
[0005] In order to achieve the above purpose, the technical solution adopted by the embodiment of the present invention is as follows:
[0006] In a first aspect, an embodiment of the present invention provides a remote update method for an Internet of Things device, which is applied to an Internet of Things system, wherein the Internet of Things system includes a coordinator and multiple terminal devices, wherein the coordinator is provided with M wireless communication modules, and the terminal device is provided with a wireless communication module, and the method includes:
[0007] The terminal device transmits data to the main communication module during the corresponding indicator reporting period in the ni-th time unit to report the current version number of the terminal device to the coordinator, wherein the main communication module is any one of the M wireless communication modules in the coordinator, and the ni-th time unit is the i-th time unit in the n-th time interval;
[0008] The coordinator determines the amount of data to be transmitted according to the current version number of the terminal device;
[0009] The coordinator generates an update task instruction according to the amount of data to be transmitted of each of the terminal devices, wherein the update task instruction includes a target update task corresponding to a target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device;
[0010] The coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the nith time unit;
[0011] After receiving the update task instruction, the target terminal device executes its corresponding target update task and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
[0012] Optionally, the step of the coordinator determining the amount of data to be transmitted according to the current version number of the terminal device includes:
[0013] The coordinator compares the current version number of the terminal device with the target version number to determine whether the two are consistent;
[0014] If they are consistent, the coordinator determines that the amount of data to be transmitted of the terminal device is 0;
[0015] If they are inconsistent, the coordinator determines whether the update data corresponding to the target version number has been sent to the terminal device according to the update record of the terminal device;
[0016] If the update data corresponding to the target version number has not been sent to the terminal device, the coordinator uses all the update data corresponding to the target version number as the update data to be transmitted, and then determines the amount of data to be transmitted;
[0017] If the update data corresponding to the target version number has been sent to the terminal device, the coordinator uses the remaining update data corresponding to the target version number as the update data to be transmitted, and further determines the amount of data to be transmitted.
[0018] In a second aspect, an embodiment of the present invention provides a remote update method for an Internet of Things device, which is applied to a coordinator in an Internet of Things system, wherein the Internet of Things system includes the coordinator and a plurality of terminal devices, wherein the coordinator is provided with M wireless communication modules, and the terminal device is provided with a wireless communication module, wherein the method includes:
[0019] The coordinator determines the amount of data to be transmitted according to the current version number of the terminal device, wherein the current version number is the indicator data reported by the terminal device in the corresponding indicator reporting period in the ni-th time unit, and the ni-th time unit is the ith time unit in the n-th time interval;
[0020] The coordinator generates an update task instruction according to the amount of data to be transmitted of each of the terminal devices, wherein the update task instruction includes a target update task corresponding to a target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device;
[0021] The coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the nith time unit, so that the target terminal device executes its corresponding target update task after receiving the update task instruction, and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
[0022] In a third aspect, an embodiment of the present invention provides an Internet of Things system, the Internet of Things system comprising a coordinator and a plurality of terminal devices, the coordinator being provided with M wireless communication modules, and the terminal device being provided with a wireless communication module;
[0023] The terminal device is used to report the current version number of the terminal device to the coordinator by transmitting data to the main communication module during the corresponding indicator reporting period in the ni-th time unit, wherein the main communication module is any one of the M wireless communication modules in the coordinator, and the ni-th time unit is the ith time unit of the n-th time interval;
[0024] The coordinator is used to determine the amount of data to be transmitted according to the current version number of the terminal device;
[0025] The coordinator is used to generate an update task instruction according to the amount of data to be transmitted of each of the terminal devices, wherein the update task instruction includes a target update task corresponding to a target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device;
[0026] The coordinator is used to broadcast the update task instruction through the main communication module during the task broadcast period of the nith time unit;
[0027] The target terminal device is used to execute its corresponding target update task after receiving the update task instruction, and complete the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
[0028] Optionally, the coordinator is further configured to broadcast a clock alignment instruction through the main communication module during a clock broadcast period of the ni-th time unit;
[0029] The terminal device is also used to receive the clock alignment instruction through its internal wireless communication module during the clock broadcast period of the ni-th time unit, and complete the clock alignment based on the clock alignment instruction.
[0030] Compared with the prior art, the embodiment of the present invention provides a remote update method and system for an Internet of Things device. In the corresponding indicator reporting period of the terminal device in the ni time unit, the terminal device transmits data to the main communication module to report the current version number of the terminal device to the coordinator, and the coordinator determines the amount of data to be transmitted according to the current version number of the terminal device; the coordinator generates an update task instruction according to the amount of data to be transmitted of each terminal device; the coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the ni time unit; after receiving the update task instruction, the target terminal device executes its corresponding target update task, and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice. In the remote update method for an Internet of Things device provided by the embodiment of the present invention, when there are multiple target terminal devices, the multiple target terminal devices can perform data transmission in parallel with the multiple target communication modules, effectively improving the communication bandwidth of the Internet of Things system and improving the update efficiency of the Internet of Things device. In addition, different target communication modules correspond to different frequency bands, which avoids the situation where multiple terminal devices compete for the same target communication module, reduces the risk of interference, and ensures the reliability of communication.
[0031] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, preferred embodiments are given below and described in detail with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0033] Figure 1 A schematic diagram of the structure of an Internet of Things system provided by an embodiment of the present invention.
[0034] Figure 2 A schematic diagram of a management cycle provided by an embodiment of the present invention.
[0035] Figure 3 A schematic diagram of a time unit provided by an embodiment of the present invention.
[0036] Figure 4 One of the flow charts of the remote update method of the Internet of Things device provided by the embodiment of the present invention.
[0037] Figure 5 A schematic diagram of the relationship between a data transmission time slice and a data transmission period provided in an embodiment of the present invention.
[0038] Figure 6 The second flowchart of the remote update method of the Internet of Things device provided by the embodiment of the present invention.
[0039] Figure 7 The third flowchart of the remote update method of the Internet of Things device provided by the embodiment of the present invention.
[0040] In the figure: 10 - coordinator; 20 - terminal device. DETAILED DESCRIPTION
[0041] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.
[0042] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0043] Some embodiments of the present invention are described in detail below in conjunction with the accompanying drawings. In the absence of conflict, the following embodiments and features in the embodiments can be combined with each other.
[0044] In order to quickly and conveniently implement remote updates of IoT devices, the present invention provides an optional implementation method, please refer to Figure 1 , Figure 1 A schematic diagram of the structure of an Internet of Things system provided by an embodiment of the present invention.
[0045] The Internet of Things system includes a coordinator 10 and multiple terminal devices 20, wherein the coordinator 10 is provided with M wireless communication modules, and the terminal device 20 is provided with a wireless communication module, wherein M is greater than or equal to 1, and the wireless communication module in the coordinator 10 is of the same type as the wireless communication module in the terminal device 20. The wireless communication module in the terminal device 20 can perform data transmission with any wireless communication module in the coordinator 10.
[0046] like Figure 1As shown, the coordinator 10 is further provided with a first controller, and the terminal device 20 is further provided with a second controller. The first controller and the second controller can be but are not limited to a microcontroller unit (MCU), a central processing unit (CPU), a network processor (NP), etc.; they can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
[0047] The first controller is communicatively connected to the M wireless communication modules in the coordinator 10, and the second controller is communicatively connected to the wireless communication module in the terminal device 20. The first controller and the second controller can perform data transmission through the above-mentioned wireless communication modules.
[0048] Optionally, the terminal device 20 is a sensor device, and the sensor device also includes a data acquisition unit, which is communicatively connected to the second controller. The data acquisition unit can be, but is not limited to, a temperature acquisition unit, a humidity acquisition unit, a stress acquisition unit, a vibration amplitude acquisition unit, etc. The data acquisition unit can transmit the collected data to the second controller. Then, the second controller transmits it to the first controller in the coordinator through the wireless communication module, and the first controller can perform preliminary processing on the received data and transmit the processed data to the server.
[0049] The wireless communication module supports broadcast data and may be, but is not limited to, a ZigBee communication module, a WiFi communication module, a Bluetooth communication module, a 4G communication module or a 5G communication module.
[0050] It should be noted that Figure 1 It is shown that the coordinator 10 is provided with three wireless communication modules and the number of terminal devices 20 is three. This is just for the convenience of demonstration. The specific number of the two is not limited here. Engineers can flexibly adjust according to application requirements.
[0051] In the embodiment of the present invention, the management cycle is divided into multiple time intervals, each time interval is divided into multiple time units, and each time unit is divided into multiple time periods. By performing different actions at different time points, the M wireless communication modules in the coordinator 10 are time-division multiplexed to achieve the purpose of improving system bandwidth and improving update efficiency. To facilitate understanding of the relationship between the above time units, please refer to Figure 2 and Figure 3 , Figure 2 A schematic diagram of a management cycle provided by an embodiment of the present invention, Figure 3 A schematic diagram of a time unit provided by an embodiment of the present invention. The management period TG is divided into N time intervals, Tn represents the nth time interval, 1≤n≤N, each time interval is divided into I time units, Si represents the i-th time unit in the time interval, 1≤i≤I.
[0052] Optionally, each time unit is divided into multiple time periods, including a clock broadcast period Ga, K indicator reporting periods Gb, a task broadcast period Gc and a data transmission period Gd, where Gbk represents the indicator reporting period corresponding to the kth terminal device 20, 1≤k≤K, and K is the total number of terminal devices 20.
[0053] The embodiment of the present invention provides a remote update method for an IoT device, which can be applied to but not limited to the IoT system described above. For the specific process, please refer to Figure 4 The remote update method of the IoT device includes: S40, S50, S60, S70 and S80, which are described in detail as follows.
[0054] S40, the terminal device reports the current version number of the terminal device to the coordinator by transmitting data to the main communication module during the corresponding indicator reporting period in the ni-th time unit.
[0055] The main communication module is any one of the M wireless communication modules in the coordinator, and the ni-th time unit is the ith time unit in the n-th time interval.
[0056] In the same indicator reporting period, only one terminal device 20 uses the frequency band corresponding to the main communication module to transmit data to the main communication module to report the corresponding indicator data to the coordinator 10, thereby avoiding the situation where multiple terminal devices 20 report indicator data at the same time in the same period, resulting in overlap, and the coordinator 10 cannot fully obtain the indicator data of all terminal devices 20.
[0057] S50, the coordinator determines the amount of data to be transmitted according to the current version number of the terminal device.
[0058] The amount of data to be transmitted refers to the amount of update data to be transmitted.
[0059] S60, the coordinator generates an update task instruction according to the amount of data to be transmitted of each terminal device.
[0060] The update task instruction includes a target update task corresponding to the target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device.
[0061] Optionally, the information of the data transmission time slice includes the start time of the data transmission time slice and the duration of the data transmission time slice, and the data transmission time slice corresponding to the target terminal device belongs to the data transmission period Gd of the ni-th time unit. It should be noted that any target communication module is assigned to at most one terminal device 20 at the same time point. The number of target terminal devices can be greater than or equal to 1.
[0062] S70, the coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the ni-th time unit.
[0063] It should be understood that all terminal devices 20 will receive the update task instruction broadcast by the main communication module during the task broadcast period, and identify whether the target terminal device identification in the target update task is the same as its own identification. If the same, it is determined that it is the target terminal device and can execute the target update task.
[0064] S80, after receiving the update task instruction, the target terminal device executes its corresponding target update task and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
[0065] It should be noted that the coordinator 10 will send the update data corresponding to the target version number to the target terminal device through the target communication module during the data transmission time slice corresponding to the target terminal device. The wireless communication module in the target terminal device maintains the same frequency band as the target communication module, and completes the version update by receiving the update data transmitted by the target communication module.
[0066] In the remote update method for IoT devices provided by the embodiment of the present invention, when there are multiple target terminal devices, the multiple target terminal devices can perform data transmission in parallel with multiple target communication modules, effectively improving the communication bandwidth of the IoT system and the update efficiency of IoT devices. Different target communication modules correspond to different frequency bands, which avoids the situation where multiple terminal devices compete for the same target communication module, reduces the risk of interference, and ensures the reliability of communication.
[0067] exist Figure 4Based on the content in S50, the embodiment of the present invention also provides an optional implementation, please refer to the following. S50, the coordinator determines the amount of data to be transmitted according to the current version number of the terminal device, including: S501, S502, S503, S504 and S505, which are specifically described as follows.
[0068] S501, the coordinator compares the current version number of the terminal device with the target version number to determine whether the two are consistent. If they are consistent, S502 is executed; if they are inconsistent, S503 is executed.
[0069] S502: The coordinator determines that the amount of data to be transmitted of the terminal device is 0.
[0070] When the amount of data to be transmitted of the terminal device is 0, it means that it does not need to be updated in the current time unit.
[0071] S503, the coordinator determines whether the update data corresponding to the target version number has been sent to the terminal device according to the update record of the terminal device. If the update data corresponding to the target version number has not been sent to the terminal device, execute S504; if the update data corresponding to the target version number has been sent to the terminal device, then S505.
[0072] It should be noted that, when the coordinator determines that the current version number is different from the target version number, it may request the update data corresponding to the target version number from the server and cache the received update data corresponding to the target version number.
[0073] S504: The coordinator takes all update data corresponding to the target version number as update data to be transmitted, and further determines the amount of data to be transmitted.
[0074] If the update data corresponding to the target version number has been sent to the terminal device, then in S505, the coordinator uses the remaining update data corresponding to the target version number as the update data to be transmitted, and further determines the amount of data to be transmitted.
[0075] In an embodiment of the present invention, the update task instruction includes one or more target update tasks. On this basis, regarding how to generate the target update task, the embodiment of the present invention also provides an optional implementation method, please refer to the following. The coordinator generates the target update task in the update task instruction according to the amount of data to be transmitted of each terminal device, including: S601-S611, which is specifically described as follows.
[0076] S601, the coordinator determines the target duration required by the terminal device according to the amount of data to be transmitted and the transmission speed of the terminal device.
[0077] The target duration is the value of the amount of data to be transmitted divided by the transmission speed.
[0078] S602: The coordinator prioritizes the terminal devices whose target duration is greater than 0.
[0079] It should be understood that if the target duration is 0, it means that it does not need to be updated in the nith time unit, so no priority sorting is performed. In the embodiment of the present invention, by prioritizing the terminal devices 20 with target durations greater than 0, it is ensured that the terminal devices 20 with higher priorities can complete the update faster.
[0080] In an optional implementation, the coordinator 10 stores the priority level corresponding to each terminal device 20 , and then can prioritize the terminal devices 20 with target durations greater than 0 according to the priority level.
[0081] S603: When j≤M, the coordinator sets the terminal device with the jth priority as the target terminal device.
[0082] Because the coordinator 10 has M wireless communication modules that can work normally, it can ensure that data of at least M terminal devices are transmitted in the ni-th time unit. Therefore, when j≤M, the coordinator 10 is used to set the j-th priority terminal device as the target terminal device.
[0083] S604, when the target duration corresponding to the j-th priority terminal device is ≤ the duration of the data transmission period in the ni-th time unit, the coordinator uses the starting point of the data transmission period in the ni-th time unit as the starting time of the data transmission time slice corresponding to the j-th priority terminal device, uses the target duration corresponding to the j-th priority terminal device as the duration of the data transmission time slice corresponding to the j-th priority terminal device, and uses the j-th wireless communication module in the coordinator as the target communication module corresponding to the j-th priority terminal device, so as to generate a target update task corresponding to the j-th priority terminal device.
[0084] Please refer to Figure 5 , Figure 5 A schematic diagram of the relationship between a data transmission time slice and a data transmission period provided in an embodiment of the present invention.
[0085] S605. When j≤M, when the target duration corresponding to the j-priority terminal device is greater than the duration of the data transmission period in the ni-th time unit, the coordinator uses the starting point of the data transmission period in the ni-th time unit as the starting time of the data transmission time slice corresponding to the j-priority terminal device, uses the duration of the data transmission period in the ni-th time unit as the duration of the data transmission time slice corresponding to the j-priority terminal device, and uses the j-th wireless communication module in the coordinator as the target communication module corresponding to the j-priority terminal device, so as to generate a target update task corresponding to the j-priority terminal device.
[0086] S606, when j is greater than M, the coordinator determines whether the duration of the idle transmission period of the mth wireless communication module is greater than 0. If the duration of the idle transmission period of the mth wireless communication module is equal to 0, execute S607; if the duration of the idle transmission period of the mth wireless communication module is greater than 0, execute S608.
[0087] The idle transmission period is the remaining period of the wireless communication module in the data transmission period of the ni-th time unit that is not occupied. The initial value of m is 1, and the initial value of j in this stage is M+1. Please continue to refer to Figure 5 .
[0088] S607, the coordinator sets m=m+1 and determines whether m≤M. If m≤M, S606 is repeated to determine whether the duration of the idle transmission period of the mth wireless communication module is greater than 0. If m>M, the process ends.
[0089] S608: The coordinator sets the terminal device with the jth priority as the target terminal device.
[0090] S609, when the target duration corresponding to the j-priority terminal device is ≤ the duration of the idle transmission period of the m-th wireless communication module, the coordinator uses the starting point of the idle transmission period of the m-th wireless communication module as the starting time of the data transmission time slice corresponding to the j-priority terminal device, uses the target duration corresponding to the j-priority terminal device as the duration of the data transmission time slice corresponding to the j-priority terminal device, and uses the m-th wireless communication module in the coordinator as the target communication module corresponding to the j-priority terminal device, so as to generate a target update task corresponding to the j-priority terminal device.
[0091] For example Figure 5 The target duration corresponding to the M+1th priority terminal device shown is less than or equal to the duration of the idle transmission period of the mth wireless communication module.
[0092] S610, when the target duration corresponding to the j-priority terminal device is greater than the duration of the idle transmission period of the m-th wireless communication module, the coordinator uses the starting point of the idle transmission period of the m-th wireless communication module as the starting time of the data transmission time slice corresponding to the j-priority terminal device, uses the duration of the idle transmission period of the m-th wireless communication module as the duration of the data transmission time slice corresponding to the j-priority terminal device, and uses the m-th wireless communication module in the coordinator as the target communication module corresponding to the j-priority terminal device, so as to generate a target update task corresponding to the j-priority terminal device.
[0093] For example Figure 5The target duration corresponding to the M+2th priority terminal device shown is less than or equal to the duration of the idle transmission period of the mth wireless communication module.
[0094] S611, after generating the target update task corresponding to the terminal device of the jth priority, the coordinator sets j=j+1 to determine whether j is greater than J. If so, the process ends; if not, the process repeats S606 to determine whether the duration of the idle transmission period of the mth wireless communication module is greater than 0.
[0095] Among them, J is the total number of terminal devices with target duration greater than 0.
[0096] Based on the above, the embodiment of the present invention also provides an optional implementation method, please refer to Figure 6 Before the indicator reporting period of the ni-th time unit, the remote update method of the Internet of Things device also includes: S10 and S20, as follows.
[0097] S10, the coordinator broadcasts a clock alignment instruction through the main communication module during the clock broadcast period of the ni-th time unit.
[0098] S20, the terminal device receives a clock alignment instruction through its internal wireless communication module during the clock broadcast period of the ni-th time unit, and completes clock alignment based on the clock alignment instruction.
[0099] By performing clock alignment, it is ensured that terminal devices in the system can communicate in an orderly manner, avoiding overlapping conflicts and data loss.
[0100] Please continue to refer to Figure 6 In an optional implementation, after completing the clock alignment based on the clock alignment instruction, the remote update method of the Internet of Things device also includes: S30, as follows.
[0101] S30, the terminal device determines its corresponding indicator reporting period according to its own number and a preset time offset.
[0102] The embodiment of the present invention provides a remote update method for an IoT device, which can be applied to but not limited to the coordinator in the IoT system described above. For the specific process, please refer to Figure 7 The remote update method of the IoT device includes: S50, S60 and S70, which are described in detail as follows.
[0103] S50, the coordinator determines the amount of data to be transmitted according to the current version number of the terminal device.
[0104] The current version number is the indicator data reported by the terminal device in the corresponding indicator reporting period in the ni-th time unit, and the ni-th time unit is the ith time unit in the n-th time interval;
[0105] S60, the coordinator generates an update task instruction according to the amount of data to be transmitted of each terminal device.
[0106] The update task instruction includes a target update task corresponding to the target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device.
[0107] S70, the coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the ni-th time unit.
[0108] After receiving the update task instruction, the target terminal device executes its corresponding target update task and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
[0109] Based on the above, the embodiment of the present invention further provides an Internet of Things system, such as Figure 1 The Internet of Things system includes a coordinator 10 and a plurality of terminal devices 20. The coordinator 10 is provided with M wireless communication modules, and the terminal devices 20 are provided with a wireless communication module.
[0110] The terminal device 20 is used to report the current version number of the terminal device 20 to the coordinator 10 by transmitting data to the main communication module during the corresponding indicator reporting period in the ni-th time unit, wherein the main communication module is any one of the M wireless communication modules in the coordinator 10, and the ni-th time unit is the i-th time unit of the n-th time interval.
[0111] The coordinator 10 is used to determine the amount of data to be transmitted according to the current version number of the terminal device 20 .
[0112] The coordinator 10 is used to generate an update task instruction based on the amount of data to be transmitted by each terminal device 20, wherein the update task instruction includes a target update task corresponding to the target terminal device, and the target update task includes information on the data transmission time slice corresponding to the target terminal device, an identifier of the target communication module, and an identifier of the target terminal device.
[0113] The coordinator 10 is used to broadcast the task update instruction through the main communication module during the task broadcast period of the ni-th time unit.
[0114] The target terminal device is used to execute its corresponding target update task after receiving the update task instruction, and complete the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
[0115] Optionally, the coordinator 10 is further configured to broadcast a clock alignment instruction through the main communication module during a clock broadcast period of the ni-th time unit.
[0116] The terminal device 20 is also used to receive the clock alignment instruction through its internal wireless communication module during the clock broadcast period of the ni-th time unit, and complete the clock alignment based on the clock alignment instruction.
[0117] It should be noted that the Internet of Things system provided in this embodiment can execute the method flow shown in the above method flow embodiment to achieve the corresponding technical effect. For the sake of brief description, for parts not mentioned in this embodiment, reference can be made to the corresponding contents in the above embodiment.
[0118] In summary, the embodiment of the present invention provides a remote update method and an Internet of Things system for Internet of Things devices. In the corresponding indicator reporting period of the terminal device in the ni time unit, the terminal device transmits data to the main communication module to report the current version number of the terminal device to the coordinator, and the coordinator determines the amount of data to be transmitted according to the current version number of the terminal device; the coordinator generates an update task instruction according to the amount of data to be transmitted of each terminal device; the coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the ni time unit; after receiving the update task instruction, the target terminal device executes its corresponding target update task, and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice. In the remote update method for Internet of Things devices provided by the embodiment of the present invention, when there are multiple target terminal devices, the multiple target terminal devices can perform data transmission in parallel with the multiple target communication modules, effectively improving the communication bandwidth of the Internet of Things system and improving the update efficiency of the Internet of Things devices. In addition, different target communication modules correspond to different frequency bands, which avoids the situation where multiple terminal devices compete for the same target communication module, reduces the risk of interference, and ensures the reliability of communication.
[0119] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
[0120] It will be apparent to those skilled in the art that the invention is not limited to the details of the exemplary embodiments described above and that the invention can be implemented in other specific forms without departing from the spirit or essential features of the invention. Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of the invention is defined by the appended claims rather than the foregoing description, and it is intended that all variations falling within the meaning and scope of the equivalent elements of the claims be included in the invention. Any reference numeral in a claim should not be considered as limiting the claim to which it relates.
Claims
1. A remote update method for an Internet of Things device, characterized in that: Applied to an Internet of Things system, the Internet of Things system includes a coordinator and multiple terminal devices, the coordinator is provided with M wireless communication modules, M is greater than 1, and the terminal device is provided with a wireless communication module, the method includes: The terminal device transmits data to the main communication module during the corresponding indicator reporting period in the ni-th time unit to report the current version number of the terminal device to the coordinator, wherein the main communication module is any one of the M wireless communication modules in the coordinator, and the ni-th time unit is the i-th time unit in the n-th time interval; The coordinator determines the amount of data to be transmitted according to the current version number of the terminal device; The coordinator generates an update task instruction according to the amount of data to be transmitted of each of the terminal devices, wherein the update task instruction includes a target update task corresponding to a target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device; The coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the nith time unit; After receiving the update task instruction, the target terminal device executes its corresponding target update task and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
2. The remote update method for an Internet of Things device according to claim 1, characterized in that: The step of the coordinator determining the amount of data to be transmitted according to the current version number of the terminal device comprises: The coordinator compares the current version number of the terminal device with the target version number to determine whether the two are consistent; If they are consistent, the coordinator determines that the amount of data to be transmitted of the terminal device is 0; If they are inconsistent, the coordinator determines whether the update data corresponding to the target version number has been sent to the terminal device according to the update record of the terminal device; If the update data corresponding to the target version number has not been sent to the terminal device, the coordinator uses all the update data corresponding to the target version number as the update data to be transmitted, and then determines the amount of data to be transmitted; If the update data corresponding to the target version number has been sent to the terminal device, the coordinator uses the remaining update data corresponding to the target version number as the update data to be transmitted, and further determines the amount of data to be transmitted.
3. The remote update method for an Internet of Things device according to claim 1, characterized in that: The coordinator generates a target update task in an update task instruction according to the amount of data to be transmitted of each of the terminal devices, including: The coordinator determines the target duration required by the terminal device according to the amount of data to be transmitted and the transmission speed of the terminal device; The coordinator prioritizes the terminal devices whose target duration is greater than 0; In the case of j≤M, the coordinator sets the terminal device with the jth priority as the target terminal device; When the target duration corresponding to the j-priority terminal device is ≤ the duration of the data transmission period in the ni-th time unit, the coordinator uses the starting point of the data transmission period in the ni-th time unit as the starting time of the data transmission time slice corresponding to the j-priority terminal device, uses the target duration corresponding to the j-priority terminal device as the duration of the data transmission time slice corresponding to the j-priority terminal device, and uses the j-th wireless communication module in the coordinator as the target communication module corresponding to the j-priority terminal device, so as to generate a target update task corresponding to the j-priority terminal device.
4. The method for remote updating of an Internet of Things device according to claim 3, characterized in that: The coordinator generates a target update task in an update task instruction according to the amount of data to be transmitted of each of the terminal devices, including: When j≤M, when the target duration corresponding to the j-priority terminal device is greater than the duration of the data transmission period in the ni-th time unit, the coordinator uses the starting point of the data transmission period in the ni-th time unit as the starting time of the data transmission time slice corresponding to the j-priority terminal device, uses the duration of the data transmission period in the ni-th time unit as the duration of the data transmission time slice corresponding to the j-priority terminal device, and uses the j-th wireless communication module in the coordinator as the target communication module corresponding to the j-priority terminal device, so as to generate a target update task corresponding to the j-priority terminal device.
5. The remote update method for an Internet of Things device as claimed in claim 3 or 4, characterized in that: The coordinator generates a target update task in an update task instruction according to the amount of data to be transmitted of each of the terminal devices, including: When j is greater than M, the coordinator determines whether the duration of the idle transmission period of the mth wireless communication module is greater than 0; wherein the idle transmission period is the remaining period of the wireless communication module in the data transmission period of the nith time unit that is not occupied, and the initial value of m is 1; If the duration of the idle transmission period of the mth wireless communication module is equal to 0, the coordinator sets m=m+1, determines whether m≤M, and if so, repeatedly determines whether the duration of the idle transmission period of the mth wireless communication module is greater than 0; If the duration of the idle transmission period of the mth wireless communication module is greater than 0, the coordinator sets the terminal device of the jth priority as the target terminal device; When the target duration corresponding to the j-th priority terminal device is ≤ the duration of the idle transmission period of the m-th wireless communication module, the coordinator uses the starting point of the idle transmission period of the m-th wireless communication module as the starting time of the data transmission time slice corresponding to the j-th priority terminal device, uses the target duration corresponding to the j-th priority terminal device as the duration of the data transmission time slice corresponding to the j-th priority terminal device, and uses the m-th wireless communication module in the coordinator as the target communication module corresponding to the j-th priority terminal device, so as to generate a target update task corresponding to the j-th priority terminal device; When the target duration corresponding to the terminal device of the jth priority is greater than the duration of the idle transmission period of the mth wireless communication module, the coordinator uses the starting point of the idle transmission period of the mth wireless communication module as the starting time of the data transmission time slice corresponding to the terminal device of the jth priority, uses the duration of the idle transmission period of the mth wireless communication module as the duration of the data transmission time slice corresponding to the terminal device of the jth priority, and uses the mth wireless communication module in the coordinator as the target communication module corresponding to the terminal device of the jth priority, so as to generate a target update task corresponding to the terminal device of the jth priority; After generating the target update task corresponding to the terminal device of the jth priority, the coordinator sets j=j+1 to determine whether j is greater than J, where J is the total number of terminal devices with a target duration greater than 0; If j≤J, the coordinator repeatedly determines whether the duration of the idle transmission period of the mth wireless communication module is greater than 0.
6. The method for remote updating of an Internet of Things device according to claim 1, wherein: Before the indicator reporting period of the ni-th time unit, the method further includes: The coordinator broadcasts a clock alignment instruction through the main communication module during the clock broadcast period of the ni-th time unit; The terminal device receives the clock alignment instruction through its internal wireless communication module during the clock broadcast period of the ni-th time unit, and completes the clock alignment based on the clock alignment instruction.
7. The remote update method for an Internet of Things device according to claim 6, characterized in that: After completing the clock alignment based on the clock alignment instruction, the method further includes: The terminal device determines its corresponding indicator reporting period according to its own number and a preset time offset.
8. A remote update method for an Internet of Things device, characterized in that: A coordinator applied to an Internet of Things system, the Internet of Things system comprising the coordinator and a plurality of terminal devices, the coordinator being provided with M wireless communication modules, M being greater than 1, the terminal device being provided with a wireless communication module, the method comprising: The coordinator determines the amount of data to be transmitted according to the current version number of the terminal device, wherein the current version number is the indicator data reported by the terminal device in the corresponding indicator reporting period in the ni-th time unit, and the ni-th time unit is the ith time unit in the n-th time interval; The coordinator generates an update task instruction according to the amount of data to be transmitted of each of the terminal devices, wherein the update task instruction includes a target update task corresponding to a target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device; The coordinator broadcasts the update task instruction through the main communication module during the task broadcast period of the nith time unit, so that the target terminal device executes its corresponding target update task after receiving the update task instruction, and completes the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
9. An Internet of Things system, characterized in that: The Internet of Things system includes a coordinator and a plurality of terminal devices, the coordinator is provided with M wireless communication modules, M is greater than 1, and the terminal devices are provided with wireless communication modules; The terminal device is used to report the current version number of the terminal device to the coordinator by transmitting data to the main communication module during the corresponding indicator reporting period in the ni-th time unit, wherein the main communication module is any one of the M wireless communication modules in the coordinator, and the ni-th time unit is the ith time unit of the n-th time interval; The coordinator is used to determine the amount of data to be transmitted according to the current version number of the terminal device; The coordinator is used to generate an update task instruction according to the amount of data to be transmitted of each of the terminal devices, wherein the update task instruction includes a target update task corresponding to a target terminal device, and the target update task includes information of a data transmission time slice corresponding to the target terminal device, an identifier of a target communication module, and an identifier of the target terminal device; The coordinator is used to broadcast the update task instruction through the main communication module during the task broadcast period of the ni-th time unit; The target terminal device is used to execute its corresponding target update task after receiving the update task instruction, and complete the version update by receiving the update data transmitted by the target communication module in its corresponding data transmission time slice.
10. The Internet of Things system according to claim 9, characterized in that: The coordinator is further configured to broadcast a clock alignment instruction through the main communication module during a clock broadcast period of the ni-th time unit; The terminal device is also used to receive the clock alignment instruction through its internal wireless communication module during the clock broadcast period of the ni-th time unit, and complete the clock alignment based on the clock alignment instruction.
Citation Information
Patent Citations
Data transmission method, device and system based on Internet
CN106130858A
Battery management system and update method therefor, and master node, slave node and storage medium
WO2023102733A1