nordic
Fork of nRF51822 by
Diff: source/btle/btle.cpp
- Revision:
- 421:1b5c227270f9
- Parent:
- 419:d66d5957a220
- Child:
- 424:9bf22621d592
--- a/source/btle/btle.cpp Tue Aug 11 15:14:23 2015 +0100 +++ b/source/btle/btle.cpp Tue Aug 11 15:14:23 2015 +0100 @@ -52,11 +52,13 @@ error_t btle_init(void) { + nrf_clock_lfclksrc_t clockSource; if (NRF_CLOCK->LFCLKSRC & (CLOCK_LFCLKSRC_SRC_Xtal << CLOCK_LFCLKSRC_SRC_Pos)) { - SOFTDEVICE_HANDLER_INIT(NRF_CLOCK_LFCLKSRC_XTAL_20_PPM, NULL); + clockSource = NRF_CLOCK_LFCLKSRC_XTAL_20_PPM; } else { - SOFTDEVICE_HANDLER_INIT(NRF_CLOCK_LFCLKSRC_RC_250_PPM_4000MS_CALIBRATION, NULL); + clockSource = NRF_CLOCK_LFCLKSRC_RC_250_PPM_4000MS_CALIBRATION; } + SOFTDEVICE_HANDLER_INIT(clockSource, NULL); // Enable BLE stack /**