How to get the system tick count in MQX 5?

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

How to get the system tick count in MQX 5?

Jump to solution
2,224 Views
WilliamLiSH
Contributor II

Hi,

I would like to add the elapsed time after power on in the debug message to specify the time sequence of code running and I prefer to use the system tick. However, I did not find the function interface to get current system tick.

Could you please help specify which interface should be used? Or is there any alternative solution for this purpose?

Hope to get your reply soon.

Tags (1)
0 Kudos
Reply
1 Solution
2,173 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi @WilliamLiSH 

 

For elapsed time,  I would suggest you use _time_get_elapsed() in second/millisecond time.

or in tick time with  _time_get_elapsed_ticks().

 

Regards

Daniel

View solution in original post

0 Kudos
Reply
2 Replies
2,174 Views
danielchen
NXP TechSupport
NXP TechSupport

Hi @WilliamLiSH 

 

For elapsed time,  I would suggest you use _time_get_elapsed() in second/millisecond time.

or in tick time with  _time_get_elapsed_ticks().

 

Regards

Daniel

0 Kudos
Reply
2,135 Views
WilliamLiSH
Contributor II

Thanks for your reply. I use _time_get_elapsed_us() and it works now.

0 Kudos
Reply