aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Svensson <dsvensson@gmail.com>2016-05-29 16:39:27 +0200
committerJack Humbert <jack.humb@gmail.com>2016-05-29 10:39:27 -0400
commitb85dd60397e139f787ae26552145391f34686f4d (patch)
treebf77eddbf64cf3cea1600da2e8ac3c35ab472ff7
parent536ad6813a452328d8b3437c55c1984f84eecc79 (diff)
downloadqmk_firmware-b85dd60397e139f787ae26552145391f34686f4d.tar.gz
qmk_firmware-b85dd60397e139f787ae26552145391f34686f4d.zip
Fix build errors (#359)
* brings gh60 up-to-date (needs testing) * brings hhkb up-to-date (needs testing) * brings jd45 up-to-date (needs testing)
-rw-r--r--keyboard/gh60/Makefile10
-rw-r--r--keyboard/gh60/keymap_common.c30
-rw-r--r--keyboard/hhkb/Makefile2
-rw-r--r--keyboard/hhkb/matrix.c8
-rw-r--r--keyboard/jd45/Makefile2
5 files changed, 15 insertions, 37 deletions
diff --git a/keyboard/gh60/Makefile b/keyboard/gh60/Makefile
index 4c8f9dc8a..9429049fd 100644
--- a/keyboard/gh60/Makefile
+++ b/keyboard/gh60/Makefile
@@ -42,14 +42,14 @@
42TARGET = gh60_lufa 42TARGET = gh60_lufa
43 43
44# Directory common source filess exist 44# Directory common source filess exist
45TOP_DIR = ../..
45TMK_DIR = ../../tmk_core 46TMK_DIR = ../../tmk_core
46 47
47# Directory keyboard dependent files exist 48# Directory keyboard dependent files exist
48TARGET_DIR = . 49TARGET_DIR = .
49 50
50# project specific files 51# project specific files
51SRC = keymap_common.c \ 52SRC = matrix.c \
52 matrix.c \
53 led.c 53 led.c
54 54
55ifdef KEYMAP 55ifdef KEYMAP
@@ -119,6 +119,7 @@ MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
119EXTRAKEY_ENABLE = yes # Audio control and System control(+450) 119EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
120CONSOLE_ENABLE = yes # Console for debug(+400) 120CONSOLE_ENABLE = yes # Console for debug(+400)
121COMMAND_ENABLE = yes # Commands for debug and configuration 121COMMAND_ENABLE = yes # Commands for debug and configuration
122CUSTOM_MATRIX = yes
122#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend 123#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
123NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA 124NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA
124 125
@@ -128,8 +129,7 @@ NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA
128 129
129# Search Path 130# Search Path
130VPATH += $(TARGET_DIR) 131VPATH += $(TARGET_DIR)
132VPATH += $(TOP_DIR)
131VPATH += $(TMK_DIR) 133VPATH += $(TMK_DIR)
132 134
133include $(TMK_DIR)/protocol/lufa.mk 135include $(TOP_DIR)/quantum/quantum.mk
134include $(TMK_DIR)/common.mk
135include $(TMK_DIR)/rules.mk \ No newline at end of file
diff --git a/keyboard/gh60/keymap_common.c b/keyboard/gh60/keymap_common.c
deleted file mode 100644
index fdb1769e1..000000000
--- a/keyboard/gh60/keymap_common.c
+++ /dev/null
@@ -1,30 +0,0 @@
1/*
2Copyright 2012,2013 Jun Wako <wakojun@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 2 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#include "keymap_common.h"
18
19
20/* translates key to keycode */
21uint8_t keymap_key_to_keycode(uint8_t layer, keypos_t key)
22{
23 return pgm_read_byte(&keymaps[(layer)][(key.row)][(key.col)]);
24}
25
26/* translates Fn keycode to action */
27action_t keymap_fn_to_action(uint8_t keycode)
28{
29 return (action_t){ .code = pgm_read_word(&fn_actions[FN_INDEX(keycode)]) };
30}
diff --git a/keyboard/hhkb/Makefile b/keyboard/hhkb/Makefile
index 21ba261a2..b6c3b869e 100644
--- a/keyboard/hhkb/Makefile
+++ b/keyboard/hhkb/Makefile
@@ -56,7 +56,7 @@ SRC = hhkb_qmk.c \
56ifdef KEYMAP 56ifdef KEYMAP
57 SRC := keymaps/keymaps/$(KEYMAP).c $(SRC) 57 SRC := keymaps/keymaps/$(KEYMAP).c $(SRC)
58else 58else
59 SRC := keymaps/keymaps/default.c $(SRC) 59 SRC := keymaps/default.c $(SRC)
60endif 60endif
61 61
62CONFIG_H = config.h 62CONFIG_H = config.h
diff --git a/keyboard/hhkb/matrix.c b/keyboard/hhkb/matrix.c
index 14fae0b82..2dfb2f5e1 100644
--- a/keyboard/hhkb/matrix.c
+++ b/keyboard/hhkb/matrix.c
@@ -188,6 +188,14 @@ void matrix_print(void)
188 } 188 }
189} 189}
190 190
191uint8_t matrix_key_count(void) {
192 uint8_t count = 0;
193 for (int8_t r = MATRIX_ROWS - 1; r >= 0; --r) {
194 count += bitpop16(matrix_get_row(r));
195 }
196 return count;
197}
198
191void matrix_power_up(void) { 199void matrix_power_up(void) {
192 KEY_POWER_ON(); 200 KEY_POWER_ON();
193} 201}
diff --git a/keyboard/jd45/Makefile b/keyboard/jd45/Makefile
index f6a8d10c5..d270a6f8a 100644
--- a/keyboard/jd45/Makefile
+++ b/keyboard/jd45/Makefile
@@ -56,7 +56,7 @@ SRC = jd45.c \
56ifdef KEYMAP 56ifdef KEYMAP
57 SRC := keymaps/keymaps/(KEYMAP).c $(SRC) 57 SRC := keymaps/keymaps/(KEYMAP).c $(SRC)
58else 58else
59 SRC := keymaps/keymaps/default.c $(SRC) 59 SRC := keymaps/default.c $(SRC)
60endif 60endif
61 61
62CONFIG_H = config.h 62CONFIG_H = config.h