Wiselib
|
Extension of Radio Concept. More...
Inherits concepts::Radio_concept.
Public Types | |
enum | SpecialNodeIds { BROADCAST_ADDRESS, NULL_NODE_ID } |
enum | Restrictions { MAX_MESSAGE_LENGTH } |
Public Member Functions | |
int | enable_radio () |
Turn on radio. | |
int | disable_radio () |
Turn off radio. | |
int | send (node_id_t receiver, size_t len, block_data_t *data) |
Send message of len units beginning at *data to given receiver. | |
node_id_t | id () |
Return id of node for current radio. | |
template<class T , void(T::*)(node_id_t, size_t, block_data_t *) TMethod> | |
int | reg_recv_callback (T *obj_pnt) |
Register message reception callback function. | |
int | unreg_recv_callback (int idx) |
Unregister message reception callback function - use unique identifier returned by registration. | |
Public Attributes | |
typedef | OsModel |
Type of Os Concept which has been set for the radio. | |
typedef | self_pointer_t |
Defines type of pointer to this radio. | |
typedef | node_id_t |
Type of node id - must be unique for a node in the network. | |
typedef | block_data_t |
Data type used for raw data in message sending process. | |
typedef | size_t |
Unsigned integer that represents length information. | |
typedef | message_id_t |
Type of message Ids - should be common for all radios if heterogeneity should be supported. |
Extension of Radio Concept.
enum concepts::Radio_concept::Restrictions [inherited] |
enum concepts::Radio_concept::SpecialNodeIds [inherited] |
int concepts::Radio_concept::disable_radio | ( | ) | [inherited] |
Turn off radio.
Messages can
not be sent and received.
Reimplemented in concepts::Routing_concept.
int concepts::Radio_concept::enable_radio | ( | ) | [inherited] |
Turn on radio.
Messages can be sent and received.
Reimplemented in concepts::Routing_concept.
node_id_t concepts::Radio_concept::id | ( | ) | [inherited] |
Return id of node for current radio.
This can just be the id provided by the Os, but also any other one for special models. For example, a virtual radio model providing IPv6 addresses.
int concepts::Radio_concept::reg_recv_callback | ( | T * | obj_pnt | ) | [inherited] |
Register message reception callback function.
Reimplemented in concepts::Routing_concept, and concepts::ExtendedDataRadio_concept.
int concepts::Radio_concept::send | ( | node_id_t | receiver, |
size_t | len, | ||
block_data_t * | data | ||
) | [inherited] |
Send message of len units beginning at *data to given receiver.
Reimplemented in concepts::Routing_concept.
int concepts::Radio_concept::unreg_recv_callback | ( | int | idx | ) | [inherited] |
Unregister message reception callback function - use unique identifier returned by registration.
Reimplemented in concepts::Routing_concept.
typedef concepts::Radio_concept::block_data_t [inherited] |
Data type used for raw data in message sending process.
Usually an\ uint8_t.
Reimplemented in concepts::Routing_concept.
typedef concepts::Radio_concept::message_id_t [inherited] |
Type of message Ids - should be common for all radios if heterogeneity should be supported.
Standard is unit16_t.
Reimplemented in concepts::Routing_concept.
typedef concepts::Radio_concept::node_id_t [inherited] |
Type of node id - must be unique for a node in the network.
Reimplemented in concepts::Routing_concept.
typedef concepts::Radio_concept::OsModel [inherited] |
Type of Os Concept which has been set for the radio.
Reimplemented in concepts::Routing_concept.
typedef concepts::Radio_concept::self_pointer_t [inherited] |
Defines type of pointer to this radio.
Reimplemented in concepts::Routing_concept.
typedef concepts::Radio_concept::size_t [inherited] |
Unsigned integer that represents length information.
Reimplemented in concepts::Routing_concept.