mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-09-10 17:15:43 +00:00
Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
852d94f4e6 | ||
|
|
1c87b97dd6 | ||
|
|
d9ef323f8a | ||
|
|
57b21c037c | ||
|
|
fd3c1aa909 | ||
|
|
3d50a2867b | ||
|
|
0836e47e33 |
@@ -16,6 +16,7 @@ include common.mk
|
||||
KEYBOARD_FILESAFE := $(subst /,_,$(KEYBOARD))
|
||||
TARGET ?= $(KEYBOARD_FILESAFE)_$(KEYMAP)
|
||||
KEYBOARD_OUTPUT := $(BUILD_DIR)/obj_$(KEYBOARD_FILESAFE)
|
||||
STM32_PATH := quantum/stm32
|
||||
|
||||
# Force expansion
|
||||
TARGET := $(TARGET)
|
||||
@@ -68,6 +69,7 @@ ifneq ("$(wildcard $(KEYBOARD_PATH_1)/)","")
|
||||
KEYBOARD_PATHS += $(KEYBOARD_PATH_1)
|
||||
endif
|
||||
|
||||
|
||||
# Pull in rules.mk files from all our subfolders
|
||||
ifneq ("$(wildcard $(KEYBOARD_PATH_5)/rules.mk)","")
|
||||
include $(KEYBOARD_PATH_5)/rules.mk
|
||||
@@ -85,6 +87,19 @@ ifneq ("$(wildcard $(KEYBOARD_PATH_1)/rules.mk)","")
|
||||
include $(KEYBOARD_PATH_1)/rules.mk
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(PROTON)), yes)
|
||||
OPT_DEFS += -DPROTON_CONVERSION
|
||||
include $(STM32_PATH)/proton_c.mk
|
||||
endif
|
||||
|
||||
include quantum/mcu_selection.mk
|
||||
|
||||
ifdef MCU_FAMILY
|
||||
OPT_DEFS += -DQMK_STM32
|
||||
KEYBOARD_PATHS += $(STM32_PATH)
|
||||
endif
|
||||
|
||||
|
||||
# Find all the C source files to be compiled in subfolders.
|
||||
KEYBOARD_SRC :=
|
||||
|
||||
|
||||
@@ -11,8 +11,8 @@ Keycodes are actually defined in [common/keycode.h](https://github.com/qmk/qmk_f
|
||||
|
||||
There are 3 standard keyboard layouts in use around the world- ANSI, ISO, and JIS. North America primarily uses ANSI, Europe and Africa primarily use ISO, and Japan uses JIS. Regions not mentioned typically use either ANSI or ISO. The keycodes corresponding to these layouts are shown here:
|
||||
|
||||
<!-- Source for this image: http://www.keyboard-layout-editor.com/#/gists/bf431647d1001cff5eff20ae55621e9a -->
|
||||

|
||||
<!-- Source for this image: http://www.keyboard-layout-editor.com/#/gists/070a530eedaed36a2d77f3f6fd455677 -->
|
||||

|
||||
|
||||
## Some Of My Keys Are Swapped Or Not Working
|
||||
|
||||
|
||||
@@ -206,19 +206,18 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|
||||
## [Quantum Keycodes](quantum_keycodes.md#qmk-keycodes)
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|---------------|-----------|---------------------------------------------------------------------|
|
||||
|`RESET` | |Put the keyboard into DFU mode for flashing |
|
||||
|`DEBUG` | |Toggle debug mode |
|
||||
|`EEPROM_RESET` |`EEP_RST` |Resets EEPROM state by reinitializing it |
|
||||
|`KC_GESC` |`GRAVE_ESC`|Escape when tapped, <code>`</code> when pressed with Shift or GUI|
|
||||
|`KC_LSPO` | |Left Shift when held, `(` when tapped |
|
||||
|`KC_RSPC` | |Right Shift when held, `)` when tapped |
|
||||
|`KC_LEAD` | |The [Leader key](feature_leader_key.md) |
|
||||
|`KC_LOCK` | |The [Lock key](feature_key_lock.md) |
|
||||
|`FUNC(n)` |`F(n)` |Call `fn_action(n)` (deprecated) |
|
||||
|`M(n)` | |Call macro `n` |
|
||||
|`MACROTAP(n)` | |Macro-tap `n` idk FIXME |
|
||||
|Key |Aliases |Description |
|
||||
|-------------|-----------|---------------------------------------------------------------------|
|
||||
|`RESET` | |Put the keyboard into DFU mode for flashing |
|
||||
|`DEBUG` | |Toggle debug mode |
|
||||
|`KC_GESC` |`GRAVE_ESC`|Escape when tapped, <code>`</code> when pressed with Shift or GUI|
|
||||
|`KC_LSPO` | |Left Shift when held, `(` when tapped |
|
||||
|`KC_RSPC` | |Right Shift when held, `)` when tapped |
|
||||
|`KC_LEAD` | |The [Leader key](feature_leader_key.md) |
|
||||
|`KC_LOCK` | |The [Lock key](feature_key_lock.md) |
|
||||
|`FUNC(n)` |`F(n)` |Call `fn_action(n)` (deprecated) |
|
||||
|`M(n)` | |Call macro `n` |
|
||||
|`MACROTAP(n)`| |Macro-tap `n` idk FIXME |
|
||||
|
||||
## [Audio Keys](feature_audio.md)
|
||||
|
||||
|
||||
@@ -28,6 +28,6 @@ Sometimes it's useful to print debug messages from within your [custom code](cus
|
||||
After that you can use a few different print functions:
|
||||
|
||||
* `print("string")`: Print a simple string.
|
||||
* `uprintf("%s string", var)`: Print a formatted string
|
||||
* `sprintf("%s string", var)`: Print a formatted string
|
||||
* `dprint("string")` Print a simple string, but only when debug mode is enabled
|
||||
* `dprintf("%s string", var)`: Print a formatted string, but only when debug mode is enabled
|
||||
|
||||
@@ -18,14 +18,14 @@
|
||||
#define _BOARD_H_
|
||||
|
||||
/*
|
||||
* Setup for Clueboard 60% Keyboard
|
||||
* Setup for Generic STM32_F303 Board
|
||||
*/
|
||||
|
||||
/*
|
||||
* Board identifier.
|
||||
*/
|
||||
#define BOARD_GENERIC_STM32_F303XC
|
||||
#define BOARD_NAME "Planck PCB"
|
||||
#define BOARD_NAME "STM32_F303"
|
||||
|
||||
/*
|
||||
* Board oscillators-related settings.
|
||||
@@ -56,16 +56,3 @@
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2a, K2b, K2c, K2d, K2e, K2f }, \
|
||||
{ K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3a, K3b, K3c, K3d, K3e, K3f } \
|
||||
}
|
||||
|
||||
#define LAYOUT_kc_ortho_4x12( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0a, K0b, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1a, K1b, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2a, K2b, \
|
||||
K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3a, K3b \
|
||||
) \
|
||||
{ \
|
||||
{ KC_##K00, KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, KC_##K08, KC_##K09, KC_##K0a, KC_##K0b, ___, ___, ___, ___}, \
|
||||
{ KC_##K10, KC_##K11, KC_##K12, KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, KC_##K18, KC_##K19, KC_##K1a, KC_##K1b, ___, ___, ___, ___}, \
|
||||
{ KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_##K24, KC_##K25, KC_##K26, KC_##K27, KC_##K28, KC_##K29, KC_##K2a, KC_##K2b, ___, ___, ___, ___}, \
|
||||
{ KC_##K30, KC_##K31, KC_##K32, KC_##K33, KC_##K34, KC_##K35, KC_##K36, KC_##K37, KC_##K38, KC_##K39, KC_##K3a, KC_##K3b, ___, ___, ___, ___} \
|
||||
}
|
||||
|
||||
@@ -76,4 +76,5 @@ AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
|
||||
LAYOUTS = ortho_4x4 ortho_4x8 ortho_4x12 ortho_4x16
|
||||
#FIXME: Community keymap build are currently failing due to missing functionality
|
||||
#LAYOUTS = ortho_4x4 ortho_4x8 ortho_4x12 ortho_4x16
|
||||
|
||||
@@ -77,4 +77,5 @@ AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
|
||||
LAYOUTS = ortho_5x5 ortho_5x10 ortho_5x15
|
||||
#FIXME: Community keymap build are currently failing due to missing functionality
|
||||
#LAYOUTS = ortho_5x5 ortho_5x10 ortho_5x15
|
||||
|
||||
@@ -17,5 +17,3 @@
|
||||
#pragma once
|
||||
|
||||
// place overrides here
|
||||
|
||||
#define PERMISSIVE_HOLD
|
||||
|
||||
@@ -15,62 +15,19 @@
|
||||
*/
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
enum foobar_layers {
|
||||
QWERTY,
|
||||
FN1,
|
||||
FN2,
|
||||
FN3,
|
||||
FN4,
|
||||
FN5
|
||||
};
|
||||
|
||||
#define FN1_SPC LT(FN1, KC_SPC)
|
||||
#define FN2_BSC LT(FN2, KC_BSPC)
|
||||
#define FN3_C LT(FN3, KC_C)
|
||||
#define FN4_V LT(FN4, KC_V)
|
||||
#define FN5_B LT(FN5, KC_B)
|
||||
#define RALT_N RALT_T(KC_N)
|
||||
#define LALT_X LALT_T(KC_X)
|
||||
#define LCTL_Z LCTL_T(KC_Z)
|
||||
#define RCTL_M RCTL_T(KC_M)
|
||||
#define LSFT_ENT LSFT_T(KC_ENT)
|
||||
#define RGUI_ESC RGUI_T(KC_ESC)
|
||||
#define FN1_Q LT(1, KC_Q)
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[QWERTY] = LAYOUT_split(
|
||||
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P,
|
||||
KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, RGUI_ESC,
|
||||
LCTL_Z, LALT_X, FN3_C, FN4_V, FN2_BSC, FN1_SPC, FN5_B, RALT_N, RCTL_M, LSFT_ENT
|
||||
[0] = LAYOUT_split(
|
||||
FN1_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P,
|
||||
KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_ESC,
|
||||
KC_Z, KC_X, KC_C, KC_V, KC_BSPC, KC_SPC, KC_B, KC_N, KC_M, KC_ENT
|
||||
),
|
||||
|
||||
[FN1] = LAYOUT_split(
|
||||
KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0,
|
||||
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10,
|
||||
_______, _______, _______, _______, KC_DEL, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
[FN2] = LAYOUT_split(
|
||||
KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN,
|
||||
KC_F11, KC_F12, _______, _______, _______, _______, _______, _______, _______, KC_GRV,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
[FN3] = LAYOUT_split(
|
||||
_______, _______, _______, _______, _______, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS,
|
||||
KC_TAB, _______, _______, _______, _______, KC_COMM, KC_DOT, KC_SLSH, KC_SCLN, KC_QUOT,
|
||||
_______, _______, _______, _______, _______, _______, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
||||
),
|
||||
|
||||
[FN4] = LAYOUT_split(
|
||||
_______, _______, _______, _______, _______, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE,
|
||||
KC_TAB, _______, _______, _______, _______, KC_LABK, KC_RABK, KC_QUES, KC_COLN, KC_DQUO,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
[FN5] = LAYOUT_split(
|
||||
[1] = LAYOUT_split(
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, RESET, _______, _______, _______, _______
|
||||
_______, _______, _______, _______, _______, _______, RESET, _______, _______, _______
|
||||
),
|
||||
};
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
SRC += ws2812.c
|
||||
|
||||
# MCU name
|
||||
#MCU = at90usb1286
|
||||
MCU = atmega32u4
|
||||
@@ -52,7 +54,7 @@ OPT_DEFS += -DBOOTLOADER_SIZE=4096
|
||||
# change yes to no to disable
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = yes # Console for debug(+400)
|
||||
COMMAND_ENABLE = yes # Commands for debug and configuration
|
||||
|
||||
@@ -1,42 +0,0 @@
|
||||
/*
|
||||
Copyright 2018 listofoptions <listofoptions@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"
|
||||
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x6060
|
||||
#define DEVICE_VER 1
|
||||
#define MANUFACTURER QMK
|
||||
#define PRODUCT 5291 keyboard converter
|
||||
#define DESCRIPTION 5291 keyboard converter
|
||||
|
||||
#define MATRIX_ROWS 24
|
||||
#define MATRIX_COLS 4
|
||||
|
||||
#define MATRIX_ROW_PINS {B2, B3, B4, B5, B6}
|
||||
#define MATRIX_COL_PINS {B0, B1}
|
||||
#define MATRIX_DATA_PIN D0
|
||||
#define MATRIX_STROBE_PIN D1
|
||||
#define LED_PIN D6
|
||||
|
||||
|
||||
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
|
||||
#define DEBOUNCING_DELAY 0
|
||||
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
#include "ibm_5291.h"
|
||||
#include <avr/io.h>
|
||||
#include "quantum.h"
|
||||
@@ -1,69 +0,0 @@
|
||||
/*
|
||||
Copyright 2018 listofoptions <listofoptions@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 "quantum.h"
|
||||
|
||||
/*
|
||||
* ,-------. ,--------------------------------------------------------------------------.
|
||||
* | F1| F2| |Esc| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =| BS |NumLck |ScrLck |
|
||||
* |-------| |--------------------------------------------------------------------------|
|
||||
* | F3| F4| | Tab | Q| W| E| R| T| Y| U| I| O| P| [| ] | | 7| 8| 9| -|
|
||||
* |-------| |------------------------------------------------------|Ent|---------------|
|
||||
* | F5| F6| | Ctrl | A| S| D| F| G| H| J| K| L| ;| '| `| | 4| 5| 6| |
|
||||
* |-------| |----------------------------------------------------------------------| |
|
||||
* | F7| F8| |Shif| \| Z| X| C| V| B| N| M| ,| .| /|Shift|PrS| 1| 2| 3| +|
|
||||
* |-------| |----------------------------------------------------------------------| |
|
||||
* | F9|F10| | Alt | Space |CapsLck| 0 | . | |
|
||||
* `-------' `--------------------------------------------------------------------------'
|
||||
*/
|
||||
|
||||
#define LAYOUT_5291( \
|
||||
KEY_F1,KEY_F2, KEY_ESC, KEY_1, KEY_2,KEY_3,KEY_4,KEY_5,KEY_6,KEY_7,KEY_8,KEY_9, KEY_0, KEY_MIN, KEY_EQU, KEY_BACK, KEY_NLOCK, KEY_SLOCK, \
|
||||
KEY_F3,KEY_F4, KEY_TAB, KEY_Q, KEY_W,KEY_E,KEY_R,KEY_T,KEY_Y,KEY_U,KEY_I,KEY_O, KEY_P, KEY_LBRC,KEY_RBRC, KEY_PAD7,KEY_PAD8, KEY_PAD9,KEY_PMIN, \
|
||||
KEY_F5,KEY_F6, KEY_LCTR,KEY_A, KEY_S,KEY_D,KEY_F,KEY_G,KEY_H,KEY_J,KEY_K,KEY_L, KEY_SEMI,KEY_QUOT,KEY_TICK, KEY_ENTR,KEY_PAD4,KEY_PAD5, KEY_PAD6, \
|
||||
KEY_F7,KEY_F8, KEY_LSFS,KEY_BSLS,KEY_Z,KEY_X,KEY_C,KEY_V,KEY_B,KEY_N,KEY_M,KEY_COMM,KEY_DOT, KEY_SLS,KEY_RSFS, KEY_PAST,KEY_PAD1,KEY_PAD2, KEY_PAD3,KEY_PPLS, \
|
||||
KEY_F9,KEY_F10, KEY_LALT, KEY_SPACE, KEY_CLOCK, KEY_PAD0, KEY_PDOT \
|
||||
) \
|
||||
{ {KEY_Z, KEY_S, KEY_W, KEY_3 }\
|
||||
, {KEY_X, KEY_D, KEY_E, KEY_4 }\
|
||||
, {KEY_C, KEY_F, KEY_R, KEY_5 }\
|
||||
, {KEY_V, KEY_G, KEY_T, KEY_6 }\
|
||||
, {KEY_B, KEY_H, KEY_Y, KEY_7 }\
|
||||
, {KEY_N, KEY_J, KEY_U, KEY_8 }\
|
||||
, {KEY_PAD2, KEY_PAD5,KEY_PAD8,KEY_NLOCK }\
|
||||
, {KEY_M, KEY_K, KEY_I, KEY_9 }\
|
||||
, {KEY_COMM, KEY_L, KEY_O, KEY_0 }\
|
||||
, {KEY_DOT, KEY_SEMI,KEY_P, KEY_MIN }\
|
||||
, {KEY_SLS, KEY_QUOT,KEY_LBRC,KEY_EQU }\
|
||||
, {KEY_SPACE, KEY_RSFS,KEY_TICK,KEY_RBRC }\
|
||||
, {KEY_CLOCK, KEY_PAST,KEY_ENTR,KEY_BACK }\
|
||||
, {KEY_PAD0, KEY_PAD1,KEY_PAD4,KEY_PAD7 }\
|
||||
, {KEY_PPLS, KC_NO, KEY_PMIN,KEY_SLOCK }\
|
||||
, {KEY_PDOT, KEY_PAD3,KEY_PAD6,KEY_PAD9 }\
|
||||
, {KEY_BSLS, KEY_A, KEY_Q, KEY_2 }\
|
||||
, {KEY_LALT, KC_NO, KC_NO, KEY_1 }\
|
||||
, {KEY_F7, KEY_F5, KEY_F3, KEY_F1 }\
|
||||
, {KEY_F8, KEY_F6, KEY_F4, KEY_F2 }\
|
||||
, {KC_F10, KC_NO, KC_NO, KC_NO }\
|
||||
, {KC_F9, KC_NO, KC_NO, KC_NO }\
|
||||
, {KEY_LSFS, KEY_LCTR,KEY_TAB, KEY_ESC }\
|
||||
, {KC_NO, KC_NO, KC_NO, KC_NO }\
|
||||
}
|
||||
|
||||
#define LAYOUT LAYOUT_5291
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"keyboard_name": "IBM 5291",
|
||||
"keyboard_folder": "converter/5291",
|
||||
"url": "https://deskthority.net/wiki/IBM_Model_F#IBM_5291_Keyboard",
|
||||
"maintainer": "listofoptions",
|
||||
}
|
||||
@@ -1,233 +0,0 @@
|
||||
/*
|
||||
Copyright 2018 listofoptions <listofoptions@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/>.
|
||||
*/
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
/*
|
||||
enum xt_keycodes
|
||||
{ XT_PAST = SAFE_RANGE // XT pad asterisk / print screen
|
||||
, XT_SLCK // XT scroll lock / break
|
||||
, XT_F6 // F6 / app key
|
||||
, XT_F5 // F5 / gui
|
||||
, XT_F9 // F9 / F11
|
||||
, XT_F10 // F10 / F12
|
||||
} ;
|
||||
|
||||
static bool shift_pressed = false ,
|
||||
alt_pressed = false ,
|
||||
ctrl_pressed = false ,
|
||||
xt_pscr_pressed = false ,
|
||||
xt_brk_pressed = false ,
|
||||
xt_app_pressed = false ,
|
||||
xt_gui_pressed = false ,
|
||||
xt_lout_pressed = false ,
|
||||
xt_f11_pressed = false ,
|
||||
xt_f12_pressed = false ;
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case KC_LSFT:
|
||||
case KC_RSFT:
|
||||
if (record->event.pressed) {
|
||||
shift_pressed = true ;
|
||||
} else {
|
||||
shift_pressed = false ;
|
||||
}
|
||||
return true;
|
||||
break;
|
||||
|
||||
case KC_LALT:
|
||||
if (record->event.pressed) {
|
||||
alt_pressed = true ;
|
||||
} else {
|
||||
alt_pressed = false ;
|
||||
}
|
||||
return true;
|
||||
break;
|
||||
|
||||
case KC_LCTL:
|
||||
if (record->event.pressed) {
|
||||
ctrl_pressed = true ;
|
||||
} else {
|
||||
ctrl_pressed = false ;
|
||||
}
|
||||
return true;
|
||||
break;
|
||||
|
||||
case XT_PAST:
|
||||
if (record->event.pressed) {
|
||||
if (shift_pressed) {
|
||||
xt_pscr_pressed = true ;
|
||||
register_code(KC_PSCR);
|
||||
} else {
|
||||
register_code(KC_PAST);
|
||||
}
|
||||
} else {
|
||||
if (xt_pscr_pressed) {
|
||||
xt_pscr_pressed = false ;
|
||||
unregister_code(KC_PSCR);
|
||||
} else {
|
||||
unregister_code(KC_PAST);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
case XT_SLCK:
|
||||
if (record->event.pressed) {
|
||||
if (ctrl_pressed) {
|
||||
xt_brk_pressed = true ;
|
||||
register_code(KC_BRK);
|
||||
} else {
|
||||
register_code(KC_SLCK);
|
||||
}
|
||||
} else {
|
||||
if (xt_brk_pressed) {
|
||||
xt_brk_pressed = false ;
|
||||
unregister_code(KC_BRK);
|
||||
} else {
|
||||
unregister_code(KC_SLCK);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
case XT_F6:
|
||||
if (record->event.pressed) {
|
||||
if (shift_pressed) {
|
||||
xt_app_pressed = true ;
|
||||
register_code(KC_APP);
|
||||
} else {
|
||||
register_code(KC_F6);
|
||||
}
|
||||
} else {
|
||||
if (xt_app_pressed) {
|
||||
xt_app_pressed = false ;
|
||||
unregister_code(KC_APP);
|
||||
} else {
|
||||
unregister_code(KC_F6);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
case XT_F5:
|
||||
if (record->event.pressed) {
|
||||
if (shift_pressed) {
|
||||
xt_gui_pressed = true ;
|
||||
register_code(KC_LGUI);
|
||||
} else if (ctrl_pressed) {
|
||||
xt_lout_pressed = true ;
|
||||
register_code (KC_LGUI) ;
|
||||
register_code (KC_L) ;
|
||||
} else {
|
||||
register_code(KC_F5);
|
||||
}
|
||||
} else {
|
||||
if (xt_gui_pressed) {
|
||||
xt_gui_pressed = false ;
|
||||
unregister_code(KC_LGUI);
|
||||
} else if (xt_lout_pressed) {
|
||||
xt_lout_pressed = false ;
|
||||
unregister_code (KC_LGUI) ;
|
||||
unregister_code (KC_L) ;
|
||||
} else {
|
||||
unregister_code(KC_F5);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
case XT_F9:
|
||||
if (record->event.pressed) {
|
||||
if (shift_pressed) {
|
||||
xt_f11_pressed = true ;
|
||||
register_code(KC_F11);
|
||||
} else {
|
||||
register_code(KC_F9);
|
||||
}
|
||||
} else {
|
||||
if (xt_f11_pressed) {
|
||||
xt_f11_pressed = false ;
|
||||
unregister_code(KC_F11);
|
||||
} else {
|
||||
unregister_code(KC_F9);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
case XT_F10:
|
||||
if (record->event.pressed) {
|
||||
if (shift_pressed) {
|
||||
xt_f12_pressed = true ;
|
||||
register_code(KC_F12);
|
||||
} else {
|
||||
register_code(KC_F10);
|
||||
}
|
||||
} else {
|
||||
if (xt_f12_pressed) {
|
||||
xt_f12_pressed = false ;
|
||||
unregister_code(KC_F12);
|
||||
} else {
|
||||
unregister_code(KC_F10);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
|
||||
default:
|
||||
return true;
|
||||
break;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
*/
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
// default layout is the standard XT layout
|
||||
/*
|
||||
* ,-------. ,--------------------------------------------------------------------------.
|
||||
* | F1| F2| |Esc| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =| BS |NumLck |ScrLck |
|
||||
* |-------| |--------------------------------------------------------------------------|
|
||||
* | F3| F4| | Tab | Q| W| E| R| T| Y| U| I| O| P| [| ] | | 7| 8| 9| -|
|
||||
* |-------| |------------------------------------------------------|Ent|---------------|
|
||||
* | F5| F6| | Ctrl | A| S| D| F| G| H| J| K| L| ;| '| `| | 4| 5| 6| |
|
||||
* |-------| |----------------------------------------------------------------------| |
|
||||
* | F7| F8| |Shif| \| Z| X| C| V| B| N| M| ,| .| /|Shift| *| 1| 2| 3| +|
|
||||
* |-------| |----------------------------------------------------------------------| |
|
||||
* | F9|F10| | Alt | Space |CapsLck| 0 | . | |
|
||||
* `-------' `--------------------------------------------------------------------------'
|
||||
*/
|
||||
/*
|
||||
[0] = LAYOUT (
|
||||
KC_F1,KC_F2, 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_NLCK, XT_SLCK,
|
||||
KC_F3,KC_F4, 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_P7,KC_P8, KC_P9, KC_PMNS,
|
||||
XT_F5,XT_F6, KC_LCTL,KC_A, KC_S,KC_D,KC_F,KC_G,KC_H,KC_J,KC_K,KC_L, KC_SCLN,KC_QUOT,KC_GRV, KC_ENT, KC_P4,KC_P5, KC_P6,
|
||||
KC_F7,KC_F8, KC_LSFT,KC_BSLS,KC_Z,KC_X,KC_C,KC_V,KC_B,KC_N,KC_M,KC_COMM,KC_DOT, KC_SLSH,KC_RSFT,XT_PAST,KC_P1,KC_P2, KC_P3, KC_PPLS,
|
||||
XT_F9,XT_F10,KC_LALT, KC_SPACE, KC_CAPS, KC_P0, KC_PDOT
|
||||
)
|
||||
*/
|
||||
[0] = LAYOUT (
|
||||
KC_F1,KC_F2, 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_NLCK, KC_SLCK,
|
||||
KC_F3,KC_F4, 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_P7,KC_P8, KC_P9, KC_PMNS,
|
||||
KC_F5,KC_F6, KC_LCTL,KC_A, KC_S,KC_D,KC_F,KC_G,KC_H,KC_J,KC_K,KC_L, KC_SCLN,KC_QUOT,KC_GRV, KC_ENT, KC_P4,KC_P5, KC_P6,
|
||||
KC_F7,KC_F8, KC_LSFT,KC_BSLS,KC_Z,KC_X,KC_C,KC_V,KC_B,KC_N,KC_M,KC_COMM,KC_DOT, KC_SLSH,KC_RSFT,KC_PAST,KC_P1,KC_P2, KC_P3, KC_PPLS,
|
||||
KC_F9,KC_F10,KC_LALT, KC_SPACE, KC_CAPS, KC_P0, KC_PDOT
|
||||
)
|
||||
} ;
|
||||
|
||||
Binary file not shown.
@@ -1,284 +0,0 @@
|
||||
/*
|
||||
Copyright 2018 listofoptions <listofoptions@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/>.
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
#include <string.h>
|
||||
#if defined(__AVR__)
|
||||
#include <avr/io.h>
|
||||
#endif
|
||||
#include <util/delay.h>
|
||||
|
||||
#include "wait.h"
|
||||
#include "print.h"
|
||||
#include "debug.h"
|
||||
#include "util.h"
|
||||
#include "matrix.h"
|
||||
#include "timer.h"
|
||||
|
||||
#include "config.h"
|
||||
|
||||
|
||||
#ifndef DEBOUNCING_DELAY
|
||||
# define DEBOUNCING_DELAY 5
|
||||
#endif
|
||||
|
||||
#define print_matrix_header() print("\nr/c 01234567\n")
|
||||
#define print_matrix_row(row) print_bin_reverse8(matrix_get_row(row))
|
||||
#define matrix_bitpop(i) bitpop(matrix[i])
|
||||
#define ROW_SHIFTER ((uint8_t)1)
|
||||
#define check_bit(var,pos) ((var) & (1<<(pos)))
|
||||
|
||||
#define NUM_ROW_PINS 5
|
||||
#define NUM_COL_PINS 2
|
||||
|
||||
static const uint8_t row_pins [NUM_ROW_PINS] = MATRIX_ROW_PINS ;
|
||||
static const uint8_t col_pins [NUM_ROW_PINS] = MATRIX_COL_PINS ;
|
||||
|
||||
#if ( DEBOUNCING_DELAY > 0 )
|
||||
static uint16_t debouncing_time ;
|
||||
static bool debouncing = false ;
|
||||
#endif
|
||||
|
||||
static uint8_t matrix [MATRIX_ROWS] = {0};
|
||||
|
||||
#if ( DEBOUNCING_DELAY > 0 )
|
||||
static uint8_t matrix_debounce [MATRIX_ROWS] = {0};
|
||||
#endif
|
||||
|
||||
static
|
||||
inline
|
||||
void toggle_led(void) {
|
||||
uint8_t pin = LED_PIN ;
|
||||
_SFR_IO8((pin >> 4) + 2) ^= _BV(pin & 0xF);
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void init_led(void) {
|
||||
uint8_t pin = LED_PIN ;
|
||||
_SFR_IO8((pin >> 4) + 1) |= _BV(pin & 0xF); // OUT
|
||||
_SFR_IO8((pin >> 4) + 2) &= ~_BV(pin & 0xF); // LOW
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void init_data(void) {
|
||||
uint8_t pin = MATRIX_DATA_PIN ;
|
||||
_SFR_IO8((pin >> 4) + 1) &= ~_BV(pin & 0xF); // IN
|
||||
_SFR_IO8((pin >> 4) + 2) |= _BV(pin & 0xF); // LO
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void init_strobe(void) {
|
||||
uint8_t pin = MATRIX_STROBE_PIN ;
|
||||
_SFR_IO8((pin >> 4) + 1) |= _BV(pin & 0xF); // OUT
|
||||
_SFR_IO8((pin >> 4) + 2) |= _BV(pin & 0xF); // HI
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void init_rows(void) {
|
||||
for ( uint8_t i = 0 ; i < NUM_ROW_PINS; ++i ) {
|
||||
uint8_t pin = row_pins[i];
|
||||
_SFR_IO8((pin >> 4) + 1) |= _BV(pin & 0xF); // OUT
|
||||
_SFR_IO8((pin >> 4) + 2) &= ~_BV(pin & 0xF); // LOW
|
||||
}
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void init_cols(void) {
|
||||
for ( uint8_t i = 0 ; i < NUM_COL_PINS; ++i ) {
|
||||
uint8_t pin = col_pins[i];
|
||||
_SFR_IO8((pin >> 4) + 1) |= _BV(pin & 0xF); // OUT
|
||||
_SFR_IO8((pin >> 4) + 2) &= ~_BV(pin & 0xF); // LOW
|
||||
}
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void select_row(uint8_t current_row) {
|
||||
for ( uint8_t i = 0 ; i < NUM_ROW_PINS; ++i ) {
|
||||
uint8_t pin = row_pins[i] ;
|
||||
if ( check_bit( current_row, i ) ) {
|
||||
_SFR_IO8((pin >> 4) + 2) |= _BV(pin & 0xF); // HI
|
||||
} else {
|
||||
_SFR_IO8((pin >> 4) + 2) &= ~_BV(pin & 0xF); // LOW
|
||||
}
|
||||
}
|
||||
wait_us(30) ;
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
void select_col(uint8_t current_col) {
|
||||
for ( uint8_t i = 0 ; i < NUM_COL_PINS; ++i ) {
|
||||
uint8_t pin = col_pins[i] ;
|
||||
if ( check_bit( current_col, i ) ) {
|
||||
_SFR_IO8((pin >> 4) + 2) |= _BV(pin & 0xF); // HI
|
||||
} else {
|
||||
_SFR_IO8((pin >> 4) + 2) &= ~_BV(pin & 0xF); // LOW
|
||||
}
|
||||
}
|
||||
wait_us(30) ;
|
||||
}
|
||||
|
||||
static
|
||||
inline
|
||||
uint8_t matrix_strobe(uint8_t col_index) {
|
||||
uint8_t strobe_pin = MATRIX_STROBE_PIN ;
|
||||
uint8_t data_pin = MATRIX_DATA_PIN ;
|
||||
|
||||
// set strobe pin low
|
||||
_SFR_IO8((strobe_pin >> 4) + 2) &= ~_BV(strobe_pin & 0xF);
|
||||
|
||||
wait_us(30) ;
|
||||
|
||||
// read data
|
||||
uint8_t data = (_SFR_IO8(data_pin >> 4) & _BV(data_pin & 0xF)) ;
|
||||
|
||||
// set strobe pin hi
|
||||
_SFR_IO8((strobe_pin >> 4) + 2) |= _BV(strobe_pin & 0xF);
|
||||
|
||||
uint8_t out = data ? (1 << col_index) : 0 ;
|
||||
return out ;
|
||||
}
|
||||
|
||||
static
|
||||
bool matrix_read(uint8_t current_matrix[], uint8_t current_row) {
|
||||
// Store last value of row prior to reading
|
||||
uint8_t last_row_value = current_matrix[current_row];
|
||||
|
||||
// Clear data in matrix row
|
||||
current_matrix[current_row] = 0;
|
||||
|
||||
select_row(current_row);
|
||||
|
||||
// For each col...
|
||||
for(uint8_t col_index = 0; col_index < MATRIX_COLS; ++col_index) {
|
||||
|
||||
select_col(col_index) ;
|
||||
|
||||
// strobe the matrix
|
||||
// Populate the matrix row with the state of the data pin
|
||||
current_matrix[current_row] |= matrix_strobe(col_index) ;
|
||||
}
|
||||
|
||||
bool test = last_row_value != current_matrix[current_row] ;
|
||||
return test ;
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_init_quantum(void) {
|
||||
matrix_init_kb();
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_scan_quantum(void) {
|
||||
matrix_scan_kb();
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_init_kb(void) {
|
||||
matrix_init_user();
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_scan_kb(void) {
|
||||
matrix_scan_user();
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_init_user(void) {
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_scan_user(void) {
|
||||
}
|
||||
|
||||
inline
|
||||
uint8_t matrix_rows(void) {
|
||||
return MATRIX_ROWS;
|
||||
}
|
||||
|
||||
inline
|
||||
uint8_t matrix_cols(void) {
|
||||
return MATRIX_COLS;
|
||||
}
|
||||
|
||||
inline
|
||||
uint8_t matrix_get_row(uint8_t row) {
|
||||
return matrix[row];
|
||||
}
|
||||
|
||||
void matrix_init(void) {
|
||||
init_led() ;
|
||||
init_rows() ;
|
||||
init_cols() ;
|
||||
init_data() ;
|
||||
init_strobe() ;
|
||||
|
||||
// initialize matrix state: all keys off
|
||||
for (uint8_t i = 0; i < MATRIX_ROWS; i++) {
|
||||
matrix[i] = 0;
|
||||
# if (DEBOUNCING_DELAY > 0)
|
||||
matrix_debounce [i] = 0;
|
||||
# endif
|
||||
}
|
||||
|
||||
matrix_init_quantum() ;
|
||||
}
|
||||
|
||||
uint8_t matrix_scan(void) {
|
||||
for ( uint8_t current_row = 0; current_row < MATRIX_ROWS; ++current_row ) {
|
||||
# if (DEBOUNCING_DELAY > 0)
|
||||
bool matrix_changed = matrix_read(matrix_debounce, current_row);
|
||||
|
||||
if (matrix_changed) {
|
||||
debouncing = true ;
|
||||
debouncing_time = timer_read();
|
||||
}
|
||||
|
||||
# else
|
||||
matrix_read(matrix, current_row);
|
||||
# endif
|
||||
}
|
||||
|
||||
# if (DEBOUNCING_DELAY > 0)
|
||||
if (debouncing && (timer_elapsed(debouncing_time) > DEBOUNCING_DELAY)) {
|
||||
for (uint8_t i = 0; i < MATRIX_ROWS; i++) {
|
||||
matrix[i] = matrix_debounce[i];
|
||||
}
|
||||
debouncing = false;
|
||||
}
|
||||
# endif
|
||||
|
||||
matrix_scan_quantum();
|
||||
return 1;
|
||||
}
|
||||
|
||||
void matrix_print(void) {
|
||||
print_matrix_header();
|
||||
|
||||
for (uint8_t row = 0; row < MATRIX_ROWS; row++) {
|
||||
phex(row); print(": ");
|
||||
print_matrix_row(row);
|
||||
print("\n");
|
||||
}
|
||||
}
|
||||
@@ -1,96 +0,0 @@
|
||||
0,Z
|
||||
1,S
|
||||
2,W
|
||||
3,3
|
||||
4,X
|
||||
5,D
|
||||
6,E
|
||||
7,4
|
||||
8,C
|
||||
9,F
|
||||
10,R
|
||||
11,5
|
||||
12,V
|
||||
13,G
|
||||
14,T
|
||||
15,6
|
||||
16,B
|
||||
17,H
|
||||
18,Y
|
||||
19,7
|
||||
20,N
|
||||
21,J
|
||||
22,U
|
||||
23,8
|
||||
24,PAD_2
|
||||
25,PAD_5
|
||||
26,PAD_8
|
||||
27,NUM_LOCK
|
||||
28,M
|
||||
29,K
|
||||
30,I
|
||||
31,9
|
||||
32,COMMA
|
||||
33,L
|
||||
34,O
|
||||
35,0
|
||||
36,PERIOD
|
||||
37,SEMICOLON
|
||||
38,P
|
||||
39,MINUS
|
||||
40,SLASH
|
||||
41,QUOTE
|
||||
42,LEFT_BRACE
|
||||
43,EQUAL
|
||||
44,SPACE
|
||||
45,RSHIFT
|
||||
46,BACK_QUOTE
|
||||
47,RIGHT_BRACE
|
||||
48,CAPS_LOCK
|
||||
49,PAD_ASTERIX
|
||||
50,ENTER
|
||||
51,BACKSPACE
|
||||
52,PAD_0
|
||||
53,PAD_1
|
||||
54,PAD_4
|
||||
55,PAD_7
|
||||
56,PAD_PLUS
|
||||
57,UNASSIGNED
|
||||
58,PAD_MINUS
|
||||
59,SCROLL_LOCK
|
||||
60,PAD_PERIOD
|
||||
61,PAD_3
|
||||
62,PAD_6
|
||||
63,PAD_9
|
||||
64,BACKSLASH
|
||||
65,A
|
||||
66,Q
|
||||
67,2
|
||||
68,LALT
|
||||
69,UNASSIGNED
|
||||
70,UNASSIGNED
|
||||
71,1
|
||||
72,F7
|
||||
73,F5
|
||||
74,F3
|
||||
75,F1
|
||||
76,F8
|
||||
77,F6
|
||||
78,F4
|
||||
79,F2
|
||||
80,F10
|
||||
81,UNASSIGNED
|
||||
82,UNASSIGNED
|
||||
83,UNASSIGNED
|
||||
84,F9
|
||||
85,UNASSIGNED
|
||||
86,UNASSIGNED
|
||||
87,UNASSIGNED
|
||||
88,LSHIFT
|
||||
89,LCTRL
|
||||
90,TAB
|
||||
91,ESC
|
||||
92,UNASSIGNED
|
||||
93,UNASSIGNED
|
||||
94,UNASSIGNED
|
||||
95,UNASSIGNED
|
||||
|
@@ -1,70 +0,0 @@
|
||||
# IBM 5291 keyboard converter
|
||||
|
||||

|
||||
|
||||
A converter for the eponymous keyboard.
|
||||
|
||||
Keyboard Maintainer: [Listofoptions](https://github.com/listofoptions)
|
||||
Hardware Supported: IBM 5291, Teensy 2.0
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make converter/ibm_5291:default
|
||||
|
||||
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
|
||||
|
||||
|
||||
the pinout is as follows:
|
||||
|
||||
IBM−5291−Cable to Pinhead−14
|
||||
|
||||
| pin | description
|
||||
----|------------------------
|
||||
1 | GND
|
||||
2 | NC
|
||||
3 | GND
|
||||
4 | GN)
|
||||
5 | +5V
|
||||
6 | D0
|
||||
7 | D1
|
||||
8 | D2
|
||||
9 | D3
|
||||
10| D4
|
||||
11| D5
|
||||
12| D6
|
||||
13| Strobe
|
||||
14| Out
|
||||
|
||||
the pins on this connector are organized 
|
||||
|
||||
IBM−5291−2 Cable with DB15M connector
|
||||
|
||||
| pin | description
|
||||
----|-------------
|
||||
|1,2,3 | GND
|
||||
|4 | +5V
|
||||
|5 | D0
|
||||
|6 | D1
|
||||
|7 | D2
|
||||
|8 | D3
|
||||
|9 | D4
|
||||
|10 | D5
|
||||
|11 | D6
|
||||
|12 | Strobe
|
||||
|13 | Out
|
||||
|14 | PE
|
||||
|15 | NC
|
||||
|
||||
the above connector is actually numbered so it should be easier to determine
|
||||
where the needed connections are.
|
||||
|
||||
to connect to the teensy, the following are pins are needed (if you should choose not set your own):
|
||||
* PB0 -> PB6 are connected to D0 -> D6
|
||||
* +5V is connected to the corresponding teensy pin
|
||||
* gnd is as well, only one of the gnd pins needs to be connected though.
|
||||
* strobe is connected to pin PD1
|
||||
* data is connected to PD0
|
||||
* PE does not need to be connected to anything, but it could also be connected to gnd
|
||||
|
||||
sources:
|
||||
http://www.retrocomputing.eu/documents/5291_MaintenanceLibrary.pdf
|
||||
@@ -1,72 +0,0 @@
|
||||
# MCU name
|
||||
#MCU = at90usb1287
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Bootloader
|
||||
# This definition is optional, and if your keyboard supports multiple bootloaders of
|
||||
# different sizes, comment this out, and the correct address will be loaded
|
||||
# automatically (+60). See bootloader.mk for all options.
|
||||
BOOTLOADER = halfkay
|
||||
|
||||
# Build Options
|
||||
# change to "no" to disable the options, or define them in the Makefile in
|
||||
# the appropriate keymap folder that will get included automatically
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = no # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
|
||||
MIDI_ENABLE = no # MIDI controls
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
|
||||
API_SYSEX_ENABLE = no
|
||||
SPLIT_KEYBOARD = no
|
||||
WAIT_FOR_USB = yes
|
||||
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
|
||||
LAYOUTS_HAS_RGB = NO
|
||||
|
||||
CUSTOM_MATRIX = yes
|
||||
SRC = matrix.c
|
||||
@@ -41,10 +41,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define RGBLIGHT_HUE_STEP 8
|
||||
#define RGBLIGHT_SAT_STEP 8
|
||||
#define RGBLIGHT_VAL_STEP 8
|
||||
#define RGBLIGHT_LIMIT_VAL 100
|
||||
#endif
|
||||
|
||||
#ifdef AUDIO_ENABLE
|
||||
#define B6_AUDIO
|
||||
// #define NO_MUSIC_MODE
|
||||
#define RGBLIGHT_LIMIT_VAL 120
|
||||
#endif
|
||||
|
||||
@@ -26,10 +26,10 @@ enum crkbd_keycodes {
|
||||
K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A \
|
||||
) \
|
||||
LAYOUT_wrapper( \
|
||||
KC_ESC, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, KC_MINS, \
|
||||
KC_TAB, ALT_T(K11), K12, K13, K14, K15, K16, K17, K18, K19, K1A, RGUI_T(KC_QUOT), \
|
||||
KC_ESC, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, KC_BSPC, \
|
||||
KC_TAB, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, KC_QUOT, \
|
||||
OS_LSFT, CTL_T(K21), K22, K23, K24, K25, K26, K27, K28, K29, CTL_T(K2A), OS_RSFT, \
|
||||
LT(_LOWER,KC_GRV), KC_SPC, KC_BSPC, KC_DEL, KC_ENT, RAISE \
|
||||
LT(_LOWER,KC_GRV), KC_SPC, LALT_T(KC_BSPC), KC_DEL, KC_ENT, RAISE \
|
||||
)
|
||||
#define LAYOUT_crkbd_base_wrapper(...) LAYOUT_crkbd_base(__VA_ARGS__)
|
||||
|
||||
@@ -66,14 +66,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
),
|
||||
|
||||
[_LOWER] = LAYOUT_wrapper(
|
||||
KC_F11, _________________LOWER_L1__________________, _________________LOWER_R1__________________, KC_F11,
|
||||
KC_F12, _________________LOWER_L2__________________, _________________LOWER_R2__________________, KC_PIPE,
|
||||
_______, _________________LOWER_L3__________________, _________________LOWER_R3__________________, _______,
|
||||
KC_TILD, _________________LOWER_L1__________________, _________________LOWER_R1__________________, KC_BSPC,
|
||||
KC_F11, _________________LOWER_L2__________________, _________________LOWER_R2__________________, KC_PIPE,
|
||||
KC_F12, _________________LOWER_L3__________________, _________________LOWER_R3__________________, _______,
|
||||
_______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
[_RAISE] = LAYOUT_wrapper( \
|
||||
_______, _________________RAISE_L1__________________, _________________RAISE_R1__________________, _______,
|
||||
KC_GRV, _________________RAISE_L1__________________, _________________RAISE_R1__________________, KC_BSPC,
|
||||
_______, _________________RAISE_L2__________________, _________________RAISE_R2__________________, KC_BSLS,
|
||||
_______, _________________RAISE_L3__________________, _________________RAISE_R3__________________, _______,
|
||||
_______, _______, _______, _______, _______, _______
|
||||
@@ -81,13 +81,18 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_ADJUST] = LAYOUT_wrapper( \
|
||||
KC_MAKE, _________________ADJUST_L1_________________, _________________ADJUST_R1_________________, KC_RESET,
|
||||
VRSN, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, EEP_RST,
|
||||
_______, _________________ADJUST_L3_________________, _________________ADJUST_R3_________________, KC_MPLY,
|
||||
_______, _______, _______, KC_NUKE, TG_MODS, _______
|
||||
VRSN, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, EPRM,
|
||||
TG_MODS, _________________ADJUST_L3_________________, _________________ADJUST_R3_________________, KC_MPLY,
|
||||
_______, _______, _______, _______, _______, _______
|
||||
)
|
||||
};
|
||||
|
||||
int RGB_current_mode;
|
||||
|
||||
void matrix_init_keymap(void) {
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
RGB_current_mode = rgblight_config.mode;
|
||||
#endif
|
||||
//SSD1306 OLED init, make sure to add #define SSD1306OLED in config.h
|
||||
#ifdef SSD1306OLED
|
||||
iota_gfx_init(!has_usb()); // turns on the display
|
||||
@@ -97,118 +102,53 @@ void matrix_init_keymap(void) {
|
||||
PORTD &= ~(1<<5);
|
||||
|
||||
DDRB &= ~(1<<0);
|
||||
PORTB &= ~(1<<0);
|
||||
}
|
||||
PORTB &= ~(1<<0);}
|
||||
|
||||
//SSD1306 OLED update loop, make sure to add #define SSD1306OLED in config.h
|
||||
#ifdef SSD1306OLED
|
||||
|
||||
// When add source files to SRC in rules.mk, you can use functions.
|
||||
const char *read_layer_state(void);
|
||||
const char *read_logo(void);
|
||||
void set_keylog(uint16_t keycode, keyrecord_t *record);
|
||||
const char *read_keylog(void);
|
||||
const char *read_keylogs(void);
|
||||
char layer_state_str[24];
|
||||
char modifier_state_str[24];
|
||||
char host_led_state_str[24];
|
||||
char keylog_str[24] = {};
|
||||
char keylogs_str[21] = {};
|
||||
int keylogs_str_idx = 0;
|
||||
|
||||
// const char *read_mode_icon(bool swap);
|
||||
const char *read_host_led_state(void);
|
||||
// void set_timelog(void);
|
||||
// const char *read_timelog(void);
|
||||
|
||||
const char code_to_name[60] = {
|
||||
' ', ' ', ' ', ' ', 'a', 'b', 'c', 'd', 'e', 'f',
|
||||
'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p',
|
||||
'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z',
|
||||
'1', '2', '3', '4', '5', '6', '7', '8', '9', '0',
|
||||
'R', 'E', 'B', 'T', '_', '-', '=', '[', ']', '\\',
|
||||
'#', ';', '\'', '`', ',', '.', '/', ' ', ' ', ' '};
|
||||
|
||||
void set_keylog(uint16_t keycode, keyrecord_t *record) {
|
||||
char name = ' ';
|
||||
if (keycode < 60) {
|
||||
name = code_to_name[keycode];
|
||||
}
|
||||
|
||||
// update keylog
|
||||
snprintf(keylog_str, sizeof(keylog_str), "%dx%d, k%2d : %c",
|
||||
record->event.key.row, record->event.key.col,
|
||||
keycode, name);
|
||||
|
||||
// update keylogs
|
||||
if (keylogs_str_idx == sizeof(keylogs_str) - 1) {
|
||||
keylogs_str_idx = 0;
|
||||
for (int i = 0; i < sizeof(keylogs_str) - 1; i++) {
|
||||
keylogs_str[i] = ' ';
|
||||
}
|
||||
}
|
||||
|
||||
keylogs_str[keylogs_str_idx] = name;
|
||||
keylogs_str_idx++;
|
||||
}
|
||||
|
||||
const char *read_keylog(void) {
|
||||
return keylog_str;
|
||||
}
|
||||
|
||||
const char *read_keylogs(void) {
|
||||
return keylogs_str;
|
||||
}
|
||||
|
||||
|
||||
const char* read_modifier_state(void) {
|
||||
uint8_t modifiers = get_mods();
|
||||
uint8_t one_shot = get_oneshot_mods();
|
||||
|
||||
snprintf(modifier_state_str, sizeof(modifier_state_str), "Mods:%s %s %s %s",
|
||||
(modifiers & MODS_CTRL_MASK || one_shot & MODS_CTRL_MASK) ? "CTL" : " ",
|
||||
(modifiers & MODS_GUI_MASK || one_shot & MODS_GUI_MASK) ? "GUI" : " ",
|
||||
(modifiers & MODS_ALT_MASK || one_shot & MODS_ALT_MASK) ? "ALT" : " ",
|
||||
(modifiers & MODS_SHIFT_MASK || one_shot & MODS_SHIFT_MASK) ? "SFT" : " "
|
||||
);
|
||||
|
||||
return modifier_state_str;
|
||||
}
|
||||
|
||||
const char *read_host_led_state(void) {
|
||||
uint8_t leds = host_keyboard_leds();
|
||||
|
||||
snprintf(host_led_state_str, sizeof(host_led_state_str), "NL:%s CL:%s SL:%s",
|
||||
(leds & (1 << USB_LED_NUM_LOCK)) ? "on" : "- ",
|
||||
(leds & (1 << USB_LED_CAPS_LOCK)) ? "on" : "- ",
|
||||
(leds & (1 << USB_LED_SCROLL_LOCK)) ? "on" : "- "
|
||||
);
|
||||
|
||||
return host_led_state_str;
|
||||
}
|
||||
|
||||
const char* read_layer_state(void) {
|
||||
switch (biton32(layer_state)) {
|
||||
case _RAISE:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Raise ");
|
||||
break;
|
||||
case _LOWER:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Lower ");
|
||||
break;
|
||||
case _ADJUST:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Adjust ");
|
||||
break;
|
||||
default:
|
||||
switch (biton32(default_layer_state)) {
|
||||
switch (layer_state) {
|
||||
case _QWERTY:
|
||||
switch (default_layer_state) {
|
||||
case _QWERTY:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Qwerty ");
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: QWERTY");
|
||||
break;
|
||||
case _COLEMAK:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Colemak");
|
||||
break;
|
||||
case _DVORAK:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Dvorak ");
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Dvorak");
|
||||
break;
|
||||
case _WORKMAN:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Workman");
|
||||
break;
|
||||
}
|
||||
break;
|
||||
case _RAISE:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Raise");
|
||||
break;
|
||||
case _LOWER:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Lower");
|
||||
break;
|
||||
case _ADJUST:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Adjust");
|
||||
break;
|
||||
default:
|
||||
snprintf(layer_state_str, sizeof(layer_state_str), "Layer: Undef-%ld", layer_state);
|
||||
}
|
||||
|
||||
return layer_state_str;
|
||||
@@ -220,13 +160,12 @@ void matrix_scan_keymap(void) {
|
||||
|
||||
void matrix_render_user(struct CharacterMatrix *matrix) {
|
||||
if (is_master) {
|
||||
//If you want to change the display of OLED, you need to change here
|
||||
// If you want to change the display of OLED, you need to change here
|
||||
matrix_write_ln(matrix, read_layer_state());
|
||||
matrix_write_ln(matrix, read_modifier_state());
|
||||
// matrix_write_ln(matrix, read_keylog());
|
||||
matrix_write_ln(matrix, read_keylog());
|
||||
matrix_write_ln(matrix, read_keylogs());
|
||||
// matrix_write_ln(matrix, read_mode_icon(keymap_config.swap_lalt_lgui));
|
||||
matrix_write(matrix, read_host_led_state());
|
||||
//matrix_write_ln(matrix, read_mode_icon(keymap_config.swap_lalt_lgui));
|
||||
matrix_write_ln(matrix, read_host_led_state());
|
||||
//matrix_write_ln(matrix, read_timelog());
|
||||
} else {
|
||||
matrix_write(matrix, read_logo());
|
||||
@@ -248,14 +187,8 @@ void iota_gfx_task_user(void) {
|
||||
}
|
||||
|
||||
bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case KC_A ... KC_SLASH:
|
||||
case KC_F1 ... KC_F12:
|
||||
case KC_INSERT ... KC_UP:
|
||||
case KC_KP_SLASH ... KC_KP_DOT:
|
||||
case KC_F13 ... KC_F24:
|
||||
if (record->event.pressed) { set_keylog(keycode, record); }
|
||||
break;
|
||||
if (record->event.pressed) {
|
||||
set_keylog(keycode, record);
|
||||
// set_timelog();
|
||||
}
|
||||
return true;
|
||||
|
||||
@@ -20,14 +20,12 @@ SWAP_HANDS_ENABLE = no # Enable one-hand typing
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
|
||||
BOOTLOADER = qmk-dfu
|
||||
|
||||
# If you want to change the display of OLED, you need to change here
|
||||
SRC += ./lib/glcdfont.c \
|
||||
./lib/rgb_state_reader.c \
|
||||
./lib/logo_reader.c \
|
||||
# ./lib/keylogger.c \
|
||||
# ./lib/host_led_state_reader.c \
|
||||
# ./lib/mode_icon_reader.c \
|
||||
./lib/keylogger.c \
|
||||
./lib/host_led_state_reader.c \
|
||||
# ./lib/layer_state_reader.c \
|
||||
# ./lib/mode_icon_reader.c \
|
||||
# ./lib/timelogger.c \
|
||||
|
||||
@@ -1,43 +0,0 @@
|
||||
/* Copyright 2018 Elliot Powell
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#include "96.h"
|
||||
|
||||
void matrix_init_kb(void) {
|
||||
// put your keyboard start-up code here
|
||||
// runs once when the firmware starts up
|
||||
|
||||
matrix_init_user();
|
||||
}
|
||||
|
||||
void matrix_scan_kb(void) {
|
||||
// put your looping keyboard code here
|
||||
// runs every cycle (a lot)
|
||||
|
||||
matrix_scan_user();
|
||||
}
|
||||
|
||||
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
|
||||
// put your per-action keyboard code here
|
||||
// runs for every action, just before processing by the firmware
|
||||
|
||||
return process_record_user(keycode, record);
|
||||
}
|
||||
|
||||
void led_set_kb(uint8_t usb_led) {
|
||||
// put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
|
||||
|
||||
led_set_user(usb_led);
|
||||
}
|
||||
@@ -1,47 +0,0 @@
|
||||
/* Copyright 2018 Elliot Powell
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#ifndef EP96_H
|
||||
#define EP96_H
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
/* This a shortcut to help you visually see your layout.
|
||||
*
|
||||
* The first section contains all of the arguments representing the physical
|
||||
* layout of the board and position of the keys.
|
||||
*
|
||||
* The second converts the arguments into a two-dimensional array which
|
||||
* represents the switch matrix.
|
||||
*/
|
||||
#define xxxx KC_NO
|
||||
|
||||
#define LAYOUT( \
|
||||
K000, K001, K002, k003, k004, k005, k006, k007, k008, k009, k010, k011, k012, k013, k014, k015, k016, k017, k018, \
|
||||
K100, K101, K102, k103, k104, k105, k106, k107, k108, k109, k110, k111, k112, k114, k115, k116, k117, k118, \
|
||||
K200, K202, k203, k204, k205, k206, k207, k208, k209, k210, k211, k212, k213, k215, k216, k217, \
|
||||
K300, K302, k303, k304, k305, k306, k307, k308, k309, k310, k311, k312, k313, k314, k315, k316, k317, k318, \
|
||||
K400, K401, K402, k403, k404, k405, k406, k407, k408, k409, k410, k411, k413, k414, k415, k416, k417, \
|
||||
K500, K501, K502, k506, k511, k512, k513, k514, k515, k516, k517, k518) \
|
||||
{ \
|
||||
{K000, K001, K002, k003, k004, k005, k006, k007, k008, k009, k010, k011, k012, k013, k014, k015, k016, k017, k018}, \
|
||||
{K100, K101, K102, k103, k104, k105, k106, k107, k108, k109, k110, k111, k112, xxxx, k114, k115, k116, k117, k118}, \
|
||||
{K200, xxxx, K202, k203, k204, k205, k206, k207, k208, k209, k210, k211, k212, k213, xxxx, k215, k216, k217, xxxx}, \
|
||||
{K300, xxxx, K302, k303, k304, k305, k306, k307, k308, k309, k310, k311, k312, k313, k314, k315, k316, k317, k318}, \
|
||||
{K400, K401, K402, k403, k404, k405, k406, k407, k408, k409, k410, k411, xxxx, k413, k414, k415, k416, k417, xxxx}, \
|
||||
{K500, K501, K502, xxxx, xxxx, xxxx, k506, xxxx, xxxx, xxxx, xxxx, k511, k512, k513, k514, k515, k516, k517, k518} \
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -1,212 +0,0 @@
|
||||
/*
|
||||
Copyright 2018 Elliot Powell
|
||||
|
||||
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 0xFEED
|
||||
#define PRODUCT_ID 0x9696
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER Elliot Powell
|
||||
#define PRODUCT ep96
|
||||
#define DESCRIPTION A simple 96 key keyboard
|
||||
|
||||
/* key matrix size */
|
||||
#define MATRIX_ROWS 6
|
||||
#define MATRIX_COLS 19
|
||||
|
||||
/*
|
||||
* Keyboard Matrix Assignments
|
||||
*
|
||||
* Change this to how you wired your keyboard
|
||||
* COLS: AVR pins used for columns, left to right
|
||||
* ROWS: AVR pins used for rows, top to bottom
|
||||
* DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
|
||||
* ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
|
||||
*
|
||||
*/
|
||||
#define MATRIX_ROW_PINS { B0, B1, B3, B2, B7, C6 }
|
||||
#define MATRIX_COL_PINS { D0, D1, D2, D3, D5, D4, D6, D7, B4, B5, B6, C7, F7, F6, F5, F4, F1, F0, E6 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
/* COL2ROW, ROW2COL, or CUSTOM_MATRIX */
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
// #endif
|
||||
|
||||
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
|
||||
#define DEBOUNCING_DELAY 5
|
||||
|
||||
/* define if matrix has ghost (lacks anti-ghosting diodes) */
|
||||
//#define MATRIX_HAS_GHOST
|
||||
|
||||
|
||||
/* 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
|
||||
|
||||
/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
|
||||
* This is userful for the Windows task manager shortcut (ctrl+shift+esc).
|
||||
*/
|
||||
// #define GRAVE_ESC_CTRL_OVERRIDE
|
||||
|
||||
/*
|
||||
* Force NKRO
|
||||
*
|
||||
* Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
|
||||
* state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
|
||||
* makefile for this to work.)
|
||||
*
|
||||
* If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
|
||||
* until the next keyboard reset.
|
||||
*
|
||||
* NKRO may prevent your keystrokes from being detected in the BIOS, but it is
|
||||
* fully operational during normal computer usage.
|
||||
*
|
||||
* For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
|
||||
* or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
|
||||
* bootmagic, NKRO mode will always be enabled until it is toggled again during a
|
||||
* power-up.
|
||||
*
|
||||
*/
|
||||
//#define FORCE_NKRO
|
||||
|
||||
/*
|
||||
* Magic Key Options
|
||||
*
|
||||
* Magic keys are hotkey commands that allow control over firmware functions of
|
||||
* the keyboard. They are best used in combination with the HID Listen program,
|
||||
* found here: https://www.pjrc.com/teensy/hid_listen.html
|
||||
*
|
||||
* The options below allow the magic key functionality to be changed. This is
|
||||
* useful if your keyboard/keypad is missing keys and you want magic key support.
|
||||
*
|
||||
*/
|
||||
|
||||
/* key combination for magic key command */
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
|
||||
)
|
||||
|
||||
/* control how magic key switches layers */
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
|
||||
|
||||
/* override magic key keymap */
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
|
||||
//#define MAGIC_KEY_HELP1 H
|
||||
//#define MAGIC_KEY_HELP2 SLASH
|
||||
//#define MAGIC_KEY_DEBUG D
|
||||
//#define MAGIC_KEY_DEBUG_MATRIX X
|
||||
//#define MAGIC_KEY_DEBUG_KBD K
|
||||
//#define MAGIC_KEY_DEBUG_MOUSE M
|
||||
//#define MAGIC_KEY_VERSION V
|
||||
//#define MAGIC_KEY_STATUS S
|
||||
//#define MAGIC_KEY_CONSOLE C
|
||||
//#define MAGIC_KEY_LAYER0_ALT1 ESC
|
||||
//#define MAGIC_KEY_LAYER0_ALT2 GRAVE
|
||||
//#define MAGIC_KEY_LAYER0 0
|
||||
//#define MAGIC_KEY_LAYER1 1
|
||||
//#define MAGIC_KEY_LAYER2 2
|
||||
//#define MAGIC_KEY_LAYER3 3
|
||||
//#define MAGIC_KEY_LAYER4 4
|
||||
//#define MAGIC_KEY_LAYER5 5
|
||||
//#define MAGIC_KEY_LAYER6 6
|
||||
//#define MAGIC_KEY_LAYER7 7
|
||||
//#define MAGIC_KEY_LAYER8 8
|
||||
//#define MAGIC_KEY_LAYER9 9
|
||||
//#define MAGIC_KEY_BOOTLOADER PAUSE
|
||||
//#define MAGIC_KEY_LOCK CAPS
|
||||
//#define MAGIC_KEY_EEPROM E
|
||||
//#define MAGIC_KEY_NKRO N
|
||||
//#define MAGIC_KEY_SLEEP_LED Z
|
||||
|
||||
/*
|
||||
* 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
|
||||
//#define NO_ACTION_MACRO
|
||||
//#define NO_ACTION_FUNCTION
|
||||
|
||||
/*
|
||||
* MIDI options
|
||||
*/
|
||||
|
||||
/* Prevent use of disabled MIDI features in the keymap */
|
||||
//#define MIDI_ENABLE_STRICT 1
|
||||
|
||||
/* enable basic MIDI features:
|
||||
- MIDI notes can be sent when in Music mode is on
|
||||
*/
|
||||
//#define MIDI_BASIC
|
||||
|
||||
/* enable advanced MIDI features:
|
||||
- MIDI notes can be added to the keymap
|
||||
- Octave shift and transpose
|
||||
- Virtual sustain, portamento, and modulation wheel
|
||||
- etc.
|
||||
*/
|
||||
//#define MIDI_ADVANCED
|
||||
|
||||
/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
|
||||
//#define MIDI_TONE_KEYCODE_OCTAVES 1
|
||||
|
||||
/*
|
||||
* HD44780 LCD Display Configuration
|
||||
*/
|
||||
/*
|
||||
#define LCD_LINES 2 //< number of visible lines of the display
|
||||
#define LCD_DISP_LENGTH 16 //< visibles characters per line of the display
|
||||
|
||||
#define LCD_IO_MODE 1 //< 0: memory mapped mode, 1: IO port mode
|
||||
|
||||
#if LCD_IO_MODE
|
||||
#define LCD_PORT PORTB //< port for the LCD lines
|
||||
#define LCD_DATA0_PORT LCD_PORT //< port for 4bit data bit 0
|
||||
#define LCD_DATA1_PORT LCD_PORT //< port for 4bit data bit 1
|
||||
#define LCD_DATA2_PORT LCD_PORT //< port for 4bit data bit 2
|
||||
#define LCD_DATA3_PORT LCD_PORT //< port for 4bit data bit 3
|
||||
#define LCD_DATA0_PIN 4 //< pin for 4bit data bit 0
|
||||
#define LCD_DATA1_PIN 5 //< pin for 4bit data bit 1
|
||||
#define LCD_DATA2_PIN 6 //< pin for 4bit data bit 2
|
||||
#define LCD_DATA3_PIN 7 //< pin for 4bit data bit 3
|
||||
#define LCD_RS_PORT LCD_PORT //< port for RS line
|
||||
#define LCD_RS_PIN 3 //< pin for RS line
|
||||
#define LCD_RW_PORT LCD_PORT //< port for RW line
|
||||
#define LCD_RW_PIN 2 //< pin for RW line
|
||||
#define LCD_E_PORT LCD_PORT //< port for Enable line
|
||||
#define LCD_E_PIN 1 //< pin for Enable line
|
||||
#endif
|
||||
*/
|
||||
|
||||
@@ -1,426 +0,0 @@
|
||||
{
|
||||
"keyboard_name": "ep96",
|
||||
"maintainer": "e11i0t23",
|
||||
"width": 19,
|
||||
"height": 6,
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"key_count": 100,
|
||||
"layout": [{
|
||||
"label": "Esc",
|
||||
"x": 0,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F1",
|
||||
"x": 1,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F2",
|
||||
"x": 2,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F3",
|
||||
"x": 3,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F4",
|
||||
"x": 4,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F5",
|
||||
"x": 5,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F6",
|
||||
"x": 6,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F7",
|
||||
"x": 7,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F8",
|
||||
"x": 8,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F9",
|
||||
"x": 9,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F10",
|
||||
"x": 10,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F11",
|
||||
"x": 11,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "F12",
|
||||
"x": 12,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "Prt Sc",
|
||||
"x": 13,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "Delete",
|
||||
"x": 14,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "home",
|
||||
"x": 15,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "Menu",
|
||||
"x": 16,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "Pg Up",
|
||||
"x": 17,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "Pg Dn",
|
||||
"x": 18,
|
||||
"y": 0
|
||||
}, {
|
||||
"label": "~",
|
||||
"x": 0,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "!",
|
||||
"x": 1,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "@",
|
||||
"x": 2,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "#",
|
||||
"x": 3,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "$",
|
||||
"x": 4,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "%",
|
||||
"x": 5,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "^",
|
||||
"x": 6,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "&",
|
||||
"x": 7,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "*",
|
||||
"x": 8,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "(",
|
||||
"x": 9,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": ")",
|
||||
"x": 10,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "_",
|
||||
"x": 11,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "+",
|
||||
"x": 12,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "Backspace",
|
||||
"x": 13,
|
||||
"y": 1,
|
||||
"w": 2
|
||||
}, {
|
||||
"label": "Num Lock",
|
||||
"x": 15,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "/",
|
||||
"x": 16,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "*",
|
||||
"x": 17,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "-",
|
||||
"x": 18,
|
||||
"y": 1
|
||||
}, {
|
||||
"label": "Tab",
|
||||
"x": 0,
|
||||
"y": 2,
|
||||
"w": 1.5
|
||||
}, {
|
||||
"label": "Q",
|
||||
"x": 1.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "W",
|
||||
"x": 2.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "E",
|
||||
"x": 3.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "R",
|
||||
"x": 4.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "T",
|
||||
"x": 5.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "Y",
|
||||
"x": 6.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "U",
|
||||
"x": 7.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "I",
|
||||
"x": 8.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "O",
|
||||
"x": 9.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "P",
|
||||
"x": 10.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "{",
|
||||
"x": 11.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "}",
|
||||
"x": 12.5,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "Enter",
|
||||
"x": 13.75,
|
||||
"y": 2,
|
||||
"w": 1.25,
|
||||
"h": 2
|
||||
}, {
|
||||
"label": "7",
|
||||
"x": 15,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "8",
|
||||
"x": 16,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "9",
|
||||
"x": 17,
|
||||
"y": 2
|
||||
}, {
|
||||
"label": "+",
|
||||
"x": 18,
|
||||
"y": 2,
|
||||
"h": 2
|
||||
}, {
|
||||
"label": "Caps Lock",
|
||||
"x": 0,
|
||||
"y": 3,
|
||||
"w": 1.75
|
||||
}, {
|
||||
"label": "A",
|
||||
"x": 1.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "S",
|
||||
"x": 2.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "D",
|
||||
"x": 3.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "F",
|
||||
"x": 4.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "G",
|
||||
"x": 5.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "H",
|
||||
"x": 6.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "J",
|
||||
"x": 7.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "K",
|
||||
"x": 8.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "L",
|
||||
"x": 9.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": ":",
|
||||
"x": 10.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "\"",
|
||||
"x": 11.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "~",
|
||||
"x": 12.75,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "4",
|
||||
"x": 15,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "5",
|
||||
"x": 16,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "6",
|
||||
"x": 17,
|
||||
"y": 3
|
||||
}, {
|
||||
"label": "Shift",
|
||||
"x": 0,
|
||||
"y": 4,
|
||||
"w": 1.25
|
||||
}, {
|
||||
"label": "|",
|
||||
"x": 1.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "Z",
|
||||
"x": 2.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "X",
|
||||
"x": 3.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "C",
|
||||
"x": 4.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "V",
|
||||
"x": 5.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "B",
|
||||
"x": 6.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "N",
|
||||
"x": 7.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "M",
|
||||
"x": 8.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "<",
|
||||
"x": 9.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": ">",
|
||||
"x": 10.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "?",
|
||||
"x": 11.25,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "Shift",
|
||||
"x": 12.25,
|
||||
"y": 4,
|
||||
"w": 1.75
|
||||
}, {
|
||||
"label": "\u2191",
|
||||
"x": 14,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "1",
|
||||
"x": 15,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "2",
|
||||
"x": 16,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "3",
|
||||
"x": 17,
|
||||
"y": 4
|
||||
}, {
|
||||
"label": "Enter",
|
||||
"x": 18,
|
||||
"y": 4,
|
||||
"h": 2
|
||||
}, {
|
||||
"label": "Ctrl",
|
||||
"x": 0,
|
||||
"y": 5,
|
||||
"w": 1.25
|
||||
}, {
|
||||
"label": "Win",
|
||||
"x": 1.25,
|
||||
"y": 5,
|
||||
"w": 1.25
|
||||
}, {
|
||||
"label": "Alt",
|
||||
"x": 2.5,
|
||||
"y": 5,
|
||||
"w": 1.25
|
||||
}, {
|
||||
"x": 3.75,
|
||||
"y": 5,
|
||||
"w": 6.25
|
||||
}, {
|
||||
"label": "Alt",
|
||||
"x": 10,
|
||||
"y": 5,
|
||||
"w": 1.5
|
||||
}, {
|
||||
"label": "Crtl",
|
||||
"x": 11.5,
|
||||
"y": 5,
|
||||
"w": 1.5
|
||||
}, {
|
||||
"label": "\u2190",
|
||||
"x": 13,
|
||||
"y": 5
|
||||
}, {
|
||||
"label": "\u2193",
|
||||
"x": 14,
|
||||
"y": 5
|
||||
}, {
|
||||
"label": "\u2192",
|
||||
"x": 15,
|
||||
"y": 5
|
||||
}, {
|
||||
"label": "0",
|
||||
"x": 16,
|
||||
"y": 5
|
||||
}, {
|
||||
"label": ".",
|
||||
"x": 17,
|
||||
"y": 5
|
||||
}]
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,67 +0,0 @@
|
||||
/* Copyright 2018 Elliot Powell
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
// Defines the keycodes used by our macros in process_record_user
|
||||
enum custom_keycodes {
|
||||
QMKBEST = SAFE_RANGE,
|
||||
QMKURL
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT( /* Base */
|
||||
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_DEL, KC_HOME, KC_END, KC_PGUP, KC_PGDN, \
|
||||
KC_GRV, 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_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
|
||||
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_P7, KC_P8, KC_P9, \
|
||||
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_NUHS, KC_ENT, KC_P4, KC_P5, KC_P6, KC_PPLS, \
|
||||
KC_LSFT, KC_BSLS, 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_P1, KC_P2, KC_P3, \
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT, KC_PENT \
|
||||
),
|
||||
};
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case QMKBEST:
|
||||
if (record->event.pressed) {
|
||||
// when keycode QMKBEST is pressed
|
||||
SEND_STRING("QMK is the best thing ever!");
|
||||
} else {
|
||||
// when keycode QMKBEST is released
|
||||
}
|
||||
break;
|
||||
case QMKURL:
|
||||
if (record->event.pressed) {
|
||||
// when keycode QMKURL is pressed
|
||||
SEND_STRING("https://qmk.fm/" SS_TAP(X_ENTER));
|
||||
} else {
|
||||
// when keycode QMKURL is released
|
||||
}
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void matrix_init_user(void) {
|
||||
|
||||
}
|
||||
|
||||
void matrix_scan_user(void) {
|
||||
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led) {
|
||||
|
||||
}
|
||||
@@ -1 +0,0 @@
|
||||
# The default keymap for ep96
|
||||
@@ -1,15 +0,0 @@
|
||||
# ep96
|
||||
|
||||

