Quality RTOS & Embedded Software

 Real time embedded FreeRTOS RSS feed 
Quick Start Supported MCUs PDF Books Trace Tools Ecosystem TCP & FAT




Loading

vTaskSetApplicationTaskTag()

Posted by jinx on April 16, 2010
I was looking at the example on vTaskSetApplicationTaskTag() in the FreeRTOS reference manual and I have a question about the last line in that example (Listing 42):

#define traceTASK_SWITCHED_OUT() xTaskCAllApplicationTaskHook( pxCurrentTCB, 0)

This #define, as I understand it, globally enables all tasks to run their defined registered callbacks. Am I correct? If so, what about tasks that do not define a callback? Does the kernel 'ignore' calling the task-hooks of those asks that do not define the hook callbacks or does it force all tasks to define the hook-callbacks?

RE: vTaskSetApplicationTaskTag()

Posted by Dave on April 16, 2010
If pxCurrentTCB does not have a tag defined then xTaskCallApplicationTaskHook() will return pdFAIL. It is safe.


[ Back to the top ]    [ About FreeRTOS ]    [ Sitemap ]    [ ]




Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.

Latest News

FreeRTOS kernel V10 is available for immediate download. Now MIT licensed.


FreeRTOS Partners

ARM Connected RTOS partner for all ARM microcontroller cores

IAR Partner

Microchip Premier RTOS Partner

RTOS partner of NXP for all NXP ARM microcontrollers

STMicro RTOS partner supporting ARM7, ARM Cortex-M3, ARM Cortex-M4 and ARM Cortex-M0

Texas Instruments MCU Developer Network RTOS partner for ARM and MSP430 microcontrollers

OpenRTOS and SafeRTOS