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.

RTOS/CC3220S-LAUNCHXL: pthread_yield is missing in pthread.h

Part Number: CC3220S-LAUNCHXL
Other Parts Discussed in Thread: SYSBIOS

Tool/software: TI-RTOS

Dear Community

As it appears, pthread.h header (taken from simplelink_cc32xx_sdk_1_50_00_06/kernel/tirtos/packages/ti/sysbios/posix/) is missing pthread_yield function.
Searching for it in other headers gave the following occurrences:

simplelink_cc32xx_sdk_1_50_00_06/kernel/tirtos/packages/gnu/targets/arm/libs/install-native/arm-none-eabi/include/pthread.h:void        _EXFUN(pthread_yield, (void));
ccsv7/tools/compiler/gcc-arm-none-eabi-6-2017-q1-update/arm-none-eabi/include/pthread.h:void    _EXFUN(pthread_yield, (void));


E.g. it seems to exists but not available to the application. May I still use it? If no, what I may use instead to yield CPU time to tasks of any priority? As I understand, Task_yield yields to same priority tasks.

  • Hello,

    I suggest openning a thread to the TIROS guys.

    Anyway, as far as I know there is no API support for it.

    The yield will just give-up the thread's turn and you can reach the same by calling sleep. It will make the processor do rearrangement in the tasks and decide which task would be next. It is even possible that sleep calls yield internally.

    Regards,

    Shlomi