uT-Kernel 2.0 Specification
3.1.1 General Data Types
typedef signed char B; /* signed 8- bit integer */
typedef signed short H; /* signed 16 - bit integer */
typedef signed long W; /* signed 32 - bit integer */
typedef signed long long D; /* signed 64 - bit integer */
typedef unsigned char UB ; /* unsigned 8- bit integer */
typedef unsigned short UH ; /* unsigned 16 - bit integer */
typedef unsigned long UW ; /* unsigned 32 - bit integer */
typedef unsigned long long UD ; /* unsigned 64 - bit integer */
typedef char VB ; /* 8 - bit data without an intended type */
typedef short VH ; /* 16 - bit data without an intended type */
typedef long VW ; /* 32 - bit data without an intended type */
typedef long long VD ; /* 64 - bit data without an intended type */
typedef void * VP ; /* pointer to data without an intended type */
typedef volatile B _B ; /* volatile declaration */
typedef volatile H _H ;
typedef volatile W _W ;
typedef volatile D _D ;
typedef volatile UB _UB ;
typedef volatile UH _UH ;
typedef volatile UW _UW ;
typedef volatile UD _UD ;
typedef signed int INT ; /* signed integer of processor bit width */
typedef unsigned int UINT ; /* unsigned integer of processor bit width */
typedef INT SZ ; /* Generic SiZe */
typedef INT ID ; /* general ID */
typedef W MSEC ; /* general time ( in milliseconds ) */
typedef void (* FP ) () ; /* general function address */
typedef INT (* FUNCP ) () ; /* general function address */
# define LOCAL static /* local symbol definition */
# define EXPORT /* global symbol definition */
# define IMPORT extern /* global symbol reference */
/*
* Boolean values
* TRUE = 1 is defined , but any value other than 0 is logically TRUE .
* Do NOT use as in if ( bool == TRUE )
* use as in if ( bool )
*/
typedef UINT BOOL ;
# define TRUE 1 /* true */
# define FALSE 0 /* false */
/*
* TRON character codes
*/
typedef UH TC ; /* TRON character codes */
# define TNULL (( TC ) 0) /* TRON code string termination */
3.1.2 Other Defined Data Types
typedef INT FN ; /* Function Codes */
typedef INT RNO ; /* rendezvous number */
typedef UW ATR ; /* Object / handler attributes */
typedef INT ER ; /* Error Code */
typedef INT PRI ; /* Priority */
typedef W TMO ; /* Timeout specification in milliseconds */
typedef D TMO_U ; /* Timeout specification in microseconds with 64 - â
bit integer */
typedef UW RELTIM ; /* Relative time in milliseconds */
typedef UD RELTIM_U ; /* Relative time in microseconds with 64 - bit â
integer */
typedef struct systim { /* System time in milliseconds */
W hi ; /* High 32 bits */
UW lo ; /* Low 32 bits */
} SYSTIM ;
typedef D SYSTIM_U ; /* System time in microseconds with 64 - bit integer â
*/
/*
* Common constants
*/
# define NULL 0 /* Null pointer */
# define TA_NULL 0 /* No special attributes indicated */
# define TMO_POL 0 /* Polling */
# define TMO_FEVR ( -1) /* Eternal wait */