Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
10 years, 10 months ago.
Run 2 loops at the same time
Hi,
I am using the LPC1768 for a project, I am trying to run 2 while loops at the same time. Is this possible and if so how do I do it;
Regards, Nick
1 Answer
10 years, 10 months ago.
There are multiple solutions: you can use an RTOS, you can often merge the loops into one, you can use a Ticker to address the second loop while you main is in the first loop or you can perhaps use some sort of interrupt instead of polling for a specific condition in your while loops. Give some more info on what you are trying to do.