types.h

00001 /*
00002         libbroadway - A general purpose library to control the Wii.
00003         General types definition
00004 
00005 # This code is licensed to you under the terms of the GNU GPL, version 2;
00006 # see file COPYING or http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt
00007 */
00008 
00009 #ifndef __TYPES_H__
00010 #define __TYPES_H__
00011 
00012 #include <stdint.h>
00013 #include <stddef.h>
00014 
00015 typedef volatile uint8_t        vuint8_t;
00016 typedef volatile uint16_t       vuint16_t;
00017 typedef volatile uint32_t       vuint32_t;
00018 typedef volatile uint64_t       vuint64_t;
00019 
00020 typedef volatile int8_t         vint8_t;
00021 typedef volatile int16_t        vint16_t;
00022 typedef volatile int32_t        vint32_t;
00023 typedef volatile int64_t        vint64_t;
00024 
00025 typedef uint8_t                 u8;
00026 typedef uint16_t                u16;
00027 typedef uint32_t                u32;
00028 typedef uint64_t                u64;
00029 typedef int8_t                  s8;
00030 typedef int16_t                 s16;
00031 typedef int32_t                 s32;
00032 typedef int64_t                 s64;
00033 
00034 typedef vuint8_t                vu8;
00035 typedef vuint16_t               vu16;
00036 typedef vuint32_t               vu32;
00037 typedef vuint64_t               vu64;
00038 typedef vint8_t                 vs8;
00039 typedef vint16_t                vs16;
00040 typedef vint32_t                vs32;
00041 typedef vint64_t                vs64;
00042 
00043 /* These types must be 16-bit, 32-bit or larger integer */
00044 typedef s32                     INT;
00045 typedef u32                     UINT;
00046 
00047 /* These types must be 8-bit integer */
00048 typedef s8                      CHAR;
00049 typedef u8                      UCHAR;
00050 typedef u8                      BYTE;
00051 
00052 /* These types must be 16-bit integer */
00053 typedef s16                     SHORT;
00054 typedef u16                     USHORT;
00055 typedef u16                     WORD;
00056 typedef u16                     WCHAR;
00057 
00058 /* These types must be 32-bit integer */
00059 typedef s32                     LONG;
00060 typedef u32                     ULONG;
00061 typedef u32                     DWORD;
00062 
00063 /* Boolean type */
00064 #ifndef FALSE
00065 #define FALSE                   (0)
00066 #endif
00067 #ifndef TRUE
00068 #define TRUE                    (1)
00069 #endif
00070 #ifndef BOOL
00071 #define BOOL                    int
00072 #endif
00073 /*typedef enum { FALSE = 0, TRUE } BOOL;*/
00074 
00075 #endif
00076 
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines
Generated by  doxygen 1.6.3