mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2025-02-21 06:07:10 +08:00
Merge pull request #3036 from Linjieqiang/fix_stm32hal_rtc_error
bsp: fix stm32 rtc hal library error.
This commit is contained in:
commit
42248d81e5
@ -110,6 +110,9 @@ static rt_err_t rt_rtc_config(struct rt_device *dev)
|
||||
#endif
|
||||
HAL_RCCEx_PeriphCLKConfig(&PeriphClkInitStruct);
|
||||
|
||||
/* Enable RTC Clock */
|
||||
__HAL_RCC_RTC_ENABLE();
|
||||
|
||||
RTC_Handler.Instance = RTC;
|
||||
if (HAL_RTCEx_BKUPRead(&RTC_Handler, RTC_BKP_DR1) != BKUP_REG_DATA)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user