Ensure demo app files are using FreeRTOS V8 names - a few were missed previously.

This commit is contained in:
Richard Barry 2014-05-29 13:54:15 +00:00
parent ef254df85f
commit f46070dc79
60 changed files with 422 additions and 422 deletions

View file

@ -98,11 +98,11 @@ static portTASK_FUNCTION_PROTO( vCompetingMathTask4, pvParameters );
/* These variables are used to check that all the tasks are still running. If a
task gets a calculation wrong it will stop setting its check variable. */
static volatile unsigned short usTaskCheck[ mathNUMBER_OF_TASKS ] = { ( unsigned short ) 0 };
static volatile uint16_t usTaskCheck[ mathNUMBER_OF_TASKS ] = { ( uint16_t ) 0 };
/*-----------------------------------------------------------*/
void vStartMathTasks( unsigned portBASE_TYPE uxPriority )
void vStartMathTasks( UBaseType_t uxPriority )
{
xTaskCreate( vCompetingMathTask1, "Math1", mathSTACK_SIZE, ( void * ) &( usTaskCheck[ 0 ] ), uxPriority, NULL );
xTaskCreate( vCompetingMathTask2, "Math2", mathSTACK_SIZE, ( void * ) &( usTaskCheck[ 1 ] ), uxPriority, NULL );
@ -114,7 +114,7 @@ void vStartMathTasks( unsigned portBASE_TYPE uxPriority )
static portTASK_FUNCTION( vCompetingMathTask1, pvParameters )
{
volatile portDOUBLE d1, d2, d3, d4;
volatile unsigned short *pusTaskCheckVariable;
volatile uint16_t *pusTaskCheckVariable;
volatile portDOUBLE dAnswer;
short sError = pdFALSE;
@ -131,7 +131,7 @@ short sError = pdFALSE;
/* The variable this task increments to show it is still running is passed in
as the parameter. */
pusTaskCheckVariable = ( unsigned short * ) pvParameters;
pusTaskCheckVariable = ( uint16_t * ) pvParameters;
/* Keep performing a calculation and checking the result against a constant. */
for(;;)
@ -172,7 +172,7 @@ short sError = pdFALSE;
static portTASK_FUNCTION( vCompetingMathTask2, pvParameters )
{
volatile portDOUBLE d1, d2, d3, d4;
volatile unsigned short *pusTaskCheckVariable;
volatile uint16_t *pusTaskCheckVariable;
volatile portDOUBLE dAnswer;
short sError = pdFALSE;
@ -190,7 +190,7 @@ short sError = pdFALSE;
/* The variable this task increments to show it is still running is passed in
as the parameter. */
pusTaskCheckVariable = ( unsigned short * ) pvParameters;
pusTaskCheckVariable = ( uint16_t * ) pvParameters;
/* Keep performing a calculation and checking the result against a constant. */
for( ;; )
@ -230,7 +230,7 @@ short sError = pdFALSE;
static portTASK_FUNCTION( vCompetingMathTask3, pvParameters )
{
volatile portDOUBLE *pdArray, dTotal1, dTotal2, dDifference;
volatile unsigned short *pusTaskCheckVariable;
volatile uint16_t *pusTaskCheckVariable;
const size_t xArraySize = 10;
size_t xPosition;
short sError = pdFALSE;
@ -242,7 +242,7 @@ short sError = pdFALSE;
/* The variable this task increments to show it is still running is passed in
as the parameter. */
pusTaskCheckVariable = ( unsigned short * ) pvParameters;
pusTaskCheckVariable = ( uint16_t * ) pvParameters;
pdArray = ( portDOUBLE * ) pvPortMalloc( xArraySize * sizeof( portDOUBLE ) );
@ -293,7 +293,7 @@ short sError = pdFALSE;
static portTASK_FUNCTION( vCompetingMathTask4, pvParameters )
{
volatile portDOUBLE *pdArray, dTotal1, dTotal2, dDifference;
volatile unsigned short *pusTaskCheckVariable;
volatile uint16_t *pusTaskCheckVariable;
const size_t xArraySize = 10;
size_t xPosition;
short sError = pdFALSE;
@ -305,7 +305,7 @@ short sError = pdFALSE;
/* The variable this task increments to show it is still running is passed in
as the parameter. */
pusTaskCheckVariable = ( unsigned short * ) pvParameters;
pusTaskCheckVariable = ( uint16_t * ) pvParameters;
pdArray = ( portDOUBLE * ) pvPortMalloc( xArraySize * sizeof( portDOUBLE ) );
@ -354,9 +354,9 @@ short sError = pdFALSE;
/*-----------------------------------------------------------*/
/* This is called to check that all the created tasks are still running. */
portBASE_TYPE xAreMathsTaskStillRunning( void )
BaseType_t xAreMathsTaskStillRunning( void )
{
portBASE_TYPE xReturn = pdPASS, xTask;
BaseType_t xReturn = pdPASS, xTask;
/* Check the maths tasks are still running by ensuring their check variables
have been set to pdPASS. */