Skip to content

Read of RTC only after write #88208

@SoftwareArchitekt

Description

@SoftwareArchitekt

Describe the bug
I am using a blackpill_f401cc board. It comes with an STM32F401 CPU. This includes an RTC.
SW Zephyr 4.1.0-1530
Stwps what I have done:

  1. Set RTC with rtc_set_time(rtc, &tm) with an date and time
  2. Read the date and time with rtc_get_time(rtc, &tm) -> it works
  3. Buffer the RTC with Batterie on VBAT-Connector and GND.
  4. Remove rtc_set_time from code
  5. flash
  6. run program -> read the correct time
  7. disconnect from power
  8. reconnect power -> rtc_get_time -> error -61 / -ENODATA
  9. after debugging, I figure out that in file zephyr/drivers/rtc
    /rtc_ll_stm32.c line 531 throw this error

At this point I just want to remove the code from line 525 to 532 for proper working.
How else could it be fixed?

This is my first issue here, so I hope I wrote everything clear - if not, just support me to fill the needed informations

Metadata

Metadata

Assignees

Labels

Waiting for responseWaiting for author's responsearea: RTCReal Time ClockbugThe issue is a bug, or the PR is fixing a bugplatform: STM32ST Micro STM32priority: lowLow impact/importance bug

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions