Communication interaction method, device and medium for Internet of Things terminal
By using device tags and delay information to select the optimal path in the communication interaction of IoT terminals, the loop problem in IoT terminal communication is solved, and efficient data transmission and resource management are achieved.
Patent Information
- Application Number
- CN202411314895.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-20
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2044-09-20
AI Technical Summary
Communication and interaction of IoT terminals face challenges such as device diversity, network heterogeneity, data transmission security, energy consumption limitation, real-time and scalability. The existing technology is difficult to effectively avoid loop paths, resulting in excessive resource consumption and data. Insufficient transmission efficiency.
By generating a data request message including its own device tag, setting device tags using intermediate nodes, selecting the optimal sending path based on delay and node tag length, and setting sending rules to generate a loopless path, minimizing resource consumption and improving data transmission efficiency.
The selection of loopless paths is realized, which minimizes resource consumption, improves data transmission efficiency, avoids loop paths, and improves network performance.
Smart Images

Figure CN118842745B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of Internet of Things, and in particular relates to a communication interaction method, device and medium for an Internet of Things terminal. Background Art
[0002] As an emerging technology paradigm, the Internet of Things (IoT) connects sensors, devices, machines and digital networks to achieve intelligent identification, positioning, tracking, monitoring and management of objects. With the rapid development of IoT technology, hundreds of millions of devices are connected to the Internet, forming a huge network ecosystem. However, the communication interaction of IoT terminals faces many challenges, including device diversity, network heterogeneity, data transmission security, energy consumption constraints, real-time and scalability.
[0003] Existing methods for improving the communication efficiency of IoT terminals, such as a Chinese patent application with publication number CN118337504A, propose a data processing method and system for an IoT terminal group, the method includes obtaining real-time data and information of a trusted IoT terminal group, the information of the trusted IoT terminal group includes an identification code and a priority of the IoT terminal group; comparing the total amount of real-time data with a preset threshold, if the total amount of real-time data is less than or equal to the preset threshold, processing all the real-time data, if the total amount of real-time data is greater than the preset threshold, processing the real-time data in sequence according to the priority of the IoT terminal group; standardizing and encrypting the real-time data to obtain corrected real-time data; processing the corrected real-time data.
[0004] The above existing technologies detect the source of real-time data, eliminate the real-time data that does not need to be processed, and then standardize and encrypt the real-time data to ensure the security of real-time data transmission and faster subsequent processing. However, there is a lack of appropriate loop avoidance mechanism in the selection of transmission paths, which may cause routing loops.
[0005] Another example is the Chinese patent application with publication number CN114051217A, which proposes a secure routing method and system for an integrated energy Internet of Things sensor network, wherein the method includes: determining the source node and terminal node of data information transmission in the integrated energy Internet of Things sensor network; obtaining a routing code for representing the data information transmission path according to the number of nodes, source nodes and terminal nodes of the integrated energy Internet of Things sensor network; calculating the quantitative service quality value of the routing code, and extracting the routing code with the best quantitative service quality value as the target secure route; updating the routing code based on weight iteration, and returning to the previous step until the set iteration stop condition is reached; according to the target secure route, transmitting the data information from the source node to the terminal node. Although this prior art can obtain a better routing solution in fewer iterations, there may still be a loop path.
[0006] Therefore, a communication interaction method for IoT terminals is needed, which can combine the node status in the network to perform routing selection and generate a loop-free path, minimize resource consumption, and improve data transmission efficiency. Summary of the invention
[0007] To solve the above problems, the present invention provides a communication interaction method, device and medium for an Internet of Things terminal to solve the problems in the prior art.
[0008] In order to achieve the above-mentioned object of the invention, the present invention proposes a communication interaction method for an Internet of Things terminal, comprising:
[0009] Step S1: locating a first terminal and a second terminal, wherein the first terminal and the second terminal are respectively the starting point and the end point of data communication;
[0010] Step S2: the first terminal generates a data request message including its own device tag, and sends the data request message to the second terminal through multiple intermediate nodes, setting the device tag for each intermediate node. After receiving the data request message, the second terminal generates a data response message including its own device tag;
[0011] Step S3: the second terminal obtains all its own first neighbor nodes, assigns a number to each of the first neighbor nodes based on the number of the first neighbor nodes, the second terminal sends the data response message to each of the first neighbor nodes respectively, and the data response message includes the number corresponding to the first neighbor node, the first neighbor node extracts the number from the data response message, combines the device tag of the second terminal and its own number into a node tag of the first neighbor node, and defines the device tag of the second terminal as a source tag, and associates the source tag with the corresponding node tag and stores them in the first neighbor node;
[0012] Step S4: each of the first neighbor nodes obtains its own second neighbor nodes, assigns each of the second neighbor nodes a number based on the number of the second neighbor nodes, the first neighbor node adds its own node label to the data response message, and sends it to the second neighbor node, uses the device label of the first neighbor node as the source label of the second neighbor node, generates its own node label based on the data response message, associates the source label with the corresponding node label and stores it in the second neighbor node, repeats this operation until the data response message is sent to the first terminal, and the first terminal generates a label table based on all the node labels and the corresponding source labels in the received data response message;
[0013] Step S5: Setting a sending rule, and generating an optimal sending path from the first terminal to the second terminal based on the sending rule and the node label.
[0014] Furthermore, setting the sending rules includes the following steps:
[0015] The sending rule includes a first rule and a second rule, the first rule is a longest path rule, and the second rule is a shortest path rule.
[0016] Further, generating the optimal sending path based on the first rule and the node label includes the following steps:
[0017] Acquire all third neighbor nodes of the first terminal, and if there is only one third neighbor node, the first terminal uses the third neighbor node as a first path node;
[0018] If there are multiple third neighbor nodes, the delay of each third neighbor node is obtained, and the third neighbor node whose delay is less than the first threshold is defined as a candidate node. The first terminal obtains the length value of each node label in the label table. If there is only one node label whose length value is greater than the second threshold, the corresponding node label is defined as the first optimal label, and the third neighbor node that generates the first optimal label is obtained and defined as the first path node.
[0019] If there are multiple node labels whose lengths are greater than the first threshold, starting from the first label of each node label from left to right, the label values of the node labels at the same position are compared in sequence. When the label value of one of the node labels is greater than that of the other node labels, the node label with the largest label value is defined as the first optimal label. The third neighbor node that generates the first optimal label is obtained and defined as the first path node.
[0020] Taking the first path node as a new starting node, obtaining all fourth neighbor nodes of the new starting node, the first path node stores the label table of the fourth neighbor nodes, selecting the second optimal label from the label table, obtaining the fourth neighbor node that generates the second optimal label, defining it as a second path node, repeating this operation until reaching the second terminal, connecting all path nodes to generate the optimal sending path, and the path nodes include the first path node and the second path node.
[0021] Further, generating the optimal sending path based on the second rule and the node label includes the following steps:
[0022] The node label whose length value is less than the third threshold is selected and defined as the third optimal label, the fifth neighbor node corresponding to the third optimal label is obtained and defined as the third path node, and all the third path nodes are connected to generate the optimal sending path.
[0023] The selection of the second path node further comprises the following steps:
[0024] If the length value of the second optimal label selected from the label table of the fourth neighbor node is greater than or equal to the first optimal label of the first path node, the second optimal label is removed, and a new node label is selected from the label table again until the length value of the node label is less than the first optimal label, and the node label is defined as the new second optimal label, and the sixth neighbor node that generates the second optimal label is obtained and defined as the second path node.
[0025] The present invention also provides a device, which is used to implement the above method, comprising: a processor, a memory and a communication bus, wherein the processor and the memory communicate with each other through the communication bus;
[0026] The memory is used to store computer programs;
[0027] The processor is used to execute the program stored in the memory to implement the method described above.
[0028] The present invention also provides a computer medium, wherein the computer medium stores program instructions, wherein when the program instructions are executed, the device where the computer medium is located is controlled to execute the above method.
[0029] Compared with the prior art, the beneficial effects of the present invention are at least as follows:
[0030] The present invention generates a data request message including its own device tag from a first terminal, and sends the data request message to a second terminal through multiple intermediate nodes. The second terminal receives the data request message and generates a data response message including its own device tag. In the process of sending the data response message, a node label for each node is generated, and the optimal path node is selected according to the delay of each node and the length of the node label. The optimal sending path is generated based on the optimal path node, avoiding loop paths, minimizing resource consumption, and improving data transmission efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 A flow chart of the steps of the communication interaction method for an Internet of Things terminal of the present invention;
[0032] Figure 2 It is a node relationship diagram of the present invention;
[0033] Figure 3 Schematic diagram of node label of the present invention. DETAILED DESCRIPTION
[0034] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0035] It is understood that the terms "first", "second", etc. used in this application may be used herein to describe various elements, but unless otherwise specified, these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first xx script may be referred to as a second xx script, and similarly, a second xx script may be referred to as a first xx script.
[0036] like Figure 1 As shown, a communication interaction method for an Internet of Things terminal includes:
[0037] S1: Locate a first terminal and a second terminal, where the first terminal and the second terminal are the starting point and the end point of data communication, respectively.
[0038] Specifically, the first terminal is a device responsible for initiating data transmission, such as a sensor or a smart device, and the second terminal is a device that receives data from the first terminal and processes or responds to it, such as a data center, a control center or other terminal device. The present invention assumes that the first terminal is a temperature and humidity sensor for detecting the indoor environment and collecting data, and the second terminal is a home automation control system that receives data from the temperature and humidity sensor and adjusts the air conditioning or heating based on the data to maintain indoor comfort.
[0039] S2: The first terminal generates a data request message including its own device tag, sends the data request message to the second terminal through multiple intermediate nodes, sets a device tag for each intermediate node, and after receiving the data request message, the second terminal generates a data response message including its own device tag.
[0040] Specifically, device tags are set for the first terminal, the second terminal, and the intermediate node to identify and distinguish different IoT devices, such as Figure 2As shown, it is a node relationship diagram from the first terminal to the second terminal, wherein the device label 1 represents the first terminal, the device label 7 represents the second terminal, and the others represent intermediate nodes. The intermediate nodes can be routers, gateways or other IoT devices. The data request message generated by the first terminal contains information such as request type, data content, timestamp and its own device label, etc. After the second terminal receives the data request message, it generates a data response message according to the request content, including response data, timestamp and its own device label, etc.
[0041] S3: The second terminal obtains all its own first neighbor nodes, assigns a number to each first neighbor node based on the number of first neighbor nodes, and the second terminal sends a data response message to each first neighbor node respectively, and the data response message includes the number of the corresponding first neighbor node. The first neighbor node extracts the number from the data response message, combines the device tag of the second terminal and its own number into a node tag of the first neighbor node, and defines the device tag of the second terminal as a source tag, and associates the source tag with the corresponding node tag and stores it in the first neighbor node.
[0042] Specifically, Figure 3 As shown, it is a schematic diagram of node labels. The second terminal obtains all its first neighbor nodes, including two nodes: 6 and 5. A corresponding number is set for the first neighbor node with label 6, assuming it is 1, and a corresponding number is set for the first neighbor node with label 5, assuming it is 2. The device label 7 of the second terminal and the number 1 of the first neighbor node 6 are combined to form the node label of the first neighbor node 6: 71, wherein the device label 7 of the second terminal is also the source label of the node label 71, and the associated storage generates: 7-71, and the node label of the first neighbor node 5 is: 72, and the associated storage generates: 7-72.
[0043] S4: Each first neighbor node obtains its own second neighbor node, assigns a number to each second neighbor node based on the number of second neighbor nodes, the first neighbor node adds its own node label to the data response message, and sends it to the second neighbor node, uses the device label of the first neighbor node as the source label of the second neighbor node, generates its own node label based on the data response message, associates the source label with the corresponding node label and stores it in the second neighbor node, repeats this operation until the data response message is sent to the first terminal, and the first terminal generates a label table based on all node labels and corresponding source labels in the received data response message.
[0044] Specifically, Figure 3As shown, the first neighbor node 6 obtains its own second neighbor node 4 and assigns the second neighbor node 4 a number of 1. The first neighbor node 5 obtains its own second neighbor nodes 4 and 3 and assigns them numbers 1 and 2 respectively. The second neighbor node 4 records the device number 6 of the first neighbor node 6 and the device number 5 of the first neighbor node 5. The first node label of the second neighbor node 4 is generated according to the node label 71 of the first neighbor node 6: 711, where 6 is the source label of the node label 711, and the associated storage generates: 6-711. The second node label of the second neighbor node 4 is generated according to the node label 72 of the first neighbor node 5: 721, where 5 is the source label of the node label 721, and the associated storage generates: 5-721. The node label of the second neighbor node 3 is: 722, and the source label is 5. The associated storage obtains 5-722. According to this method, the node label of each node is generated and stored with the corresponding source label until it is sent to the first terminal to generate the node label of the first terminal.
[0045] S5: Setting a sending rule, and generating an optimal sending path from the first terminal to the second terminal based on the sending rule and the node label.
[0046] Specifically, in the Internet of Things network, the energy resources, bandwidth, memory and processing power of each node are limited. In the process of data transmission, a loop may be generated due to failure to select a suitable node. The present invention can generate a loop-free path, that is, the optimal transmission path in the present invention, by setting transmission rules, thereby minimizing resource consumption and improving data transmission efficiency.
[0047] As a preferred technical solution of the present invention, setting the sending rules includes the following steps:
[0048] The sending rule includes a first rule and a second rule, the first rule is a longest path rule, and the second rule is a shortest path rule.
[0049] Specifically, the present invention sets two sending rules. The first rule is to select the longest path under the premise of maintaining a loop-free path. The longest path refers to the path with the most label information. Selecting the longest loop-free path can adjust the route according to the real-time network conditions in dynamic routing selection, thereby providing more forwarding options and a higher degree of freedom. At the same time, in the case of network congestion, it helps to disperse traffic and avoid congestion points, thereby improving the overall performance of the network.
[0050] The second rule is to select the shortest path while maintaining a loop-free path, which can reduce the probability of errors or loss of data packets during transmission, while reducing energy consumption during transmission and improving transmission efficiency.
[0051] Generating an optimal sending path based on the first rule and the node label includes the following steps:
[0052] All third neighbor nodes of the first terminal are obtained. If there is only one third neighbor node, the first terminal uses the third neighbor node as the first path node.
[0053] If there are multiple third neighbor nodes, obtain the delay of each third neighbor node, and define the third neighbor node with a delay less than the first threshold as a candidate node. The first terminal obtains the length value of each node label in the label table. If there is only one node label with a length value greater than the second threshold, the corresponding node label is defined as the first optimal label. The third neighbor node that generates the first optimal label is obtained and defined as the first path node.
[0054] If there are multiple node labels with lengths greater than the first threshold, starting from the first label of each node label from left to right, the label values of the node labels at the same position are compared in sequence. When the label value of one of the node labels is greater than that of the other node labels, the node label with the largest label value is defined as the first optimal label, and the third neighbor node that generates the first optimal label is obtained and defined as the first path node.
[0055] Take the first path node as the new starting node, obtain all fourth neighbor nodes of the new starting node, the first path node stores a label table of the fourth neighbor nodes, select the second optimal label from it, obtain the fourth neighbor node that generates the second optimal label, and define it as the second path node. Repeat this operation until reaching the second terminal, connect all path nodes to generate the optimal sending path, and the path nodes include the first path node and the second path node.
[0056] Specifically, all third neighbor nodes 1 and 2 of the first terminal 0 (replaced by device tags) are obtained, and the delays of the two third neighbor nodes are calculated. The delay is the time delay caused by the third neighbor node receiving the message from the first terminal. Assuming that the delay of the third neighbor node 1 is 1, the delay of the third neighbor node 2 is 3, and the first threshold is 2, the third neighbor node 1 is used as a candidate node. If there is only one candidate node, the third neighbor node 1 is used as the candidate node and directly as the first path node.
[0057] Take the first path node 1 as the new starting node, and obtain its own fourth neighbor node: 2 and 4. Assuming that the delays of 2 and 4 are both less than the first threshold, because the node label length of 2 is greater than the node label length of 4, 2 and 4 are selected as candidate nodes. The second threshold is reduced in sequence according to the actual situation. Here, the second threshold is set to 4, and the node labels with a length value greater than 4 come from the fourth neighbor node 2, including: 71121, 72121, 72211. Starting from the first label of each node label, which is 7, from left to right, compare the label values of the same position of the node label in sequence. By comparison, it can be seen that 72211 is the second optimal label and the second path node is 2.
[0058] According to this method, the optimal label of the fourth neighbor node 2 is 7212, and the path node is 4. The optimal label of the fifth neighbor node 4 is 721, and the path node is 5. The optimal label of neighbor node 5 is 72, and the path node is 7. Then, all the path nodes are connected to generate the longest optimal sending path: 0-1-2-4-5-7.
[0059] Generating the optimal sending path based on the second rule and the node label includes the following steps:
[0060] A node label whose length value is less than a third threshold is selected and defined as a third optimal label, a fifth neighbor node corresponding to the third optimal label is obtained and defined as a third path node, and all third path nodes are connected to generate an optimal sending path.
[0061] Specifically, the second rule is different from the first rule in that a node with a smaller label length is selected as the first optimal label. For example, starting from the first terminal 0, because the delay of 1 is less than 2 and less than the first threshold, 1 is still selected as the first optimal label, and 1 is used as the new starting node to obtain its own neighbor nodes 2 and 4, because the delays of 2 and 4 are both greater than the first threshold, and the node label length value of 4 is less than 2 and less than the third threshold. The third threshold is assumed to be 5, so 4 is selected as an alternative node, and 7211 is used as the first optimal label, then 4 is used as the third path node. According to this method, the shortest optimal sending path is obtained: 0-1-4-5-7.
[0062] The selection of the second path node also includes the following steps:
[0063] If the length value of the second optimal label selected from the label table of the fourth neighbor node is greater than or equal to the first optimal label of the first path node, the second optimal label is removed, and a new node label is selected from the label table again until the length value of the node label is less than the first optimal label. The node label is defined as the new second optimal label, and the sixth neighbor node that generates the second optimal label is obtained and defined as the second path node.
[0064] Specifically, after selecting the second optimal label of the fourth neighbor node, it is necessary to compare the length value of the second optimal label with the length value of the first optimal label of the first path node. If the length value of the second optimal label is greater than or equal to the length value of the first optimal label of the first path node, the second optimal label needs to be eliminated and a new selection needs to be made. This is because it is necessary to ensure that the length of the node label is gradually reduced and is closer to the destination during the reduction process to ensure that there is no loop path.
[0065] The present invention also provides a device for implementing the above method, comprising: a processor, a memory and a communication bus, wherein the processor and the memory communicate with each other via the communication bus;
[0066] Memory for storing computer programs;
[0067] The processor is used to execute the program stored in the memory to implement the above method.
[0068] The present invention also provides a computer medium, which stores program instructions, wherein when the program instructions are executed, the device where the computer medium is located is controlled to execute the above method.
[0069] It should be understood that, although each step in the flow chart of each embodiment of the present invention is shown in sequence according to the indication of the arrow, these steps are not necessarily performed in sequence according to the order indicated by the arrow. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be performed in other orders. Moreover, at least a portion of the steps in each embodiment may include a plurality of sub-steps or a plurality of stages, and these sub-steps or stages are not necessarily performed at the same time, but can be performed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but can be performed in turn or alternately with at least a portion of other steps or sub-steps or stages of other steps.
[0070] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the above-mentioned program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0071] The technical features of the above-mentioned embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above-mentioned embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0072] The above embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent of the present invention. It should be pointed out that, for those of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
[0073] The above are only preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A communication interaction method for an Internet of Things terminal, It is characterized in that The method comprises the following steps: S1: locating a first terminal and a second terminal, where the first terminal and the second terminal are respectively a starting point and an end point of data communication; S2: The first terminal generates a data request message including its own device tag, and sends the data request message to the second terminal through multiple intermediate nodes, setting a device tag for each intermediate node. After receiving the data request message, the second terminal generates a data response message including its own device tag; S3: The second terminal obtains all its own first neighbor nodes, assigns a number to each first neighbor node based on the number of the first neighbor nodes, the second terminal sends the data response message to each first neighbor node respectively, and the data response message includes the number of the corresponding first neighbor node, the first neighbor node extracts the number from the data response message, combines the device tag of the second terminal and its own number into a node tag of the first neighbor node, and defines the device tag of the second terminal as the source tag of the first neighbor node, and associates the source tag of the first neighbor node with the node tag of the corresponding first neighbor node and stores them in the first neighbor node; S4: Each first neighbor node obtains its own second neighbor node, assigns a number to each second neighbor node based on the number of second neighbor nodes, the first neighbor node adds its own node label to the data response message, and sends it to the second neighbor node, the second neighbor node uses the device label of the first neighbor node as the source label of the second neighbor node, generates its own node label based on the data response message, associates the source label of the second neighbor node with the corresponding node label of the second neighbor node and stores it in the second neighbor node, repeats this operation until the data response message is sent to the first terminal, and the first terminal generates a label table based on all node labels and corresponding source labels in the received data response message; S5: Setting a sending rule, and generating an optimal sending path from the first terminal to the second terminal based on the sending rule and the node label.
2. The method according to claim 1, It is characterized in that Setting up a sending rule involves the following steps: The sending rule includes a first rule or a second rule, the first rule is a longest path rule, and the second rule is a shortest path rule.
3. The method according to claim 2, It is characterized in that Generating an optimal sending path based on the first rule and the node label comprises the following steps: Acquire all third neighbor nodes of the first terminal, and if there is only one third neighbor node, the first terminal uses the third neighbor node as a first path node; If there are multiple third neighbor nodes, the delay of each third neighbor node is obtained, and the third neighbor node whose delay is less than the first threshold is defined as a candidate node. The first terminal obtains the length value of each node label in the label table. If there is only one node label whose length value is greater than the second threshold, the corresponding node label is defined as the first optimal label, and the third neighbor node that generates the first optimal label is obtained and defined as the first path node. If there are multiple node labels with lengths greater than the second threshold, starting from the first label of each node label from left to right, the label values of the node labels at the same position are compared in sequence. When the label value of one of the node labels is greater than that of the other node labels, the node label with the largest label value is defined as the first optimal label, and the third neighbor node that generates the first optimal label is obtained and defined as the first path node; Taking the first path node as a new starting node, all fourth neighbor nodes of the new starting node are obtained, a label table of the fourth neighbor nodes is stored in the first path node, a second optimal label is selected from the label table, and the fourth neighbor node that generates the second optimal label is obtained and defined as the second path node. This operation is repeated until the second terminal is reached, and all path nodes are connected to generate an optimal sending path, and the path nodes include the first path node and the second path node.
4. The method according to claim 3, It is characterized in that Generating an optimal sending path based on the second rule and the node label comprises the following steps: A node label whose length value is less than a third threshold is selected and defined as a third optimal label, a fifth neighbor node corresponding to the third optimal label is obtained and defined as a third path node, and all the third path nodes are connected to generate the optimal sending path.
5. The method according to claim 3, It is characterized in that The selection of the second path node also includes the following steps: If the length value of the second optimal label selected from the label table of the fourth neighbor node is greater than or equal to the length value of the first optimal label of the first path node, the second optimal label is removed, and a new node label is selected from the label table again until the length value of the new node label is less than the length value of the first optimal label. The new node label is defined as a new second optimal label, and the sixth neighbor node that generates the new second optimal label is obtained and defined as a new second path node.
6. A communication interaction device for an Internet of Things terminal, used to implement the method according to any one of claims 1 to 5, It is characterized in that include: A processor, a memory and a communication bus, wherein the processor and the memory communicate with each other via the communication bus; The memory is used to store computer programs; The processor is used to execute the program stored in the memory to implement the method described in any one of claims 1-5.
7. A computer medium, It is characterized in that The computer medium stores program instructions, wherein when the program instructions are executed, the device where the computer medium is located is controlled to execute the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Secure routing method and system for integrated energy Internet of Things sensor network
CN114051217A
Data processing method and system of Internet of Things terminal group
CN118337504A
Data sending method and device, electronic equipment and storage medium
CN117014994A
Internet of Things intelligent dolly comprehensive practical training device
CN209804040U
