Bug STM32L452CEU6 Internal WakeUp using RTC using CubeMX
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-10-21 8:10 AM
Hi All
I switched form a STM32L412CBU6 to a STM32L452CEU6 MCU and created therefore a new project. The enable of the Internal Wakeup with RTC is not generated anymore into the rtc.c file using CubeMX Version 6.6.1. (I'm using the option seperte .c/.h file in the code generation setting tab).
Solved! Go to Solution.
- Labels:
-
RTC
-
STM32CubeMX
-
STM32L4 series
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-11-01 10:17 AM
Hello @MHoh.1l​
First let me thank you for posting.
After investigation I was able to reproduce the same behavior using the same environment as you did.
As a temporary solution I propose that you add the following instructions in the void MX_RTC_Init(void) function in the rtc.c file:
/* USER CODE BEGIN RTC_Init 2 */
/** Enable the WakeUp
*/
if (HAL_RTCEx_SetWakeUpTimer(&hrtc, 0, RTC_WAKEUPCLOCK_RTCCLK_DIV16) != HAL_OK)
{
Error_Handler();
}
/* USER CODE END RTC_Init 2 */
This is an example of implementation of the solution; you can set the wakeup clock divider and the counter value as you need and pass the values to HAL_RTCEx_SetWakeUpTimer function.
With this being said, this problem is raised internally to be reviewed. I'll keep you posted with the updates.
Internal ticket number: 138078 (This is an internal tracking number and is not accessible or usable by customers).
Thx
Semer.
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-11-01 10:17 AM
Hello @MHoh.1l​
First let me thank you for posting.
After investigation I was able to reproduce the same behavior using the same environment as you did.
As a temporary solution I propose that you add the following instructions in the void MX_RTC_Init(void) function in the rtc.c file:
/* USER CODE BEGIN RTC_Init 2 */
/** Enable the WakeUp
*/
if (HAL_RTCEx_SetWakeUpTimer(&hrtc, 0, RTC_WAKEUPCLOCK_RTCCLK_DIV16) != HAL_OK)
{
Error_Handler();
}
/* USER CODE END RTC_Init 2 */
This is an example of implementation of the solution; you can set the wakeup clock divider and the counter value as you need and pass the values to HAL_RTCEx_SetWakeUpTimer function.
With this being said, this problem is raised internally to be reviewed. I'll keep you posted with the updates.
Internal ticket number: 138078 (This is an internal tracking number and is not accessible or usable by customers).
Thx
Semer.
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-11-09 1:47 AM
Hi Semer
Thanks for your reply. I already impelmented it as shown by your example.
Best regards,
michi
