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 
27 enum LEDEnum {
28  OFF = 0,
29  LED1 = 1,
30  LED2 = 2,
31  LED3 = 3,
32  LED4 = 4,
33 
34  LED5 = 5,
35  LED6 = 6,
36  LED7 = 7,
37  LED8 = 8,
38  LED9 = 9,
39  LED10 = 10,
41  ALL = 5,
42 };
43 
45 enum ColorsEnum {
47  Red = 0xFF0000,
49  Green = 0xFF00,
51  Blue = 0xFF,
52 
54  Yellow = 0xFFEB04,
56  Lightblue = 0xFFFF,
58  Purble = 0xFF00FF,
59 
61  White = 0xFFFFFF,
63  Off = 0x00,
64 };
65 
66 enum RumbleEnum {
67  RumbleHigh = 0x10,
68  RumbleLow = 0x20,
69 };
70 
72 enum ButtonEnum {
75  UP = 0,
76  RIGHT = 1,
77  DOWN = 2,
78  LEFT = 3,
83  PLUS = 5,
84  TWO = 6,
85  ONE = 7,
86  MINUS = 8,
87  HOME = 9,
88  Z = 10,
89  C = 11,
90  B = 12,
91  A = 13,
96  L = 16,
97  R = 17,
98  ZL = 18,
99  ZR = 19,
104  SELECT = 4,
105  START = 5,
106  L3 = 6,
107  R3 = 7,
108 
109  L2 = 8,
110  R2 = 9,
111  L1 = 10,
112  R1 = 11,
113  TRIANGLE = 12,
114  CIRCLE = 13,
115  CROSS = 14,
116  SQUARE = 15,
117 
118  PS = 16,
119 
120  MOVE = 17, // Covers 12 bits - we only need to read the top 8
121  T = 18, // Covers 12 bits - we only need to read the top 8
125  SHARE = 4,
126  OPTIONS = 5,
127  TOUCHPAD = 17,
132  BACK = 4,
133  X = 14,
134  Y = 15,
135  XBOX = 16,
136  SYNC = 17,
137  BLACK = 8, // Available on the original Xbox controller
138  WHITE = 9, // Available on the original Xbox controller
142  RED = 0,
143  YELLOW = 1,
144  GREEN = 2,
145  ORANGE = 3,
146  BLUE = 4,
148 };
149 
153  LeftHatX = 0,
155  LeftHatY = 1,
160 };
161 
168  aX = 50, aY = 52, aZ = 54,
170  gZ = 56,
171  gX, gY, // These are not available on the PS3 controller
172 
174  aXmove = 28,
176  aZmove = 30,
178  aYmove = 32,
179 
181  gXmove = 40,
183  gZmove = 42,
185  gYmove = 44,
186 
188  tempMove = 46,
189 
191  mXmove = 47,
193  mZmove = 49,
195  mYmove = 50,
196 };
197 
199 enum AngleEnum {
200  Pitch = 0x01,
201  Roll = 0x02,
202 };
203 
204 #endif
AnalogHatEnum
LEDEnum
RumbleEnum
ButtonEnum
ColorsEnum
AngleEnum
SensorEnum