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.

Compiler/MSP430FR2111: How to disable JTAG

Part Number: MSP430FR2111


Tool/software: TI C/C++ Compiler

Good Day,

I used 4-wire JTAG to download  and debug program.  I wanted that  P1.4 , P1.5  are general - purpose I/O Pins  with Hi/Lo transition Interrupt.

int main(void)
{
    WDTCTL = WDTPW | WDTHOLD;               
    // Configure GPIO
    P1OUT &= ~BIT2;                         
    P1DIR |= BIT2;   
	
    P1OUT |= BIT4|BIT5;                         
    P1REN |= BIT4|BIT5;                          
    P1IES |= BIT4|BIT5;                      
    P1IE |= BIT4|BIT5;                           

    PM5CTL0 &= ~LOCKLPM5;
 
    P1IFG &= ~(BIT4|BIT5);                         
    while(1)
    {
        __bis_SR_register(LPM3_bits | GIE);
        __no_operation();                   
        P1OUT ^= BIT2;                      
    }
}

// Port 1 interrupt service routine
#if defined(__TI_COMPILER_VERSION__) || defined(__IAR_SYSTEMS_ICC__)
#pragma vector=PORT1_VECTOR
__interrupt void Port_1(void)
#elif defined(__GNUC__)
void __attribute__ ((interrupt(PORT1_VECTOR))) Port_1 (void)
#else
#error Compiler not supported!
#endif
{
    P1IFG &= ~(BIT4|BIT5);                         
    __bic_SR_register_on_exit(LPM3_bits);  
}

The program didn't  into  Port_1 ISR, I check the DataSheet found I should disable JTAG .  I try to  add "SYSCTL  |=  SYSJTAGPIN;" before  I configed P1.4,P1.5.  It also didn't into Port_1 ISR. How to make P1.4 ,P1.5 to be general - purpose I/O Pins  which  Interrupts is Ok ? 

BestRegards

Jent

**Attention** This is a public forum