diff options
author | Jim Mussared <jim.mussared@gmail.com> | 2020-11-25 00:06:16 +1100 |
---|---|---|
committer | Damien George <damien@micropython.org> | 2020-12-02 14:41:26 +1100 |
commit | 801e8ffacff0d2ed15e82136db2a8a45afbfab7b (patch) | |
tree | 1102e234887e533f7a1933e7dfd6f7a8e33e0bda /extmod/modbluetooth.h | |
parent | f822557cbb79decb6947e1e35b8cddce18f4c06f (diff) |
extmod/modbluetooth: Add gap_pair(conn_handle) func to intiate pairing.
Signed-off-by: Jim Mussared <jim.mussared@gmail.com>
Diffstat (limited to 'extmod/modbluetooth.h')
-rw-r--r-- | extmod/modbluetooth.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/extmod/modbluetooth.h b/extmod/modbluetooth.h index 977453bec..48e75d432 100644 --- a/extmod/modbluetooth.h +++ b/extmod/modbluetooth.h @@ -319,6 +319,11 @@ int mp_bluetooth_gap_disconnect(uint16_t conn_handle); int mp_bluetooth_get_preferred_mtu(void); int mp_bluetooth_set_preferred_mtu(uint16_t mtu); +#if MICROPY_PY_BLUETOOTH_ENABLE_PAIRING_BONDING +// Initiate pairing on the specified connection. +int mp_bluetooth_gap_pair(uint16_t conn_handle); +#endif // MICROPY_PY_BLUETOOTH_ENABLE_PAIRING_BONDING + #if MICROPY_PY_BLUETOOTH_ENABLE_CENTRAL_MODE // Start a discovery (scan). Set duration to zero to run continuously. int mp_bluetooth_gap_scan_start(int32_t duration_ms, int32_t interval_us, int32_t window_us, bool active_scan); |