]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS/Demo/MB96350_Softune_Dice_Kit/main.c
Update version number to V8.0.0 (without the release candidate number).
[freertos] / FreeRTOS / Demo / MB96350_Softune_Dice_Kit / main.c
index 544e170393203ed0adcd4afe51b2b4d9cd6c9ac2..16a9465b62dd24a362f8f6011dd7e93d8d182fe1 100644 (file)
@@ -1,93 +1,92 @@
 /*\r
-    FreeRTOS V7.1.1 - Copyright (C) 2012 Real Time Engineers Ltd.\r
-       \r
+    FreeRTOS V8.0.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
     ***************************************************************************\r
      *                                                                       *\r
-     *    FreeRTOS tutorial books are available in pdf and paperback.        *\r
-     *    Complete, revised, and edited pdf reference manuals are also       *\r
-     *    available.                                                         *\r
-     *                                                                       *\r
-     *    Purchasing FreeRTOS documentation will not only help you, by       *\r
-     *    ensuring you get running as quickly as possible and with an        *\r
-     *    in-depth knowledge of how to use FreeRTOS, it will also help       *\r
-     *    the FreeRTOS project to continue with its mission of providing     *\r
-     *    professional grade, cross platform, de facto standard solutions    *\r
-     *    for microcontrollers - completely free of charge!                  *\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
-     *    >>> See http://www.FreeRTOS.org/Documentation for details. <<<     *\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 for using FreeRTOS, and thank you for your support!      *\r
+     *    Thank you!                                                         *\r
      *                                                                       *\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
-    >>>NOTE<<< The modification to the GPL is included to allow you to\r
-    distribute a combined work that includes FreeRTOS without being obliged to\r
-    provide the source code for proprietary components outside of the FreeRTOS\r
-    kernel.  FreeRTOS is distributed in the hope that it will be useful, but\r
-    WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\r
-    or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for\r
-    more details. You should have received a copy of the GNU General Public\r
-    License and the FreeRTOS license exception along with FreeRTOS; if not it\r
-    can be viewed here: http://www.freertos.org/a00114.html and also obtained\r
-    by writing to Richard Barry, contact details for whom are available on the\r
-    FreeRTOS WEB site.\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
+\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
+    link: http://www.freertos.org/a00114.html\r
 \r
     1 tab == 4 spaces!\r
-    \r
+\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?"                                     *\r
      *                                                                       *\r
      *    http://www.FreeRTOS.org/FAQHelp.html                               *\r
      *                                                                       *\r
     ***************************************************************************\r
 \r
-    \r
-    http://www.FreeRTOS.org - Documentation, training, latest information, \r
-    license and contact details.\r
-    \r
+    http://www.FreeRTOS.org - Documentation, books, training, latest versions,\r
+    license and Real Time Engineers Ltd. contact details.\r
+\r
     http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products,\r
-    including FreeRTOS+Trace - an indispensable productivity tool.\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
-    Real Time Engineers ltd license FreeRTOS to High Integrity Systems, who sell \r
-    the code with commercial support, indemnification, and middleware, under \r
-    the OpenRTOS brand: http://www.OpenRTOS.com.  High Integrity Systems also\r
-    provide a safety engineered and independently SIL3 certified version under \r
-    the SafeRTOS brand: http://www.SafeRTOS.com.\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
+\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
+    mission critical applications that require provable dependability.\r
+\r
+    1 tab == 4 spaces!\r
 */\r
 \r
 \r
 /*****\r
  *\r
  * See http://www.freertos.org/Documentation/FreeRTOS-documentation-and-book.html\r
- * for an introductory guide to using real time kernels, and FreeRTOS in \r
- * particular. \r
+ * for an introductory guide to using real time kernels, and FreeRTOS in\r
+ * particular.\r
  *\r
  *****\r
- *  \r
+ *\r
  * The DICE-KIT-16FX has two 7 segment displays and two buttons that can\r
  * generate interrupts.  This example uses this IO as follows:\r
  *\r
  *\r
- * - Left 7 segment display - \r
+ * - Left 7 segment display -\r
  *\r
- * 7 'flash' tasks are created, each of which toggles a single segment of the \r
- * left display.  Each task executes at a fixed frequency, with a different \r
+ * 7 'flash' tasks are created, each of which toggles a single segment of the\r
+ * left display.  Each task executes at a fixed frequency, with a different\r
  * frequency being used by each task.\r
  *\r
  * When button SW2 is pressed an interrupt is generated that wakes up a 'dice'\r
  * task.  The dice task suspends the 7 tasks that are accessing the left display\r
  * before simulating a dice being thrown by generating a random number between\r
  * 1 and 6.  After the number has been generated the task sleeps for 5 seconds,\r
- * if SW2 is pressed again within the 5 seconds another random number is \r
+ * if SW2 is pressed again within the 5 seconds another random number is\r
  * generated, if SW2 is not pressed within the 5 seconds then the 7 tasks are\r
  * un-suspended and will once again toggle the segments of the left hand display.\r
  *\r
  * Only one dice task is actually defined.  Two instances of this single\r
  * definition are created, the first to simulate a dice being thrown on the left\r
  * display, and the other to simulate a dice being thrown on the right display.\r
- * The task parameter is used to let the dice tasks know which display to \r
+ * The task parameter is used to let the dice tasks know which display to\r
  * control.\r
  *\r
  * Both dice tasks and the flash tasks operate completely independently under\r
  * the control of FreeRTOS.  11 tasks and 7 co-routines are created in total,\r
- * including the idle task. \r
+ * including the idle task.\r
  *\r
  * The co-routines all execute within a single low priority task.\r
  *\r
@@ -161,10 +160,10 @@ void main( void )
        vCreateFlashTasksAndCoRoutines();\r
 \r
        /* Create a 'dice' task to control the left hand display. */\r
