This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320C5535: UART receive interrupt hangs

Part Number: TMS320C5535

Hello,

I am using UART on C5535 with receive fifo and interrupts enabled. Transmit interrupts are disabled. Baud rate is 115200 Baud. When there is a lot of communication via UART, the ISR suddenly isn't called anymore. When I have a look at the registers in that situation, receiver data available bit is set in IIR. But dsp doesn't jump into ISR. I am using dsp bios and the interrupt dispatcher.

void UART_intrDispatch(void)
{
do
{
dataReceived();

}
while (CSL_FEXT(hUart->uartRegs->IIR, UART_IIR_IPEND) // todo: check int handling
== CSL_UART_IIR_IPEND_PENDING);
}

void dataReceived(void)
{
Char data;

UART_read(hUart, &data, 0, 0);

// do some stuff with the data

}

What is the reason for that? How should UART inetrupts be handled correctly?

Thanks in advance

Marc

  • Hi Marc,

    Could you test behaviour of CSL_UART_IntExample demo which is an UART example to test the Interrupt mode functionality of CSL UART to check whether UART interrupts are handled properly.

    BR
    Tsvetolin Shulev
  • Hello,
    CSL_UART_IntExample runs, but baudrate is only 2400 and no BIOS is used. My application also runs, but sometimes when there is lots of communication via UART, ISR is not called anymore. When I manually clear UART_INT(6) with the debugger, it continues running and ISR is called again. Must be a timing problem. In the BIOS interrupt dispatcher I have set "self" for the mask.

    Thank you

  • Marc,

    Apologies for the slow reply.
    Are you able to use DMA in your example? I think this would be the best approach considering the overhead on the CPU with UART interrupts.
    In order to see an example of UART with DMA, please see C:\ti\c55_lp\c55_csl_3.08\ccs_v6.x_examples\uart\CSL_UART_dmaExample

    Hope this helps.

    Lali