dsPIC33E/os_APIs.c
// Function name	: OSSetTaskContext()
// Author           : Fabian Kung
// Last modified	: 9 March 2019
// Purpose          : Set the task's State and Timer variables.
// Arguments		: ptrTaskData = A pointer to the structure structTASK.
//                  nState = Next state of the task.
//                  nTimer = Timer, the no. of clock ticks before the task
//                  executes again.
// Return           : None.

Function name  : OSSetTaskContext()
Author           : Fabian Kung
Last modified  : 9 March 2019
Purpose          : Set the task's State and Timer variables.
Arguments              : ptrTaskData = A pointer to the structure structTASK.
nState = Next state of the task.
nTimer = Timer, the no. of clock ticks before the task
executes again.
Return           : None.
Function name : OSSetTaskContext () Author : Fabian Kung Last modified : 9 March 2019 Purpose : Set the task ' s State and Timer variables . Arguments : ptrTaskData = A pointer to the structure structTASK . nState = Next state of the task . nTimer = Timer the no . of clock ticks before the task executes again . Return : None .
void OSSetTaskContext(TASK_ATTRIBUTE *ptrTaskData, INT16 nState, INT16 nTimer)
{
	ptrTaskData->nState = nState;
	ptrTaskData->nTimer = nTimer;
    gunTaskExecutedCount--;
}
void OSSetTaskContext ( TASK_ATTRIBUTE * ptrTaskData , INT16 nState , INT16 nTimer ) { ptrTaskData -> nState = nState ; ptrTaskData -> nTimer = nTimer ; gunTaskExecutedCount -- ; }
Function name  : OSSetTaskContext()
Author           : Fabian Kung
Last modified  : 9 March 2019
Purpose          : Set the task's State and Timer variables.
Function name : OSSetTaskContext () Author : Fabian Kung Last modified : 9 March 2019 Purpose : Set the task ' s State and Timer variables .