初级会员

- 积分
- 54
- 金钱
- 54
- 注册时间
- 2018-4-14
- 在线时间
- 6 小时
|
1金钱
本帖最后由 SXX666 于 2018-5-9 17:05 编辑
在用STM32停止功能的时候,我在停止模式之前点亮了灯,进入停止模式之后灯竟然还在亮,我看了手册配置的,将所有的IO口配置为模拟,麻烦有人帮我解释一下停止模式为什么还能亮灯,我用RTC中断唤醒停止模式需要配置什么条件么,RTC中断我已经配好了,可以正常进行中断服务函数,但是用RTC唤醒停止模式就不行了
[mw_shl_code=applescript,true]void To_enter_Stop(void)
{
//RTC_WakeUpCmd(ENABLE);
RTC_WakeUpCmd(ENABLE);
/* Request Wait For Interrupt */
PWR_EnterSTOPMode(PWR_Regulator_LowPower,PWR_STOPEntry_WFI);
/* Enter Stop Mode */
GPIO_LowPower_Config();
}[/mw_shl_code]
[mw_shl_code=applescript,true]int main(void)
{
//static u8 a;
// static float res1;
// uint8_t str[]="hello bay";
// static u8 cha;
// int i;
// unsigned static char DEVID_AD;
//u8 datatemp[SIZE];
RCC_Configuration();
NVIC_PriorityGroupConfig(NVIC_PriorityGroup_2);
delay_init(32);
uart_init();
LED_ALLInit();
KEY_ALLInit();
LD_ALLON();
RTC_Config();
To_enter_Stop();
while(1)
{
// RTC_Config();
// delay_s(1);
// To_enter_Stop();
// delay_s(1);
}
}[/mw_shl_code]
|
|