version 0.1 written by Akiba, taken from here:
[chibi.git] / freakusb / usb / types.h
blobaf3036fbd30089d93e79147e3e048ca1227ff928
1 /*******************************************************************
2 Copyright (C) 2008 FreakLabs
4 This program is free software; you can redistribute it and/or modify
5 it under the terms of the GNU General Public License as published by
6 the Free Software Foundation; either version 2 of the License, or
7 (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 GNU General Public License for more details.
14 You should have received a copy of the GNU General Public License along
15 with this program; if not, write to the Free Software Foundation, Inc.,
16 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 Please post support questions to the FreakLabs forum.
19 *******************************************************************/
20 /*!
21 \file types.h
22 \ingroup usb
24 /*******************************************************************/
25 #ifndef TYPES_H
26 #define TYPES_H
28 #include <stdbool.h>
30 // Standard data types
31 typedef unsigned char U8; /// Generic 8 bit unsigned data type
32 typedef unsigned short U16; /// Generic 16 bit unsigned data type
33 typedef unsigned int U32; /// Generic 32 bit unsigned data type
34 typedef unsigned long long U64; /// Generic 64 bit unsigned data type
36 typedef signed char S8; /// Generic 8 bit signed data type
37 typedef signed short S16; /// Generic 16 bit signed data type
38 typedef signed int S32; /// Generic 32 bit signed data type
40 /*!
41 Boolean type definition. It uses a full byte to hold a boolean value.
42 Slightly inefficient.
44 //typedef enum
45 //{
46 // false = 0,
47 // true = 1
48 //} bool;
49 #endif