|
1 |
| -/* Cores */ |
2 |
| -#define configNUM_CORES 2 |
3 |
| -#define configUSE_CORE_AFFINITY 1 |
4 |
| -#define configRUN_MULTIPLE_PRIORITIES 1 |
5 |
| - |
6 |
| -#define configUSE_PREEMPTION 1 |
7 |
| -#define configUSE_IDLE_HOOK 1 |
8 |
| -#define configUSE_MINIMAL_IDLE_HOOK 1 |
9 |
| -#define configUSE_TICK_HOOK 1 |
10 |
| -#define configCPU_CLOCK_HZ ( ( unsigned long ) F_CPU ) |
11 |
| -#define configTICK_RATE_HZ ( ( TickType_t ) 1000 ) |
12 |
| -#define configMAX_PRIORITIES ( 8 ) |
13 |
| -#define configMINIMA
8000
L_STACK_SIZE ( ( unsigned short ) 256 ) |
14 |
| -#define configTOTAL_HEAP_SIZE ( ( size_t ) ( 164 * 1024 ) ) |
15 |
| -#define configMAX_TASK_NAME_LEN ( 10 ) |
16 |
| -#define configUSE_TRACE_FACILITY 1 |
17 |
| -#define configUSE_16_BIT_TICKS 0 |
18 |
| -#define configIDLE_SHOULD_YIELD 1 |
19 |
| -#define configUSE_MUTEXES 1 |
20 |
| -#define configQUEUE_REGISTRY_SIZE 8 |
21 |
| -#define configUSE_RECURSIVE_MUTEXES 1 |
22 |
| -#define configUSE_MALLOC_FAILED_HOOK 1 |
23 |
| -#define configUSE_APPLICATION_TASK_TAG 0 |
24 |
| -#define configUSE_COUNTING_SEMAPHORES 1 |
25 |
| -#define configUSE_QUEUE_SETS 1 |
26 |
| -#define configSUPPORT_DYNAMIC_ALLOCATION 1 |
27 |
| -#define configSUPPORT_STATIC_ALLOCATION 1 |
28 |
| -#define configSTACK_DEPTH_TYPE uint32_t |
| 1 | +#define configNUM_CORES 2 |
| 2 | +#define configUSE_CORE_AFFINITY 1 |
| 3 | +#define configRUN_MULTIPLE_PRIORITIES 1 |
| 4 | + |
| 5 | +#define configUSE_PREEMPTION 1 |
| 6 | +#define configUSE_IDLE_HOOK 1 |
| 7 | +#define configUSE_MINIMAL_IDLE_HOOK 1 |
| 8 | +#define configUSE_TICK_HOOK 1 |
| 9 | +#define configCPU_CLOCK_HZ ( ( unsigned long ) F_CPU ) |
| 10 | +#define configTICK_RATE_HZ ( ( TickType_t ) 1000 ) |
| 11 | +#define configMAX_PRIORITIES ( 8 ) |
| 12 | +#define configMINIMAL_STACK_SIZE ( ( unsigned short ) 256 ) |
| 13 | +#define configTOTAL_HEAP_SIZE ( ( size_t ) ( 164 * 1024 ) ) |
| 14 | +#define configMAX_TASK_NAME_LEN ( 10 ) |
| 15 | +#define configUSE_TRACE_FACILITY 1 |
| 16 | +#define configUSE_16_BIT_TICKS 0 |
| 17 | +#define configIDLE_SHOULD_YIELD 1 |
| 18 | +#define configUSE_MUTEXES 1 |
| 19 | +#define configQUEUE_REGISTRY_SIZE 8 |
| 20 | +#define configUSE_RECURSIVE_MUTEXES 1 |
| 21 | +#define configUSE_MALLOC_FAILED_HOOK 1 |
| 22 | +#define configUSE_APPLICATION_TASK_TAG 0 |
| 23 | +#define configUSE_COUNTING_SEMAPHORES 1 |
| 24 | +#define configUSE_QUEUE_SETS 1 |
| 25 | +#define configSUPPORT_DYNAMIC_ALLOCATION 1 |
| 26 | +#define configSUPPORT_STATIC_ALLOCATION 1 |
| 27 | +#define configSTACK_DEPTH_TYPE uint32_t |
29 | 28 | #define configUSE_TASK_PREEMPTION_DISABLE 1
|
30 | 29 |
|
31 |
| -#define configUSE_NEWLIB_REENTRANT 1 |
| 30 | +#define configUSE_NEWLIB_REENTRANT 1 |
32 | 31 | #define configNEWLIB_REENTRANT_IS_DYNAMIC 1
|
33 | 32 |
|
34 | 33 | /* Run time stats related definitions. */
|
35 |
| -void vMainConfigureTimerForRunTimeStats(void); |
36 |
| -unsigned long ulMainGetRunTimeCounterValue(void); |
| 34 | +extern void vMainConfigureTimerForRunTimeStats(void); |
| 35 | +extern unsigned long ulMainGetRunTimeCounterValue(void); |
37 | 36 | #define configGENERATE_RUN_TIME_STATS 1
|
38 | 37 | #define portCONFIGURE_TIMER_FOR_RUN_TIME_STATS() //vMainConfigureTimerForRunTimeStats()
|
39 | 38 | #define portGET_RUN_TIME_COUNTER_VALUE() ulMainGetRunTimeCounterValue()
|
40 | 39 |
|
41 | 40 | /* Co-routine definitions. */
|
42 |
| -#define configUSE_CO_ROUTINES 1 |
| 41 | +#define configUSE_CO_ROUTINES 1 |
43 | 42 | #define configMAX_CO_ROUTINE_PRIORITIES ( 2 )
|
44 | 43 |
|
45 | 44 | /* Software timer definitions. */
|
46 |
| -#define configUSE_TIMERS 1 |
47 |
| -#define configTIMER_TASK_PRIORITY ( 2 ) |
48 |
| -#define configTIMER_QUEUE_LENGTH 5 |
49 |
| -#define configTIMER_TASK_STACK_DEPTH ( 1024 ) |
| 45 | + #define configUSE_TIMERS 1 |
| 46 | +#define configTIMER_TASK_PRIORITY ( 2 ) |
| 47 | +#define configTIMER_QUEUE_LENGTH 5 |
| 48 | +#define configTIMER_TASK_STACK_DEPTH ( 1024 ) |
50 | 49 |
|
51 | 50 | /* Set the following definitions to 1 to include the API function, or zero
|
52 | 51 | to exclude the API function. */
|
53 |
| -#define INCLUDE_xTaskGetCurrentTaskHandle 1 |
54 |
| -#define INCLUDE_vTaskPrioritySet 1 |
55 |
| -#define INCLUDE_uxTaskPriorityGet 1 |
56 |
| -#define INCLUDE_vTaskDelete 1 |
57 |
| -#define INCLUDE_vTaskCleanUpResources 1 |
58 |
| -#define INCLUDE_vTaskSuspend 1 |
59 |
| -#define INCLUDE_vTaskDelayUntil 1 |
60 |
| -#define INCLUDE_vTaskDelay 1 |
61 |
| -#define INCLUDE_eTaskGetState 1 |
| 52 | +#define INCLUDE_eTaskGetState 1 |
| 53 | +#define INCLUDE_uxTaskGetStackHighWaterMark 1 |
| 54 | +#define INCLUDE_uxTaskPriorityGet 1 |
| 55 | +#define INCLUDE_vTaskCleanUpResources 1 |
| 56 | +#define INCLUDE_vTaskDelay 1 |
| 57 | +#define INCLUDE_vTaskDelayUntil 1 |
| 58 | +#define INCLUDE_vTaskDelete 1 |
| 59 | +#define INCLUDE_vTaskPrioritySet 1 |
| 60 | +#define INCLUDE_vTaskSuspend 1 |
| 61 | +#define INCLUDE_xQueueGetMutexHolder 1 |
| 62 | +#define INCLUDE_xTaskAbortDelay 1 |
| 63 | +#define INCLUDE_xTaskGetCurrentTaskHandle 1 |
| 64 | +#define INCLUDE_xTaskGetHandle 1 |
| 65 | +#define INCLUDE_xTaskGetIdleTaskHandle 1 |
| 66 | +#define INCLUDE_xTaskGetSchedulerState 1 |
| 67 | +#define INCLUDE_xTaskResumeFromISR 1 |
| 68 | +#define INCLUDE_xTimerPendFunctionCall 1 |
62 | 69 |
|
63 |
| -/* This demo makes use of one or more example stats formatting functions. These |
64 |
| - format the raw data provided by the uxTaskGetSystemState() function in to human |
65 |
| - readable ASCII form. See the notes in the implementation of vTaskList() within |
66 |
| - FreeRTOS/Source/tasks.c for limitations. */ |
67 | 70 | #define configUSE_STATS_FORMATTING_FUNCTIONS 1
|
68 | 71 |
|
69 |
| -#define configUSE_MUTEXES 1 |
70 |
| -#define INCLUDE_uxTaskGetStackHighWaterMark 1 |
71 |
| -#define INCLUDE_xTaskGetIdleTaskHandle 1 |
72 |
| -#define configUSE_MALLOC_FAILED_HOOK 1 |
73 |
| -#define configCHECK_FOR_STACK_OVERFLOW 2 |
74 |
| -/* Normal assert() semantics without relying on the provision of an assert.h |
75 |
| - header file. */ |
| 72 | +#define
F438
configUSE_MUTEXES 1 |
| 73 | +#define configUSE_MALLOC_FAILED_HOOK 1 |
| 74 | +#define configCHECK_FOR_STACK_OVERFLOW 2 |
76 | 75 |
|
77 | 76 | /* Cortex-M specific definitions. */
|
78 | 77 | #undef __NVIC_PRIO_BITS
|
79 | 78 | #ifdef __NVIC_PRIO_BITS
|
80 | 79 | /* __BVIC_PRIO_BITS will be specified when CMSIS is being used. */
|
81 |
| -#define configPRIO_BITS __NVIC_PRIO_BITS |
| 80 | +#define configPRIO_BITS __NVIC_PRIO_BITS |
82 | 81 | #else
|
83 |
| -#define configPRIO_BITS 3 /* 8 priority levels */ |
| 82 | +#define configPRIO_BITS 3 /* 8 priority levels */ |
84 | 83 | #endif
|
85 | 84 |
|
86 | 85 | /* The lowest interrupt priority that can be used in a call to a "set priority"
|
87 | 86 | function. */
|
88 |
| -#define configLIBRARY_LOWEST_INTERRUPT_PRIORITY 0x7 |
| 87 | +#define configLIBRARY_LOWEST_INTERRUPT_PRIORITY 0x7 |
89 | 88 |
|
90 | 89 | /* The highest interrupt priority that can be used by any interrupt service
|
91 | 90 | routine that makes calls to interrupt safe FreeRTOS API functions. DO NOT CALL
|
92 | 91 | INTERRUPT SAFE FREERTOS API FUNCTIONS FROM ANY INTERRUPT THAT HAS A HIGHER
|
93 | 92 | PRIORITY THAN THIS! (higher priorities are lower numeric values. */
|
94 |
| -#define configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY 5 |
| 93 | +#define configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY 5 |
95 | 94 |
|
96 | 95 | /* Interrupt priorities used by the kernel port layer itself. These are generic
|
97 | 96 | to all Cortex-M ports, and do not rely on any particular library functions. */
|
98 |
| -#define configKERNEL_INTERRUPT_PRIORITY ( configLIBRARY_LOWEST_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) ) |
| 97 | +#define configKERNEL_INTERRUPT_PRIORITY ( configLIBRARY_LOWEST_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) ) |
99 | 98 | /* !!!! configMAX_SYSCALL_INTERRUPT_PRIORITY must not be set to zero !!!!
|
100 | 99 | See http://www.FreeRTOS.org/RTOS-Cortex-M3-M4.html. */
|
101 |
| -#define configMAX_SYSCALL_INTERRUPT_PRIORITY ( configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) ) |
| 100 | +#define configMAX_SYSCALL_INTERRUPT_PRIORITY ( configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) ) |
102 | 101 |
|
103 | 102 | extern void rtosFatalError(void);
|
104 | 103 | #define configASSERT( x ) \
|
105 | 104 | if( ( x ) == 0 ) { portDISABLE_INTERRUPTS(); rtosFatalError(); }
|
106 | 105 |
|
107 |
| -/* Definitions that map the FreeRTOS port interrupt handlers to their CMSIS |
108 |
| - standard names - or at least those used in the unmodified vector table. */ |
109 |
| -//#define xPortPendSVHandler PendSV_Handler |
110 |
| -//#define xPortSysTickHandler SysTick_Handler |
111 |
| -//#define vPortSVCHandler SVC_Handler |
112 |
| - |
113 |
| -/* The size of the global output buffer that is available for use when there |
114 |
| - are multiple command interpreters running at once (for example, one on a UART |
115 |
| - and one on TCP/IP). This is done to prevent an output buffer being defined by |
116 |
| - each implementation - which would waste RAM. In this case, there is only one |
117 |
| - command interpreter running. */ |
118 |
| -#define configCOMMAND_INT_MAX_OUTPUT_SIZE 2048 |
119 |
| - |
120 |
| - |
121 | 106 | #define configUSE_DYNAMIC_EXCEPTION_HANDLERS 0
|
122 |
| -#define configSUPPORT_PICO_SYNC_INTEROP 1 |
123 |
| -#define configSUPPORT_PICO_TIME_INTEROP 1 |
124 |
| - |
| 107 | +#define configSUPPORT_PICO_SYNC_INTEROP 1 |
| 108 | +#define configSUPPORT_PICO_TIME_INTEROP 1 |
125 | 109 |
|
126 | 110 | #include "rp2040_config.h"
|
127 |
| -//#include "task.h" |
0 commit comments