Time elapsed

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Time elapsed

Jump to solution
1,070 Views
anshun
Contributor II

Hi,

I am using mcuexpresso for my project.

How to calculate the time elapsed in microseconds .

Is there any API to get the count or time?

0 Kudos
Reply
1 Solution
1,060 Views
nickwallis
Senior Contributor I

You can use the DWT as a cycle counter, either to measure execution time or for delays.

https://mcuoneclipse.com/2017/01/30/cycle-counting-on-arm-cortex-m-with-dwt/

-Nick

 

View solution in original post

1 Reply
1,061 Views
nickwallis
Senior Contributor I

You can use the DWT as a cycle counter, either to measure execution time or for delays.

https://mcuoneclipse.com/2017/01/30/cycle-counting-on-arm-cortex-m-with-dwt/

-Nick