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.

CCS/MSP430F5528: Timer TAIV does not change when CCIF is high

Part Number: MSP430F5528


Tool/software: Code Composer Studio

Hi, I am using TDC1000-TDC7200EVM with MSP430F5528, when I want to use the timer1_A, I have some problems:

Here are the codes I use to initial the TIMER1_A3:

I changed INTERVAL_100ms=50.

When I started to debug, here are the value of registers:

Initial the TIMER:

TA1R = TA1CCR0:

TA1R is reset to 0:

TA1IV did not change so that there is no interrupt.

What can I do?

  • Hi Jiao,

    do you set the general interrupt enable bit somewhere in your code?

    As you've only posted the timer initialization I don't know if you've added a

    __bis_SR_register(GIE);

    somewhere in your application code.

    Please let me know if this already solves your issue.

    Thanks and best regards,

    Britta

  • Hi Britta,

    I found I did not enable the interrupt TAIE. I added  '__bis_SR_register(GIE);' , and it works.However, here is the register value when the TAIFG=1:

    The TA1IV changed, but the program did not jump to the interrupt program. The interrupt vector is TIMER1_A1_VECTOR        (48 * 1u) .

    What should I do?

    regards,

    Jiao

  • Hi Jiao,

    so the interrupt occurs but the application doesn't jump to the Timer1_A1 isr, correct?
    Could you share your ISR code?
    What happens if you set a breakpoint at the isr entry? Is it ever reached?
    Please share those specifics so that I can further understand the issue.

    Thanks and best regards,
    Britta
  • Hi Britta,

    Yes, the interrupt occurs but it doesn't jump to Timer1_A1 isr. Actually,if I set a breakpoint in the Timer1_A1 isr, the interrupt will occur. However, when I use 'step over' to run my program step by step,  it will not jump to isr.

    Here is my code:

    Thank you very much.

    regards,

    Jiao

  • For some reason I can't copy/paste your code, but anyway try

    >#pragma vector=TIMER1_A0_VECTOR
  • Hi,

    I suppose that you were able to move on with your application after Bruce's indication as I didn't hear back from you anymore.
    Please note that I am going to close this thread. In case you need further assistance on this topic you can reply back to this thread which will re-open it. In case you have other questions you can use the "Ask a related question" or "Ask a new question" button on the top right of this page.

    Best regards,
    Britta

**Attention** This is a public forum