FreeRTOS Support Archive
The FreeRTOS support forum is used to obtain active support directly from Real
Time Engineers Ltd. In return for using our top quality software and services for
free, we request you play fair and do your bit to help others too! Sign up
to receive notifications of new support topics then help where you can.
This is a read only archive of threads posted to the FreeRTOS support forum.
The archive is updated every week, so will not always contain the very latest posts.
Use these archive pages to search previous posts. Use the Live FreeRTOS Forum
link to reply to a post, or start a new support thread.
[FreeRTOS Home] [Live FreeRTOS Forum] [FAQ] [Archive Top] [March 2013 Threads] Which FreeRTOS Function To Use?Posted by rog57 on March 11, 2013 Hi, After reading throught the FreeRTOS "A Guide..." I'm still unsure just the right way to implement what I'm needing to do, and hoping for some advice. It's fairly straightforward:
Task 1 runs every 30 seconds. When Task 2 runs, I need to suspend just Task 1 (no other task) until Task 2 is complete.
What's the best way to do this?
Thank you for any tips on implementing this.
RE: Which FreeRTOS Function To Use?Posted by rog57 on March 11, 2013 BTW - I should have noted that Task 2 runs non-scheduled (non-deterministic)
RE: Which FreeRTOS Function To Use?Posted by Friedrich Lobenstock on March 11, 2013 If task 1 can be suspended at any time, then just assign task 2 a higher priority and it will suspend task 1 every time it runs.
RE: Which FreeRTOS Function To Use?Posted by Richard Damon on March 12, 2013 It isn't totally clear what you mean, as, has been commented, if Task 2 has a higher priority than Task 1, then when ever task 2 is running task 1 is not (since FreeRTOS doesn't to my knowledge support multi-core processors). If what you mean is that every time you create a copy of Task2 with vTaskCreate or signal a semaphore/queue that Task2 is waiting on, you want Task 1 suspended until Task2 gets ready to end/block again, then use vTaskSuspend/Resume in Task2, with Task 1 as the target.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|