Closed ag88 closed 1 year ago
the comment about this PR : https://github.com/stevstrong/Arduino_STM32/issues/44#issuecomment-795857671
What is actually the status of this PR? Is it safe to merge?
this is done back then when I'm trying to use the backup registers on stm32f401. The readme.md in this commit is here https://github.com/rogerclarkmelbourne/Arduino_STM32/pull/850/files#diff-5b489eef3ad090c0a5bed41a1f684527533ee35d6300a3ec9e008013bf280689 and the test is here, it is both a test as well as an example codes https://github.com/rogerclarkmelbourne/Arduino_STM32/pull/850/files#diff-afb267cf20737b1168f92a9d093766aab94b0aa65704e08d1a6b2633f796ddac
stm32f401 don't have backup sram but that they do have backup registers and this commit is part of works i'm using in some of my sketches to keep some data in the backup registers as these can be safe kept by VBAT (e.g. a coin cell for the RTC) even if the main VDD 3v3 is powered off. This (the backup registers) has also been used in conjunction with RTClock. Hence, it should not affect the function of RTClock. One of the commit is actually a fix. When RTC is running on LSE and VBAT. The original code causes the RTC reset when powered up, this fix avoids clobbering a running RTC if it is running on LSE. https://github.com/rogerclarkmelbourne/Arduino_STM32/pull/850/commits/48817fab8da62b28c539be58213783b248c85b73 I've done various tests on stm32f401 and is actually using the codes in sketches as described above. I've tested the codes against a stm32f407 back then for backup sram and registers as well.
I think this shouldn't break anything
OK, then I will commit this. If somebody will encounter a problem related to this, then I will revert it. Thank you for contributing!
thanks ! I'd monitor issues here and in www.stm32duino.com and would respond just in case someone is after all using it
STM32F4: update bkp.h, bkp.c add support for backup registers and backup sram. added example in STM32F4/libraries/RTClock/examples/BkpTest