Skip to content

Instantly share code, notes, and snippets.

@ksksue
Created December 5, 2014 02:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ksksue/d16948ed69e4e89f33b2 to your computer and use it in GitHub Desktop.
Save ksksue/d16948ed69e4e89f33b2 to your computer and use it in GitHub Desktop.
static void ble_stack_init(void)
{
// Initialize SoftDevice.
SOFTDEVICE_HANDLER_INIT(NRF_CLOCK_LFCLKSRC_RC_250_PPM_4000MS_CALIBRATION, false);
// Subscribe for BLE events.
uint32_t err_code = softdevice_ble_evt_handler_set(ble_evt_dispatch);
APP_ERROR_CHECK(err_code);
// Register with the SoftDevice handler module for BLE events.
err_code = softdevice_sys_evt_handler_set(sys_evt_dispatch);
APP_ERROR_CHECK(err_code);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment