#include <aggregation.h>
List of all members.
Classes |
struct | messages_statistics |
Public Types |
enum | status_codes { RUNNING = 0,
WAITING = 1,
RECEIVING_VALUES = 2
} |
enum | node_roles { LEAF_NODE = 0,
NORMAL_NODE = 1,
INTERMEDIATE_NODE = 2,
SINK = 3
} |
typedef OsModel_P | OsModel |
typedef Radio_P | Radio |
typedef Debug_P | Debug |
typedef Cluster_P | Cluster |
typedef OsModel_P::Clock | Clock |
typedef OsModel_P::Timer | Timer |
typedef Aggregate_P | Aggregate_t |
typedef Aggregate_t::value_t | Aggregate_value_t |
typedef Routing_P | tree_routing_t |
typedef AggregateMsg< OsModel,
Radio > | msg_t |
typedef Radio::node_id_t | node_id_t |
typedef Radio::size_t | size_t |
typedef Radio::block_data_t | block_data_t |
typedef Radio::message_id_t | message_id_t |
typedef Clock::time_t | time_t |
typedef Radio::ExtendedData | ExData |
typedef Radio::TxPower | TxPower |
typedef Aggregation< OsModel_P,
Radio_P, Debug_P, Cluster_P,
Aggregate_P, Routing_P > | self_t |
typedef wiselib::vector_static
< OsModel, Aggregate_t, 10 > | aggregates_vector_t |
typedef
aggregates_vector_t::iterator | iterator_t |
typedef delegate4< void,
uint8_t, node_id_t, uint8_t,
uint8_t * > | event_notifier_delegate_t |
Public Member Functions |
| Aggregation () |
| Constructor.
|
| ~Aggregation () |
void | init (Radio &radio, Timer &timer, Clock &clock, Debug &debug, Cluster &cluster, tree_routing_t &tree) |
| Initialize the module.
|
void | enable () |
void | disable () |
void | init_aggregation () |
| Initializes the aggregation algorithm.
|
Aggregate_t | combine_aggregates (Aggregate_t agg1, Aggregate_t agg2) |
| Combines two aggregate value.
|
Aggregate_t | combine_all_aggregates () |
void | extract_aggregates () |
| Extracts the aggregate(s) value(s), used at the gateway (final destination node).
|
uint16_t | msgs_count () |
uint32_t | msgs_size () |
void | send (Aggregate_t aggregate) |
void | wait_for_chlds (void *data) |
void | set_role (uint8_t role) |
| Sets the role of the module.
|
Public Attributes |
TxPower | power |
aggregates_vector_t | aggregates_vector |
| Vector containing the aggregates that the node is going to combine.
|
template<typename OsModel_P, typename Radio_P, typename Debug_P, typename Cluster_P, typename Aggregate_P, typename Routing_P>
class wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >
Member Typedef Documentation
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
typedef Aggregation<OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P> wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::self_t |
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
Member Enumeration Documentation
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
- Enumerator:
LEAF_NODE |
the node is a leaf at the cluster
|
NORMAL_NODE |
normal node that just send and combines aggregates
|
INTERMEDIATE_NODE |
node that is responsible for collenting the aggregates at a local level
|
SINK |
The final destination that the intermediate nodes will send the aggregate vallues.
|
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
- Enumerator:
RUNNING |
|
WAITING |
|
RECEIVING_VALUES |
|
Constructor & Destructor Documentation
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
Member Function Documentation
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
Combines two aggregate value.
The specific function is implemented in the aggregation_base since the rest of the algorithm is independent.
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
void wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::disable |
( |
| ) |
[inline] |
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
void wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::enable |
( |
| ) |
[inline] |
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
void wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::extract_aggregates |
( |
| ) |
[inline] |
Extracts the aggregate(s) value(s), used at the gateway (final destination node).
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
void wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::init |
( |
Radio & |
radio, |
|
|
Timer & |
timer, |
|
|
Clock & |
clock, |
|
|
Debug & |
debug, |
|
|
Cluster & |
cluster, |
|
|
tree_routing_t & |
tree |
|
) |
| [inline] |
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
void wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::init_aggregation |
( |
| ) |
[inline] |
Initializes the aggregation algorithm.
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
Sets the role of the module.
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
void wiselib::Aggregation< OsModel_P, Radio_P, Debug_P, Cluster_P, Aggregate_P, Routing_P >::wait_for_chlds |
( |
void * |
data | ) |
[inline] |
Member Data Documentation
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
Vector containing the aggregates that the node is going to combine.
template<typename OsModel_P , typename Radio_P , typename Debug_P , typename Cluster_P , typename Aggregate_P , typename Routing_P >
The documentation for this class was generated from the following file: