2016-05-20 02:00 PM
I'm using the wakeup interrupt from the RTC, but I don't want it active until certain conditions are present.
But I have no choice, either I disable it in Cube and get no stubs for interrupts and no definition, or I enable it and it is automatically running, like it or not.Fortunately I've found that is won't actually start until I do:__HAL_RTC_WAKEUPTIMER_CLEAR_FLAG(&hrtc, RTC_FLAG_WUTF);Is that by design? If so why isn't it in the HAL documents?I would suggest having a check-box in the configuration of 'enabled'. So it can be configured in a disabled state.-Matt2016-05-23 04:15 AM
Hi reed.matthew.003,
Please, tell us which CubeMx version and device you are using in your project. And to make your request clear, you mean this ''wakeup clear flag'' macro is not present with the generated code which cause a functional problem ? -Hannibal-2016-05-23 06:28 AM
Hannibal,
Thanks for the reply. I'm using 4.14.0And no, my comment is not about the wake-up clear macro.I would like the Cube Configuration for RTC in the ''Wake UP'' section to have a check-mark ''Wake UP Enabled'' which would allow the wake-up timer to be setup, but not enabled.Thanks!-Matt2016-05-23 08:15 AM
Hi reed.matthew.003,
This depends on the RTC configuration on CubeMx , it is selected internalwakeup , so it is enabled for ''ready for use'' state of the peripheral. (see figure)You can easly edit the generated code and remove the HAL_RTCEx_SetWakeUpTimer() function and place it as you want. Becareful, be awre it will be generated if you re-generated the code.-Hannibal-