Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 262198

Problem with eUSCI_A ISR with MSP430F6733

$
0
0

Hello

I'm working on a project that utilises eUSCI_A1 in UART mode. I'm having a problem with the ISR. It works fine when receiving, but the TX interrupt does not trigger the ISR. TX interrupt is enabled, the flag is set and vector registers the TX interrupt (UCA1IV == 0x04), but it just does not enter the ISR.

The same code works fine with MSP430F5132 eUSCI_A0 so this seems really strange behaviour.

Unfortunately I cannot share the code, but this is the basic logic:

  1. Wait for valid frame from RX
  2. Process frame and construct a response in a SW buffer
  3. Enable TX interrupt from UCA1IE and begin transmitting bytes from the SW buffer
  4. Wait for transmit to complete

The MCU hangs in step 4 because the vector never triggers. I can't even force trigger the ISR by manipulating the flags manually. This same program logic works with MSP430F5132, where in step 3 the interrupt enable triggers the ISR. Could this be a silicon error?

Here is the ISR:

#pragma vector = USCI_A1_VECTOR
__interrupt void USCI_A1_ISR(void)
{
    switch(__even_in_range(UCA1IV, 0x04))
    {
    case 0x00:
        // Erroneous interrupt call. Ignore.
        break;

    case 0x02:
        v_Decipher_RX_Data();
        break;

    case 0x04:
        v_Transmit_Data();
        break;

    default:
        // Erroneous interrupt call. Ignore.
        break;
    }

    return;
}


Viewing all articles
Browse latest Browse all 262198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>