]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS/Demo/CORTEX_LM3S811_GCC/main.c
***IMMINENT RELEASE NOTICE***
[freertos] / FreeRTOS / Demo / CORTEX_LM3S811_GCC / main.c
index 8bcf384d03521076b3b62fcd3b4724771f04e32d..fdb281d217c1de2ba292ec1d91fd2292bb2717db 100644 (file)
@@ -1,5 +1,6 @@
 /*\r
-    FreeRTOS V7.5.2 - Copyright (C) 2013 Real Time Engineers Ltd.\r
+    FreeRTOS V8.1.0 - Copyright (C) 2014 Real Time Engineers Ltd. \r
+    All rights reserved\r
 \r
     VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION.\r
 \r
     the terms of the GNU General Public License (version 2) as published by the\r
     Free Software Foundation >>!AND MODIFIED BY!<< the FreeRTOS exception.\r
 \r
-    >>! NOTE: The modification to the GPL is included to allow you to distribute\r
-    >>! a combined work that includes FreeRTOS without being obliged to provide\r
-    >>! the source code for proprietary components outside of the FreeRTOS\r
-    >>! kernel.\r
+    >>!   NOTE: The modification to the GPL is included to allow you to     !<<\r
+    >>!   distribute a combined work that includes FreeRTOS without being   !<<\r
+    >>!   obliged to provide the source code for proprietary components     !<<\r
+    >>!   outside of the FreeRTOS kernel.                                   !<<\r
 \r
     FreeRTOS is distributed in the hope that it will be useful, but WITHOUT ANY\r
     WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS\r
 #include "BlockQ.h"\r
 \r
 /* Delay between cycles of the 'check' task. */\r
-#define mainCHECK_DELAY                                                ( ( portTickType ) 5000 / portTICK_RATE_MS )\r
+#define mainCHECK_DELAY                                                ( ( TickType_t ) 5000 / portTICK_PERIOD_MS )\r
 \r
 /* UART configuration - note this does not use the FIFO so is not very\r
 efficient. */\r
@@ -136,8 +137,8 @@ efficient. */
 \r
 /* Misc. */\r
 #define mainQUEUE_SIZE                         ( 3 )\r
-#define mainDEBOUNCE_DELAY                     ( ( portTickType ) 150 / portTICK_RATE_MS )\r
-#define mainNO_DELAY                           ( ( portTickType ) 0 )\r
+#define mainDEBOUNCE_DELAY                     ( ( TickType_t ) 150 / portTICK_PERIOD_MS )\r
+#define mainNO_DELAY                           ( ( TickType_t ) 0 )\r
 /*\r
  * Configure the processor and peripherals for this demo.\r
  */\r
@@ -160,15 +161,15 @@ static void vButtonHandlerTask( void *pvParameters );
 static void vPrintTask( void *pvParameter );\r
 \r
 /* String that is transmitted on the UART. */\r
-static portCHAR *cMessage = "Task woken by button interrupt! --- ";\r
-static volatile portCHAR *pcNextChar;\r
+static char *cMessage = "Task woken by button interrupt! --- ";\r
+static volatile char *pcNextChar;\r
 \r
 /* The semaphore used to wake the button handler task from within the GPIO\r
 interrupt handler. */\r
-xSemaphoreHandle xButtonSemaphore;\r
+SemaphoreHandle_t xButtonSemaphore;\r
 \r
 /* The queue used to send strings to the print task for display on the LCD. */\r
-xQueueHandle xPrintQueue;\r
+QueueHandle_t xPrintQueue;\r
 \r
 /*-----------------------------------------------------------*/\r
 \r
@@ -183,7 +184,7 @@ int main( void )
        xSemaphoreTake( xButtonSemaphore, 0 );\r
 \r
        /* Create the queue used to pass message to vPrintTask. */\r
-       xPrintQueue = xQueueCreate( mainQUEUE_SIZE, sizeof( portCHAR * ) );\r
+       xPrintQueue = xQueueCreate( mainQUEUE_SIZE, sizeof( char * ) );\r
 \r
        /* Start the standard demo tasks. */\r
        vStartIntegerMathTasks( tskIDLE_PRIORITY );\r
@@ -209,9 +210,9 @@ int main( void )
 static void vCheckTask( void *pvParameters )\r
 {\r
 portBASE_TYPE xErrorOccurred = pdFALSE;\r
-portTickType xLastExecutionTime;\r
-const portCHAR *pcPassMessage = "PASS";\r
-const portCHAR *pcFailMessage = "FAIL";\r
+TickType_t xLastExecutionTime;\r
+const char *pcPassMessage = "PASS";\r
+const char *pcFailMessage = "FAIL";\r
 \r
        /* Initialise xLastExecutionTime so the first call to vTaskDelayUntil()\r
        works correctly. */\r
@@ -304,7 +305,7 @@ static void prvSetupHardware( void )
 \r
 static void vButtonHandlerTask( void *pvParameters )\r
 {\r
-const portCHAR *pcInterruptMessage = "Int";\r
+const char *pcInterruptMessage = "Int";\r
 \r
        for( ;; )\r
        {\r
@@ -339,7 +340,7 @@ const portCHAR *pcInterruptMessage = "Int";
 \r
 void vUART_ISR(void)\r
 {\r
-unsigned portLONG ulStatus;\r
+unsigned long ulStatus;\r
 \r
        /* What caused the interrupt. */\r
        ulStatus = UARTIntStatus( UART0_BASE, pdTRUE );\r
@@ -379,7 +380,7 @@ portBASE_TYPE xHigherPriorityTaskWoken = pdFALSE;
 \r
 static void vPrintTask( void *pvParameters )\r
 {\r
-portCHAR *pcMessage;\r
+char *pcMessage;\r
 unsigned portBASE_TYPE uxLine = 0, uxRow = 0;\r
 \r
        for( ;; )\r