]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS/Demo/Common/Minimal/comtest_strings.c
Update version numbers in preparation for V8.2.0 release candidate 1.
[freertos] / FreeRTOS / Demo / Common / Minimal / comtest_strings.c
index 0de0a5fa6d85301257f5b1a39b2299bf8b22b976..113040f5bd6b314661270f0f17479d9ef8a3ffae 100644 (file)
@@ -1,37 +1,23 @@
 /*\r
-    FreeRTOS V8.0.0:rc1 - Copyright (C) 2014 Real Time Engineers Ltd.\r
+    FreeRTOS V8.2.0rc1 - 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
-    ***************************************************************************\r
-     *                                                                       *\r
-     *    FreeRTOS provides completely free yet professionally developed,    *\r
-     *    robust, strictly quality controlled, supported, and cross          *\r
-     *    platform software that has become a de facto standard.             *\r
-     *                                                                       *\r
-     *    Help yourself get started quickly and support the FreeRTOS         *\r
-     *    project by purchasing a FreeRTOS tutorial book, reference          *\r
-     *    manual, or both from: http://www.FreeRTOS.org/Documentation        *\r
-     *                                                                       *\r
-     *    Thank you!                                                         *\r
-     *                                                                       *\r
-    ***************************************************************************\r
-\r
     This file is part of the FreeRTOS distribution.\r
 \r
     FreeRTOS is free software; you can redistribute it and/or modify it under\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
-    FOR A PARTICULAR PURPOSE.  Full license text is available from the following\r
+    FOR A PARTICULAR PURPOSE.  Full license text is available on the following\r
     link: http://www.freertos.org/a00114.html\r
 \r
     1 tab == 4 spaces!\r
     ***************************************************************************\r
      *                                                                       *\r
      *    Having a problem?  Start by reading the FAQ "My application does   *\r
-     *    not run, what could be wrong?"                                     *\r
+     *    not run, what could be wrong?".  Have you defined configASSERT()?  *\r
      *                                                                       *\r
      *    http://www.FreeRTOS.org/FAQHelp.html                               *\r
      *                                                                       *\r
     ***************************************************************************\r
 \r
+    ***************************************************************************\r
+     *                                                                       *\r
+     *    FreeRTOS provides completely free yet professionally developed,    *\r
+     *    robust, strictly quality controlled, supported, and cross          *\r
+     *    platform software that is more than just the market leader, it     *\r
+     *    is the industry's de facto standard.                               *\r
+     *                                                                       *\r
+     *    Help yourself get started quickly while simultaneously helping     *\r
+     *    to support the FreeRTOS project by purchasing a FreeRTOS           *\r
+     *    tutorial book, reference manual, or both:                          *\r
+     *    http://www.FreeRTOS.org/Documentation                              *\r
+     *                                                                       *\r
+    ***************************************************************************\r
+\r
+    ***************************************************************************\r
+     *                                                                       *\r
+     *   Investing in training allows your team to be as productive as       *\r
+     *   possible as early as possible, lowering your overall development    *\r
+     *   cost, and enabling you to bring a more robust product to market     *\r
+     *   earlier than would otherwise be possible.  Richard Barry is both    *\r
+     *   the architect and key author of FreeRTOS, and so also the world's   *\r
+     *   leading authority on what is the world's most popular real time     *\r
+     *   kernel for deeply embedded MCU designs.  Obtaining your training    *\r
+     *   from Richard ensures your team will gain directly from his in-depth *\r
+     *   product knowledge and years of usage experience.  Contact Real Time *\r
+     *   Engineers Ltd to enquire about the FreeRTOS Masterclass, presented  *\r
+     *   by Richard Barry:  http://www.FreeRTOS.org/contact\r
+     *                                                                       *\r
+    ***************************************************************************\r
+\r
+    ***************************************************************************\r
+     *                                                                       *\r
+     *    You are receiving this top quality software for free.  Please play *\r
+     *    fair and reciprocate by reporting any suspected issues and         *\r
+     *    participating in the community forum:                              *\r
+     *    http://www.FreeRTOS.org/support                                    *\r
+     *                                                                       *\r
+     *    Thank you!                                                         *\r
+     *                                                                       *\r
+    ***************************************************************************\r
+\r
     http://www.FreeRTOS.org - Documentation, books, training, latest versions,\r
     license and Real Time Engineers Ltd. contact details.\r
 \r
     including FreeRTOS+Trace - an indispensable productivity tool, a DOS\r
     compatible FAT file system, and our tiny thread aware UDP/IP stack.\r
 \r
+    http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate.\r
+    Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS.\r
+\r
     http://www.OpenRTOS.com - Real Time Engineers ltd license FreeRTOS to High\r
-    Integrity Systems to sell under the OpenRTOS brand.  Low cost OpenRTOS\r
-    licenses offer ticketed support, indemnification and middleware.\r
+    Integrity Systems ltd. to sell under the OpenRTOS brand.  Low cost OpenRTOS\r
+    licenses offer ticketed support, indemnification and commercial middleware.\r
 \r
     http://www.SafeRTOS.com - High Integrity Systems also provide a safety\r
     engineered and independently SIL3 certified version for use in safety and\r
 /* The Tx timer transmits the sequence of characters at a pseudo random\r
 interval that is capped between comTX_MAX_BLOCK_TIME and\r
 comTX_MIN_BLOCK_TIME. */\r
