BLE_GAP_SetChannelMap
C
uint16_t BLE_GAP_SetChannelMap(uint8_t *p_map);
Description
Sets local channel map.
Note
If not called, the status of all 37 channels defaults to unknown. The application should call this API within 10 seconds of determining that the channel classification has changed. There should be at least a one-second interval between successive calls. The BLE stack uses this channel map along with its own assessment. This API is only effective in the Central role.
Parameters
Parameter | Description |
---|---|
[in] p_map | 5-byte channel map array with 37 1-bit fields corresponding to the 37 data channels. A '0' indicates a bad channel, and a '1' indicates an unknown channel status. The most significant bits are reserved and must be set to 0. |
Return values
Return value | Description |
---|---|
MBA_RES_SUCCESS | Successfully sets the channel map. |
MBA_RES_OOM | Internal memory allocation failure occurred. |
MBA_RES_INVALID_PARA | Invalid parameters, such as setting bits corresponding to advertising channels (3 most significant bits of p_map). |