aboutsummaryrefslogtreecommitdiff
path: root/keyboards/yampad/yampad.h
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/yampad/yampad.h')
-rw-r--r--keyboards/yampad/yampad.h57
1 files changed, 57 insertions, 0 deletions
diff --git a/keyboards/yampad/yampad.h b/keyboards/yampad/yampad.h
new file mode 100644
index 000000000..68ec98ffd
--- /dev/null
+++ b/keyboards/yampad/yampad.h
@@ -0,0 +1,57 @@
1
2/* Copyright 2019
3 *
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17#pragma once
18
19#include "quantum.h"
20#define ___ KC_NO
21
22/* This a shortcut to help you visually see your layout.
23 *
24 * The first section contains all of the arguments representing the physical
25 * layout of the board and position of the keys.
26 *
27 * The second converts the arguments into a two-dimensional array which
28 * represents the switch matrix.
29 */
30
31/* COSPAD numpad matrix layout
32 * ,-------------------.
33 * | 00 | 01 | 02 | 03 |
34 * |----|----|----|----|
35 * | 10 | 11 | 12 | |
36 * |----|----|----| 13 |
37 * | 20 | 21 | 22 | |
38 * |----|----|----|----|
39 * | 30 | 31 | 32 | |
40 * |----|----|----| 43 |
41 * | 40 | 41 | 42 | |
42 * `-------------------'
43 */
44#define LAYOUT( \
45 k00, k01, k02, k03, \
46 k10, k11, k12, \
47 k20, k21, k22, k13, \
48 k30, k31, k32, \
49 k40, k41, k42, k43 \
50) \
51{ \
52 {k00, k01, k02, k03}, \
53 {k10, k11, k12, k13}, \
54 {k20, k21, k22, ___}, \
55 {k30, k31, k32, ___}, \
56 {k40, k41, k42, k43} \
57}