Task Suspension

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

Task Suspension

Jump to solution
717 Views
netra
Contributor IV

I am using mqx 3.5 (MCF52259),

I want to suspend a thread using shell command .

Can anyone tell me how to do??

1 Solution
406 Views
Martin_
NXP Employee
NXP Employee

https://community.freescale.com/message/329949#329949

for example, set an event or semaphore. the task would poll the event/semaphore in a while(1) loop and call _task_block() in response to it.  alternatively you can use task queue to suspend/resume tasks (_taskq_suspend_task(), _taskq_resume()).

View solution in original post

2 Replies
407 Views
Martin_
NXP Employee
NXP Employee

https://community.freescale.com/message/329949#329949

for example, set an event or semaphore. the task would poll the event/semaphore in a while(1) loop and call _task_block() in response to it.  alternatively you can use task queue to suspend/resume tasks (_taskq_suspend_task(), _taskq_resume()).

406 Views
DavidS
NXP Employee
NXP Employee

Hi Netra,

Wow that is very old version of MQX.  Please note latest download (http://www.freescale.com/mqx) is MQX4.0.2.GA.

In your MQX3.5\docs\mqx\MQXUG.pdf please review information on the following:

2.6.7 Task Queues

In addition to providing a scheduling mechanism, task queues provide a simple and efficient way to

synchronize tasks. You can suspend tasks in the task queue and remove them from the task queue.

Regards,

David