-#define comTX_MAX_BLOCK_TIME           ( ( portTickType ) 0x96 )\r
-#define comTX_MIN_BLOCK_TIME           ( ( portTickType ) 0x32 )\r
-#define comOFFSET_TIME                         ( ( portTickType ) 3 )\r
+#define comTX_MAX_BLOCK_TIME           ( ( TickType_t ) 0x96 )\r
+#define comTX_MIN_BLOCK_TIME           ( ( TickType_t ) 0x32 )\r
+#define comOFFSET_TIME                         ( ( TickType_t ) 3 )\r
 \r
 /* States for the simple state machine implemented in the Rx task. */\r
 #define comtstWAITING_START_OF_STRING  0\r
@@ -132,36 +162,36 @@ a bit so more than one character can be processed at a time.  This is relative
 to comTX_MIN_BLOCK_TIME to ensure it is never longer than the shortest gap\r
 between transmissions.  It could be worked out more scientifically from the\r
 baud rate being used. */\r
-#define comSHORT_DELAY                         ( comTX_MIN_BLOCK_TIME >> ( portTickType ) 2 )\r
+#define comSHORT_DELAY                         ( comTX_MIN_BLOCK_TIME >> ( TickType_t ) 2 )\r
 \r
 /* The string that is transmitted and received. */\r
 #define comTRANSACTED_STRING           "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890"\r
 \r
 /* A block time of 0 simply means "don't block". */\r
-#define comtstDONT_BLOCK                       ( portTickType ) 0\r
+#define comtstDONT_BLOCK                       ( TickType_t ) 0\r
 \r
 /* Handle to the com port used by both tasks. */\r
 static xComPortHandle xPort = NULL;\r
 \r
 /* The callback function allocated to the transmit timer, as described in the\r
 comments at the top of this file. */\r
-static void prvComTxTimerCallback( xTimerHandle xTimer );\r
+static void prvComTxTimerCallback( TimerHandle_t xTimer );\r
 \r
 /* The receive task as described in the comments at the top of this file. */\r
 static void vComRxTask( void *pvParameters );\r
 \r
 /* The Rx task will toggle LED ( uxBaseLED + comRX_LED_OFFSET).  The Tx task\r
 will toggle LED ( uxBaseLED + comTX_LED_OFFSET ). */\r
-static unsigned portBASE_TYPE uxBaseLED = 0;\r
+static UBaseType_t uxBaseLED = 0;\r
 \r
 /* The Rx task toggles uxRxLoops on each successful iteration of its defined\r
 function - provided no errors have ever been latched.  If this variable stops\r
 incrementing, then an error has occurred. */\r
-static volatile unsigned portBASE_TYPE uxRxLoops = 0UL;\r
+static volatile UBaseType_t uxRxLoops = 0UL;\r
 \r
 /* The timer used to periodically transmit the string.  This is the timer that\r
 has prvComTxTimerCallback allocated to it as its callback function. */\r
-static xTimerHandle xTxTimer = NULL;\r
+static TimerHandle_t xTxTimer = NULL;\r
 \r
 /* The string length is held at file scope so the Tx timer does not need to\r
 calculate it each time it executes. */\r
@@ -169,7 +199,7 @@ static size_t xStringLength = 0U;
 \r
 /*-----------------------------------------------------------*/\r
 \r
-void vStartComTestStringsTasks( unsigned portBASE_TYPE uxPriority, unsigned long ulBaudRate, unsigned portBASE_TYPE uxLED )\r
+void vStartComTestStringsTasks( UBaseType_t uxPriority, uint32_t ulBaudRate, UBaseType_t uxLED )\r
 {\r
        /* Store values that are used at run time. */\r
        uxBaseLED = uxLED;\r
@@ -188,15 +218,15 @@ void vStartComTestStringsTasks( unsigned portBASE_TYPE uxPriority, unsigned long
 \r
        /* Create the Rx task and the Tx timer.  The timer is started from the\r
        Rx task. */\r
-       xTaskCreate( vComRxTask, "COMRx", comSTACK_SIZE, NULL, uxPriority, ( xTaskHandle * ) NULL );\r
+       xTaskCreate( vComRxTask, "COMRx", comSTACK_SIZE, NULL, uxPriority, ( TaskHandle_t * ) NULL );\r
        xTxTimer = xTimerCreate( "TxTimer", comTX_MIN_BLOCK_TIME, pdFALSE, NULL, prvComTxTimerCallback );\r
        configASSERT( xTxTimer );\r
 }\r
 /*-----------------------------------------------------------*/\r
 \r
-static void prvComTxTimerCallback( xTimerHandle xTimer )\r
+static void prvComTxTimerCallback( TimerHandle_t xTimer )\r
 {\r
-portTickType xTimeToWait;\r
+TickType_t xTimeToWait;\r
 \r
        /* The parameter is not used in this case. */\r
        ( void ) xTimer;\r
@@ -232,7 +262,7 @@ portTickType xTimeToWait;
 \r
 static void vComRxTask( void *pvParameters )\r
 {\r
-portBASE_TYPE xState = comtstWAITING_START_OF_STRING, xErrorOccurred = pdFALSE;\r
+BaseType_t xState = comtstWAITING_START_OF_STRING, xErrorOccurred = pdFALSE;\r
 char *pcExpectedByte, cRxedChar;\r
 const xComPortHandle xPort = NULL;\r
 \r
@@ -324,9 +354,9 @@ const xComPortHandle xPort = NULL;
 }\r
 /*-----------------------------------------------------------*/\r
 \r
-portBASE_TYPE xAreComTestTasksStillRunning( void )\r
+BaseType_t xAreComTestTasksStillRunning( void )\r
 {\r
-portBASE_TYPE xReturn;\r
+BaseType_t xReturn;\r
 \r
        /* If the count of successful reception loops has not changed than at\r
        some time an error occurred (i.e. a character was received out of sequence)\r