11-25-2008 11:41 PM
hi engineer:i have a problem when i deal with the uartlite interrupt,i want to send message by uartlite in normal mode and receive message in interrupt mode,then there is problem,the uartlite interrupt handler is called when i send message .
i had found that there are two different interrupt mode (send message by edge sensitivtyand and receive message by level sensitivity) in the datasheet,but there is only one interrupt port ,how can i deal with the problem? in my project i use a interrupt controller,how the interrupt controller distinguish the two different interrupt?
thank you for your time ,i hope your reply!
11-26-2008 10:38 AM
According to my knowledge and pervious expeince with the UARTLite; you cannot enable/disable send/receive interrupts indepnedntly. The send and/or receive interrupts must be enabled together and this not a software issue only but it's limited because of the hardware design of UARTLite itself. If you can go to its datasheet; you will find that there is only one interrupt enable/flag in its control/status registers.
However; you can set an empty interrupt handler for receive and/or send interrupts. The both handlers could be set indpendently using XUartLite_SetRecvHandler () or XUartLite_SetSendHandler ()
11-27-2008 06:11 AM
And you should use the level sensitivity concerning interrupt controller's output signal to the processor!
The interrupt controller sets the output signal as long as the ISR resets the occurred interrupt source.
This mechanism is like a handshake due to the asynchronism.