NUC230_240_Series_BSP_CMSIS_V3.01.004\SampleCode\StdDriver\UART_TxRx_Function官方范例中此范例最后只启动uart的中断,没启动NVIC的IRQ 中断请求,中断功能正常,想问看看各位大大为何可以如此写?谢谢大家! /* Enable Interrupt and install the call back function */ UART_EnableInt(UART0, (UART_IER_RDA_IEN_Msk | UART_IER_THRE_IEN_Msk | UART_IER_TOUT_IEN_Msk)); while(g_bWait); /* Enable Interrupt and install the call back function */ UART_EnableInt(UART0, (UART_IER_RDA_IEN_Msk | UART_IER_THRE_IEN_Msk | UART_IER_TOUT_IEN_Msk)); NVIC_EnableIRQ(UART02_IRQn); while(g_bWait); |
更多回帖