Compare commits

..

30 Commits

Author SHA1 Message Date
mtei
90f9fb4eee Fixed docs/newbs_testing_debugging.md and tmk_core/common/print.h 2018-11-27 14:40:19 -05:00
abishalom
77ed9e3a73 Keymap: Added abishalom keymaps (#4495)
* Added abishalom keymaps

Added personal keymaps for Massdrop Alt and Tada68

* Update keyboards/tada68/keymaps/abishalom/rules.mk

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/rules.mk

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/config.h

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/keymap.c

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/keymap.c

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/rules.mk

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/keymap.c

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Update keyboards/tada68/keymaps/abishalom/keymap.c

Co-Authored-By: abishalom <abishalom1997@gmail.com>

* Updated keymaps

* Bugfix Tada68

* Update keyboards/tada68/keymaps/abishalom/keymap.c

Co-Authored-By: abishalom <abishalom1997@gmail.com>
2018-11-27 09:22:49 -08:00
Mattia Dal Ben
faef966a4d Keymap: Set serial connection as default for the Redox rev1.0 keyboard (#4488)
* Set serial as default for Redox

* Updated rules.mk file

* Removed unused rule

Co-Authored-By: mattdibi <mattdibi@users.noreply.github.com>

* Removed unused rule

Co-Authored-By: mattdibi <mattdibi@users.noreply.github.com>
2018-11-27 08:59:53 -08:00
Takeshi ISHII
a054b5a06c Fix Helix ws2812.c listed more than once warning. (#4499)
Remove `SRC += ws2812.c` from helix/rev2/rules.mk and helix/pico/rules.mk.
Because it will be added in common_features.mk.
2018-11-27 07:22:47 -08:00
noroadsleft
952a30ef34 handwired/arrow_pad Refactor and Configurator support (#4498)
* handwired/arrow_pad: layout macro and keymap refactor

- Layout macros moved from the keymaps to arrow_pad.h.
- LAYOUT_pad21 refactored to only accept keys that are physical present (no KC_NO entries required in keymap)
- Keymaps now use #include QMK_KEYBOARD_H
- Keymaps refactored to use process_record_user function (from action_get_macro)

* handwired/arrow_pad: Readme cleanup

Fixed the make commands and updated the layout macro.

* handwired/arrow_pad: Configurator support
2018-11-26 20:57:15 -08:00
Joe Wasson
bada74e2a1 Keymap: Fix build errors for non-Zeal boards. (#4496) 2018-11-26 17:39:29 -08:00
Drashna Jaelre
ecd21b44a8 Update to drashna userspace and keymaps (#4459)
* Fix reversed bool check in layer_state_set

* Add Quefrency 65 for a friend

* Add Ergodox EZ Glow keymap

* Add RGB Matrix Code

* Further changes to rgb matrix ErgoDox EZ

* Update bjohnson keymaps

* Fix CRKBD display

* Overhaul to corne keyboard

* Narrow scope for keylogger

* Minor layout tweaks to Corne Keyboard

* additional CRKBD tweaks

* Minor tweaks to CRKBD

* Add all characters for keylogger

* Ergodox EZ Glow overhaul

* Fix Ergodox EZ Glow layer colors

* Increase Tapping Term for Corne Keyboard

* Fix unicode-ish

* Revert some changes

* Add layer specific lighting effects

* Some minor tweaks to ergodox glow config

* revert changes to ergodox files

* Update Glow readme

* Add more tapping term defines

* Fix changes

* Fix ergodox keymap

* Hopefully fix sleeping

* Disable layer indications if rgb matrix is disabled

* Add support for sleeping and rgb layer change toggle to ergodox ez glow

* Make RGB Layer Indication Great Again

* Make Unicode Great Again

* Remove placeholder define

Co-Authored-By: drashna <drashna@live.com>

* Remove placeholder define

Co-Authored-By: drashna <drashna@live.com>

* Remove old EEPROM Reset keycode
2018-11-26 16:45:24 -08:00
zvecr
edb6c98fd2 Keyboard: Enable community ortho 4x12 layouts for lets split eh (#4487)
* Enable ortho_4x12 community layouts for lets_split_eh

* Keymap build fixes now that ortho_4x12 is enabled

* Keymap build fixes now that ortho_4x12 is enabled
2018-11-26 14:58:22 -08:00
Drashna Jaelre
b7b20cd9df Revert "Add support for PR and Issue templates to QMK_firmware GitHub (#4491)" (#4492)
This reverts commit b91dfa04e3.
2018-11-26 14:35:48 -08:00
Drashna Jaelre
b91dfa04e3 Add support for PR and Issue templates to QMK_firmware GitHub (#4491)
* Add support document

* Add Bug Report

* Add GitHub Pull Request Template

* Feature request issue template

* Touch up feature request template

* Add 'other issues' template

* move support doc
2018-11-26 14:35:01 -08:00
zgtm
fe68599a34 Keyboard: add generic ortho 5x15 layout support to Idobo (#4486) 2018-11-26 10:01:34 -08:00
listofoptions
4ebd27002a Keyboard: 5291 firmware to replace the existing soarers controller firmware (#4483)
* compiles but is not working

* still testing 5291

* compiles but is not working

* still testing 5291

* fixed a but in the layout (reversed key order in row)

* compiles but is not working

* still testing 5291

* fixed a but in the layout (reversed key order in row)

* fixed some issues

* doumentation needed

* doumentation needed

* documentation needed

* documentation needed

* Update readme.md

documentation

* Update readme.md

i dislike markdown <_>

* merge preperation
2018-11-26 09:53:49 -08:00
epaew
f3ffd6ad50 Keymap: Refactor edvorakjp user library (#4480)
* Refactor edvorakjp user library

* add tap dance support

* update keymaps

* edvorakjp: add SWAP_SCLN option

* fix behavior of SWAP_SCLN
2018-11-26 09:50:45 -08:00
zvecr
0031e46191 Keyboard: 40percentclub - enable 4x4 and 5x5 community keymaps (#4437)
* Enable 4x4 and 5x5 community keymap support

* Pull 4x4 community keymap fixes from @noroadsleft

* Build fixes for guidoism keymap - move keymap to layouts/community/planck_mit as it uses the LAYOUT_planck_mit macro
2018-11-26 09:27:07 -08:00
mwpeterson
97ab3211e2 Keymap: add Interrobang (#4420)
* remove clmk and dvrk and backlight; switch esc and enter to be modtap; add meh key

* change songs

* space cadet; move enter; move '"; move pgup pgdn

* remove extra songs

* update from noahfredrick keymap

* make it easier to type ../../thing/*/*

* move pipe

* requested changes

* add interrobang support

* add shift-insert to raise-v and lower-v, move pipe to raise-/lower-n
2018-11-26 09:26:26 -08:00
Drashna Jaelre
8bc19c8dcf Fix Blockey compiler (and size) issues (#4390) 2018-11-26 08:09:37 -08:00
Elliot Powell
6266c172b9 added ep/96 as a supported keyboard (#4476)
* added ep/96

* Update keyboards/ep/96/readme.md

Co-Authored-By: e11i0t23 <32494740+e11i0t23@users.noreply.github.com>

* removed led code

* Update keyboards/ep/96/config.h

Co-Authored-By: e11i0t23 <32494740+e11i0t23@users.noreply.github.com>

* Update keyboards/ep/96/info.json

Co-Authored-By: e11i0t23 <32494740+e11i0t23@users.noreply.github.com>

* Update keyboards/ep/96/readme.md

Co-Authored-By: e11i0t23 <32494740+e11i0t23@users.noreply.github.com>
2018-11-26 07:58:53 -08:00
Will Homer
ccd4da941c Add Espectro ISO layout (#4479)
* Add Espectro ISO layout

* Remove unused define from Espectro ISO layout
2018-11-26 07:57:30 -08:00
noroadsleft
834b555eca Keymap FAQ: fix positions of KC_HENK and KC_MHEN for JIS layout (#4482)
These keys were previously in each other's positions.
2018-11-25 18:40:47 -08:00
Colin Kahn
d7ab738ca6 Adding keymap layers for 40precentclub/foobar (#4481) 2018-11-25 18:38:46 -08:00
André Silva
f0db40ff11 fix diffutils arch package name (#4470) 2018-11-24 08:48:42 -08:00
xjacobx
3363743bf7 Adding my new keymap for the Idobo (#4468)
* Adding my new keymap, based of xd75, with leds enabled via the rules.mk file

* cleaned up the rules file

* Per Change Requests: removed deprecated functions along with updated the map to use the layout macro instead of raw matrix
2018-11-24 08:41:39 -08:00
Jasper Lievisse Adriaanse
7bc7c34d4f Add RCTL to my Planck layout (#4475) 2018-11-24 08:40:48 -08:00
noroadsleft
ee8627e078 Add EEPROM_RESET keycode to keycodes.md doc (#4473) 2018-11-23 20:07:53 -08:00
Gergely Nagy
3dd6d53942 ergodox: update algernon's layout to v1.12
This is the final version of my layout.

Overall changes
===============

* Updated to work with QMK master.

Miscellaneous
=============

* The `😂` symbol can be entered with UCIS.
* `LEAD r` now inputs `Right Alt`.

Signed-off-by: Gergely Nagy <me@gergo.csillger.hu>
2018-11-22 13:31:30 -08:00
Milton Griffin
2943d19ecd Keymap: Clone layout for Massdrop's xd75 (#4461)
* Added default75. No lighting.

* Added default75. No lighting.

* Update keyboards/idobo/keymaps/default75/config.h

Co-Authored-By: griffinmilton3 <griffinmilton3@gmail.com>

* Update keyboards/idobo/keymaps/default75/config.h

Co-Authored-By: griffinmilton3 <griffinmilton3@gmail.com>

* Update keyboards/idobo/keymaps/default75/config.h

Co-Authored-By: griffinmilton3 <griffinmilton3@gmail.com>

* Update keyboards/idobo/keymaps/default75/config.h

Co-Authored-By: griffinmilton3 <griffinmilton3@gmail.com>

* Fixes for pull request

* Updated keyboard declartion structure
2018-11-22 10:15:46 -08:00
Erez Zukerman
48262bdce0 Merge pull request #4454 from trunneml/improveddebounce
Adaptive debounce logic
2018-11-22 10:51:20 -05:00
Erez Zukerman
b7dd415c97 Merge pull request #4458 from drashna/ergodox_ez_matrix_fix
Fix Ergodox EZ Matrix scan
2018-11-22 10:50:20 -05:00
Drashna Jaelre
8837b9d99e Fix row 11 2018-11-21 07:49:28 -08:00
Michael Graf
ad91454574 Adaptive debounce logic
The debounce filtering reports a key/switch change directly, without any extra delay. After that the debounce logic will filter all further changes, until the key/switch reports the same state for the given count of scans.
So a perfect switch will get a short debounce period and a bad key will get a much longer debounce period. The result is an adaptive debouncing period for each switch.

This value defines how often the same key/switch state has to be detected in successive reads until the next key state can be reported.
In other words this value defines the minimum debouncing period for a switch.
2018-11-20 15:55:35 +01:00
123 changed files with 3855 additions and 778 deletions

View File

@@ -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/070a530eedaed36a2d77f3f6fd455677 -->
![Keyboard Layout Image](https://i.imgur.com/gvlNUpQ.png)
<!-- Source for this image: http://www.keyboard-layout-editor.com/#/gists/bf431647d1001cff5eff20ae55621e9a -->
![Keyboard Layout Image](https://i.imgur.com/5wsh5wM.png)
## Some Of My Keys Are Swapped Or Not Working

View File

@@ -206,18 +206,19 @@ 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 |
|`KC_GESC` |`GRAVE_ESC`|Escape when tapped, <code>&#96;</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 |
|`EEPROM_RESET` |`EEP_RST` |Resets EEPROM state by reinitializing it |
|`KC_GESC` |`GRAVE_ESC`|Escape when tapped, <code>&#96;</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)

View File

@@ -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.
* `sprintf("%s string", var)`: Print a formatted string
* `uprintf("%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

View File

@@ -56,3 +56,16 @@
{ 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, ___, ___, ___, ___} \
}

View File

@@ -76,5 +76,4 @@ 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)
#FIXME: Community keymap build are currently failing due to missing functionality
#LAYOUTS = ortho_4x4 ortho_4x8 ortho_4x12 ortho_4x16
LAYOUTS = ortho_4x4 ortho_4x8 ortho_4x12 ortho_4x16

View File

@@ -77,5 +77,4 @@ 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)
#FIXME: Community keymap build are currently failing due to missing functionality
#LAYOUTS = ortho_5x5 ortho_5x10 ortho_5x15
LAYOUTS = ortho_5x5 ortho_5x10 ortho_5x15

View File

@@ -17,3 +17,5 @@
#pragma once
// place overrides here
#define PERMISSIVE_HOLD

View File

@@ -15,19 +15,62 @@
*/
#include QMK_KEYBOARD_H
#define FN1_Q LT(1, KC_Q)
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)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[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
[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
),
[1] = LAYOUT_split(
[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(
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, RESET, _______, _______, _______
_______, _______, _______, _______, _______, RESET, _______, _______, _______, _______
),
};

View File

@@ -1,5 +1,3 @@
SRC += ws2812.c
# MCU name
#MCU = at90usb1286
MCU = atmega32u4
@@ -54,7 +52,7 @@ OPT_DEFS += -DBOOTLOADER_SIZE=4096
# change yes to no to disable
#
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
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

View File

@@ -0,0 +1,42 @@
/*
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

View File

@@ -0,0 +1,3 @@
#include "ibm_5291.h"
#include <avr/io.h>
#include "quantum.h"

View File

@@ -0,0 +1,69 @@
/*
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

View File

@@ -0,0 +1,6 @@
{
"keyboard_name": "IBM 5291",
"keyboard_folder": "converter/5291",
"url": "https://deskthority.net/wiki/IBM_Model_F#IBM_5291_Keyboard",
"maintainer": "listofoptions",
}

View File

@@ -0,0 +1,233 @@
/*
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
)
} ;

View File

@@ -0,0 +1,284 @@
/*
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");
}
}

View File

@@ -0,0 +1,96 @@
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 0 Z
2 1 S
3 2 W
4 3 3
5 4 X
6 5 D
7 6 E
8 7 4
9 8 C
10 9 F
11 10 R
12 11 5
13 12 V
14 13 G
15 14 T
16 15 6
17 16 B
18 17 H
19 18 Y
20 19 7
21 20 N
22 21 J
23 22 U
24 23 8
25 24 PAD_2
26 25 PAD_5
27 26 PAD_8
28 27 NUM_LOCK
29 28 M
30 29 K
31 30 I
32 31 9
33 32 COMMA
34 33 L
35 34 O
36 35 0
37 36 PERIOD
38 37 SEMICOLON
39 38 P
40 39 MINUS
41 40 SLASH
42 41 QUOTE
43 42 LEFT_BRACE
44 43 EQUAL
45 44 SPACE
46 45 RSHIFT
47 46 BACK_QUOTE
48 47 RIGHT_BRACE
49 48 CAPS_LOCK
50 49 PAD_ASTERIX
51 50 ENTER
52 51 BACKSPACE
53 52 PAD_0
54 53 PAD_1
55 54 PAD_4
56 55 PAD_7
57 56 PAD_PLUS
58 57 UNASSIGNED
59 58 PAD_MINUS
60 59 SCROLL_LOCK
61 60 PAD_PERIOD
62 61 PAD_3
63 62 PAD_6
64 63 PAD_9
65 64 BACKSLASH
66 65 A
67 66 Q
68 67 2
69 68 LALT
70 69 UNASSIGNED
71 70 UNASSIGNED
72 71 1
73 72 F7
74 73 F5
75 74 F3
76 75 F1
77 76 F8
78 77 F6
79 78 F4
80 79 F2
81 80 F10
82 81 UNASSIGNED
83 82 UNASSIGNED
84 83 UNASSIGNED
85 84 F9
86 85 UNASSIGNED
87 86 UNASSIGNED
88 87 UNASSIGNED
89 88 LSHIFT
90 89 LCTRL
91 90 TAB
92 91 ESC
93 92 UNASSIGNED
94 93 UNASSIGNED
95 94 UNASSIGNED
96 95 UNASSIGNED

View File

@@ -0,0 +1,70 @@
# IBM 5291 keyboard converter
![5291](https://deskthority.net/wiki/IBM_Model_F#IBM_5291_Keyboard)
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:
IBM5291Cable to Pinhead14
| 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 ![here](https://geekhack.org/index.php?action=dlattach;topic=48950.0;attach=36759;image)
IBM52912 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

View File

@@ -0,0 +1,72 @@
# 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

View File

@@ -41,5 +41,10 @@ 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 120
#define RGBLIGHT_LIMIT_VAL 100
#endif
#ifdef AUDIO_ENABLE
#define B6_AUDIO
// #define NO_MUSIC_MODE
#endif

View File

@@ -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_BSPC, \
KC_TAB, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, KC_QUOT, \
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), \
OS_LSFT, CTL_T(K21), K22, K23, K24, K25, K26, K27, K28, K29, CTL_T(K2A), OS_RSFT, \
LT(_LOWER,KC_GRV), KC_SPC, LALT_T(KC_BSPC), KC_DEL, KC_ENT, RAISE \
LT(_LOWER,KC_GRV), KC_SPC, 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_TILD, _________________LOWER_L1__________________, _________________LOWER_R1__________________, KC_BSPC,
KC_F11, _________________LOWER_L2__________________, _________________LOWER_R2__________________, KC_PIPE,
KC_F12, _________________LOWER_L3__________________, _________________LOWER_R3__________________, _______,
KC_F11, _________________LOWER_L1__________________, _________________LOWER_R1__________________, KC_F11,
KC_F12, _________________LOWER_L2__________________, _________________LOWER_R2__________________, KC_PIPE,
_______, _________________LOWER_L3__________________, _________________LOWER_R3__________________, _______,
_______, _______, _______, _______, _______, _______
),
[_RAISE] = LAYOUT_wrapper( \
KC_GRV, _________________RAISE_L1__________________, _________________RAISE_R1__________________, KC_BSPC,
_______, _________________RAISE_L1__________________, _________________RAISE_R1__________________, _______,
_______, _________________RAISE_L2__________________, _________________RAISE_R2__________________, KC_BSLS,
_______, _________________RAISE_L3__________________, _________________RAISE_R3__________________, _______,
_______, _______, _______, _______, _______, _______
@@ -81,18 +81,13 @@ 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_________________, EPRM,
TG_MODS, _________________ADJUST_L3_________________, _________________ADJUST_R3_________________, KC_MPLY,
_______, _______, _______, _______, _______, _______
VRSN, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, EEP_RST,
_______, _________________ADJUST_L3_________________, _________________ADJUST_R3_________________, KC_MPLY,
_______, _______, _______, KC_NUKE, TG_MODS, _______
)
};
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
@@ -102,53 +97,118 @@ 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 (layer_state) {
case _QWERTY:
switch (default_layer_state) {
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)) {
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;
@@ -160,12 +220,13 @@ 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_keylog());
matrix_write_ln(matrix, read_modifier_state());
// 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_ln(matrix, read_host_led_state());
// matrix_write_ln(matrix, read_mode_icon(keymap_config.swap_lalt_lgui));
matrix_write(matrix, read_host_led_state());
//matrix_write_ln(matrix, read_timelog());
} else {
matrix_write(matrix, read_logo());
@@ -187,8 +248,14 @@ void iota_gfx_task_user(void) {
}
bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
if (record->event.pressed) {
set_keylog(keycode, 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;
// set_timelog();
}
return true;

View File

@@ -20,12 +20,14 @@ 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/layer_state_reader.c \
# ./lib/keylogger.c \
# ./lib/host_led_state_reader.c \
# ./lib/mode_icon_reader.c \
# ./lib/layer_state_reader.c \
# ./lib/timelogger.c \

43
keyboards/ep/96/96.c Normal file
View File

@@ -0,0 +1,43 @@
/* 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);
}

47
keyboards/ep/96/96.h Normal file
View File

@@ -0,0 +1,47 @@
/* 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

212
keyboards/ep/96/config.h Normal file
View File

@@ -0,0 +1,212 @@
/*
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
*/

426
keyboards/ep/96/info.json Normal file
View File

@@ -0,0 +1,426 @@
{
"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
}]
}
}
}

View File

@@ -0,0 +1,67 @@
/* 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) {
}

View File

@@ -0,0 +1 @@
# The default keymap for ep96

15
keyboards/ep/96/readme.md Normal file
View File

@@ -0,0 +1,15 @@
# ep96
![ep96](https://i.imgur.com/PZ2C7a8.jpg)
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).

81
keyboards/ep/96/rules.mk Normal file
View File

@@ -0,0 +1,81 @@
# 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)

View File

@@ -85,17 +85,20 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define RGBW 1
/* "debounce" is measured in keyboard scans. Some users reported
* needing values as high as 15, which was at the time around 50ms.
/*
* The debounce filtering reports a key/switch change directly,
* without any extra delay. After that the debounce logic will filter
* all further changes, until the key/switch reports the same state for
* the given count of scans.
* So a perfect switch will get a short debounce period and
* a bad key will get a much longer debounce period.
* The result is an adaptive debouncing period for each switch.
*
* If you don't define it here, the matrix code will default to
* 5, which is now closer to 10ms, but still plenty according to
* manufacturer specs.
*
* Default is quite high, because of reports with some production
* runs seeming to need it. This may change when configuration for
* this is more directly exposed.
*/
#define DEBOUNCE 15
#define DEBOUNCE 10
#define USB_MAX_POWER_CONSUMPTION 500

View File

@@ -57,6 +57,11 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* matrix state(1:on, 0:off) */
static matrix_row_t matrix[MATRIX_ROWS];
/*
* matrix state(1:on, 0:off)
* contains the raw values without debounce filtering of the last read cycle.
*/
static matrix_row_t raw_matrix[MATRIX_ROWS];
// Debouncing: store for each key the number of scans until it's eligible to
// change. When scanning the matrix, ignore any changes in keys that have
@@ -118,6 +123,7 @@ void matrix_init(void)
// initialize matrix state: all keys off
for (uint8_t i=0; i < MATRIX_ROWS; i++) {
matrix[i] = 0;
raw_matrix[i] = 0;
for (uint8_t j=0; j < MATRIX_COLS; ++j) {
debounce_matrix[i * MATRIX_COLS + j] = 0;
}
@@ -151,26 +157,30 @@ void matrix_power_up(void) {
// Returns a matrix_row_t whose bits are set if the corresponding key should be
// eligible to change in this scan.
matrix_row_t debounce_mask(uint8_t row) {
matrix_row_t debounce_mask(matrix_row_t rawcols, uint8_t row) {
matrix_row_t result = 0;
for (uint8_t j=0; j < MATRIX_COLS; ++j) {
if (debounce_matrix[row * MATRIX_COLS + j]) {
--debounce_matrix[row * MATRIX_COLS + j];
matrix_row_t change = rawcols ^ raw_matrix[row];
raw_matrix[row] = rawcols;
for (uint8_t i = 0; i < MATRIX_COLS; ++i) {
if (debounce_matrix[row * MATRIX_COLS + i]) {
--debounce_matrix[row * MATRIX_COLS + i];
} else {
result |= (1 << j);
result |= (1 << i);
}
if (change & (1 << i)) {
debounce_matrix[row * MATRIX_COLS + i] = DEBOUNCE;
}
}
return result;
}
// Report changed keys in the given row. Resets the debounce countdowns
// corresponding to each set bit in 'change' to DEBOUNCE.
void debounce_report(matrix_row_t change, uint8_t row) {
for (uint8_t i = 0; i < MATRIX_COLS; ++i) {
if (change & (1 << i)) {
debounce_matrix[row * MATRIX_COLS + i] = DEBOUNCE;
}
}
matrix_row_t debounce_read_cols(uint8_t row) {
// Read the row without debouncing filtering and store it for later usage.
matrix_row_t cols = read_cols(row);
// Get the Debounce mask.
matrix_row_t mask = debounce_mask(cols, row);
// debounce the row and return the result.
return (cols & mask) | (matrix[row] & ~mask);;
}
uint8_t matrix_scan(void)
@@ -214,15 +224,12 @@ uint8_t matrix_scan(void)
select_row(i + MATRIX_ROWS_PER_SIDE);
// we don't need a 30us delay anymore, because selecting a
// left-hand row requires more than 30us for i2c.
matrix_row_t mask = debounce_mask(i);
matrix_row_t cols = (read_cols(i) & mask) | (matrix[i] & ~mask);
debounce_report(cols ^ matrix[i], i);
matrix[i] = cols;
// grab cols from left hand
matrix[i] = debounce_read_cols(i);
// grab cols from right hand
mask = debounce_mask(i + MATRIX_ROWS_PER_SIDE);
cols = (read_cols(i + MATRIX_ROWS_PER_SIDE) & mask) | (matrix[i + MATRIX_ROWS_PER_SIDE] & ~mask);
debounce_report(cols ^ matrix[i + MATRIX_ROWS_PER_SIDE], i + MATRIX_ROWS_PER_SIDE);
matrix[i + MATRIX_ROWS_PER_SIDE] = cols;
matrix[i + MATRIX_ROWS_PER_SIDE] = debounce_read_cols(i + MATRIX_ROWS_PER_SIDE);
unselect_rows();
}
@@ -379,7 +386,7 @@ static void select_row(uint8_t row)
break;
case 11:
DDRD |= (1<<2);
PORTD &= ~(1<<3);
PORTD &= ~(1<<2);
break;
case 12:
DDRD |= (1<<3);
@@ -392,4 +399,3 @@ static void select_row(uint8_t row)
}
}
}

View File

@@ -0,0 +1,88 @@
/* 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, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
};

View File

@@ -10,4 +10,34 @@
#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

View File

@@ -0,0 +1,62 @@
{
"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}
]
}
}
}

View File

@@ -1,35 +1,18 @@
#include "arrow_pad.h"
#include QMK_KEYBOARD_H
#include "led.h"
// 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 layers {
LAYER_BASE,
LAYER_EDIT,
LAYER_FUNCTION
};
#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
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 SC_UNDO LCTL(KC_Z)
#define SC_REDO LCTL(KC_Y)
@@ -42,13 +25,10 @@
#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, KC_FN0, \
KC_ESC, KC_TAB, KC_BSLS, MO(2), \
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
KC_P7, KC_P8, KC_P9, KC_PEQL, \
KC_P4, KC_P5, KC_P6, KC_PPLS, \
@@ -57,15 +37,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_EDIT] = LAYOUT( \
KC_ESC, KC_TAB, KC_SPC, _______, \
KC_FN1, SC_PSTE, SC_REDO, SC_UNDO, \
TG(1), 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( \
KC_FN2, KC_FN3, KC_FN4, _______, \
KC_FN1, _______, _______, _______, \
BL_TOGG, BL_INC, BL_DEC, _______, \
TG(1), _______, _______, _______, \
_______, _______, _______, _______, \
_______, _______, _______, _______, \
_______, _______, _______, XXXXXXX, \
@@ -74,68 +54,46 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
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)
{
bool process_record_user(uint16_t keycode, keyrecord_t * record) {
// MACRODOWN only works in this function
switch (id) {
switch (keycode) {
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;
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);
}
break;
return MACRO_NONE;
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;
}
void led_set_user(uint8_t usb_led)

View File

@@ -1,32 +1,18 @@
#include "arrow_pad.h"
#include QMK_KEYBOARD_H
#include "led.h"
// 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 layers {
LAYER_BASE,
LAYER_EDIT,
LAYER_FUNCTION
};
#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
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 SC_UNDO LCTL(KC_Z)
#define SC_REDO LCTL(KC_Y)
@@ -39,100 +25,75 @@
#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, KC_FN0, \
[LAYER_BASE] = LAYOUT_pad21( \
KC_ESC, KC_TAB, KC_BSLS, MO(2), \
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
KC_P7, KC_P8, KC_P9, XXXXXXX, \
KC_P7, KC_P8, KC_P9, \
KC_P4, KC_P5, KC_P6, KC_PPLS, \
KC_P1, KC_P2, KC_P3, XXXXXXX, \
KC_P0, XXXXXXX, KC_PDOT, KC_PENT ),
KC_P1, KC_P2, KC_P3, \
KC_P0, KC_PDOT, KC_PENT ),
[LAYER_EDIT] = LAYOUT( \
[LAYER_EDIT] = LAYOUT_pad21( \
KC_ESC, KC_TAB, KC_SPC, _______, \
KC_FN1, SC_PSTE, SC_REDO, SC_UNDO, \
KC_HOME, KC_UP, KC_PGUP, XXXXXXX, \
TG(1), SC_PSTE, SC_REDO, SC_UNDO, \
KC_HOME, KC_UP, KC_PGUP, \
KC_LEFT, M_COPY, KC_RGHT, M_CTALT, \
KC_END, KC_DOWN, KC_PGDN, XXXXXXX, \
KC_BSPC, XXXXXXX, KC_DEL, M_SHFCT),
KC_END, KC_DOWN, KC_PGDN, \
KC_BSPC, KC_DEL, M_SHFCT),
[LAYER_FUNCTION] = LAYOUT( \
KC_FN2, KC_FN3, KC_FN4, _______, \
KC_FN1, _______, _______, _______, \
_______, _______, _______, XXXXXXX, \
[LAYER_FUNCTION] = LAYOUT_pad21( \
BL_TOGG, BL_INC, BL_DEC, _______, \
TG(1), _______, _______, _______, \
_______, _______, _______, \
_______, _______, _______, _______, \
_______, _______, _______, XXXXXXX, \
RESET, XXXXXXX, _______, _______ ),
_______, _______, _______, \
RESET, _______, _______ ),
};
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)
{
bool process_record_user(uint16_t keycode, keyrecord_t * record) {
// MACRODOWN only works in this function
switch (id) {
switch (keycode) {
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;
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);
}
break;
return MACRO_NONE;
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;
}
void led_set_user(uint8_t usb_led)

View File

@@ -1,35 +1,18 @@
#include "arrow_pad.h"
#include QMK_KEYBOARD_H
#include "led.h"
// 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 layers {
LAYER_BASE,
LAYER_EDIT,
LAYER_FUNCTION
};
#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
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 SC_UNDO LCTL(KC_Z)
#define SC_REDO LCTL(KC_Y)
@@ -42,13 +25,10 @@
#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, KC_FN0, \
KC_ESC, KC_TAB, KC_BSLS, MO(2), \
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
KC_P7, KC_P8, KC_P9, KC_PEQL, \
KC_P4, KC_P5, KC_P6, KC_PPLS, \
@@ -57,15 +37,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_EDIT] = LAYOUT( \
KC_ESC, KC_TAB, KC_SPC, _______, \
KC_FN1, SC_PSTE, SC_REDO, SC_UNDO, \
TG(1), 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( \
KC_FN2, KC_FN3, KC_FN4, _______, \
KC_FN1, _______, _______, _______, \
BL_TOGG, BL_INC, BL_DEC, _______, \
TG(1), _______, _______, _______, \
_______, _______, _______, _______, \
_______, _______, _______, _______, \
_______, _______, _______, XXXXXXX, \
@@ -74,68 +54,46 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
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)
{
bool process_record_user(uint16_t keycode, keyrecord_t * record) {
// MACRODOWN only works in this function
switch (id) {
switch (keycode) {
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;
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);
}
break;
return MACRO_NONE;
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;
}
void led_set_user(uint8_t usb_led)

View File

@@ -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 KEYMAP( \
#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, ___PLS, \
KM___7, KM___8, KM___9, \
KM___4, KM___5, KM___6, KM_PLS, \
KM___1, KM___2, KM___3, ___ENT, \
KM___0, _____0, KM_DOT, KM_ENT \
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, }, \
@@ -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 default`.
To build with the default keymap, simply run `make handwired/arrow_pad: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 [default|pad_21|pad_24|<name>]
$ make handwired/arrow_pad:[default|pad_21|pad_24|<name>]
```
Keymaps follow the format **__\<name\>.c__** and are stored in the `keymaps` folder.

View File

@@ -1,3 +1,2 @@
SRC += pico/matrix.c \
pico/split_util.c \
ws2812.c
SRC += pico/matrix.c
SRC += pico/split_util.c

View File

@@ -4,6 +4,7 @@
#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.

View File

@@ -11,7 +11,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
switch(keycode) {
case KC_LOCK:
if (record->event.pressed) {
if (edvorakjp_config.enable_kc_lang) {
if (get_enable_kc_lang()) {
SEND_STRING( SS_LCTRL(SS_LSFT(SS_TAP(X_POWER))) );
} else {
SEND_STRING( SS_LGUI("l") );

View File

@@ -5,7 +5,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_EDVORAK] = LAYOUT_kc(
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
LBRC,RBRC,COMM,DOT , P , Y , F , G , R , W , Q ,BSLS,
LBRC,RBRC,COMM,DOT , Y , P , F , G , R , W , Q ,BSLS,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
EQL , A , O , E , I , U , D , T , N , S , M ,MINS,
//|----+----+----+----+----+----| |----+----+----+----+----+----|

View File

@@ -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 , P , Y , F , G , R , W , Q ,BSLS,
LBRC,RBRC,COMM,DOT , Y , P , F , G , R , W , Q ,BSLS,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
EQL , A , O , E , I , U , D , T , N , S , M ,MINS,
//|----+----+----+----+----+----+----. ,----|----+----+----+----+----+----|

View File

@@ -23,15 +23,10 @@ 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}}};
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]);
}
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]);
// 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];
@@ -63,7 +58,7 @@ void render_status(struct CharacterMatrix *matrix) {
// Host Keyboard LED Status
char led[40];
snprintf(led, sizeof(led), "\n%s %s %s %s",
edvorakjp_config.enable_jp_extra_layer && japanese_mode ? "EXT" : " ",
get_enable_jp_extra_layer() && get_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" : " ");

View File

@@ -1,4 +1,3 @@
SRC += rev2/matrix.c
SRC += rev2/split_util.c
SRC += rev2/split_scomm.c
SRC += ws2812.c

View File

@@ -0,0 +1,21 @@
/* Copyright 2017 Benjamin Kesselring
*
* 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

View File

@@ -0,0 +1,67 @@
/* Copyright 2018 Milton Griffin
*
* 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
// Keyboard Layers
#define _QW 0
#define _FN 1
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* QWERTY
* .--------------------------------------------------------------------------------------------------------------------------------------.
* | ESC | 1 | 2 | 3 | 4 | 5 | - | ` | = | 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 | SPACE | SPACE | FN | RALT | RGUI | RCTRL |
* '--------------------------------------------------------------------------------------------------------------------------------------'
*/
[_QW] = LAYOUT_ortho_5x15( /* QWERTY */
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_MINS, KC_GRV, KC_EQL, 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_LBRC, KC_BSLS, KC_RBRC, 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_SPC, KC_SPC, MO(_FN), KC_RALT, KC_RGUI, KC_RCTL \
),
/* FUNCTION
* .--------------------------------------------------------------------------------------------------------------------------------------.
* | F1 | F2 | F3 | F4 | F5 | F6 | NUM LK | P/ | P* | F7 | F8 | F9 | F10 | F11 | F12 |
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
* | SELECT | CALC | MYCOMP | MAIL | RGB HD | RGB HI | P7 | P8 | P9 | - | | | PR SCR | SCR LK | PAUSE |
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
* | PREV | PLAY | NEXT | STOP | RGB SD | RGB SI | P4 | P5 | P6 | + | | RESET | | | |
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
* | VOL- | MUTE | VOL+ | APP | RGB VD | RGB VI | 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_MYCM, KC_MAIL, RGB_HUD, RGB_HUI, KC_P7, KC_P8, KC_P9, KC_MINS, _______, _______, KC_PSCR, KC_SLCK, KC_PAUS, \
KC_MPRV, KC_MPLY, KC_MNXT, KC_MSTP, RGB_SAD, RGB_SAI, KC_P4, KC_P5, KC_P6, KC_PLUS, _______, RESET, _______, _______, _______, \
KC_VOLD, KC_MUTE, KC_VOLU, KC_APP, RGB_VAD, RGB_VAI, 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), _______, _______, _______ \
),
};

View File

@@ -0,0 +1 @@
# The default keymap for xd75, with led controls

View File

@@ -0,0 +1,14 @@
# 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/>.

View File

@@ -0,0 +1,19 @@
/* 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

View File

@@ -0,0 +1,67 @@
/* 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), _______, _______, _______ \
),
};

View File

@@ -0,0 +1 @@
# Updated the keymap, based off XD75 default, to meet my needs. Refer to rules.mk to enable or disable rgb and other features.

View File

@@ -0,0 +1,19 @@
# 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

View File

@@ -79,3 +79,5 @@ 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

View File

@@ -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, _______, _______, _______, _______, EPRM,
VRSN, _________________ADJUST_L1_________________, KC_NUKE, _______, _______, _______, _______, EEP_RST,
_______, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, TG_MODS,
_______, _________________ADJUST_L3_________________, TG_GAME, _______, _________________ADJUST_R3_________________, KC_MPLY,
_______, _______, _______, _______, _______, _______

View File

@@ -8,7 +8,7 @@ RGBLIGHT_ENABLE = yes
AUDIO_ENABLE = yes
NKRO_ENABLE = yes
BACKLIGHT_ENABLE = no
SWAP_HANDS_ENABLE = yes
SWAP_HANDS_ENABLE = no
INDICATOR_LIGHTS = yes
MACROS_ENABLED = no

View File

@@ -26,5 +26,6 @@
#define MOUSEKEY_WHEEL_TIME_TO_MAX 20
#define TAPPING_TERM 120
#define SWAP_SCLN
#endif

View File

@@ -1,7 +1,4 @@
#include QMK_KEYBOARD_H
#include "action_layer.h"
#include "eeconfig.h"
#include "edvorakjp.h"
enum custom_keycodes {
@@ -32,7 +29,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 , P , Y , F , G , R , W , Q ,BSLS,
LBRC,RBRC,COMM,DOT , Y , P , F , G , R , W , Q ,BSLS,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
EQL , A , O , E , I , U , D , T , N , S , M ,MINS,
//|----+----+----+----+----+----+----. ,----|----+----+----+----+----+----|
@@ -134,7 +131,7 @@ bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
switch(keycode) {
case KC_LOCK:
if (record->event.pressed) {
if (edvorakjp_config.enable_kc_lang) {
if (get_enable_kc_lang()) {
SEND_STRING( SS_LCTRL(SS_LSFT(SS_TAP(X_POWER))) );
} else {
SEND_STRING( SS_LGUI("l") );

View File

@@ -1,6 +1,4 @@
#include "eeconfig.h"
extern keymap_config_t keymap_config;
#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.

View File

@@ -1 +1,16 @@
#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

View File

@@ -67,4 +67,6 @@ 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

View File

@@ -0,0 +1,189 @@
#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
}
}

View File

@@ -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_________________, EPRM,
VRSN, _________________ADJUST_L2_________________, _______, _______, _______, KC_NUKE, _________________ADJUST_R2_________________, EEP_RST,
TG_MODS, _________________ADJUST_L3_________________, _______, _______, _______, _______, _______, _______, _________________ADJUST_R3_________________, KC_MPLY
)
};

View File

@@ -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 | | LGUI | Alt |Lower | SPC | Enter|Raise |Point.| | LOCK | Ctrl |
* `-----------------------------------------------------------------------------------'
*/
[_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_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
),
/* Lower

View File

@@ -35,6 +35,19 @@ 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,
@@ -81,7 +94,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* window ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
* switcher │ │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ │
* ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
* │ │ - │ + │ ` │ | │ : │ │ , │ . │ \ │ │
* │ │ - │ + │ ` │SFTIN│ : │ | │ , │ . │ \ │ │
* ├─────┼─────┼─────┼─────┼─────┼─────┴─────┼─────┼─────┼─────┼─────┼─────┤
* │ │ │ │ │ │ Backspace │ │ │ │ │ │
* └─────┴─────┴─────┴─────┴─────┴───────────┴─────┴─────┴─────┴─────┴─────┘
@@ -89,8 +102,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, KC_PIPE, KC_COLN, XXXXXXX, XXXXXXX, KC_COMM, KC_DOT, KC_BSLS, _______,
_______, _______, _______, _______, _______, KC_BSPC, KC_BSPC, _______, _______, _______, _______, _______
_______, KC_MINS, KC_PLUS, KC_GRV, SFT_INS, KC_COLN, KC_PIPE, X(IBANG), KC_COMM, KC_DOT, KC_BSLS, _______,
_______, _______, _______, _______, _______, KC_BSPC, KC_BSPC, _______, _______, _______, _______, _______
),
/* Symbol layer
@@ -99,7 +112,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
* │ │ ! │ @ │ # │ $ │ % │ ^ │ & │ * │ ' │ " │ │ \
* ├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤ |-- Mostly shifted version
* │ │ _ │ = │ ~ │ | │ : │ │ │ , │ . │ / │ │ / of lower layer
* │ │ _ │ = │ ~ │SFTIN│ : │ | │ │ , │ . │ / │ │ / of lower layer
* ├─────┼─────┼─────┼─────┼─────┼─────┴─────┼─────┼─────┼─────┼─────┼─────┤
* │ │ │ │ │ │ Delete │ │ │ │ │ │
* └─────┴─────┴─────┴─────┴─────┴───────────┴─────┴─────┴─────┴─────┴─────┘
@@ -107,7 +120,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, KC_PIPE, KC_COLN, XXXXXXX, XXXXXXX, KC_COMM, KC_DOT, KC_SLSH, _______,
_______, KC_UNDS, KC_EQL, KC_TILD, SFT_INS, KC_COLN, KC_PIPE, XXXXXXX, KC_COMM, KC_DOT, KC_SLSH, _______,
_______, _______, _______, _______, _______, KC_DEL, KC_DEL, _______, _______, _______, _______, _______
),
@@ -241,6 +254,10 @@ 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);
}

View File

@@ -1,6 +1,7 @@
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
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

View File

@@ -0,0 +1,41 @@
/*
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

View File

@@ -0,0 +1,33 @@
#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, _______, _______, _______
)
};

View File

@@ -0,0 +1,22 @@
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

View File

@@ -18,12 +18,10 @@ 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

View File

@@ -18,12 +18,10 @@ 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

View File

@@ -18,14 +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_LEFT
// #define MASTER_RIGHT
// #define EE_HANDS
#undef RGBLED_NUM

View File

@@ -18,12 +18,10 @@ 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

View File

@@ -17,16 +17,14 @@ 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

View File

@@ -66,9 +66,7 @@ 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 = no # Enable WS2812 RGB underlight.
SUBPROJECT_rev1 = yes
USE_I2C = yes
RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
SPLIT_KEYBOARD = yes

View File

@@ -0,0 +1,3 @@
#pragma once
#define BACKLIGHT_BREATHING

View File

@@ -0,0 +1,96 @@
#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),
};

View File

@@ -0,0 +1,6 @@
# 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.

View File

@@ -0,0 +1,18 @@
# 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

View File

@@ -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, EPRM, KC_RGB_T,RGB_M_P, RGB_M_B, RGB_M_R, RGB_SAI,
MEDIA, EEP_RST, 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,5 +94,3 @@ void matrix_init_keymap(void) {
DDRB &= ~(1<<0);
PORTB &= ~(1<<0);
}

View File

@@ -1,5 +1,18 @@
<!-- -*- mode: markdown; fill-column: 8192 -*- -->
## v1.12
*2018-11-22*
### Overall changes
* Updated to work with QMK master.
### Miscellaneous
* The `😂` symbol can be entered with UCIS.
* `LEAD r` now inputs `Right Alt`.
## v1.11
*2017-10-01*

Binary file not shown.

After

Width:  |  Height:  |  Size: 103 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 104 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 136 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

View File

@@ -13,6 +13,7 @@
#include "eeconfig.h"
#include "wait.h"
#include "version.h"
#include "print.h"
/* Layers */
@@ -1033,6 +1034,10 @@ void matrix_scan_user(void) {
}
#endif
SEQ_ONE_KEY (KC_R) {
ang_tap(KC_RALT, 0);
}
SEQ_ONE_KEY (KC_T) {
time_travel = !time_travel;
}
@@ -1126,7 +1131,8 @@ const qk_ucis_symbol_t ucis_symbol_table[] = UCIS_TABLE
UCIS_SYM("micro", 0x00b5),
UCIS_SYM("tm", 0x2122),
UCIS_SYM("child", 0x1f476),
UCIS_SYM("family", 0x1F46A)
UCIS_SYM("family", 0x1F46A),
UCIS_SYM("joy", 0x1F602)
);
bool process_record_user (uint16_t keycode, keyrecord_t *record) {

View File

@@ -3,7 +3,12 @@
algernon's layout
=======================
This is an unconventional layout for the [ErgoDox EZ][ez]. For more details about the history of the layout, see my [blog posts about my ErgoDox journey][blog-ergodox].
This is the layout I used to use on my [ErgoDox EZ][ez], while I was using [QMK][qmk]. I no longer do so, and this repository is obsolete, and not updated anymore. My current firmware is based on [Kaleidoscope][kaleidoscope], and is located [elsewhere][ergodox-sketch]. I'm keeping the repo around for historical and educational purposes.
[kaleidoscope]: https://github.com/keyboardio/Kaleidoscope
[ergodox-sketch]: https://git.madhouse-project.org/algernon/ErgoDox-sketch
Nevertheless, this is an unconventional layout for the [ErgoDox EZ][ez]. For more details about the history of the layout, see my [blog posts about my ErgoDox journey][blog-ergodox].
[ez]: https://ergodox-ez.com/
[blog-ergodox]: https://asylum.madhouse-project.org/blog/tags/ergodox/
@@ -57,6 +62,7 @@ At its core, this is a Dvorak layout, with some minor changes. The more interest
- `LEAD d` toggles logging keypress positions to the HID console.
- `LEAD t` toggles time travel. Figuring out the current `date` is left as an exercise to the reader.
- `LEAD u` enters the [Unicode symbol input](#unicode-symbol-input) mode.
- `LEAD r` inputs `Right Alt`, which is the `Compose` key of my choice.
The symbols on the front in the image above have the same color as the key that activates them, with the exception of the **Arrow** layer, which is just black on the front.
@@ -128,13 +134,13 @@ $ git clone https://github.com/qmk/qmk_firmware.git
$ cd qmk_firmware
$ git clone https://github.com/algernon/ergodox-layout.git \
layouts/community/ergodox/algernon_master
$ make ergodox_ez-algernon_master
$ make ergodox_ez:algernon_master
```
From time to time, updates may be submitted back to the QMK repository. If you are reading it there, you can build the firmware like any other firmware included with it (assuming you are in the root directory of the firmware):
```
$ make ergodox_ez-algernon
$ make ergodox_ez:algernon
```
## Using on Windows

View File

@@ -9,8 +9,9 @@ KEYLOGGER_ENABLE ?= yes
UCIS_ENABLE = yes
MOUSEKEY_ENABLE = no
LEADER_ENABLE = yes
RGBLIGHT_ENABLE = no
AUTOLOG_ENABLE ?= no
AUTOLOG_ENABLE ?= yes
ifeq (${FORCE_NKRO},yes)
OPT_DEFS += -DFORCE_NKRO

View File

@@ -20,8 +20,13 @@ 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
@@ -40,7 +45,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, OSM(MOD_MEH),OSM(MOD_LGUI),KC_LBRC, KC_RBRC, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, UC_SHRG, \
KC_GRV, OS_MEH, OS_HYPR, KC_LBRC, KC_RBRC, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, UC(0x2E2E), \
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) \
@@ -198,7 +203,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,
@@ -263,7 +268,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_________________, _______, _______, _______, _______, _______, _______, _______, EPRM,
VRSN, _________________ADJUST_L1_________________, _______, _______, _______, _______, _______, _______, _______, EEP_RST,
_______, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, TG(_MODS),
_______, _________________ADJUST_L3_________________, _______, _______, _________________ADJUST_R3_________________, KC_MPLY,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
@@ -290,10 +295,6 @@ 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();
@@ -335,3 +336,106 @@ 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

View File

@@ -0,0 +1 @@
Note: This board will not flash if the "g_rgb_leds" const is not set to weak in the ergodox_ez.c file

View File

@@ -0,0 +1,11 @@
#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)

View File

@@ -0,0 +1,67 @@
/* 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
};

View File

@@ -0,0 +1,9 @@
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

View File

@@ -5,6 +5,8 @@ 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

View File

@@ -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_________________, EPRM,
VRSN, _________________ADJUST_L2_________________, _________________ADJUST_R2_________________, EEP_RST,
_______, _________________ADJUST_L3_________________, _________________ADJUST_R3_________________, TG_MODS,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
)

View File

@@ -5,10 +5,10 @@ ifeq ($(strip $(KEYBOARD)), jj40)
SWAP_HANDS_ENABLE = no
endif
ifeq ($(strip $(KEYBOARD)), 4x4)
ifeq ($(strip $(KEYBOARD)), 40percentclub/4x4)
SWAP_HANDS_ENABLE = no
endif
ifeq ($(strip $(KEYBOARD)), zlant)
SWAP_HANDS_ENABLE = no
endif
endif

View File

@@ -3,6 +3,8 @@ AUDIO_ENABLE = no # Audio output on port C6
ifeq ("$(KEYBOARD)","vitamins_included")
RGBLIGHT_ENABLE = no
else ifeq ($(strip $(KEYBOARD)), 40percentclub/4x4)
RGBLIGHT_ENABLE = no
else
RGBLIGHT_ENABLE = yes
endif

Some files were not shown because too many files have changed in this diff Show More