How to get periodic scheduled tasks (on the order of 10us)?

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

How to get periodic scheduled tasks (on the order of 10us)?

跳至解决方案
2,176 次查看
stephen_eng
Contributor III

Hello!

I've got the i.MX 8m Mini EVK, and for my application, I need to be able to schedule periodic tasks, with triggers on the order of 10s of microseconds. Now I realize that since the timing is short, and I also need it to be very consistent, I'm assuming that I'll have to be using the Cortex M4 core to handle these events. I've already played around with some of the MCUXpresso SDK examples, and I'm able to get a bunch of those examples running. There's a FreeRTOS SW Timer example which use the xTimerCreate function call, but after trying a few things out, and reading up on it, it seems that I will only be able to get tasks occurring every 1ms or so if I were to tune some parameters.

I guess my other options look like:

  • Find another FreeRTOS API to schedule tasks. I don't know if one exists, but if you know of something, please educate me
  • Use some kind of higher-rate hardware timer to provide interrupts for me. I don't know if the 8m Mini EVK provides something built in, or if I need to provide an external stimulus through a GPIO pin.

If anyone else has done something similar, let me know.

Thanks!

标签 (2)
0 项奖励
回复
1 解答
2,131 次查看
stephen_eng
Contributor III

I think I might have found it. It looks like I can leverage the GPT timer example in the MCUXpresso SDK.

MCUXpresso SDK API Reference Manual: GPT: General Purpose Timer 

在原帖中查看解决方案

0 项奖励
回复
1 回复
2,132 次查看
stephen_eng
Contributor III

I think I might have found it. It looks like I can leverage the GPT timer example in the MCUXpresso SDK.

MCUXpresso SDK API Reference Manual: GPT: General Purpose Timer 

0 项奖励
回复