Microchip® Advanced Software Framework

appEngine_t2bf_atmel.h File Reference
#include "btypes.h"

Typedefs

typedef uint8 TAppEngineJoystick
 
typedef void TAppEnginePrintCb (TString textToDisplay)
 

Enumerations

enum  TAppEngineJoystickEnum {
  AppEngine_None,
  AppEngine_Left = 0x3C,
  AppEngine_Right = 0x3E,
  AppEngine_Up = 0x2B,
  AppEngine_Down = 0x2D,
  AppEngine_Push = 0x3D
}
 

Functions

void AppEngineConnectButton (void)
 Handles functionality coupled to press of the Connect button. More...
 
boolean AppEngineInit (TAppEnginePrintCb *pCb, TString deviceName)
 Initializes the Bluetooth functionality. More...
 
void AppEngineInquiryButton (void)
 Handles functionality coupled to press of the Inquiry button. More...
 
void AppEngineJoystickButton (TAppEngineJoystick joystick)
 Sends a letter for each direction on the joystick. More...
 
void AppEngineSelectDeviceButton (void)
 Handles functionality coupled to press of the Select button. More...
 

typedef void TAppEnginePrintCb(TString textToDisplay)

Enumerator
AppEngine_None 
AppEngine_Left 
AppEngine_Right 
AppEngine_Up 
AppEngine_Down 
AppEngine_Push 

void AppEngineConnectButton ( void  )

Handles functionality coupled to press of the Connect button.

Parameters
None
Return values
None

References AppEngine_Connected_State, AppEngine_Connecting_State, AppEngine_Disconnecting_State, AppEngine_Idle_State, AppEngineNotifyCallback(), myBdAddr, mySppPort, myState, NULL, T2BF_STATUS_OK, T2BFSppConnect(), and T2BFSppDisconnect().

Referenced by app_engine().

boolean AppEngineInit ( TAppEnginePrintCb pCb,
TString  deviceName 
)

Initializes the Bluetooth functionality.

Parameters
pCbPointer to callback function that shall receive events from t2BF
deviceNameSets the user friendly name that are used when this unit is discovered by others.
Return values
trueInitialization successful.
falseBaud rate set point is out of range for the given input clock frequency.

References AppEngine_Idle_State, AppEngineBtCb(), AppEngineNotifyCallback(), AppEngineSppCb(), myBdAddr, myName, mySppPort, myState, myStatus, NULL, pMyCb, T2BF_AUTO_AUTH_ALLOW, T2BF_LITE_COD, T2BF_SEC_LEVEL_2, T2BF_SEC_NORMAL, T2BF_STATUS_OK, T2BFAutoAuthentication(), T2BFDiscoverable(), T2BFInit(), T2BFSppCreatePort(), T2BFSppOpen(), T2BFStart(), T2BFWriteName(), T2BFWritePin(), UNISTR_CHARSET_ASCII, UNISTR_ENCODING_NONE, and UNISTRToUtf16().

Referenced by app_engine().

void AppEngineInquiryButton ( void  )
void AppEngineJoystickButton ( TAppEngineJoystick  joystick)

Sends a letter for each direction on the joystick.

Parameters
joystickIdentifies what direction the joystick has been pulled in.
Return values
None.

References AppEngine_Down, AppEngine_Left, AppEngine_Push, AppEngine_Right, AppEngine_Up, and AppEngineInternalSendData().

Referenced by app_engine().

void AppEngineSelectDeviceButton ( void  )

Handles functionality coupled to press of the Select button.

Parameters
None
Return values
None

References AppEngine_Idle_State, AppEngineNotifyCallback(), myBdAddr, myIndex, myState, pMyBdAddress, pMyName, and T2BFENG_MAX_NAME_LENGTH.

Referenced by app_engine().