求助stm8l151外部中断唤醒函数
展开全部
/* 禁止TIM3 */
TIM3->SR1 = (uint8_t)(~(uint8_t)TIM3_IT_Update);
CLK_PeripheralClockConfig(CLK_Peripheral_TIM3, DISABLE);
TIM3_ITConfig(TIM3_IT_Update, DISABLE);
TIM3_Cmd(DISABLE);
if(Halt.wakeupFlag == 0)
{
POWER433MOFF;
halt();
}
Halt.wakeupFlag = 0;
Si4432PortReset();
MCUTXLEDOFF;
POWER433MON;
//唤醒
EXTI->SR1 = 0Xff;
TIM3->SR1 = (uint8_t)(~(uint8_t)TIM3_IT_Update);
CLK_PeripheralClockConfig(CLK_Peripheral_TIM3, DISABLE);
TIM3_ITConfig(TIM3_IT_Update, DISABLE);
TIM3_Cmd(DISABLE);
if(Halt.wakeupFlag == 0)
{
POWER433MOFF;
halt();
}
Halt.wakeupFlag = 0;
Si4432PortReset();
MCUTXLEDOFF;
POWER433MON;
//唤醒
EXTI->SR1 = 0Xff;
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询