-       xTaskCreate( vDiceTask, ( signed char * ) "Dice1", configMINIMAL_STACK_SIZE, ( void * ) configLEFT_DISPLAY, mainDICE_PRIORITY, NULL );\r
+       xTaskCreate( vDiceTask, "Dice1", configMINIMAL_STACK_SIZE, ( void * ) configLEFT_DISPLAY, mainDICE_PRIORITY, NULL );\r
 \r
        /* Create a 'dice' task to control the right hand display. */\r
-       xTaskCreate( vDiceTask, ( signed char * ) "Dice2", configMINIMAL_STACK_SIZE, ( void * ) configRIGHT_DISPLAY, mainDICE_PRIORITY, NULL );\r
+       xTaskCreate( vDiceTask, "Dice2", configMINIMAL_STACK_SIZE, ( void * ) configRIGHT_DISPLAY, mainDICE_PRIORITY, NULL );\r
 \r
        /* Start the scheduler running. */\r
        vTaskStartScheduler();\r
@@ -182,7 +181,7 @@ static void prvSetupHardware( void )
        scheduler has been started. */\r
        InitIrqLevels();\r
        portDISABLE_INTERRUPTS();\r
-       __set_il( 7 );  \r
+       __set_il( 7 );\r
 \r
        /* Set Port3 as output (7Segment Display). */\r
        DDR03  = 0xff;\r
@@ -211,7 +210,7 @@ static void prvSetupHardware( void )
 \r
        /* Enable external interrupt 8. */\r
        PIER00_IE0 = 1;\r
-       \r
+\r
        /* LB0, LA0 = 11 -> falling edge. */\r
        ELVRL1_LB8 = 1;\r
        ELVRL1_LA8 = 1;\r
@@ -222,13 +221,13 @@ static void prvSetupHardware( void )
 \r
        /* Enable external interrupt 9. */\r
        PIER00_IE1 = 1;\r
-       \r
+\r
        /* LB1, LA1 = 11 -> falling edge. */\r
        ELVRL1_LB9 = 1;\r
        ELVRL1_LA9 = 1;\r
 \r
        /* Reset and enable the interrupt request. */\r
        EIRR1_ER9 = 0;\r
-       ENIR1_EN9 = 1;  \r
+       ENIR1_EN9 = 1;\r
 }\r
 \r