Hi All;
I'm using uvision compiler. Below A portion of my code regarding UART1 RX interrupt.
I was using reading flags. I want to use interrupt.
I didn't get an interrupt. What is wrong?
#define UART_INT_EN *((unsigned long int *)(0xE000E100))
#define UART_INT_DIS *((unsigned long int *)(0xE000E180))
void UART1_Handler(void){
char_rxdata = (unsigned char)UART1-> DR;
UART1-> DR= char_rxdata;
UART1->ICR &=~(1u<<4); //UARTICR
}
void main(void){
UART_INT_EN |=(1u<<6); // Enable UART1 interrupt
UART1->IM |=(1u<<4); //UART Interrupt Mask (UARTIM) /
while(1);