Measure code execution time on ARM Cortex-M0 using KDS

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Measure code execution time on ARM Cortex-M0 using KDS

2,289件の閲覧回数
rafaalvescomp11
Contributor II

Good night,

 

I am using the Freedom KL25Z platform and the Kinetis Design Studio (KDS) software.

How can I measure code execution time in KDS?

 

Agradeço desde já,

Rafael

0 件の賞賛
返信
5 返答(返信)

2,277件の閲覧回数
jingpan
NXP TechSupport
NXP TechSupport

Hi rafaalvescomp11,

KDS hasn't this function. You use systick to count time or use gpio and oscillator to monitor.

 

Rregards,

Jing

2,248件の閲覧回数
rafaalvescomp11
Contributor II

Good afternoon,

 

I used a Systick, configured and programmed the Systick according to the images below and the current countdown value was 2410470, how do I convert this value to the execution time?

0 件の賞賛
返信

2,137件の閲覧回数
jingpan
NXP TechSupport
NXP TechSupport

Hi,

Systick clock frequency is equal to core clock frequency. For example, if the core run at 48M, the total time is 2410470/48M.

 

Regards,

Jing

0 件の賞賛
返信

2,093件の閲覧回数
rafaalvescomp11
Contributor II

Hi Jing,

Dividing 2410470 by 20.97152M which is the system clock I get as a result 0.11 seconds, but wouldn't the execution time of the attached example have to be close to 5s?

 

Regards,

Rafael 

0 件の賞賛
返信

2,266件の閲覧回数
rafaalvescomp11
Contributor II

Hi jingpan,

Thank you.

0 件の賞賛
返信