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.

UART2 transmit interrupt blocks when receiving

Hello,

I think there's a problem with the interrupts on C6748, I modified uartEcho.c example to show the problem, basically I'm sending continuously from the board to terminal and whenever I keep pressed a key to send from terminal to the board (LogicPD EVMC6748), the code blocks and stops sending. I've set hardware breakpoints in the interrupt and it no longer arrives there.

See the attached file where you can see my modifications from the StarterWare (1.20.01.01)\uart\uartEcho.c example.

4784.uartEcho.c.txt

Any idea why this is happening? I would have assumed that 

Thank you in advance,

David.

  • hmm... I had once faced this problem. As far as I remember it was case of missing interrupts under slightly higher interrupt rates.

    The UART controller raises the interrupt only once for any number of interrupts (tx, rx error) that have occurred almost simultaneously.

    I had solved this by handling the interrupts by re-reading the interrupt status before exiting the handler.

    For example:

    UARTIsr()

    {

    while(intr_status_still_exists)

    {

    if (tx)

    {

    do something;

    }

    else if (rx)

    {

    do something;

    }

    else if (err)

    {

    do something;

    }

    }

    }

    Hope this helps.

    Regards,

    Madhvapathi Sriram

  • Thank you for your answer, indeed, requesting in a while loop the status of UART interrupts until no more flags are reported has fixed the problem.