[go: up one dir, main page]

CN104125108A - Fault diagnosis device and method thereof and setting method of back-off time - Google Patents

Fault diagnosis device and method thereof and setting method of back-off time Download PDF

Info

Publication number
CN104125108A
CN104125108A CN201310149266.8A CN201310149266A CN104125108A CN 104125108 A CN104125108 A CN 104125108A CN 201310149266 A CN201310149266 A CN 201310149266A CN 104125108 A CN104125108 A CN 104125108A
Authority
CN
China
Prior art keywords
node
time
neighbor
diagnosis
nodes
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201310149266.8A
Other languages
Chinese (zh)
Inventor
张兆宇
底欣
温允
藤田裕志
尾崎一幸
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to CN201310149266.8A priority Critical patent/CN104125108A/en
Priority to JP2014088201A priority patent/JP2014217063A/en
Publication of CN104125108A publication Critical patent/CN104125108A/en
Pending legal-status Critical Current

Links

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

本发明实施例提供一种故障诊断装置和方法、以及退避时间的设置方法,所述故障诊断装置包括:时间启动单元,在怀疑节点需要诊断时,启动诊断节点针对所述怀疑节点的退避时间;根节点确定单元,根据对所述退避时间的倒计时来确定根节点;所述根节点为所述怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;诊断控制单元,控制所述根节点启动建立诊断树,并接收所述诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。通过本发明实施例,可以在网关处获得统一的诊断结果,同时降低系统的通信开销。

Embodiments of the present invention provide a fault diagnosis device and method, and a method for setting back-off time. The fault diagnosis device includes: a time start unit, which starts the back-off time of the diagnostic node for the suspected node when the suspected node needs to be diagnosed; The root node determination unit determines the root node according to the countdown of the back-off time; the root node is the diagnosis node whose back-off time ends first among the plurality of diagnosis nodes of the suspected node; the diagnosis control unit controls the root node The node starts to establish the diagnosis tree, receives the diagnosis information sent by the nodes in the diagnosis tree, and reports the diagnosis result to the gateway. Through the embodiment of the present invention, a unified diagnosis result can be obtained at the gateway, while reducing the communication overhead of the system.

Description

故障诊断装置和方法、以及退避时间的设置方法Fault diagnosis device and method, and setting method of backoff time

技术领域technical field

本发明涉及网络故障诊断技术领域,特别涉及一种故障诊断装置和方法、以及退避时间的设置方法。The invention relates to the technical field of network fault diagnosis, in particular to a fault diagnosis device and method, and a backoff time setting method.

背景技术Background technique

网络在发生故障时,需要启动网络故障诊断过程来排除故障,例如可以包括链路故障诊断和节点故障诊断。目前,当一怀疑节点需要诊断时,该怀疑节点的多个诊断节点可能均启动诊断过程,各自建立诊断树并上报诊断结果。When a fault occurs in the network, it is necessary to start a network fault diagnosis process to eliminate the fault, which may include, for example, link fault diagnosis and node fault diagnosis. At present, when a suspected node needs to be diagnosed, multiple diagnostic nodes of the suspected node may all start the diagnosis process, respectively build a diagnosis tree and report the diagnosis result.

但是,在实现本发明的过程中,发明人发现现有技术的缺陷在于:在怀疑节点需要诊断的情况下,由于无法保证只有一个诊断节点上报诊断结果,因而在网关(GW,Gateway)处无法获得统一的诊断结果,同时多个诊断过程被启动、以及多个诊断节点上报诊断信息也会给系统带来过大的通信开销。However, in the process of implementing the present invention, the inventor found that the defect of the prior art is: in the case of a suspected node that needs to be diagnosed, it cannot be ensured that only one diagnostic node reports the diagnosis result, so the gateway (GW, Gateway) cannot To obtain a unified diagnosis result, multiple diagnostic processes are started at the same time, and multiple diagnostic nodes report diagnostic information will also bring excessive communication overhead to the system.

发明内容Contents of the invention

本发明实施例提供一种故障诊断装置和方法、以及退避时间的设置方法,目的在于在网关处获得统一的诊断结果,同时降低系统的通信开销。Embodiments of the present invention provide a fault diagnosis device and method, and a backoff time setting method, aiming at obtaining a unified diagnosis result at a gateway while reducing communication overhead of the system.

根据本发明实施例的一个方面,提供一种故障诊断装置,所述故障诊断装置包括:According to an aspect of an embodiment of the present invention, a fault diagnosis device is provided, and the fault diagnosis device includes:

时间启动单元,在怀疑节点需要诊断时,启动诊断节点针对所述怀疑节点的退避时间;其中,通过将所述怀疑节点的多个邻居节点分为不同的组来设置所述退避时间;A time starting unit, when the suspected node needs to be diagnosed, starts the backoff time of the diagnostic node for the suspected node; wherein, the backoff time is set by dividing a plurality of neighbor nodes of the suspected node into different groups;

根节点确定单元,根据对所述退避时间的倒计时来确定根节点;所述根节点为所述怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;The root node determination unit determines the root node according to the countdown of the back-off time; the root node is the diagnostic node whose back-off time ends first among the multiple diagnostic nodes of the suspected node;

诊断控制单元,控制所述根节点启动建立诊断树,并接收所述诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。The diagnosis control unit controls the root node to start establishing the diagnosis tree, receives the diagnosis information sent by the nodes in the diagnosis tree, and reports the diagnosis result to the gateway.

根据本发明实施例的另一个方面,提供一种故障诊断方法,所述故障诊断方法包括:According to another aspect of the embodiments of the present invention, a fault diagnosis method is provided, and the fault diagnosis method includes:

在怀疑节点需要诊断时,启动诊断节点针对所述怀疑节点的退避时间;其中,通过将所述怀疑节点的多个邻居节点分为不同的组来设置所述退避时间;When the suspected node needs to be diagnosed, start the back-off time of the diagnostic node for the suspected node; wherein, the back-off time is set by dividing a plurality of neighbor nodes of the suspected node into different groups;

根据对所述退避时间的倒计时来确定根节点;所述根节点为所述怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;Determine the root node according to the countdown to the backoff time; the root node is the diagnostic node whose backoff time ends first among the plurality of diagnostic nodes of the suspect node;

控制所述根节点启动建立诊断树,并接收所述诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。Controlling the root node to start establishing a diagnosis tree, receiving diagnosis information sent by nodes in the diagnosis tree, and reporting a diagnosis result to the gateway.

根据本发明实施例的另一个方面,提供一种退避时间的设置方法,所述设置方法包括:According to another aspect of the embodiments of the present invention, a backoff time setting method is provided, the setting method comprising:

将节点的多个邻居节点分为不同的组;Divide multiple neighbor nodes of a node into different groups;

对于不同组的邻居节点,设置不同的退避时间。For different groups of neighbor nodes, set different backoff time.

本发明实施例的有益效果在于:在怀疑节点需要诊断时,启动诊断节点针对怀疑节点的退避时间,根据对退避时间的倒计时来确定根节点,并由该根节点启动建立诊断树,接收诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。由此,可以在网关处获得统一的诊断结果,同时降低系统的通信开销。The beneficial effects of the embodiments of the present invention are: when a suspected node needs to be diagnosed, start the diagnostic node for the back-off time of the suspected node, determine the root node according to the countdown of the back-off time, and start the establishment of the diagnostic tree by the root node, receive the diagnostic tree The diagnostic information sent by the nodes in the network, and report the diagnostic results to the gateway. In this way, a unified diagnosis result can be obtained at the gateway, while reducing the communication overhead of the system.

参照后文的说明和附图,详细公开了本发明的特定实施方式,指明了本发明的原理可以被采用的方式。应该理解,本发明的实施方式在范围上并不因而受到限制。在所附权利要求的精神和条款的范围内,本发明的实施方式包括许多改变、修改和等同。With reference to the following description and accompanying drawings, there are disclosed in detail specific embodiments of the invention, indicating the manner in which the principles of the invention may be employed. It should be understood that embodiments of the invention are not limited thereby in scope. Embodiments of the invention encompass many changes, modifications and equivalents within the spirit and scope of the appended claims.

针对一种实施方式描述和/或示出的特征可以以相同或类似的方式在一个或更多个其它实施方式中使用,与其它实施方式中的特征相组合,或替代其它实施方式中的特征。Features described and/or illustrated with respect to one embodiment can be used in the same or similar manner in one or more other embodiments, in combination with, or instead of features in other embodiments .

应该强调,术语“包括/包含”在本文使用时指特征、整件、步骤或组件的存在,但并不排除一个或更多个其它特征、整件、步骤或组件的存在或附加。It should be emphasized that the term "comprising/comprising" when used herein refers to the presence of a feature, integer, step or component, but does not exclude the presence or addition of one or more other features, integers, steps or components.

附图说明Description of drawings

图1是本发明实施例1的故障诊断装置的一构成示意图;FIG. 1 is a schematic diagram of the composition of a fault diagnosis device according to Embodiment 1 of the present invention;

图2是本发明实施例1的故障诊断装置的另一构成示意图;Fig. 2 is another schematic diagram of the structure of the fault diagnosis device according to Embodiment 1 of the present invention;

图3是本发明实施例1的对一节点的邻居节点进行分组之后的示意图;FIG. 3 is a schematic diagram after grouping neighbor nodes of a node according to Embodiment 1 of the present invention;

图4是本发明实施例1的t1、t2、t3、t4与BO1、BO2的关系示意图;Fig. 4 is a schematic diagram of the relationship between t 1 , t 2 , t 3 , t 4 and BO 1 and BO 2 in Example 1 of the present invention;

图5是本发明实施例1的故障诊断装置的另一构成示意图;Fig. 5 is another schematic diagram of the structure of the fault diagnosis device according to Embodiment 1 of the present invention;

图6是本发明实施例1的对一节点的邻居节点进行分组之后的另一示意图;Fig. 6 is another schematic diagram after grouping neighbor nodes of a node according to Embodiment 1 of the present invention;

图7是本发明实施例1的检测包的一结构示意图;Fig. 7 is a schematic structural diagram of a detection package according to Embodiment 1 of the present invention;

图8是本发明实施例2的故障诊断方法的一流程示意图;FIG. 8 is a schematic flow chart of a fault diagnosis method according to Embodiment 2 of the present invention;

图9是本发明实施例2的故障诊断方法的另一流程示意图;Fig. 9 is another schematic flow chart of the fault diagnosis method in Embodiment 2 of the present invention;

图10是本发明实施例3的退避时间的设置方法的一流程示意图;FIG. 10 is a schematic flowchart of a method for setting back-off time in Embodiment 3 of the present invention;

图11是本发明实施例3的退避时间的设置方法的一示例图;FIG. 11 is an example diagram of a method for setting back-off time in Embodiment 3 of the present invention;

图12是本发明实施例3的退避时间的设置方法的另一示例图;Fig. 12 is another example diagram of the setting method of the backoff time in Embodiment 3 of the present invention;

图13是本发明实施例4的网络节点的一示意图;FIG. 13 is a schematic diagram of a network node according to Embodiment 4 of the present invention;

图14是本发明实施例4的网络节点的另一示意图。Fig. 14 is another schematic diagram of a network node according to Embodiment 4 of the present invention.

具体实施方式Detailed ways

下面结合附图对本发明的各种实施方式进行说明。这些实施方式只是示例性的,不是对本发明的限制。为了使本领域的技术人员能够容易地理解本发明的原理和实施方式,本发明的实施方式以无线Ad hoc网络或者无线传感器网络为例进行说明。但应该注意的是,本发明不限于此,本发明的实施方式可以适用于所有存在网络故障的通信系统。Various embodiments of the present invention will be described below in conjunction with the accompanying drawings. These embodiments are illustrative only, and do not limit the present invention. In order to enable those skilled in the art to easily understand the principle and implementation of the present invention, the implementation of the present invention will be described by taking a wireless Ad hoc network or a wireless sensor network as an example. However, it should be noted that the present invention is not limited thereto, and the embodiments of the present invention may be applicable to all communication systems with network faults.

实施例1Example 1

本发明实施例提供一种故障诊断装置,图1是本发明实施例的故障诊断装置的一构成示意图。如图1所示,该故障诊断装置100包括:时间启动单元101、根节点确定单元102和诊断控制单元103。An embodiment of the present invention provides a fault diagnosis device, and FIG. 1 is a schematic diagram of the structure of the fault diagnosis device according to the embodiment of the present invention. As shown in FIG. 1 , the fault diagnosis device 100 includes: a time start unit 101 , a root node determination unit 102 and a diagnosis control unit 103 .

