![]() |
nRF Connect SDK Bare Metal API 2.0.99
|
| uint32_t pm_peer_delete | ( | uint16_t | peer_id | ) |
#include <peer_manager.h>
Delete all data stored for a peer and free the peer ID.
This function deletes every piece of data that is associated with the specified peer and frees the peer ID to be used for another peer. The deletion happens asynchronously, and the peer ID is not freed until the data is deleted. When the operation finishes, a PM_EVT_PEER_DELETE_SUCCEEDED or PM_EVT_PEER_DELETE_FAILED event is sent.
| [in] | peer_id | Peer ID to be freed and have all associated data deleted. |
| NRF_SUCCESS | If the operation was initiated successfully. |
| NRF_ERROR_INVALID_PARAM | If the peer ID was not valid. |
| NRF_ERROR_INVALID_STATE | If the Peer Manager is not initialized. |