From 1fc88f10ff7d3969afda8d07877169f54c659ee9 Mon Sep 17 00:00:00 2001 From: richardbarry Date: Wed, 9 Feb 2011 19:30:44 +0000 Subject: [PATCH] Add the timer demo/test task creating to the WIN32-MSVC/main.c file. git-svn-id: https://svn.code.sf.net/p/freertos/code/trunk@1288 1d2547de-c912-0410-9cb9-b8ca96c0e9e2 --- Demo/WIN32-MSVC/main.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Demo/WIN32-MSVC/main.c b/Demo/WIN32-MSVC/main.c index e9fe4bf47..4ce366beb 100644 --- a/Demo/WIN32-MSVC/main.c +++ b/Demo/WIN32-MSVC/main.c @@ -96,6 +96,7 @@ #include "QPeek.h" #include "recmutex.h" #include "flop.h" +#include "TimerDemo.h" /* Priorities at which the tasks are created. */ #define mainCHECK_TASK_PRIORITY ( configMAX_PRIORITIES - 1 ) @@ -109,6 +110,8 @@ #define mainGEN_QUEUE_TASK_PRIORITY ( tskIDLE_PRIORITY ) #define mainFLOP_TASK_PRIORITY ( tskIDLE_PRIORITY ) +#define mainTIMER_FREQUENCY ( configTICK_RATE_HZ ) + /* Task function prototypes. */ static void prvCheckTask( void *pvParameters ); @@ -128,6 +131,7 @@ int main( void ) vStartQueuePeekTasks(); vStartMathTasks( mainFLOP_TASK_PRIORITY ); vStartRecursiveMutexTasks(); + vStartTimerDemoTask( mainTIMER_FREQUENCY ); /* Start the scheduler itself. */ vTaskStartScheduler(); @@ -156,7 +160,11 @@ char *pcStatusMessage = "OK"; vTaskDelayUntil( &xNextWakeTime, xCycleFrequency ); /* Check the standard demo tasks are running without error. */ - if( xAreIntegerMathsTaskStillRunning() != pdTRUE ) + if( xAreTimerDemoTasksStillRunning() != pdTRUE ) + { + pcStatusMessage = "Error: TimerDemo"; + } + else if( xAreIntegerMathsTaskStillRunning() != pdTRUE ) { pcStatusMessage = "Error: IntMath"; } -- 2.39.5