portmacro.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define portCHAR   char
 
#define portFLOAT   float
 
#define portDOUBLE   double
 
#define portLONG   long
 
#define portSHORT   short
 
#define portSTACK_TYPE   uint32_t
 
#define portBASE_TYPE   long
 
#define portMAX_DELAY   ( TickType_t ) 0xffffffffUL
 
#define portTICK_TYPE_IS_ATOMIC   1
 
#define portSTACK_GROWTH   ( -1 )
 
#define portTICK_PERIOD_MS   ( ( TickType_t ) 1000 / configTICK_RATE_HZ )
 
#define portBYTE_ALIGNMENT   8
 
#define portYIELD()
 
#define portNVIC_INT_CTRL_REG   ( * ( ( volatile uint32_t * ) 0xe000ed04 ) )
 
#define portNVIC_PENDSVSET_BIT   ( 1UL << 28UL )
 
#define portEND_SWITCHING_ISR(xSwitchRequired)   if( xSwitchRequired != pdFALSE ) portYIELD()
 
#define portYIELD_FROM_ISR(x)   portEND_SWITCHING_ISR( x )
 
#define portSET_INTERRUPT_MASK_FROM_ISR()   ulPortRaiseBASEPRI()
 
#define portCLEAR_INTERRUPT_MASK_FROM_ISR(x)   vPortSetBASEPRI(x)
 
#define portDISABLE_INTERRUPTS()   vPortRaiseBASEPRI()
 
#define portENABLE_INTERRUPTS()   vPortSetBASEPRI(0)
 
#define portENTER_CRITICAL()   vPortEnterCritical()
 
#define portEXIT_CRITICAL()   vPortExitCritical()
 
#define portTASK_FUNCTION_PROTO(vFunction, pvParameters)   void vFunction( void *pvParameters )
 
#define portTASK_FUNCTION(vFunction, pvParameters)   void vFunction( void *pvParameters )
 
#define portSUPPRESS_TICKS_AND_SLEEP(xExpectedIdleTime)   vPortSuppressTicksAndSleep( xExpectedIdleTime )
 
#define configUSE_PORT_OPTIMISED_TASK_SELECTION   1
 
#define portRECORD_READY_PRIORITY(uxPriority, uxReadyPriorities)   ( uxReadyPriorities ) |= ( 1UL << ( uxPriority ) )
 
#define portRESET_READY_PRIORITY(uxPriority, uxReadyPriorities)   ( uxReadyPriorities ) &= ~( 1UL << ( uxPriority ) )
 
#define portGET_HIGHEST_PRIORITY(uxTopPriority, uxReadyPriorities)   uxTopPriority = ( 31UL - ( uint32_t ) ucPortCountLeadingZeros( ( uxReadyPriorities ) ) )
 
#define portNOP()
 
#define portINLINE   __inline
 
#define portFORCE_INLINE   inline __attribute__(( always_inline))
 

Typedefs

typedef portSTACK_TYPE StackType_t
 
typedef long BaseType_t
 
typedef unsigned long UBaseType_t
 
typedef uint32_t TickType_t
 

Functions

void vPortEnterCritical (void)
 
void vPortExitCritical (void)
 
void vPortSuppressTicksAndSleep (TickType_t xExpectedIdleTime)
 
 __attribute__ ((always_inline)) static inline uint8_t ucPortCountLeadingZeros(uint32_t ulBitmap)
 

Macro Definition Documentation

#define configUSE_PORT_OPTIMISED_TASK_SELECTION   1
#define portBASE_TYPE   long
#define portBYTE_ALIGNMENT   8
#define portCHAR   char
#define portCLEAR_INTERRUPT_MASK_FROM_ISR (   x)    vPortSetBASEPRI(x)
#define portDISABLE_INTERRUPTS ( )    vPortRaiseBASEPRI()
#define portDOUBLE   double
#define portENABLE_INTERRUPTS ( )    vPortSetBASEPRI(0)
#define portEND_SWITCHING_ISR (   xSwitchRequired)    if( xSwitchRequired != pdFALSE ) portYIELD()
#define portENTER_CRITICAL ( )    vPortEnterCritical()
#define portEXIT_CRITICAL ( )    vPortExitCritical()
#define portFLOAT   float
#define portFORCE_INLINE   inline __attribute__(( always_inline))
#define portGET_HIGHEST_PRIORITY (   uxTopPriority,
  uxReadyPriorities 
)    uxTopPriority = ( 31UL - ( uint32_t ) ucPortCountLeadingZeros( ( uxReadyPriorities ) ) )
#define portINLINE   __inline
#define portLONG   long
#define portMAX_DELAY   ( TickType_t ) 0xffffffffUL
#define portNOP ( )
#define portNVIC_INT_CTRL_REG   ( * ( ( volatile uint32_t * ) 0xe000ed04 ) )
#define portNVIC_PENDSVSET_BIT   ( 1UL << 28UL )
#define portRECORD_READY_PRIORITY (   uxPriority,
  uxReadyPriorities 
)    ( uxReadyPriorities ) |= ( 1UL << ( uxPriority ) )
#define portRESET_READY_PRIORITY (   uxPriority,
  uxReadyPriorities 
)    ( uxReadyPriorities ) &= ~( 1UL << ( uxPriority ) )
#define portSET_INTERRUPT_MASK_FROM_ISR ( )    ulPortRaiseBASEPRI()
#define portSHORT   short
#define portSTACK_GROWTH   ( -1 )
#define portSTACK_TYPE   uint32_t
#define portSUPPRESS_TICKS_AND_SLEEP (   xExpectedIdleTime)    vPortSuppressTicksAndSleep( xExpectedIdleTime )
#define portTASK_FUNCTION (   vFunction,
  pvParameters 
)    void vFunction( void *pvParameters )
#define portTASK_FUNCTION_PROTO (   vFunction,
  pvParameters 
)    void vFunction( void *pvParameters )
#define portTICK_PERIOD_MS   ( ( TickType_t ) 1000 / configTICK_RATE_HZ )
#define portTICK_TYPE_IS_ATOMIC   1
#define portYIELD ( )
Value:
{ \
/* Set a PendSV to request a context switch. */ \
\
/* Barriers are normally not required but do ensure the code is completely \
within the specified behaviour for the architecture. */ \
__asm volatile( "dsb" ); \
__asm volatile( "isb" ); \
}
#define portNVIC_PENDSVSET_BIT
Definition: portmacro.h:133
#define portNVIC_INT_CTRL_REG
Definition: portmacro.h:132
#define portYIELD_FROM_ISR (   x)    portEND_SWITCHING_ISR( x )

Typedef Documentation

typedef long BaseType_t
typedef uint32_t TickType_t
typedef unsigned long UBaseType_t

Function Documentation

__attribute__ ( (always_inline)  )
void vPortEnterCritical ( void  )
void vPortExitCritical ( void  )
void vPortSuppressTicksAndSleep ( TickType_t  xExpectedIdleTime)