forked from mmoller2k/pikeyd
-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathpikeyd.conf
47 lines (42 loc) · 808 Bytes
/
pikeyd.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#joy.cfg
#format:
# [keycode from /usr/include/linux/input.h] [whitespace] [GPIO pin no]
# Not limited to a single key. A GPIO press will emit all defined keys in order.
KEY_LEFT 0
KEY_RIGHT 1
KEY_UP 4
KEY_DOWN 7
KEY_W 0
KEY_A 1
KEY_S 4
KEY_D 7
KEY_1 8
KEY_2 9
KEY_3 10
KEY_4 11
KEY_5 14
KEY_6 15
KEY_7 17
KEY_8 18
KEY_9 21
KEY_0 22
KEY_MINUS 23
KEY_EQUAL 24
KEY_ESC 25
KEY_H 21
KEY_E 21
KEY_L 21
KEY_L 21
KEY_O 21
#define I/O expanders before using them
#XIO(tag) gpio_int_pin/chip_addr:register_no
#MCP23008 only has a single 8-bit bank
XIO_M 17/0x20/MCP23008
#define an MCP23008 expander at address 0x20 with interrupt wired to GPIO-17
#MCP23017 has two 8-bit banks
#XIO_A 17/0x20/MCP23017A
#XIO_B 17/0x20/MCP23017B
KEY_O XIO_M:1
KEY_L XIO_M:2
KEY_E XIO_A:6
KEY_E XIO_B:6