This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Task_create() returns null handle

Other Parts Discussed in Thread: CC3200

Hello,

I am developing application for CC3200 using TI RTOS. I have created one task statically using configuration script. Now from this task I am creating two more task dynamically by doing..

// Global Declaration..

Task_Handle handle1/*monitorTcpServer_Handle*/;
Task_Handle handle2/*monitorSelect_Handle*/;
Task_Params task_params;
Error_Block task_eb;

Void monitorTcpServer_Tsk(UArg arg0, UArg arg1);
Void monitorSelect_Tsk(UArg arg0, UArg arg1);

// Function to create task dynamically..
void create_task_new()
{
	starttask1 = TRUE;
	starttask2 = TRUE;

    Log_e("==>> Creating Monitor Tcp Server Task..\n");
	Error_init(&task_eb);
	Task_Params_init(&task_params);
	task_params.stackSize = 1024;
	task_params.priority = 2;
    //task_params.instance->name = "monitorTcpServer_Handle_obj";
    handle1 = Task_create(monitorTcpServer_Tsk, &task_params, &task_eb);
    if(handle1 == NULL)
    	Log_e("Task Creation Failed.\n");

    Log_e("==>> Creating Monitor Select Task..\n");
    Error_init(&task_eb);
    Task_Params_init(&task_params);
    task_params.stackSize = 1024;
    task_params.priority = 2;
    //task_params.instance->name = "monitorSelect_Handle_obj";
    handle2 = Task_create(monitorSelect_Tsk, &task_params, &task_eb);
    if(handle2 == NULL)
        Log_e("Task Creation Failed.\n");

}

I am calling create_task_new() from the task which I have created statically. The problem is Task_create() returns NULL every time. Am I missing anything..??