USB Host Shield 2.0
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
controllerEnums.h
Go to the documentation of this file.
1 /* Copyright (C) 2013 Kristian Lauszus, TKJ Electronics. All rights reserved.
2 
3  This software may be distributed and modified under the terms of the GNU
4  General Public License version 2 (GPL2) as published by the Free Software
5  Foundation and appearing in the file GPL2.TXT included in the packaging of
6  this file. Please note that GPL2 Section 2[b] requires that all works based
7  on this software must also be made publicly available under the terms of
8  the GPL2 ("Copyleft").
9 
10  Contact information
11  -------------------
12 
13  Kristian Lauszus, TKJ Electronics
14  Web : http://www.tkjelectronics.com
15  e-mail : kristianl@tkjelectronics.com
16  */
17 
18 #ifndef _controllerenums_h
19 #define _controllerenums_h
20 
21 /*
22  This header file is used to store different enums for the controllers,
23  This is necessary so all the different libraries can be used at once
24  */
25 
27 enum LED {
28  LED1 = 0,
29  LED2 = 1,
30  LED3 = 2,
31  LED4 = 3,
32 
33  LED5 = 4,
34  LED6 = 5,
35  LED7 = 6,
36  LED8 = 7,
37  LED9 = 8,
38  LED10 = 9,
40  ALL = 4,
41 };
42 
44 enum Button {
47  UP = 0,
48  RIGHT = 1,
49  DOWN = 2,
50  LEFT = 3,
55  PLUS = 5,
56  TWO = 6,
57  ONE = 7,
58  MINUS = 8,
59  HOME = 9,
60  Z = 10,
61  C = 11,
62  B = 12,
63  A = 13,
68  L = 16,
69  R = 17,
70  ZL = 18,
71  ZR = 19,
76  SELECT = 4,
77  START = 5,
78  L3 = 6,
79  R3 = 7,
80 
81  L2 = 8,
82  R2 = 9,
83  L1 = 10,
84  R1 = 11,
85  TRIANGLE = 12,
86  CIRCLE = 13,
87  CROSS = 14,
88  SQUARE = 15,
89 
90  PS = 16,
91 
92  MOVE = 17, // Covers 12 bits - we only need to read the top 8
93  T = 18, // Covers 12 bits - we only need to read the top 8
98  BACK = 4,
99  X = 14,
100  Y = 15,
101  XBOX = 16,
102  SYNC = 17,
104 };
105 
107 enum AnalogHat {
109  LeftHatX = 0,
111  LeftHatY = 1,
116 };
117 
118 #endif