BLE_GAP_SetScanRspData

C

uint16_t BLE_GAP_SetScanRspData(BLE_GAP_AdvDataParams_T *p_scanData);

Description

Sets scan response data.

Note

If advertising is currently enabled, the new data will be used in subsequent advertising events. If an advertising event is in progress when this command is issued, the new data may not be used for that event. This API is part of the legacy advertising feature and will be disallowed if any extended advertising feature API has been used prior to this call. See Categories of advertising APIs and events for details on advertising APIs. The BLE_GAP_AdvInit function must be called prior to using this API.

Parameters

ParameterDescription
[in] p_scanDataPointer to the structure containing scan response data to be set. See BLE_GAP_AdvDataParams_T.

Return values

Return valueDescription
MBA_RES_SUCCESSSuccessfully sets scan response data.
MBA_RES_OOMInternal memory allocation failure occurred.
MBA_RES_INVALID_PARAInvalid parameters. Scan response data length exceeds BLE_GAP_ADV_MAX_LENGTH.
MBA_RES_COMMAND_DISALLOWEDCommand disallowed when extended advertising feature is in use.