stm32f rtc memory space?

Post here first, or if you can't find a relevant section!
Post Reply
picclock
Posts: 20
Joined: Sat Aug 14, 2021 8:21 am

stm32f rtc memory space?

Post by picclock »

I am using STM32RTC arduino library, stm32f401, with battery powered backup registers (20x32bit).
Do the rtc registers, (hour, min day etc.) affect or use any of the backup register space ?.
I intend to use the internal rc clock as accuracy is fairly unimportant.

Any help much appreciated.

Best Regards

picclock
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: stm32f rtc memory space?

Post by fpiSTM »

RTC registers does not affect the BKUP register.
Anyway the STM32RTC library uses one backup register to know if the RTC has already been configured or not.
And 2 more for STM32F1xx serie to store the date.
picclock
Posts: 20
Joined: Sat Aug 14, 2021 8:21 am

Re: stm32f rtc memory space?

Post by picclock »

@ fpiSTM
I have examined the two header files, STM32RTC.h and rtc.h (and the cpp file) but I cannot find any info on reserved bu ram use.
Do you know which ram locations are used, or where they might be declared.
Best Regards
picclock
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: stm32f rtc memory space?

Post by fpiSTM »

picclock
Posts: 20
Joined: Sat Aug 14, 2021 8:21 am

Re: stm32f rtc memory space?

Post by picclock »

OK I think I figured it. I wrote a program to clear and read back the BU Ram contents and found that Location 1 holds some data from the RTC. Not sure why 1?, unable to locate declaration. I was using location 0 as a checksum for the BU values, which would seem more logical. Reprogramming the chip (STM32F401) appears to have no effect on the clock time or backup registers. Battery used for ram backup.
Thanks for your assistance
Best Regards
picclock
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: stm32f rtc memory space?

Post by fpiSTM »

Post Reply

Return to “General discussion”