中级会员
- 积分
- 354
- 金钱
- 354
- 注册时间
- 2018-7-20
- 在线时间
- 46 小时
|
楼主 |
发表于 2018-10-17 09:32:04
|
显示全部楼层
[mw_shl_code=c,true]void USART6_IRQHandler(void)
{
if(USART_GetITStatus(USART6, USART_IT_RXNE) != RESET)
{
BaseType_t xHigherPriorityTaskWoken;
xHigherPriorityTaskWoken = pdFALSE;
u16 ReceiveData;
if((GetRxBufferLength(&MyUart[GPS_COM6])<(UARTBUFFSIZE-1)))
{
ReceiveData=USART_ReceiveData(USART6);
EnRxBuffer(&MyUart[GPS_COM6], ReceiveData);
portYIELD_FROM_ISR(xHigherPriorityTaskWoken);
}
USART_ClearITPendingBit(USART6,USART_IT_RXNE);
}
}[/mw_shl_code] |
|