-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
times reset after power cycle #32
Comments
this person make it work with mbed. i dont understand the code but i will paste it here in case some one find it useful i think it may be related to this: |
The epoch includes date data which is lost on power cycle on stm32f1xx boards, this should be fixed by my pull request here |
i try your version of this library, still same behaviour |
i just realize that i have to replace the rtc.c and rtc.h files in the cores. everything its working now thank you very much. |
I've just hit exactly this problem. I had a development (a Bluepill STM32F103C8T6 based satellite clock) based on the Roger Clark STM32 core. After migrating some time later to the official STM32 arduino core 1.9.0 and adapting the clock to use the STM32RTC library https://github.com/stm32duino/STM32RTC , the time would not be retained during a power cycle. Anyway, I have applied the fix here, developed by Josh-Gaby and it now appears to work correctly again. That is, the RTC time does not suffer an unwanted reset during a power cycle. Many thanks for fixing that! This is what I did to apply the fix, in case it is useful for someone who wants to retrofit it into the current arduino core version 1.9.0 :
I don't doubt there is a more elegant way of achieving the same thing, but it worked for me. |
Thanks! This method works on my custom STM32F103 circuit with supercap connected to VBAT pin. Btw, for Windows user, the ArduinoData is located at "%USERPROFILE%\AppData\Local\Arduino15" |
I do not know how to make the choice, there is no response from the official? |
the time its lost after power cycling, although LSE_CLOCK is selected, and the vbat is connected
im using the epoch example with some modifications to be able to the set time via UART
arduino 1.8.13
stm32f103 bluepill
library.properties:
name=STM32duino RTC
version=1.1.0
author=STMicroelectronics, Wi6Labs
maintainer=stm32duino ........
The text was updated successfully, but these errors were encountered: