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.

CC2640R2F: Problems encountered when creating new tasks using CC2640R2F

Part Number: CC2640R2F

Create a new task using the CC2640R2F SDK, in addition to the original (SimpleBLESpheral_createTask), create a user task.

I have created a new task and modified the global macro definition (ICALL-MAX-NUM-ENTITIES=7) (ICALL-MAX-NUM_TASKS=4),

The task can run, I imitated (SimpleBLESpheral_createTask) and used

ICall_ RegisterApp (&selfEntity,&syncEvent);

Event_ Pend (syncEvent, Event_Id_NONE, SBP_ALL-EVENTS, ICALL_TIMEOUT FOREVER);

Can also successfully send and receive events and queues.

However, when using "osal_snv_write (0x80, 1, (uint8 *)&data);" in a new task, it will get stuck in this function and not come out, which will be discovered during simulation.

This operation can be placed in 'SimpleBLESpheral_Task'.

May I ask if my configuration is correct? Do you need any other configurations?

   // Configure task
    Task_Params taskParams;
    Task_Params_init(&taskParams);
    taskParams.stack = kiwiTaskStack;
    taskParams.stackSize = KIWI_TASK_STACK_SIZE;
    taskParams.priority = KIWI_TASK_PRIORITY;

    Task_construct(&kiwiTask, AppKiwi_taskFxn, &taskParams, NULL);

  • Hi Alex,

    Seems that the way you've created the new task is working.

    Concerning the osal_snv_write() function, I suggest you to read the dedicated chapter in the user's guide, go to he Application chapter, then Memory Management and finally Flash there you could find a section on Using Simple NV for Flash Storage.

    Does the task works properly without this function? Are you able to use the stack properly? (are you using blestack or ble5stack?)

    What you can do to help you debugging is using the ROV tool on CCS, it will help you to know which task is running and where are you exactly stuck.

    regards,

  • Mostly osal_SNV_WRITE What will block, false death, has the information? 

  • Hi Alex,

    What's the remaining size of flash do you have for your example?

    Are you able to read properly with osal_snv? Have you configured SNV followed the guide steps?

    regards,