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.

TMS320F2808: Software Timer Interrupt

Part Number: TMS320F2808


Hi,

I think this is a simple problem about timer interrupts, but does the TMS320F2808 offer the possibility to generate own timer interrupts. So far I found only two possibilities to trigger a timer interrupt in the documentation (EPwm timer interrupts and CPU timer interrupts). But with these it is not possible to create arbitrary numbers of interrupts with different period durations.

Specifically, I am looking for a kind of software timer interrupt that triggers an interrupt after different times. For example the first timer should trigger after 10us, the second after 100us, the third after 1ms, the fourth after 10ms, ... . If there is a solution for this how would I be able to implement it as C-code.

Thank you already in advance.

  • Hi Kevin,

    The F2808 device has three general purpose timers, Timer 0,1, and 2. Each of these timers can be configured to generate an interrupt at different periods. 

    If you need more than 3 timers then you could possibly implement a check within one of the interrupt service routines (ISR). For example, you could configure timer 0 to generate an interrupt every 10us. Within that ISR, keep track of how many times the interrupt has been called, after 10 times you should know that 100us have gone by and you can execute the task you need done for that timeframe.

    Best Regards,

    Marlyn