Wiselib
Public Member Functions | Public Attributes
concepts::ClusterHeadDecision_concept Class Reference

Basic Concept for Cluster Head Decision Modules. More...

List of all members.

Public Member Functions

void init ()
 Initialize module and pass pointers to the os modules.
void set_parameter1 (uint8_t param1)
 Pass any parameters needed by the module.
bool is_cluster_head ()
 Returns if the node is a cluster head or not.
void reset ()
 Resets module to prepare it to run the algorithm.
bool calculate_head ()
 Depending on the algorithm described decides whether the node is a cluster head and returns the decision.
void receive (node_id_t from, size_t len, block_data_t *recvm)
 Receives a message and uses its data if addressed to CHD.
MsgType get_payload ()
 Generates a new payload to be sent from the CHD module.

Public Attributes

typedef OsModel
typedef Radio
typedef Debug
typedef self_type
typedef node_id_t
typedef size_t
typedef block_data_t
typedef cluster_id_t

Detailed Description

Basic Concept for Cluster Head Decision Modules.

The Cluster Head Decision Component (CHD) is used to elect cluster heads based on selected parameters given by the user. By examining many clustering algorithms we can identify some generic modules that use selected parameters to elect the cluster heads. Such modules can be the Probabilistic, the Identity Based , Energy Based , Node Connectivity and K-Attribute where one or more attributes like sensor readings are used find cluster heads.

As some algorithms elect cluster heads in an almost identical way, CHD modules can be easily reused for multiple algorithms.


Member Function Documentation

bool concepts::ClusterHeadDecision_concept::calculate_head ( )

Depending on the algorithm described decides whether the node is a cluster head and returns the decision.

MsgType concepts::ClusterHeadDecision_concept::get_payload ( )

Generates a new payload to be sent from the CHD module.

void concepts::ClusterHeadDecision_concept::init ( )

Initialize module and pass pointers to the os modules.

bool concepts::ClusterHeadDecision_concept::is_cluster_head ( )

Returns if the node is a cluster head or not.

void concepts::ClusterHeadDecision_concept::receive ( node_id_t  from,
size_t  len,
block_data_t recvm 
)

Receives a message and uses its data if addressed to CHD.

void concepts::ClusterHeadDecision_concept::reset ( )

Resets module to prepare it to run the algorithm.

void concepts::ClusterHeadDecision_concept::set_parameter1 ( uint8_t  param1)

Pass any parameters needed by the module.


Member Data Documentation


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines