We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents db60d6a + 07d7165 commit e6d4b84Copy full SHA for e6d4b84
hal/targets/hal/TARGET_NORDIC/TARGET_MCU_NRF51822/us_ticker.c
@@ -515,16 +515,7 @@ static void register_next_tick() {
515
*/
516
int os_tick_init (void)
517
{
518
- NRF_CLOCK->LFCLKSRC = (CLOCK_LFCLKSRC_SRC_Xtal << CLOCK_LFCLKSRC_SRC_Pos);
519
- NRF_CLOCK->EVENTS_LFCLKSTARTED = 0;
520
- NRF_CLOCK->TASKS_LFCLKSTART = 1;
521
-
522
- while (NRF_CLOCK->EVENTS_LFCLKSTARTED == 0) {
523
- // wait for the low frequency clock start
524
- }
525
526
- NRF_RTC1->PRESCALER = 0; /* for no pre-scaling. */
527
+ // their is no need to start the LF clock, it is already started by SystemInit.
528
NVIC_SetPriority(RTC1_IRQn, RTC1_IRQ_PRI);
529
NVIC_ClearPendingIRQ(RTC1_IRQn);
530
NVIC_EnableIRQ(RTC1_IRQn);
0 commit comments