Skip to main content
Associate II
Mar 17, 2026 2:15 PM UTC
Solved

STM32U073CCT6 - True random-number generator (RNG) and STOP MODE

Hi

 

I would like to check if it is necessary to call MX_RNG_Init() after the MCU exits STOP MODE to reconfigure the RNG?

 

BR

Gilberto

Gyessine
GyessineBest answer
ST Technical Moderator
Mar 18, 2026 10:24 AM UTC

Hello @gilberto-falker 
Stop mode achieves the lowest power consumption while retaining the content of SRAM and registers. All clocks in the VCORE domain are stopped, the PLL, the MSI RC, the HSI16 RC and the HSE crystal oscillators are disabled
and since The RNG runs on two different clocks which one of them is the AHB bus in the STM32U073
what really matters is that you call the  SystemClock_Config(); just after exiting stop mode.
you can also track the RNGEN bit in the RNG_CR register and the DRDY bit in the RNG_SR register
BR
Gyessine

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question.

1 reply

Gyessine
GyessineBest answer
ST Technical Moderator
Mar 18, 2026 10:24 AM UTC

Hello @gilberto-falker 
Stop mode achieves the lowest power consumption while retaining the content of SRAM and registers. All clocks in the VCORE domain are stopped, the PLL, the MSI RC, the HSI16 RC and the HSE crystal oscillators are disabled
and since The RNG runs on two different clocks which one of them is the AHB bus in the STM32U073
what really matters is that you call the  SystemClock_Config(); just after exiting stop mode.
you can also track the RNGEN bit in the RNG_CR register and the DRDY bit in the RNG_SR register
BR
Gyessine

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question.