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/MSP430FR2633: Driverlib Timer examples do not work

Part Number: MSP430FR2633
Other Parts Discussed in Thread: MSP430WARE,

Tool/software: Code Composer Studio

I'm using Code Composer Studio 8.1.0.00011 with MSP430Ware 3.80.04.05 installed. I am trying to use the TimerA examples to understand how the timers work. However, the code does not execute past enabling the GIE.

I loaded the "timer_a_ex2_continousModeOperationWithCCR0Interrupt" project. After changing the processor to MSP430FR2633 in the project properties, I tried to compile. GPIO_PORT_LED1 and GPIO_PIN_LED1 are not defined. It appears Board.h is missing a definition for the FR2633. So I added #defines for P1 and PIN7. (I have also tried with P1 and PIN0 to emulate the original example, but no difference.)

PIN7 (or PIN0) never toggles from the timer interrupt. I am watching them with an oscilloscope for activity. If I put in GPIO_setOutputLowOnPin() and GPIO_setOutputHighOnPin() statements after GPIO_setAsOutputPin(), I can see the pins toggle. I have also set a breakpoint in the ISR, but it never breaks.

If I pause the debugger, it drops me into "isr_trap.asm" on an instruction "JMP __TI_ISR_TRAP". 

What do I have to do to make Timers work?

  • Hi James,

    Thanks for post, We know your question and will come back to you later.

    regards
    KC
  • Hi James,
    You can find the example projects through below steps using the CCS.
    1. Click Projects->Examples
    2. Select your device "MSP430FR2633" for example
    3. Click Software->MSP430Ware->MSP430FR2633->Peripheral examples->Register Level
    4. Find the examples you need in this folder

    Best regards,
    Cash Hao
  • Cash Hao said:
    3. Click Software->MSP430Ware->MSP430FR2633->Peripheral examples->Register Level

    Yes, I found those. I was asking how to make the Driverlib examples work.

  • FYI, 6 days later, I am still waiting for an answer.
  • Hi James,

    So you mean the examples code TI provided can not work?

    Best regards,

    Cash Hao

  • > > So you mean the examples code TI provided can not work?

    That is exactly what I said in my original question/post.
  • Hi James,
    But I still do not know where did you find this code example project "timer_a_ex2_continousModeOperationWithCCR0Interrupt". If you need example codes for MSP430FR2633, please refer to the path I have sent before. The official timer code example for MSP430FR2633 is named after "msp430fr243x_ta0_0x.c". These code examples have been testified.

    Best regards,
    Cash Hao
  • I am tired of repeating myself. I want to know how to configure the timer using driverLib. This example does not ever interrupt.

    > I still do not know where did you find this code example project "timer_a_ex2_continousModeOperationWithCCR0Interrupt"
    Resource Explorer > Software > MSP430Ware > Libraries > Driver Library > MSP430FR2xx_4xx > Example Projects > TIMER_A


    > These code examples have been testified.
    If you insist. I have tried to configure 4 perperials with either register level or DriverLib. So far, all 4 have examples with errors. So while they have been "tested" it is clear no one bothered to make sure they work correctly.
  • "I am tired of repeating myself. I want to know how to configure the timer using driverLib."

    to be fair, you listed quite a few issues in your original post and some of them were addressed earlier. and it is until now that you specifically called out the interrupt issue.

    having a nasty attitude is never going not to help you get help, especially when the help is free.

    " This example does not ever interrupt."

    have you thought about taking a look at the driverlib manual, sample code or datasheet? those devices are fairly simple. setting up the timer interrupt involves clearing the flag, enabling the interrupt bit, and write an ISR.

    here is an example for the FR series: 

    pay attention to the tmra0..4.h/.c files and tmrb0.h/.c files.

    hope it helps.

  • > and it is until now that you specifically called out the interrupt issue.
    Excuse me? My original post clearly said "PIN7 (or PIN0) never toggles from the timer interrupt."

    In fact, it is the only issue I'm asking for help on regarding TimerA and Driverlib. The rest are pointing out the numerous issues with the sample code and documentation provided by TI.

    >have you thought about taking a look at the driverlib manual, sample code or datasheet
    See above.

    > especially when the help is free.
    I don't consider buying parts from TI and specing them into my end product as "free."

    > having a nasty attitude
    After waiting this long for a proper response to my question, I am exercising considerable restraint from a nasty attitude.

    >here is an example for the FR series:
    I don't see driverlib referenced anywhere.
  • I don't have your equipment, so I'm working somewhat blind here.
    1) With due respect to the TI test team, I'm pretty sure they couldn't have tested this combination since (as you pointed out) it doesn't build due to Board.h
    2) The ISR_TRAP is symptomatic of a misplaced interrupt vector or enablement. When I build for the FR2633, the vector seems to be in place. Similarly, the (timer) register locations -- which are different between the FR4133 and FR2633 -- look OK in the assembly.
    3) That said, this sounds procedural. The first thing to look at is whether the General category check box "manage .. configuration automatically" is checked. If it got un-checked somehow, a number of things could go wrong.
    4) Just for Magic and Superstition, try a "Project->Clean".
    5) Could you post the "stanza" you added to Board.h? I'm sure you knew what you were doing, but sometimes all it takes is a typo.
    6) Once you're in this state, could you check (I recommend the "Disassembly" window) to see what's at 0xfff4? It ought to be a pointer to the ISR.
  • This issue is not resolved, but I want to close out the question. I've decided to adopt a different platform.

**Attention** This is a public forum