Any NXP SDK API to provide delay in microseconds resolution?

cancel
Showing results for 
Search instead for 
Did you mean: 

Any NXP SDK API to provide delay in microseconds resolution?

179 Views
misterbee
Contributor II

I wonder if NXP SDK for LPC5411X provides any HAL API to introduce delay in microseconds resolutions?

0 Kudos
4 Replies

155 Views
jay_heng
NXP Employee
NXP Employee

There is common API: SDK_DelayAtLeastUs(), it might not be accurate,but the resolution is us.

0 Kudos

174 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

HI misterbee 

SDK doesn't have such an API

We suggest using timer to get a accurate delay.

Thanks,

Jun Zhang

0 Kudos

159 Views
misterbee
Contributor II

Thank you but how timer can be used as delay?

I am talking about delay that needed in between e.g. I2C command. I don't think timer is relevant.

0 Kudos

154 Views
jay_heng
NXP Employee
NXP Employee

Enable HW timer first, then poll timer counter value until the delay time is met.

0 Kudos