controller.h File Reference

Description : prototypes of the functions used by controllercc2420.c. More...

#include <bite.h>

Include dependency graph for controller.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

char controller_read (void *frame, int *distance)
 Receive a frame.
int controller_read_alarm_frame (unsigned int *x, unsigned int *y)
 Read an alarm frame from the transmitter "x", "y".
char controller_write (void *frame, unsigned int size, char priority)
 Write a frame to the channel of communication.

Variables

UINT16 buffer_phy []


Detailed Description

Description : prototypes of the functions used by controllercc2420.c.

Definition in file controller.h.


Function Documentation

char controller_read ( void *  frame,
int *  distance 
)

Receive a frame.

Parameters:
[out] frame : Points to the buffer to receive data that is being read from the channel.
[out] distance : Mesure of the distance between this and the sender of the frame
Returns:
0 : Success.

"other" : Error.

Definition at line 94 of file controllerCC2420.c.

References buffer_phy, buffer_reprog, cc2420_powerdown(), CDISPLAY_INFO_MAC, CSERIAL_PUTCHAR_MAC, CSERIAL_PUTS_MAC, Flag_PT, nbytes, flag_execution::recep_coll, flag_execution::recep_notrans, flag_execution::recep_ok, flag_execution::recep_overflow, RecepFrame(), REVEIL, sendFrame(), flag_execution::trans_underflow, WAIT_100us, WAIT_DATA_AFTER_WB, and wakeup_cc2420().

Referenced by PT_THREAD().

Here is the call graph for this function:

Here is the caller graph for this function:

int controller_read_alarm_frame ( unsigned int *  x,
unsigned int *  y 
)

Read an alarm frame from the transmitter "x", "y".

Parameters:
[out] x : Points to the received transmitter identity.
[out] y : Points to the received transmitter identity.
Returns:
0 : Success.

1 : not awake trame

2 : size of packet invalid

3 : time out

Definition at line 196 of file controllerCC2420.c.

References buffer_phy, cc2420_powerdown(), CDISPLAY_NUMBER_MAC, CSERIAL_PUTS_MAC, info_Reveil::id_x, info_Reveil::id_y, nbytes, RANDMAX_WAKEUP_INTERVAL, RecepFrame(), REVEIL, TIME_BASE, flag_execution::trans_nowakeup, info_Reveil::type, wakeup_cc2420(), and wakeup_interval.

Referenced by check_online_code_version(), and PT_THREAD().

Here is the call graph for this function:

Here is the caller graph for this function:

char controller_write ( void *  frame,
unsigned int  size,
char  priority 
)

Write a frame to the channel of communication.

Parameters:
[in] frame : Points to the frame containing the data to be written to the channel.
[in] size : size of the frame in byte
[in] priority : indicate the priority of the frame
Returns:
0 : Success.

1 : Error.

Definition at line 264 of file controllerCC2420.c.

References cc2420_change_emission_power(), cc2420_powerdown(), CSERIAL_PUTS_MAC, HIGH_PRIORITY, NO_PRIORITY, sendFrame(), flag_execution::trans_coll, flag_execution::trans_ok, flag_execution::trans_underflow, WAIT_100us, and wakeup_cc2420().

Referenced by PT_THREAD().

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation


Generated on Wed Jun 3 12:05:43 2009 for PowWow v1.0 by  doxygen 1.5.6