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.

Timer64 ISR settling time

I created a timer64 to call an ISR routine every 300us.  In that ISR, I use the TSCL register to record the tick count and capture the delta time between calls.   I noticed that the first 6 times, the ISR delta varies widely and is much less then 300us.  After the 6th entry, the deltas settle down to about 300us.  

I'm passing in TIMER_ANY to allow SYS/BIOS to create the timer.  The timer is created before BIOS_Start is called.

Also, I noticed that if I create the timer after BIOS_Start, the timer would be called every 26us no matter what I set the period to.  Can the timer not be created after BIOS is started?

Thanks

  • Hi Tony,

    We have not heard such a behavior so for. Could you please try the same on CSL timer example? Below is the path to it.

    PATH: ..\ti\pdk_C6678_1_1_2_6\packages\ti\csl\example\timer

    Also we would recommend you to start a new thread on BIOS forum for BIOS queries.

    Thank you.

  • The CSL timer works more consistently, specifically the High Timer (Unchained) in Continuous Mode.  I would like to use this timer to interrupt every 100us.  In the example, the Uint32 LoadValue is passed into CSL_tmrHwControl to set the peroid.  From what I understand, the clock ticks every 6 system ticks.  So if I wanted a 100us period timer, I would need to pass into LoadValue 16.67, however the data type of LoadValue is a Uint32.  Is there another method to get this to work?

    Thanks

  • Hi Tony,

    Timer operates on both internal & external clock. Please tune the timer frequency to do the same. For more information read the Timer user guide (Section 3.3)

    http://www.ti.com/lit/sprugv5

    Thank you.

  • Hi  ,

    Is the expecation that the Timer frequency for the internal and external clock to be programed by the application?  is there a API to do so, or does the applicatoin directly modify the registers?

     

     

  • Hi,

    The below API is used to configure the clock source. Please refer CSL example for more information. CSL_tmrHwSetup(wdTmr, &hwSetup);

    Thank you.