]> git.sur5r.net Git - freertos/commitdiff
Add the timer demo/test task creating to the WIN32-MSVC/main.c file.
authorrichardbarry <richardbarry@1d2547de-c912-0410-9cb9-b8ca96c0e9e2>
Wed, 9 Feb 2011 19:30:44 +0000 (19:30 +0000)
committerrichardbarry <richardbarry@1d2547de-c912-0410-9cb9-b8ca96c0e9e2>
Wed, 9 Feb 2011 19:30:44 +0000 (19:30 +0000)
git-svn-id: https://svn.code.sf.net/p/freertos/code/trunk@1288 1d2547de-c912-0410-9cb9-b8ca96c0e9e2

Demo/WIN32-MSVC/main.c

index e9fe4bf4787638b67681a6cb3990e81cf4faba8e..4ce366bebce65a9c285a1278ff9533e9476c5161 100644 (file)
@@ -96,6 +96,7 @@
 #include "QPeek.h"\r
 #include "recmutex.h"\r
 #include "flop.h"\r
+#include "TimerDemo.h"\r
 \r
 /* Priorities at which the tasks are created. */\r
 #define mainCHECK_TASK_PRIORITY                ( configMAX_PRIORITIES - 1 )\r
 #define mainGEN_QUEUE_TASK_PRIORITY    ( tskIDLE_PRIORITY )\r
 #define mainFLOP_TASK_PRIORITY         ( tskIDLE_PRIORITY )\r
 \r
+#define mainTIMER_FREQUENCY                    ( configTICK_RATE_HZ )\r
+\r
 /* Task function prototypes. */\r
 static void prvCheckTask( void *pvParameters );\r
 \r
@@ -128,6 +131,7 @@ int main( void )
        vStartQueuePeekTasks();\r
        vStartMathTasks( mainFLOP_TASK_PRIORITY );\r
        vStartRecursiveMutexTasks();\r
+       vStartTimerDemoTask( mainTIMER_FREQUENCY );\r
 \r
        /* Start the scheduler itself. */\r
        vTaskStartScheduler();\r
@@ -156,7 +160,11 @@ char *pcStatusMessage = "OK";
                vTaskDelayUntil( &xNextWakeTime, xCycleFrequency );\r
 \r
                /* Check the standard demo tasks are running without error. */\r
-           if( xAreIntegerMathsTaskStillRunning() != pdTRUE )\r
+               if( xAreTimerDemoTasksStillRunning() != pdTRUE )\r
+               {\r
+                       pcStatusMessage = "Error: TimerDemo";\r
+               }\r
+           else if( xAreIntegerMathsTaskStillRunning() != pdTRUE )\r
            {\r
                        pcStatusMessage = "Error: IntMath";\r
            }   \r