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.

Time delay / Clock cycles for C-lang Instructions - TMS470R1B1M

Other Parts Discussed in Thread: TMS470R1B1M

Hi,

I just started to work with the the TMS470R1B1M microcontroller. I am looking to generate time delays using a timer/counters. We are using a 60Mhz clock and I am looking to generate a delay of  5 nano seconds. How can I find out the time taken for an empty For loop or empty While loop if I were to use these instead to generate this delay of small magnitude? How many clock cycles for each? What is a better way for timer usage, HET timer or RTI?

Thanks

Geeta

  • Geeta,

     

    Please be aware that the TMS470R1x series (tms470r1b1m) is not recommended for new designs.  Please see the full 'NRDN' notice here.

    Soon TI will be launching the new TMS470M series of microcontrollers.  This series will feature greater ARM CPU performance and a similar peripherial set to the TMS470R1 Series of microcontrollers.  Please come back soon for more information about the TMS470M Series of microcontrollers.  The product preview for the first two microcontrollers in the TMS470M series is available here: TMS470MF0660x - SPNS157. The TMS470M Series Technical Reference Manual is available here: TMS470M TRM.

    Best Regards,

     

    Jean-Marc Mifsud

  • Hi Jean,

    This is actually an old product and not new development. Therefore I need support on this particular series of microcontroller itself. Can you please give me the information regarding my query wrt instruction times (from my previous post).

    Thanks

    Geeta

  • Geeta,

     

    In your original post you said that the device is running at 60Mhz. This is ~17 ns clock cycle.
    You are trying to generate a 5ns delay by software.

    This is impossible to achieve by hardware or by software.
    Can you confirm the 5ns delay?

    Thanks and Regards,

    Jean-Marc Mifsud

  • Hi Jean,

    That is right. I am looking at alternatives for small delays ( not using timers) trying to get the size of instructions like 'for' loop etc. For example:

    For(i=0; i<100; i++)

    {

    //do nothing ;

    }

    I do realise that I cannot get that small delays with the clock that I am using but looking to see what delays different instructions will give me. Is there any documentation for this?

    Thank You for your earlier prompt replies.

    Geeta

  • Hi Jean,

    I am still waiting to hear from you regarding my query for clock cycle times for instructions.

    Thanks

    Geeta

  • Geeta,

     

    You will found all timing and cycle count information for all instructions in the ARM7 Technical Reference Manual at the following link.

    http://infocenter.arm.com/help/index.jsp

    Look for ARM7TDMI, R4p1, Chapter 6. Instruction Cycle Timing.

     

    Regards,

    Jean-Marc Mifsud