![]() |
nRF Connect SDK Bare Metal API 2.0.99
|
| uint32_t pm_allow_list_set | ( | const uint16_t * | peers, |
| uint32_t | peer_cnt ) |
#include <peer_manager.h>
Set or clear the allow list.
To clear the current allow list, pass either NULL as peers or zero as peer_cnt.
| [in] | peers | The peers to add to the allow list. Pass NULL to clear the current allow list. |
| [in] | peer_cnt | The number of peers to add to the allow list. The number must not be greater than BLE_GAP_WHITELIST_ADDR_MAX_COUNT. Pass zero to clear the current allow list. |
| NRF_SUCCESS | If the allow list was successfully set or cleared. |
| BLE_ERROR_GAP_WHITELIST_IN_USE | If an allow list is already in use and cannot be set. |
| BLE_ERROR_GAP_INVALID_BLE_ADDR | If a peer in peers has an address that cannot be added to the allow list. |
| NRF_ERROR_NOT_FOUND | If any of the peers in peers cannot be found. |
| NRF_ERROR_DATA_SIZE | If peer_cnt is greater than BLE_GAP_WHITELIST_ADDR_MAX_COUNT. |
| NRF_ERROR_INVALID_STATE | If the Peer Manager is not initialized. |