Commit 57e00ef2 authored by Dave Hylands's avatar Dave Hylands
Browse files

stmhal: Fix RTC code to work on the F7

parent 7f3c0d1e
......@@ -211,7 +211,7 @@ void rtc_init(void) {
if (rtc_use_lse) {
// fall back to LSI...
rtc_use_lse = false;
PWR->CR |= PWR_CR_DBP;
HAL_PWR_EnableBkUpAccess();
RTCHandle.State = HAL_RTC_STATE_RESET;
if (HAL_RTC_Init(&RTCHandle) != HAL_OK) {
rtc_info = 0x0100ffff; // indicate error
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment