X-Git-Url: https://git.friedersdorff.com/?a=blobdiff_plain;ds=sidebyside;f=converter%2Fadb_usb%2Fconfig.h;h=5ce5c22159481f81b3b58c498d8fb8464d3d7fd0;hb=c6e533ce83d6ae4393e6cdf1f6d39ffefc790115;hp=52d5925a508e43bd9c50da1a5f10bc6e64bf0fd7;hpb=afb08462085132acf7a1962522952f7dbf064519;p=max%2Ftmk_keyboard.git
diff --git a/converter/adb_usb/config.h b/converter/adb_usb/config.h
index 52d5925a..5ce5c221 100644
--- a/converter/adb_usb/config.h
+++ b/converter/adb_usb/config.h
@@ -18,8 +18,6 @@ along with this program. If not, see .
#ifndef CONFIG_H
#define CONFIG_H
-/* controller configuration */
-#include "controller_teensy.h"
#define VENDOR_ID 0xFEED
#define PRODUCT_ID 0x0ADB
@@ -32,41 +30,34 @@ along with this program. If not, see .
#define MATRIX_ROWS 16 // keycode bit: 3-0
#define MATRIX_COLS 8 // keycode bit: 6-4
-/* Locking Caps Lock support */
-#define MATRIX_HAS_LOCKING_CAPS
+#define MATRIX_ROW(code) ((code)>>3&0x0F)
+#define MATRIX_COL(code) ((code)&0x07)
-/* key combination for command */
-#define IS_COMMAND() ( \
- keyboard_report->mods == (MOD_BIT(KB_LSHIFT) | MOD_BIT(KB_LCTRL) | MOD_BIT(KB_LALT) | MOD_BIT(KB_LGUI)) || \
- keyboard_report->mods == (MOD_BIT(KB_LSHIFT) | MOD_BIT(KB_RSHIFT)) \
-)
-
-
-/* mouse keys */
-#ifdef MOUSEKEY_ENABLE
-# define MOUSEKEY_DELAY_TIME 192
-#endif
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
-/* PS/2 mouse */
-#ifdef PS2_MOUSE_ENABLE
-# define PS2_CLOCK_PORT PORTF
-# define PS2_CLOCK_PIN PINF
-# define PS2_CLOCK_DDR DDRF
-# define PS2_CLOCK_BIT 0
-# define PS2_DATA_PORT PORTF
-# define PS2_DATA_PIN PINF
-# define PS2_DATA_DDR DDRF
-# define PS2_DATA_BIT 1
-#endif
+/* legacy keymap support */
+#define USE_LEGACY_KEYMAP
/* ADB port setting */
-#define ADB_PORT PORTF
-#define ADB_PIN PINF
-#define ADB_DDR DDRF
+#define ADB_PORT PORTD
+#define ADB_PIN PIND
+#define ADB_DDR DDRD
#define ADB_DATA_BIT 0
//#define ADB_PSW_BIT 1 // optional
+/* key combination for command */
+#ifndef __ASSEMBLER__
+#include "adb.h"
+#include "matrix.h"
+#define IS_COMMAND() ( \
+ matrix_is_on(MATRIX_ROW(ADB_POWER), MATRIX_COL(ADB_POWER)) \
+)
+#endif
+
#endif