Skip to content

Commit 18f9087

Browse files
committed
Replace tabs with spaces
1 parent 481a451 commit 18f9087

File tree

1 file changed

+14
-14
lines changed
  • libraries/mbed/targets/hal/TARGET_STM/TARGET_STM32L0

1 file changed

+14
-14
lines changed

libraries/mbed/targets/hal/TARGET_STM/TARGET_STM32L0/rtc_api.c

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -72,22 +72,22 @@ void rtc_init(void)
7272
__HAL_RCC_RTC_CONFIG(RCC_RTCCLKSOURCE_LSE);
7373
rtc_freq = LSE_VALUE;
7474
} else {
75-
error("Cannot initialize RTC with LSE\n");
75+
error("Cannot initialize RTC with LSE\n");
7676
}
7777
#else
78-
// Enable LSI clock
79-
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_LSI | RCC_OSCILLATORTYPE_LSE;
80-
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_NONE; // Mandatory, otherwise the PLL is reconfigured!
81-
RCC_OscInitStruct.LSEState = RCC_LSE_OFF;
82-
RCC_OscInitStruct.LSIState = RCC_LSI_ON;
83-
if (HAL_RCC_OscConfig(&RCC_OscInitStruct) != HAL_OK) {
84-
error("RTC error: LSI clock initialization failed.");
85-
}
86-
// Connect LSI to RTC
87-
__HAL_RCC_RTC_CLKPRESCALER(RCC_RTCCLKSOURCE_LSI);
88-
__HAL_RCC_RTC_CONFIG(RCC_RTCCLKSOURCE_LSI);
89-
// This value is LSI typical value. To be measured precisely using a timer input capture for example.
90-
rtc_freq = 38000;
78+
// Enable LSI clock
79+
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_LSI | RCC_OSCILLATORTYPE_LSE;
80+
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_NONE; // Mandatory, otherwise the PLL is reconfigured!
81+
RCC_OscInitStruct.LSEState = RCC_LSE_OFF;
82+
RCC_OscInitStruct.LSIState = RCC_LSI_ON;
83+
if (HAL_RCC_OscConfig(&RCC_OscInitStruct) != HAL_OK) {
84+
error("RTC error: LSI clock initialization failed.");
85+
}
86+
// Connect LSI to RTC
87+
__HAL_RCC_RTC_CLKPRESCALER(RCC_RTCCLKSOURCE_LSI);
88+
__HAL_RCC_RTC_CONFIG(RCC_RTCCLKSOURCE_LSI);
89+
// This value is LSI typical value. To be measured precisely using a timer input capture for example.
90+
rtc_freq = 38000;
9191
#endif
9292

9393
// Enable RTC

0 commit comments

Comments
 (0)