In built delay function

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

In built delay function

3,469 次查看
durgasivakrishn
Contributor III

Hi,

I am using MK66FN2M0VLQ18 for my application I need to use milliseconds and microseconds delay in the application I want to use inbuilt delay functions as in STM32F7 (HAL_Delay) I am not interested to use PIT Timers for this purpose can anyone suggest me something. And is there any inbuilt function to have such kind of delay in MK66 SDK.

Looking forward to your reply,

Regards,

B.Durga sivakrishna

0 项奖励
回复
3 回复数

3,087 次查看
jingpan
NXP TechSupport
NXP TechSupport

Hi Durga,

No, NXP Kinetis SDK hasn't such a function. But I think this is not a big problem. HAL_Delay use Systick to count time. It looks like

__weak void HAL_Delay(__IO uint32_t Delay)
{
  uint32_t tickstart = 0;
  tickstart = HAL_GetTick();
  while((HAL_GetTick() - tickstart) < Delay)
  {
  }
}

You can do it by yourself.

Regards,

Jing

3,087 次查看
durgasivakrishn
Contributor III

Hi Jing,

Thanks for your reply, my doubt clarified.

Regards,

B.Durga sivarkrishna

0 项奖励
回复

3,087 次查看
mjbcswitzerland
Specialist V
0 项奖励
回复