1 /* Copyright (C) 2013 Kristian Lauszus, TKJ Electronics. All rights reserved.
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
13 Kristian Lauszus, TKJ Electronics
14 Web : http://www.tkjelectronics.com
15 e-mail : kristianl@tkjelectronics.com
18 #ifndef _controllerenums_h
19 #define _controllerenums_h
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.
26 /** Enum used to turn on the LEDs on the different controllers. */
40 /** Used to blink all LEDs on the Xbox controller */
44 /** Used to set the colors of the Move and PS4 controller. */
46 /** r = 255, g = 0, b = 0 */
48 /** r = 0, g = 255, b = 0 */
50 /** r = 0, g = 0, b = 255 */
53 /** r = 255, g = 235, b = 4 */
55 /** r = 0, g = 255, b = 255 */
57 /** r = 255, g = 0, b = 255 */
60 /** r = 255, g = 255, b = 255 */
62 /** r = 0, g = 0, b = 0 */
71 /** This enum is used to read all the different buttons on the different controllers */
74 /** These buttons are available on all the the controllers */
95 /** These are only available on the Wii U Pro Controller */
103 /** PS3 controllers buttons */
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
124 /** PS4 controllers buttons - SHARE and OPTIONS are present instead of SELECT and START */
137 BLACK = 8, // Available on the original Xbox controller
138 WHITE = 9, // Available on the original Xbox controller
141 /** PS Buzz controllers */
150 /** Joysticks on the PS3 and Xbox controllers. */
152 /** Left joystick x-axis */
154 /** Left joystick y-axis */
156 /** Right joystick x-axis */
158 /** Right joystick y-axis */
163 * Sensors inside the Sixaxis Dualshock 3, Move controller and PS4 controller.
164 * <B>Note:</B> that the location is shifted 9 when it's connected via USB on the PS3 controller.
167 /** Accelerometer values */
168 aX = 50, aY = 52, aZ = 54,
171 gX, gY, // These are not available on the PS3 controller
173 /** Accelerometer x-axis */
175 /** Accelerometer z-axis */
177 /** Accelerometer y-axis */
187 /** Temperature sensor */
190 /** Magnetometer x-axis */
192 /** Magnetometer z-axis */
194 /** Magnetometer y-axis */
198 /** Used to get the angle calculated using the PS3 controller and PS4 controller. */