CCR0 interrupt not executing

Discussions on how to get your MSP JTAG programmer up and running.

Moderator: phalanx

Post Reply
composer
Posts: 6
Joined: Mon Jul 20, 2009 6:51 am

CCR0 interrupt not executing

Post by composer » Sun Jan 15, 2012 12:05 pm

I supplied the code for setting up TA in updown mode.I obtained two output frequencies but TA interrupt routine is not executing when TA reaches CCRO.Can anyone help, please.I can supply the whole code if necessary.Microcontroller is msp430f149.



P1DIR |= 0x0C; // P1.2,3 output
P1SEL |= 0x0C; // P1.2 and P1.3 TA1/2 options



CCR0 = 2400-1;
CCTL1 = OUTMOD_6;
CCTL2 = OUTMOD_2;
CCR1=500;
CCR2=1000;

CCTL0 = CCIE; // CCR0 interrupt enabled


TACTL = TASSEL_1 + MC_3 + TAIE; // ACLK, updown mode

UhClem
Posts: 408
Joined: Sun Aug 03, 2008 6:11 pm

Re: CCR0 interrupt not executing

Post by UhClem » Sun Jan 15, 2012 12:45 pm

When you say that the TA interrupt routine is not executing on the CCR0 condition I suspect you mean the routine attached to the TAIV interrupt vector isn't executing. TACCR0 uses a different interrupt vector.
Two interrupt vectors are associated with the 16-bit Timer_A module:
TACCR0 interrupt vector for TACCR0 CCIFG
TAIV interrupt vector for all other CCIFG flags and TAIFG

composer
Posts: 6
Joined: Mon Jul 20, 2009 6:51 am

Re: CCR0 interrupt not executing

Post by composer » Mon Jan 16, 2012 1:48 am

When I turned off ADC interrupt sudenly TA interrupt routine started working.Thank you.

Post Reply