summaryrefslogtreecommitdiff
path: root/hhkb
diff options
context:
space:
mode:
Diffstat (limited to 'hhkb')
-rw-r--r--hhkb/Makefile10
-rw-r--r--hhkb/config.h13
-rw-r--r--hhkb/keymap.c8
-rw-r--r--hhkb/matrix.c2
4 files changed, 18 insertions, 15 deletions
diff --git a/hhkb/Makefile b/hhkb/Makefile
index 7c7ed0ee23..2c8cd5afcf 100644
--- a/hhkb/Makefile
+++ b/hhkb/Makefile
@@ -8,11 +8,13 @@ COMMON_DIR = ..
TARGET_DIR = .
# keyboard dependent files
-TARGET_SRC = tmk.c \
+TARGET_SRC = main_pjrc.c \
keymap.c \
matrix.c \
led.c
+CONFIG_H = config.h
+
# MCU name, you MUST set this to match the board you are using
# type "make clean" after changing this, so all files will be rebuilt
@@ -38,5 +40,11 @@ USB_EXTRA_ENABLE = yes # Enhanced feature for Windows(Audio control and System c
USB_NKRO_ENABLE = yes # USB Nkey Rollover
+
+#---------------- Programming Options --------------------------
+PROGRAM_CMD = teensy_loader_cli.exe -mmcu=$(MCU) -w -v $(TARGET).hex
+
+
+
include $(COMMON_DIR)/Makefile.pjrc
include $(COMMON_DIR)/Makefile.common
diff --git a/hhkb/config.h b/hhkb/config.h
index b8392aa8eb..886eef928a 100644
--- a/hhkb/config.h
+++ b/hhkb/config.h
@@ -10,26 +10,27 @@
#define PRODUCT HHKB mod
#define DESCRIPTION t.m.k. keyboard firmware for HHKB mod
+
/* matrix size */
#define MATRIX_ROWS 8
#define MATRIX_COLS 8
-
/* define if matrix has ghost */
//#define MATRIX_HAS_GHOST
-/* key combination for command */
-#define IS_COMMAND() (keyboard_report->mods == (BIT_LSHIFT | BIT_RSHIFT))
+/* key combination for command */
+#define IS_COMMAND() ( \
+ keyboard_report->mods == (BIT_LSHIFT | BIT_RSHIFT) || \
+ keyboard_report->mods == (BIT_LCTRL | BIT_RSHIFT) \
+)
-/* USB NKey Rollover */
-#ifdef USB_NKRO_ENABLE
-#endif
/* mouse keys */
#ifdef MOUSEKEY_ENABLE
# define MOUSEKEY_DELAY_TIME 192
#endif
+
/* PS/2 mouse */
#ifdef PS2_MOUSE_ENABLE
/*
diff --git a/hhkb/keymap.c b/hhkb/keymap.c
index d6acf4595a..78f1a7f759 100644
--- a/hhkb/keymap.c
+++ b/hhkb/keymap.c
@@ -9,7 +9,7 @@
#include "print.h"
#include "debug.h"
#include "util.h"
-#include "keymap_skel.h"
+#include "keymap.h"
// Convert physical keyboard layout to matrix array.
@@ -193,9 +193,3 @@ uint8_t keymap_fn_keycode(uint8_t fn_bits)
{
return pgm_read_byte(&fn_keycode[(biton(fn_bits))]);
}
-
-// define a condition to enter special function mode
-bool keymap_is_special_mode(uint8_t fn_bits)
-{
- return host_get_mods() == (BIT_LSHIFT | BIT_RSHIFT) || host_get_mods() == (BIT_LCTRL | BIT_RSHIFT);
-}
diff --git a/hhkb/matrix.c b/hhkb/matrix.c
index 15633d53da..fefd247873 100644
--- a/hhkb/matrix.c
+++ b/hhkb/matrix.c
@@ -7,7 +7,7 @@
#include <util/delay.h>
#include "print.h"
#include "util.h"
-#include "matrix_skel.h"
+#include "matrix.h"
#if (MATRIX_COLS > 16)