2024-06-27 06:37 AM
Hi...
We are planning to use STM32H503KB (32 pin package) in our application. The MCU VDD is supplied from either of the two sources:
1. With power supply (5V)
2. With 3V cell
Our need is to bring the MCU to standby mode when the supply is provided from 3V cell and back to Normal operation when supply is provided from 5V. We have our actual logic (actual requirement - internal RTC) running in loop during 5V supply.
From the datasheet, I understand that if we proceed with setting SLEEPDEEP bit & LPMS = 1, we can bring the MCU into standby mode and a rising / falling edge to WKUP pin would bring the MCU to normal state.
Kindly confirm if my understanding is correct.
I would like to know if there's way by which if VDD of the MCU reduces below certain value, the MCU should go into standby mode and if supply comes back to 5V, MCU comes back to normal / run mode.
Kindly guide me in this regard.
Best Regards,
Prahaladh S
2024-06-30 08:31 PM - edited 2024-06-30 08:34 PM
One method to sense 5v using optocoupler whose collector connected to 3.3v. 5v is input to the opto diode side.
HAL_PWR_EnterSTANDBYMode();
2024-07-01 04:59 AM
Thank you for your response...
I'll look into it...
Best Regards,
Prahaladh S