@@ -325,28 +325,28 @@ struct joycon_imu_cal {
325
325
* All the controller's button values are stored in a u32.
326
326
* They can be accessed with bitwise ANDs.
327
327
*/
328
- static const u32 JC_BTN_Y = BIT (0 );
329
- static const u32 JC_BTN_X = BIT (1 );
330
- static const u32 JC_BTN_B = BIT (2 );
331
- static const u32 JC_BTN_A = BIT (3 );
332
- static const u32 JC_BTN_SR_R = BIT (4 );
333
- static const u32 JC_BTN_SL_R = BIT (5 );
334
- static const u32 JC_BTN_R = BIT (6 );
335
- static const u32 JC_BTN_ZR = BIT (7 );
336
- static const u32 JC_BTN_MINUS = BIT (8 );
337
- static const u32 JC_BTN_PLUS = BIT (9 );
338
- static const u32 JC_BTN_RSTICK = BIT (10 );
339
- static const u32 JC_BTN_LSTICK = BIT (11 );
340
- static const u32 JC_BTN_HOME = BIT (12 );
341
- static const u32 JC_BTN_CAP = BIT (13 ); /* capture button */
342
- static const u32 JC_BTN_DOWN = BIT (16 );
343
- static const u32 JC_BTN_UP = BIT (17 );
344
- static const u32 JC_BTN_RIGHT = BIT (18 );
345
- static const u32 JC_BTN_LEFT = BIT (19 );
346
- static const u32 JC_BTN_SR_L = BIT (20 );
347
- static const u32 JC_BTN_SL_L = BIT (21 );
348
- static const u32 JC_BTN_L = BIT (22 );
349
- static const u32 JC_BTN_ZL = BIT (23 );
328
+ #define JC_BTN_Y BIT(0)
329
+ #define JC_BTN_X BIT(1)
330
+ #define JC_BTN_B BIT(2)
331
+ #define JC_BTN_A BIT(3)
332
+ #define JC_BTN_SR_R BIT(4)
333
+ #define JC_BTN_SL_R BIT(5)
334
+ #define JC_BTN_R BIT(6)
335
+ #define JC_BTN_ZR BIT(7)
336
+ #define JC_BTN_MINUS BIT(8)
337
+ #define JC_BTN_PLUS BIT(9)
338
+ #define JC_BTN_RSTICK BIT(10)
339
+ #define JC_BTN_LSTICK BIT(11)
340
+ #define JC_BTN_HOME BIT(12)
341
+ #define JC_BTN_CAP BIT(13) /* capture button */
342
+ #define JC_BTN_DOWN BIT(16)
343
+ #define JC_BTN_UP BIT(17)
344
+ #define JC_BTN_RIGHT BIT(18)
345
+ #define JC_BTN_LEFT BIT(19)
346
+ #define JC_BTN_SR_L BIT(20)
347
+ #define JC_BTN_SL_L BIT(21)
348
+ #define JC_BTN_L BIT(22)
349
+ #define JC_BTN_ZL BIT(23)
350
350
351
351
enum joycon_msg_type {
352
352
JOYCON_MSG_TYPE_NONE ,
0 commit comments