crflash.h File Reference

Go to the source code of this file.

Functions

void vStartFlashCoRoutines (unsigned portBASE_TYPE uxPriority)
portBASE_TYPE xAreFlashCoRoutinesStillRunning (void)


Function Documentation

void vStartFlashCoRoutines ( unsigned portBASE_TYPE  uxPriority  ) 

Definition at line 128 of file crflash.c.

References crfFIXED_DELAY_PRIORITY, crfFLASH_INDEX, crfFLASH_PRIORITY, crfMAX_FLASH_TASKS, crfQUEUE_LENGTH, portBASE_TYPE, prvFixedDelayCoRoutine(), prvFlashCoRoutine(), xCoRoutineCreate(), xFlashQueue, and xQueueCreate().

00129 {
00130 unsigned portBASE_TYPE uxIndex;
00131 
00132     if( uxNumberToCreate > crfMAX_FLASH_TASKS )
00133     {
00134         uxNumberToCreate = crfMAX_FLASH_TASKS;
00135     }
00136 
00137     /* Create the queue used to pass data between the co-routines. */
00138     xFlashQueue = xQueueCreate( crfQUEUE_LENGTH, sizeof( unsigned portBASE_TYPE ) );
00139 
00140     if( xFlashQueue )
00141     {
00142         /* Create uxNumberToCreate 'fixed delay' co-routines. */
00143         for( uxIndex = 0; uxIndex < uxNumberToCreate; uxIndex++ )
00144         {
00145             xCoRoutineCreate( prvFixedDelayCoRoutine, crfFIXED_DELAY_PRIORITY, uxIndex );
00146         }
00147 
00148         /* Create the 'flash' co-routine. */
00149         xCoRoutineCreate( prvFlashCoRoutine, crfFLASH_PRIORITY, crfFLASH_INDEX );
00150     }
00151 }

portBASE_TYPE xAreFlashCoRoutinesStillRunning ( void   ) 

Definition at line 228 of file crflash.c.

References xCoRoutineFlashStatus.

00229 {
00230     /* Return pdPASS or pdFAIL depending on whether an error has been detected
00231     or not. */
00232     return xCoRoutineFlashStatus;
00233 }


Generated on Thu Dec 17 20:02:00 2009 for AVR32 UC3 - FreeRTOS Real Time Kernel by  doxygen 1.5.5