feat(ble): add behavior to disconnect from BLE profile
Adds new functionality and a behavior to disconnect an active BLE connection. The motivation for this is that for some devices like phones, the presence of an active BLE connection results in the onscreen keyboard being selected.
This commit is contained in:
parent
d7d9eed317
commit
0a4b1a6533
5 changed files with 41 additions and 6 deletions
|
|
@ -9,6 +9,7 @@
|
|||
#define BT_PRV_CMD 2
|
||||
#define BT_SEL_CMD 3
|
||||
// #define BT_FULL_RESET_CMD 4
|
||||
#define BT_DISC_CMD 5
|
||||
|
||||
/*
|
||||
Note: Some future commands will include additional parameters, so we
|
||||
|
|
@ -19,3 +20,4 @@ defines these aliases up front.
|
|||
#define BT_NXT BT_NXT_CMD 0
|
||||
#define BT_PRV BT_PRV_CMD 0
|
||||
#define BT_SEL BT_SEL_CMD
|
||||
#define BT_DISC BT_DISC_CMD
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ int zmk_ble_clear_bonds();
|
|||
int zmk_ble_prof_next();
|
||||
int zmk_ble_prof_prev();
|
||||
int zmk_ble_prof_select(uint8_t index);
|
||||
int zmk_ble_prof_disconnect(uint8_t index);
|
||||
|
||||
int zmk_ble_active_profile_index();
|
||||
bt_addr_le_t *zmk_ble_active_profile_addr();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue