nochanges
Dependents: BLE_Acceleration_Statejudging
Fork of nRF51822 by
Diff: btle/btle.cpp
- Revision:
- 1:f84abedbf4fb
- Parent:
- 0:eff01767de02
- Child:
- 17:c3e11bb6cb72
diff -r eff01767de02 -r f84abedbf4fb btle/btle.cpp --- a/btle/btle.cpp Wed Mar 26 14:38:17 2014 +0000 +++ b/btle/btle.cpp Thu Apr 03 01:45:38 2014 +0100 @@ -94,13 +94,13 @@ switch (p_ble_evt->header.evt_id) { case BLE_GAP_EVT_CONNECTED: - nRF51GattServer::getInstance().m_connectionHandle = p_ble_evt->evt.gap_evt.conn_handle; + nRF51Gap::getInstance().setConnectionHandle( p_ble_evt->evt.gap_evt.conn_handle ); nRF51Gap::getInstance().handleEvent(GapEvents::GAP_EVENT_CONNECTED); break; case BLE_GAP_EVT_DISCONNECTED: // Since we are not in a connection and have not started advertising, store bonds - nRF51GattServer::getInstance().m_connectionHandle = BLE_CONN_HANDLE_INVALID; + nRF51Gap::getInstance().setConnectionHandle (BLE_CONN_HANDLE_INVALID); ASSERT_STATUS_RET_VOID ( ble_bondmngr_bonded_centrals_store() ); nRF51Gap::getInstance().handleEvent(GapEvents::GAP_EVENT_DISCONNECTED); break; @@ -117,7 +117,7 @@ sec_params.min_key_size = CFG_BLE_SEC_PARAM_MIN_KEY_SIZE ; sec_params.max_key_size = CFG_BLE_SEC_PARAM_MAX_KEY_SIZE ; - ASSERT_STATUS_RET_VOID ( sd_ble_gap_sec_params_reply(nRF51GattServer::getInstance().m_connectionHandle, BLE_GAP_SEC_STATUS_SUCCESS, &sec_params) ); + ASSERT_STATUS_RET_VOID ( sd_ble_gap_sec_params_reply(nRF51Gap::getInstance().getConnectionHandle(), BLE_GAP_SEC_STATUS_SUCCESS, &sec_params) ); } break;