diff --git a/keyboards/handwired/k680t/config.h b/keyboards/handwired/k680t/config.h new file mode 100644 index 0000000000..7ff6d54e5e --- /dev/null +++ b/keyboards/handwired/k680t/config.h @@ -0,0 +1,37 @@ +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x414A // AJ = Ajazz +#define PRODUCT_ID 0x6874 // (k)68(0)t +#define DEVICE_VER 0x0069 // haha funny number +#define MANUFACTURER ajazz x steven-y-e +#define PRODUCT k680t by steven-y-e +#define DESCRIPTION k680t x teensy 2.0 handwired by steven-y-e + +/* key matrix size */ +#define MATRIX_ROWS 5 +#define MATRIX_COLS 16 + +#define MATRIX_ROW_PINS { B0, B1, B2, B3, B7 } +#define MATRIX_COL_PINS { F5, F6, F7, B6, B5, B4, D7, D6, D4, D5, C7, C6, D3, D2, D1, D0 } +#define UNUSED_PINS + +#define DIODE_DIRECTION COL2ROW + +#define SOFT_SERIAL_PIN D0 + +#define DEBOUNCE 5 + +#define LOCKING_SUPPORT_ENABLE + +#define LOCKING_RESYNC_ENABLE + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION + +/* Bootmagic Lite key configuration */ +//#define BOOTMAGIC_LITE_ROW 0 +//#define BOOTMAGIC_LITE_COLUMN 0 diff --git a/keyboards/handwired/k680t/info.json b/keyboards/handwired/k680t/info.json new file mode 100644 index 0000000000..4e53037eb4 --- /dev/null +++ b/keyboards/handwired/k680t/info.json @@ -0,0 +1,85 @@ +{ + "keyboard_name": "k680t by steven-y-e", + "url": "", + "maintainer": "steven-y-e", + "width": 17.25, + "height": 5, + "layouts": { + "LAYOUT": { + "layout": [ + {"label":"Esc", "x":0, "y":0}, + {"label":"!", "x":1, "y":0}, + {"label":"@", "x":2, "y":0}, + {"label":"#", "x":3, "y":0}, + {"label":"$", "x":4, "y":0}, + {"label":"%", "x":5, "y":0}, + {"label":"^", "x":6, "y":0}, + {"label":"&", "x":7, "y":0}, + {"label":"*", "x":8, "y":0}, + {"label":"(", "x":9, "y":0}, + {"label":")", "x":10, "y":0}, + {"label":"_", "x":11, "y":0}, + {"label":"+", "x":12, "y":0}, + {"label":"Backspace", "x":13, "y":0, "w":2}, + {"label":"~", "x":15.25, "y":0}, + {"label":"Page Up", "x":16.25, "y":0}, + + {"label":"Tab", "x":0, "y":1, "w":1.5}, + {"label":"Q", "x":1.5, "y":1}, + {"label":"W", "x":2.5, "y":1}, + {"label":"E", "x":3.5, "y":1}, + {"label":"R", "x":4.5, "y":1}, + {"label":"T", "x":5.5, "y":1}, + {"label":"Y", "x":6.5, "y":1}, + {"label":"U", "x":7.5, "y":1}, + {"label":"I", "x":8.5, "y":1}, + {"label":"O", "x":9.5, "y":1}, + {"label":"P", "x":10.5, "y":1}, + {"label":"{", "x":11.5, "y":1}, + {"label":"}", "x":12.5, "y":1}, + {"label":"|", "x":13.5, "y":1, "w":1.5}, + {"label":"Delete", "x":15.25, "y":1}, + {"label":"Page Down", "x":16.25, "y":1}, + + {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, + {"label":"A", "x":1.75, "y":2}, + {"label":"S", "x":2.75, "y":2}, + {"label":"D", "x":3.75, "y":2}, + {"label":"F", "x":4.75, "y":2}, + {"label":"G", "x":5.75, "y":2}, + {"label":"H", "x":6.75, "y":2}, + {"label":"J", "x":7.75, "y":2}, + {"label":"K", "x":8.75, "y":2}, + {"label":"L", "x":9.75, "y":2}, + {"label":":", "x":10.75, "y":2}, + {"label":"\"", "x":11.75, "y":2}, + {"label":"Enter", "x":12.75, "y":2, "w":2.25}, + + {"label":"Shift", "x":0, "y":3, "w":2.25}, + {"label":"Z", "x":2.25, "y":3}, + {"label":"X", "x":3.25, "y":3}, + {"label":"C", "x":4.25, "y":3}, + {"label":"V", "x":5.25, "y":3}, + {"label":"B", "x":6.25, "y":3}, + {"label":"N", "x":7.25, "y":3}, + {"label":"M", "x":8.25, "y":3}, + {"label":"<", "x":9.25, "y":3}, + {"label":">", "x":10.25, "y":3}, + {"label":"?", "x":11.25, "y":3}, + {"label":"Shift", "x":12.25, "y":3, "w":2.75}, + {"label":"Up", "x":15.25, "y":3}, + + {"label":"Ctrl", "x":0, "y":4, "w":1.25}, + {"label":"Win", "x":1.25, "y":4, "w":1.25}, + {"label":"Alt", "x":2.5, "y":4, "w":1.25}, + {"label":"Space", "x":3.75, "y":4, "w":6.25}, + {"label":"Alt", "x":10, "y":4}, + {"label":"Fn", "x":11, "y":4}, + {"label":"Ctrl", "x":12, "y":4}, + {"label":"Left", "x":14.25, "y":4}, + {"label":"Down", "x":15.25, "y":4}, + {"label":"Right", "x":16.25, "y":4} + ] + } + } +} diff --git a/keyboards/handwired/k680t/k680t.c b/keyboards/handwired/k680t/k680t.c new file mode 100644 index 0000000000..c20caeaa24 --- /dev/null +++ b/keyboards/handwired/k680t/k680t.c @@ -0,0 +1,17 @@ +/* Copyright 2021 steven-y-e + * + * 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 . + */ + +#include "k680t.h" diff --git a/keyboards/handwired/k680t/k680t.h b/keyboards/handwired/k680t/k680t.h new file mode 100644 index 0000000000..2b1ef23a9f --- /dev/null +++ b/keyboards/handwired/k680t/k680t.h @@ -0,0 +1,36 @@ +#pragma once + +#include "quantum.h" + +/* k680t ANSI wiring matrix layout + * ,--------------------------------------------------------------------. + * | 00 | 01| 02| 03| 04| 05| 06| 07| 08| 09| 0a| 0b| 0c| 0d || 0e| 0f| + * |--------------------------------------------------------------------| + * | 10 | 11| 12| 13| 14| 15| 16| 17| 18| 19| 1a| 1b| 1c| 1d || 1e| 1f| + * |--------------------------------------------------------------------| + * | 20 | 21| 22| 23| 24| 25| 26| 27| 28| 29| 2a| 2b| 2d | | + * |--------------------------------------------------------------------| + * | 30 | 32| 33| 34| 35| 36| 37| 38| 39| 3a| 3b| 3d || 3e| | + * |--------------------------------------------------------------------| + * | 40 | 42 | 43 | 46 | 4a | 4b | 4c | | 4d| 4e| 4f| + * `--------------------------------------------------------------------' + */ + +#define XXX KC_NO +// allows blanks in the key matrix array to have the same character length +// as valid keys + +#define LAYOUT( \ + k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d, k0e, k0f, \ + k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, k1e, k1f, \ + k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2d, \ + k30, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3d, k3e, \ + k40, k42, k43, k46, k4a, k4b, k4c, k4d, k4e, k4f \ +) \ +{ \ + {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d, k0e, k0f}, \ + {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, k1e, k1f}, \ + {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, XXX, k2d, XXX, XXX}, \ + {k30, XXX, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, XXX, k3d, k3e, XXX}, \ + {k40, XXX, k42, k43, XXX, XXX, k46, XXX, XXX, XXX, k4a, k4b, k4c, k4d, k4e, k4f} \ +} diff --git a/keyboards/handwired/k680t/keymaps/default/keymap.c b/keyboards/handwired/k680t/keymaps/default/keymap.c new file mode 100644 index 0000000000..3bb9343f29 --- /dev/null +++ b/keyboards/handwired/k680t/keymaps/default/keymap.c @@ -0,0 +1,65 @@ +/* Copyright 2021 steven-y-e + * + * 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 . + */ +#include QMK_KEYBOARD_H + +// Defines names for use in layer keycodes and the keymap +enum layer_names { + _BASE, + _FN +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base (default) layer + * ,----------------------------------------------------------------------. + * |Esc | 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backsp ||~ ` |PgUp| + * |----------------------------------------------------------------------| + * |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \ ||Del |PgDn| + * |----------------------------------------------------------------------| + * |CAPS | A| S| D| F| G| H| J| K| L| ;| '|Return | | + * |----------------------------------------------------------------------| + * |Shift | Z| X| C| V| B| N| M| ,| .| /| Shift || Up | | + * |----------------------------------------------------------------------| + * |Ctrl|Win |Alt | Space |Alt | FN |Ctrl| |Left|Down|Righ| + * `----------------------------------------------------------------------' + */ + [_BASE] = LAYOUT( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_GRV, KC_PGUP, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_PGDN, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(_FN), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + /* FN (function) layer + * ,----------------------------------------------------------------------. + * | |F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12| || | | + * |----------------------------------------------------------------------| + * | | | | | | | | | | | | | | || | | + * |----------------------------------------------------------------------| + * | | | | | | | | | | | | | | | + * |----------------------------------------------------------------------| + * | | | | | | | | | | | | || | | + * |----------------------------------------------------------------------| + * | | | | | | | | | | | | + * `----------------------------------------------------------------------' + */ + [_FN] = LAYOUT( + _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ + ) +}; diff --git a/keyboards/handwired/k680t/keymaps/default/readme.md b/keyboards/handwired/k680t/keymaps/default/readme.md new file mode 100644 index 0000000000..d77a86afdd --- /dev/null +++ b/keyboards/handwired/k680t/keymaps/default/readme.md @@ -0,0 +1 @@ +# The default keymap for k680t diff --git a/keyboards/handwired/k680t/readme.md b/keyboards/handwired/k680t/readme.md new file mode 100644 index 0000000000..ee4183b165 --- /dev/null +++ b/keyboards/handwired/k680t/readme.md @@ -0,0 +1,54 @@ +# Ajazz k680t + +*a nice 65% layout repurposed with a customizable mcu* + +* Keyboard Maintainer: [steven-y-e](https://github.com/steven-y-e) +* Hardware Supported: Ajazz k680t handwired to a Teensy 2.0 +* Hardware Availability: Ajazz/Epomaker/Taobao, PJRC + + +## Wiring Guide + +``` +matrix layout +,--------------------------------------------------------------------. +| 00 | 01| 02| 03| 04| 05| 06| 07| 08| 09| 0a| 0b| 0c| 0d || 0e| 0f| +|--------------------------------------------------------------------| +| 10 | 11| 12| 13| 14| 15| 16| 17| 18| 19| 1a| 1b| 1c| 1d || 1e| 1f| +|--------------------------------------------------------------------| +| 20 | 21| 22| 23| 24| 25| 26| 27| 28| 29| 2a| 2b| 2d | | +|--------------------------------------------------------------------| +| 30 | 32| 33| 34| 35| 36| 37| 38| 39| 3a| 3b| 3d || 3e| | +|--------------------------------------------------------------------| +| 40 | 42 | 43 | 46 | 4a | 4b | 4c | | 4d| 4e| 4f| +'--------------------------------------------------------------------' + +matrix row pins: +0 - B0 +1 - B1 +2 - B2 +3 - B3 +4 - B7 + +matrix column pins: +0 - F5 +1 - F6 +2 - F7 +3 - B6 +4 - B5 +5 - B4 +6 - D7 +7 - D6 +8 - D4 +9 - D5 +a - C7 +b - C6 +c - D3 +d - D2 +e - D1 +f - D0 +``` + +Note that the column and row pins can be reconfigured as needed in +``./config.h``, and even the matrix can be redefined in ``./k680t.h`` +(but at that point, why are you even using this configuration?) diff --git a/keyboards/handwired/k680t/rules.mk b/keyboards/handwired/k680t/rules.mk new file mode 100644 index 0000000000..d7ccfec97c --- /dev/null +++ b/keyboards/handwired/k680t/rules.mk @@ -0,0 +1,20 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = halfkay #teensy bootloader + +# Build Options +BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration +MOUSEKEY_ENABLE = yes # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE +SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend +# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work +NKRO_ENABLE = yes # USB Nkey Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow +BLUETOOTH_ENABLE = no # Enable Bluetooth +AUDIO_ENABLE = no # Audio output