This module implements the Peripheral GAP Role.
More...
This module implements the Peripheral GAP Role.
§ GAPRole_GetParameter()
bStatus_t GAPRole_GetParameter |
( |
uint16_t |
param, |
|
|
void * |
pValue |
|
) |
| |
Get a GAP Role parameter.
- Note
- The "pValue" field must point to a "uint16_t".
- Parameters
-
param | Peripheral GAPRole Parameters |
pValue | pointer to location to get the value. This is dependent on the parameter ID and WILL be cast to the appropriate data type (example: data type of uint16_t will be cast to uint16_t pointer). |
- Returns
- SUCCESS
-
INVALIDPARAMETER
§ GAPRole_RegisterAppCBs()
Register application's callbacks.
- Parameters
-
pParamUpdateCB | pointer to param update callback. |
§ GAPRole_SendUpdateParam()
bStatus_t GAPRole_SendUpdateParam |
( |
uint16_t |
minConnInterval, |
|
|
uint16_t |
maxConnInterval, |
|
|
uint16_t |
latency, |
|
|
uint16_t |
connTimeout, |
|
|
uint8_t |
handleFailure |
|
) |
| |
§ GAPRole_SetParameter()
bStatus_t GAPRole_SetParameter |
( |
uint16_t |
param, |
|
|
uint8_t |
len, |
|
|
void * |
pValue |
|
) |
| |
Set a GAP Role parameter.
- Note
- The "len" field must be set to the size of a "uint16_t" and the "pValue" field must point to a "uint16_t".
- Parameters
-
param | Peripheral GAPRole Parameters |
len | length of data to write |
pValue | pointer to data to write. This is dependent on the parameter ID and WILL be cast to the appropriate data type (example: data type of uint16_t will be cast to uint16_t pointer). |
- Returns
- SUCCESS
-
INVALIDPARAMETER
-
bleInvalidRange : len is invalid for the given param
-
blePending : previous param update has not been completed
-
bleIncorrectMode : can not start connectable advertising because nonconnectable advertising is enabled
§ GAPRole_StartDevice()
Initialize the GAP layer.
- Warning
- Only call this function once
- Parameters
-
pAppCallbacks | pointer to application callbacks. |
- Returns
- SUCCESS
-
bleAlreadyInRequestedMode : device was already initialized
§ GAPRole_TerminateConnection()
bStatus_t GAPRole_TerminateConnection |
( |
void |
| ) |
|