Message transmission method and device
By obtaining message transmission path and congestion information in the mesh network, dynamically planning the message transmission path, solving the congestion problem caused by excessive data packet processing by the routing processor, and improving the transmission efficiency and reliability of the network.
Patent Information
- Application Number
- CN202410741601.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-07
- Publication Date
- 2025-03-18
- Estimated Expiration
- 2044-06-07
AI Technical Summary
In a multi-core connected wireless network structure mesh network, the routing processor needs to process a large number of data packets, resulting in congestion of routing channels, which slows down the processing rate and even causes abnormal system lag.
By obtaining node coordinates and congestion information in the message transmission path, determining the node to be selected, and dynamically planning the message transmission path based on the destination node coordinates and congestion information to avoid congestion caused by repeated use of the same path.
It effectively avoids data transmission interruption or data loss caused by message congestion, improves network transmission efficiency and reliability, and balances network load.
Smart Images

Figure CN118612786B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data transmission, and in particular to a message transmission method and device. Background Art
[0002] At present, in a mesh network with multi-core wireless network structure, each core can run and send data packets at the same time. At the same time, the routing processor needs to process a large number of data packets. Some messages will pass through some nodes together, which can easily lead to congestion in the routing channel, slowing down the processing rate and even causing abnormal freezing of the system. Summary of the invention
[0003] In view of the above problems, the embodiments of the present application provide a message transmission method and device that overcome the above problems or at least partially solve the above problems.
[0004] In a first aspect, an embodiment of the present invention provides a message transmission method, the method comprising:
[0005] When a first message is received, a message transmission path of a second message is obtained, and coordinates of a destination node of the first message and coordinates of a destination node of the second message are obtained, wherein the second message represents a previous message of the first message;
[0006] Determine nodes among all nodes except nodes in a message transmission path of the second message as nodes to be selected;
[0007] Obtain the message congestion information of each candidate node;
[0008] A message transmission path of the first message is determined according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and message congestion information of each to-be-selected node.
[0009] Optionally, the message congestion information includes: information on whether the message is congested and / or information on the message congestion level.
[0010] Optionally, the acquiring the coordinates of the destination node of the first message and the coordinates of the destination node of the second message includes:
[0011] Obtaining an identity of a destination node of the first message, and obtaining an identity of a destination node of the second message according to a message transmission path of the second message;
[0012] According to the correspondence between the identity identifier and the coordinates, obtaining the coordinates of the destination node of the first message corresponding to the identity identifier of the destination node of the first message;
[0013] According to the correspondence between the identity identifier and the coordinates, the coordinates of the destination node of the second message corresponding to the identity identifier of the destination node of the second message are obtained.
[0014] Optionally, determining the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and message congestion information of each to-be-selected node includes:
[0015] When the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message;
[0016] Determine, according to the message congestion information of each candidate node, a first message transmission path for transmitting the first message to the first intermediate node;
[0017] Determine, according to the message congestion information of each to-be-selected node, a second message transmission path for transmitting the first message from the first intermediate node to the destination node of the first message;
[0018] A message transmission path of the first message is determined according to the first message transmission path and the second message transmission path.
[0019] Optionally, when the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message includes:
[0020] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have the same abscissa and different ordinates, determining the coordinates of the first intermediate node of the first message according to the ordinate of the destination node of the first message;
[0021] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have different abscissas but the same ordinates, determining the coordinates of the first intermediate node of the first message according to the abscissa of the destination node of the first message;
[0022] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of horizontal and vertical coordinates, the coordinates of the first intermediate node of the first message are determined based on the coordinates of the destination node of the first message and the message transmission path of the second message.
[0023] Optionally, when the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message and the message transmission path of the second message includes:
[0024] In a case where the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, if the message transmission path of the second message is first transmitted along the horizontal coordinate direction and then transmitted along the vertical coordinate direction, the coordinates of the first intermediate node of the first message are determined according to the vertical coordinate of the destination node of the first message;
[0025] If the message transmission path of the second message is first transmitted along the ordinate direction and then transmitted along the abscissa direction, the coordinates of the first intermediate node of the first message are determined according to the abscissa of the destination node of the first message.
[0026] Optionally, the determining the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node further includes:
[0027] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are different in both the horizontal and vertical coordinates, the message transmission path of the first message is determined based on the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each candidate node.
[0028] In a second aspect, an embodiment of the present invention further provides a message transmission device, the device comprising:
[0029] A first acquisition module, configured to acquire, upon receiving a first message, a message transmission path of a second message, and acquire coordinates of a destination node of the first message and coordinates of a destination node of the second message, wherein the second message represents a previous message of the first message;
[0030] A first determining module, used to determine nodes other than nodes in a message transmission path of the second message among all nodes as candidate nodes;
[0031] The second acquisition module is used to obtain the message congestion information of each candidate node;
[0032] The second determination module is used to determine the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node.
[0033] In a third aspect, an embodiment of the present application provides an electronic device, which includes a processor and a memory, wherein the memory stores programs or instructions that can be run on the processor, and when the program or instructions are executed by the processor, the steps of the method described in the first aspect are implemented.
[0034] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.
[0035] In a fifth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.
[0036] In a sixth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect.
[0037] In the above embodiment of the present invention, when receiving the first message, the message transmission path of the second message is obtained, and the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are obtained, the second message represents the previous message of the first message, and the nodes other than the nodes in the message transmission path of the second message are determined as the nodes to be selected, so that the nodes involved in the message transmission path of the previous message of the first message can be eliminated, and the congestion caused by the repeated use of the same path by two adjacent messages can be avoided. Then, the message congestion information of each node to be selected is obtained, and the message transmission path of the first message is determined according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each node to be selected, that is, the path planning is performed through the message congestion information of the node to be selected, which can avoid the situation that data transmission interruption or data loss caused by message congestion. This dynamic avoidance strategy based on historical path records can not only effectively balance the network load, but also improve the transmission efficiency and reliability of the entire mesh network. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.
[0039] Figure 1A schematic diagram of node locations provided by an embodiment of the present invention;
[0040] Figure 2 A flowchart of a message transmission method provided by an embodiment of the present invention;
[0041] Figure 3 A structural block diagram of a message transmission device provided in an embodiment of the present invention
[0042] Figure 4 is a structural block diagram of an electronic device provided in an embodiment of the present application;
[0043] Figure 5 It is a structural block diagram of another electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0044] The following will be combined with the drawings in the embodiments of the present invention to clearly describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field belong to the scope of protection of this application.
[0045] The terms "first", "second", etc. in the specification and claims of the present invention are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention can be implemented in an order other than those illustrated or described herein, and the objects distinguished by "first", "second", etc. are generally of the same type, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0046] The message transmission method provided by the embodiment of the present invention is described in detail below through specific embodiments and application scenarios in conjunction with the accompanying drawings.
[0047] Specifically, the embodiment of the present invention provides a message transmission method, which can be applied to a routing processor, which is a core component in a network device, especially in a complex multi-core mesh network, responsible for path selection, packet forwarding, traffic management and security control, and ensures efficient and stable transmission of data in the network through efficient processing and dynamic adjustment. Under high load and multi-concurrency conditions, the performance and function of the routing processor directly affect the performance and reliability of the entire network.
[0048] Among them, mesh is a communication network in which any wireless device node can act as a router to send and receive signals, and can dynamically maintain connections and communications with other single or multiple nodes in any way. The coordinate position of each node is as follows: Figure 1 shown.
[0049] like Figure 2 As shown, the message transmission method may specifically include the following steps:
[0050] Step 201, upon receiving a first message, obtaining a message transmission path of a second message, and obtaining coordinates of a destination node of the first message and coordinates of a destination node of the second message, wherein the second message represents a previous message of the first message.
[0051] Specifically, firstly, the first message is received through the coherent hub interface (CHI) channel. If the first message is received, the coordinates of the destination node of the first message are obtained, and the message transmission path of the previous message of the first message (i.e., the second message) is obtained, and the coordinates of the destination node of the second message are obtained from the message transmission path of the second message. Among them, the message transmission path of the second message represents the nodes that the second message passes through in sequence when transmitting it to the destination node.
[0052] It is understandable that the first message refers to the current message, not the first message. Similarly, the second message refers to the previous message of the current message, not the second message.
[0053] It should be noted that the message transmission path of each message and the nodes passed in sequence in the message transmission path can be recorded by setting the register. The recorded data of the register is shown in Table 1 below:
[0054] Table 1 Message transmission path of each message
[0055] Message Message transmission path Message A1 Message transmission path B1 Message A2 Message transmission path B2 Message A3 Message transmission path B3
[0056] Among them, the message transmission path corresponding to the message A1 is B1, the message transmission path corresponding to the message A2 is B2, and the message transmission path corresponding to the message A3 is B3.
[0057] The message (including the first message and the second message) refers to a data packet transmitted from an interface to a destination, and the destination node is the destination to which the data packet is to go.
[0058] In computer networks and graph theory, a node is a basic unit or connection point in a network. It can be a computing device, a router, a switch, a server, or even a sensor. In different contexts, nodes can have different specific definitions and functions, but in general, nodes are entities that transmit and process data in the network. The roles and functions of nodes include but are not limited to:
[0059] Data processing: Nodes can process data, for example, computers can run applications, perform computing tasks, process user input and output, etc.
[0060] Data storage: Nodes can store data, such as database servers, file servers, etc.
[0061] Data transmission: Nodes can receive and send data packets to communicate over the network. For example, routers and switches forward data packets to connect different network devices.
[0062] Control function: Nodes can perform network control functions, such as managing network traffic, monitoring network status, and executing network security policies.
[0063] Step 202: determine nodes among all nodes except the nodes in the message transmission path of the second message as nodes to be selected.
[0064] Specifically, when the first message arrives, the nodes involved in the message transmission path of the second message recorded previously can be detected and analyzed, so as to avoid congestion caused by the repeated use of the same path by two adjacent messages. That is, if the message transmission path of the second message uses nodes, the first message should choose to bypass these nodes and use unoccupied nodes for transmission, thereby reducing the risk of path conflicts and congestion.
[0065] The nodes to be selected are multiple nodes to be selected, that is, multiple nodes among all nodes except the nodes involved in the message transmission path of the second message are all the nodes to be selected.
[0066] Step 203: Obtain message congestion information of each candidate node.
[0067] Specifically, by setting a real-time monitoring module on each node, each candidate node can collect its own node traffic and load data in real time through its own real-time monitor, and evaluate the message congestion information of each candidate node, thereby knowing the message congestion situation of each candidate node.
[0068] Step 204: determine a message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and message congestion information of each to-be-selected node.
[0069] Specifically, by planning the path of the first message based on the message congestion information of the candidate node, congestion caused by repeated use of the same path by two adjacent messages can be avoided, thereby avoiding data transmission interruption or data loss due to message congestion.
[0070] In the above embodiment of the present invention, when receiving the first message, the message transmission path of the second message is obtained, and the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are obtained, the second message represents the previous message of the first message, and the nodes other than the nodes in the message transmission path of the second message are determined as the nodes to be selected, so that the nodes involved in the message transmission path of the previous message of the first message can be eliminated, and the congestion caused by the repeated use of the same path by two adjacent messages can be avoided. Then, the message congestion information of each node to be selected is obtained, and the message transmission path of the first message is determined according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each node to be selected, that is, the path planning is performed through the message congestion information of the node to be selected, which can avoid the situation that data transmission interruption or data loss caused by message congestion. This dynamic avoidance strategy based on historical path records can not only effectively balance the network load, but also improve the transmission efficiency and reliability of the entire mesh network.
[0071] As an optional specific implementation, the step 201 of acquiring the coordinates of the destination node of the first message and the coordinates of the destination node of the second message includes:
[0072] Obtaining an identity of a destination node of the first message, and obtaining an identity of a destination node of the second message according to a message transmission path of the second message;
[0073] According to the correspondence between the identity identifier and the coordinates, obtaining the coordinates of the destination node of the first message corresponding to the identity identifier of the destination node of the first message;
[0074] According to the correspondence between the identity identifier and the coordinates, the coordinates of the destination node of the second message corresponding to the identity identifier of the destination node of the second message are obtained.
[0075] Specifically, first establish a correspondence between the identity document (ID) of each node and the coordinates of the node, which can be implemented specifically through the correspondence table sam. When the first message is received, the first message is parsed to obtain the identity of the destination node to which the first message is to be sent. Through the correspondence between the identity of each node and the coordinates of the node, the coordinates corresponding to the identity of the destination node of the first message can be obtained, and the coordinates are the coordinates of the destination node of the first message.
[0076] Similarly, after receiving the first message, the message transmission path of the previous message of the first message (i.e., the second message) is obtained, and the identity of the destination node of the second message can be obtained from the transmission path of the second message. Through the correspondence between the identity of each node and the coordinates of the node, the coordinates corresponding to the identity of the destination node of the second message can be obtained, and the coordinates are the coordinates of the destination node of the second message.
[0077] In the above embodiment, the coordinates of the destination node of the first message can be obtained through the correspondence between the identity identifier of each node and the coordinates of the node, which facilitates planning of the message transmission path of the first message.
[0078] As an optional specific embodiment, in step 203, the message congestion information includes but is not limited to: information on whether the message is congested and / or information on the message congestion level.
[0079] Specifically, the message congestion information includes: information on whether the message is congested. A congestion information monitoring module can be set for each node to monitor whether each node is congested, that is, to monitor the congestion status of each node, which can be specifically reflected by the busy bit (i.e., busy bit). As shown in Table 2 below, the number of nodes is n. When the busy bit is displayed, it means that the node is in a congested state. When the non-busy bit is displayed, it means that the node is in a non-congested state. If the node is a candidate node, the candidate node can be used as an alternative node for the first message. For example: Node A is in a busy position, indicating that Node A is in a congested state, and the coordinates of Node A are (x0, y0). Node B is in a non-busy position, indicating that Node B is in a non-congested state, and the coordinates of Node B are (x1, y0). Node W is in a busy position, indicating that Node W is in a congested state, and the coordinates of Node W are (xn, yn).
[0080] Table 2 Congestion status of each node
[0081] Node A Busy Position (x0, y0) Node B Non-busy bit (x1, y0) … … … Node W Busy Position (xn, yn)
[0082] When multiple messages pass through a node during transmission, if the congestion level of the node reaches a preset threshold, the monitoring module of the node will trigger a mechanism: the busy signal of the node and its coordinates are fed back to the routing processor, and the routing processor updates the busy bit of the corresponding node in the sam table as a sign of congestion. This flag will be taken into account when the next message is transmitted in order to avoid passing through the node. The implementation of this mechanism has several important benefits:
[0083] First, the stability and continuity of the routing processor can be ensured. By promptly identifying and avoiding congested nodes, the routing processor can continue to process packets without interruption or data loss due to congestion.
[0084] Secondly, this mechanism helps to improve the processing efficiency of the routing processor, avoids passing through congested nodes, reduces the waiting time of messages, shortens transmission delays, and thus improves the overall processing speed.
[0085] In addition, this mechanism can also prevent the route processor from serious problems such as freezing or crashing due to congestion. Through timely congestion feedback and processing, the route processor can effectively cope with high load conditions and maintain stable operation.
[0086] In general, by implementing such a congestion feedback mechanism, the routing processor can improve processing efficiency and reduce failure risks while ensuring stability and continuity, thereby ensuring the reliability and performance of the routing processor.
[0087] Specifically, the message congestion information includes: message congestion level information. The congestion level information of each node can be set, and the congestion situation of each node can be monitored in real time. The congestion level is set to three levels: (H), medium (M), and low (L), as shown in Table 2 below, and the level table is dynamically updated in real time. Each time a new incoming message transmission path is planned, points with high congestion levels can be bypassed first to achieve the purpose of reducing congestion.
[0088] Table 3 Congestion level of each node
[0089] Node A High congestion level (x0, y0) Node B Congestion level (x1, y0) … … … Node W Low congestion level (xn,yn)
[0090] Among them, the number of nodes is n, the congestion level of node A is high, indicating that the congestion level of node A is very high, and the coordinates of node A are (x0, y0). The congestion level of node B is medium, indicating that the congestion level of node B is medium, and the coordinates of node B are (x1, y0). The congestion level of node W is low, indicating that the congestion level of node W is low, and the coordinates of node W are (xn, yn).
[0091] The specific steps for path planning using the congestion level table are as follows:
[0092] A congestion information monitoring module is deployed on each node to collect the traffic and load data of each node. The congestion information monitoring module of each node dynamically evaluates the congestion level of the node based on its own data and reports it to the routing processor. For example: if the traffic of a node is continuously higher than the set threshold, its congestion level is raised to high (H); conversely, if the traffic of a node is continuously lower than the set threshold, its congestion level is lowered to low (L).
[0093] When a new message requires path planning, the routing processor first queries the current congestion level of each node. In order to reduce congestion, nodes with high congestion levels (H) will be bypassed first, and nodes with low (L) congestion levels will be given the highest priority for message transmission, and nodes with medium (M) congestion levels will be given the second highest priority for message transmission. During the message transmission process, the routing processor will continuously feedback and adjust the congestion level of each node according to the actual transmission situation to ensure that the routing strategy always matches the current network load status. This dynamic adjustment mechanism can effectively avoid network bottlenecks and improve the transmission efficiency and stability of the entire network.
[0094] In a specific example: suppose there is a node A, and the current traffic is higher than the set threshold. The congestion information monitoring module of the node marks its congestion level as high (H). When a new message arrives, the routing processor queries the congestion level of each node. Since the congestion level of node A is high (H), when planning the transmission path, node A will be bypassed and other nodes with low (L) congestion levels will be selected for message transmission; if there are no nodes with low (L) congestion levels, nodes with medium (M) congestion levels will be selected for message transmission. This method can effectively reduce congestion in the network and improve overall transmission efficiency.
[0095] As an optional specific embodiment, the step 204 determines the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node, including:
[0096] When the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message;
[0097] Determine, according to the message congestion information of each candidate node, a first message transmission path for transmitting the first message to the first intermediate node;
[0098] Determine, according to the message congestion information of each to-be-selected node, a second message transmission path for transmitting the first message from the first intermediate node to the destination node of the first message;
[0099] A message transmission path of the first message is determined according to the first message transmission path and the second message transmission path.
[0100] Specifically, after obtaining the coordinates of the destination node of the first message and the coordinates of the destination node of the second message, determine whether the horizontal coordinates of the coordinates of the two destination nodes are the same and whether the vertical coordinates are the same. If at least one of the horizontal coordinates and the vertical coordinates of the coordinates of the two destination nodes is the same, it is necessary to determine the coordinates of the first intermediate node that must be passed in the message transmission path of the first message based on the coordinates of the destination node of the first message. After determining the coordinates of the first intermediate node, it is equivalent to dividing the message transmission path of the first message into two parts, the first part is from the starting point to the first intermediate node, and the second part is from the first intermediate node to the destination node.
[0101] Obtain the message congestion information of each node to be selected, and plan the transmission path from the starting point to the first intermediate node according to the message congestion information to obtain the first message transmission path, and the first message can be transmitted to the first intermediate node according to the first message transmission path. Then, according to the message congestion information of each node to be selected, plan the transmission path from the first intermediate node to the destination node to obtain the second message transmission path, and the first message can be transmitted from the first intermediate node to the destination node according to the second message transmission path. The first message transmission path and the second message transmission path are combined to obtain the complete message transmission path of the first message.
[0102] It should be noted that the first segment in the first segment message transmission path is not the transmission path between the first node and the second node in the message transmission path expressing the first message, but the transmission path between the starting point and the first intermediate node, and the transmission path may include two nodes, the starting point and the first intermediate node, and may also include multiple nodes between the starting point and the first intermediate node. Similarly, the second segment in the second segment message transmission path is not the transmission path between the second node and the third node in the message transmission path expressing the first message, but the transmission path between the first intermediate node and the destination node, and the transmission path may include two nodes, the first intermediate node and the destination node, and may also include multiple nodes between the first intermediate node and the destination node.
[0103] Further, in step 204, when the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of the horizontal coordinate and / or the vertical coordinate, the step of determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message specifically includes:
[0104] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have the same abscissa and different ordinates, determining the coordinates of the first intermediate node of the first message according to the ordinate of the destination node of the first message;
[0105] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have different abscissas but the same ordinates, determining the coordinates of the first intermediate node of the first message according to the abscissa of the destination node of the first message;
[0106] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of horizontal and vertical coordinates, the coordinates of the first intermediate node of the first message are determined based on the coordinates of the destination node of the first message and the message transmission path of the second message.
[0107] Specifically, after obtaining the coordinates of the destination node of the first message and the coordinates of the destination node of the second message, it is determined whether the horizontal coordinates of the coordinates of the two destination nodes are the same and whether the vertical coordinates are the same. If the horizontal coordinates of the coordinates of the two destination nodes are the same and the vertical coordinates are different, in order to avoid congestion of the first message and the second message on the horizontal axis, it is necessary to first transmit the first message along the vertical axis and then turn to the destination node, which can effectively disperse the traffic and avoid congestion on the same horizontal line. For example: the coordinates of the destination node of the first message are (3, 4), and the coordinates of the destination node of the second message are (3, 5). Since the horizontal coordinates of the coordinates of the two destination nodes are the same and the vertical coordinates are different, the first message can be first transmitted along the node in the vertical axis direction, and then turned to the node with the coordinates of (3, 4) for transmission, and the coordinates of the first intermediate node of the first message can be determined as (0, 4), that is, according to the message congestion information of the selected node, the first message transmission path between (0, 0) and the node (0, 4) is planned, and there may be no other nodes between (0, 0) and (0, 4), or there may be one or more nodes. After reaching the node (0, 4), the second message transmission path between (0, 4) and the node (3, 4) is planned according to the message congestion information of other candidate nodes.
[0108] If the coordinates of the two destination nodes have different horizontal coordinates and the same vertical coordinates, in order to avoid congestion between the first message and the second message on the vertical axis, the first message needs to be transmitted along the horizontal axis first, and then turned to the destination node, which can effectively disperse the traffic and avoid congestion in the same vertical direction. For example: the coordinates of the destination node of the first message are (3, 4), and the coordinates of the destination node of the second message are (2, 4). Since the coordinates of the two destination nodes have the same vertical coordinates and different horizontal coordinates, the first message can be first transmitted along the node in the horizontal axis direction, and then turned to the node with coordinates (3, 4) for transmission. The coordinates of the first intermediate node of the first message can be determined as (3, 0), that is, according to the message congestion information of the selected node, the first message transmission path between (0, 0) and node (3, 0) is planned. There may be no other nodes between (0, 0) and (3, 0), or there may be one or more nodes. After reaching the node (3, 0), the second message transmission path between (3, 0) and the node (3, 4) is planned according to the message congestion information of other candidate nodes.
[0109] If the coordinates of two destination nodes have the same horizontal and vertical coordinates, in order to avoid the first message and the second message having the same message transmission path, when planning the message transmission path according to the coordinates of the destination node of the first message, avoid the nodes in the message transmission path of the second message to avoid congestion on the same path.
[0110] Further, in step 204, when the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, the step of determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message and the message transmission path of the second message specifically includes:
[0111] In a case where the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, if the message transmission path of the second message is first transmitted along the horizontal coordinate direction and then transmitted along the vertical coordinate direction, the coordinates of the first intermediate node of the first message are determined according to the vertical coordinate of the destination node of the first message;
[0112] If the message transmission path of the second message is first transmitted along the ordinate direction and then transmitted along the abscissa direction, the coordinates of the first intermediate node of the first message are determined according to the abscissa of the destination node of the first message.
[0113] Specifically, if the coordinates of the two destination nodes have the same horizontal coordinate and the same vertical coordinate, in order to avoid the first message and the second message having the same message transmission path, the message transmission path of the second message is obtained. If the message transmission path of the second message is first transmitted along the horizontal coordinate direction and then along the vertical coordinate direction, the message transmission path of the first message is set to first transmit along the vertical coordinate direction and then along the horizontal coordinate direction, that is, the coordinates of the first intermediate node are determined according to the vertical coordinate of the destination node of the first message, so as to avoid congestion caused by the same message transmission paths of the first message and the second message.
[0114] For example: the coordinates of the destination node of the first message are (3, 4), and the coordinates of the destination node of the second message are (3, 4), and the coordinates of the two destination nodes have the same ordinate and the same abscissa. If the message transmission path of the second message is first transmitted to (3, 0) and then to (3, 4), it means that the message transmission path of the second message is first transmitted along the abscissa direction and then along the ordinate direction. At this time, the message transmission path of the first message needs to be set to first transmit along the ordinate direction and then along the abscissa direction, that is, the coordinates of the first intermediate node of the first message are determined to be (0, 4), that is, the message transmission path of the first message is first transmitted to (0, 4) and then to (3, 4), thereby avoiding the situation where the message transmission paths of the first message and the second message are the same and cause congestion.
[0115] If the coordinates of the two destination nodes have the same horizontal coordinate and the same vertical coordinate, in order to avoid the first message and the second message having the same message transmission path, the message transmission path of the second message is obtained. If the message transmission path of the second message is first transmitted along the vertical coordinate direction and then along the horizontal coordinate direction, the message transmission path of the first message is set to first transmit along the horizontal coordinate direction and then along the vertical coordinate direction, that is, the coordinates of the first intermediate node are determined according to the horizontal coordinate of the destination node of the first message, so as to avoid congestion caused by the same message transmission paths of the first message and the second message.
[0116] For example: the coordinates of the destination node of the first message are (3, 4), and the coordinates of the destination node of the second message are (3, 4), and the coordinates of the two destination nodes have the same ordinate and the same abscissa. If the message transmission path of the second message is first transmitted to (0, 4) and then to (3, 4), it means that the message transmission path of the second message is first transmitted along the ordinate direction and then along the abscissa direction. At this time, the message transmission path of the first message needs to be set to first transmit along the abscissa direction and then along the ordinate direction, that is, the coordinates of the first intermediate node of the first message are determined to be (3, 0), that is, the message transmission path of the first message is first transmitted to (3, 0) and then to (3, 4), thereby avoiding the situation where the message transmission paths of the first message and the second message are the same and cause congestion.
[0117] The above-mentioned embodiment can dynamically adjust the transmission path of the message to avoid congestion caused by repeated use of the same path. This dynamic avoidance strategy based on historical path records can not only effectively balance the network load and reduce bottlenecks, but also improve the transmission efficiency and reliability of the entire mesh network.
[0118] As an optional specific implementation, the step 204 determines the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node, and further includes:
[0119] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are different in both the horizontal and vertical coordinates, the message transmission path of the first message is determined based on the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each candidate node.
[0120] Specifically, after obtaining the coordinates of the destination node of the first message and the coordinates of the destination node of the second message, it is determined whether the horizontal coordinates of the coordinates of the two destination nodes are the same and whether the vertical coordinates are the same. If the horizontal coordinates and vertical coordinates of the coordinates of the two destination nodes are not the same, it is necessary to plan the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each node to be selected, so as to avoid the message transmission path of the first message from intersecting with the message transmission path of the second message, that is, if the message transmission path of the second message uses nodes, the first message should choose to bypass these nodes and use unoccupied nodes for transmission, thereby reducing the risk of path conflict and congestion.
[0121] In addition, it should be noted that, in order to avoid changes in node coordinates, the correspondence between the node identity and coordinates can be set to be updated regularly to ensure the accuracy of the data and the stable operation of the routing processor.
[0122] In summary, the above embodiments of the present invention can obtain the coordinates of the destination node of the first message through the correspondence between the identity identifier of each node and the coordinates of the node, so as to facilitate the planning of the message transmission path of the first message. In addition, the acquisition of real-time message congestion information is crucial to preventing network congestion. By planning message transmission based on message congestion information, bandwidth resources can be effectively allocated during peak network traffic periods to ensure priority transmission of key data packets, thereby alleviating network load. In addition, by dynamically adjusting the message transmission path based on the comparison of the horizontal and vertical coordinates of the coordinates of the two destination nodes, congestion caused by repeated use of the same path can be avoided. This dynamic avoidance strategy based on historical path records can not only effectively balance network loads and reduce bottlenecks, but also improve the transmission efficiency and reliability of the entire mesh network.
[0123] The message transmission method provided by the embodiment of the present invention is introduced above. The message transmission device provided by the embodiment of the present invention will be introduced below with reference to the accompanying drawings.
[0124] like Figure 3 As shown, the embodiment of the present invention further provides a message transmission device 300, the device comprising:
[0125] A first acquisition module 301 is used to acquire a message transmission path of a second message when a first message is received, and acquire the coordinates of a destination node of the first message and the coordinates of a destination node of the second message, wherein the second message represents a previous message of the first message;
[0126] A first determining module 302 is used to determine nodes other than nodes in a message transmission path of the second message among all nodes as candidate nodes;
[0127] The second acquisition module 303 is used to obtain the message congestion information of each node to be selected;
[0128] The second determination module 304 is used to determine the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each candidate node.
[0129] In the above embodiment of the present invention, when receiving the first message, the message transmission path of the second message is obtained, and the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are obtained, the second message represents the previous message of the first message, and the nodes other than the nodes in the message transmission path of the second message are determined as the nodes to be selected, so that the nodes involved in the message transmission path of the previous message of the first message can be eliminated, and the congestion caused by the repeated use of the same path by two adjacent messages can be avoided. Then, the message congestion information of each node to be selected is obtained, and the message transmission path of the first message is determined according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each node to be selected, that is, the path planning is performed through the message congestion information of the node to be selected, which can avoid the situation that data transmission interruption or data loss caused by message congestion. This dynamic avoidance strategy based on historical path records can not only effectively balance the network load, but also improve the transmission efficiency and reliability of the entire mesh network.
[0130] Optionally, the message congestion information includes: information on whether the message is congested and / or information on the message congestion level.
[0131] Optionally, when acquiring the coordinates of the destination node of the first message and the coordinates of the destination node of the second message, the first acquisition module 301 is specifically used to:
[0132] Obtaining an identity of a destination node of the first message, and obtaining an identity of a destination node of the second message according to a message transmission path of the second message;
[0133] According to the correspondence between the identity identifier and the coordinates, obtaining the coordinates of the destination node of the first message corresponding to the identity identifier of the destination node of the first message;
[0134] According to the correspondence between the identity identifier and the coordinates, the coordinates of the destination node of the second message corresponding to the identity identifier of the destination node of the second message are obtained.
[0135] Optionally, the second determining module 304 is specifically configured to:
[0136] When the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message;
[0137] Determine, according to the message congestion information of each candidate node, a first message transmission path for transmitting the first message to the first intermediate node;
[0138] Determine, according to the message congestion information of each to-be-selected node, a second message transmission path for transmitting the first message from the first intermediate node to the destination node of the first message;
[0139] A message transmission path of the first message is determined according to the first message transmission path and the second message transmission path.
[0140] Optionally, when the coordinates of the destination node of the first message are the same as the abscissa and / or the ordinate in the coordinates of the destination node of the second message, the second determination module 304 determines the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message, specifically for:
[0141] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have the same abscissa and different ordinates, determining the coordinates of the first intermediate node of the first message according to the ordinate of the destination node of the first message;
[0142] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have different abscissas but the same ordinates, determining the coordinates of the first intermediate node of the first message according to the abscissa of the destination node of the first message;
[0143] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of horizontal and vertical coordinates, the coordinates of the first intermediate node of the first message are determined based on the coordinates of the destination node of the first message and the message transmission path of the second message.
[0144] Optionally, when the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, the second determination module 304 determines the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message and the message transmission path of the second message, specifically for:
[0145] In a case where the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, if the message transmission path of the second message is first transmitted along the horizontal coordinate direction and then transmitted along the vertical coordinate direction, the coordinates of the first intermediate node of the first message are determined according to the vertical coordinate of the destination node of the first message;
[0146] If the message transmission path of the second message is first transmitted along the ordinate direction and then transmitted along the abscissa direction, the coordinates of the first intermediate node of the first message are determined according to the abscissa of the destination node of the first message.
[0147] Optionally, the second determining module 304 is further configured to:
[0148] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are different in both the horizontal and vertical coordinates, the message transmission path of the first message is determined based on the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each candidate node.
[0149] In summary, the above embodiments of the present invention can obtain the coordinates of the destination node of the first message through the correspondence between the identity identifier of each node and the coordinates of the node, so as to facilitate the planning of the message transmission path of the first message. In addition, the acquisition of real-time message congestion information is crucial to preventing network congestion. By planning message transmission based on message congestion information, bandwidth resources can be effectively allocated during peak network traffic periods to ensure priority transmission of key data packets, thereby alleviating network load. In addition, by dynamically adjusting the message transmission path based on the comparison of the horizontal and vertical coordinates of the coordinates of the two destination nodes, congestion caused by repeated use of the same path can be avoided. This dynamic avoidance strategy based on historical path records can not only effectively balance network loads and reduce bottlenecks, but also improve the transmission efficiency and reliability of the entire mesh network.
[0150] The message transmission device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or it can be other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., which is not specifically limited in the embodiment of the present application.
[0151] The message transmission device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
[0152] The message transmission device provided in the embodiment of the present application can achieve Figure 1 to Figure 2 To avoid repetition, the various processes implemented by the method embodiment are not described here.
[0153] Alternatively, if Figure 4 As shown, an embodiment of the present application also provides an electronic device 400, including a processor 401 and a memory 402, wherein the memory 402 stores a program or instruction that can be executed on the processor 401, and when the program or instruction is executed by the processor 401, the various steps of the above-mentioned message transmission method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0154] It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and non-mobile electronic devices mentioned above.
[0155] Figure 5 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.
[0156] The electronic device 1000 includes but is not limited to: a radio frequency unit 1001, a network module 1002, an audio output unit 1003, an input unit 1004, a sensor 1005, a display unit 1006, a user input unit 1007, an interface unit 1008, a memory 1009, and a processor 1010 and other components.
[0157] Those skilled in the art will appreciate that the electronic device 1000 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 1010 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Figure 5 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0158] The processor 1010 is configured to, upon receiving a first message, obtain a message transmission path of a second message, and obtain coordinates of a destination node of the first message and coordinates of a destination node of the second message, wherein the second message represents a previous message of the first message;
[0159] Determine nodes among all nodes except nodes in a message transmission path of the second message as nodes to be selected;
[0160] Obtain the message congestion information of each candidate node;
[0161] A message transmission path of the first message is determined according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and message congestion information of each to-be-selected node.
[0162] In the above embodiment of the present invention, when receiving the first message, the message transmission path of the second message is obtained, and the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are obtained, the second message represents the previous message of the first message, and the nodes other than the nodes in the message transmission path of the second message are determined as the nodes to be selected, so that the nodes involved in the message transmission path of the previous message of the first message can be eliminated, and the congestion caused by the repeated use of the same path by two adjacent messages can be avoided. Then, the message congestion information of each node to be selected is obtained, and the message transmission path of the first message is determined according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each node to be selected, that is, the path planning is performed through the message congestion information of the node to be selected, which can avoid the situation that data transmission interruption or data loss caused by message congestion. This dynamic avoidance strategy based on historical path records can not only effectively balance the network load, but also improve the transmission efficiency and reliability of the entire mesh network.
[0163] Optionally, the message congestion information includes: information on whether the message is congested and / or information on the message congestion level.
[0164] Optionally, when acquiring the coordinates of the destination node of the first message and the coordinates of the destination node of the second message, the processor 1010 is specifically configured to:
[0165] Obtaining an identity of a destination node of the first message, and obtaining an identity of a destination node of the second message according to a message transmission path of the second message;
[0166] According to the correspondence between the identity identifier and the coordinates, obtaining the coordinates of the destination node of the first message corresponding to the identity identifier of the destination node of the first message;
[0167] According to the correspondence between the identity identifier and the coordinates, the coordinates of the destination node of the second message corresponding to the identity identifier of the destination node of the second message are obtained.
[0168] Optionally, when the processor 1010 determines the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node, it is specifically configured to:
[0169] When the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message;
[0170] Determine, according to the message congestion information of each candidate node, a first message transmission path for transmitting the first message to the first intermediate node;
[0171] Determine, according to the message congestion information of each to-be-selected node, a second message transmission path for transmitting the first message from the first intermediate node to the destination node of the first message;
[0172] A message transmission path of the first message is determined according to the first message transmission path and the second message transmission path.
[0173] Optionally, when the coordinates of the destination node of the first message are the same as the abscissa and / or the ordinate in the coordinates of the destination node of the second message, the processor 1010 determines the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message, specifically configured to:
[0174] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have the same abscissa and different ordinates, determining the coordinates of the first intermediate node of the first message according to the ordinate of the destination node of the first message;
[0175] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have different abscissas but the same ordinates, determining the coordinates of the first intermediate node of the first message according to the abscissa of the destination node of the first message;
[0176] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of horizontal and vertical coordinates, the coordinates of the first intermediate node of the first message are determined based on the coordinates of the destination node of the first message and the message transmission path of the second message.
[0177] Optionally, when the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, the processor 1010 determines the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message and the message transmission path of the second message, specifically configured to:
[0178] In a case where the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, if the message transmission path of the second message is first transmitted along the horizontal coordinate direction and then transmitted along the vertical coordinate direction, the coordinates of the first intermediate node of the first message are determined according to the vertical coordinate of the destination node of the first message;
[0179] If the message transmission path of the second message is first transmitted along the ordinate direction and then transmitted along the abscissa direction, the coordinates of the first intermediate node of the first message are determined according to the abscissa of the destination node of the first message.
[0180] Optionally, when the processor 1010 determines the message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node, it is further specifically configured to:
[0181] When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are different in both the horizontal and vertical coordinates, the message transmission path of the first message is determined based on the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each candidate node.
[0182] In summary, the above embodiments of the present invention can obtain the coordinates of the destination node of the first message through the correspondence between the identity identifier of each node and the coordinates of the node, so as to facilitate the planning of the message transmission path of the first message. In addition, the acquisition of real-time message congestion information is crucial to preventing network congestion. By planning message transmission based on message congestion information, bandwidth resources can be effectively allocated during peak network traffic periods to ensure priority transmission of key data packets, thereby alleviating network load. In addition, by dynamically adjusting the message transmission path based on the comparison of the horizontal and vertical coordinates of the coordinates of the two destination nodes, congestion caused by repeated use of the same path can be avoided. This dynamic avoidance strategy based on historical path records can not only effectively balance network loads and reduce bottlenecks, but also improve the transmission efficiency and reliability of the entire mesh network.
[0183] It should be understood that in the embodiment of the present application, the input unit 1004 may include a graphics processor (Graphics Processing Unit, GPU) 10041 and a microphone 10042, and the graphics processor 10041 processes the image data of the static picture or video obtained by the image capture device (such as a camera) in the video capture mode or the image capture mode. The display unit 1006 may include a display panel 10061, and the display panel 10061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 1007 includes a touch panel 10071 and at least one of other input devices 10072. The touch panel 10071 is also called a touch screen. The touch panel 10071 may include two parts: a touch detection device and a touch controller. Other input devices 10072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0184] The memory 1009 can be used to store software programs and various data. The memory 1009 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 1009 may include a volatile memory or a non-volatile memory, or the memory 1009 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 1009 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0185] The processor 1010 may include one or more processing units; optionally, the processor 1010 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 1010.
[0186] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the various processes of the above-mentioned message transmission method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0187] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0188] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned message transmission method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0189] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0190] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned message transmission method embodiment and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0191] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0192] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0193] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A message transmission method, characterized in that: The method comprises: When a first message is received, a message transmission path of a second message is obtained, and coordinates of a destination node of the first message and coordinates of a destination node of the second message are obtained, wherein the second message represents a previous message of the first message, and the message transmission path of the second message represents nodes sequentially passed through when transmitting the second message to the destination node; Determine nodes among all nodes except nodes in a message transmission path of the second message as nodes to be selected; Obtain the message congestion information of each candidate node; Determine a message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and message congestion information of each to-be-selected node; The determining, according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node, a message transmission path of the first message includes: When the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message; Determine, according to the message congestion information of each candidate node, a first message transmission path for transmitting the first message to the first intermediate node; Determine, according to the message congestion information of each to-be-selected node, a second message transmission path for transmitting the first message from the first intermediate node to the destination node of the first message; A message transmission path of the first message is determined according to the first message transmission path and the second message transmission path.
2. The method according to claim 1, characterized in that The message congestion information includes: information on whether the message is congested and / or information on the message congestion level.
3. The method according to claim 1, characterized in that The acquiring the coordinates of the destination node of the first message and the coordinates of the destination node of the second message includes: Obtaining an identity of a destination node of the first message, and obtaining an identity of a destination node of the second message according to a message transmission path of the second message; According to the correspondence between the identity identifier and the coordinates, obtaining the coordinates of the destination node of the first message corresponding to the identity identifier of the destination node of the first message; According to the correspondence between the identity identifier and the coordinates, the coordinates of the destination node of the second message corresponding to the identity identifier of the destination node of the second message are obtained.
4. The method according to claim 1, characterized in that: The determining, according to the coordinates of the destination node of the first message, the coordinates of the first intermediate node of the first message when the coordinates of the destination node of the first message are the same as the abscissa and / or the ordinate in the coordinates of the destination node of the second message, comprises: When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have the same abscissa and different ordinates, determining the coordinates of the first intermediate node of the first message according to the ordinate of the destination node of the first message; When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message have different abscissas but the same ordinates, determining the coordinates of the first intermediate node of the first message according to the abscissa of the destination node of the first message; When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of horizontal and vertical coordinates, the coordinates of the first intermediate node of the first message are determined based on the coordinates of the destination node of the first message and the message transmission path of the second message.
5. The method according to claim 4, characterized in that The determining, when the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, of the first intermediate node of the first message according to the coordinates of the destination node of the first message and the message transmission path of the second message, includes: In a case where the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are the same in terms of the horizontal coordinate and the vertical coordinate, if the message transmission path of the second message is first transmitted along the horizontal coordinate direction and then transmitted along the vertical coordinate direction, the coordinates of the first intermediate node of the first message are determined according to the vertical coordinate of the destination node of the first message; If the message transmission path of the second message is first transmitted along the ordinate direction and then transmitted along the abscissa direction, the coordinates of the first intermediate node of the first message are determined according to the abscissa of the destination node of the first message.
6. The method according to claim 1, characterized in that The determining, according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each to-be-selected node, of a message transmission path of the first message further includes: When the coordinates of the destination node of the first message and the coordinates of the destination node of the second message are different in both the horizontal and vertical coordinates, the message transmission path of the first message is determined based on the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and the message congestion information of each candidate node.
7. A message transmission device, characterized in that: The device comprises: A first acquisition module, configured to acquire, upon receiving a first message, a message transmission path of a second message, and acquire coordinates of a destination node of the first message and coordinates of a destination node of the second message, wherein the second message represents a previous message of the first message, wherein the message transmission path of the second message represents nodes sequentially passed through when transmitting the second message to the destination node; A first determining module, used to determine nodes other than nodes in a message transmission path of the second message among all nodes as candidate nodes; The second acquisition module is used to obtain the message congestion information of each candidate node; A second determination module, configured to determine a message transmission path of the first message according to the coordinates of the destination node of the first message, the coordinates of the destination node of the second message, and message congestion information of each to-be-selected node; The second determining module is specifically used to: When the coordinates of the destination node of the first message are the same as the coordinates of the destination node of the second message in terms of abscissa and / or ordinate, determining the coordinates of the first intermediate node of the first message according to the coordinates of the destination node of the first message; Determine, according to the message congestion information of each candidate node, a first message transmission path for transmitting the first message to the first intermediate node; Determine, according to the message congestion information of each to-be-selected node, a second message transmission path for transmitting the first message from the first intermediate node to the destination node of the first message; A message transmission path of the first message is determined according to the first message transmission path and the second message transmission path.
8. An electronic device, characterized in that: It includes a processor and a memory, the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the message transmission method according to any one of claims 1 to 6 are implemented.
9. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by the processor, the steps of the message transmission method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Message forwarding method and device, network equipment and computer storage medium
CN118101024A