Go to the documentation of this file.
69 #ifndef INC_FREERTOS_H
70 #error "include FreeRTOS.h must appear in source files before include croutine.h"
242 #define crSTART( pxCRCB ) switch( ( ( corCRCB * )( pxCRCB ) )->uxState ) { case 0:
279 #define crSET_STATE0( xHandle ) ( ( corCRCB * )( xHandle ) )->uxState = (__LINE__ * 2); return; case (__LINE__ * 2):
280 #define crSET_STATE1( xHandle ) ( ( corCRCB * )( xHandle ) )->uxState = ((__LINE__ * 2)+1); return; case ((__LINE__ * 2)+1):
328 #define crDELAY( xHandle, xTicksToDelay ) \
329 if( ( xTicksToDelay ) > 0 ) \
331 vCoRoutineAddToDelayedList( ( xTicksToDelay ), NULL ); \
333 crSET_STATE0( ( xHandle ) );
418 #define crQUEUE_SEND( xHandle, pxQueue, pvItemToQueue, xTicksToWait, pxResult ) \
420 *( pxResult ) = xQueueCRSend( ( pxQueue) , ( pvItemToQueue) , ( xTicksToWait ) ); \
421 if( *( pxResult ) == errQUEUE_BLOCKED ) \
423 crSET_STATE0( ( xHandle ) ); \
424 *pxResult = xQueueCRSend( ( pxQueue ), ( pvItemToQueue ), 0 ); \
426 if( *pxResult == errQUEUE_YIELD ) \
428 crSET_STATE1( ( xHandle ) ); \
429 *pxResult = pdPASS; \
510 #define crQUEUE_RECEIVE( xHandle, pxQueue, pvBuffer, xTicksToWait, pxResult ) \
512 *( pxResult ) = xQueueCRReceive( ( pxQueue) , ( pvBuffer ), ( xTicksToWait ) ); \
513 if( *( pxResult ) == errQUEUE_BLOCKED ) \
515 crSET_STATE0( ( xHandle ) ); \
516 *( pxResult ) = xQueueCRReceive( ( pxQueue) , ( pvBuffer ), 0 ); \
518 if( *( pxResult ) == errQUEUE_YIELD ) \
520 crSET_STATE1( ( xHandle ) ); \
521 *( pxResult ) = pdPASS; \
619 #define crQUEUE_SEND_FROM_ISR( pxQueue, pvItemToQueue, xCoRoutinePreviouslyWoken ) xQueueCRSendFromISR( ( pxQueue ), ( pvItemToQueue ), ( xCoRoutinePreviouslyWoken ) )
732 #define crQUEUE_RECEIVE_FROM_ISR( pxQueue, pvBuffer, pxCoRoutineWoken ) xQueueCRReceiveFromISR( ( pxQueue ), ( pvBuffer ), ( pxCoRoutineWoken ) )