blob: 1dd8e157c5a7014e90ebe49e369d59bc7808eeaa [file] [log] [blame]
Siarhei Vishniakou46429ecd2017-11-02 18:25:12 -07001# Copyright (C) 2017 The Android Open Source Project
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15#
16# Xbox Wireless Controller
17#
18
19
20# Mapping according to https://developer.android.com/training/game-controllers/controller-input.html
21
22key 0x132 BUTTON_X
23key 0x130 BUTTON_A
24key 0x131 BUTTON_B
25key 0x133 BUTTON_Y
26
27key 0x134 BUTTON_L1
28key 0x135 BUTTON_R1
29
30# LT axis
31axis 0x02 LTRIGGER
32# RT axis
33axis 0x05 RTRIGGER
34
35
36# Left Analog Stick
37axis 0x00 X
38axis 0x01 Y
39# Right Analog Stick
40axis 0x03 Z
41axis 0x04 RZ
42
43# Left stick click
44key 0x138 BUTTON_THUMBL
45# Right stick click
46key 0x139 BUTTON_THUMBR
47
48# Hat
49axis 0x10 HAT_X
50axis 0x11 HAT_Y
51
52# Mapping according to https://www.kernel.org/doc/Documentation/input/gamepad.txt
53# Two overlapping rectangles
54key 0x136 BUTTON_SELECT
55# Hamburger - 3 parallel lines
56key 0x137 BUTTON_START
57
58# Xbox key
Siarhei Vishniakouda16f222018-08-21 18:30:16 -070059key 0x8b BUTTON_MODE