其中,时间启动单元101在怀疑节点需要诊断时,启动诊断节点针对该怀疑节点的退避时间;根节点确定单元102根据对退避时间的倒计时来确定根节点,根节点是该怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;诊断控制单元103控制根节点启动建立诊断树,并接收该诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。Wherein, the time starting unit 101 starts the backoff time of the diagnosis node for the suspected node when the suspected node needs to be diagnosed; the root node determination unit 102 determines the root node according to the countdown to the backoff time, and the root node is a plurality of diagnostics of the suspected node. The diagnosis node whose backoff time ends first among the nodes; the diagnosis control unit 103 controls the root node to start establishing a diagnosis tree, receives the diagnosis information sent by the nodes in the diagnosis tree, and reports the diagnosis result to the gateway.

在本实施例中,故障诊断装置100可以是诊断节点的一组成部分,网络中的一个或多个诊断节点可以具有该故障诊断装置100,诊断节点的其他部分的构成可以参考现有技术。例如,网络中的每一诊断节点均可以具有该故障诊断装置100;而怀疑节点可以具有与诊断节点相同的构成。由此,网络中的各个节点之间可以形成分布式的结构。In this embodiment, the fault diagnosis device 100 may be an integral part of the diagnosis node, and one or more diagnosis nodes in the network may have the fault diagnosis device 100 , and the composition of other parts of the diagnosis node may refer to the prior art. For example, each diagnosis node in the network may have the fault diagnosis device 100; and the suspect node may have the same configuration as the diagnosis node. As a result, a distributed structure can be formed among the various nodes in the network.

但本发明不限于此,例如故障诊断装置100还可以是独立于诊断节点的部件,可以是网络中控制多个诊断节点的设备,由此在网络中形成集中式的结构。或者,故障诊断装置100的一部分可以位于诊断节点上,而另一部分形成集中式的设备。本领域技术人员可以根据实际情况确定具体的实施场景。在以下的实施例中,仅以该故障诊断装置包括在一个或多个诊断节点中为例进行说明。But the present invention is not limited thereto. For example, the fault diagnosis device 100 may also be a component independent of the diagnosis node, or a device controlling multiple diagnosis nodes in the network, thereby forming a centralized structure in the network. Alternatively, a part of the fault diagnosis device 100 may be located on a diagnosis node, while another part forms a centralized device. Those skilled in the art can determine the specific implementation scenario according to the actual situation. In the following embodiments, it is only described by taking that the fault diagnosis device is included in one or more diagnosis nodes as an example.

在本实施例中,诊断过程中可以有两种节点:诊断节点(DN,Detection Node)和怀疑节点(SN,Suspect Node)。例如,当节点A无法和节点B通信时,节点A会怀疑B发生故障,A会启动一个针对B的诊断过程;A称为诊断节点DN,而B称作怀疑节点SN。诊断节点是怀疑节点的一个或多个邻居节点,也就是说,诊断节点的集合可以是怀疑节点的邻居节点集合的一个子集。In this embodiment, there may be two kinds of nodes in the diagnosis process: a diagnosis node (DN, Detection Node) and a suspect node (SN, Suspect Node). For example, when node A fails to communicate with node B, node A will suspect that B has failed, and A will start a diagnosis process for B; A is called the diagnosis node DN, and B is called the suspected node SN. A diagnostic node is one or more neighbor nodes of a suspect node, that is, the set of diagnostic nodes can be a subset of the set of neighbor nodes of a suspect node.

当怀疑节点B需要诊断时,可能存在多个诊断节点(例如除节点A之外,还有节点C、D)。在具体实施时,诊断节点A、C、D可以通过各自的时间启动单元101来启动退避时间开始倒计时;然后倒计时最先结束的诊断节点(例如节点A)中的根节点确定单元102可以确定该节点A为根节点(RN,Root Node),而其他诊断节点(例如节点C、D)中的根节点确定单元102可以确定节点C、D不是根节点(可以停止退避时间的倒计时,具体可以参考后述内容)。When it is suspected that node B needs to be diagnosed, there may be multiple diagnostic nodes (for example, besides node A, there are also nodes C and D). During specific implementation, diagnostic nodes A, C, and D can start the countdown of the backoff time through their respective time starting units 101; Node A is the root node (RN, Root Node), and the root node determination unit 102 in other diagnostic nodes (such as nodes C and D) can determine that nodes C and D are not root nodes (the countdown of the backoff time can be stopped, for details, refer to content described later).

由此,可以由诊断节点A中的诊断控制单元103进行诊断控制,由该根节点A启动建立诊断树,加入到诊断树中的节点将各自的诊断信息发送给该根节点A,节点A最终将诊断结果上报给GW。因而在网关处可以获得统一的诊断结果,同时降低系统的通信开销。至于具体如何进行诊断树的建立、以及具体如何收集诊断信息和如何发送诊断结果,可以参考现有技术,本发明不再详细说明。Thus, the diagnostic control unit 103 in the diagnostic node A can perform diagnostic control, and the root node A starts to establish the diagnostic tree, and the nodes added to the diagnostic tree send their own diagnostic information to the root node A, and the node A finally Report the diagnosis result to GW. Therefore, a unified diagnosis result can be obtained at the gateway, and the communication overhead of the system can be reduced at the same time. As for how to establish the diagnosis tree, how to collect the diagnosis information and how to send the diagnosis results, reference may be made to the prior art, which will not be described in detail in the present invention.

在本实施例中,退避时间可以预先设置。对于网络中的一个节点,可以为该节点的多个邻居节点设置退避时间。退避时间可以通过将该节点的多个邻居节点分为不同的组后而设置,不同组的邻居节点设置不同的退避时间。In this embodiment, the backoff time can be preset. For a node in the network, backoff time can be set for multiple neighbor nodes of the node. The backoff time can be set by dividing multiple neighbor nodes of the node into different groups, and the neighbor nodes in different groups set different backoff time.

在具体实施时,如果怀疑节点的邻居节点中存在网关节点,也就是说网关是该怀疑节点的一邻居节点,则在该网关对该怀疑节点进行诊断时,可以将该网关确定为根节点。例如,可以直接确定该网关为根节点,由该网关建立诊断树;也可以为该网关设置小于其他节点的退避时间,使得该网关最先结束退避时间。In specific implementation, if there is a gateway node among the neighbor nodes of the suspect node, that is to say, the gateway is a neighbor node of the suspect node, then when the gateway diagnoses the suspect node, the gateway can be determined as the root node. For example, the gateway can be directly determined as the root node, and the diagnostic tree can be established by the gateway; a backoff time shorter than that of other nodes can also be set for the gateway, so that the gateway ends the backoff time first.

在具体实施时,至于如何设置退避时间,可以由该节点对各个邻居节点统一分配,也可以由各个邻居节点各自自己计算。本发明不限于此,本实施例中仅以各个邻居节点自己计算各自针对该节点的退避时间为例进行说明。In specific implementation, as for how to set the backoff time, the node can uniformly allocate each neighbor node, or each neighbor node can calculate it by itself. The present invention is not limited thereto. In this embodiment, it is only described by taking each neighbor node calculating its own backoff time for the node as an example.

图2是本发明实施例的故障诊断装置的另一构成示意图。如图2所示,该故障诊断装置200包括:时间启动单元101、根节点确定单元102和诊断控制单元103。如上所述。Fig. 2 is another schematic diagram of the structure of the fault diagnosis device according to the embodiment of the present invention. As shown in FIG. 2 , the fault diagnosis device 200 includes: a time start unit 101 , a root node determination unit 102 and a diagnosis control unit 103 . as above.

如图2所示,该故障诊断装置200还可以包括:分组单元204。该分组单元204根据通信距离将怀疑节点的多个邻居节点分为不同的组。As shown in FIG. 2 , the fault diagnosis device 200 may further include: a grouping unit 204 . The grouping unit 204 divides multiple neighboring nodes of the suspected node into different groups according to the communication distance.

在具体实施时,分组单元204具体可以用于:根据通信距离将一节点的多个邻居节点分为第一组和第二组;其中,第一组中的邻居节点与该节点的通信距离小于或等于设定的距离,比如R/2、R/3、R/4等,第二组中的邻居节点与该节点的通信距离大于所述设定的距离。其中,R为该节点的通信范围。In a specific implementation, the grouping unit 204 can be specifically used to: divide a plurality of neighbor nodes of a node into a first group and a second group according to the communication distance; wherein, the communication distance between the neighbor nodes in the first group and the node is less than Or equal to a set distance, such as R/2, R/3, R/4, etc., the communication distance between the neighbor nodes in the second group and the node is greater than the set distance. Among them, R is the communication range of the node.

此外,也可以通过接收到该节点的信号强度进行分组,其中,第一组中的邻居节点接收到该节点的信号强度大于等于设定的信号强度阈值,比如-50dBm、-60dBm、-70dBm等,第一组中的邻居节点接收到该节点的信号强度小于所述设定的信号强度阈值。In addition, it is also possible to group by receiving the signal strength of the node, wherein the neighbor nodes in the first group receive the signal strength of the node greater than or equal to the set signal strength threshold, such as -50dBm, -60dBm, -70dBm, etc. , the signal strength received by the neighbor nodes in the first group is less than the set signal strength threshold.

当分成超过两组,如分成第一组、第二组、第三组,第一组中的邻居节点与该节点的通信距离小于或等于R/4,第二组中的邻居节点与该节点的通信距离大于R/4小于等于R/2,第三组中的邻居节点与该节点的通信距离大于R/2。其余的分组方法不再举例,与此类似。When divided into more than two groups, such as the first group, the second group, and the third group, the communication distance between the neighbor nodes in the first group and the node is less than or equal to R/4, and the communication distance between the neighbor nodes in the second group and the node The communication distance of is greater than R/4 and less than or equal to R/2, and the communication distance between the neighbor nodes in the third group and this node is greater than R/2. The rest of the grouping methods will not be given as examples, and are similar to this.

例如,网络中的每个节点可以通过周期性的侦听(例如采用Hello包)机制来获取自己和邻居节点间的接收信号强度指示(RSSI,Received Signal Strength Indication)信息,进而得到该节点和邻居节点之间的通信距离,然后可以将多个邻居节点进行分组。For example, each node in the network can obtain the Received Signal Strength Indication (RSSI, Received Signal Strength Indication) information between itself and its neighbor nodes through a periodic listening mechanism (for example, using Hello packets), and then obtain the information of the node and its neighbors. The communication distance between nodes can then group multiple neighbor nodes.

值得注意的是,以上通过通信距离进行分组的方法仅是本发明的具体实施方式,但本发明不限于此,例如还可以根据其他信息(例如通信质量)进行分组,或者将邻居节点分为多于2组(例如3组、4组等等),可以根据实际情况确定具体的实施场景。It is worth noting that the above method of grouping by communication distance is only a specific embodiment of the present invention, but the present invention is not limited thereto. For example, grouping can also be performed according to other information (such as communication quality), or neighbor nodes can be divided into multiple For group 2 (such as group 3, group 4, etc.), the specific implementation scenario can be determined according to the actual situation.

图3是本发明实施例的对一节点的邻居节点进行分组之后的示意图。如图3所示,节点①是该节点,节点②③④⑤⑥是其邻居节点。可以将与节点①距离小于等于R/2(R是节点的通信范围)的区域(图中区域A)称作主要区域PZ(Primary Zone);在节点①的通信范围内,并且与节点①距离大于R/2的区域(图中区域B)称作次要区域SZ(Secondary Zone)。由此,可以将邻居节点分组(例如,PZ区域的邻居节点对应第一组,SZ区域的邻居节点对应第二组)。Fig. 3 is a schematic diagram after grouping neighbor nodes of a node according to an embodiment of the present invention. As shown in Figure 3, node ① is the node, and node ②③④⑤⑥ is its neighbor node. The area (area A in the figure) whose distance from node ① is less than or equal to R/2 (R is the communication range of the node) can be called the primary zone PZ (Primary Zone); within the communication range of node ①, and the distance from node ① The area greater than R/2 (area B in the figure) is called the secondary area SZ (Secondary Zone). Thus, the neighbor nodes can be grouped (for example, the neighbor nodes in the PZ area correspond to the first group, and the neighbor nodes in the SZ area correspond to the second group).

在本实施例中,将一节点的多个邻居节点分为不同的组之后,可以对不同组的邻居节点设置不同的退避时间。由此,可以使得不同组的邻居节点的退避时间不会同时结束,根据退避时间的倒计时来确定的根节点可以为一个。In this embodiment, after the multiple neighbor nodes of a node are divided into different groups, different backoff times may be set for the neighbor nodes of different groups. Thus, the backoff time of neighboring nodes in different groups may not end at the same time, and there may be only one root node determined according to the countdown of the backoff time.

