Hi,
When using a usart, and enabling tx irq, I get a permanent call to the irq routine (permanent = once we return from the irq routine, we get back to it without any time to execute something else).
To reproduce : use lpcxpresso54608_usart_example from sdk, and replace in "usart_interrupt.c" the line
USART_EnableInterrupts(DEMO_USART, kUSART_RxLevelInterruptEnable | kUSART_RxErrorInterruptEnable);
by
USART_EnableInterrupts(DEMO_USART, kUSART_TxLevelInterruptEnable );
The problem has been reproduced with this program on lpc54608 (om13098) and lpc54606 (custom board).
The original problem has also been detected on a mbed generated project on our custom board.
We got the same behaviour for all the usart we are using (0,2, 4 and 6).
Hi SST Informatique,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
After initializing the UART, the TX FIFO is empty, meanwhile, the transmit FIFO level trigger is 0, I think it can explain repeat enter the transmit FIFO level interrupt.
Fig 1
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------
Hi,
Good try, but this is not the case :
- Theory : FIFO is empty and the irq should be triggered when it **become** empty
- Real world : I already tried to set the TXLVL to 1 before enabling the irq, and the result is the same.
Any other idea ?
Thanks
Stephane
Hi SST Informatique,
Sorry for the late reply.
There're suggestions for you for further testing
1. Increase TXLVAL(>1).
2. Clear the TXLVL interrupt status in the interrupt function.
Please give a try.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------