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.

Tiva-C project 0, looking at dynamic efficiency in project0

Hi, 

In project 0, I am trying to figure out how many clock cycles it takes to turn on red LED, and then blue LED. Is there a way in CCS to view this information? I tried to look at the disassembly code, but i"m not a pro at using CCS, and I wasn't able to find a simple explanation/tutorial in the wiki documentation. 

Thanks,

  • Hello Forum User,

    It depends on the code packing and coding style. If you write it in ASM code with a single GPIO Port then it could be down to a few clock cycles. In C it may be a little more than ASM. Also it depends on how the code is placed in the memory and how the prefetch buffer stores the data.

    Simple way is to connect scope probes on both pins and measure the time difference. Then divide it by the system clock to know the actual number of clocks. Again the first para holds true...

    Regards
    Amit