如图2所示,该故障诊断装置200还可以包括:时间设置单元205,该时间设置单元205对不同组的邻居节点设置不同的退避时间。其中,对于每个组中的多个邻居节点,所对应的退避时间可以为多个;例如各个邻居节点的退避时间各不相同。因此每个组的退避时间可以形成一段时间范围。As shown in FIG. 2 , the fault diagnosis device 200 may further include: a time setting unit 205 , which sets different backoff times for different groups of neighboring nodes. Wherein, for multiple neighbor nodes in each group, there may be multiple corresponding backoff times; for example, the backoff times of each neighbor node are different. Therefore, the backoff time of each group can form a range of time.

并且,不同的组的退避时间所形成的时间范围互不重叠。以下以分为两组为例,对退避时间的设置进行说明。在本实施例中,可以按照下述规则为每个邻居节点设置一个退避时间BO(Backoff)。Also, the time ranges formed by the backoff times of different groups do not overlap with each other. In the following, two groups are taken as an example to illustrate the setting of the backoff time. In this embodiment, a backoff time BO (Backoff) may be set for each neighbor node according to the following rules.

例如,时间设置单元205可以采用如下公式设置退避时间:For example, the time setting unit 205 may use the following formula to set the backoff time:

t0≤t1≤BO1≤t2<t3≤BO2≤t4 t 0 ≤t 1 ≤BO 1 ≤t 2 <t 3 ≤BO 2 ≤t 4

其中,BO1是为第一组的邻居节点(例如图3中的④⑤)设置的退避时间,BO2是为第二组的邻居节点(例如图3中的②③⑥)设置的退避时间;其中,t1、t2、t3、t4是预定的时间,t0为该诊断节点检测到怀疑节点故障的时刻。Among them, BO 1 is the backoff time set for the first group of neighbor nodes (such as ④⑤ in Figure 3), and BO 2 is the backoff time set for the second group of neighbor nodes (such as ②③⑥ in Figure 3); among them, t 1 , t 2 , t 3 , and t 4 are predetermined times, and t 0 is the moment when the diagnostic node detects a suspected node failure.

在具体实施时,可以采用如下规则来实现:In specific implementation, the following rules can be used to achieve:

BO1=t1+(t2-t1)·F(Hop,NN)BO 1 =t 1 +(t 2 -t 1 )·F(Hop,NN)

BO2=t3+(t4-t3)·F(Hop,NN)BO 2 =t 3 +(t 4 -t 3 )·F(Hop,NN)

F(Hop,NN)为一取值在[0,1]的函数,F(Hop,NN)与该邻居节点的跳数Hop成正比,与该邻居节点的邻居数量成反比。F(Hop, NN) is a function whose value is in [0, 1]. F(Hop, NN) is proportional to the hop number Hop of the neighbor node, and inversely proportional to the number of neighbors of the neighbor node.

在具体实施时,t0=t1时表明当该节点一检测到故障就开始退避时间的倒计时;t0<t1时表明该节点在检测到故障之后,延时一段时间再开始退避时间的倒计时。t1=t2时,该节点可以以MAC层CSMA/CA机制的backoff时间作为自己的退避时间;MAC层中的backoff机制是为了保证避免信道冲突,具体内容可以参考现有技术。对于t3、t4可以与t1、t2的情况相同。In the specific implementation, when t 0 =t 1 , it means that the countdown of the back-off time starts as soon as the node detects a fault; when t 0 <t 1 , it means that the node delays for a period of time after detecting the fault and then starts the countdown of the back-off time countdown. When t 1 =t 2 , the node can use the backoff time of the MAC layer CSMA/CA mechanism as its own backoff time; the backoff mechanism in the MAC layer is to ensure that channel conflicts are avoided, and the specific content can refer to the existing technology. The case of t 3 and t 4 can be the same as that of t 1 and t 2 .

在具体实施时,如果怀疑节点的邻居节点中存在网关节点,则可以为该网关分配t0到t1之间的退避时间,使得该网关最先结束退避时间的倒计时,成为根节点而启动建立诊断树。In specific implementation, if there is a gateway node among the neighbor nodes of the suspected node, the gateway can be assigned a backoff time between t 0 and t 1 , so that the gateway first ends the countdown of the backoff time and becomes the root node to start the establishment diagnostic tree.

