Steven Truong
Pointers API
1. main.c
1.1. main
Declaration
int main( int argc, const char* argv[] );
Returns the exit status. The main has an infinite loop that constantly calls demoApp_tick();.
Range:
There is no range.
2. demoApp.c
2.1. demoApp_init
Declaration
void demoApp_init();
Initialises the demoApp application.
Range:
There is no range.
2.2. BUTTONONE_Pressed
Declaration
unsigned char BUTTONONE_Pressed(void);
Returns true if button one has been pressed, false otherwise.
Range:
Returns int, 1 or 0.
2.3. BUTTONTWO_Pressed
Declaration
unsigned char BUTTONTWO_Pressed(void);
Returns true if button one has been pressed, false otherwise.
Range:
Returns int, 1 or 0.
2.4. BUTTONTHREE_Pressed
Declaration
unsigned char BUTTONTHREE_Pressed(void);
Returns true if button one has been pressed, false otherwise.
Range:
Returns int, 1 or 0.
2.5. sendToFriends
Declaration
void sendToFriends (Packet* pktPtr, int button);
Sets the values of pktPtr and sends the packet to neighbouring ProSpeckz devices.
Range:
Button must be between 1-4.
2.6. demoApp_tick
Declaration
void demoApp_tick();
Instantiates the pktPtr and declares which button to be sent to neighbouring devices.
Range:
There is no range.
2.7. demoApp_receivedPacketHandler
Declaration
void demoApp_receivedPacketHandler(Packet* rxPktPtr);
Declares what to do with a received packet. This is called in the MAC layer when a packet has been received. It also writes to the serial port, depending on the details in the packet.
Range:
There is no range.