/*\r
- FreeRTOS V8.2.3 - Copyright (C) 2015 Real Time Engineers Ltd.\r
+ FreeRTOS V9.0.0rc2 - Copyright (C) 2016 Real Time Engineers Ltd.\r
All rights reserved\r
\r
VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION.\r
#error Missing definition: configUSE_TICK_HOOK must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
#endif\r
\r
+#ifndef configUSE_16_BIT_TICKS\r
+ #error Missing definition: configUSE_16_BIT_TICKS must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+#endif\r
+\r
+#ifndef configMAX_PRIORITIES\r
+ #error configMAX_PRIORITIES must be defined to be greater than or equal to 1.\r
+#endif\r
+\r
+#ifndef configUSE_CO_ROUTINES\r
+ #define configUSE_CO_ROUTINES 0\r
+#endif\r
+\r
#ifndef INCLUDE_vTaskPrioritySet\r
- #error Missing definition: INCLUDE_vTaskPrioritySet must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+ #define INCLUDE_vTaskPrioritySet 0\r
#endif\r
\r
#ifndef INCLUDE_uxTaskPriorityGet\r
- #error Missing definition: INCLUDE_uxTaskPriorityGet must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+ #define INCLUDE_uxTaskPriorityGet 0\r
#endif\r
\r
#ifndef INCLUDE_vTaskDelete\r
- #error Missing definition: INCLUDE_vTaskDelete must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+ #define INCLUDE_vTaskDelete 0\r
#endif\r
\r
#ifndef INCLUDE_vTaskSuspend\r
- #error Missing definition: INCLUDE_vTaskSuspend must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+ #define INCLUDE_vTaskSuspend 0\r
#endif\r
\r
#ifndef INCLUDE_vTaskDelayUntil\r
- #error Missing definition: INCLUDE_vTaskDelayUntil must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+ #define INCLUDE_vTaskDelayUntil 0\r
#endif\r
\r
#ifndef INCLUDE_vTaskDelay\r
- #error Missing definition: INCLUDE_vTaskDelay must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+ #define INCLUDE_vTaskDelay 0\r
#endif\r
\r
-#ifndef configUSE_16_BIT_TICKS\r
- #error Missing definition: configUSE_16_BIT_TICKS must be defined in FreeRTOSConfig.h as either 1 or 0. See the Configuration section of the FreeRTOS API documentation for details.\r
+#ifndef INCLUDE_xTaskGetIdleTaskHandle\r
+ #define INCLUDE_xTaskGetIdleTaskHandle 0\r
#endif\r
\r
-#ifndef configMAX_PRIORITIES\r
- #error configMAX_PRIORITIES must be defined to be greater than or equal to 1.\r
+#ifndef INCLUDE_xTaskAbortDelay\r
+ #define INCLUDE_xTaskAbortDelay 0\r
#endif\r
\r
-#ifndef configUSE_CO_ROUTINES\r
- #define configUSE_CO_ROUTINES 0\r
+#ifndef INCLUDE_xQueueGetMutexHolder\r
+ #define INCLUDE_xQueueGetMutexHolder 0\r
#endif\r
\r
-#if configUSE_CO_ROUTINES != 0\r
- #ifndef configMAX_CO_ROUTINE_PRIORITIES\r
- #error configMAX_CO_ROUTINE_PRIORITIES must be greater than or equal to 1.\r
- #endif\r
+#ifndef INCLUDE_xSemaphoreGetMutexHolder\r
+ #define INCLUDE_xSemaphoreGetMutexHolder INCLUDE_xQueueGetMutexHolder\r
#endif\r
\r
-#ifndef INCLUDE_xTaskGetIdleTaskHandle\r
- #define INCLUDE_xTaskGetIdleTaskHandle 0\r
+#ifndef INCLUDE_xTaskGetTaskHandle\r
+ #define INCLUDE_xTaskGetTaskHandle 0\r
#endif\r
\r
-#ifndef INCLUDE_xTimerGetTimerDaemonTaskHandle\r
- #define INCLUDE_xTimerGetTimerDaemonTaskHandle 0\r
+#ifndef INCLUDE_uxTaskGetStackHighWaterMark\r
+ #define INCLUDE_uxTaskGetStackHighWaterMark 0\r
#endif\r
\r
-#ifndef INCLUDE_xQueueGetMutexHolder\r
- #define INCLUDE_xQueueGetMutexHolder 0\r
+#ifndef INCLUDE_eTaskGetState\r
+ #define INCLUDE_eTaskGetState 0\r
#endif\r
\r
-#ifndef INCLUDE_xSemaphoreGetMutexHolder\r
- #define INCLUDE_xSemaphoreGetMutexHolder INCLUDE_xQueueGetMutexHolder\r
+#ifndef INCLUDE_xTaskResumeFromISR\r
+ #define INCLUDE_xTaskResumeFromISR 1\r
#endif\r
\r
-#ifndef INCLUDE_pcTaskGetTaskName\r
- #define INCLUDE_pcTaskGetTaskName 0\r
+#ifndef INCLUDE_xTimerPendFunctionCall\r
+ #define INCLUDE_xTimerPendFunctionCall 0\r
#endif\r
\r
-#ifndef configUSE_APPLICATION_TASK_TAG\r
- #define configUSE_APPLICATION_TASK_TAG 0\r
+#ifndef INCLUDE_xTaskGetSchedulerState\r
+ #define INCLUDE_xTaskGetSchedulerState 0\r
#endif\r
\r
-#ifndef configNUM_THREAD_LOCAL_STORAGE_POINTERS\r
- #define configNUM_THREAD_LOCAL_STORAGE_POINTERS 0\r
+#ifndef INCLUDE_xTaskGetCurrentTaskHandle\r
+ #define INCLUDE_xTaskGetCurrentTaskHandle 0\r
#endif\r
\r
-#ifndef INCLUDE_uxTaskGetStackHighWaterMark\r
- #define INCLUDE_uxTaskGetStackHighWaterMark 0\r
+#if configUSE_CO_ROUTINES != 0\r
+ #ifndef configMAX_CO_ROUTINE_PRIORITIES\r
+ #error configMAX_CO_ROUTINE_PRIORITIES must be greater than or equal to 1.\r
+ #endif\r
#endif\r
\r
-#ifndef INCLUDE_eTaskGetState\r
- #define INCLUDE_eTaskGetState 0\r
+#ifndef configUSE_DAEMON_TASK_STARTUP_HOOK\r
+ #define configUSE_DAEMON_TASK_STARTUP_HOOK 0\r
+#endif\r
+\r
+#ifndef configUSE_APPLICATION_TASK_TAG\r
+ #define configUSE_APPLICATION_TASK_TAG 0\r
+#endif\r
+\r
+#ifndef configNUM_THREAD_LOCAL_STORAGE_POINTERS\r
+ #define configNUM_THREAD_LOCAL_STORAGE_POINTERS 0\r
#endif\r
\r
#ifndef configUSE_RECURSIVE_MUTEXES\r
#error configMAX_TASK_NAME_LEN must be set to a minimum of 1 in FreeRTOSConfig.h\r
#endif\r
\r
-#ifndef INCLUDE_xTaskResumeFromISR\r
- #define INCLUDE_xTaskResumeFromISR 1\r
-#endif\r
-\r
-#ifndef INCLUDE_xTimerPendFunctionCall\r
- #define INCLUDE_xTimerPendFunctionCall 0\r
-#endif\r
-\r
#ifndef configASSERT\r
#define configASSERT( x )\r
#define configASSERT_DEFINED 0\r
\r
#endif /* configUSE_TIMERS */\r
\r
-#ifndef INCLUDE_xTaskGetSchedulerState\r
- #define INCLUDE_xTaskGetSchedulerState 0\r
-#endif\r
-\r
-#ifndef INCLUDE_xTaskGetCurrentTaskHandle\r
- #define INCLUDE_xTaskGetCurrentTaskHandle 0\r
-#endif\r
-\r
-\r
#ifndef portSET_INTERRUPT_MASK_FROM_ISR\r
#define portSET_INTERRUPT_MASK_FROM_ISR() 0\r
#endif\r
#if ( configQUEUE_REGISTRY_SIZE < 1 )\r
#define vQueueAddToRegistry( xQueue, pcName )\r
#define vQueueUnregisterQueue( xQueue )\r
- #define pcQueueGetQueueName( xQueue )\r
+ #define pcQueueGetName( xQueue )\r
#endif\r
\r
#ifndef portPOINTER_SIZE_TYPE\r
#endif\r
\r
#ifndef traceTASK_DELAY_UNTIL\r
- #define traceTASK_DELAY_UNTIL()\r
+ #define traceTASK_DELAY_UNTIL( x )\r
#endif\r
\r
#ifndef traceTASK_DELAY\r
#define portYIELD_WITHIN_API portYIELD\r
#endif\r
\r
-#ifndef pvPortMallocAligned\r
- #define pvPortMallocAligned( x, puxPreallocatedBuffer ) ( ( ( puxPreallocatedBuffer ) == NULL ) ? ( pvPortMalloc( ( x ) ) ) : ( puxPreallocatedBuffer ) )\r
-#endif\r
-\r
-#ifndef vPortFreeAligned\r
- #define vPortFreeAligned( pvBlockToFree ) vPortFree( pvBlockToFree )\r
-#endif\r
-\r
#ifndef portSUPPRESS_TICKS_AND_SLEEP\r
#define portSUPPRESS_TICKS_AND_SLEEP( xExpectedIdleTime )\r
#endif\r
#endif\r
\r
#ifndef configSUPPORT_STATIC_ALLOCATION\r
+ /* Defaults to 0 for backward compatibility. */\r
#define configSUPPORT_STATIC_ALLOCATION 0\r
#endif\r
\r
+#ifndef configSUPPORT_DYNAMIC_ALLOCATION\r
+ /* Defaults to 1 for backward compatibility. */\r
+ #define configSUPPORT_DYNAMIC_ALLOCATION 1\r
+#endif\r
+\r
+/* Sanity check the configuration. */\r
+#if( configUSE_TICKLESS_IDLE != 0 )\r
+ #if( INCLUDE_vTaskSuspend != 1 )\r
+ #error INCLUDE_vTaskSuspend must be set to 1 if configUSE_TICKLESS_IDLE is not set to 0\r
+ #endif /* INCLUDE_vTaskSuspend */\r
+#endif /* configUSE_TICKLESS_IDLE */\r
+\r
+#if( ( portUSING_MPU_WRAPPERS == 1 ) && ( configSUPPORT_STATIC_ALLOCATION != 1 ) )\r
+ #error configSUPPORT_STATIC_ALLOCATION must be set to 1 in FreeRTOSConfig.h when the MPU is used.\r
+#endif\r
+\r
+#if( ( configSUPPORT_STATIC_ALLOCATION == 0 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 0 ) )\r
+ #error configSUPPORT_STATIC_ALLOCATION and configSUPPORT_DYNAMIC_ALLOCATION cannot both be 0, but can both be 1.\r
+#endif\r
+\r
#if( ( configUSE_RECURSIVE_MUTEXES == 1 ) && ( configUSE_MUTEXES != 1 ) )\r
- #error configUSE_MUTEXES must be set to 1 to use recursive mutexes\r
+ #error configUSE_MUTEXES must be set to 1 to use recursive mutexes\r
#endif\r
\r
#if( portTICK_TYPE_IS_ATOMIC == 0 )\r
#define xCoRoutineHandle CoRoutineHandle_t\r
#define pdTASK_HOOK_CODE TaskHookFunction_t\r
#define portTICK_RATE_MS portTICK_PERIOD_MS\r
+ #define pcTaskGetTaskName pcTaskGetName\r
+ #define pcTimerGetTimerName pcTimerGetName\r
\r
/* Backward compatibility within the scheduler code only - these definitions\r
are not really required but are included for completeness. */\r
#define xList List_t\r
#endif /* configENABLE_BACKWARD_COMPATIBILITY */\r
\r
+#if( configUSE_ALTERNATIVE_API != 0 )\r
+ #error The alternative API was deprecated some time ago, and was removed in FreeRTOS V9.0 0\r
+#endif\r
+\r
/* Set configUSE_TASK_FPU_SUPPORT to 0 to omit floating point support even\r
if floating point hardware is otherwise supported by the FreeRTOS port in use.\r
This constant is not supported by all FreeRTOS ports that include floating\r
StaticMiniListItem_t xDummy3;\r
} StaticList_t;\r
\r
-/* For data hiding purposes. */\r
-typedef enum\r
-{\r
- eNothing = 0\r
-} eDummy;\r
-\r
/*\r
- * In line with software engineering best practice, FreeRTOS implements a strict\r
- * data hiding policy, so the real task control block (TCB) structure is not\r
- * accessible to the application code. However, if the application writer wants\r
- * to statically allocate a TCB then the size of the TCB needs to be know. The\r
- * dummy TCB structure below is used for this purpose. Its size will allows\r
- * match the size of the real TCB, no matter what the FreeRTOSConfig.h settings.\r
+ * In line with software engineering best practice, especially when supplying a\r
+ * library that is likely to change in future versions, FreeRTOS implements a\r
+ * strict data hiding policy. This means the Task structure used internally by\r
+ * FreeRTOS is not accessible to application code. However, if the application\r
+ * writer wants to statically allocate the memory required to create a task then\r
+ * the size of the task object needs to be know. The StaticTask_t structure\r
+ * below is provided for this purpose. Its sizes and alignment requirements are\r
+ * guaranteed to match those of the genuine structure, no matter which\r
+ * architecture is being used, and no matter how the values in FreeRTOSConfig.h\r
+ * are set. Its contents are somewhat obfuscated in the hope users will\r
+ * recognise that it would be unwise to make direct use of the structure members.\r
*/\r
typedef struct xSTATIC_TCB\r
{\r
void *pxDummy14;\r
#endif\r
#if( configNUM_THREAD_LOCAL_STORAGE_POINTERS > 0 )\r
- void pvDummy15[ configNUM_THREAD_LOCAL_STORAGE_POINTERS ];\r
+ void *pvDummy15[ configNUM_THREAD_LOCAL_STORAGE_POINTERS ];\r
#endif\r
#if ( configGENERATE_RUN_TIME_STATS == 1 )\r
uint32_t ulDummy16;\r
#endif\r
#if ( configUSE_TASK_NOTIFICATIONS == 1 )\r
uint32_t ulDummy18;\r
- eDummy eDummy19;\r
+ uint8_t ucDummy19;\r
#endif\r
- #if ( configSUPPORT_STATIC_ALLOCATION == 1 )\r
- UBaseType_t uxDummy20;\r
+ #if( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )\r
+ uint8_t uxDummy20;\r
#endif\r
\r
-} StaticTCB_t;\r
+} StaticTask_t;\r
\r
/*\r
- * In line with software engineering best practice, FreeRTOS implements a strict\r
- * data hiding policy, so the queue structure is not accessible to the\r
- * application code. However, if the application writer wants to statically\r
- * allocate a queue (or one of the other objects that uses a queue as its base\r
- * structure) then the size of the queue needs to be know. The dummy queue\r
- * structure below is used for this purpose. Its size will allows match the\r
- * size of the real queue, no matter what the FreeRTOSConfig.h settings.\r
+ * In line with software engineering best practice, especially when supplying a\r
+ * library that is likely to change in future versions, FreeRTOS implements a\r
+ * strict data hiding policy. This means the Queue structure used internally by\r
+ * FreeRTOS is not accessible to application code. However, if the application\r
+ * writer wants to statically allocate the memory required to create a queue\r
+ * then the size of the queue object needs to be know. The StaticQueue_t\r
+ * structure below is provided for this purpose. Its sizes and alignment\r
+ * requirements are guaranteed to match those of the genuine structure, no\r
+ * matter which architecture is being used, and no matter how the values in\r
+ * FreeRTOSConfig.h are set. Its contents are somewhat obfuscated in the hope\r
+ * users will recognise that it would be unwise to make direct use of the\r
+ * structure members.\r
*/\r
typedef struct xSTATIC_QUEUE\r
{\r
} u;\r
\r
StaticList_t xDummy3[ 2 ];\r
- UBaseType_t uxDummy4[ 5 ];\r
+ UBaseType_t uxDummy4[ 3 ];\r
+ uint8_t ucDummy5[ 2 ];\r
+\r
+ #if( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )\r
+ uint8_t ucDummy6;\r
+ #endif\r
\r
#if ( configUSE_QUEUE_SETS == 1 )\r
void *pvDummy7;\r
#endif\r
\r
#if ( configUSE_TRACE_FACILITY == 1 )\r
- UBaseType_t uxDummy5;\r
- uint8_t ucDummy6;\r
+ UBaseType_t uxDummy8;\r
+ uint8_t ucDummy9;\r
+ #endif\r
+\r
+} StaticQueue_t;\r
+typedef StaticQueue_t StaticSemaphore_t;\r
+\r
+/*\r
+ * In line with software engineering best practice, especially when supplying a\r
+ * library that is likely to change in future versions, FreeRTOS implements a\r
+ * strict data hiding policy. This means the event group structure used\r
+ * internally by FreeRTOS is not accessible to application code. However, if\r
+ * the application writer wants to statically allocate the memory required to\r
+ * create an event group then the size of the event group object needs to be\r
+ * know. The StaticEventGroup_t structure below is provided for this purpose.\r
+ * Its sizes and alignment requirements are guaranteed to match those of the\r
+ * genuine structure, no matter which architecture is being used, and no matter\r
+ * how the values in FreeRTOSConfig.h are set. Its contents are somewhat\r
+ * obfuscated in the hope users will recognise that it would be unwise to make\r
+ * direct use of the structure members.\r
+ */\r
+typedef struct xSTATIC_EVENT_GROUP\r
+{\r
+ TickType_t xDummy1;\r
+ StaticList_t xDummy2;\r
+\r
+ #if( configUSE_TRACE_FACILITY == 1 )\r
+ UBaseType_t uxDummy3;\r
#endif\r
\r
- #if ( configSUPPORT_STATIC_ALLOCATION == 1 )\r
- uint8_t ucDummy7;\r
+ #if( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )\r
+ uint8_t ucDummy4;\r
#endif\r
\r
-} StaticQueue_t;\r
+} StaticEventGroup_t;\r
+\r
+/*\r
+ * In line with software engineering best practice, especially when supplying a\r
+ * library that is likely to change in future versions, FreeRTOS implements a\r
+ * strict data hiding policy. This means the software timer structure used\r
+ * internally by FreeRTOS is not accessible to application code. However, if\r
+ * the application writer wants to statically allocate the memory required to\r
+ * create a software timer then the size of the queue object needs to be know.\r
+ * The StaticTimer_t structure below is provided for this purpose. Its sizes\r
+ * and alignment requirements are guaranteed to match those of the genuine\r
+ * structure, no matter which architecture is being used, and no matter how the\r
+ * values in FreeRTOSConfig.h are set. Its contents are somewhat obfuscated in\r
+ * the hope users will recognise that it would be unwise to make direct use of\r
+ * the structure members.\r
+ */\r
+typedef struct xSTATIC_TIMER\r
+{\r
+ void *pvDummy1;\r
+ StaticListItem_t xDummy2;\r
+ TickType_t xDummy3;\r
+ UBaseType_t uxDummy4;\r
+ void *pvDummy5[ 2 ];\r
+ #if( configUSE_TRACE_FACILITY == 1 )\r
+ UBaseType_t uxDummy6;\r
+ #endif\r
+\r
+ #if( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) )\r
+ uint8_t ucDummy7;\r
+ #endif\r
\r
+} StaticTimer_t;\r
\r
#ifdef __cplusplus\r
}\r