FreeRTOSConfig.h
Go to the documentation of this file.
1 /*
2  * FreeRTOS Kernel V10.0.0
3  * Copyright (C) 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
4  *
5  * Permission is hereby granted, free of charge, to any person obtaining a copy of
6  * this software and associated documentation files (the "Software"), to deal in
7  * the Software without restriction, including without limitation the rights to
8  * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9  * the Software, and to permit persons to whom the Software is furnished to do so,
10  * subject to the following conditions:
11  *
12  * The above copyright notice and this permission notice shall be included in all
13  * copies or substantial portions of the Software. If you wish to use our Amazon
14  * FreeRTOS name, please do so in a fair use way that does not cause confusion.
15  *
16  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
18  * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
19  * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
20  * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
21  * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22  *
23  * http://www.FreeRTOS.org
24  * http://aws.amazon.com/freertos
25  *
26  * 1 tab == 4 spaces!
27  */
28 
29 
30 #ifndef FREERTOS_CONFIG_H
31 #define FREERTOS_CONFIG_H
32 
33 /*-----------------------------------------------------------
34  * Application specific definitions.
35  *
36  * These definitions should be adjusted for your particular hardware and
37  * application requirements.
38  *
39  * THESE PARAMETERS ARE DESCRIBED WITHIN THE 'CONFIGURATION' SECTION OF THE
40  * FreeRTOS API DOCUMENTATION AVAILABLE ON THE FreeRTOS.org WEB SITE.
41  *
42  * See http://www.freertos.org/a00110.html.
43  *----------------------------------------------------------*/
44 
45 /* For definition of BOARD_MCK. */
46 #ifndef __IAR_SYSTEMS_ASM__
47  /* Prevent chip.h being included when this file is included from the IAR
48  port layer assembly file. */
49  #include "board.h"
50 #endif
51 #include "sysclk.h"
52 #include "../drivers/d_time.h"
53 #include "../../../../src/data_sets.h"
54 
55 #define configUSE_PREEMPTION 1
56 #define configUSE_PORT_OPTIMISED_TASK_SELECTION 1
57 #define configUSE_QUEUE_SETS 1
58 #define configUSE_IDLE_HOOK 1
59 #define configUSE_TICK_HOOK 0
60 // #define configCPU_CLOCK_HZ ( BOARD_MCK << 1UL )
61 #define configCPU_CLOCK_HZ ( sysclk_get_cpu_hz() )
62 #define configTICK_RATE_HZ ( 1000 )
63 #define configMAX_PRIORITIES ( 10 )
64 #define configMINIMAL_STACK_SIZE ( ( unsigned short ) 130 )
65 
66 #define configTOTAL_HEAP_SIZE 262144//( ( size_t ) ( 46 * 1024 ) )
67 
68 #define configMAX_TASK_NAME_LEN ( 10 )
69 #define configUSE_TRACE_FACILITY 1
70 #define configUSE_16_BIT_TICKS 0
71 #define configIDLE_SHOULD_YIELD 1
72 #define configUSE_MUTEXES 1
73 #define configQUEUE_REGISTRY_SIZE 8
74 #define configCHECK_FOR_STACK_OVERFLOW 2
75 #define configUSE_RECURSIVE_MUTEXES 1
76 #define configUSE_MALLOC_FAILED_HOOK 1
77 #define configUSE_APPLICATION_TASK_TAG 0
78 #define configUSE_COUNTING_SEMAPHORES 1
79 
80 /* The full demo always has tasks to run so the tick will never be turned off.
81 The blinky demo will use the default tickless idle implementation to turn the
82 tick off. */
83 #define configUSE_TICKLESS_IDLE 0
84 
85 /* Run time stats gathering definitions. */
86 #define configGENERATE_RUN_TIME_STATS 1 /* http://www.freertos.org/rtos-run-time-stats.html */
87 #define portCONFIGURE_TIMER_FOR_RUN_TIME_STATS() time_init()
88 #define portGET_RUN_TIME_COUNTER_VALUE() ((uint32_t)time_ticks())
89 #define INCLUDE_uxTaskGetStackHighWaterMark 1
90 
91 
92 /* This demo makes use of one or more example stats formatting functions. These
93 format the raw data provided by the uxTaskGetSystemState() function in to human
94 readable ASCII form. See the notes in the implementation of vTaskList() within
95 FreeRTOS/Source/tasks.c for limitations. */
96 #define configUSE_STATS_FORMATTING_FUNCTIONS 1
97 
98 /* Co-routine definitions. */
99 #define configUSE_CO_ROUTINES 0
100 #define configMAX_CO_ROUTINE_PRIORITIES ( 2 )
101 
102 /* Software timer definitions. */
103 #define configUSE_TIMERS 1
104 #define configTIMER_TASK_PRIORITY ( configMAX_PRIORITIES - 1 )
105 #define configTIMER_QUEUE_LENGTH 5
106 #define configTIMER_TASK_STACK_DEPTH ( configMINIMAL_STACK_SIZE * 2 )
107 
108 /* Set the following definitions to 1 to include the API function, or zero
109 to exclude the API function. */
110 #define INCLUDE_vTaskPrioritySet 1
111 #define INCLUDE_uxTaskPriorityGet 1
112 #define INCLUDE_vTaskDelete 1
113 #define INCLUDE_vTaskCleanUpResources 1
114 #define INCLUDE_vTaskSuspend 1
115 #define INCLUDE_vTaskDelayUntil 1
116 #define INCLUDE_vTaskDelay 1
117 #define INCLUDE_eTaskGetState 1
118 #define INCLUDE_xTimerPendFunctionCall 1
119 
120 extern evb_rtos_info_t g_rtos;
121 #define traceMALLOC(pvAddress, uiSize) g_rtos.mallocSize += uiSize
122 #define traceFREE(pvAddress, uiSize) g_rtos.freeSize += uiSize
123 
124 /* Cortex-M specific definitions. */
125 #ifdef __NVIC_PRIO_BITS
126  /* __BVIC_PRIO_BITS will be specified when CMSIS is being used. */
127  #define configPRIO_BITS __NVIC_PRIO_BITS
128 #else
129  #define configPRIO_BITS 3 /* 7 priority levels */
130 #endif
131 
132 /* The lowest interrupt priority that can be used in a call to a "set priority"
133 function. */
134 #define configLIBRARY_LOWEST_INTERRUPT_PRIORITY 0x07
135 
136 /* The highest interrupt priority that can be used by any interrupt service
137 routine that makes calls to interrupt safe FreeRTOS API functions. DO NOT CALL
138 INTERRUPT SAFE FREERTOS API FUNCTIONS FROM ANY INTERRUPT THAT HAS A HIGHER
139 PRIORITY THAN THIS! (higher priorities are lower numeric values. */
140 #define configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY 4
141 
142 /* Interrupt priorities used by the kernel port layer itself. These are generic
143 to all Cortex-M ports, and do not rely on any particular library functions. */
144 #define configKERNEL_INTERRUPT_PRIORITY ( configLIBRARY_LOWEST_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) )
145 /* !!!! configMAX_SYSCALL_INTERRUPT_PRIORITY must not be set to zero !!!!
146 See http://www.FreeRTOS.org/RTOS-Cortex-M3-M4.html. */
147 #define configMAX_SYSCALL_INTERRUPT_PRIORITY ( configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) )
148 
149 /* Normal assert() semantics without relying on the provision of an assert.h
150 header file. */
151 #define configASSERT( x ) if( ( x ) == 0 ) { taskDISABLE_INTERRUPTS(); for( ;; ); }
152 
153 /* Definitions that map the FreeRTOS port interrupt handlers to their CMSIS
154 standard names. Based on the architecture choosen, the below definitons may be needed*/
155 
156 #define xPortPendSVHandler PendSV_Handler
157 #define vPortSVCHandler SVC_Handler
158 #define xPortSysTickHandler SysTick_Handler
159 
160 #endif /* FREERTOS_CONFIG_H */
161 
evb_rtos_info_t g_rtos
Definition: globals.c:27
Standard board header file.


inertial_sense_ros
Author(s):
autogenerated on Sun Feb 28 2021 03:17:57