X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=FreeRTOS%2FDemo%2FCORTEX_A9_Zynq_ZC702%2FRTOSDemo%2Fsrc%2FFull_Demo%2Fmain_full.c;h=c113594776f4000a7191ddaca39e1e8a0c85a5e2;hb=70f0bb6133065c1f0049f8258d0454027d37f657;hp=36cd22b0be2aec59eb1ea242a61da3778bdf9813;hpb=848e93f82db671b616ba01196c539ebea2df891c;p=freertos diff --git a/FreeRTOS/Demo/CORTEX_A9_Zynq_ZC702/RTOSDemo/src/Full_Demo/main_full.c b/FreeRTOS/Demo/CORTEX_A9_Zynq_ZC702/RTOSDemo/src/Full_Demo/main_full.c index 36cd22b0b..c11359477 100644 --- a/FreeRTOS/Demo/CORTEX_A9_Zynq_ZC702/RTOSDemo/src/Full_Demo/main_full.c +++ b/FreeRTOS/Demo/CORTEX_A9_Zynq_ZC702/RTOSDemo/src/Full_Demo/main_full.c @@ -1,60 +1,64 @@ /* - FreeRTOS V8.1.2 - Copyright (C) 2014 Real Time Engineers Ltd. + FreeRTOS V9.0.0rc2 - Copyright (C) 2016 Real Time Engineers Ltd. All rights reserved VISIT http://www.FreeRTOS.org TO ENSURE YOU ARE USING THE LATEST VERSION. - *************************************************************************** - * * - * FreeRTOS provides completely free yet professionally developed, * - * robust, strictly quality controlled, supported, and cross * - * platform software that has become a de facto standard. * - * * - * Help yourself get started quickly and support the FreeRTOS * - * project by purchasing a FreeRTOS tutorial book, reference * - * manual, or both from: http://www.FreeRTOS.org/Documentation * - * * - * Thank you! * - * * - *************************************************************************** - This file is part of the FreeRTOS distribution. FreeRTOS is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License (version 2) as published by the - Free Software Foundation >>!AND MODIFIED BY!<< the FreeRTOS exception. + Free Software Foundation >>>> AND MODIFIED BY <<<< the FreeRTOS exception. + *************************************************************************** >>! NOTE: The modification to the GPL is included to allow you to !<< >>! distribute a combined work that includes FreeRTOS without being !<< >>! obliged to provide the source code for proprietary components !<< >>! outside of the FreeRTOS kernel. !<< + *************************************************************************** FreeRTOS is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS - FOR A PARTICULAR PURPOSE. Full license text is available from the following + FOR A PARTICULAR PURPOSE. Full license text is available on the following link: http://www.freertos.org/a00114.html - 1 tab == 4 spaces! - *************************************************************************** * * - * Having a problem? Start by reading the FAQ "My application does * - * not run, what could be wrong?" * + * FreeRTOS provides completely free yet professionally developed, * + * robust, strictly quality controlled, supported, and cross * + * platform software that is more than just the market leader, it * + * is the industry's de facto standard. * * * - * http://www.FreeRTOS.org/FAQHelp.html * + * Help yourself get started quickly while simultaneously helping * + * to support the FreeRTOS project by purchasing a FreeRTOS * + * tutorial book, reference manual, or both: * + * http://www.FreeRTOS.org/Documentation * * * *************************************************************************** - http://www.FreeRTOS.org - Documentation, books, training, latest versions, - license and Real Time Engineers Ltd. contact details. + http://www.FreeRTOS.org/FAQHelp.html - Having a problem? Start by reading + the FAQ page "My application does not run, what could be wrong?". Have you + defined configASSERT()? + + http://www.FreeRTOS.org/support - In return for receiving this top quality + embedded software for free we request you assist our global community by + participating in the support forum. + + http://www.FreeRTOS.org/training - Investing in training allows your team to + be as productive as possible as early as possible. Now you can receive + FreeRTOS training directly from Richard Barry, CEO of Real Time Engineers + Ltd, and the world's leading authority on the world's leading RTOS. http://www.FreeRTOS.org/plus - A selection of FreeRTOS ecosystem products, including FreeRTOS+Trace - an indispensable productivity tool, a DOS compatible FAT file system, and our tiny thread aware UDP/IP stack. - http://www.OpenRTOS.com - Real Time Engineers ltd license FreeRTOS to High - Integrity Systems to sell under the OpenRTOS brand. Low cost OpenRTOS - licenses offer ticketed support, indemnification and middleware. + http://www.FreeRTOS.org/labs - Where new FreeRTOS products go to incubate. + Come and try FreeRTOS+TCP, our new open source TCP/IP stack for FreeRTOS. + + http://www.OpenRTOS.com - Real Time Engineers ltd. license FreeRTOS to High + Integrity Systems ltd. to sell under the OpenRTOS brand. Low cost OpenRTOS + licenses offer ticketed support, indemnification and commercial middleware. http://www.SafeRTOS.com - High Integrity Systems also provide a safety engineered and independently SIL3 certified version for use in safety and @@ -144,6 +148,11 @@ #include "QueueOverwrite.h" #include "IntQueue.h" #include "EventGroupsDemo.h" +#include "TaskNotify.h" +#include "IntSemTest.h" +#include "StaticAllocation.h" +#include "AbortDelay.h" + /* Priorities for the demo application tasks. */ #define mainSEM_TEST_PRIORITY ( tskIDLE_PRIORITY + 1UL ) @@ -224,7 +233,7 @@ static void prvPseudoRandomiser( void *pvParameters ); /* The following two variables are used to communicate the status of the register check tasks to the check task. If the variables keep incrementing, -then the register check tasks has not discovered any errors. If a variable +then the register check tasks have not discovered any errors. If a variable stops incrementing, then an error has been found. */ volatile unsigned long ulRegTest1LoopCounter = 0UL, ulRegTest2LoopCounter = 0UL; @@ -235,7 +244,7 @@ char *pcStatusMessage = "All tasks running without error"; void main_full( void ) { - /* Start all the other standard demo/test tasks. They have not particular + /* Start all the other standard demo/test tasks. They have no particular functionality, but do demonstrate how to use the FreeRTOS API and test the kernel port. */ vStartInterruptQueueTasks(); @@ -250,6 +259,10 @@ void main_full( void ) vStartTimerDemoTask( mainTIMER_TEST_PERIOD ); vStartQueueOverwriteTask( mainQUEUE_OVERWRITE_PRIORITY ); vStartEventGroupTasks(); + vStartTaskNotifyTask(); + vStartInterruptSemaphoreTasks(); + vStartStaticallyAllocatedTasks(); + vCreateAbortDelayTasks(); /* Start the tasks that implements the command console on the UART, as described above. */ @@ -318,80 +331,100 @@ unsigned long ulErrorFound = pdFALSE; that they are all still running, and that none have detected an error. */ if( xAreIntQueueTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 0UL; } if( xAreMathsTaskStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 1UL; } if( xAreDynamicPriorityTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 2UL; } if( xAreBlockingQueuesStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 3UL; } if ( xAreBlockTimeTestTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 4UL; } if ( xAreGenericQueueTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 5UL; } if ( xAreRecursiveMutexTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 6UL; } if( xIsCreateTaskStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 7UL; } if( xAreSemaphoreTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 8UL; } if( xAreTimerDemoTasksStillRunning( ( TickType_t ) mainNO_ERROR_CHECK_TASK_PERIOD ) != pdPASS ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 9UL; } if( xAreCountingSemaphoreTasksStillRunning() != pdTRUE ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 10UL; } if( xIsQueueOverwriteTaskStillRunning() != pdPASS ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 11UL; } if( xAreEventGroupTasksStillRunning() != pdPASS ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 12UL; + } + + if( xAreTaskNotificationTasksStillRunning() != pdTRUE ) + { + ulErrorFound |= 1UL << 13UL; + } + + if( xAreInterruptSemaphoreTasksStillRunning() != pdTRUE ) + { + ulErrorFound |= 1UL << 14UL; + } + + if( xAreStaticAllocationTasksStillRunning() != pdPASS ) + { + ulErrorFound |= 1UL << 15UL; + } + + if( xAreAbortDelayTestTasksStillRunning() != pdPASS ) + { + ulErrorFound |= 1UL << 16UL; } /* Check that the register test 1 task is still running. */ if( ulLastRegTest1Value == ulRegTest1LoopCounter ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 17UL; } ulLastRegTest1Value = ulRegTest1LoopCounter; /* Check that the register test 2 task is still running. */ if( ulLastRegTest2Value == ulRegTest2LoopCounter ) { - ulErrorFound = pdTRUE; + ulErrorFound |= 1UL << 18UL; } ulLastRegTest2Value = ulRegTest2LoopCounter;