STM32F103V 4串口电路
interrupts */
USART_ITConfig(USART1, USART_IT_RXNE, ENABLE);
USART_ITConfig(USART1, USART_IT_TXE, ENABLE);
USART_ITConfig(USART2, USART_IT_RXNE, ENABLE);
USART_ITConfig(USART2, USART_IT_TXE, ENABLE);
USART_ITConfig(USART3, USART_IT_RXNE, ENABLE);
USART_ITConfig(USART3, USART_IT_TXE, ENABLE);
USART_ITConfig(UART4, USART_IT_RXNE, ENABLE);
USART_ITConfig(UART4, USART_IT_TXE, ENABLE);
/* Enable the USART1 */
USART_Cmd(USART1, ENABLE);
USART_Cmd(USART2, ENABLE);
USART_Cmd(USART3, ENABLE);
USART_Cmd(UART4, ENABLE);
}
/****************串口1中断************************/
void USART1_IRQHandler(void)
{
unsigned char i;
if(USART_GetITStatus(USART1, USART_IT_RXNE) != RESET)
{
}
USART_ClearITPendingBit(USART1,USART_IT_RXNE); //清中断标识
USART_ITConfig(USART1, USART_IT_TXE, DISABLE);
}
STM32F103V串口电 相关文章:
- Windows CE 进程、线程和内存管理(11-09)
- RedHatLinux新手入门教程(5)(11-12)
- uClinux介绍(11-09)
- openwebmailV1.60安装教学(11-12)
- Linux嵌入式系统开发平台选型探讨(11-09)
- Windows CE 进程、线程和内存管理(二)(11-09)