1 /***********************************************************************
\r
2 * $Id: type.h 8242 2011-10-11 15:15:25Z nxp28536 $
\r
4 * Project: LPC43xx Common
\r
7 * Type definition Header file for NXP LPC4300 Family
\r
10 ***********************************************************************
\r
11 * Software that is described herein is for illustrative purposes only
\r
12 * which provides customers with programming information regarding the
\r
13 * products. This software is supplied "AS IS" without any warranties.
\r
14 * NXP Semiconductors assumes no responsibility or liability for the
\r
15 * use of the software, conveys no license or title under any patent,
\r
16 * copyright, or mask work right to the product. NXP Semiconductors
\r
17 * reserves the right to make changes in the software without
\r
18 * notification. NXP Semiconductors also make no representation or
\r
19 * warranty that such application will be suitable for the specified
\r
20 * use without further testing or modification.
\r
21 **********************************************************************/
\r
27 #define NULL ((void *)0)
\r
38 #define ABS(value) (value<0 ? -value : value)
\r
41 * @brief Flag Status and Interrupt Flag Status type definition
\r
43 typedef enum {RESET = 0, SET = !RESET} FlagStatus, IntStatus, SetState;
\r
44 #define PARAM_SETSTATE(State) ((State==RESET) || (State==SET))
\r
47 * @brief Functional State Definition
\r
49 typedef enum {DISABLE = 0, ENABLE = !DISABLE} FunctionalState;
\r
50 #define PARAM_FUNCTIONALSTATE(State) ((State==DISABLE) || (State==ENABLE))
\r
53 * @ Status type definition
\r
55 typedef enum {ERROR = 0, SUCCESS = !ERROR} Status;
\r
57 typedef unsigned char BYTE;
\r
58 typedef unsigned short WORD;
\r
59 typedef unsigned long DWORD;
\r
60 typedef unsigned int BOOL;
\r
64 unsigned char value;
\r
67 unsigned char bit0:1;
\r
68 unsigned char bit1:1;
\r
69 unsigned char bit2:1;
\r
70 unsigned char bit3:1;
\r
71 unsigned char bit4:1;
\r
72 unsigned char bit5:1;
\r
73 unsigned char bit6:1;
\r
74 unsigned char bit7:1;
\r
78 #endif /* __TYPE_H__ */
\r