2019-05-08 08:46 PM
Dear ALL
I got an problem when i use STM32F429 standby mode.
In the first time enter the standby mode it woks fine. I use PA0-WAUP pin to exit the standby mode. But, i make another try to enter the standby mode, it immediate reset。It is seems it entered the mode ok, and immediate exit from the mode. I have no ideal about it.
Here is my code to enter the standby mode
if(uxBits & BIT_0)
{
UART_PutStr(UART_1,"接收到BIT0被设置的消�?�\r\n");
HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN1);
HAL_PWR_EnterSTANDBYMode();
}
BYW, i use FreeRtos, and i put the code in a Take with and EverntBit been set
Solved! Go to Solution.
2019-05-08 09:05 PM
{
/* Enable Power Clock */
__HAL_RCC_PWR_CLK_ENABLE();
/* Disable all used wakeup sources: Pin1(PA.0) */
HAL_PWR_DisableWakeUpPin(PWR_WAKEUP_PIN1);
/* Clear all related wakeup flags */
__HAL_PWR_CLEAR_FLAG(PWR_FLAG_WU);
/* Re-enable all used wakeup sources: Pin1(PA.0) */
HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN1);
/*## Enter Standby Mode ####################################################*/
/* Request to enter STANDBY mode */
HAL_PWR_EnterSTANDBYMode();
}
2019-05-08 09:05 PM
{
/* Enable Power Clock */
__HAL_RCC_PWR_CLK_ENABLE();
/* Disable all used wakeup sources: Pin1(PA.0) */
HAL_PWR_DisableWakeUpPin(PWR_WAKEUP_PIN1);
/* Clear all related wakeup flags */
__HAL_PWR_CLEAR_FLAG(PWR_FLAG_WU);
/* Re-enable all used wakeup sources: Pin1(PA.0) */
HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN1);
/*## Enter Standby Mode ####################################################*/
/* Request to enter STANDBY mode */
HAL_PWR_EnterSTANDBYMode();
}
2019-05-08 10:58 PM
Hi Clive
Thanks for help. the code __HAL_PWR_CLEAR_FLAG(PWR_FLAG_WU); make the problom. very appreciate. : )
2019-05-08 10:59 PM
Hi Clive
Thanks for help. the code __HAL_PWR_CLEAR_FLAG(PWR_FLAG_WU); make the problom. very appreciate. : )
2019-05-08 11:13 PM
Hi Clive
If it is convenient, can i ask where can i find fils about HAL lib user manual, or API examples, i am an new guy in STM32, very appreciate. : )
2019-05-09 01:58 AM
Hi Clive
I find all STM32 HAL/LL lib Use manual at