Contiki-NG
|
Data Structures | |
struct | compower_activity |
An activity record that contains power consumption information for a specific communication activity. More... | |
Functions | |
void | compower_init (void) |
Initialize the communication power accounting module. | |
void | compower_accumulate (struct compower_activity *a) |
Accumulate power contumption for a communication activity. | |
void | compower_clear (struct compower_activity *a) |
Clear power consumption information for a communication activity. | |
Variables | |
struct compower_activity | compower_idle_activity |
The default idle communication activity. | |
struct compower_activity | compower_idle_activity |
The default idle communication activity. | |
The compower module accumulates power consumption information and attributes it to communication activities. Examples of communication activities are packet transmission, packet reception, and idle listening.
void compower_accumulate | ( | struct compower_activity * | a | ) |
Accumulate power contumption for a communication activity.
a | A pointer to an activity structure. This function accumulates power consumption information for a communication activity. The function typically is called by a power-saving MAC protocol when the radio is switched off, or when a packet is received or transmitted. |
Definition at line 60 of file compower.c.
void compower_clear | ( | struct compower_activity * | a | ) |
Clear power consumption information for a communication activity.
a | A pointer to an activity structure. This function clears any power contumption information that has previously been accumulated in an activity structure. |
Definition at line 77 of file compower.c.
Referenced by compower_init().
void compower_init | ( | void | ) |
Initialize the communication power accounting module.
This function initializes the communication power accounting module. The function is called by the system during boot-up.
Definition at line 54 of file compower.c.
References compower_clear(), and compower_idle_activity.
struct compower_activity compower_idle_activity |
The default idle communication activity.
This is the idle communication activity, to which all energy that is not possible to attribute to individual packets, is attributed. Examples include idle listening for incoming packets and MAC-level beacon transmissions.
Definition at line 50 of file compower.c.
Referenced by compower_init().
|
extern |
The default idle communication activity.
This is the idle communication activity, to which all energy that is not possible to attribute to individual packets, is attributed. Examples include idle listening for incoming packets and MAC-level beacon transmissions.
Definition at line 50 of file compower.c.
Referenced by compower_init().