]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS/Demo/CORTEX_M4F_Infineon_XMC4500_IAR/FreeRTOSConfig.h
Reworked XMC4500 IAR project to use latest system files and include build configurati...
[freertos] / FreeRTOS / Demo / CORTEX_M4F_Infineon_XMC4500_IAR / FreeRTOSConfig.h
index 92373f513d7db23be972ce3977ce49751adb2f39..51df1616b8c768e1774890f6bb90f46a4cf32777 100644 (file)
 \r
 #define configUSE_PREEMPTION                   1\r
 #define configUSE_IDLE_HOOK                            0\r
-#define configUSE_TICK_HOOK                            0\r
+#define configUSE_TICK_HOOK                            1\r
 #define configCPU_CLOCK_HZ                             ( SystemCoreClock )\r
 #define configTICK_RATE_HZ                             ( ( portTickType ) 1000 )\r
 #define configMAX_PRIORITIES                   ( ( unsigned portBASE_TYPE ) 5 )\r
 #define configMINIMAL_STACK_SIZE               ( ( unsigned short ) 130 )\r
-#define configTOTAL_HEAP_SIZE                  ( ( size_t ) ( 40960 ) )\r
+#define configTOTAL_HEAP_SIZE                  ( ( size_t ) ( 22800 ) )\r
 #define configMAX_TASK_NAME_LEN                        ( 10 )\r
 #define configUSE_TRACE_FACILITY               1\r
 #define configUSE_16_BIT_TICKS                 0\r
 #define configUSE_APPLICATION_TASK_TAG 0\r
 #define configUSE_COUNTING_SEMAPHORES  1\r
 #define configGENERATE_RUN_TIME_STATS  0\r
+#define configUSE_QUEUE_SETS                   1\r
 \r
 /* Co-routine definitions. */\r
 #define configUSE_CO_ROUTINES          0\r
@@ -150,16 +151,50 @@ to all Cortex-M ports, and do not rely on any particular library functions. */
 /* !!!! configMAX_SYSCALL_INTERRUPT_PRIORITY must not be set to zero !!!!\r
 See http://www.FreeRTOS.org/RTOS-Cortex-M3-M4.html. */\r
 #define configMAX_SYSCALL_INTERRUPT_PRIORITY   ( configLIBRARY_MAX_SYSCALL_INTERRUPT_PRIORITY << (8 - configPRIO_BITS) )\r
-       \r
+\r
 /* Normal assert() semantics without relying on the provision of an assert.h\r
 header file. */\r
-#define configASSERT( x ) if( ( x ) == 0 ) { taskDISABLE_INTERRUPTS(); for( ;; ); }    \r
-       \r
+#define configASSERT( x ) if( ( x ) == 0 ) { taskDISABLE_INTERRUPTS(); for( ;; ); }\r
+\r
 /* Definitions that map the FreeRTOS port interrupt handlers to their CMSIS\r
 standard names. */\r
 #define vPortSVCHandler SVC_Handler\r
 #define xPortPendSVHandler PendSV_Handler\r
 #define xPortSysTickHandler SysTick_Handler\r
 \r
+/* Demo application specific settings. */\r
+#ifdef __ICCARM__\r
+       #if defined( PART_XMC4500 )\r
+               /* Hardware includes. */\r
+               #include "XMC4500.h"\r
+               #include "System_XMC4500.h"\r
+\r
+               /* Configure pin P3.9 for the LED. */\r
+               #define configCONFIGURE_LED() ( PORT3->IOCR8 = 0x00008000 )\r
+               /* To toggle the single LED */\r
+               #define configTOGGLE_LED()      ( PORT3->OMR =  0x02000200 )\r
+       #elif defined( PART_XMC4400 )\r
+               /* Hardware includes. */\r
+               #include "XMC4400.h"\r
+               #include "System_XMC4200.h"\r
+\r
+               /* Configure pin P5.2 for the LED. */\r
+               #define configCONFIGURE_LED() ( PORT5->IOCR0 = 0x00800000 )\r
+               /* To toggle the single LED */\r
+               #define configTOGGLE_LED()      ( PORT5->OMR =  0x00040004 )\r
+       #elif defined( PART_XMC4200 )\r
+               /* Hardware includes. */\r
+               #include "XMC4200.h"\r
+               #include "System_XMC4200.h"\r
+\r
+               /* Configure pin P2.1 for the LED. */\r
+               #define configCONFIGURE_LED() PORT2->IOCR0 = 0x00008000; PORT2->HWSEL &= ~0x0000000cUL\r
+               /* To toggle the single LED */\r
+               #define configTOGGLE_LED()      ( PORT2->OMR =  0x00020002 )\r
+       #else\r
+               #error Part number not specified in project options\r
+       #endif\r
+#endif\r
+\r
 #endif /* FREERTOS_CONFIG_H */\r
 \r