prvTaskExitError(void) function

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

prvTaskExitError(void) function

3,713件の閲覧回数
davidzhu
Contributor III

 

I am running a task but here the execution ends in prvTaskExitError(void) , how to solve this problem.

The function is: 

/*-----------------------------------------------------------*/

static void prvTaskExitError( void )
{
volatile uint32_t ulDummy = 0;

/* 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();

 

Please throw some light on this

Thanks

0 件の賞賛
返信
1 返信

3,689件の閲覧回数
danielchen
NXP TechSupport
NXP TechSupport

Hi @davidzhu :

 

prvTaskExitError() should only ever be entered if an application task attempts to return or exit.

Please refer to below link

https://www.freertos.org/implementing-a-FreeRTOS-task.html

Maybe some tasks in your project return from their implementing function.

If you want to terminate a task, please can  vTaskDelete(NULL); 

 

Regards

Daniel

 

0 件の賞賛
返信