【小记】FreeRTOS任务创建后但任务中为空时运行错误

FreeRTOS任务创建后但任务中无语句为空时运行错误

会死在文件<port.c>中下边函数处

static void prvTaskExitError( void )
{
/* A function that implements a task must not exit or attempt to return to
its caller as there is nothing to return to. If a task wants to exit it
should instead call vTaskDelete( NULL ).

Artificially force an assert() to be triggered if configASSERT() is
defined, then stop here so application writers can catch the error. */
configASSERT( uxCriticalNesting == ~0UL );
portDISABLE_INTERRUPTS();
for( ;; );
}

原文地址:https://www.cnblogs.com/skullboyer/p/9159208.html