Upgrading to FreeRTOS V8.x.x
From FreeRTOS V7.x.x
FreeRTOS V8 is Backward Compatible with FreeRTOS V7FreeRTOS V8.x.x is a drop-in compatible replacement for FreeRTOS V7.x, although a change to the type used to reference character strings may result in application code generating a few (easily clearable) compiler warnings after the upgrade, and an updated typedef naming convention means use of the old typedef names is now discouraged (see config configENABLE_BACKWARD_COMPATIBILITY).
New and updated in FreeRTOS V8
- Introducing Direct to Task Notifications (from V8.2.0)
- Introducing Event Groups
- Centralised Deferred Interrupt Processing
- Use of stdint.h
- Character Pointers
- Trace and Visualisation
- New FreeRTOS Defined typedefs Names
FreeRTOS V8 provides a centralised deferred interrupt processing mechanism – allowing deferred processing to be performed in the RTOS daemon task (formally called the timer daemon task), removing the burden of implementing deferred interrupt mechanisms from the user.
Previously, and in line with good software engineering practice, the FreeRTOS coding standard did not permit the use of char types that were not explicitly qualified as either signed or unsigned. As a result char pointers used to reference strings required casts, as did the use of any standard string handling functions. The casts ensured compiler warnings were not generated by compilers that defaulted unqualified char types to be signed or compilers that defaulted unqualified char types to be unsigned.
As it has in later MISRA standards, this rule has now been relaxed, and unqualified char types are now permitted, but only when:
- The char is used to point to a human readable text string.
- The char is used to hold a single ASCII character.
Note: FreeRTOS v8.0.0 requires FreeRTOS+Trace version 2.6 or later.
NOTE: To ensure backward compatibility the old names are maintained within the code, but the use of the old names is strongly discouraged (see config configENABLE_BACKWARD_COMPATIBILITY).
|Old Name||New Name||Description|
|xTaskHandle||TaskHandle_t||Used to reference tasks.|
|xQueueHandle||QueueHandle_t||Used to reference queues.|
|xSemaphoreHandle||SemaphoreHandle_t||Used to reference binary, counting, recursive and mutex type semaphores.|
|xTimerHandle||TimerHandle_t||Used to reference software timers.|
|xCoRoutineHandle||CoRoutineHandle_t||Used to reference co-routines.|
|portTickType||TickType_t||Used to hold tick count values|
|portBASE_TYPE||BaseType_t||Defined to the most efficient signed type for the architecture.|
|unsigned portBASE_TYPE||UBaseType_t||Defined to the most efficient unsigned type for the architecture.|
|xQueueSetHandle||QueueSetHandle_t||Used to reference a queue set.|
|xQueueSetMemberHandle||QueueSetMemberHandle_t||Used to reference a member of a queue set, which can be a queue or any of the semaphore types.|
|xMemoryRegion||MemoryRegion_t||Used with ports that support memory protection.|
|xTaskParameters||TaskParameters_t||Used with ports that support memory protection.|
|xTaskStatusType||TaskStatus_t||Used in with the uxTaskGetSystemState() function.|
|pdTASK_HOOK_CODE||TaskHookFunction_t||Used with the task tag functions (for example vTaskSetApplicationTag().|
|pdTASK_CODE||TaskFunction_t||Used with the xTaskCreate() function.|
|tmrTIMER_CALLBACK||TimerCallbackFunction_t||Used with the xTimerCreate() function.|
|xTimeOutType||TimeOut_t||For advanced users only.|