summaryrefslogtreecommitdiff
path: root/keyboards/amjkeyboard/amjpad
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/amjkeyboard/amjpad')
-rw-r--r--keyboards/amjkeyboard/amjpad/amjpad.c1
-rw-r--r--keyboards/amjkeyboard/amjpad/amjpad.h58
-rw-r--r--keyboards/amjkeyboard/amjpad/config.h86
-rw-r--r--keyboards/amjkeyboard/amjpad/info.json13
-rw-r--r--keyboards/amjkeyboard/amjpad/keymaps/default/keymap.c59
-rw-r--r--keyboards/amjkeyboard/amjpad/keymaps/max/keymap.c63
-rw-r--r--keyboards/amjkeyboard/amjpad/keymaps/ortho_left/keymap.c63
-rw-r--r--keyboards/amjkeyboard/amjpad/keymaps/ortho_right/keymap.c62
-rw-r--r--keyboards/amjkeyboard/amjpad/readme.md14
-rw-r--r--keyboards/amjkeyboard/amjpad/rules.mk20
10 files changed, 439 insertions, 0 deletions
diff --git a/keyboards/amjkeyboard/amjpad/amjpad.c b/keyboards/amjkeyboard/amjpad/amjpad.c
new file mode 100644
index 0000000000..83cdedf688
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/amjpad.c
@@ -0,0 +1 @@
+#include "amjpad.h"
diff --git a/keyboards/amjkeyboard/amjpad/amjpad.h b/keyboards/amjkeyboard/amjpad/amjpad.h
new file mode 100644
index 0000000000..976a7ab041
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/amjpad.h
@@ -0,0 +1,58 @@
+#pragma once
+
+#include "quantum.h"
+
+// readability
+#define XXX KC_NO
+
+/* AMJPAD matrix layout
+ * ,-------------------.
+ * | 00 | 01 | 02 | 03 |
+ * |----|----|----|----|
+ * | 10 | 11 | 12 | 13 |
+ * |----|----|----|----|
+ * | 20 | 21 | 22 | |
+ * |----|----|----| 23 |
+ * | 30 | 31 | 32 | |
+ * |----|----|----|----|
+ * | 40 | 41 | 42 | |
+ * |----|----|----| 43 |
+ * | 50 | 52 | |
+ * `-------------------'
+ */
+// The first section contains all of the arguments
+// The second converts the arguments into a two-dimensional array
+#define LAYOUT_numpad_6x4( \
+ k00, k01, k02, k03, \
+ k10, k11, k12, k13, \
+ k20, k21, k22, \
+ k30, k31, k32, k23, \
+ k40, k41, k42, \
+ k50, k52, k43 \
+) { \
+ { k00, k01, k02, k03 }, \
+ { k10, k11, k12, k13 }, \
+ { k20, k21, k22, k23 }, \
+ { k30, k31, k32, XXX }, \
+ { k40, k41, k42, k43 }, \
+ { k50, XXX, k52, XXX } \
+}
+
+#define LAYOUT_ortho_6x4( \
+ k00, k01, k02, k03, \
+ k10, k11, k12, k13, \
+ k20, k21, k22, k23, \
+ k30, k31, k32, k33, \
+ k40, k41, k42, k43, \
+ k50, k51, k52, k53 \
+) { \
+ { k00, k01, k02, k03 }, \
+ { k10, k11, k12, k13 }, \
+ { k20, k21, k22, k23 }, \
+ { k30, k31, k32, k33 }, \
+ { k40, k41, k42, k43 }, \
+ { k50, k51, k52, k53 } \
+}
+
+void matrix_init_user(void);
+void matrix_scan_user(void);
diff --git a/keyboards/amjkeyboard/amjpad/config.h b/keyboards/amjkeyboard/amjpad/config.h
new file mode 100644
index 0000000000..fe621b7bf3
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/config.h
@@ -0,0 +1,86 @@
+/*
+Copyright 2012 Jun Wako <wakojun@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#pragma once
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0x00D8 //A+M+J
+#define PRODUCT_ID 0x6060
+#define DEVICE_VER 0x0003
+#define MANUFACTURER AMJ
+#define PRODUCT PAD
+
+/* key matrix size */
+#define MATRIX_ROWS 6
+#define MATRIX_COLS 4
+
+// ROWS: Top to bottom, COLS: Left to right
+
+#define MATRIX_ROW_PINS { F7, F6, F5, F4, D5, D0 }
+#define MATRIX_COL_PINS { F1, F0, E6, C7 }
+#define UNUSED_PINS
+
+#define BACKLIGHT_PIN B6
+
+/* COL2ROW or ROW2COL */
+#define DIODE_DIRECTION COL2ROW
+
+/* define if matrix has ghost */
+//#define MATRIX_HAS_GHOST
+
+/* Set 0 if debouncing isn't needed */
+#define DEBOUNCE 5
+
+/* 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
+
+#define LED_NUM_LOCK_PIN D6
+#define LED_PIN_ON_STATE 0
+
+/* Backlight configuration
+ */
+#define BACKLIGHT_LEVELS 4
+
+/* Underlight configuration
+ */
+
+#define RGB_DI_PIN E2
+#define RGBLIGHT_ANIMATIONS
+#define RGBLED_NUM 8 // Number of LEDs
+#define RGBLIGHT_HUE_STEP 10
+#define RGBLIGHT_SAT_STEP 17
+#define RGBLIGHT_VAL_STEP 17
+
+/*
+ * Feature disable options
+ * These options are also useful to firmware size reduction.
+ */
+
+/* disable debug print */
+//#define NO_DEBUG
+
+/* disable print */
+//#define NO_PRINT
+
+/* disable action features */
+//#define NO_ACTION_LAYER
+//#define NO_ACTION_TAPPING
+//#define NO_ACTION_ONESHOT
diff --git a/keyboards/amjkeyboard/amjpad/info.json b/keyboards/amjkeyboard/amjpad/info.json
new file mode 100644
index 0000000000..76147716d2
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/info.json
@@ -0,0 +1,13 @@
+{
+ "keyboard_name": "AMJ Pad",
+ "url": "",
+ "maintainer": "qmk",
+ "layouts": {
+ "LAYOUT_numpad_6x4": {
+ "layout": [{"label":"k00", "x":0, "y":0}, {"label":"k01", "x":1, "y":0}, {"label":"k02", "x":2, "y":0}, {"label":"k03", "x":3, "y":0}, {"label":"k10", "x":0, "y":1}, {"label":"k11", "x":1, "y":1}, {"label":"k12", "x":2, "y":1}, {"label":"k13", "x":3, "y":1}, {"label":"k20", "x":0, "y":2}, {"label":"k21", "x":1, "y":2}, {"label":"k22", "x":2, "y":2}, {"label":"k30", "x":0, "y":3}, {"label":"k31", "x":1, "y":3}, {"label":"k32", "x":2, "y":3}, {"label":"k23", "x":3, "y":2, "h":2}, {"label":"k40", "x":0, "y":4}, {"label":"k41", "x":1, "y":4}, {"label":"k42", "x":2, "y":4}, {"label":"k50", "x":0, "y":5, "w":2}, {"label":"k52", "x":2, "y":5}, {"label":"k43", "x":3, "y":4, "h":2}]
+ },
+ "LAYOUT_ortho_6x4": {
+ "layout": [{"label":"k00", "x":0, "y":0}, {"label":"k01", "x":1, "y":0}, {"label":"k02", "x":2, "y":0}, {"label":"k03", "x":3, "y":0}, {"label":"k10", "x":0, "y":1}, {"label":"k11", "x":1, "y":1}, {"label":"k12", "x":2, "y":1}, {"label":"k13", "x":3, "y":1}, {"label":"k20", "x":0, "y":2}, {"label":"k21", "x":1, "y":2}, {"label":"k22", "x":2, "y":2}, {"label":"k23", "x":3, "y":2}, {"label":"k30", "x":0, "y":3}, {"label":"k31", "x":1, "y":3}, {"label":"k32", "x":2, "y":3}, {"label":"k33", "x":3, "y":3}, {"label":"k40", "x":0, "y":4}, {"label":"k41", "x":1, "y":4}, {"label":"k42", "x":2, "y":4}, {"label":"k43", "x":3, "y":4}, {"label":"k50", "x":0, "y":5}, {"label":"k51", "x":1, "y":5}, {"label":"k52", "x":2, "y":5}, {"label":"k53", "x":3, "y":5}]
+ }
+ }
+}
diff --git a/keyboards/amjkeyboard/amjpad/keymaps/default/keymap.c b/keyboards/amjkeyboard/amjpad/keymaps/default/keymap.c
new file mode 100644
index 0000000000..c6d5f06b18
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/keymaps/default/keymap.c
@@ -0,0 +1,59 @@
+#include QMK_KEYBOARD_H
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _BL 0
+#define _FL 1
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ /* Keymap _BL: (Base Layer) Default Layer
+ * ,-------------------.
+ * |Esc |TAB |BS | = |
+ * |----|----|----|----|
+ * | NL | / | * | - |
+ * |----|----|----|----|
+ * | 7 | 8 | 9 | |
+ * |----|----|----| + |
+ * | 4 | 5 | 6 | |
+ * |----|----|----|----|
+ * | 1 | 2 | 3 | |
+ * |----|----|----| En |
+ * | 0 |./FN| |
+ * `-------------------'
+ */
+
+ [_BL] = LAYOUT_numpad_6x4(
+ KC_ESC, KC_TAB, KC_BSPC, KC_PEQL,
+ KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
+ KC_P7, KC_P8, KC_P9,
+ KC_P4, KC_P5, KC_P6, KC_PPLS,
+ KC_P1, KC_P2, KC_P3,
+ KC_P0, LT(_FL,KC_PDOT), KC_PENT
+ ),
+
+ /* Keymap _FL: Function Layer
+ * ,-------------------.
+ * |Esc |TAB |BS | = |
+ * |----|----|----|----|
+ * | NL | / | * | - |
+ * |----|----|----|----|
+ * | 7 | 8 | 9 | |
+ * |----|----|----|RST |
+ * | 4 | 5 | 6 | |
+ * |----|----|----|----|
+ * | 1 | 2 | 3 | |
+ * |----|----|----| En |
+ * | 0 |./FN| |
+ * `-------------------'
+ */
+ [_FL] = LAYOUT_numpad_6x4(
+ KC_ESC, KC_TAB, KC_BSPC, KC_PEQL,
+ KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
+ KC_P7, KC_P8, KC_P9,
+ KC_P4, KC_P5, KC_P6, QK_BOOT,
+ KC_P1, KC_P2, KC_P3,
+ KC_P0, LT(_FL,KC_PDOT), KC_PENT
+ ),
+};
diff --git a/keyboards/amjkeyboard/amjpad/keymaps/max/keymap.c b/keyboards/amjkeyboard/amjpad/keymaps/max/keymap.c
new file mode 100644
index 0000000000..7bfaed5999
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/keymaps/max/keymap.c
@@ -0,0 +1,63 @@
+#include QMK_KEYBOARD_H
+
+#ifdef RGBLIGHT_ENABLE
+#include "rgblight.h"
+#endif
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _BL 0
+#define _FL 1
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ /* Keymap _BL: (Base Layer) Default Layer
+ * ,-------------------.
+ * |Esc |Setp| - | = |
+ * |----|----|----|----|
+ * | F1 | F2 | F3 | F4 |
+ * |----|----|----|----|
+ * | 7 | 8 | 9 | - |
+ * |----|----|----|----|
+ * | 4 | 5 | 6 | LF |
+ * |----|----|----|----|
+ * | 1 | 2 | 3 | \ |
+ * |----|----|----|----|
+ * |Left|Down| Up |Rght|
+ * `-------------------'
+ */
+
+ [_BL] = LAYOUT_ortho_6x4(
+ KC_ESC, KC_TAB, KC_MINS,KC_EQL, \
+ KC_F1, KC_F2, KC_F3, KC_F4, \
+ KC_P7, KC_P8, KC_P9, KC_PMNS, \
+ KC_P4, KC_P5, KC_P6, KC_PENT, \
+ KC_P1, KC_P2, KC_P3, KC_BSLS, \
+ KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT
+ ),
+
+ /* Keymap _FL: Function Layer
+ * ,-------------------.
+ * |Esc |TAB |BS | = |
+ * |----|----|----|----|
+ * | NL | / | * | - |
+ * |----|----|----|----|
+ * | 7 | 8 | 9 | |
+ * |----|----|----|RST |
+ * | 4 | 5 | 6 | |
+ * |----|----|----|----|
+ * | 1 | 2 | 3 | |
+ * |----|----|----| En |
+ * | 0 |./FN| |
+ * `-------------------'
+ */
+ [_FL] = LAYOUT_ortho_6x4(
+ KC_ESC, KC_TAB, KC_BSPC, KC_PEQL, \
+ KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
+ KC_P7, KC_P8, KC_P9, RESET, \
+ KC_P4, KC_P5, KC_P6, KC_PENT, \
+ KC_P1, KC_P2, KC_P3, KC_PENT, \
+ KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT
+ ),
+};
diff --git a/keyboards/amjkeyboard/amjpad/keymaps/ortho_left/keymap.c b/keyboards/amjkeyboard/amjpad/keymaps/ortho_left/keymap.c
new file mode 100644
index 0000000000..815ac2a681
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/keymaps/ortho_left/keymap.c
@@ -0,0 +1,63 @@
+#include QMK_KEYBOARD_H
+
+#ifdef RGBLIGHT_ENABLE
+#include "rgblight.h"
+#endif
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _BL 0
+#define _FL 1
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ /* Keymap _BL: (Base Layer) Default Layer
+ * ,-------------------.
+ * | T | G | B |Spac|
+ * |----|----|----|----|
+ * | R | F | V | Fn |
+ * |----|----|----|----|
+ * | E | D | C | OS |
+ * |----|----|----|----|
+ * | W | S | X | Alt|
+ * |----|----|----|----|
+ * | Q | A | Z | Ctl|
+ * |----|----|----|----|
+ * | Esc| Tab|Shft| Fn2|
+ * `-------------------'
+ */
+
+ [_BL] = LAYOUT_ortho_6x4(
+ KC_T, KC_G, KC_B, KC_SPACE,\
+ KC_R, KC_F, KC_V, MO(1), \
+ KC_E, KC_D, KC_C, KC_LGUI, \
+ KC_W, KC_S, KC_X, KC_LALT, \
+ KC_Q, KC_A, KC_Z, KC_LCTL, \
+ KC_TAB, KC_ESC, KC_LSHIFT, MO(1)
+ ),
+
+ /* Keymap _FL: Function Layer
+ * ,-------------------.
+ * | 5 | F5 | F11|Spac|
+ * |----|----|----|----|
+ * | 4 | F4 | F10| |
+ * |----|----|----|----|
+ * | 3 | F3 | F9 | OS |
+ * |----|----|----|----|
+ * | 2 | F2 | F8 | Alt|
+ * |----|----|----|----|
+ * | 1 | F1 | F7 | Ctl|
+ * |----|----|----|----|
+ * | ` | Del|Shft| |
+ * `-------------------'
+ */
+ [_FL] = LAYOUT_ortho_6x4(
+ KC_5, KC_F5, KC_F11, _______, \
+ KC_4, KC_F4, KC_F10, _______, \
+ KC_3, KC_F3, KC_F9, _______, \
+ KC_2, KC_F2, KC_F8, _______, \
+ KC_1, KC_F1, KC_F7, _______, \
+ KC_GRV,KC_DEL, _______, _______
+ ),
+};
diff --git a/keyboards/amjkeyboard/amjpad/keymaps/ortho_right/keymap.c b/keyboards/amjkeyboard/amjpad/keymaps/ortho_right/keymap.c
new file mode 100644
index 0000000000..cbb81a2eab
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/keymaps/ortho_right/keymap.c
@@ -0,0 +1,62 @@
+#include QMK_KEYBOARD_H
+
+#ifdef RGBLIGHT_ENABLE
+#include "rgblight.h"
+#endif
+
+// Each layer gets a name for readability, which is then used in the keymap matrix below.
+// The underscores don't mean anything - you can have a layer called STUFF or any other name.
+// Layer names don't all need to be of the same length, obviously, and you can also skip them
+// entirely and just use numbers.
+#define _BL 0
+#define _FL 1
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ /* Keymap _BL: (Base Layer) Default Layer
+ * ,-------------------.
+ * |Spac| N | H | Y |
+ * |----|----|----|----|
+ * | Fn | M | J | U |
+ * |----|----|----|----|
+ * |Left| , | K | I |
+ * |----|----|----|----|
+ * |Down| . | L | O |
+ * |----|----|----|----|
+ * | Up | / | ; | P |
+ * |----|----|----|----|
+ * |Rght| Ret| " |Bspc|
+ * `-------------------'
+ */
+ [_BL] = LAYOUT_ortho_6x4(
+ KC_SPACE, KC_N, KC_H, KC_Y, \
+ MO(1), KC_M, KC_J, KC_U, \
+ KC_LEFT, KC_COMM, KC_K, KC_I, \
+ KC_DOWN, KC_DOT, KC_L, KC_O, \
+ KC_UP, KC_SLASH, KC_SCLN, KC_P, \
+ KC_RIGHT, KC_ENT, KC_QUOT, KC_BSPC
+ ),
+
+ /* Keymap _FL: Function Layer
+ * ,-------------------.
+ * |Esc | F12| F6 | 6 |
+ * |----|----|----|----|
+ * | NL | M | - | 7 |
+ * |----|----|----|----|
+ * |Left| , | = | 8 |
+ * |----|----|----|----|
+ * |Down| . | [ | 9 |
+ * |----|----|----|----|
+ * | Up | / | ] | 0 |
+ * |----|----|----|----|
+ * |Rght| Ret| \ | Del|
+ * `-------------------'
+ */
+ [_FL] = LAYOUT_ortho_6x4(
+ _______, KC_F12, KC_F6, KC_6, \
+ _______, _______, KC_MINS, KC_7, \
+ _______, _______, KC_EQL, KC_8, \
+ _______, _______, KC_LBRC, KC_9, \
+ _______, _______, KC_RBRC, KC_0, \
+ _______, _______, KC_BSLS, KC_DEL
+ ),
+};
diff --git a/keyboards/amjkeyboard/amjpad/readme.md b/keyboards/amjkeyboard/amjpad/readme.md
new file mode 100644
index 0000000000..98af32edef
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/readme.md
@@ -0,0 +1,14 @@
+AMJ Pad
+===
+
+A DIY Keypad Kit
+
+Keyboard Maintainer: QMK Community
+Hardware Supported: AMJ Pad
+Hardware Availability: https://geekhack.org/index.php?topic=83546.0
+
+Make example for this keyboard (after setting up your build environment):
+
+ make amjkeyboard/amjpad:default
+
+See [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) then the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information.
diff --git a/keyboards/amjkeyboard/amjpad/rules.mk b/keyboards/amjkeyboard/amjpad/rules.mk
new file mode 100644
index 0000000000..c56fff39b3
--- /dev/null
+++ b/keyboards/amjkeyboard/amjpad/rules.mk
@@ -0,0 +1,20 @@
+# MCU name
+MCU = atmega32u4
+
+# Bootloader selection
+BOOTLOADER = atmel-dfu
+
+# Build Options
+# change yes to no to disable
+#
+BOOTMAGIC_ENABLE = no # Enable Bootmagic Lite
+MOUSEKEY_ENABLE = no # Mouse keys
+EXTRAKEY_ENABLE = yes # Audio control and System control
+CONSOLE_ENABLE = yes # Console for debug
+COMMAND_ENABLE = yes # Commands for debug and configuration
+NKRO_ENABLE = yes # Enable N-Key Rollover
+RGBLIGHT_ENABLE = no # Enable keyboard underlight functionality
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+AUDIO_ENABLE = no
+
+LAYOUTS = numpad_6x4 ortho_6x4