nhdp_metric.h File Reference

Macros for NHDP metric computation. More...

Detailed Description

Macros for NHDP metric computation.

The used infrastructure for exchanging metric values is based on the rules defined in the RFC of OLSRv2. The calculations for the Directional Airtime Metric (DAT) are based on DAT Draft v5.

Author
Fabian Nack nack@.nosp@m.inf..nosp@m.fu-be.nosp@m.rlin.nosp@m..de

Definition in file nhdp_metric.h.

#include "rfc5444/rfc5444.h"
+ Include dependency graph for nhdp_metric.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

NHDP protocol macros
#define NHDP_LMT_HOP_COUNT   (163)
 Hop Count metric extension value for metric TLV extension field.
 
#define NHDP_LMT_DAT   (165)
 DAT metric extension value for metric TLV extension field.
 
#define NHDP_METRIC   (NHDP_LMT_HOP_COUNT)
 Used metric (change to switch to another metric type)
 
#define NHDP_METRIC_TIMER   (5445)
 Randomly chosen number for NHDP's metric timer event.
 
#define NHDP_METRIC_NEEDS_TIMER   (NHDP_METRIC == NHDP_LMT_DAT)
 Macro controlling the start of a periodic timer event for matric computation.
 
#define NHDP_METRIC_UNKNOWN   (0)
 
#define NHDP_METRIC_MINIMUM   (RFC5444_METRIC_MIN)
 
#define NHDP_METRIC_MAXIMUM   (RFC5444_METRIC_MAX)
 
#define NHDP_Q_MEM_LENGTH   (64)
 Default queue size for metrics using a queue to determine link loss.
 
#define NHDP_SEQNO_RESTART_DETECT   (256)
 Restart detection value for packet sequence number based link loss computation.
 
#define NHDP_KD_LM_INC   (0x8000)
 Encoding for an incoming link metric value in metric TLV.
 
#define NHDP_KD_LM_OUT   (0x4000)
 Encoding for an outgoing link metric value in metric TLV.
 
#define NHDP_KD_NM_INC   (0x2000)
 Encoding for an incoming neighbor metric value in metric TLV.
 
#define NHDP_KD_NM_OUT   (0x1000)
 Encoding for an outgoing neighbor metric value in metric TLV.
 
DAT metric specific macros
#define DAT_MEMORY_LENGTH   (NHDP_Q_MEM_LENGTH)
 Length of RCVD and TOTAL queue of DAT metric.
 
#define DAT_REFRESH_INTERVAL   (1)
 Time between DAT metric refreshal.
 
#define DAT_HELLO_TIMEOUT_FACTOR   (1.2)
 Factor to spread HELLO interval.
 
#define DAT_MINIMUM_BITRATE   (1000)
 Minimal supported bit rate in bps (default value for new links)
 
#define DAT_MAXIMUM_LOSS   (8)
 Maximum allowed loss in expected/rcvd HELLOs (should not be changed)
 
#define DAT_CONSTANT   (16777216)
 Constant value needed for DAT metric computation (should not be changed)