Cycle rutines in a task with Timmer

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

Cycle rutines in a task with Timmer

跳至解决方案
949 次查看
norbertoj
Contributor III

Hi, I'm using mqx tasks. I have a Control task that send messages to others tasks (Ethernet Client). I need that my control task send a message to Ethernet Client every 500 ms. In the rest of time, control task sends others messages to other tasks (depends of some interrupts) and do some calculations. Therefore, I need some help to how to use timmer functions in order to send a message to Ethernet Client using flags (interruptions) of the timmer.

I know that there are functions like _timer_start_periodic_every but I didn't find examples that help my code.

Sincerely, 

Norberto Jiménez

0 项奖励
回复
1 解答
834 次查看
danielchen
NXP TechSupport
NXP TechSupport

Hello Norberto Jimenez:

Yes, you can use _timer_start_periodic_every

Here is an example to create the timer component, start a periodic timer that sets an event every 20 milliseconds, and later cancel the timer.

pastedImage_1.png

pastedImage_2.png

pastedImage_3.png

Regards

Daniel

在原帖中查看解决方案

0 项奖励
回复
1 回复
835 次查看
danielchen
NXP TechSupport
NXP TechSupport

Hello Norberto Jimenez:

Yes, you can use _timer_start_periodic_every

Here is an example to create the timer component, start a periodic timer that sets an event every 20 milliseconds, and later cancel the timer.

pastedImage_1.png

pastedImage_2.png

pastedImage_3.png

Regards

Daniel

0 项奖励
回复