diff --git a/flight/PiOS.osx/osx/Libraries/FreeRTOS/Source/task.c b/flight/PiOS.osx/osx/Libraries/FreeRTOS/Source/task.c index 9a32ec7ff..13d6713f8 100644 --- a/flight/PiOS.osx/osx/Libraries/FreeRTOS/Source/task.c +++ b/flight/PiOS.osx/osx/Libraries/FreeRTOS/Source/task.c @@ -57,7 +57,8 @@ licensing and training services. */ - +#include +#include #include #include #include @@ -1988,7 +1989,8 @@ static portTASK_FUNCTION( prvIdleTask, pvParameters ) without the overhead of a separate task. NOTE: vApplicationIdleHook() MUST NOT, UNDER ANY CIRCUMSTANCES, CALL A FUNCTION THAT MIGHT BLOCK. */ - while(clock() < (last_idle_time + 1)); + while(clock() < (last_idle_time + 1)) + sched_yield(); last_idle_time = clock(); vApplicationIdleHook(); }