在一个实施方式中,F(HopNN)可以采用如下公式:In one embodiment, F(HopNN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&CenterDot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

在另一个实施方式中,F(HopNN)可以采用如下公式:In another embodiment, F(HopNN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令 in, ε is a random parameter with a value in [0,0.5]; and if order

图4是本发明实施例的t1、t2、t3、t4与BO1、BO2的关系示意图。如图4所示,BO1是[t1,t2]之间的某值,BO2是[t3,t4]之间的某值。如果距离怀疑节点R/2的范围内至少有一个诊断节点,[t2,t3]这段时间保证了只有一个诊断节点会启动诊断树的建立过程。Fig. 4 is a schematic diagram of the relationship between t 1 , t 2 , t 3 , t 4 and BO 1 , BO 2 in an embodiment of the present invention. As shown in FIG. 4 , BO1 is a certain value between [t 1 , t 2 ], and BO2 is a certain value between [t 3 , t 4 ]. If there is at least one diagnostic node within the range of R/2 from the suspected node, the period [t 2 , t 3 ] guarantees that only one diagnostic node will start the process of establishing the diagnostic tree.

在具体实施时,t2和t3之间的间隔时间为一参数。可以设定t2和t3之间的间隔为“数据包传输3跳的时间”;也可以设定t2和t3之间的间隔是“数据包传输9跳的时间”。In a specific implementation, the time interval between t2 and t3 is a parameter. The interval between t2 and t3 can be set as "the time of data packet transmission for 3 hops"; the interval between t2 and t3 can also be set as "the time of data packet transmission for 9 hops".

例如,对于图3所示的场景,邻居节点④⑤中的时间设置单元205可以针对节点①采用BO1=t1+(t2-t1)·F(Hop,NN)来设置退避时间T4、T5;邻居节点②③⑥中的时间设置单元205可以针对节点①采用BO2=t3+(t4-t3)·F(Hop,NN)来设置退避时间T2、T3、T6。而节点①中的时间设置单元205也可以针对其邻居节点来为自己设置退避时间。For example, for the scenario shown in Figure 3, the time setting unit 205 in the neighbor node ④⑤ can use BO 1 =t 1 +(t 2 −t 1 )·F(Hop,NN) to set the backoff time T4, T5; the time setting unit 205 in the neighbor node ②③⑥ can adopt BO 2 =t 3 +(t 4 −t 3 )·F(Hop,NN) to set the back-off time T2, T3, T6 for node ①. The time setting unit 205 in node ① can also set the backoff time for itself for its neighbor nodes.

值得注意的是,以上仅对本发明中退避时间的设置进行了示意性说明,但本发明不限于此,例如还可以根据实际情况采用适当的变形等,可以采用其他的公式。It should be noted that the above only schematically illustrates the setting of the backoff time in the present invention, but the present invention is not limited thereto, for example, appropriate deformations may be adopted according to actual conditions, and other formulas may be used.

图5是本发明实施例的故障诊断装置的另一构成示意图。如图5所示,该故障诊断装置500包括:时间启动单元101、根节点确定单元102、诊断控制单元103、分组单元204和时间设置单元205,如上所述。Fig. 5 is another schematic diagram of the structure of the fault diagnosis device according to the embodiment of the present invention. As shown in FIG. 5 , the fault diagnosis device 500 includes: a time start unit 101 , a root node determination unit 102 , a diagnosis control unit 103 , a grouping unit 204 and a time setting unit 205 , as described above.

如图5所示,该故障诊断装置还可以包括:节点选择单元505,在第一组没有邻居节点时,从第二组中挑选一个邻居节点作为第一组的邻居节点;并且,时间设置单元205还用于为选择出的该邻居节点设置对应第一组的退避时间。As shown in Figure 5, the fault diagnosis device can also include: a node selection unit 505, when there is no neighbor node in the first group, select a neighbor node from the second group as the neighbor node of the first group; and, the time setting unit 205 is also used to set the backoff time corresponding to the first group for the selected neighbor node.

具体地,节点选择单元505可以在所有的邻居节点与该诊断节点的距离全都大于R/2时,从距离全都大于R/2的邻居节点中挑选一个邻居节点作为第一组的邻居节点。Specifically, the node selection unit 505 may select a neighbor node from the neighbor nodes whose distances are all greater than R/2 as the first group of neighbor nodes when the distances between all neighbor nodes and the diagnostic node are greater than R/2.

如图5所示,该故障诊断装置还可以包括:时间发送单元506。该时间发送单元506将时间设置单元205设置的退避时间发送给选择出的邻居节点,使得邻居节点存储该退避时间。As shown in FIG. 5 , the fault diagnosis device may further include: a time sending unit 506 . The time sending unit 506 sends the backoff time set by the time setting unit 205 to the selected neighbor node, so that the neighbor node stores the backoff time.

其中,该节点选择单元505可以选择距离该诊断节点最近的邻居节点;或者,当存在多个距离相同的邻居节点时,该节点选择单元505选择其中跳数最小的邻居节点;或者,当存在多个距离相同且多个跳数相同的邻居节点时,该节点选择单元505从其中随机选取一个邻居节点。Wherein, the node selection unit 505 may select the neighbor node closest to the diagnostic node; or, when there are multiple neighbor nodes with the same distance, the node selection unit 505 selects the neighbor node with the smallest hop count; or, when there are multiple When there are several neighbor nodes with the same distance and the same number of hops, the node selection unit 505 randomly selects a neighbor node from them.

图6是本发明实施例的对一节点的邻居节点进行分组之后的另一示意图。如图6所示,节点①是该节点,节点②③⑥是其邻居节点。可以将与节点①距离小于等于R/2(R是节点的通信范围)的区域(图中区域A)称作主要区域PZ;在节点①的通信范围内,并且与节点①距离大于R/2的区域(图中区域B)称作次要区域SZ。Fig. 6 is another schematic diagram after grouping the neighbor nodes of a node according to the embodiment of the present invention. As shown in Figure 6, node ① is the node, and node ②③⑥ is its neighbor node. The area (area A in the figure) whose distance from node ① is less than or equal to R/2 (R is the communication range of the node) can be called the main area PZ; within the communication range of node ①, and the distance from node ① is greater than R/2 The area (area B in the figure) is called the secondary area SZ.

如图6所示,在区域A中没有邻居节点,而在区域B中具有邻居节点②③⑥。在具体实施时,针对例如附图6在PZ(区域A)中没有节点的情况,即该节点①发现邻居节点与自己的距离全都大于R/2时,该节点①挑选一个距离自己最近的节点(例如节点②)。如果有多个距离相同的邻居节点,则挑选其中跳数最小的邻居节点;如果还有多个跳数相同的邻居节点,则从中随机选取。As shown in Figure 6, there are no neighbor nodes in area A, but there are neighbor nodes ②③⑥ in area B. In the specific implementation, for example, in the case that there is no node in PZ (area A) in Figure 6, that is, when the node ① finds that the distance between the neighbor nodes and itself is greater than R/2, the node ① chooses a node that is closest to itself (e.g. node ②). If there are multiple neighbor nodes with the same distance, select the neighbor node with the smallest hop count; if there are multiple neighbor nodes with the same hop count, choose randomly from them.

在选择出该邻居节点(例如节点②)之后,节点①可以为该邻居节点②设置一个在[t1,t2]内的BACKOFF时间,并将这个时间发送给该邻居节点。After selecting the neighbor node (such as node ②), node ① can set a BACKOFF time within [t1, t2] for the neighbor node ②, and send this time to the neighbor node.

在本实施例中,时间启动单元101具体可以用于:在诊断节点没有从怀疑节点连续收到多个侦听包(Hello包)时,启动针对该怀疑节点的退避时间开始倒计时,并可以将该怀疑节点存储在本地作为本地怀疑节点LSN(Local Suspect Node)。In this embodiment, the time start unit 101 can be specifically configured to: when the diagnosis node does not receive multiple interception packets (Hello packets) from the suspect node continuously, start the countdown of the backoff time for the suspect node, and can set The suspected node is stored locally as a local suspected node LSN (Local Suspect Node).

在本实施例中,诊断控制单元103还可以用于:在根节点确定单元102确定根节点之后,控制该根节点广播检测包DP(Detection Packet);使得其他诊断节点在退避时间倒计时未结束且收到该检测包时,不再进行退避时间的倒计时。其中,其他诊断节点是指除了确定为根节点的诊断节点外的一个或多个诊断节点。In this embodiment, the diagnosis control unit 103 can also be used to: after the root node determination unit 102 determines the root node, control the root node to broadcast a detection packet DP (Detection Packet); so that other diagnostic nodes do not end the countdown of the backoff time and When the detection packet is received, the countdown of the backoff time is no longer performed. Wherein, other diagnostic nodes refer to one or more diagnostic nodes other than the diagnostic node determined as the root node.

在具体实施时,例如当节点A发现其邻居节点B已有连续K次Hello包未收到时,节点A认为节点B需要进行诊断,并将节点B存储在本地,记做LSN(Local SN)。如果节点A的退避时间BO计时结束,则可以建立诊断树并广播一个检测包DP;如果节点A在BO倒计时未结束时就收到了其他节点发送的检测包DP,则不再进行BO倒计时,而将该检测包DP继续广播(需要指出的是,已加入到诊断树中的节点如果再次收到DP包,则不再进行广播)。In actual implementation, for example, when node A discovers that its neighbor node B has not received K consecutive Hello packets, node A thinks that node B needs to be diagnosed, and stores node B locally, which is recorded as LSN (Local SN) . If the back-off time BO of node A ends, a diagnostic tree can be established and a detection packet DP is broadcast; if node A receives the detection packet DP sent by other nodes before the BO countdown is over, the BO countdown is no longer performed, and Continue to broadcast the detection packet DP (it should be pointed out that if the node that has joined the diagnosis tree receives the DP packet again, it will not broadcast again).

在具体实施时,该检测包DP可以包括源地址、怀疑节点的标识信息、以及根节点的标识信息。此外,还可以包括帧类型(Frame Type)和保留位(Reserved)。During specific implementation, the detection packet DP may include the source address, identification information of the suspected node, and identification information of the root node. In addition, the frame type (Frame Type) and reserved bits (Reserved) can also be included.

图7是本发明实施例的检测包的一结构示意图。如图7所示,可以包括:DP包的源地址(可以用GS表示);帧类型(FT,Frame Type),表明该包是detection packet;怀疑节点标识(可以用SN ID表示);根节点标识(可以用RN ID表示);以及保留位(可以用Reserved表示)。FIG. 7 is a schematic structural diagram of a detection packet according to an embodiment of the present invention. As shown in Figure 7, it can include: the source address of the DP packet (which can be represented by GS); the frame type (FT, Frame Type), indicating that the packet is a detection packet; the suspected node identifier (which can be represented by SN ID); the root node Identification (can be represented by RN ID); and reserved bit (can be represented by Reserved).

在本实施例中,当一个节点收到DP后,如果发现该DP的SN ID和本地存储的LSN相同,则可以将该DP的GS改为自己的地址之后继续广播这个DP;如果发现SN ID和本地邻居表中的某个邻居节点相同,则继续广播这个DP;如果发现SN ID不在本地邻居表内,则不广播这个DP(说明该节点不是SN的邻居节点)。In this embodiment, after a node receives a DP, if it finds that the SN ID of the DP is the same as the locally stored LSN, it can change the GS of the DP to its own address and continue broadcasting the DP; if it finds that the SN ID If it is the same as a neighbor node in the local neighbor table, continue to broadcast the DP; if it is found that the SN ID is not in the local neighbor table, the DP will not be broadcast (indicating that the node is not a neighbor node of the SN).

由上述实施例可知,在怀疑节点需要诊断时,启动诊断节点针对怀疑节点的退避时间,根据对退避时间的倒计时来确定根节点,并由该根节点启动建立诊断树,接收诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。由此,可以在网关处获得统一的诊断结果,同时降低系统的通信开销。It can be seen from the above embodiments that when a suspected node needs to be diagnosed, start the back-off time of the diagnostic node for the suspected node, determine the root node according to the countdown to the back-off time, and start the establishment of the diagnostic tree by the root node, and receive the nodes in the diagnostic tree The diagnostic information sent, and the diagnostic results are reported to the gateway. In this way, a unified diagnosis result can be obtained at the gateway, while reducing the communication overhead of the system.

实施例2Example 2

本发明实施例提供一种故障诊断方法,对应于实施例1的故障诊断装置。图8是本发明实施例的故障诊断方法的一流程示意图,如图8所示,该故障诊断方法包括:An embodiment of the present invention provides a fault diagnosis method, which corresponds to the fault diagnosis device in Embodiment 1. Fig. 8 is a schematic flow chart of a fault diagnosis method according to an embodiment of the present invention. As shown in Fig. 8, the fault diagnosis method includes:

步骤801,在怀疑节点需要诊断时,启动诊断节点针对该怀疑节点的退避时间;Step 801, when the suspected node needs to be diagnosed, start the backoff time of the suspected node for the diagnosed node;

步骤802,根据对该退避时间的倒计时来确定根节点;该根节点为该怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;Step 802, determine the root node according to the countdown of the backoff time; the root node is the diagnostic node whose backoff time ends first among the multiple diagnostic nodes of the suspected node;

步骤803,控制该根节点启动建立诊断树,并接收诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。Step 803, control the root node to start establishing a diagnosis tree, receive diagnosis information sent by nodes in the diagnosis tree, and report the diagnosis result to the gateway.

在本实施例中,退避时间可以是预先确定的。对于每个诊断节点,可以将该诊断节点的多个邻居节点分为不同的组,并对不同组的邻居节点设置不同的退避时间。In this embodiment, the backoff time may be predetermined. For each diagnostic node, multiple neighbor nodes of the diagnostic node can be divided into different groups, and different backoff times can be set for different groups of neighbor nodes.

具体地,将诊断节点的多个邻居节点分为不同的组具体可以包括:根据通信距离将多个邻居节点分为多个不同的组。例如,可以分为第一组和第二组;第一组中的邻居节点与该诊断节点的通信距离小于或等于R/2,第二组中的邻居节点与该诊断节点的通信距离大于R/2;其中,R为该诊断节点的通信范围。Specifically, dividing the multiple neighbor nodes of the diagnosis node into different groups may specifically include: dividing the multiple neighbor nodes into multiple different groups according to communication distances. For example, it can be divided into the first group and the second group; the communication distance between the neighbor nodes in the first group and the diagnosis node is less than or equal to R/2, and the communication distance between the neighbor nodes in the second group and the diagnosis node is greater than R /2; Among them, R is the communication range of the diagnosis node.

在一个实施方式中,实施场景可以如图3所示。第一组(例如图3中的区域A)和第二组(例如图3中的区域B)均存在邻居节点。可以分别对不同组的邻居节点设置不同的退避时间。In an implementation manner, the implementation scenario may be as shown in FIG. 3 . Neighbor nodes exist in both the first group (for example, area A in Figure 3 ) and the second group (for example, area B in Figure 3 ). Different backoff times can be set for different groups of neighbor nodes.

在另一个实施方式中,实施场景可以如图6所示。在所有的邻居节点与该诊断节点的距离全都大于R/2时,可以挑选一个邻居节点作为第一组的邻居节点。其中,挑选一个邻居节点作为所述第一组的邻居节点具体可以包括:选择距离该诊断节点最近的邻居节点;或者,当存在多个距离相同的邻居节点时,选择其中跳数最小的邻居节点;或者,当存在多个距离相同且多个跳数相同的邻居节点时,从其中随机选取一个邻居节点。In another implementation manner, the implementation scenario may be as shown in FIG. 6 . When the distances between all neighbor nodes and the diagnostic node are greater than R/2, a neighbor node may be selected as the first group of neighbor nodes. Wherein, selecting a neighbor node as the neighbor node of the first group may specifically include: selecting the neighbor node closest to the diagnostic node; or, when there are multiple neighbor nodes with the same distance, selecting the neighbor node with the smallest hop count ; Or, when there are multiple neighbor nodes with the same distance and the same number of hops, randomly select a neighbor node from them.

在本实施例中,该故障诊断方法还可以包括:将设置的退避时间发送给该选择出的邻居节点,使得该邻居节点存储退避时间。In this embodiment, the fault diagnosis method may further include: sending the set backoff time to the selected neighbor node, so that the neighbor node stores the backoff time.

在本实施例中,步骤801中在怀疑节点需要诊断时,启动诊断节点针对该怀疑节点的退避时间具体可以包括:在该诊断节点没有从该怀疑节点连续收到多个Hello包时,启动退避时间开始倒计时,并将该怀疑节点存储在本地作为本地怀疑节点。In this embodiment, when the suspected node needs to be diagnosed in step 801, starting the backoff time of the diagnosing node for the suspected node may specifically include: when the diagnosing node does not continuously receive multiple Hello packets from the suspected node, starting backoff The time starts counting down, and the suspect node is stored locally as a local suspect node.

在本实施例中,在步骤802确定根节点之后,该故障诊断方法还可以包括:控制该根节点广播检测包;使得其他诊断节点在退避时间倒计时未结束且收到检测包时,不再进行退避时间的倒计时。其中,检测包可以包括源地址、怀疑节点的标识信息、以及根节点的标识信息。检测包的结构可以参考附图7的内容。In this embodiment, after the root node is determined in step 802, the fault diagnosis method may further include: controlling the root node to broadcast a detection packet; so that other diagnosis nodes do not perform any further operations when the backoff time countdown has not ended and the detection packet is received. Countdown for backoff time. Wherein, the detection packet may include source address, identification information of the suspected node, and identification information of the root node. For the structure of the detection packet, please refer to the content in Fig. 7 .

在本实施例中,该故障诊断方法还可以包括:当某一个诊断节点收到检测包后,如果发现该检测包的怀疑节点的标识信息和本地存储的本地怀疑节点相同,则将该检测包的源地址改为该诊断节点自己的地址,然后继续广播检测包;如果发现检测包的怀疑节点的标识信息和本地邻居表中的某个邻居节点相同,则继续广播检测包;如果发现检测包的怀疑节点的标识信息不在本地邻居表内,则不广播检测包。In this embodiment, the fault diagnosis method may also include: after a certain diagnosis node receives the detection packet, if it is found that the identification information of the suspected node in the detection packet is the same as the local suspected node stored locally, then the detection packet Change the source address of the diagnostic node to its own address, and then continue to broadcast the detection packet; if the identification information of the suspected node in the detection packet is found to be the same as a neighbor node in the local neighbor table, continue to broadcast the detection packet; if the detection packet is found If the identification information of the suspected node is not in the local neighbor table, the detection packet will not be broadcast.

图9是本发明实施例的故障诊断方法的另一流程示意图,如图9所示,该故障诊断方法包括:Fig. 9 is another schematic flowchart of a fault diagnosis method according to an embodiment of the present invention. As shown in Fig. 9, the fault diagnosis method includes:

步骤901,诊断节点对怀疑节点发送的Hello包进行计数。Step 901, the diagnosis node counts the Hello packets sent by the suspect node.

步骤902,判断是否没有连续接收到该怀疑节点发送的K个Hello包;如果没有连续接收到,则执行步骤903。Step 902, judging whether K Hello packets sent by the suspected node have not been continuously received; if not, then step 903 is executed.

步骤903,诊断节点认为该怀疑节点需要诊断,开启退避时间开始倒计时。In step 903, the diagnosis node considers that the suspected node needs to be diagnosed, and starts counting down the backoff time.

步骤904,判断退避时间的倒计时是否结束;如果倒计时已经结束,则执行步骤905,否则执行步骤907。Step 904, judging whether the countdown of the backoff time is over; if the countdown is over, go to step 905, otherwise go to step 907.

具体地,可以判断该诊断节点针对该怀疑节点的退避时间BO;如果BO大于0则该退避时间还没有结束,执行步骤907;如果BO小于等于0则该退避时间结束,执行步骤905。Specifically, the backoff time BO of the diagnostic node for the suspect node can be judged; if BO is greater than 0, the backoff time has not ended, and step 907 is performed; if BO is less than or equal to 0, the backoff time is over, and step 905 is performed.

步骤905,确定该诊断节点为根节点,开启建立诊断树并广播检测包DP。Step 905, determine that the diagnostic node is the root node, start building a diagnostic tree and broadcast a detection packet DP.

步骤906,收集诊断信息并上报诊断结果给网关。Step 906, collecting diagnostic information and reporting the diagnostic result to the gateway.

步骤907,判断是否收到其他节点发送的检测包DP;如果收到检测包DP,则执行步骤908,否则执行步骤904。Step 907, judging whether the detection packet DP sent by other nodes is received; if the detection packet DP is received, execute step 908, otherwise execute step 904.

步骤908,停止退避时间倒计时,加入其他节点建立的诊断树并继续广播该检测包DP。Step 908, stop the countdown of the backoff time, join the diagnosis tree established by other nodes and continue to broadcast the detection packet DP.

此外,如果接收到检测包DP的节点发现该检测包DP的怀疑节点的标识信息不在本地邻居表内,则表明该节点不是该怀疑节点的邻居节点,因此不广播该检测包DP。并且,已经加入到诊断树的节点再次接收到检测包后,也可以不再广播该检测包。In addition, if the node receiving the detection packet DP finds that the identification information of the suspected node of the detection packet DP is not in the local neighbor table, it indicates that the node is not a neighbor node of the suspected node, so the detection packet DP is not broadcast. Moreover, after receiving the detection packet again, the nodes that have been added to the diagnosis tree may not broadcast the detection packet any more.

以下以图3所示的场景为例进行说明。在如图3所示的场景中,假设针对节点①,已经为邻居节点②③④⑤⑥设置了退避时间,分别是T2、T3、T4、T5、T6。具体的设置方法可以参考实施例1或者实施例3。The scenario shown in FIG. 3 is taken as an example below for description. In the scenario shown in Figure 3, it is assumed that for node ①, backoff times have been set for neighbor nodes ②③④⑤⑥, which are T2, T3, T4, T5, and T6 respectively. For the specific setting method, please refer to Embodiment 1 or Embodiment 3.

在节点①作为怀疑节点需要诊断时,节点②③④⑤⑥作为诊断节点开始启动退避时间倒计时。对于其中一个诊断节点(例如节点⑤),如果T5=0(即最早结束退避时间),则可以确定该节点⑤是根节点,该节点⑤开始建立诊断树并发送检测包DP。When node ① needs to be diagnosed as a suspected node, node ②③④⑤⑥, as a diagnostic node, starts the backoff time countdown. For one of the diagnostic nodes (such as node ⑤), if T5=0 (that is, the earliest end backoff time), it can be determined that the node ⑤ is the root node, and the node ⑤ starts to build a diagnostic tree and sends a detection packet DP.

对于其他诊断节点(例如节点②③④⑥),如果接收到该节点⑤发送的检测包DP,则停止退避时间的倒计时,加入该诊断树并继续广播该检测包DP。由此,可以由节点⑤建立诊断树,收集诊断信息并发送给网关。For other diagnostic nodes (such as node ②③④⑥), if the detection packet DP sent by the node ⑤ is received, the countdown of the backoff time will be stopped, join the diagnostic tree and continue to broadcast the detection packet DP. Thus, a diagnostic tree can be established by node ⑤, and diagnostic information can be collected and sent to the gateway.

由上述实施例可知,在怀疑节点需要诊断时,启动诊断节点针对怀疑节点的退避时间,根据对退避时间的倒计时来确定根节点,并由该根节点启动建立诊断树,接收诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。由此,可以在网关处获得统一的诊断结果,同时降低系统的通信开销。It can be seen from the above embodiments that when a suspected node needs to be diagnosed, start the back-off time of the diagnostic node for the suspected node, determine the root node according to the countdown to the back-off time, and start the establishment of the diagnostic tree by the root node, and receive the nodes in the diagnostic tree The diagnostic information sent, and the diagnostic results are reported to the gateway. In this way, a unified diagnosis result can be obtained at the gateway, while reducing the communication overhead of the system.

实施例3Example 3

本发明实施例提供一种退避时间的设置方法,可以作为实施例2的一部分或者预先准备过程,与实施例1中退避时间的设置部分相同的内容,此处不再赘述。The embodiment of the present invention provides a backoff time setting method, which can be used as a part of embodiment 2 or a pre-preparation process, and has the same content as the setting part of the backoff time in embodiment 1, which will not be repeated here.

图10是本发明实施例的退避时间的设置方法的一流程示意图,如图10所示,该设置方法包括:FIG. 10 is a schematic flowchart of a method for setting backoff time according to an embodiment of the present invention. As shown in FIG. 10 , the setting method includes:

步骤1001,将节点的多个邻居节点分为不同的组;Step 1001, dividing multiple neighbor nodes of the node into different groups;

步骤1002,对于不同组的邻居节点,设置不同的退避时间。Step 1002, setting different backoff times for different groups of neighbor nodes.

在本实施例中,对于任一节点,可以将该节点的多个邻居节点分为不同的组,然后设置退避时间。由此,可以使得不同组的邻居节点的退避时间不会同时结束,根据退避时间的倒计时来确定的根节点可以为一个。In this embodiment, for any node, multiple neighbor nodes of the node may be divided into different groups, and then a backoff time is set. Thus, the backoff time of neighboring nodes in different groups may not end at the same time, and there may be only one root node determined according to the countdown of the backoff time.

在具体实施时,步骤1001中将节点的多个邻居节点分为不同的组,具体可以包括:根据通信距离将多个邻居节点分为多个不同的组。例如,可以分为第一组和第二组,第一组中的邻居节点与该节点的通信距离小于或等于R/2,第二组中的邻居节点与该节点的通信距离大于R/2;其中,R为该节点的通信范围。During specific implementation, in step 1001, dividing multiple neighboring nodes of a node into different groups may specifically include: dividing multiple neighboring nodes into multiple different groups according to communication distances. For example, it can be divided into the first group and the second group, the communication distance between the neighbor nodes in the first group and the node is less than or equal to R/2, and the communication distance between the neighbor nodes in the second group and the node is greater than R/2 ; Among them, R is the communication range of the node.

值得注意的是,以上通过通信距离进行分组的方法仅是本发明的具体实施方式,但本发明不限于此,例如还可以根据其他信息(例如通信质量)进行分组,或者将邻居节点分为多于2组(例如3组、4组等等),可以根据实际情况确定具体的实施场景。It is worth noting that the above method of grouping by communication distance is only a specific embodiment of the present invention, but the present invention is not limited thereto. For example, grouping can also be performed according to other information (such as communication quality), or neighbor nodes can be divided into multiple For group 2 (such as group 3, group 4, etc.), the specific implementation scenario can be determined according to the actual situation.

在具体实施时,步骤1002中可以采用如下规则设置退避时间:During specific implementation, the following rules can be used to set the backoff time in step 1002:

t0≤t1≤BO1≤t2<t3≤BO2≤t4 t 0 ≤t 1 ≤BO 1 ≤t 2 <t 3 ≤BO 2 ≤t 4

其中,BO1是为第一组的邻居节点设置的退避时间,BO2是为第二组的邻居节点设置的退避时间;t1、t2、t3、t4是预定的时间。Among them, BO 1 is the backoff time set for the first group of neighbor nodes, BO 2 is the backoff time set for the second group of neighbor nodes; t 1 , t 2 , t 3 , t 4 are predetermined times.

在具体实施时,可以采用如下规则实现:In specific implementation, the following rules can be used to achieve:

BO1=t1+(t2-t1)·F(Hop,NN)BO 1 =t 1 +(t 2 -t 1 )·F(Hop,NN)

BO2=t3+(t4-t3)·F(Hop,NN)BO 2 =t 3 +(t 4 -t 3 )·F(Hop,NN)

F(Hop,NN)为一取值在[0,1]的函数,F(Hop,NN)与节点的跳数Hop成正比,与节点的邻居数量成反比。F(Hop, NN) is a function whose value is in [0, 1]. F(Hop, NN) is proportional to the hop number Hop of the node and inversely proportional to the number of neighbors of the node.

在一个实施方式中,F(Hop,NN)可以采用如下公式:In one embodiment, F(Hop, NN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&CenterDot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

在另一个实施方式中,F(HopNN)可以采用如下公式:In another embodiment, F(HopNN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令 in, ε is a random parameter with a value in [0,0.5]; and if order

值得注意的是,以上公式仅是对本发明中退避时间设置的示意性说明,但本发明不限于此,还可以根据实际情况采用适当的变形等,可以采用其他的公式。It is worth noting that the above formula is only a schematic illustration of the setting of the backoff time in the present invention, but the present invention is not limited thereto, and appropriate deformations may be adopted according to actual conditions, and other formulas may be used.

在本实施例中,退避时间的设置可以在该节点上进行,该设置方法还可以包括:将设置的退避时间发送给各个邻居节点,使得各个邻居节点分别存储对应的退避时间。In this embodiment, the backoff time may be set on the node, and the setting method may further include: sending the set backoff time to each neighbor node, so that each neighbor node stores the corresponding backoff time respectively.

此外,退避时间的设置还可以在各个邻居节点上进行,由各个邻居节点各自设置针对该节点的退避时间。以下以各个邻居节点各自设置针对该节点的退避时间为例进行说明。In addition, the setting of the backoff time can also be performed on each neighbor node, and each neighbor node sets the backoff time for the node respectively. In the following, each neighbor node sets the backoff time for the node as an example for illustration.

图11是本发明实施例的退避时间的设置方法的一示例图,以图3所示的场景为例,示出了第一组和第二组中均有邻居节点的情况。如图11所示,该设置方法包括:FIG. 11 is an example diagram of a method for setting backoff time according to an embodiment of the present invention. Taking the scene shown in FIG. 3 as an example, it shows the situation that there are neighbor nodes in both the first group and the second group. As shown in Figure 11, the setting method includes:

步骤1101,开始Hello过程。Step 1101, start the Hello process.

步骤1102,计算节点间的距离。Step 1102, calculate the distance between nodes.

具体地,可以使用Hello包中所包含的RSSI信息来计算节点间的距离,但本发明不限于此。Specifically, the distance between nodes can be calculated using the RSSI information included in the Hello packet, but the present invention is not limited thereto.

步骤1103,对于该节点的一邻居节点,判断该节点和该邻居节点的距离是否小于R/2;如果是则执行步骤1104;如果不是则执行步骤1105。Step 1103, for a neighbor node of the node, judge whether the distance between the node and the neighbor node is less than R/2; if yes, execute step 1104; if not, execute step 1105.

步骤1104,该邻居节点采用公式BO1=t1+(t2-t1)·F(Hop,NN)来设置退避时间。Step 1104, the neighbor node uses the formula BO 1 =t 1 +(t 2 −t 1 )·F(Hop,NN) to set the backoff time.

步骤1105,该邻居节点采用公式BO2=t3+(t4-t3)·F(Hop,NN)来设置退避时间。Step 1105, the neighbor node uses the formula BO 2 =t 3 +(t 4 -t 3 )·F(Hop,NN) to set the backoff time.

例如,在图3所示的场景中,邻居节点④⑤可以采用BO1=t1+(t2-t1)·F(Hop,NN)来设置针对节点①的退避时间。其中,F(Hop,NN)可以采用如下公式:For example, in the scenario shown in FIG. 3 , neighbor nodes ④⑤ can use BO 1 =t 1 +(t 2 −t 1 )·F(Hop,NN) to set the backoff time for node ①. Among them, F(Hop,NN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&CenterDot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

或者,F(Hop,NN)可以采用如下公式:Alternatively, F(Hop,NN) can use the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令Hop为节点④或⑤的跳数,NN为节点④或⑤的邻居数量。in, ε is a random parameter with a value in [0,0.5]; and if order Hop is the hop number of node ④ or ⑤, and NN is the number of neighbors of node ④ or ⑤.

而邻居节点②③⑥可以采用BO2=t3+(t4-t3)·F(Hop,NN)来设置针对节点①的退避时间。其中,F(Hop,NN)可以采用如下公式:The neighbor node ②③⑥ can use BO 2 =t 3 +(t 4 −t 3 )·F(Hop,NN) to set the backoff time for node ①. Among them, F(Hop,NN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

或者,F(Hop,NN)可以采用如下公式:Alternatively, F(Hop,NN) can use the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令Hop为节点②、③或者⑥的跳数,NN为节点②、③或者⑥的邻居数量。in, ε is a random parameter with a value in [0,0.5]; and if order Hop is the hop number of node ②, ③ or ⑥, and NN is the number of neighbors of node ②, ③ or ⑥.

图12是本发明实施例的退避时间的设置方法的另一示例图,以图3和图6所示的场景为例,示出了第一组中可能没有邻居节点的情况。如图12所示,该设置方法包括:FIG. 12 is another example diagram of the backoff time setting method according to the embodiment of the present invention. Taking the scenarios shown in FIG. 3 and FIG. 6 as examples, it shows that there may be no neighbor nodes in the first group. As shown in Figure 12, the setting method includes:

步骤1201,开始Hello过程。Step 1201, start the Hello process.

步骤1202,计算节点间的距离,并根据距离分为第一区域和第二区域。Step 1202, calculate the distance between nodes, and divide them into a first area and a second area according to the distance.

步骤1203,判断第一区域中是否存在邻居节点;如果没有邻居节点则执行步骤1205;如果存在邻居节点则执行步骤1204。Step 1203, judging whether there is a neighbor node in the first area; if there is no neighbor node, go to step 1205; if there is a neighbor node, go to step 1204.

步骤1204,该节点的邻居节点按照分组分别设置退避时间。Step 1204, the neighbor nodes of the node set the backoff time respectively according to the groups.

具体地,可以按照图11中的步骤1103至步骤1105来设置退避时间。Specifically, the backoff time may be set according to steps 1103 to 1105 in FIG. 11 .

步骤1205,该节点从邻居节点中选择一个节点,采用第一区域的公式来为该邻居节点设置退避时间,即采用BO1=t1+(t2-t1)·F(Hop,NN)。Step 1205, the node selects a node from the neighbor nodes, and uses the formula in the first area to set the backoff time for the neighbor node, that is, BO 1 =t 1 +(t 2 -t 1 )·F(Hop,NN) .

具体的,可以选择距离该节点最近的邻居节点;或者,当存在多个距离相同的邻居节点时,选择其中跳数最小的邻居节点;或者,当存在多个距离相同且多个跳数相同的邻居节点时,从其中随机选取一个邻居节点。Specifically, you can select the neighbor node closest to the node; or, when there are multiple neighbor nodes with the same distance, select the neighbor node with the smallest hop number; or, when there are multiple neighbor nodes with the same distance and the same number of hops When a neighbor node is selected, a neighbor node is randomly selected from it.

步骤1206,该节点将该退避时间发送给该选择的邻居节点。Step 1206, the node sends the backoff time to the selected neighbor node.

步骤1207,该选择的邻居节点接收到该退避时间后,将该退避时间存储在本地。Step 1207, after receiving the backoff time, the selected neighbor node stores the backoff time locally.

例如,在图6所示的场景中,节点①可以选择出一个邻居节点(例如节点②),然后节点①可以采用BO1=t1+(t2-t1)·F(Hop,NN)来设置节点②的退避时间。For example, in the scenario shown in Figure 6, node ① can select a neighbor node (such as node ②), and then node ① can adopt BO 1 =t 1 +(t 2 -t 1 )·F(Hop,NN) to set the backoff time of node ②.

其中,F(Hop,NN)可以采用如下公式:Among them, F(Hop,NN) can adopt the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

或者,F(Hop,NN)可以采用如下公式:Alternatively, F(Hop,NN) can use the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令Hop为节点②的跳数,NN为节点②的邻居数量。in, ε is a random parameter with a value in [0,0.5]; and if order Hop is the hop number of node ②, and NN is the number of neighbors of node ②.

然后,节点①可以将该退避时间发送给节点②,由节点②采用该接收到的退避时间替换掉之前自己计算的退避时间,将该更新后的退避时间存储在本地。Then, node ① can send the backoff time to node ②, and node ② replaces the previously calculated backoff time with the received backoff time, and stores the updated backoff time locally.

由上述实施例可知,通过将节点的多个邻居节点分为不同的组,并对不同组的邻居节点设置不同的退避时间。可以使得不同组的邻居节点的退避时间不会同时结束,保证根据退避时间倒计时的根节点为一个。It can be known from the above embodiments that by dividing multiple neighbor nodes of a node into different groups, and setting different backoff times for the neighbor nodes of different groups. It is possible to prevent the backoff time of neighboring nodes in different groups from ending at the same time, and ensure that there is only one root node counting down according to the backoff time.

实施例4Example 4

本发明实施例还提供一种网络节点,所述网络节点包括如实施例1所述的故障诊断装置。图13是本发明实施例的网络节点的一示意图,如图13所示,网络中可以具有多个网络节点1301、1302、1303等,一个或多个网络节点(例如网络节点1301)可以具有时间启动单元101、根节点确定单元102和诊断控制单元103。An embodiment of the present invention further provides a network node, where the network node includes the fault diagnosis device as described in Embodiment 1. Fig. 13 is a schematic diagram of a network node in an embodiment of the present invention. As shown in Fig. 13, there may be multiple network nodes 1301, 1302, 1303, etc. in the network, and one or more network nodes (such as network node 1301) may have time A startup unit 101 , a root node determination unit 102 and a diagnosis control unit 103 .

此外,作为变型例,本发明的故障诊断装置还可以是集中式的。图14是本发明实施例的网络节点的另一示意图,如图14所示,可以具有多个网络节点1301、1302、1303等。此外,网络中还可以具有故障诊断装置1304,该故障诊断装置1304具有时间启动单元101、根节点确定单元102和诊断控制单元103,对网络节点1301、1302、1303等进行控制,实现对网络节点的故障诊断。In addition, as a modification, the fault diagnosis device of the present invention may also be centralized. Fig. 14 is another schematic diagram of a network node according to an embodiment of the present invention. As shown in Fig. 14, there may be multiple network nodes 1301, 1302, 1303, and so on. In addition, there may also be a fault diagnosis device 1304 in the network. The fault diagnosis device 1304 has a time start unit 101, a root node determination unit 102, and a diagnosis control unit 103, and controls the network nodes 1301, 1302, 1303, etc. to realize the network node fault diagnosis.

本发明以上的装置和方法可以由硬件实现,也可以由硬件结合软件实现。本发明涉及这样的计算机可读程序,当该程序被逻辑部件所执行时,能够使该逻辑部件实现上文所述的装置或构成部件,或使该逻辑部件实现上文所述的各种方法或步骤。本发明还涉及用于存储以上程序的存储介质,如硬盘、磁盘、光盘、DVD、flash存储器等。The above devices and methods of the present invention can be implemented by hardware, or by combining hardware and software. The present invention relates to such a computer-readable program that, when the program is executed by a logic component, enables the logic component to realize the above-mentioned device or constituent component, or enables the logic component to realize the above-mentioned various methods or steps. The present invention also relates to a storage medium for storing the above program, such as hard disk, magnetic disk, optical disk, DVD, flash memory and the like.

以上结合具体的实施方式对本发明进行了描述,但本领域技术人员应该清楚,这些描述都是示例性的,并不是对本发明保护范围的限制。本领域技术人员可以根据本发明的精神和原理对本发明做出各种变型和修改,这些变型和修改也在本发明的范围内。The present invention has been described above in conjunction with specific embodiments, but those skilled in the art should be clear that these descriptions are all exemplary and not limiting the protection scope of the present invention. Those skilled in the art can make various variations and modifications to the present invention according to the spirit and principle of the present invention, and these variations and modifications are also within the scope of the present invention.

关于包括以上实施例的实施方式,还公开下述的附记:Regarding the implementation manner comprising the above embodiments, the following additional notes are also disclosed:

(附记1)一种故障诊断装置,所述故障诊断装置包括:(Additional Note 1) A fault diagnosis device, which includes:

时间启动单元,在怀疑节点需要诊断时,启动诊断节点针对所述怀疑节点的退避时间;A time starting unit, when the suspected node needs to be diagnosed, starts the backoff time of the diagnostic node for the suspected node;

根节点确定单元,根据对所述退避时间的倒计时来确定根节点;所述根节点为所述怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;The root node determination unit determines the root node according to the countdown of the back-off time; the root node is the diagnostic node whose back-off time ends first among the multiple diagnostic nodes of the suspected node;

诊断控制单元,控制所述根节点启动建立诊断树,并接收所述诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。The diagnosis control unit controls the root node to start establishing the diagnosis tree, receives the diagnosis information sent by the nodes in the diagnosis tree, and reports the diagnosis result to the gateway.

(附记2)根据附记1所述的故障诊断装置,其中,所述故障诊断装置还包括:(Supplement 2) The fault diagnosis device according to Supplement 1, wherein the fault diagnosis device further includes:

分组单元,将所述怀疑节点的多个邻居节点分为不同的组。A grouping unit, which divides the multiple neighbor nodes of the suspected node into different groups.

(附记3)根据附记2所述的故障诊断装置,其中,所述分组单元具体用于:根据通信距离将所述多个邻居节点分为第一组和第二组;(Supplementary Note 3) The fault diagnosis device according to Supplementary Note 2, wherein the grouping unit is specifically configured to: divide the plurality of neighboring nodes into a first group and a second group according to the communication distance;

所述第一组中的邻居节点与所述怀疑节点的通信距离小于或等于R/2,所述第二组中的邻居节点与所述怀疑节点的通信距离大于R/2;其中,所述R为所述怀疑节点的通信范围。The communication distance between the neighbor nodes in the first group and the suspect node is less than or equal to R/2, and the communication distance between the neighbor nodes in the second group and the suspect node is greater than R/2; wherein, the R is the communication range of the suspected node.

(附记4)根据附记1至3任一项所述的故障诊断装置,其中,所述故障诊断装置还包括:(Supplement 4) The fault diagnosis device according to any one of Supplements 1 to 3, wherein the fault diagnosis device further includes:

时间设置单元,根据将所述怀疑节点的多个邻居节点分成的不同的组来设置所述退避时间;其中,不同的组的退避时间所形成的时间范围互不重叠。The time setting unit is configured to set the back-off time according to the different groups into which the multiple neighbor nodes of the suspected node are divided; wherein, the time ranges formed by the back-off times of different groups do not overlap with each other.

(附记5)根据附记4所述的故障诊断装置,其中,所述时间设置单元采用如下规则设置退避时间:(Supplementary Note 5) The fault diagnosis device according to Supplementary Note 4, wherein the time setting unit adopts the following rule to set the backoff time:

t0≤t1≤BO1≤t2<t3≤BO2≤t4 t 0 ≤t 1 ≤BO 1 ≤t 2 <t 3 ≤BO 2 ≤t 4

其中,BO1是为所述第一组的邻居节点设置的退避时间,BO2是为所述第二组的邻居节点设置的退避时间;t1、t2、t3、t4是预定的时间,t0为所述诊断节点检测到所述怀疑节点故障的时刻。Wherein, BO 1 is the backoff time set for the first group of neighbor nodes, BO 2 is the backoff time set for the second group of neighbor nodes; t 1 , t 2 , t 3 , t 4 are predetermined Time, t 0 is the moment when the diagnostic node detects the suspected node failure.

(附记6)根据附记5所述的故障诊断装置,其中,(Supplementary Note 6) The fault diagnosis device according to Supplementary Note 5, wherein,

BO1=t1+(t2-t1)·F(Hop,NN)BO 1 =t 1 +(t 2 -t 1 )·F(Hop,NN)

BO2=t3+(t4-t3)·F(Hop,NN)BO 2 =t 3 +(t 4 -t 3 )·F(Hop,NN)

F(Hop,NN)为一取值在[0,1]的函数,所述F(Hop,NN)与节点的跳数Hop成正比,与节点的邻居数量成反比。F(Hop, NN) is a function whose value is in [0, 1]. The F(Hop, NN) is proportional to the hop number Hop of the node and inversely proportional to the number of neighbors of the node.

(附记7)根据附记6所述的故障诊断装置,其中,所述F(Hop,NN)采用如下公式:(Supplementary Note 7) The fault diagnosis device according to Supplementary Note 6, wherein the F(Hop, NN) adopts the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&CenterDot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

(附记8)根据附记6所述的故障诊断装置,其中,所述F(Hop,NN)采用如下公式:(Supplementary Note 8) The fault diagnosis device according to Supplementary Note 6, wherein the F(Hop, NN) adopts the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令 in, ε is a random parameter with a value in [0,0.5]; and if order

(附记9)根据附记3所述的故障诊断装置,其中,所述故障诊断装置还包括:(Supplementary note 9) The fault diagnosis device according to supplementary note 3, wherein the fault diagnosis device further includes:

节点选择单元,在所述第一组的邻居节点为空时,从第二组中挑选一个邻居节点作为所述第一组的邻居节点;并且,为选择出的所述邻居节点设置对应所述第一组的退避时间。The node selection unit selects a neighbor node from the second group as the neighbor node of the first group when the neighbor node of the first group is empty; and sets the corresponding neighbor node for the selected neighbor node. The backoff time of the first group.

(附记10)根据附记9所述的故障诊断装置,其中,所述节点选择单元选择距离所述怀疑节点最近的邻居节点;(Supplementary Note 10) The fault diagnosis device according to Supplementary Note 9, wherein the node selection unit selects a neighbor node closest to the suspected node;

或者,当存在多个距离相同的邻居节点时,所述节点选择单元选择其中跳数最小的邻居节点;Or, when there are multiple neighbor nodes with the same distance, the node selection unit selects the neighbor node with the smallest hop count;

或者,当存在多个距离相同且多个跳数相同的邻居节点时,所述节点选择单元从其中随机选取一个邻居节点。Or, when there are multiple neighbor nodes with the same distance and multiple hops, the node selection unit randomly selects a neighbor node from among them.

(附记11)根据附记9或10所述的故障诊断装置,其中,所述故障诊断装置还包括:(Supplement 11) The fault diagnosis device according to Supplement 9 or 10, wherein the fault diagnosis device further includes:

时间发送单元,将设置的退避时间发送给所述邻居节点,使得所述邻居节点存储并使用所述退避时间。The time sending unit is configured to send the set backoff time to the neighbor node, so that the neighbor node stores and uses the backoff time.

(附记12)根据附记1所述的故障诊断装置,其中,所述时间启动单元具体用于在所述诊断节点没有从所述怀疑节点连续收到多个Hello包时,启动所述退避时间开始倒计时,并将该怀疑节点存储在本地作为本地怀疑节点。(Supplementary Note 12) The fault diagnosis device according to Supplementary Note 1, wherein the time start unit is specifically configured to start the backoff when the diagnosis node does not receive multiple Hello packets from the suspect node continuously The time starts counting down, and the suspect node is stored locally as a local suspect node.

(附记13)根据附记12所述的故障诊断装置,其中,所述诊断控制单元还用于控制所述根节点广播检测包;使得其他诊断节点在退避时间倒计时未结束且收到所述检测包时,不再进行退避时间的倒计时。(Supplementary Note 13) The fault diagnosis device according to Supplementary Note 12, wherein the diagnostic control unit is further configured to control the root node to broadcast a detection packet; so that other diagnostic nodes receive the When detecting packets, the countdown of the backoff time is no longer performed.

(附记14)根据附记13所述的故障诊断装置,其中,所述检测包包括源地址、所述怀疑节点的标识信息、以及所述根节点的标识信息。(Supplementary Note 14) The fault diagnosis device according to Supplementary Note 13, wherein the detection packet includes a source address, identification information of the suspected node, and identification information of the root node.

(附记15)一种故障诊断方法,所述故障诊断方法包括:(Additional Note 15) A fault diagnosis method, the fault diagnosis method comprising:

在怀疑节点需要诊断时,启动诊断节点针对所述怀疑节点的退避时间;When the suspected node needs to be diagnosed, start the backoff time of the diagnosed node for the suspected node;

根据对所述退避时间的倒计时来确定根节点;所述根节点为所述怀疑节点的多个诊断节点中退避时间最先结束的诊断节点;Determine the root node according to the countdown to the backoff time; the root node is the diagnostic node whose backoff time ends first among the plurality of diagnostic nodes of the suspect node;

控制所述根节点启动建立诊断树,并接收所述诊断树中的节点发送的诊断信息,以及将诊断结果上报给网关。Controlling the root node to start establishing a diagnosis tree, receiving diagnosis information sent by nodes in the diagnosis tree, and reporting a diagnosis result to the gateway.

(附记16)根据附记15所述的故障诊断方法,其中,所述故障诊断方法还包括:(Supplement 16) The fault diagnosis method according to Supplement 15, wherein the fault diagnosis method further includes:

将所述怀疑节点的多个邻居节点分为不同的组,并对不同组的邻居节点设置不同的退避时间。Divide multiple neighbor nodes of the suspected node into different groups, and set different backoff times for different groups of neighbor nodes.

(附记17)根据附记16所述的故障诊断方法,其中,将所述诊断节点的多个邻居节点分为不同的组具体包括:(Supplementary Note 17) The fault diagnosis method according to Supplementary Note 16, wherein dividing the plurality of neighbor nodes of the diagnosis node into different groups specifically includes:

根据通信距离将所述多个邻居节点分为第一组和第二组;所述第一组中的邻居节点与所述怀疑节点的通信距离小于或等于R/2,所述第二组中的邻居节点与所述怀疑节点的通信距离大于R/2;其中,所述R为所述怀疑节点的通信范围。Divide the multiple neighbor nodes into a first group and a second group according to the communication distance; the communication distance between the neighbor nodes in the first group and the suspected node is less than or equal to R/2, and in the second group The communication distance between the neighbor node and the suspected node is greater than R/2; wherein, the R is the communication range of the suspected node.

(附记18)根据附记17所述的故障诊断方法,其中,所述故障诊断方法还包括:(Supplement 18) The fault diagnosis method according to Supplement 17, wherein the fault diagnosis method further includes:

在所有的邻居节点与所述怀疑节点的距离全都大于R/2时,挑选一个邻居节点作为所述第一组的邻居节点。When all the distances between the neighbor nodes and the suspected node are greater than R/2, select a neighbor node as the neighbor node of the first group.

(附记19)根据附记18所述的故障诊断方法,其中,挑选一个邻居节点作为所述第一组的邻居节点具体包括:(Supplementary Note 19) The fault diagnosis method according to Supplementary Note 18, wherein selecting a neighbor node as the neighbor node of the first group specifically includes:

选择距离所述怀疑节点最近的邻居节点;Select the nearest neighbor node from the suspected node;

或者,当存在多个距离相同的邻居节点时,选择其中跳数最小的邻居节点;Or, when there are multiple neighbor nodes with the same distance, select the neighbor node with the smallest hop count;

或者,当存在多个距离相同且多个跳数相同的邻居节点时,从其中随机选取一个邻居节点。Or, when there are multiple neighbor nodes with the same distance and multiple hops, a neighbor node is randomly selected from them.

(附记20)根据附记18或19所述的故障诊断方法,其中,所述故障诊断方法还包括:(Supplement 20) The fault diagnosis method according to Supplement 18 or 19, wherein the fault diagnosis method further includes:

将设置的退避时间发送给所述邻居节点,使得所述邻居节点存储并使用所述退避时间。Sending the set backoff time to the neighbor node, so that the neighbor node stores and uses the backoff time.

(附记21)根据附记15所述的故障诊断方法,其中,在怀疑节点需要诊断时,启动诊断节点针对所述怀疑节点的退避时间具体包括:(Supplementary Note 21) The fault diagnosis method according to Supplementary Note 15, wherein when the suspected node needs to be diagnosed, starting the backoff time of the diagnostic node for the suspected node specifically includes:

在所述诊断节点没有从所述怀疑节点连续收到多个Hello包时,启动所述退避时间开始倒计时,并将该怀疑节点存储在本地作为本地怀疑节点。When the diagnostic node does not continuously receive multiple Hello packets from the suspect node, start the countdown of the backoff time, and store the suspect node locally as a local suspect node.

(附记22)根据附记21所述的故障诊断方法,其中,所述故障诊断方法还包括:(Supplement 22) The fault diagnosis method according to Supplement 21, wherein the fault diagnosis method further includes:

控制所述根节点广播检测包;使得其他诊断节点在退避时间倒计时未结束且收到所述检测包时,不再进行退避时间的倒计时。Controlling the root node to broadcast a detection packet; so that when the countdown of the backoff time is not over and the other diagnostic nodes receive the detection packet, the countdown of the backoff time is no longer performed.

(附记23)根据附记22所述的故障诊断方法,其中,所述检测包包括源地址、所述怀疑节点的标识信息、以及所述根节点的标识信息。(Supplementary Note 23) The fault diagnosis method according to Supplementary Note 22, wherein the detection packet includes a source address, identification information of the suspected node, and identification information of the root node.

(附记24)根据附记22所述的故障诊断方法,其中,所述故障诊断方法还包括:(Supplementary Note 24) The fault diagnosis method according to Supplementary Note 22, wherein the fault diagnosis method further includes:

当某一个诊断节点收到所述检测包后,如果发现所述检测包的怀疑节点的标识信息和本地存储的本地怀疑节点相同,则将所述检测包的源地址改为所述诊断节点自己的地址,然后继续广播所述检测包;After a certain diagnostic node receives the detection packet, if it is found that the identification information of the suspected node in the detection packet is the same as the local suspected node stored locally, then the source address of the detection packet is changed to the diagnostic node itself address, and then continue to broadcast the detection packet;

如果发现所述检测包的怀疑节点的标识信息和本地邻居表中的某个邻居节点相同,则继续广播所述检测包;If it is found that the identification information of the suspected node of the detection packet is the same as a certain neighbor node in the local neighbor table, then continue to broadcast the detection packet;

如果发现所述检测包的怀疑节点的标识信息不在本地邻居表内,则不广播所述检测包。If it is found that the identification information of the suspected node of the detection packet is not in the local neighbor table, the detection packet is not broadcast.

(附记25)一种退避时间的设置方法,所述设置方法包括:(Supplementary note 25) A method for setting back-off time, the setting method comprising:

将节点的多个邻居节点分为不同的组;Divide multiple neighbor nodes of a node into different groups;

对不同组的邻居节点设置不同的退避时间,其中不同的组的退避时间所形成的时间范围互不重叠。Different back-off times are set for different groups of neighbor nodes, and the time ranges formed by the back-off times of different groups do not overlap each other.

(附记26)根据附记25所述的设置方法,其中,将节点的多个邻居节点分为不同的组具体包括:根据通信距离将所述多个邻居节点分为多个不同的组。(Supplementary Note 26) The setting method according to Supplementary Note 25, wherein dividing the multiple neighboring nodes of the node into different groups specifically includes: dividing the multiple neighboring nodes into multiple different groups according to the communication distance.

(附记27)根据附记26所述的设置方法,其中,根据通信距离将所述多个邻居节点分为第一组和第二组,所述第一组中的邻居节点与所述节点的通信距离小于或等于R/2,所述第二组中的邻居节点与所述节点的通信距离大于R/2;其中,所述R为所述节点的通信范围。(Supplementary Note 27) The setting method according to Supplementary Note 26, wherein the multiple neighbor nodes are divided into a first group and a second group according to the communication distance, and the neighbor nodes in the first group and the node The communication distance is less than or equal to R/2, and the communication distance between the neighbor nodes in the second group and the node is greater than R/2; wherein, the R is the communication range of the node.

(附记28)根据附记25至27任一项所述的设置方法,其中,采用如下规则设置退避时间:t0≤t1≤BO1≤t2<t3≤BO2≤t4(Supplementary Note 28) The setting method according to any one of Supplementary Notes 25 to 27, wherein the following rule is used to set the backoff time: t 0 ≤t 1 ≤BO 1 ≤t 2 <t 3 ≤BO 2 ≤t 4 ;

其中,BO1是为第一组的邻居节点设置的退避时间,BO2是为第二组的邻居节点设置的退避时间;t1、t2、t3、t4是预定的时间。Among them, BO 1 is the backoff time set for the first group of neighbor nodes, BO 2 is the backoff time set for the second group of neighbor nodes; t 1 , t 2 , t 3 , t 4 are predetermined times.

(附记29)根据附记28所述的设置方法,其中,(Supplementary Note 29) The setting method according to Supplementary Note 28, wherein,

BO1=t1+(t2-t1)·F(Hop,NN)BO 1 =t 1 +(t 2 -t 1 )·F(Hop,NN)

BO2=t3+(t4-t3)·F(Hop,NN)BO 2 =t 3 +(t 4 -t 3 )·F(Hop,NN)

F(Hop,NN)为一取值在[0,1]的函数,所述F(Hop,NN)与节点的跳数Hop成正比,与节点的邻居数量成反比。F(Hop, NN) is a function whose value is in [0, 1]. The F(Hop, NN) is proportional to the hop number Hop of the node and inversely proportional to the number of neighbors of the node.

(附记30)根据附记29所述的设置方法,其中,所述F(Hop,NN)采用如下公式:(Supplementary Note 30) The setting method according to Supplementary Note 29, wherein the F(Hop, NN) adopts the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; arctgarctg (( HopHop NNNN )) ++ &epsiv;&epsiv;

其中,ε为取值在[0,0.5]的随机参数。in, ε is a random parameter with a value in [0,0.5].

(附记31)根据附记29所述的设置方法,其中,所述F(Hop,NN)采用如下公式:(Supplementary Note 31) The setting method according to Supplementary Note 29, wherein the F(Hop, NN) adopts the following formula:

Ff (( HopHop ,, NNNN )) == &alpha;&alpha; &CenterDot;&Center Dot; (( sinsin (( HopHop NNNN )) ++ 11 )) ++ &epsiv;&epsiv;

或者, F ( Hop , NN ) = &alpha; &CenterDot; ( cos ( Hop NN ) + 1 ) + &epsiv; or, f ( Hop , NN ) = &alpha; &Center Dot; ( cos ( Hop NN ) + 1 ) + &epsiv;

其中,ε为取值在[0,0.5]的随机参数;并且如果则令 in, ε is a random parameter with a value in [0,0.5]; and if order

(附记32)根据附记27所述的设置方法,其中,所述故设置方法还包括:(Supplementary Note 32) The setting method according to Supplementary Note 27, wherein the said setting method further includes:

在所有的邻居节点与所述节点的距离全都大于R/2时,挑选一个邻居节点作为所述第一组的邻居节点。When all the distances between the neighbor nodes and the node are greater than R/2, select a neighbor node as the neighbor node of the first group.

(附记33)一种网络节点,所述网络节点包括如附记1至14任一项所述的故障诊断装置。(Supplementary Note 33) A network node, including the fault diagnosis device according to any one of Supplementary Notes 1 to 14.

(附记34)一种计算机可读程序,其中当在网络节点中执行所述程序时,所述程序使得计算机在所述网络节点中执行如附记15至24中任一项所述的故障诊断方法,或者如附记25至31任一项所述的退避时间的设置方法。(Supplementary Note 34) A computer-readable program, wherein, when the program is executed in a network node, the program causes a computer to execute the fault described in any one of Supplementary Notes 15 to 24 in the network node. Diagnosis method, or the setting method of backoff time as described in any one of Supplementary Notes 25 to 31.

(附记35)一种存储有计算机可读程序的存储介质,其中所述计算机可读程序使得计算机在网络节点中执行如附记15至24中任一项所述的故障诊断方法,或者如附记25至31任一项所述的退避时间的设置方法。(Supplementary Note 35) A storage medium storing a computer-readable program, wherein the computer-readable program causes a computer to execute the fault diagnosis method described in any one of Supplementary Notes 15 to 24 in a network node, or as described in The method for setting the backoff time described in any one of Supplementary Notes 25 to 31.

Claims (15)

1. A failure diagnosis device, comprising:
the time starting unit is used for starting the back-off time of the diagnosis node aiming at the doubtful node when the doubtful node needs to be diagnosed; wherein the back-off time is set by grouping a plurality of neighbor nodes of the suspect node into different groups;
a root node determination unit configured to determine a root node from the countdown of the back-off time; the root node is a diagnosis node with the first end of the back-off time in a plurality of diagnosis nodes of the suspect node;
and the diagnosis control unit controls the root node to start building a diagnosis tree, receives diagnosis information sent by the nodes in the diagnosis tree and reports a diagnosis result to the gateway.
2. The fault diagnosis device according to claim 1, wherein the fault diagnosis device further includes:
and the grouping unit is used for dividing the plurality of neighbor nodes of the suspected node into a plurality of different groups according to the communication distance.
3. The failure diagnosis apparatus according to claim 2, wherein the grouping unit groups a plurality of neighbor nodes of the suspect node into a first group and a second group according to communication distances;
the communication distance between the neighbor nodes in the first group and the suspected node is less than or equal to R/2, and the communication distance between the neighbor nodes in the second group and the suspected node is greater than R/2; wherein the R is the communication range of the suspected node.
4. The fault diagnosis device according to any one of claims 1 to 3, wherein the fault diagnosis device further includes:
and the time setting unit is used for setting the back-off time according to different groups, wherein the time ranges formed by the back-off times of the different groups are not overlapped with each other.
5. The fault diagnosis device according to claim 4, wherein the time setting unit sets the back-off time using the following rule:
t0≤t1≤BO1≤t2<t3≤BO2≤t4
wherein, BO1Is a back-off time, BO, set for the neighbor nodes of the first group2Is a back-off time set for a neighbor node of the second group; t is t1、t2、t3、t4Is a predetermined time, t0The moment when the suspected node fault is detected for the diagnostic node.
6. The failure diagnostic device according to claim 5,
BO1=t1+(t2-t1)·F(Hop,NN)
BO2=t3+(t4-t3)·F(Hop,NN)
f (Hop, NN) is a function with a value of [0,1], and is in direct proportion to Hop count Hop of a node and in inverse proportion to the number NN of neighbors of the node.
7. The fault diagnosis device according to claim 3, wherein the fault diagnosis device further includes:
a node selecting unit, selecting a neighbor node from the second group as a neighbor node of the first group when the neighbor node of the first group is empty; and setting back-off time corresponding to the first group for the selected neighbor node.
8. The fault diagnosis device according to claim 7, wherein the fault diagnosis device further includes:
and the time sending unit is used for sending the back-off time to the selected neighbor node so that the neighbor node stores and uses the back-off time.
9. The failure diagnosis apparatus according to claim 1, wherein the diagnosis control unit is further configured to control the root node to broadcast a detection packet; and when the back-off time counting down is not finished and the detection packet is received, other diagnosis nodes do not count down the back-off time any more.
10. A fault diagnosis method, comprising:
when a suspected node needs to be diagnosed, starting the back-off time of the suspected node by a diagnosis node; wherein the back-off time is set by grouping a plurality of neighbor nodes of the suspect node into different groups;
determining a root node according to the back-off time countdown; the root node is a diagnosis node with the first end of the back-off time in a plurality of diagnosis nodes of the suspect node;
and controlling the root node to start building a diagnosis tree, receiving diagnosis information sent by the nodes in the diagnosis tree, and reporting a diagnosis result to a gateway.
11. A method of setting a back-off time, the method comprising:
dividing a plurality of neighbor nodes of a node into different groups;
different back-off times are set for the neighbor nodes of different groups, wherein the time ranges formed by the back-off times of different groups are not overlapped with each other.
12. The provisioning method of claim 11, wherein grouping a plurality of neighbor nodes of a node into different groups includes: a plurality of neighbor nodes of the node are divided into a plurality of different groups according to the communication distance.
13. The provisioning method of claim 12, wherein the plurality of neighbor nodes are grouped into a first group and a second group according to communication distance;
the communication distance between the neighbor node in the first group and the node is less than or equal to R/2, and the communication distance between the neighbor node in the second group and the node is greater than R/2; wherein, the R is the communication range of the node.
14. The setting method according to any one of claims 11 to 13, wherein the back-off time is set using the following rule:
t0≤t1≤BO1≤t2<t3≤BO2≤t4
wherein, BO1Is a back-off time, BO, set for the neighbor nodes of the first group2Is a back-off time set for a neighbor node of the second group; t is t1、t2、t3、t4Is a predetermined time; t is t0To diagnose the moment when a node failure is detected by the node.
15. The setting method as recited in claim 14,
BO1=t1+(t2-t1)·F(Hop,NN)
BO2=t3+(t4-t3)·F(Hop,NN)
f (Hop, NN) is a function with a value of [0,1], and is in direct proportion to Hop count Hop of a node and in inverse proportion to the number of neighbors of the node.
CN201310149266.8A 2013-04-26 2013-04-26 Fault diagnosis device and method thereof and setting method of back-off time Pending CN104125108A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201310149266.8A CN104125108A (en) 2013-04-26 2013-04-26 Fault diagnosis device and method thereof and setting method of back-off time
JP2014088201A JP2014217063A (en) 2013-04-26 2014-04-22 Fault diagnostic device and metho, and setting method for backoff time

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310149266.8A CN104125108A (en) 2013-04-26 2013-04-26 Fault diagnosis device and method thereof and setting method of back-off time

Publications (1)

Publication Number Publication Date
CN104125108A true CN104125108A (en) 2014-10-29

Family

ID=51770378

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310149266.8A Pending CN104125108A (en) 2013-04-26 2013-04-26 Fault diagnosis device and method thereof and setting method of back-off time

Country Status (2)

Country Link
JP (1) JP2014217063A (en)
CN (1) CN104125108A (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101931370B1 (en) * 2016-11-07 2019-03-13 한림대학교 산학협력단 Method and apparatus for controlling group based concurrent transmission in visible light communication system
CN111224840A (en) * 2019-12-31 2020-06-02 江苏南高智能装备创新中心有限公司 Gateway system with fault diagnosis performance and method thereof
JP7453579B2 (en) * 2022-08-30 2024-03-21 ダイキン工業株式会社 Communication methods, refrigeration and air conditioning related systems, and communication nodes

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6499117B1 (en) * 1999-01-14 2002-12-24 Nec Corporation Network fault information management system in which fault nodes are displayed in tree form
CN1665205A (en) * 2004-01-30 2005-09-07 微软公司 Fault detection and diagnosis
CN101291296A (en) * 2008-06-20 2008-10-22 清华大学 A Method of Reducing Media Access Conflicts in Wireless Local Area Networks Through Cross-Layer Structure
CN101690010A (en) * 2007-04-13 2010-03-31 Hart通信基金会 Synchronizing time slots in wireless communication protocols
CN101860564A (en) * 2010-04-22 2010-10-13 北京航空航天大学 Protocol-based service composition system and method
US20110015494A1 (en) * 2009-07-15 2011-01-20 Microscopes International, Llc Home healthcare management system and hardware

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3539338B2 (en) * 2000-03-23 2004-07-07 日本電気株式会社 Priority data transfer method
US20030079011A1 (en) * 2001-10-23 2003-04-24 Schilling Cynthia K. System and method for displaying network status in a network topology
JP4185424B2 (en) * 2003-09-09 2008-11-26 株式会社エヌ・ティ・ティ・ドコモ Communication control method and communication terminal
JP4294620B2 (en) * 2005-07-21 2009-07-15 日本電信電話株式会社 RADIO COMMUNICATION TERMINAL, RADIO BASE STATION DEVICE, RADIO COMMUNICATION SYSTEM, RADIO COMMUNICATION METHOD, COMPUTER PROGRAM, AND RECORDING MEDIUM THEREOF
JP4641245B2 (en) * 2005-10-26 2011-03-02 三菱電機株式会社 Ad hoc network system, wireless ad hoc terminal and failure detection method thereof
JP5340475B2 (en) * 2010-03-03 2013-11-13 三菱電機株式会社 Communication control device and communication control method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6499117B1 (en) * 1999-01-14 2002-12-24 Nec Corporation Network fault information management system in which fault nodes are displayed in tree form
CN1665205A (en) * 2004-01-30 2005-09-07 微软公司 Fault detection and diagnosis
CN101690010A (en) * 2007-04-13 2010-03-31 Hart通信基金会 Synchronizing time slots in wireless communication protocols
CN101291296A (en) * 2008-06-20 2008-10-22 清华大学 A Method of Reducing Media Access Conflicts in Wireless Local Area Networks Through Cross-Layer Structure
US20110015494A1 (en) * 2009-07-15 2011-01-20 Microscopes International, Llc Home healthcare management system and hardware
CN101860564A (en) * 2010-04-22 2010-10-13 北京航空航天大学 Protocol-based service composition system and method

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
陈文钦 等: "基于故障树的知识存储及诊断系统", 《广西大学学报:自然科学版》 *
陈燕玲: "局域网故障诊断的仿真研究", 《计算机仿真》 *

Also Published As

Publication number Publication date
JP2014217063A (en) 2014-11-17

Similar Documents

Publication Publication Date Title
CN110191029B (en) Wired and wireless based hybrid dual-mode networking method
US8111684B2 (en) Path shortening in a wireless mesh network
US11146090B2 (en) Battery management system, and method and apparatus for transmitting information
US10779153B2 (en) Device to-device (D2D) discovery
CN108024230A (en) Resource selection method and equipment in a kind of V2X communications
US9246711B2 (en) Wireless mesh networking with multiple simultaneous transmissions by nearby network nodes
CN103004141B (en) Network loop detection method, equipment and system
CN101754319A (en) Routing method, routing device and routing system
US9167614B2 (en) Tunneled direct link setup systems and methods with consistent link information maintenance
WO2011091725A1 (en) Method and equipement for coordinating interference
WO2013152649A1 (en) Method and device for determining resource collision
CN109168172A (en) A kind of wireless hop of multinode ad hoc network keeps pouring in transmission method and device
CN102801596B (en) Service processing method for ring network and network equipment
US7953067B2 (en) Method, network apparatus, and tangible machine-readable medium thereof for detecting a looping network packet
CN104125108A (en) Fault diagnosis device and method thereof and setting method of back-off time
CN106105111B (en) A data transmission method and site
US20110069606A1 (en) Communication node and method of processing communication fault thereof
CN114501650B (en) Time slot resource allocation method, equipment and storage medium
US20150117257A1 (en) Slot assignment method and apparatus based on partition
CN102123011A (en) Medium access control (MAC) method and device of multirate cooperation
CN106685822A (en) Routing determination method and device thereof
CN102196512A (en) Accessing method for terminal, equipment and system
CN110401596B (en) Message transmission method and device, electronic equipment and readable storage medium
CN105813154A (en) Network layer switching control method and device
CN104683129B (en) Diagnostic tree establishment method, network fault diagnosis method and node thereof

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
AD01 Patent right deemed abandoned
AD01 Patent right deemed abandoned

Effective date of abandoning: 20180921