How do I identify Brown out reset (BOR) condition from embedded software?
I would like to distinguish POR/PDR and BOR condition. Let me know if there is a way to identify this from embedded software for stm32l072cz.
I would like to distinguish POR/PDR and BOR condition. Let me know if there is a way to identify this from embedded software for stm32l072cz.
Hi @CDesh & @KnarfB ,
Comparing both reference manuals of both STM32L4 and STM32L0 and precisely RCC_CSR register, I noted that bit 27 is described as following:
So either for L4 or L0, the flag is the same and it is set when a power reset occurs.
In STM32L0, BOR is not available on all devices.
So for both STM32L0 & STM32L4, we can identify POR/PDR/BOR condition based on the bit 27 of RCC_CSR register.
Hope my answer helped you, when your question is answered, please close this topic by choosing Select as Best. This will help other users find that answer faster.
-Amel
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.