nRF Connect SDK API 0.1.0
Loading...
Searching...
No Matches
le_pair_resp.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2023 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5 */
6
14#ifndef BT_MESH_LE_PAIR_RESP_H__
15#define BT_MESH_LE_PAIR_RESP_H__
16
17#ifdef __cplusplus
18extern "C" {
19#endif
20
21#include <zephyr/bluetooth/mesh/access.h>
22
23#define BT_MESH_VENDOR_COMPANY_ID_LE_PAIR_RESP 0x0059
24#define BT_MESH_MODEL_ID_LE_PAIR_RESP 0x000E
25
30#define BT_MESH_MODEL_LE_PAIR_RESP \
31 BT_MESH_MODEL_VND_CB(BT_MESH_VENDOR_COMPANY_ID_LE_PAIR_RESP, BT_MESH_MODEL_ID_LE_PAIR_RESP,\
32 _bt_mesh_le_pair_resp_op, NULL, NULL, \
33 &_bt_mesh_le_pair_resp_cb)
34
35/* @brief Invalidate previously used passkey.
36 *
37 * A user must call this function when a pairing request completes regardless of the status.
38 */
40
41/* @brief Set own passkey instead of using randomly generating passkeys.
42 *
43 * By default, passkeys will be randomly generated on every new request. This function allows to use
44 * pre-defined passkey instead.
45 *
46 * @params passkey Passkey to use for the pairing, or @ref BT_PASSKEY_INVALID to use randomly
47 * generated passkey again.
48 */
49void bt_mesh_le_pair_resp_passkey_set(uint32_t passkey);
50
53extern const struct bt_mesh_model_op _bt_mesh_le_pair_resp_op[];
54extern const struct bt_mesh_model_cb _bt_mesh_le_pair_resp_cb;
55
58#ifdef __cplusplus
59}
60#endif
61
62#endif /* BT_MESH_LE_PAIR_RESP_H__ */
63
void bt_mesh_le_pair_resp_passkey_invalidate(void)
void bt_mesh_le_pair_resp_passkey_set(uint32_t passkey)