|
||||
|
||||
A simple 96 key keyboard
|
||||
|
||||
Keyboard Maintainer: Keyboard Maintainer: [Elliot Powell](https://github.com/e11i0t23), [/u/e11i0t23](https://reddit.com/u/e11i0t23)
|
||||
Hardware Supported: EP96 PCB
|
||||
Hardware Availability: Possible availability upon request
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make ep/96:default
|
||||
|
||||
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
|
||||
@@ -1,81 +0,0 @@
|
||||
# MCU name
|
||||
#MCU = at90usb1286
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
|
||||
# Bootloader selection
|
||||
# Teensy halfkay
|
||||
# Pro Micro caterina
|
||||
# Atmel DFU atmel-dfu
|
||||
# LUFA DFU lufa-dfu
|
||||
# QMK DFU qmk-dfu
|
||||
# atmega32a bootloadHID
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
|
||||
# If you don't know the bootloader type, then you can specify the
|
||||
# Boot Section Size in *bytes* by uncommenting out the OPT_DEFS line
|
||||
# Teensy halfKay 512
|
||||
# Teensy++ halfKay 1024
|
||||
# Atmel DFU loader 4096
|
||||
# LUFA bootloader 4096
|
||||
# USBaspLoader 2048
|
||||
# OPT_DEFS += -DBOOTLOADER_SIZE=4096
|
||||
|
||||
|
||||
# Build Options
|
||||
# change yes to no to disable
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = yes # Console for debug(+400)
|
||||
COMMAND_ENABLE = yes # 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 = no # USB Nkey Rollover
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
|
||||
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
|
||||
MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
@@ -1,88 +0,0 @@
|
||||
/* Copyright 2018 @TurboMech /u/TurboMech <discord> @A9entOran9e#6134
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
#define _BL 0 //Base layer
|
||||
#define _FN1 1 //Function layer
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
/* BL
|
||||
____________________________________________________________________________________________________________________________________________________________________________
|
||||
| | | | | | | | | | | | | | | | | | | |
|
||||
| ESC | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | DELETE | P SCN | HOME | END | P UP | P DOWN |
|
||||
|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|
|
||||
| ` | | | | | | | | | | | | | BACK | NUM | | | |
|
||||
| ¬ | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | _ - | = + | SPACE | LOCK | / | * | - |
|
||||
|________|________|________|________|________|________|________|________|________|________|________|________|________|_________________|________|________|________|________|
|
||||
| | | | | | | | | | | | [ | ] | | | | | |
|
||||
| TAB | Q | W | E | R | T | Y | U | I | O | P | { | } | | 7 | 8 | 9 | |
|
||||
|____________|________|________|________|________|________|________|________|________|________|________|________|________|__ ENTER |________|________|________| + |
|
||||
| | | | | | | | | | | ; | ' | # | | | | | |
|
||||
| CAPS LOCK | A | S | D | F | G | H | J | K | L | : | @ | ~ | | 4 | 5 | 6 | |
|
||||
|______________|________|________|________|________|________|________|________|________|________|________|________|________|___________|________|________|________|________|
|
||||
| | \ | | | | | | | | , | . | / | | | | | | |
|
||||
| SHIFT | | | Z | X | C | V | B | N | M | < | > | ? | SHIFT | UP | 1 | 2 | 3 | |
|
||||
|__________|_______|________|________|________|________|________|________|________|________|________|________|________________|________|________|________|________| ENTER |
|
||||
| | | | | | | MO | | | | | | |
|
||||
| CTRL | LGUI | L ALT | SPACE | R ALT | R CTRL | _FN | LEFT | DOWN | RIGHT | 0 | . | |
|
||||
|__________|__________|__________|________________________________________________________|________|________|________|________|________|________|________|________|________|
|
||||
*/
|
||||
|
||||
[_BL] = LAYOUT_split_shift_and_bs(
|
||||
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, KC_PSCR, KC_HOME, KC_END, KC_PGUP, KC_PGDN,
|
||||
KC_GRV, 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_NO, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
|
||||
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_NUHS, KC_P7, KC_P8, KC_P9, KC_PPLS,
|
||||
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_NO, KC_P4, KC_P5, KC_P6,
|
||||
KC_LSFT, KC_NUBS, 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_P1, KC_P2, KC_P3, KC_PENT,
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RCTL, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT, KC_P0, KC_PDOT, KC_NO
|
||||
),
|
||||
|
||||
/* FN_1
|
||||
____________________________________________________________________________________________________________________________________________________________________________
|
||||
| | | | | | | | | | | | | | | VOL | VOL | NEXT | | |
|
||||
| RESET | | | | | | | | | | | | | MUTE | DOWN | UP | TRACK | HOME | END |
|
||||
|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|________|
|
||||
| | RGB | RGB | RGB | RGB | RGB | RGB | RGB | RGB | | | | | | | | | |
|
||||
| | TOGGLE | MODE |INCREASE|DECREASE| HUE | HUE | SAT | | | | | | DELETE | | | | |
|
||||
|________|________|________|________|________|INCREASE|DECREASE|INCREASE|DECREASE|________|________|________|________|_________________|________|________|________|________|
|
||||
| | BACK | BACK | | | | | | | | | | | | | | | |
|
||||
| | LIGHT | LIGHT | | | | | | | | | | | | | | | |
|
||||
|____________| TOGGLE |INCREASE|DECREASE|________|________|________|________|________|________|________|________|________|__ |________|________|________| |
|
||||
| | | | | | | | | | | | | | | | | | |
|
||||
| | | | | | | | | | | | | | | | | | |
|
||||
|______________|________|________|________|________|________|________|________|________|________|________|________|________|___________|________|________|________|________|
|
||||
| | | | | | | | | | | | | | | | | | |
|
||||
| | | | | | | | | | | | | | | | | | |
|
||||
|__________|_______|________|________|________|________|________|________|________|________|________|________|________________|________|________|________|________| |
|
||||
| | | | | | | | | | | | | |
|
||||
| | | | | | | | | | | | | |
|
||||
|__________|__________|__________|________________________________________________________|________|________|________|________|________|________|________|________|________|
|
||||
*/
|
||||
|
||||
[_FN1] = LAYOUT_split_shift_and_bs(
|
||||
RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MUTE, KC_VOLD, KC_VOLU, KC_MNXT, KC_HOME, KC_END,
|
||||
_______, RGB_TOG, RGB_MOD, RGB_VAI, RGB_VAD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, _______, _______, _______, _______, _______, KC_DEL, _______, _______, _______, _______,
|
||||
_______, BL_TOGG, BL_INC, BL_DEC, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
};
|
||||
|
||||
@@ -10,34 +10,4 @@
|
||||
#include <avr/io.h>
|
||||
#include <stddef.h>
|
||||
|
||||
// This is the 21-key keypad to 4x6 element matrix mapping
|
||||
#define LAYOUT( \
|
||||
KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
|
||||
KM_NUM, KM_FSL, KM_AST, KM_MIN, \
|
||||
KM___7, KM___8, KM___9, KM_EQU, \
|
||||
KM___4, KM___5, KM___6, KM_PLS, \
|
||||
KM___1, KM___2, KM___3, ___ENT, \
|
||||
KM___0, _____0, KM_DOT, KM_ENT \
|
||||
) { \
|
||||
{ KM_ESC, KM_TAB, KM_BSL, KM_ARR }, \
|
||||
{ KM_NUM, KM_FSL, KM_AST, KM_MIN }, \
|
||||
{ KM___7, KM___8, KM___9, KM_EQU }, \
|
||||
{ KM___4, KM___5, KM___6, KM_PLS }, \
|
||||
{ KM___1, KM___2, KM___3, KC_NO }, \
|
||||
{ KM___0, KC_NO, KM_DOT, KM_ENT } \
|
||||
}
|
||||
|
||||
// This is the 21-key keypad to 2x11 element matrix mapping
|
||||
#define LAYOUT_pad21( \
|
||||
KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
|
||||
KM_NUM, KM_FSL, KM_AST, KM_MIN, \
|
||||
KM___7, KM___8, KM___9, \
|
||||
KM___4, KM___5, KM___6, KM_PLS, \
|
||||
KM___1, KM___2, KM___3, \
|
||||
KM___0, KM_DOT, KM_ENT \
|
||||
) { \
|
||||
{ KM_ESC, KM_TAB, KM_BSL, KM_ARR, KM___7, KM___8, KM___9, KM_PLS, KM___1, KM___2, KM___3, }, \
|
||||
{ KM_NUM, KM_FSL, KM_AST, KM_MIN, KM___4, KM___5, KM___6, KM_ENT, KC_NO, KM___0, KM_DOT, }, \
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,62 +0,0 @@
|
||||
{
|
||||
"keyboard_name": "arrow_pad",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"width": 4,
|
||||
"height": 6,
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
{"label":"KM_ESC", "x":0, "y":0},
|
||||
{"label":"KM_TAB", "x":1, "y":0},
|
||||
{"label":"KM_BSL", "x":2, "y":0},
|
||||
{"label":"KM_ARR", "x":3, "y":0},
|
||||
{"label":"KM_NUM", "x":0, "y":1},
|
||||
{"label":"KM_FSL", "x":1, "y":1},
|
||||
{"label":"KM_AST", "x":2, "y":1},
|
||||
{"label":"KM_MIN", "x":3, "y":1},
|
||||
{"label":"KM___7", "x":0, "y":2},
|
||||
{"label":"KM___8", "x":1, "y":2},
|
||||
{"label":"KM___9", "x":2, "y":2},
|
||||
{"label":"KM_EQU", "x":3, "y":2},
|
||||
{"label":"KM___4", "x":0, "y":3},
|
||||
{"label":"KM___5", "x":1, "y":3},
|
||||
{"label":"KM___6", "x":2, "y":3},
|
||||
{"label":"KM_PLS", "x":3, "y":3},
|
||||
{"label":"KM___1", "x":0, "y":4},
|
||||
{"label":"KM___2", "x":1, "y":4},
|
||||
{"label":"KM___3", "x":2, "y":4},
|
||||
{"label":"___ENT", "x":3, "y":4},
|
||||
{"label":"KM___0", "x":0, "y":5},
|
||||
{"label":"_____0", "x":1, "y":5},
|
||||
{"label":"KM_DOT", "x":2, "y":5},
|
||||
{"label":"KM_ENT", "x":3, "y":5}
|
||||
]
|
||||
},
|
||||
"LAYOUT_pad21": {
|
||||
"layout": [
|
||||
{"label":"KM_ESC", "x":0, "y":0},
|
||||
{"label":"KM_TAB", "x":1, "y":0},
|
||||
{"label":"KM_BSL", "x":2, "y":0},
|
||||
{"label":"KM_ARR", "x":3, "y":0},
|
||||
{"label":"KM_NUM", "x":0, "y":1},
|
||||
{"label":"KM_FSL", "x":1, "y":1},
|
||||
{"label":"KM_AST", "x":2, "y":1},
|
||||
{"label":"KM_MIN", "x":3, "y":1},
|
||||
{"label":"KM___7", "x":0, "y":2},
|
||||
{"label":"KM___8", "x":1, "y":2},
|
||||
{"label":"KM___9", "x":2, "y":2},
|
||||
{"label":"KM___4", "x":0, "y":3},
|
||||
{"label":"KM___5", "x":1, "y":3},
|
||||
{"label":"KM___6", "x":2, "y":3},
|
||||
{"label":"KM_PLS", "x":3, "y":2, "h":2},
|
||||
{"label":"KM___1", "x":0, "y":4},
|
||||
{"label":"KM___2", "x":1, "y":4},
|
||||
{"label":"KM___3", "x":2, "y":4},
|
||||
{"label":"KM___0", "x":0, "y":5, "w":2},
|
||||
{"label":"KM_DOT", "x":2, "y":5},
|
||||
{"label":"KM_ENT", "x":3, "y":4, "h":2}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,18 +1,35 @@
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "arrow_pad.h"
|
||||
#include "led.h"
|
||||
|
||||
enum layers {
|
||||
LAYER_BASE,
|
||||
LAYER_EDIT,
|
||||
LAYER_FUNCTION
|
||||
};
|
||||
// This is the 21-key keypad to 2x11 element matrix mapping
|
||||
#define LAYOUT( \
|
||||
KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
|
||||
KM_NUM, KM_FSL, KM_AST, KM_MIN, \
|
||||
KM___7, KM___8, KM___9, KM_EQU, \
|
||||
KM___4, KM___5, KM___6, KM_PLS, \
|
||||
KM___1, KM___2, KM___3, ___ENT, \
|
||||
KM___0, _____0, KM_DOT, KM_ENT \
|
||||
) { \
|
||||
{ KM_ESC, KM_TAB, KM_BSL, KM_ARR }, \
|
||||
{ KM_NUM, KM_FSL, KM_AST, KM_MIN }, \
|
||||
{ KM___7, KM___8, KM___9, KM_EQU }, \
|
||||
{ KM___4, KM___5, KM___6, KM_PLS }, \
|
||||
{ KM___1, KM___2, KM___3, KC_NO }, \
|
||||
{ KM___0, KC_NO, KM_DOT, KM_ENT } \
|
||||
}
|
||||
|
||||
enum custom_keycodes {
|
||||
M_COPY = SAFE_RANGE, // KC_FN5: MACRO_COPY_CUT
|
||||
M_SHFCT, // KC_FN6: MACRO_SHIFT_CONTROL
|
||||
M_CTALT // KC_FN7: MACRO_CONTROL_ALT
|
||||
};
|
||||
#define LAYER_BASE 0
|
||||
#define LAYER_EDIT 1
|
||||
#define LAYER_FUNCTION 2
|
||||
|
||||
#define MACRO_COPY_CUT 0
|
||||
#define MACRO_SHIFT_CONTROL 1
|
||||
#define MACRO_CONTROL_ALT 2
|
||||
|
||||
#define M_COPY KC_FN5
|
||||
#define M_SHFCT KC_FN6
|
||||
#define M_CTALT KC_FN7
|
||||
|
||||
#define SC_UNDO LCTL(KC_Z)
|
||||
#define SC_REDO LCTL(KC_Y)
|
||||
@@ -25,10 +42,13 @@ enum custom_keycodes {
|
||||
#define SC_ACLS LALT(KC_F4)
|
||||
#define SC_CCLS LCTL(KC_F4)
|
||||
|
||||
#define _______ KC_TRNS
|
||||
#define XXXXXXX KC_NO
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[LAYER_BASE] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_BSLS, MO(2), \
|
||||
KC_ESC, KC_TAB, KC_BSLS, KC_FN0, \
|
||||
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
|
||||
KC_P7, KC_P8, KC_P9, KC_PEQL, \
|
||||
KC_P4, KC_P5, KC_P6, KC_PPLS, \
|
||||
@@ -37,15 +57,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[LAYER_EDIT] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_SPC, _______, \
|
||||
TG(1), SC_PSTE, SC_REDO, SC_UNDO, \
|
||||
KC_FN1, SC_PSTE, SC_REDO, SC_UNDO, \
|
||||
KC_HOME, KC_UP, KC_PGUP, KC_LALT, \
|
||||
KC_LEFT, M_COPY, KC_RGHT, KC_LCTL, \
|
||||
KC_END, KC_DOWN, KC_PGDN, XXXXXXX, \
|
||||
KC_BSPC, KC_PENT, KC_DEL, M_SHFCT ),
|
||||
KC_BSPC, KC_PENT, KC_DEL, M_SHFCT),
|
||||
|
||||
[LAYER_FUNCTION] = LAYOUT( \
|
||||
BL_TOGG, BL_INC, BL_DEC, _______, \
|
||||
TG(1), _______, _______, _______, \
|
||||
KC_FN2, KC_FN3, KC_FN4, _______, \
|
||||
KC_FN1, _______, _______, _______, \
|
||||
_______, _______, _______, _______, \
|
||||
_______, _______, _______, _______, \
|
||||
_______, _______, _______, XXXXXXX, \
|
||||
@@ -54,46 +74,68 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
};
|
||||
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t * record) {
|
||||
const uint16_t PROGMEM fn_actions[] = {
|
||||
[0] = ACTION_LAYER_MOMENTARY(LAYER_FUNCTION),
|
||||
[1] = ACTION_LAYER_TOGGLE(LAYER_EDIT),
|
||||
[2] = ACTION_BACKLIGHT_TOGGLE(),
|
||||
[3] = ACTION_BACKLIGHT_INCREASE(),
|
||||
[4] = ACTION_BACKLIGHT_DECREASE(),
|
||||
[5] = ACTION_MACRO_TAP(MACRO_COPY_CUT),
|
||||
[6] = ACTION_MACRO_TAP(MACRO_SHIFT_CONTROL),
|
||||
[7] = ACTION_MACRO_TAP(MACRO_CONTROL_ALT),
|
||||
|
||||
};
|
||||
|
||||
|
||||
void action_function(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
// MACRODOWN only works in this function
|
||||
switch (keycode) {
|
||||
switch (id) {
|
||||
|
||||
case M_COPY:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LCTL);
|
||||
if (record->tap.count == 1) {
|
||||
register_code(KC_C);
|
||||
unregister_code(KC_C);
|
||||
} else if (record->tap.count == 2) {
|
||||
register_code(KC_X);
|
||||
unregister_code(KC_X);
|
||||
}
|
||||
unregister_code(KC_LCTL);
|
||||
case MACRO_COPY_CUT:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LCTL);
|
||||
if (record->tap.count == 1) {
|
||||
register_code(KC_C);
|
||||
unregister_code(KC_C);
|
||||
}
|
||||
else if (record->tap.count == 2) {
|
||||
register_code(KC_X);
|
||||
unregister_code(KC_X);
|
||||
}
|
||||
unregister_code(KC_LCTL);
|
||||
}
|
||||
break;
|
||||
|
||||
case MACRO_SHIFT_CONTROL:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count <= 2) register_mods(MOD_BIT(KC_LSFT));
|
||||
if (record->tap.count == 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count == 3) register_code(KC_PENT);;
|
||||
}
|
||||
else {
|
||||
unregister_mods(MOD_BIT(KC_LSFT) | MOD_BIT(KC_LCTL));
|
||||
unregister_code(KC_PENT);
|
||||
}
|
||||
break;
|
||||
|
||||
case MACRO_CONTROL_ALT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count < 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count >= 2) register_mods(MOD_BIT(KC_LALT));
|
||||
}
|
||||
else {
|
||||
unregister_mods(MOD_BIT(KC_LCTL) | MOD_BIT(KC_LALT));
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
case M_SHFCT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count <= 2) register_mods(MOD_BIT(KC_LSFT));
|
||||
if (record->tap.count == 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count == 3) register_code(KC_PENT);;
|
||||
} else {
|
||||
unregister_mods(MOD_BIT(KC_LSFT) | MOD_BIT(KC_LCTL));
|
||||
unregister_code(KC_PENT);
|
||||
}
|
||||
break;
|
||||
|
||||
case M_CTALT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count < 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count >= 2) register_mods(MOD_BIT(KC_LALT));
|
||||
} else {
|
||||
unregister_mods(MOD_BIT(KC_LCTL) | MOD_BIT(KC_LALT));
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return true;
|
||||
return MACRO_NONE;
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led)
|
||||
|
||||
@@ -1,18 +1,32 @@
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "arrow_pad.h"
|
||||
#include "led.h"
|
||||
|
||||
enum layers {
|
||||
LAYER_BASE,
|
||||
LAYER_EDIT,
|
||||
LAYER_FUNCTION
|
||||
};
|
||||
// This is the 21-key keypad to 2x11 element matrix mapping
|
||||
#define LAYOUT( \
|
||||
KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
|
||||
KM_NUM, KM_FSL, KM_AST, KM_MIN, \
|
||||
KM___7, KM___8, KM___9, ___PLS, \
|
||||
KM___4, KM___5, KM___6, KM_PLS, \
|
||||
KM___1, KM___2, KM___3, ___ENT, \
|
||||
KM___0, _____0, KM_DOT, KM_ENT \
|
||||
) { \
|
||||
{ KM_ESC, KM_TAB, KM_BSL, KM_ARR, KM___7, KM___8, KM___9, KM_PLS, KM___1, KM___2, KM___3, }, \
|
||||
{ KM_NUM, KM_FSL, KM_AST, KM_MIN, KM___4, KM___5, KM___6, KM_ENT, KC_NO, KM___0, KM_DOT, }, \
|
||||
}
|
||||
|
||||
enum custom_keycodes {
|
||||
M_COPY = SAFE_RANGE, // KC_FN5: MACRO_COPY_CUT
|
||||
M_SHFCT, // KC_FN6: MACRO_SHIFT_CONTROL
|
||||
M_CTALT // KC_FN7: MACRO_CONTROL_ALT
|
||||
};
|
||||
|
||||
#define LAYER_BASE 0
|
||||
#define LAYER_EDIT 1
|
||||
#define LAYER_FUNCTION 2
|
||||
|
||||
#define MACRO_COPY_CUT 0
|
||||
#define MACRO_SHIFT_CONTROL 1
|
||||
#define MACRO_CONTROL_ALT 2
|
||||
|
||||
#define M_COPY KC_FN5
|
||||
#define M_SHFCT KC_FN6
|
||||
#define M_CTALT KC_FN7
|
||||
|
||||
#define SC_UNDO LCTL(KC_Z)
|
||||
#define SC_REDO LCTL(KC_Y)
|
||||
@@ -25,75 +39,100 @@ enum custom_keycodes {
|
||||
#define SC_ACLS LALT(KC_F4)
|
||||
#define SC_CCLS LCTL(KC_F4)
|
||||
|
||||
#define _______ KC_TRNS
|
||||
#define XXXXXXX KC_NO
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[LAYER_BASE] = LAYOUT_pad21( \
|
||||
KC_ESC, KC_TAB, KC_BSLS, MO(2), \
|
||||
[LAYER_BASE] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_BSLS, KC_FN0, \
|
||||
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
|
||||
KC_P7, KC_P8, KC_P9, \
|
||||
KC_P7, KC_P8, KC_P9, XXXXXXX, \
|
||||
KC_P4, KC_P5, KC_P6, KC_PPLS, \
|
||||
KC_P1, KC_P2, KC_P3, \
|
||||
KC_P0, KC_PDOT, KC_PENT ),
|
||||
KC_P1, KC_P2, KC_P3, XXXXXXX, \
|
||||
KC_P0, XXXXXXX, KC_PDOT, KC_PENT ),
|
||||
|
||||
[LAYER_EDIT] = LAYOUT_pad21( \
|
||||
[LAYER_EDIT] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_SPC, _______, \
|
||||
TG(1), SC_PSTE, SC_REDO, SC_UNDO, \
|
||||
KC_HOME, KC_UP, KC_PGUP, \
|
||||
KC_FN1, SC_PSTE, SC_REDO, SC_UNDO, \
|
||||
KC_HOME, KC_UP, KC_PGUP, XXXXXXX, \
|
||||
KC_LEFT, M_COPY, KC_RGHT, M_CTALT, \
|
||||
KC_END, KC_DOWN, KC_PGDN, \
|
||||
KC_BSPC, KC_DEL, M_SHFCT),
|
||||
KC_END, KC_DOWN, KC_PGDN, XXXXXXX, \
|
||||
KC_BSPC, XXXXXXX, KC_DEL, M_SHFCT),
|
||||
|
||||
[LAYER_FUNCTION] = LAYOUT_pad21( \
|
||||
BL_TOGG, BL_INC, BL_DEC, _______, \
|
||||
TG(1), _______, _______, _______, \
|
||||
_______, _______, _______, \
|
||||
[LAYER_FUNCTION] = LAYOUT( \
|
||||
KC_FN2, KC_FN3, KC_FN4, _______, \
|
||||
KC_FN1, _______, _______, _______, \
|
||||
_______, _______, _______, XXXXXXX, \
|
||||
_______, _______, _______, _______, \
|
||||
_______, _______, _______, \
|
||||
RESET, _______, _______ ),
|
||||
_______, _______, _______, XXXXXXX, \
|
||||
RESET, XXXXXXX, _______, _______ ),
|
||||
|
||||
};
|
||||
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t * record) {
|
||||
const uint16_t PROGMEM fn_actions[] = {
|
||||
[0] = ACTION_LAYER_MOMENTARY(LAYER_FUNCTION),
|
||||
[1] = ACTION_LAYER_TOGGLE(LAYER_EDIT),
|
||||
[2] = ACTION_BACKLIGHT_TOGGLE(),
|
||||
[3] = ACTION_BACKLIGHT_INCREASE(),
|
||||
[4] = ACTION_BACKLIGHT_DECREASE(),
|
||||
[5] = ACTION_MACRO_TAP(MACRO_COPY_CUT),
|
||||
[6] = ACTION_MACRO_TAP(MACRO_SHIFT_CONTROL),
|
||||
[7] = ACTION_MACRO_TAP(MACRO_CONTROL_ALT),
|
||||
|
||||
};
|
||||
|
||||
|
||||
void action_function(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
// MACRODOWN only works in this function
|
||||
switch (keycode) {
|
||||
switch (id) {
|
||||
|
||||
case M_COPY:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LCTL);
|
||||
if (record->tap.count == 1) {
|
||||
register_code(KC_C);
|
||||
unregister_code(KC_C);
|
||||
} else if (record->tap.count == 2) {
|
||||
register_code(KC_X);
|
||||
unregister_code(KC_X);
|
||||
}
|
||||
unregister_code(KC_LCTL);
|
||||
case MACRO_COPY_CUT:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LCTL);
|
||||
if (record->tap.count == 1) {
|
||||
register_code(KC_C);
|
||||
unregister_code(KC_C);
|
||||
}
|
||||
else if (record->tap.count == 2) {
|
||||
register_code(KC_X);
|
||||
unregister_code(KC_X);
|
||||
}
|
||||
unregister_code(KC_LCTL);
|
||||
}
|
||||
break;
|
||||
|
||||
case MACRO_SHIFT_CONTROL:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count <= 2) register_mods(MOD_BIT(KC_LSFT));
|
||||
if (record->tap.count == 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count == 3) register_code(KC_PENT);;
|
||||
}
|
||||
else {
|
||||
unregister_mods(MOD_BIT(KC_LSFT) | MOD_BIT(KC_LCTL));
|
||||
unregister_code(KC_PENT);
|
||||
}
|
||||
break;
|
||||
|
||||
case MACRO_CONTROL_ALT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count < 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count >= 2) register_mods(MOD_BIT(KC_LALT));
|
||||
}
|
||||
else {
|
||||
unregister_mods(MOD_BIT(KC_LCTL) | MOD_BIT(KC_LALT));
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
case M_SHFCT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count <= 2) register_mods(MOD_BIT(KC_LSFT));
|
||||
if (record->tap.count == 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count == 3) register_code(KC_PENT);;
|
||||
} else {
|
||||
unregister_mods(MOD_BIT(KC_LSFT) | MOD_BIT(KC_LCTL));
|
||||
unregister_code(KC_PENT);
|
||||
}
|
||||
break;
|
||||
|
||||
case M_CTALT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count < 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count >= 2) register_mods(MOD_BIT(KC_LALT));
|
||||
} else {
|
||||
unregister_mods(MOD_BIT(KC_LCTL) | MOD_BIT(KC_LALT));
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return true;
|
||||
return MACRO_NONE;
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led)
|
||||
|
||||
@@ -1,18 +1,35 @@
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "arrow_pad.h"
|
||||
#include "led.h"
|
||||
|
||||
enum layers {
|
||||
LAYER_BASE,
|
||||
LAYER_EDIT,
|
||||
LAYER_FUNCTION
|
||||
};
|
||||
// This is the 21-key keypad to 2x11 element matrix mapping
|
||||
#define LAYOUT( \
|
||||
KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
|
||||
KM_NUM, KM_FSL, KM_AST, KM_MIN, \
|
||||
KM___7, KM___8, KM___9, KM_EQU, \
|
||||
KM___4, KM___5, KM___6, KM_PLS, \
|
||||
KM___1, KM___2, KM___3, ___ENT, \
|
||||
KM___0, _____0, KM_DOT, KM_ENT \
|
||||
) { \
|
||||
{ KM_ESC, KM_TAB, KM_BSL, KM_ARR }, \
|
||||
{ KM_NUM, KM_FSL, KM_AST, KM_MIN }, \
|
||||
{ KM___7, KM___8, KM___9, KM_EQU }, \
|
||||
{ KM___4, KM___5, KM___6, KM_PLS }, \
|
||||
{ KM___1, KM___2, KM___3, KC_NO }, \
|
||||
{ KM___0, KC_NO, KM_DOT, KM_ENT } \
|
||||
}
|
||||
|
||||
enum custom_keycodes {
|
||||
M_COPY = SAFE_RANGE, // KC_FN5: MACRO_COPY_CUT
|
||||
M_SHFCT, // KC_FN6: MACRO_SHIFT_CONTROL
|
||||
M_CTALT // KC_FN7: MACRO_CONTROL_ALT
|
||||
};
|
||||
#define LAYER_BASE 0
|
||||
#define LAYER_EDIT 1
|
||||
#define LAYER_FUNCTION 2
|
||||
|
||||
#define MACRO_COPY_CUT 0
|
||||
#define MACRO_SHIFT_CONTROL 1
|
||||
#define MACRO_CONTROL_ALT 2
|
||||
|
||||
#define M_COPY KC_FN5
|
||||
#define M_SHFCT KC_FN6
|
||||
#define M_CTALT KC_FN7
|
||||
|
||||
#define SC_UNDO LCTL(KC_Z)
|
||||
#define SC_REDO LCTL(KC_Y)
|
||||
@@ -25,10 +42,13 @@ enum custom_keycodes {
|
||||
#define SC_ACLS LALT(KC_F4)
|
||||
#define SC_CCLS LCTL(KC_F4)
|
||||
|
||||
#define _______ KC_TRNS
|
||||
#define XXXXXXX KC_NO
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[LAYER_BASE] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_BSLS, MO(2), \
|
||||
KC_ESC, KC_TAB, KC_BSLS, KC_FN0, \
|
||||
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
|
||||
KC_P7, KC_P8, KC_P9, KC_PEQL, \
|
||||
KC_P4, KC_P5, KC_P6, KC_PPLS, \
|
||||
@@ -37,15 +57,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[LAYER_EDIT] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_SPC, _______, \
|
||||
TG(1), SC_PSTE, SC_REDO, SC_UNDO, \
|
||||
KC_FN1, SC_PSTE, SC_REDO, SC_UNDO, \
|
||||
KC_HOME, KC_UP, KC_PGUP, KC_LALT, \
|
||||
KC_LEFT, M_COPY, KC_RGHT, KC_LCTL, \
|
||||
KC_END, KC_DOWN, KC_PGDN, XXXXXXX, \
|
||||
KC_BSPC, KC_PENT, KC_DEL, M_SHFCT ),
|
||||
KC_BSPC, KC_PENT, KC_DEL, M_SHFCT),
|
||||
|
||||
[LAYER_FUNCTION] = LAYOUT( \
|
||||
BL_TOGG, BL_INC, BL_DEC, _______, \
|
||||
TG(1), _______, _______, _______, \
|
||||
KC_FN2, KC_FN3, KC_FN4, _______, \
|
||||
KC_FN1, _______, _______, _______, \
|
||||
_______, _______, _______, _______, \
|
||||
_______, _______, _______, _______, \
|
||||
_______, _______, _______, XXXXXXX, \
|
||||
@@ -54,46 +74,68 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
};
|
||||
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t * record) {
|
||||
const uint16_t PROGMEM fn_actions[] = {
|
||||
[0] = ACTION_LAYER_MOMENTARY(LAYER_FUNCTION),
|
||||
[1] = ACTION_LAYER_TOGGLE(LAYER_EDIT),
|
||||
[2] = ACTION_BACKLIGHT_TOGGLE(),
|
||||
[3] = ACTION_BACKLIGHT_INCREASE(),
|
||||
[4] = ACTION_BACKLIGHT_DECREASE(),
|
||||
[5] = ACTION_MACRO_TAP(MACRO_COPY_CUT),
|
||||
[6] = ACTION_MACRO_TAP(MACRO_SHIFT_CONTROL),
|
||||
[7] = ACTION_MACRO_TAP(MACRO_CONTROL_ALT),
|
||||
|
||||
};
|
||||
|
||||
|
||||
void action_function(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
// MACRODOWN only works in this function
|
||||
switch (keycode) {
|
||||
switch (id) {
|
||||
|
||||
case M_COPY:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LCTL);
|
||||
if (record->tap.count == 1) {
|
||||
register_code(KC_C);
|
||||
unregister_code(KC_C);
|
||||
} else if (record->tap.count == 2) {
|
||||
register_code(KC_X);
|
||||
unregister_code(KC_X);
|
||||
}
|
||||
unregister_code(KC_LCTL);
|
||||
case MACRO_COPY_CUT:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LCTL);
|
||||
if (record->tap.count == 1) {
|
||||
register_code(KC_C);
|
||||
unregister_code(KC_C);
|
||||
}
|
||||
else if (record->tap.count == 2) {
|
||||
register_code(KC_X);
|
||||
unregister_code(KC_X);
|
||||
}
|
||||
unregister_code(KC_LCTL);
|
||||
}
|
||||
break;
|
||||
|
||||
case MACRO_SHIFT_CONTROL:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count <= 2) register_mods(MOD_BIT(KC_LSFT));
|
||||
if (record->tap.count == 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count == 3) register_code(KC_PENT);;
|
||||
}
|
||||
else {
|
||||
unregister_mods(MOD_BIT(KC_LSFT) | MOD_BIT(KC_LCTL));
|
||||
unregister_code(KC_PENT);
|
||||
}
|
||||
break;
|
||||
|
||||
case MACRO_CONTROL_ALT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count < 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count >= 2) register_mods(MOD_BIT(KC_LALT));
|
||||
}
|
||||
else {
|
||||
unregister_mods(MOD_BIT(KC_LCTL) | MOD_BIT(KC_LALT));
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
|
||||
case M_SHFCT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count <= 2) register_mods(MOD_BIT(KC_LSFT));
|
||||
if (record->tap.count == 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count == 3) register_code(KC_PENT);;
|
||||
} else {
|
||||
unregister_mods(MOD_BIT(KC_LSFT) | MOD_BIT(KC_LCTL));
|
||||
unregister_code(KC_PENT);
|
||||
}
|
||||
break;
|
||||
|
||||
case M_CTALT:
|
||||
if (record->event.pressed) {
|
||||
if (record->tap.count < 2) register_mods(MOD_BIT(KC_LCTL));
|
||||
if (record->tap.count >= 2) register_mods(MOD_BIT(KC_LALT));
|
||||
} else {
|
||||
unregister_mods(MOD_BIT(KC_LCTL) | MOD_BIT(KC_LALT));
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return true;
|
||||
return MACRO_NONE;
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led)
|
||||
|
||||
@@ -94,13 +94,13 @@ More info can be found on [GeekHack](https://geekhack.org/index.php?topic=73632.
|
||||
The second ArrowPad was a conversion from a 21-key Genovation keypad. It used a 2 row x 11 column matrix.
|
||||
|
||||
```
|
||||
#define LAYOUT_pad21( \
|
||||
#define KEYMAP( \
|
||||
KM_ESC, KM_TAB, KM_BSL, KM_ARR, \
|
||||
KM_NUM, KM_FSL, KM_AST, KM_MIN, \
|
||||
KM___7, KM___8, KM___9, \
|
||||
KM___7, KM___8, KM___9, ___PLS, \
|
||||
KM___4, KM___5, KM___6, KM_PLS, \
|
||||
KM___1, KM___2, KM___3, \
|
||||
KM___0, KM_DOT, KM_ENT \
|
||||
KM___1, KM___2, KM___3, ___ENT, \
|
||||
KM___0, _____0, KM_DOT, KM_ENT \
|
||||
) { \
|
||||
{ KM_ESC, KM_TAB, KM_BSL, KM_ARR, KM___7, KM___8, KM___9, KM_PLS, KM___1, KM___2, KM___3, }, \
|
||||
{ KM_NUM, KM_FSL, KM_AST, KM_MIN, KM___4, KM___5, KM___6, KM_ENT, KC_NO, KM___0, KM_DOT, }, \
|
||||
@@ -119,7 +119,7 @@ Download or clone the whole firmware and navigate to the keyboards/arrow_pad fol
|
||||
Depending on which keymap you would like to use, you will have to compile slightly differently.
|
||||
|
||||
### Default
|
||||
To build with the default keymap, simply run `make handwired/arrow_pad:default`.
|
||||
To build with the default keymap, simply run `make default`.
|
||||
|
||||
### Other Keymaps
|
||||
Several version of keymap are available in advance but you are recommended to define your favorite layout yourself. To define your own keymap create file named `<name>.c` in the keymaps folder, and see keymap document (you can find in top readme.md) and existent keymap files.
|
||||
@@ -127,7 +127,7 @@ Several version of keymap are available in advance but you are recommended to de
|
||||
To build the firmware binary hex file with a keymap just do `make` with a keymap like this:
|
||||
|
||||
```
|
||||
$ make handwired/arrow_pad:[default|pad_21|pad_24|<name>]
|
||||
$ make [default|pad_21|pad_24|<name>]
|
||||
```
|
||||
|
||||
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
SRC += pico/matrix.c
|
||||
SRC += pico/split_util.c
|
||||
SRC += pico/matrix.c \
|
||||
pico/split_util.c \
|
||||
ws2812.c
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
#undef TAPPING_FORCE_HOLD
|
||||
#undef TAPPING_TERM
|
||||
#define TAPPING_TERM 120
|
||||
#define SWAP_SCLN
|
||||
|
||||
// If you need more program area, try select and reduce rgblight modes to use.
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
|
||||
switch(keycode) {
|
||||
case KC_LOCK:
|
||||
if (record->event.pressed) {
|
||||
if (get_enable_kc_lang()) {
|
||||
if (edvorakjp_config.enable_kc_lang) {
|
||||
SEND_STRING( SS_LCTRL(SS_LSFT(SS_TAP(X_POWER))) );
|
||||
} else {
|
||||
SEND_STRING( SS_LGUI("l") );
|
||||
|
||||
@@ -5,7 +5,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_EDVORAK] = LAYOUT_kc(
|
||||
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
|
||||
LBRC,RBRC,COMM,DOT , Y , P , F , G , R , W , Q ,BSLS,
|
||||
LBRC,RBRC,COMM,DOT , P , Y , F , G , R , W , Q ,BSLS,
|
||||
//|----+----+----+----+----+----| |----+----+----+----+----+----|
|
||||
EQL , A , O , E , I , U , D , T , N , S , M ,MINS,
|
||||
//|----+----+----+----+----+----| |----+----+----+----+----+----|
|
||||
|
||||
@@ -7,7 +7,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
|
||||
GRV ,EXLM, AT ,HASH,DLR ,PERC, CIRC,AMPR,ASTR,LPRN,RPRN,BSPC,
|
||||
//|----+----+----+----+----+----| |----+----+----+----+----+----|
|
||||
LBRC,RBRC,COMM,DOT , Y , P , F , G , R , W , Q ,BSLS,
|
||||
LBRC,RBRC,COMM,DOT , P , Y , F , G , R , W , Q ,BSLS,
|
||||
//|----+----+----+----+----+----| |----+----+----+----+----+----|
|
||||
EQL , A , O , E , I , U , D , T , N , S , M ,MINS,
|
||||
//|----+----+----+----+----+----+----. ,----|----+----+----+----+----+----|
|
||||
|
||||
@@ -23,10 +23,15 @@ void render_status(struct CharacterMatrix *matrix) {
|
||||
|
||||
// Render to mode icon
|
||||
static char logo[][2][3] = {{{0x95,0x96,0},{0xb5,0xb6,0}},{{0x97,0x98,0},{0xb7,0xb8,0}}};
|
||||
int mode_number = get_enable_kc_lang() ? 0 : 1;
|
||||
matrix_write(matrix, logo[mode_number][0]);
|
||||
matrix_write(matrix, "\n");
|
||||
matrix_write(matrix, logo[mode_number][1]);
|
||||
if (edvorakjp_config.enable_kc_lang) {
|
||||
matrix_write(matrix, logo[0][0]);
|
||||
matrix_write_P(matrix, PSTR("\n"));
|
||||
matrix_write(matrix, logo[0][1]);
|
||||
} else {
|
||||
matrix_write(matrix, logo[1][0]);
|
||||
matrix_write_P(matrix, PSTR("\n"));
|
||||
matrix_write(matrix, logo[1][1]);
|
||||
}
|
||||
|
||||
// Define layers here, Have not worked out how to have text displayed for each layer. Copy down the number you see and add a case for it below
|
||||
char buf[40];
|
||||
@@ -58,7 +63,7 @@ void render_status(struct CharacterMatrix *matrix) {
|
||||
// Host Keyboard LED Status
|
||||
char led[40];
|
||||
snprintf(led, sizeof(led), "\n%s %s %s %s",
|
||||
get_enable_jp_extra_layer() && get_japanese_mode() ? "EXT" : " ",
|
||||
edvorakjp_config.enable_jp_extra_layer && japanese_mode ? "EXT" : " ",
|
||||
(host_keyboard_leds() & (1<<USB_LED_NUM_LOCK)) ? "NMLK" : " ",
|
||||
(host_keyboard_leds() & (1<<USB_LED_CAPS_LOCK)) ? "CAPS" : " ",
|
||||
(host_keyboard_leds() & (1<<USB_LED_SCROLL_LOCK)) ? "SCLK" : " ");
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
SRC += rev2/matrix.c
|
||||
SRC += rev2/split_util.c
|
||||
SRC += rev2/split_scomm.c
|
||||
SRC += ws2812.c
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
/* Copyright 2018 MechMerlin
|
||||
*
|
||||
* 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
|
||||
|
||||
// place overrides here
|
||||
@@ -1,67 +0,0 @@
|
||||
/* Copyright 2018 xAceOfSpaidsx
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
// Layer shorthand
|
||||
#define _QW 0
|
||||
#define _FN 1
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
/* QWERTY - based off xd75 default map with a couple modifications for my preference
|
||||
* .--------------------------------------------------------------------------------------------------------------------------------------.
|
||||
* | ESC | 1 | 2 | 3 | 4 | 5 | F2 | ` | F5 | 6 | 7 | 8 | 9 | 0 | BACKSP |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------|
|
||||
* | TAB | Q | W | E | R | T | - | \ | = | Y | U | I | O | P | ' |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+-----------------+--------|
|
||||
* | CAP LK | A | S | D | F | G | HOME | DEL | PG UP | H | J | K | L | ; | ENTER |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------------------------+--------|
|
||||
* | LSHIFT | Z | X | C | V | B | END | UP | PG DN | N | M | , | . | / | RSHIFT |
|
||||
* |--------+--------+--------+--------+--------+-----------------+--------+--------+--------+--------+-----------------+--------+--------|
|
||||
* | LCTRL | LGUI | LALT | FN | SPACE | SPACE | LEFT | DOWN | RIGHT | [ | ] | FN | RALT | RGUI | RCTRL |
|
||||
* '--------------------------------------------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
|
||||
[_QW] = LAYOUT_ortho_5x15( /* QWERTY */
|
||||
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_F2, KC_GRV, KC_F5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_MINS, KC_BSLS, KC_EQL, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_QUOT, \
|
||||
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_HOME, KC_DEL, KC_PGUP, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_ENT, \
|
||||
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_END, KC_UP, KC_PGDN, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, \
|
||||
KC_LCTL, KC_LGUI, KC_LALT, MO(_FN), KC_SPC, KC_SPC, KC_LEFT, KC_DOWN, KC_RGHT, KC_LBRC, KC_RBRC, MO(_FN), KC_RALT, KC_RGUI, KC_RCTL \
|
||||
),
|
||||
|
||||
/* FUNCTION Layer - removed the rgb hue saturation and vibrance for audio controls and added some functionality I use from other boards.
|
||||
* .--------------------------------------------------------------------------------------------------------------------------------------.
|
||||
* | F1 | F2 | F3 | F4 | F5 | F6 | NUM LK | P/ | P* | F7 | F8 | F9 | F10 | F11 | F12 |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | SELECT | CALC | UP | | | NEXT | P7 | P8 | P9 | - | | | PR SCR | SCR LK | PAUSE |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | PREV | LEFT | DOWN | RIGHT | DEL | PLAY | P4 | P5 | P6 | + | | RESET | | | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | VOL- | MUTE | VOL+ | APP | | STOP | P1 | P2 | P3 | PENT | | | | | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | | | RGB TG | FN | RGB RMD| RGB MD | P0 | | P. | PENT | PENT | FN | | | |
|
||||
* '--------------------------------------------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
|
||||
[_FN] = LAYOUT_ortho_5x15( /* FUNCTION */
|
||||
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_NLCK, KC_SLSH, KC_ASTR, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, \
|
||||
KC_MSEL, KC_CALC, KC_UP , _______, _______, KC_MNXT, KC_P7, KC_P8, KC_P9, KC_MINS, _______, _______, KC_PSCR, KC_SLCK, KC_PAUS, \
|
||||
KC_MPRV, KC_LEFT, KC_DOWN, KC_RGHT, KC_DEL , KC_MPLY, KC_P4, KC_P5, KC_P6, KC_PLUS, _______, RESET, _______, _______, _______, \
|
||||
KC_VOLD, KC_MUTE, KC_VOLU, KC_APP, _______, KC_MSTP, KC_P1, KC_P2, KC_P3, KC_PENT, _______, _______, _______, _______, _______, \
|
||||
_______, _______, RGB_TOG, MO(_FN), RGB_RMOD,RGB_MOD, KC_P0, _______, KC_PDOT, KC_PENT, KC_PENT, MO(_FN), _______, _______, _______ \
|
||||
),
|
||||
};
|
||||
@@ -1 +0,0 @@
|
||||
# Updated the keymap, based off XD75 default, to meet my needs. Refer to rules.mk to enable or disable rgb and other features.
|
||||
@@ -1,19 +0,0 @@
|
||||
# Copyright 2013 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/>.
|
||||
|
||||
#Had to disable the first 2 to get the firmware size down enough after enabling the rgb controls.
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
|
||||
@@ -79,5 +79,3 @@ BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
|
||||
LAYOUTS = ortho_5x15
|
||||
|
||||
@@ -79,7 +79,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_ADJUST] = LAYOUT_wrapper(
|
||||
KC_MAKE, _______, _______, _______, _______, _______, _________________ADJUST_R1_________________, KC_RST,
|
||||
VRSN, _________________ADJUST_L1_________________, KC_NUKE, _______, _______, _______, _______, EEP_RST,
|
||||
VRSN, _________________ADJUST_L1_________________, KC_NUKE, _______, _______, _______, _______, EPRM,
|
||||
_______, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, TG_MODS,
|
||||
_______, _________________ADJUST_L3_________________, TG_GAME, _______, _________________ADJUST_R3_________________, KC_MPLY,
|
||||
_______, _______, _______, _______, _______, _______
|
||||
|
||||
@@ -8,7 +8,7 @@ RGBLIGHT_ENABLE = yes
|
||||
AUDIO_ENABLE = yes
|
||||
NKRO_ENABLE = yes
|
||||
BACKLIGHT_ENABLE = no
|
||||
SWAP_HANDS_ENABLE = no
|
||||
SWAP_HANDS_ENABLE = yes
|
||||
|
||||
INDICATOR_LIGHTS = yes
|
||||
MACROS_ENABLED = no
|
||||
|
||||
@@ -26,6 +26,5 @@
|
||||
#define MOUSEKEY_WHEEL_TIME_TO_MAX 20
|
||||
|
||||
#define TAPPING_TERM 120
|
||||
#define SWAP_SCLN
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "action_layer.h"
|
||||
#include "eeconfig.h"
|
||||
|
||||
#include "edvorakjp.h"
|
||||
|
||||
enum custom_keycodes {
|
||||
@@ -29,7 +32,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
|
||||
GRV ,EXLM, AT ,HASH,DLR ,PERC, CIRC,AMPR,ASTR,LPRN,RPRN,BSPC,
|
||||
//|----+----+----+----+----+----| |----+----+----+----+----+----|
|
||||
LBRC,RBRC,COMM,DOT , Y , P , F , G , R , W , Q ,BSLS,
|
||||
LBRC,RBRC,COMM,DOT , P , Y , F , G , R , W , Q ,BSLS,
|
||||
//|----+----+----+----+----+----| |----+----+----+----+----+----|
|
||||
EQL , A , O , E , I , U , D , T , N , S , M ,MINS,
|
||||
//|----+----+----+----+----+----+----. ,----|----+----+----+----+----+----|
|
||||
@@ -131,7 +134,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
|
||||
switch(keycode) {
|
||||
case KC_LOCK:
|
||||
if (record->event.pressed) {
|
||||
if (get_enable_kc_lang()) {
|
||||
if (edvorakjp_config.enable_kc_lang) {
|
||||
SEND_STRING( SS_LCTRL(SS_LSFT(SS_TAP(X_POWER))) );
|
||||
} else {
|
||||
SEND_STRING( SS_LGUI("l") );
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "eeconfig.h"
|
||||
|
||||
extern keymap_config_t keymap_config;
|
||||
|
||||
// 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.
|
||||
|
||||
@@ -1,16 +1 @@
|
||||
#include "lets_split_eh.h"
|
||||
|
||||
#ifdef SWAP_HANDS_ENABLE
|
||||
__attribute__ ((weak))
|
||||
const keypos_t hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
{{0, 4}, {1, 4}, {2, 4}, {3, 4}, {4, 4}, {5, 4}},
|
||||
{{0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5}},
|
||||
{{0, 6}, {1, 6}, {2, 6}, {3, 6}, {4, 6}, {5, 6}},
|
||||
{{0, 7}, {1, 7}, {2, 7}, {3, 7}, {4, 7}, {5, 7}},
|
||||
{{0, 0}, {1, 0}, {2, 0}, {3, 0}, {4, 0}, {5, 0}},
|
||||
{{0, 1}, {1, 1}, {2, 1}, {3, 1}, {4, 1}, {5, 1}},
|
||||
{{0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2}, {5, 2}},
|
||||
{{0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3}},
|
||||
};
|
||||
#endif
|
||||
|
||||
@@ -67,6 +67,4 @@ SPLIT_KEYBOARD = yes
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
|
||||
LAYOUTS = ortho_4x12
|
||||
|
||||
DEFAULT_FOLDER = lets_split_eh/eh
|
||||
|
||||
@@ -1,189 +0,0 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
enum alt_keycodes {
|
||||
L_BRI = SAFE_RANGE, //LED Brightness Increase
|
||||
L_BRD, //LED Brightness Decrease
|
||||
L_PTN, //LED Pattern Select Next
|
||||
L_PTP, //LED Pattern Select Previous
|
||||
L_PSI, //LED Pattern Speed Increase
|
||||
L_PSD, //LED Pattern Speed Decrease
|
||||
L_T_MD, //LED Toggle Mode
|
||||
L_T_ONF, //LED Toggle On / Off
|
||||
L_ON, //LED On
|
||||
L_OFF, //LED Off
|
||||
L_T_BR, //LED Toggle Breath Effect
|
||||
L_T_PTD, //LED Toggle Scrolling Pattern Direction
|
||||
U_T_AUTO, //USB Extra Port Toggle Auto Detect / Always Active
|
||||
U_T_AGCR, //USB Toggle Automatic GCR control
|
||||
DBG_TOG, //DEBUG Toggle On / Off
|
||||
DBG_MTRX, //DEBUG Toggle Matrix Prints
|
||||
DBG_KBD, //DEBUG Toggle Keyboard Prints
|
||||
DBG_MOU, //DEBUG Toggle Mouse Prints
|
||||
MD_BOOT, //Restart into bootloader after hold timeout
|
||||
};
|
||||
|
||||
#define TG_NKRO MAGIC_TOGGLE_NKRO //Toggle 6KRO / NKRO mode
|
||||
|
||||
keymap_config_t keymap_config;
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = 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_DEL, \
|
||||
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_HOME, \
|
||||
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_PGUP, \
|
||||
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_PGDN, \
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT \
|
||||
),
|
||||
[1] = LAYOUT(
|
||||
KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS, KC_MUTE, \
|
||||
L_T_BR, L_PSD, L_BRI, L_PSI, KC_TRNS, KC_TRNS, KC_TRNS, U_T_AUTO,U_T_AGCR,KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_TRNS, KC_END, \
|
||||
L_T_PTD, L_PTP, L_BRD, L_PTN, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLU, \
|
||||
KC_TRNS, L_T_MD, L_T_ONF, KC_TRNS, KC_TRNS, MD_BOOT, TG_NKRO, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PGUP, KC_VOLD, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PGDN, KC_END \
|
||||
),
|
||||
/*
|
||||
[X] = LAYOUT(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS \
|
||||
),
|
||||
*/
|
||||
};
|
||||
|
||||
// Runs just one time when the keyboard initializes.
|
||||
void matrix_init_user(void) {
|
||||
};
|
||||
|
||||
// Runs constantly in the background, in a loop.
|
||||
void matrix_scan_user(void) {
|
||||
};
|
||||
|
||||
#define MODS_SHIFT (keyboard_report->mods & MOD_BIT(KC_LSHIFT) || keyboard_report->mods & MOD_BIT(KC_RSHIFT))
|
||||
#define MODS_CTRL (keyboard_report->mods & MOD_BIT(KC_LCTL) || keyboard_report->mods & MOD_BIT(KC_RCTRL))
|
||||
#define MODS_ALT (keyboard_report->mods & MOD_BIT(KC_LALT) || keyboard_report->mods & MOD_BIT(KC_RALT))
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
static uint32_t key_timer;
|
||||
|
||||
switch (keycode) {
|
||||
case L_BRI:
|
||||
if (record->event.pressed) {
|
||||
if (LED_GCR_STEP > LED_GCR_MAX - gcr_desired) gcr_desired = LED_GCR_MAX;
|
||||
else gcr_desired += LED_GCR_STEP;
|
||||
if (led_animation_breathing) gcr_breathe = gcr_desired;
|
||||
}
|
||||
return false;
|
||||
case L_BRD:
|
||||
if (record->event.pressed) {
|
||||
if (LED_GCR_STEP > gcr_desired) gcr_desired = 0;
|
||||
else gcr_desired -= LED_GCR_STEP;
|
||||
if (led_animation_breathing) gcr_breathe = gcr_desired;
|
||||
}
|
||||
return false;
|
||||
case L_PTN:
|
||||
if (record->event.pressed) {
|
||||
if (led_animation_id == led_setups_count - 1) led_animation_id = 0;
|
||||
else led_animation_id++;
|
||||
}
|
||||
return false;
|
||||
case L_PTP:
|
||||
if (record->event.pressed) {
|
||||
if (led_animation_id == 0) led_animation_id = led_setups_count - 1;
|
||||
else led_animation_id--;
|
||||
}
|
||||
return false;
|
||||
case L_PSI:
|
||||
if (record->event.pressed) {
|
||||
led_animation_speed += ANIMATION_SPEED_STEP;
|
||||
}
|
||||
return false;
|
||||
case L_PSD:
|
||||
if (record->event.pressed) {
|
||||
led_animation_speed -= ANIMATION_SPEED_STEP;
|
||||
if (led_animation_speed < 0) led_animation_speed = 0;
|
||||
}
|
||||
return false;
|
||||
case L_T_MD:
|
||||
if (record->event.pressed) {
|
||||
led_lighting_mode++;
|
||||
if (led_lighting_mode > LED_MODE_MAX_INDEX) led_lighting_mode = LED_MODE_NORMAL;
|
||||
}
|
||||
return false;
|
||||
case L_T_ONF:
|
||||
if (record->event.pressed) {
|
||||
led_enabled = !led_enabled;
|
||||
I2C3733_Control_Set(led_enabled);
|
||||
}
|
||||
return false;
|
||||
case L_ON:
|
||||
if (record->event.pressed) {
|
||||
led_enabled = 1;
|
||||
I2C3733_Control_Set(led_enabled);
|
||||
}
|
||||
return false;
|
||||
case L_OFF:
|
||||
if (record->event.pressed) {
|
||||
led_enabled = 0;
|
||||
I2C3733_Control_Set(led_enabled);
|
||||
}
|
||||
return false;
|
||||
case L_T_BR:
|
||||
if (record->event.pressed) {
|
||||
led_animation_breathing = !led_animation_breathing;
|
||||
if (led_animation_breathing) {
|
||||
gcr_breathe = gcr_desired;
|
||||
led_animation_breathe_cur = BREATHE_MIN_STEP;
|
||||
breathe_dir = 1;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
case L_T_PTD:
|
||||
if (record->event.pressed) {
|
||||
led_animation_direction = !led_animation_direction;
|
||||
}
|
||||
return false;
|
||||
case U_T_AUTO:
|
||||
if (record->event.pressed && MODS_SHIFT && MODS_CTRL) {
|
||||
TOGGLE_FLAG_AND_PRINT(usb_extra_manual, "USB extra port manual mode");
|
||||
}
|
||||
return false;
|
||||
case U_T_AGCR:
|
||||
if (record->event.pressed && MODS_SHIFT && MODS_CTRL) {
|
||||
TOGGLE_FLAG_AND_PRINT(usb_gcr_auto, "USB GCR auto mode");
|
||||
}
|
||||
return false;
|
||||
case DBG_TOG:
|
||||
if (record->event.pressed) {
|
||||
TOGGLE_FLAG_AND_PRINT(debug_enable, "Debug mode");
|
||||
}
|
||||
return false;
|
||||
case DBG_MTRX:
|
||||
if (record->event.pressed) {
|
||||
TOGGLE_FLAG_AND_PRINT(debug_matrix, "Debug matrix");
|
||||
}
|
||||
return false;
|
||||
case DBG_KBD:
|
||||
if (record->event.pressed) {
|
||||
TOGGLE_FLAG_AND_PRINT(debug_keyboard, "Debug keyboard");
|
||||
}
|
||||
return false;
|
||||
case DBG_MOU:
|
||||
if (record->event.pressed) {
|
||||
TOGGLE_FLAG_AND_PRINT(debug_mouse, "Debug mouse");
|
||||
}
|
||||
return false;
|
||||
case MD_BOOT:
|
||||
if (record->event.pressed) {
|
||||
key_timer = timer_read32();
|
||||
} else {
|
||||
if (timer_elapsed32(key_timer) >= 500) {
|
||||
reset_keyboard();
|
||||
}
|
||||
}
|
||||
return false;
|
||||
default:
|
||||
return true; //Process all other keycodes normally
|
||||
}
|
||||
}
|
||||
@@ -91,7 +91,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_ADJUST] = LAYOUT_wrapper(\
|
||||
KC_MAKE, _________________ADJUST_L1_________________, _________________ADJUST_R1_________________, KC_RESET,
|
||||
VRSN, _________________ADJUST_L2_________________, _______, _______, _______, KC_NUKE, _________________ADJUST_R2_________________, EEP_RST,
|
||||
VRSN, _________________ADJUST_L2_________________, _______, _______, _______, KC_NUKE, _________________ADJUST_R2_________________, EPRM,
|
||||
TG_MODS, _________________ADJUST_L3_________________, _______, _______, _______, _______, _______, _______, _________________ADJUST_R3_________________, KC_MPLY
|
||||
)
|
||||
};
|
||||
|
||||
@@ -46,14 +46,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | Shift| Z | X | C | V | B | N | M | , | . | / |Shift |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | Ctrl | | LGUI | Alt |Lower | SPC | Enter|Raise |Point.| | LOCK | Ctrl |
|
||||
* | Ctrl | | LGUI | Alt |Lower | SPC | Enter|Raise |Point.| | LOCK | |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_QWERTY] = LAYOUT_planck_grid(
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
|
||||
KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
|
||||
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_LCTL, _______, KC_LGUI, KC_LALT, LOWER, KC_SPC, KC_ENT, RAISE, PT, _______, LOCK, KC_RCTL
|
||||
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_LCTL, _______, KC_LGUI, KC_LALT, LOWER, KC_SPC, KC_ENT, RAISE, PT, _______, LOCK, _______
|
||||
),
|
||||
|
||||
/* Lower
|
||||
|
||||
@@ -35,19 +35,6 @@ enum planck_layers {
|
||||
#define WM_W LALT(LGUI(KC_LEFT))
|
||||
#define WM_CNTR LALT(LGUI(KC_C))
|
||||
|
||||
#define SFT_INS LSFT(KC_INS)
|
||||
|
||||
// Unicode
|
||||
#ifdef UNICODEMAP_ENABLE
|
||||
enum unicode_name {
|
||||
IBANG // ‽
|
||||
};
|
||||
|
||||
const uint32_t PROGMEM unicode_map[] = {
|
||||
[IBANG] = 0x0203D // ‽
|
||||
};
|
||||
#endif // UNICODEMAP_ENABLE
|
||||
|
||||
// Custom key codes
|
||||
enum planck_keycodes {
|
||||
QWERTY = SAFE_RANGE,
|
||||
@@ -94,7 +81,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* window ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
|
||||
* switcher │ │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ │
|
||||
* ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
|
||||
* │ │ - │ + │ ` │SFTIN│ : │ | │ ‽ │ , │ . │ \ │ │
|
||||
* │ │ - │ + │ ` │ | │ : │ │ │ , │ . │ \ │ │
|
||||
* ├─────┼─────┼─────┼─────┼─────┼─────┴─────┼─────┼─────┼─────┼─────┼─────┤
|
||||
* │ │ │ │ │ │ Backspace │ │ │ │ │ │
|
||||
* └─────┴─────┴─────┴─────┴─────┴───────────┴─────┴─────┴─────┴─────┴─────┘
|
||||
@@ -102,8 +89,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[LOWER_LAYER] = LAYOUT_planck_grid(
|
||||
KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, S(KC_3),
|
||||
_______, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, _______,
|
||||
_______, KC_MINS, KC_PLUS, KC_GRV, SFT_INS, KC_COLN, KC_PIPE, X(IBANG), KC_COMM, KC_DOT, KC_BSLS, _______,
|
||||
_______, _______, _______, _______, _______, KC_BSPC, KC_BSPC, _______, _______, _______, _______, _______
|
||||
_______, KC_MINS, KC_PLUS, KC_GRV, KC_PIPE, KC_COLN, XXXXXXX, XXXXXXX, KC_COMM, KC_DOT, KC_BSLS, _______,
|
||||
_______, _______, _______, _______, _______, KC_BSPC, KC_BSPC, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
/* Symbol layer
|
||||
@@ -112,7 +99,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
|
||||
* │ │ ! │ @ │ # │ $ │ % │ ^ │ & │ * │ ' │ " │ │ \
|
||||
* ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤ |-- Mostly shifted version
|
||||
* │ │ _ │ = │ ~ │SFTIN│ : │ | │ │ , │ . │ / │ │ / of lower layer
|
||||
* │ │ _ │ = │ ~ │ | │ : │ │ │ , │ . │ / │ │ / of lower layer
|
||||
* ├─────┼─────┼─────┼─────┼─────┼─────┴─────┼─────┼─────┼─────┼─────┼─────┤
|
||||
* │ │ │ │ │ │ Delete │ │ │ │ │ │
|
||||
* └─────┴─────┴─────┴─────┴─────┴───────────┴─────┴─────┴─────┴─────┴─────┘
|
||||
@@ -120,7 +107,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[RAISE_LAYER] = LAYOUT_planck_grid(
|
||||
S(KC_GRV), KC_F11, KC_F12, KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, S(KC_3),
|
||||
_______, S(KC_1), S(KC_2), S(KC_3), S(KC_4), S(KC_5), S(KC_6), S(KC_7), S(KC_8), KC_QUOT, S(KC_QUOT), _______,
|
||||
_______, KC_UNDS, KC_EQL, KC_TILD, SFT_INS, KC_COLN, KC_PIPE, XXXXXXX, KC_COMM, KC_DOT, KC_SLSH, _______,
|
||||
_______, KC_UNDS, KC_EQL, KC_TILD, KC_PIPE, KC_COLN, XXXXXXX, XXXXXXX, KC_COMM, KC_DOT, KC_SLSH, _______,
|
||||
_______, _______, _______, _______, _______, KC_DEL, KC_DEL, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
@@ -254,10 +241,6 @@ void plover_lookup(void) {
|
||||
unregister_code(PV_RG);
|
||||
}
|
||||
|
||||
void matrix_init_user(void) {
|
||||
set_unicode_input_mode(UC_LNX);
|
||||
};
|
||||
|
||||
uint32_t layer_state_set_user(uint32_t state) {
|
||||
return update_tri_layer_state(state, LOWER_LAYER, RAISE_LAYER, ADJUST_LAYER);
|
||||
}
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
|
||||
CONSOLE_ENABLE = no # Console for debug
|
||||
COMMAND_ENABLE = no # Disable shift combination, which conflicts with shift-parens
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys (disabled to save space)
|
||||
NKRO_ENABLE = no # N-key rollover required for use as a steno board
|
||||
AUDIO_ENABLE = yes # Audio output on port C6
|
||||
UNICODEMAP_ENABLE = yes # Enable extended unicode
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
|
||||
CONSOLE_ENABLE = no # Console for debug
|
||||
COMMAND_ENABLE = no # Disable shift combination, which conflicts with shift-parens
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys (disabled to save space)
|
||||
NKRO_ENABLE = no # N-key rollover required for use as a steno board
|
||||
AUDIO_ENABLE = yes # Audio output on port C6
|
||||
|
||||
@@ -2,41 +2,8 @@
|
||||
SRC = matrix.c
|
||||
LAYOUTS += ortho_4x12
|
||||
|
||||
## chip/board settings
|
||||
# - the next two should match the directories in
|
||||
# <chibios>/os/hal/ports/$(MCU_FAMILY)/$(MCU_SERIES)
|
||||
MCU_FAMILY = STM32
|
||||
MCU_SERIES = STM32F3xx
|
||||
|
||||
# Linker script to use
|
||||
# - it should exist either in <chibios>/os/common/ports/ARMCMx/compilers/GCC/ld/
|
||||
# or <this_dir>/ld/
|
||||
MCU_LDSCRIPT = STM32F303xC
|
||||
|
||||
# Startup code to use
|
||||
# - it should exist in <chibios>/os/common/startup/ARMCMx/compilers/GCC/mk/
|
||||
MCU_STARTUP = stm32f3xx
|
||||
|
||||
# Board: it should exist either in <chibios>/os/hal/boards/
|
||||
# or <this_dir>/boards
|
||||
BOARD = GENERIC_STM32_F303XC
|
||||
|
||||
# Cortex version
|
||||
MCU = cortex-m4
|
||||
|
||||
# ARM version, CORTEX-M0/M1 are 6, CORTEX-M3/M4/M7 are 7
|
||||
ARMV = 7
|
||||
|
||||
USE_FPU = yes
|
||||
|
||||
# Vector table for application
|
||||
# 0x00000000-0x00001000 area is occupied by bootlaoder.*/
|
||||
# The CORTEX_VTOR... is needed only for MCHCK/Infinity KB
|
||||
# OPT_DEFS = -DCORTEX_VTOR_INIT=0x08005000
|
||||
OPT_DEFS =
|
||||
|
||||
# Options to pass to dfu-util when flashing
|
||||
DFU_ARGS = -d 0483:df11 -a 0 -s 0x08000000:leave
|
||||
MCU = STM32F303
|
||||
|
||||
# Build Options
|
||||
# comment out to disable the options.
|
||||
|
||||
@@ -1,39 +1,6 @@
|
||||
# MCU name
|
||||
#MCU = at90usb1287
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Bootloader
|
||||
# This definition is optional, and if your keyboard supports multiple bootloaders of
|
||||
# different sizes, comment this out, and the correct address will be loaded
|
||||
|
||||
@@ -33,7 +33,6 @@
|
||||
#define MATRIX_ROW_PINS { B9 }
|
||||
#define MATRIX_COL_PINS { B0 }
|
||||
|
||||
|
||||
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
|
||||
#define DEBOUNCE 6
|
||||
|
||||
|
||||
@@ -1,41 +0,0 @@
|
||||
/*
|
||||
This is the c configuration file for the keymap
|
||||
|
||||
Copyright 2012 Jun Wako <wakojun@gmail.com>
|
||||
Copyright 2015 Jack Humbert
|
||||
Copyright 2018 Danny Nguyen <danny@keeb.io>
|
||||
|
||||
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
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
|
||||
#define USE_SERIAL
|
||||
// #define USE_I2C
|
||||
|
||||
#define TAPPING_TERM 500
|
||||
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define PERMISSIVE_HOLD
|
||||
#define FORCE_NKRO
|
||||
#define RETRO_TAPPING
|
||||
|
||||
#define TAPPING_TOGGLE 1
|
||||
|
||||
#define NO_ACTION_MACRO
|
||||
#define NO_ACTION_FUNCTION
|
||||
|
||||
#define RGBLIGHT_SLEEP
|
||||
@@ -1,33 +0,0 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
extern keymap_config_t keymap_config;
|
||||
|
||||
// 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 _BASE 0
|
||||
#define _FN1 1
|
||||
|
||||
enum custom_keycodes {
|
||||
QWERTY = SAFE_RANGE,
|
||||
};
|
||||
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[_BASE] = LAYOUT_65(
|
||||
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, XXXXXXX, KC_BSPC, KC_HOME, \
|
||||
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_END, \
|
||||
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_DEL, \
|
||||
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_INS, \
|
||||
KC_LCTL, KC_LGUI, KC_LALT, LT(_FN1,KC_SPC),KC_SPC, KC_SPC, XXXXXXX, KC_RALT, KC_RGUI, XXXXXXX, KC_APP, KC_RCTL, TT(_FN1)
|
||||
),
|
||||
|
||||
[_FN1] = LAYOUT_65(
|
||||
KC_TILD, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, XXXXXXX, KC_BSPC, KC_PGUP, \
|
||||
_______, _______, KC_UP, _______, _______, _______, _______, KC_P7, KC_P8, KC_P9, _______, _______, _______, _______, KC_PGDN, \
|
||||
_______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, KC_P4, KC_P5, KC_P6, _______, _______, _______, _______, \
|
||||
_______, RGB_MOD, RGB_HUI, RGB_HUD, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, \
|
||||
_______, _______, _______, _______, _______, KC_P0, XXXXXXX, _______, _______, XXXXXXX, _______, _______, _______
|
||||
)
|
||||
};
|
||||
@@ -1,22 +0,0 @@
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
# Build Options
|
||||
# change to "no" to disable the options, or define them in the Makefile in
|
||||
# the appropriate keymap folder that will get included automatically
|
||||
#
|
||||
BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
|
||||
MIDI_ENABLE = no # MIDI controls
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
UNICODE_ENABLE = yes # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
|
||||
SPLIT_KEYBOARD = yes
|
||||
@@ -18,10 +18,12 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#pragma once
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
#define USE_SERIAL
|
||||
// #define USE_I2C
|
||||
|
||||
// #define USE_SERIAL
|
||||
#define USE_I2C
|
||||
|
||||
/* Select hand configuration */
|
||||
|
||||
#define MASTER_LEFT
|
||||
// #define MASTER_RIGHT
|
||||
// #define EE_HANDS
|
||||
|
||||
@@ -18,10 +18,12 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#pragma once
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
|
||||
#define USE_SERIAL
|
||||
// #define USE_I2C
|
||||
|
||||
/* Select hand configuration */
|
||||
|
||||
#define MASTER_LEFT
|
||||
// #define MASTER_RIGHT
|
||||
// #define EE_HANDS
|
||||
|
||||
@@ -18,12 +18,14 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#pragma once
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
#define USE_SERIAL
|
||||
// #define USE_I2C
|
||||
|
||||
// #define USE_SERIAL
|
||||
#define USE_I2C
|
||||
|
||||
/* Select hand configuration */
|
||||
|
||||
// #define MASTER_LEFT
|
||||
#define MASTER_LEFT
|
||||
// #define MASTER_RIGHT
|
||||
// #define EE_HANDS
|
||||
|
||||
#undef RGBLED_NUM
|
||||
|
||||
@@ -18,10 +18,12 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#pragma once
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
#define USE_SERIAL
|
||||
// #define USE_I2C
|
||||
|
||||
// #define USE_SERIAL
|
||||
#define USE_I2C
|
||||
|
||||
/* Select hand configuration */
|
||||
|
||||
#define MASTER_LEFT
|
||||
// #define MASTER_RIGHT
|
||||
// #define EE_HANDS
|
||||
|
||||
@@ -17,14 +17,16 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#pragma once
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
|
||||
/* Change the default tapping toggle value (normally 5) */
|
||||
#define TAPPING_TOGGLE 2
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
#define USE_SERIAL
|
||||
//#define USE_I2C
|
||||
|
||||
/* Select hand configuration */
|
||||
|
||||
#define MASTER_LEFT
|
||||
// #define MASTER_RIGHT
|
||||
// #define EE_HANDS
|
||||
|
||||
@@ -66,7 +66,9 @@ UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
|
||||
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
|
||||
SUBPROJECT_rev1 = yes
|
||||
USE_I2C = yes
|
||||
|
||||
SPLIT_KEYBOARD = yes
|
||||
|
||||
|
||||
@@ -24,24 +24,22 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x6063
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER Ortholinear Keyboards
|
||||
#define PRODUCT The Subatomic Keyboard
|
||||
#define MANUFACTURER OLKB
|
||||
#define PRODUCT Subatomic
|
||||
#define DESCRIPTION A compact ortholinear keyboard
|
||||
|
||||
/* key matrix size */
|
||||
#define MATRIX_ROWS 5
|
||||
#define MATRIX_COLS 14
|
||||
#define MATRIX_ROWS 10
|
||||
#define MATRIX_COLS 8
|
||||
|
||||
/* Planck PCB default pin-out */
|
||||
#define MATRIX_ROW_PINS { D2, D5, B5, B6, D3 }
|
||||
#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7, C6, C5 }
|
||||
#define MATRIX_ROW_PINS { A10, A9, A8, B15, C13, C14, C15, A2, A3, A6 }
|
||||
#define MATRIX_COL_PINS { B11, B10, B2, B1, A7, B0, B9, B8 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
// #define AUDIO_VOICES
|
||||
// #define C6_AUDIO
|
||||
|
||||
#define BACKLIGHT_PIN B7
|
||||
|
||||
/* COL2ROW or ROW2COL */
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
#ifndef CONFIG_USER_H
|
||||
#define CONFIG_USER_H
|
||||
|
||||
#include "../../config.h"
|
||||
|
||||
/*
|
||||
* MIDI options
|
||||
*/
|
||||
|
||||
/* Prevent use of disabled MIDI features in the keymap */
|
||||
//#define MIDI_ENABLE_STRICT 1
|
||||
|
||||
/* enable basic MIDI features:
|
||||
- MIDI notes can be sent when in Music mode is on
|
||||
*/
|
||||
#define MIDI_BASIC
|
||||
|
||||
/* enable advanced MIDI features:
|
||||
- MIDI notes can be added to the keymap
|
||||
- Octave shift and transpose
|
||||
- Virtual sustain, portamento, and modulation wheel
|
||||
- etc.
|
||||
*/
|
||||
//#define MIDI_ADVANCED
|
||||
|
||||
/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
|
||||
//#define MIDI_TONE_KEYCODE_OCTAVES 2
|
||||
|
||||
#endif
|
||||
@@ -44,13 +44,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | Pg Dn| Brite| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up | Right| \ |
|
||||
* `-------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_QWERTY] = {
|
||||
{KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_TRNS},
|
||||
{KC_TRNS, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_TRNS},
|
||||
{KC_TRNS, KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_TRNS},
|
||||
{KC_TRNS, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT, KC_TRNS},
|
||||
{KC_TRNS, BACKLIT, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_TRNS}
|
||||
},
|
||||
[_QWERTY] = LAYOUT_ortho_5x14(
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL,
|
||||
KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
|
||||
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT,
|
||||
BACKLIT, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
||||
),
|
||||
|
||||
/* Colemak
|
||||
* ,-------------------------------------------------------------------------------------------------.
|
||||
@@ -65,13 +65,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | Pg Dn| Brite| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up | Right| \ |
|
||||
* `-------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_COLEMAK] = {
|
||||
{KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_TRNS},
|
||||
{KC_TRNS, KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_DEL, KC_TRNS},
|
||||
{KC_TRNS, KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT, KC_TRNS},
|
||||
{KC_TRNS, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT, KC_TRNS},
|
||||
{KC_TRNS, BACKLIT, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_TRNS}
|
||||
},
|
||||
[_COLEMAK] = LAYOUT_ortho_5x14(
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
|
||||
KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_DEL,
|
||||
KC_ESC, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT,
|
||||
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT,
|
||||
BACKLIT, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
||||
),
|
||||
|
||||
/* Dvorak
|
||||
* ,-------------------------------------------------------------------------------------------------.
|
||||
@@ -86,13 +86,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | Pg Dn| Brite| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up | Right| \ |
|
||||
* `-------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_DVORAK] = {
|
||||
{KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_TRNS},
|
||||
{KC_TRNS, KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_DEL, KC_TRNS},
|
||||
{KC_TRNS, KC_ESC, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH, KC_TRNS},
|
||||
{KC_TRNS, KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_ENT, KC_TRNS},
|
||||
{KC_TRNS, BACKLIT, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_TRNS}
|
||||
},
|
||||
[_DVORAK] = LAYOUT_ortho_5x14(
|
||||
KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_TRNS,
|
||||
KC_TRNS, KC_TAB, KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_DEL, KC_TRNS,
|
||||
KC_TRNS, KC_ESC, KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_SLSH, KC_TRNS,
|
||||
KC_TRNS, KC_LSFT, KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_ENT, KC_TRNS,
|
||||
KC_TRNS, BACKLIT, KC_LCTL, KC_LALT, KC_LGUI, LOWER, KC_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_TRNS
|
||||
),
|
||||
|
||||
/* Lower
|
||||
* ,-------------------------------------------------------------------------------------------------.
|
||||
@@ -107,13 +107,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | | | | | | | | | Next | Vol- | Vol+ | Play | |
|
||||
* `-------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_LOWER] = {
|
||||
{KC_TRNS, KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, KC_TRNS},
|
||||
{KC_TRNS, KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_DEL, KC_TRNS},
|
||||
{KC_TRNS, KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, KC_TRNS},
|
||||
{KC_TRNS, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______,KC_TRNS},
|
||||
{KC_TRNS, _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY, KC_TRNS}
|
||||
},
|
||||
[_LOWER] = LAYOUT_ortho_5x14(
|
||||
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC,
|
||||
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_DEL,
|
||||
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE,
|
||||
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F11, KC_F12,S(KC_NUHS),S(KC_NUBS),_______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY
|
||||
),
|
||||
|
||||
/* Raise
|
||||
* ,-------------------------------------------------------------------------------------------------.
|
||||
@@ -128,13 +128,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | | | | | | | | | Next | Vol- | Vol+ | | Play |
|
||||
* `-------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_RAISE] = {
|
||||
{KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, KC_TRNS},
|
||||
{KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_DEL, KC_TRNS},
|
||||
{KC_TRNS, KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, KC_TRNS},
|
||||
{KC_TRNS, _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______, KC_TRNS},
|
||||
{KC_TRNS, _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY, KC_TRNS}
|
||||
},
|
||||
[_RAISE] = LAYOUT_ortho_5x14(
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_DEL,
|
||||
KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS,
|
||||
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_F11, KC_F12, KC_NUHS, KC_NUBS, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY
|
||||
),
|
||||
|
||||
/* Adjust (Lower + Raise)
|
||||
* ,-------------------------------------------------------------------------------------------------.
|
||||
@@ -149,13 +149,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | | | | | | | | | | | | | |
|
||||
* `-------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_ADJUST] = {
|
||||
{KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_TRNS},
|
||||
{KC_TRNS, _______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL, KC_TRNS},
|
||||
{KC_TRNS, _______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, _______, _______, KC_TRNS},
|
||||
{KC_TRNS, _______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______, KC_TRNS},
|
||||
{KC_TRNS, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_TRNS}
|
||||
}
|
||||
[_ADJUST] = LAYOUT_ortho_5x14(
|
||||
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,
|
||||
_______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL,
|
||||
_______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, _______, _______,
|
||||
_______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
)
|
||||
|
||||
|
||||
};
|
||||
|
||||
@@ -1,69 +1,22 @@
|
||||
# project specific files
|
||||
#SRC = matrix.c
|
||||
|
||||
|
||||
# MCU name
|
||||
MCU = at90usb1286
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
|
||||
# Boot Section Size in *bytes*
|
||||
# Teensy halfKay 512
|
||||
# Teensy++ halfKay 1024
|
||||
# Atmel DFU loader 4096
|
||||
# LUFA bootloader 4096
|
||||
# USBaspLoader 2048
|
||||
OPT_DEFS += -DBOOTLOADER_SIZE=8192
|
||||
# Cortex version
|
||||
MCU = STM32F303
|
||||
|
||||
# Build Options
|
||||
# change to "no" to disable the options, or define them in the Makefile in
|
||||
# the appropriate keymap folder that will get included automatically
|
||||
# comment out to disable the options.
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
|
||||
MIDI_ENABLE = yes # MIDI controls
|
||||
AUDIO_ENABLE = yes # Audio output on port C6
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight.
|
||||
API_SYSEX_ENABLE = no
|
||||
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
BACKLIGHT_ENABLE = no
|
||||
BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration
|
||||
## (Note that for BOOTMAGIC on Teensy LC you have to use a custom .ld script.)
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control
|
||||
CONSOLE_ENABLE = yes # Console for debug
|
||||
COMMAND_ENABLE = yes # Commands for debug and configuration
|
||||
#SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
|
||||
NKRO_ENABLE = yes # USB Nkey Rollover
|
||||
#CUSTOM_MATRIX = yes # Custom matrix file
|
||||
AUDIO_ENABLE = yes
|
||||
RGBLIGHT_ENABLE = no
|
||||
# SERIAL_LINK_ENABLE = yes
|
||||
|
||||
@@ -3,4 +3,25 @@
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
#endif
|
||||
|
||||
#define LAYOUT_ortho_5x14( \
|
||||
k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d, \
|
||||
k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, \
|
||||
k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2d, \
|
||||
k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \
|
||||
k40, k41, k42, k43, k44, k45, k46, k47, k48, k49, k4a, k4b, k4c, k4d \
|
||||
) \
|
||||
{ \
|
||||
{ k00, k01, k02, k03, k04, k05, KC_NO, KC_NO }, \
|
||||
{ k10, k11, k12, k13, k14, k15, KC_NO, KC_NO }, \
|
||||
{ k20, k21, k22, k23, k24, k25, KC_NO, KC_NO }, \
|
||||
{ k30, k31, k32, k33, k34, k35, KC_NO, KC_NO }, \
|
||||
{ k06, k07, k08, k09, k0a, k0b, k0c, k0d }, \
|
||||
{ k16, k17, k18, k19, k1a, k1b, k1c, k1d }, \
|
||||
{ k26, k27, k28, k29, k2a, k2b, k2c, k2d }, \
|
||||
{ k36, k37, k38, k39, k3a, k3b, k3c, k3d }, \
|
||||
{ k40, k41, k42, k49, k4a, k4b, k4c, k4d }, \
|
||||
{ k46, k47, k48, k43, k44, k45, KC_NO, KC_NO }, \
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#define BACKLIGHT_BREATHING
|
||||
@@ -1,96 +0,0 @@
|
||||
#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
|
||||
#define _NL 2
|
||||
|
||||
#define SEMI_FN LT(_FL, KC_SCLN)
|
||||
|
||||
//Tap Dance Declarations
|
||||
enum {
|
||||
TD_WIN_LOCK = 0
|
||||
};
|
||||
|
||||
//BL_BRTG - breathing mode. Would like to put in.
|
||||
|
||||
//Tap Dance Definitions
|
||||
qk_tap_dance_action_t tap_dance_actions[] = {
|
||||
[TD_WIN_LOCK] = ACTION_TAP_DANCE_DOUBLE(MAGIC_NO_GUI, MAGIC_UNNO_GUI)
|
||||
};
|
||||
|
||||
//
|
||||
////In Layer declaration, add tap dance item in place of a key code
|
||||
//TD(TD_WIN_LOCK)
|
||||
|
||||
// Double Tap Fn button to get caps. FN + Tab to get to number layer -> Maybe switch to FN + space?.
|
||||
// Press fn+GUI once to lock, double tap to unlock.
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
/* Keymap _BL: (Base Layer) Default Layer
|
||||
* ,----------------------------------------------------------------.
|
||||
* |Esc | 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backsp |~ ` |
|
||||
* |----------------------------------------------------------------|
|
||||
* |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \ |Del |
|
||||
* |----------------------------------------------------------------|
|
||||
* |FNCAP| A| S| D| F| G| H| J| K| L| ;| '|Enter |PgUp |
|
||||
* |----------------------------------------------------------------|
|
||||
* |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift | Up|PgDn|
|
||||
* |----------------------------------------------------------------|
|
||||
* |Ctrl|Win |Alt | Space |Alt| FN|Ctrl|Lef|Dow|Rig |
|
||||
* `----------------------------------------------------------------'
|
||||
*/
|
||||
[_BL] = LAYOUT_ansi(
|
||||
KC_GESC, 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_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, \
|
||||
LT(_FL, KC_CAPS), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, SEMI_FN,KC_QUOT, KC_ENT,KC_PGUP, \
|
||||
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_PGDN, \
|
||||
KC_LCTL, KC_LGUI,KC_LALT, KC_SPC, KC_RALT,MO(_FL),KC_RCTRL, KC_LEFT,KC_DOWN,KC_RGHT),
|
||||
|
||||
/* Keymap _FL: Function Layer
|
||||
* ,----------------------------------------------------------------.
|
||||
* | | F1|F2 |F3 |F4 |F5 |F6 |F7 |F8 |F9 |F10|F11|F12|Del | |
|
||||
* |----------------------------------------------------------------|
|
||||
* |#PAD |Pre| U |NXT| | | |PGD| U |PGU|PSC| | | |Ins |
|
||||
* |----------------------------------------------------------------|
|
||||
* | |L | D | R |PPl| | | L | D | R | | | |Home|
|
||||
* |----------------------------------------------------------------|
|
||||
* | CAPS |MUT|VU-|VU+| | | |BRG|BL-|BL+|BLT| |Stp|End |
|
||||
* |----------------------------------------------------------------|
|
||||
* | |WTOG| | | | | |Pre|PPl|Nxt |
|
||||
* `----------------------------------------------------------------'
|
||||
*/
|
||||
[_FL] = LAYOUT_ansi(
|
||||
_______, KC_F1 ,KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, _______ , \
|
||||
TO(_NL),KC_MPRV, KC_UP ,KC_MNXT,_______, _______,_______,KC_PGDN,KC_UP,KC_PGUP,KC_PSCR,_______,_______, _______,KC_INSERT, \
|
||||
_______,KC_LEFT,KC_DOWN,KC_RGHT,KC_MPLY,_______,_______,KC_LEFT,KC_DOWN,KC_RGHT,_______,_______, _______,KC_HOME, \
|
||||
_______,KC_MUTE,KC_VOLD,KC_VOLU, _______,_______, _______,BL_BRTG,BL_DEC,BL_INC,BL_TOGG,_______, KC_STOP, KC_END, \
|
||||
_______,TD(TD_WIN_LOCK),_______, _______, _______,KC_TRNS,_______,KC_MPRV,KC_MPLY, KC_MNXT),
|
||||
|
||||
|
||||
//Press either of function keys to get back to base layer.
|
||||
|
||||
/* Keymap _NL: Number Layer
|
||||
* ,----------------------------------------------------------------.
|
||||
* |ESC| F1 | F2| F3| F4| |#L | 7 | 8 | 9 | - | | = | | |
|
||||
* |----------------------------------------------------------------|
|
||||
* | TAB | | UP| | | | / | 4 | 5 | 6 | + | | | | DEL|
|
||||
* |----------------------------------------------------------------|
|
||||
* | _BL |LFT|DWN|RGT| | | * | 1 | 2 | 3 |ENT| | ENT |PgUp|
|
||||
* |----------------------------------------------------------------|
|
||||
* | SHIFT | | | | | | 0 | 0 | , | . |BKS| SHIFT| U |PgDn|
|
||||
* |----------------------------------------------------------------|
|
||||
* |CTRL|WIN |ALT | |ALT| _BL |CTRL| L | D | R|
|
||||
* `----------------------------------------------------------------'
|
||||
*/
|
||||
[_NL] = LAYOUT_ansi(
|
||||
_______, KC_F1 ,KC_F2, KC_F3, KC_F4, _______, KC_NLCK, KC_P7, KC_P8, KC_P9, KC_PMNS, KC_PEQL, KC_PEQL, _______, _______ , \
|
||||
KC_TAB,_______, KC_UP,_______,_______, _______,KC_PSLS,KC_P4,KC_P5,KC_P6,KC_PPLS,_______,_______, _______,KC_DEL, \
|
||||
TO(_BL),KC_LEFT,KC_DOWN,KC_RGHT,_______,_______,KC_PAST,KC_P1,KC_P2,KC_P3,KC_PENT,_______, KC_ENT,KC_PGUP, \
|
||||
KC_LSFT,_______,_______,_______, _______,_______, KC_P0,KC_P0,KC_PCMM,KC_PDOT,KC_BSPC,KC_RSFT, KC_UP, KC_PGDN, \
|
||||
KC_LCTRL,KC_LGUI,KC_LALT, KC_SPC, KC_RALT,TO(_BL),KC_RCTRL,KC_LEFT,KC_DOWN, KC_RGHT),
|
||||
|
||||
};
|
||||
@@ -1,6 +0,0 @@
|
||||
# Godolphins13 Tada68
|
||||
|
||||
My Tada68 layout.
|
||||
Caps lock acts as a function key when held, otherwise just caps lock.
|
||||
In the function layer, arrow keys mapped to both wasd and ijkl, as I haven't really decided which I like best.
|
||||
|
||||
@@ -1,18 +0,0 @@
|
||||
# Build Options
|
||||
# change to "no" to disable the options, or define them in the Makefile in
|
||||
# the appropriate keymap folder that will get included automatically
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = yes # Commands for debug and configuration
|
||||
NKRO_ENABLE = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
|
||||
MIDI_ENABLE = no # MIDI controls
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
RGBLIGHT_ENABLE = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
|
||||
SLEEP_LED_ENABLE = yes # Breathing sleep LED during USB suspend
|
||||
TAP_DANCE_ENABLE = yes # Tappa Dance Bitch
|
||||
@@ -60,7 +60,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_MEDIA] = LAYOUT_ortho_5x7(
|
||||
KC_MAKE, KC_RESET,MU_TOG, AU_ON, AU_OFF, CK_TOGG, RGB_SAD,
|
||||
MEDIA, EEP_RST, KC_RGB_T,RGB_M_P, RGB_M_B, RGB_M_R, RGB_SAI,
|
||||
MEDIA, EPRM, KC_RGB_T,RGB_M_P, RGB_M_B, RGB_M_R, RGB_SAI,
|
||||
RGB_TOG, RGB_MOD, RGB_RMOD,RGB_M_SW,RGB_M_SN,RGB_M_K, RGB_HUD,
|
||||
KC_MPLY, KC_MPRV, KC_MNXT, RGB_M_X, RGB_M_G, RGB_M_P, RGB_HUI,
|
||||
KC_MUTE, KC_VOLD, KC_VOLU, XXXXXXX, XXXXXXX, RGB_VAD, RGB_VAI
|
||||
@@ -94,3 +94,5 @@ void matrix_init_keymap(void) {
|
||||
DDRB &= ~(1<<0);
|
||||
PORTB &= ~(1<<0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -20,13 +20,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#ifdef UNICODEMAP_ENABLE
|
||||
#include "drashna_unicode.h"
|
||||
#endif // UNICODEMAP_ENABLE
|
||||
extern uint8_t input_mode;
|
||||
|
||||
#ifdef RGB_MATRIX_ENABLE
|
||||
extern bool g_suspend_state;
|
||||
extern rgb_config_t rgb_matrix_config;
|
||||
#endif
|
||||
extern userspace_config_t userspace_config;
|
||||
|
||||
|
||||
//enum more_custom_keycodes {
|
||||
// KC_P00 = NEW_SAFE_RANGE
|
||||
@@ -45,7 +40,7 @@ bool skip_leds = false;
|
||||
KC_TAB, K01, K02, K03, K04, K05, TG(_DIABLO), TG(_DIABLO), K06, K07, K08, K09, K0A, KC_BSLS, \
|
||||
KC_C1R3, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, KC_QUOT, \
|
||||
KC_MLSF, CTL_T(K21), K22, K23, K24, K25, TG(_GAMEPAD), TG(_GAMEPAD), K26, K27, K28, K29, CTL_T(K2A), KC_MRSF, \
|
||||
KC_GRV, OS_MEH, OS_HYPR, KC_LBRC, KC_RBRC, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, UC(0x2E2E), \
|
||||
KC_GRV, OSM(MOD_MEH),OSM(MOD_LGUI),KC_LBRC, KC_RBRC, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, UC_SHRG, \
|
||||
OS_LALT, OS_LGUI, OS_RGUI, CTL_T(KC_ESCAPE), \
|
||||
KC_HOME, KC_PGUP, \
|
||||
LT(_LOWER, KC_SPACE),KC_BSPC, KC_END, KC_PGDN, KC_DEL, LT(_RAISE, KC_ENTER) \
|
||||
@@ -203,7 +198,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
*/
|
||||
[_GAMEPAD] = LAYOUT_ergodox_pretty_wrapper(
|
||||
KC_ESC, KC_NO, KC_1, KC_2, KC_3, HYPR(KC_Q), HYPR(KC_GRV), KC_TRNS, KC_F9, KC_F10, KC_F11, KC_F12, KC_NO, KC_NO,
|
||||
KC_F1, KC_K, KC_Q, KC_W, KC_E, KC_R, KC_T, UC_SHRG, UC_DISA, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_F1, KC_K, KC_Q, KC_W, KC_E, KC_R, KC_T, UC_SHRG, UC_DISA, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_TAB, KC_G, KC_A, KC_S, KC_D, KC_F, KC_I, KC_O, KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_LCTL, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_TRNS, TG(_GAMEPAD), KC_N, KC_M, KC_NO, KC_NO, KC_NO, KC_NO,
|
||||
KC_GRV, KC_U, KC_I, KC_Y, KC_T, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_NO,
|
||||
@@ -268,7 +263,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_ADJUST] = LAYOUT_ergodox_pretty_wrapper(
|
||||
KC_MAKE, _______, _______, _______, _______, _______, _______, KC_NUKE, _________________ADJUST_R1_________________, KC_RST,
|
||||
VRSN, _________________ADJUST_L1_________________, _______, _______, _______, _______, _______, _______, _______, EEP_RST,
|
||||
VRSN, _________________ADJUST_L1_________________, _______, _______, _______, _______, _______, _______, _______, EPRM,
|
||||
_______, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, TG(_MODS),
|
||||
_______, _________________ADJUST_L3_________________, _______, _______, _________________ADJUST_R3_________________, KC_MPLY,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
|
||||
@@ -295,6 +290,10 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
|
||||
return true;
|
||||
}
|
||||
|
||||
void matrix_init_keymap(void) { // Runs boot tasks for keyboard
|
||||
};
|
||||
|
||||
|
||||
void matrix_scan_keymap(void) { // runs frequently to update info
|
||||
uint8_t modifiers = get_mods();
|
||||
uint8_t led_usb_state = host_keyboard_leds();
|
||||
@@ -336,106 +335,3 @@ bool indicator_is_this_led_used_keyboard(uint8_t index) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#ifdef RGB_MATRIX_ENABLE
|
||||
|
||||
void suspend_power_down_keymap(void) {
|
||||
rgb_matrix_set_suspend_state(true);
|
||||
rgb_matrix_config.enable = false;
|
||||
}
|
||||
|
||||
void suspend_wakeup_init_keymap(void) {
|
||||
rgb_matrix_config.enable = true;
|
||||
rgb_matrix_set_suspend_state(false);
|
||||
}
|
||||
|
||||
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue) {
|
||||
rgb_led led;
|
||||
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
|
||||
led = g_rgb_leds[i];
|
||||
if (led.matrix_co.raw < 0xFF) {
|
||||
if (led.modifier) {
|
||||
rgb_matrix_set_color( i, red, green, blue );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void rgb_matrix_indicators_user(void) {
|
||||
if (g_suspend_state || !rgb_matrix_config.enable || !userspace_config.rgb_layer_change) return;
|
||||
|
||||
switch (biton32(layer_state)) {
|
||||
case _MODS:
|
||||
rgb_matrix_layer_helper(0xFF, 0xFF, 0x00); break;
|
||||
case _GAMEPAD:
|
||||
rgb_matrix_layer_helper(0xFF, 0x80, 0x00);
|
||||
rgb_matrix_set_color(32, 0x00, 0xFF, 0x00); // Q
|
||||
rgb_matrix_set_color(31, 0x00, 0xFF, 0xFF); // W
|
||||
rgb_matrix_set_color(30, 0xFF, 0x00, 0x00); // E
|
||||
rgb_matrix_set_color(29, 0xFF, 0x80, 0x00); // R
|
||||
rgb_matrix_set_color(37, 0x00, 0xFF, 0xFF); // A
|
||||
rgb_matrix_set_color(36, 0x00, 0xFF, 0xFF); // S
|
||||
rgb_matrix_set_color(35, 0x00, 0xFF, 0xFF); // D
|
||||
rgb_matrix_set_color(34, 0x7A, 0x00, 0xFF); // F
|
||||
|
||||
rgb_matrix_set_color(27, 0xFF, 0xFF, 0xFF); // 1
|
||||
rgb_matrix_set_color(26, 0x00, 0xFF, 0x00); // 2
|
||||
rgb_matrix_set_color(25, 0x7A, 0x00, 0xFF); // 3
|
||||
|
||||
break;
|
||||
case _DIABLO:
|
||||
rgb_matrix_layer_helper(0xFF, 0x00, 0x00); break;
|
||||
case _RAISE:
|
||||
rgb_matrix_layer_helper(0xFF, 0xFF, 0x00); break;
|
||||
case _LOWER:
|
||||
rgb_matrix_layer_helper(0x00, 0xFF, 0x00); break;
|
||||
case _ADJUST:
|
||||
rgb_matrix_layer_helper(0xFF, 0x00, 0x00); break;
|
||||
default:
|
||||
switch (biton32(default_layer_state)) {
|
||||
case _QWERTY:
|
||||
rgb_matrix_layer_helper(0x00, 0xFF, 0xFF); break;
|
||||
case _COLEMAK:
|
||||
rgb_matrix_layer_helper(0xFF, 0x00, 0xFF); break;
|
||||
case _DVORAK:
|
||||
rgb_matrix_layer_helper(0x00, 0xFF, 0x00); break;
|
||||
case _WORKMAN:
|
||||
rgb_matrix_layer_helper(0xD9, 0xA5, 0x21); break;
|
||||
}
|
||||
}
|
||||
#if 0
|
||||
if (this_mod & MODS_SHIFT_MASK || this_led & (1<<USB_LED_CAPS_LOCK) || this_osm & MODS_SHIFT_MASK) {
|
||||
rgb_matrix_set_color(24, 0x00, 0xFF, 0x00);
|
||||
rgb_matrix_set_color(36, 0x00, 0xFF, 0x00);
|
||||
}
|
||||
if (this_mod & MODS_CTRL_MASK || this_osm & MODS_CTRL_MASK) {
|
||||
rgb_matrix_set_color(25, 0xFF, 0x00, 0x00);
|
||||
rgb_matrix_set_color(34, 0xFF, 0x00, 0x00);
|
||||
rgb_matrix_set_color(37, 0xFF, 0x00, 0x00);
|
||||
|
||||
}
|
||||
if (this_mod & MODS_GUI_MASK || this_osm & MODS_GUI_MASK) {
|
||||
rgb_matrix_set_color(39, 0xFF, 0xD9, 0x00);
|
||||
}
|
||||
if (this_mod & MODS_ALT_MASK || this_osm & MODS_ALT_MASK) {
|
||||
rgb_matrix_set_color(38, 0x00, 0x00, 0xFF);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void matrix_init_keymap(void) {
|
||||
#ifdef RGB_MATRIX_KEYPRESSES
|
||||
rgblight_mode(RGB_MATRIX_MULTISPLASH);
|
||||
#else
|
||||
rgblight_mode(RGB_MATRIX_RAINBOW_MOVING_CHEVRON);
|
||||
#endif
|
||||
|
||||
input_mode = 2;
|
||||
}
|
||||
|
||||
#else
|
||||
void matrix_init_keymap(void) {
|
||||
input_mode = 2;
|
||||
}
|
||||
#endif //RGB_MATRIX_INIT
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
Note: This board will not flash if the "g_rgb_leds" const is not set to weak in the ergodox_ez.c file
|
||||
@@ -1,11 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include "../drashna/config.h"
|
||||
|
||||
#undef PRODUCT
|
||||
#define PRODUCT DrashnaDox - Hacked ErgoDox EZ Glow
|
||||
|
||||
#undef DEBOUNCE
|
||||
#define DEBOUNCE 5
|
||||
|
||||
// #define RGB_MATRIX_KEYPRESSES // reacts to keypresses (will slow down matrix scan by a lot)
|
||||
@@ -1,67 +0,0 @@
|
||||
/* placeholder file */
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const rgb_led g_rgb_leds[DRIVER_LED_TOTAL] = {
|
||||
|
||||
/*{row | col << 4}
|
||||
| {x=0..224, y=0..64}
|
||||
| | modifier
|
||||
| | | */
|
||||
{{0|(0<<4)}, {24.9*5, 16*0}, 0}, // LED 1 on right
|
||||
{{0|(1<<4)}, {24.9*6, 16*0}, 0}, // LED 2
|
||||
{{0|(2<<4)}, {24.9*7, 16*0}, 0}, // LED 3
|
||||
{{0|(3<<4)}, {24.9*8, 16*0}, 0}, // LED 4
|
||||
{{0|(4<<4)}, {24.9*9, 16*0}, 0}, // LED 5
|
||||
|
||||
{{1|(5<<4)}, {24.9*5, 16*1}, 0}, // LED 6
|
||||
{{1|(6<<4)}, {24.9*6, 16*1}, 0}, // LED 7
|
||||
{{1|(7<<4)}, {24.9*7, 16*1}, 0}, // LED 8
|
||||
{{1|(8<<4)}, {24.9*8, 16*1}, 0}, // LED 9
|
||||
{{1|(9<<4)}, {24.9*9, 16*1}, 0}, // LED 10
|
||||
|
||||
{{2|(5<<4)}, {24.9*5, 16*2}, 0}, // LED 11
|
||||
{{2|(6<<4)}, {24.9*6, 16*2}, 0}, // LED 12
|
||||
{{2|(7<<4)}, {24.9*7, 16*2}, 0}, // LED 13
|
||||
{{2|(8<<4)}, {24.9*8, 16*2}, 0}, // LED 14
|
||||
{{2|(9<<4)}, {24.9*9, 16*2}, 0}, // LED 15
|
||||
|
||||
{{3|(5<<4)}, {24.9*5, 16*2}, 0}, // LED 16
|
||||
{{3|(6<<4)}, {24.9*6, 16*2}, 0}, // LED 17
|
||||
{{3|(7<<4)}, {24.9*7, 16*2}, 0}, // LED 18
|
||||
{{3|(8<<4)}, {24.9*8, 16*2}, 0}, // LED 19
|
||||
{{3|(9<<4)}, {24.9*9, 16*2}, 0}, // LED 20
|
||||
|
||||
{{4|(6<<4)}, {24.9*6, 16*2}, 1}, // LED 21
|
||||
{{4|(7<<4)}, {24.9*7, 16*2}, 1}, // LED 22
|
||||
{{4|(8<<4)}, {24.9*8, 16*2}, 1}, // LED 23
|
||||
{{4|(9<<4)}, {24.9*9, 16*2}, 1}, // LED 24
|
||||
|
||||
{{0|(0<<4)}, {24.9*4, 16*0}, 0}, // LED 1 on left
|
||||
{{0|(1<<4)}, {24.9*3, 16*0}, 0}, // LED 2
|
||||
{{0|(2<<4)}, {24.9*2, 16*0}, 0}, // LED 3
|
||||
{{0|(3<<4)}, {24.9*1, 16*0}, 0}, // LED 4
|
||||
{{0|(4<<4)}, {24.9*0, 16*0}, 0}, // LED 5
|
||||
|
||||
{{1|(5<<4)}, {24.9*4, 16*1}, 0}, // LED 6
|
||||
{{1|(6<<4)}, {24.9*3, 16*1}, 0}, // LED 7
|
||||
{{1|(7<<4)}, {24.9*2, 16*1}, 0}, // LED 8
|
||||
{{1|(8<<4)}, {24.9*1, 16*1}, 0}, // LED 9
|
||||
{{1|(9<<4)}, {24.9*0, 16*1}, 0}, // LED 10
|
||||
|
||||
{{2|(5<<4)}, {24.9*4, 16*2}, 0}, // LED 11
|
||||
{{2|(6<<4)}, {24.9*3, 16*2}, 0}, // LED 12
|
||||
{{2|(7<<4)}, {24.9*2, 16*2}, 0}, // LED 13
|
||||
{{2|(8<<4)}, {24.9*1, 16*2}, 0}, // LED 14
|
||||
{{2|(9<<4)}, {24.9*0, 16*2}, 0}, // LED 15
|
||||
|
||||
{{3|(5<<4)}, {24.9*4, 16*2}, 0}, // LED 16
|
||||
{{3|(6<<4)}, {24.9*3, 16*2}, 0}, // LED 17
|
||||
{{3|(7<<4)}, {24.9*2, 16*2}, 0}, // LED 18
|
||||
{{3|(8<<4)}, {24.9*1, 16*2}, 0}, // LED 19
|
||||
{{3|(9<<4)}, {24.9*0, 16*2}, 0}, // LED 20
|
||||
|
||||
{{4|(6<<4)}, {24.9*3, 16*2}, 1}, // LED 21
|
||||
{{4|(7<<4)}, {24.9*2, 16*2}, 1}, // LED 22
|
||||
{{4|(8<<4)}, {24.9*1, 16*2}, 1}, // LED 23
|
||||
{{4|(9<<4)}, {24.9*0, 16*2}, 1}, // LED 24
|
||||
};
|
||||
@@ -1,9 +0,0 @@
|
||||
USER_NAME := drashna
|
||||
SRC += ../drashna/keymap.c
|
||||
|
||||
-include $$(LAYOUT_KEYMAP_PATH)/../drashna/rules.mk
|
||||
|
||||
ifneq (,$(findstring ergodox_ez,$(KEYBOARD)))
|
||||
RGBLIGHT_ENABLE = no
|
||||
RGB_MATRIX_ENABLE = yes
|
||||
endif
|
||||
@@ -5,8 +5,6 @@ endif
|
||||
AUDIO_ENABLE = no
|
||||
ifeq ($(strip $(KEYBOARD)), zlant)
|
||||
BACKLIGHT_ENABLE = no
|
||||
else ifeq ($(strip $(KEYBOARD)), 40percentclub/4x4)
|
||||
BACKLIGHT_ENABLE = no
|
||||
else
|
||||
BACKLIGHT_ENABLE = yes
|
||||
endif
|
||||
|
||||
@@ -92,7 +92,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_ADJUST] = LAYOUT_ortho_4x12_wrapper(
|
||||
KC_MAKE, _________________ADJUST_L1_________________, _________________ADJUST_R1_________________, KC_RST,
|
||||
VRSN, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, EEP_RST,
|
||||
VRSN, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, EPRM,
|
||||
_______, _________________ADJUST_L3_________________, _________________ADJUST_R3_________________, TG_MODS,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user