| | |
| | | #define BLE_GAP_ROLE_MASTER 0 |
| | | #define BLE_GAP_ROLE_SLAVE 1 |
| | | |
| | | #define BLE_GAP_EVENT_CONNECT 0 |
| | | #define BLE_GAP_EVENT_DISCONNECT 1 |
| | | #define BLE_GAP_EVENT_CONNECT 0 /*!< connection complete event. */ |
| | | #define BLE_GAP_EVENT_DISCONNECT 1 /*!< disconnection complete event */ |
| | | /* Reserved 2 */ |
| | | #define BLE_GAP_EVENT_CONN_UPDATE 3 |
| | | #define BLE_GAP_EVENT_CONN_UPDATE_REQ 4 |
| | | #define BLE_GAP_EVENT_L2CAP_UPDATE_REQ 5 |
| | | #define BLE_GAP_EVENT_TERM_FAILURE 6 |
| | | #define BLE_GAP_EVENT_DISC 7 |
| | | #define BLE_GAP_EVENT_DISC_COMPLETE 8 |
| | | #define BLE_GAP_EVENT_ADV_COMPLETE 9 |
| | | #define BLE_GAP_EVENT_ENC_CHANGE 10 |
| | | #define BLE_GAP_EVENT_PASSKEY_ACTION 11 |
| | | #define BLE_GAP_EVENT_NOTIFY_RX 12 |
| | | #define BLE_GAP_EVENT_NOTIFY_TX 13 |
| | | #define BLE_GAP_EVENT_SUBSCRIBE 14 |
| | | #define BLE_GAP_EVENT_MTU 15 |
| | | #define BLE_GAP_EVENT_IDENTITY_RESOLVED 16 |
| | | #define BLE_GAP_EVENT_REPEAT_PAIRING 17 |
| | | #define BLE_GAP_EVENT_PHY_UPDATE_COMPLETE 18 |
| | | #define BLE_GAP_EVENT_EXT_DISC 19 |
| | | #define BLE_GAP_EVENT_PERIODIC_SYNC 20 |
| | | #define BLE_GAP_EVENT_PERIODIC_REPORT 21 |
| | | #define BLE_GAP_EVENT_PERIODIC_SYNC_LOST 22 |
| | | #define BLE_GAP_EVENT_SCAN_REQ_RCVD 23 |
| | | #define BLE_GAP_EVENT_PERIODIC_TRANSFER 24 |
| | | #define BLE_GAP_EVENT_PATHLOSS_THRESHOLD 25 |
| | | #define BLE_GAP_EVENT_TRANSMIT_POWER 26 |
| | | #define BLE_GAP_EVENT_CONN_UPDATE 3 /*!< connection parameter update complete event. */ |
| | | #define BLE_GAP_EVENT_CONN_UPDATE_REQ 4 /*!< RX LL connection param req */ |
| | | #define BLE_GAP_EVENT_L2CAP_UPDATE_REQ 5 /*!< RX slave L2cap connection update req. */ |
| | | #define BLE_GAP_EVENT_TERM_FAILURE 6 /*!< */ |
| | | #define BLE_GAP_EVENT_DISC 7 /*!< adv report event */ |
| | | #define BLE_GAP_EVENT_DISC_COMPLETE 8 /*!< scan duration expired event */ |
| | | #define BLE_GAP_EVENT_ADV_COMPLETE 9 /*!< adv duration expired event */ |
| | | #define BLE_GAP_EVENT_ENC_CHANGE 10 /*!< Encrypt Changed event */ |
| | | #define BLE_GAP_EVENT_PASSKEY_ACTION 11 /*!< PinCode display/request event */ |
| | | #define BLE_GAP_EVENT_NOTIFY_RX 12 /*!< Central Rx notify event. */ |
| | | #define BLE_GAP_EVENT_NOTIFY_TX 13 /*!< Peripheral Tx notify cmpl event. */ |
| | | #define BLE_GAP_EVENT_SUBSCRIBE 14 /*!< Enable/Disable Peripheral Notify & Indicate status event. */ |
| | | #define BLE_GAP_EVENT_MTU 15 /*!< MTU update complete event. */ |
| | | #define BLE_GAP_EVENT_IDENTITY_RESOLVED 16 /*!< indicate peer address is RPA event. */ |
| | | #define BLE_GAP_EVENT_REPEAT_PAIRING 17 /*!< The user is asked whether to delete the existing pair info to create a new pair. */ |
| | | #define BLE_GAP_EVENT_PHY_UPDATE_COMPLETE 18 /*!< PHY update complete event. */ |
| | | #define BLE_GAP_EVENT_EXT_DISC 19 /*!< extended adv report event. */ |
| | | #define BLE_GAP_EVENT_PERIODIC_SYNC 20 /*!< period adv sync event. */ |
| | | #define BLE_GAP_EVENT_PERIODIC_REPORT 21 /*!< period adv report event. */ |
| | | #define BLE_GAP_EVENT_PERIODIC_SYNC_LOST 22 /*!< period adv sync loss event. */ |
| | | #define BLE_GAP_EVENT_SCAN_REQ_RCVD 23 /*!< rx scan req event. */ |
| | | #define BLE_GAP_EVENT_PERIODIC_TRANSFER 24 /*!< */ |
| | | #define BLE_GAP_EVENT_PATHLOSS_THRESHOLD 25 /*!< */ |
| | | #define BLE_GAP_EVENT_TRANSMIT_POWER 26 /*!< */ |
| | | |
| | | /*** Reason codes for the subscribe GAP event. */ |
| | | |
| | |
| | | * A BLE host core return code on unexpected |
| | | * error. |
| | | */ |
| | | #if SMP_MULTI_ADDR_MODE_EN |
| | | int ble_gap_unpair(const ble_addr_t *peer_addr,const ble_addr_t *own_addr); |
| | | #else |
| | | int ble_gap_unpair(const ble_addr_t *peer_addr); |
| | | #endif |
| | | |
| | | /** |
| | | * Unpairs the oldest bonded peer device. The keys related to that peer |