Compare commits

...

25 Commits

Author SHA1 Message Date
Miguel Garcia Rodriguez
e9a67f8fde Fix installation for linux finding ID:fedora in os_release 2018-09-10 20:52:34 -07:00
Thomas Vandaele
265eca0f7c Add manjaro asn arch-based distro 2018-09-10 17:55:46 -07:00
leico
2e0c63e0af improve looks like hang up when first time execute make git-submodule (#3846) 2018-09-10 16:21:54 -07:00
Jeremy Herve
e11e4a91ac Keymap: Redox: add a new Colemak keymap, macOS oriented. (#3861)
* Add my own keymap to the list of available Redox keymaps.

This keymap is a Colemak keymap, and is meant to be used on Mac OS.
More information can be found in the readme.

* Fix "macOS" typo and remove mention of the license.

This directory inherits the project's license.

* Add missing custom keycode.

* Address feedback from PR review

- Remove deprecated code
- Remove RGB logic since it is overwritten by code running later.
2018-09-10 07:39:05 -07:00
Peter Nguyen
7d8f680b50 Fix typo in keymap_swedish.h (#3877)
* Fix typo in keymap_swedish.h

* Update keymap_swedish.h
2018-09-09 19:49:26 -07:00
sK0pe
63852e7a68 Keymap: Adjusted keymaps for standardisation (#3874)
* Added HHKB with 7U space bar
There are backlight changers on the function Z, X and C, mediat controls
have been removed.

* Fixed the default layout and added a keymap
GUI and ALT keys were swapped.
My own keymap which adds calculator, removes power, removes eject.

* Adjusted naming convention of hhkb layout layer

Fixed as per required from code review.

* Updated for qmk configurator

I didn't realise that there was a new standardisation across all the keymaps to accommodate the configurator.

Hopefully fixed now.
2018-09-09 19:47:14 -07:00
MechMerlin
fa1e674bbb 65% and 68 key community layouts (#3872)
* rename 68_ansi layout to 65_ansi layout

* more renames and readme change

* add company names

* add community layouts for 68_ansi

* add 68_ansi support for mf68 type boards

* update readme
2018-09-09 19:45:59 -07:00
Damien
7b8e5d4555 Keymap: Updated my FC660C config (#3870)
* - Fixed DK60 version in config.h

* - Updated dk60 readme with new QMK rules

* - Fixed wording in readme

* Added dbroqua layout for DZ60

I've also updated dz60.h to add "true HHKD" keymap definition (6U
spacebar).

With the default HHKB definition r_alt was not mapped and when I pressed
r_menu it was r_alt.

Regards

* Updated dbroqua layout for HHKB keyboard

Added default configuration and alternate (swap gui/alt keys).

Save user choice in keyboard memory (like plank, thanks for this
feature!).

* Added dbroqua layout for Iris keyboard

* Updated layout and fixed includes

* Added personal layout for FC660C

* Inverted ESC & GRV
2018-09-09 19:43:45 -07:00
Danny
3dbdfbd99a Add support for a different pinout on Split boards (#3869)
* Add support for a different pinout for the right half of a split keyboard (number of cols/rows still has to be the same)
2018-09-09 19:42:46 -07:00
noroadsleft
38c916a368 Keyboard: Updated readmes for 1upkeyboards (#3864)
Corrected the make examples by adding the parent directory.

Updated the QMK Docs links for the build environment setup and the make instructions. Added links to the Newbs Guide.
2018-09-09 19:33:30 -07:00
Yasuhiro Shimizu
93b5c98fbb Keymap: remove unnecessary readme from my helix keymap (#3860) 2018-09-09 19:23:24 -07:00
Josh
17fffc3a51 Keymap: Initial PR for contributing my ortho_4x12 community layout. (#3853)
* Initial keymap with no BL and with Ctrl and Enter on the home row.

* Removing alternative layouts (Dvorak etc.).

* Putting Enter back in the default position, moving Esc next to Alt.

* Replacing grave with del.

* Adding a numpad layer.

* Adding operators and a triple zero to the numpad layer.

* Swapping Alt and Win.

* Updating to use new audio macros.

* Removing numpad layer and changing left space to MOD_HYPR on hold.

* Adding configurable 'clicky keys' feature.

* Cleaning up clicky conditional logic.

* Turning on backlight support and mapping backlight keys in the adjust layer.

* Enabling backlight functionality.

* Adding Adventure time theme song; increasing fake clicky randomness.

* Cleaning up layer constants in my Planck keymap.

* Initial implementation of porting my Planck keymap to a Let's Split.

* Updating keyboards/planck/keymaps/josh to use declarations from new work on master.

* Updating keyboards/lets_split/keymaps/josh to use declarations from new work on master.

* Work in progress migrating Planck and Let's Split keymaps to a community keymap.  Everything is working but Planck backlight.

* Fixing rules.mk to enable backlight & audio correctly on Planck PCBs.  Cleanup.

* Tweaks to get Let's Split working with my community layout.

* Switching to use EE_HANDS in my Let's Split build.

* Adding vitamins_included makefile options to my ortho_4x12 layout.

* Fixing planck/rev6 build -- backlight must be disabled.

* Removing I2C from my rules.mk and addressing it in the config.h instead.

* Moving community layout directory to my reddit username.  :D

* Adding a test encoder function; making lower left a media key and moving esc to a mod tap on ctrl.

* Commenting out -flto in the compiler flags for the vitamins_included keyboard (couldn't figure out how else to turn it off).

* Changing rotary encoder to control media volume.

* Changing backlight and clicky defaults to max brightness no breathing and a low pitch click.

* Initial implementation of backlight flickering.

* Updating my README.md

* Adding LINK_TIME_OPTIMIZATION to the vitamins_included/rev1 as a rules.mk feature.

* Reverting keyboards/vitamins_included/rules.mk to master and using 'filter_out' in my layout instead.

* Adding tested boards to the readme for my layout.

* Per drashna, removing redundant clicky implementation and cleaning up headers.

* Removing an extra include from my keymap.
2018-09-09 19:09:53 -07:00
patrickmt
e68c8f2ac6 Keyboard: CTRL LED scan code mapping fix (#3867)
* CTRL LED scan code mapping fix

Fixed scan codes to properly align with key wiring

* Update scan codes for caps and scroll lock lighting

Update scan codes for caps and scroll lock lighting according to previous scan code mapping update
2018-09-07 14:22:12 -07:00
Danny
7f7c278c3e Keyboard: Add support for Quefrency 65% right half (#3865)
* Add support for Quefrency 65% right half

* Add support for additional thumb key on Rev. 1.1 PCB
2018-09-06 12:49:13 -07:00
TheOneTrueTrench
e0c9f1d9b9 Keymap: Added new Marianas keymap for DZ60 (#3858)
* Added new Marianas keymap for DZ60

* Included suggestions to remove unnecessary line regarding MODS_CTRL_MASK, and added names for layers.

Added enum to define names for layers, and removed unused #DEFINE
2018-09-06 08:08:16 -07:00
Matthew Treadwell
c3b3f33c6a Keymap: Update personal keymap (#3855)
* Updated personal keymap

* simplified keymap based on suggestions
2018-09-05 16:39:00 -07:00
Michael F. Lamb
e72d07c22b Keymap: mitosis/datagrok: bug fix (#3854)
I don't know how this slipped past the test suite in the last merge, but
this syntax I tried is invalid and doesn't compile. Fixed.
2018-09-05 13:52:29 -07:00
Luke Stanley
155850187d Keyboard: Add IBM 122-key Terminal keyboard and my Ergodox EZ keymap (Programmer's Dvorak + Gaming/QWERTY layer) (#3850)
* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* Add keyboard information and separated my custom layout from the default

* Add readme to Lukaus' Ergodox EZ keymap

* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* Add keyboard information and separated my custom layout from the default

* Add readme to Lukaus' Ergodox EZ keymap

* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* Fix merge conflict again?

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* Add keyboard information and separated my custom layout from the default

* Add readme to Lukaus' Ergodox EZ keymap

* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* added my lukaus keymap (programmers dvorak with QWERTY, function, and mouse/keypad layers)

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* updated ergodox_ez keymap and initial commit for IBM Model M 122 key

* Add keyboard information and separated my custom layout from the default

* update keymap

* Update rules.mk to remove redundant commented line

* Fix missing key on default layout for IBM Model M 122 key

* Fix issues identified by drashna and noroadsleft

* Update readme for IBM 122 key
2018-09-05 13:45:19 -07:00
antonio miranda
2b09900bdc Keymap: Add am keymap (#3843)
* Add am keymap

* Add configuration to play nice with stuck modifiers

This is in particular useful with emacs since its easy to get ctrl stuck

* Deactivate mouse keys and backlight

* Add control/esc and shift/enter taps

* Remove DVORAK and PLOVER

I won't be using this soon, so getting some free space

* Raiser and Lower ideas from jeebak

* Add cursor and mouse layers

* Enable mouse keys

* Switch underscore with minus

* Disable audio and fix warnings

* Update to the upstream changes

* VIM line motion symbols on the raise layer

* Enable sound and freeup some media keys on layers

* Fix whitespace on keymap

* Code review changes

* Improve keymap documentation

* Improve keymap to match to the default one

* Restore DEFAULT_FOLDER to the default value

* Fix config.h unescaped line
2018-09-05 13:41:27 -07:00
patrickmt
e5465e1c57 CTRL and ALT updates
Added support to enter bootloader from software (bootloader version must be newer than "v2.18Jun 22 2018 17:28:08" until workaround for older is created).
Updated CTRL and ALT keymaps for entering bootloader with Fn+b held for >500ms.
Added basic MacOS keymap for ALT.
USB sleep LED indicator now turns off after 1 second.
Slowed down debug LED code printing.
2018-09-05 11:14:31 -07:00
yiancar
73a3399d0e Add the ability to disable the USB startup check for Chibios
- Added support for NO_USB_STARTUP_CHECK. This allows the keyboard do function and not get stuck in a SUSPENDED state loop in case of no USB connection.
- Added support for WAIT_FOR_USB. In LUFA no keyboard has this flag enable therefor no keyboard waits for usb to be active.
- Added documentation for both configuration flags as they were missing.
2018-09-05 09:42:04 -04:00
MechMerlin
1a907a1627 Keyboard: formatting changes for readme and enable bootmagic (#3851) 2018-09-04 13:29:58 -07:00
Michael F. Lamb
224b4dea98 mitosis:datagrok add layer select, more layouts (#3835)
* mitosis:datagrok: fix typo'd inconsistent brace arrangement

(thank you @cari66ean)

* mitosis:datagrok: add makefile argument MITOSIS_DATAGROK_SLOWUART

* mitosis:datagrok: return backspace to opposite space, use TT(), more

- move backspace back to its position opposite space
- move del to red+backspace
- move tab back to tap-leftshift
- move printscreen/scrolllock/pause to blue+left pinky column
- use TT() instead of MO() to stick a layer on if wanted
- indentation that my text editor wants
- default to no audio; i can enable it at compile time.

* mitosis:datagrok: modularize features, add default layer rotator key

* mitosis: add MITOSIS_DATAGROK_BOTTOMSPACE makefile argument

* mitosis:datagrok: README improvements; document new features

* mitosis:datagrok: dot. not "number pad dot." in numbers layer

* mitosis:datagrok remove unnecessary _user audio code

* mitosis:datagrok: return to MO() for red/blue, keep TT() for purple

in this way, the LED still updates quickly when red or blue is pressed,
but we can still lock the purple layer on for 10-key numpad operation
with red+tapping blue.

* mitosis:datagrok: add colemak and dvorak default layers

* mitosis:datagrok update readme re: available default layouts

* mitosis: remove unneeded code that was overriding led_set_user

also, add some comments

* mitosis:datagrok: updated led setting code for new layers

also, place into led_set_user where it belongs, not matrix_scan_user.

* mitosis:datagrok: update LEDs when setting the default layer

maybe this should go into default_layer_set?

* mitosis:datagrok update readme with new imgur links + other improvements

* mitosis:datagrok fix typo in image urls

* mitosis:datagrok remove useless #include (ty @drashna)

* mitosis:datagrok undo unnecessary change to quantum/quantum.h

i can put the extern float definition in my own keymap code. (ty @drashna)

* mitosis:datagrok move customized layout to my keymap

no need to modify keyboard-level mitosis.h. (ty @drashna)

* mitosis:datagrok update comment describing my led indicator logic

* datagrok:mitosis update readme to document LED indicator.
2018-09-04 08:55:31 -07:00
Emīls Delle
40718d2ca3 Keymap: Create ISO HHKB keymapping for GH60 (#3832)
* Create ISO HHKB keymapping for GH60

* Add media controls to Fn layer

* Use M(x) instead of F(x), add Copyright text
2018-09-04 08:52:52 -07:00
marksard
0533ea4a20 Keymap: Added a keymap like a JIS keyboard for JJ 40. (#3847) 2018-09-04 08:52:00 -07:00
86 changed files with 4255 additions and 358 deletions

View File

@@ -578,7 +578,7 @@ lib/%:
git-submodule:
git submodule sync --recursive
git submodule update --init --recursive
git submodule update --init --recursive --progress
ifdef SKIP_VERSION
SKIP_GIT := yes

View File

@@ -248,3 +248,7 @@ Use these to enable or disable building certain features. The more you have enab
* Enable Bluetooth with the Adafruit EZ-Key HID
* `SPLIT_KEYBOARD`
* Enables split keyboard support (dual MCU like the let's split and bakingpy's boards) and includes all necessary files located at quantum/split_common
* `WAIT_FOR_USB`
* Forces the keyboard to wait for a USB connection to be established before it starts up
* `NO_USB_STARTUP_CHECK`
* Disables usb suspend check after keyboard startup. Usually the keyboard waits for the host to wake it up before any tasks are performed. This is useful for split keyboards as one half will not get a wakeup call but must send commands to the master.

View File

@@ -10,6 +10,6 @@ Hardware Availability: [1upkeyboards.com](https://www.1upkeyboards.com/shop/cont
Make example for this keyboard (after setting up your build environment):
make 1up60hse:default
make 1upkeyboards/1up60hse:default
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
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).

View File

@@ -8,6 +8,6 @@ Hardware Availability: [1upkeyboards](https://www.1upkeyboards.com/shop/controll
Make example for this keyboard (after setting up your build environment):
make 1up60rgb:default
make 1upkeyboards/1up60rgb:default
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
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).

View File

@@ -9,6 +9,6 @@ Hardware Availability: [1up Keyboards](https://1upkeyboards.com/)
Make example for this keyboard (after setting up your build environment):
make sweet16:default
make 1upkeyboards/sweet16:default
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
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).

View File

@@ -0,0 +1,71 @@
#include QMK_KEYBOARD_H
enum marianas_layers {
BASE,
NAV_CLUSTER,
RGB,
MOUSE,
GAMING,
FN_LAYER,
LAYER_SEL
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[BASE]=
LAYOUT(
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_NO, KC_BSPC,
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,
MO(FN_LAYER), 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_LSPO, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSPC, KC_NO,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_LGUI, KC_NO, KC_APP, KC_RCTL),
[NAV_CLUSTER]=
LAYOUT(
KC_TRNS, KC_PSCREEN, KC_SCROLLLOCK, KC_PAUSE, KC_INSERT, KC_HOME, KC_PGUP, KC_NUMLOCK, KC_KP_SLASH, KC_KP_ASTERISK, KC_KP_MINUS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_DELETE, KC_END, KC_PGDOWN, KC_KP_7, KC_KP_8, KC_KP_9, KC_KP_PLUS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_UP, KC_UP, KC_KP_4, KC_KP_5, KC_KP_6, KC_KP_PLUS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RIGHT, KC_KP_1, KC_KP_2, KC_KP_3, KC_KP_ENTER, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_KP_0, KC_KP_0, KC_KP_0, KC_KP_DOT, KC_KP_ENTER, KC_TRNS, KC_TRNS, KC_TRNS),
[RGB]=
LAYOUT(
KC_TRNS, RGB_TOG, RGB_MOD, RGB_M_P, RGB_M_B, RGB_M_R, RGB_M_SW, RGB_M_SN, RGB_M_K, RGB_M_X, RGB_M_G, RGB_SPD, RGB_SPI, KC_TRNS, KC_TRNS,
KC_TRNS, RGB_HUI, RGB_HUD, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, RGB_SAI, RGB_SAD, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, RGB_VAI, RGB_VAD, 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),
[MOUSE]=
LAYOUT(
KC_TRNS, KC_ACL0, KC_ACL1, KC_ACL2, 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_WH_U, KC_TRNS, KC_TRNS, KC_TRNS, KC_BTN3, KC_BTN1, KC_MS_U, KC_BTN2, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_WH_L, KC_WH_D, KC_WH_R, KC_TRNS, KC_TRNS, KC_BTN4, KC_MS_L, KC_MS_D, KC_MS_R, KC_BTN5, 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),
[GAMING]=
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_NO, KC_BSPC,
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_TRNS, 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_LSHIFT, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSHIFT, KC_NO,
KC_LCTL, KC_NO, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_RCTL, KC_NO, KC_NO, TO(BASE)),
[FN_LAYER]=
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_DEL,
KC_CAPSLOCK, KC_MPRV, KC_MPLY, KC_MNXT, LWIN(KC_R), KC_TRNS, KC_CALC, KC_PGUP, KC_UP, KC_PGDN, KC_PSCR, KC_SLCK, KC_BRK, KC_TRNS,
KC_TRNS, KC_VOLD, KC_MUTE, KC_VOLU, KC_TRNS, KC_TRNS, KC_HOME, KC_LEFT, KC_DOWN, KC_RIGHT, KC_INS, KC_DEL, MO(LAYER_SEL),
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_END, 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_HYPR, KC_TRNS, KC_MEH, KC_TRNS),
[LAYER_SEL]=
LAYOUT(
TO(BASE), TO(NAV_CLUSTER), TO(RGB), TO(MOUSE), TO(GAMING), 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)
};

View File

@@ -0,0 +1,16 @@
#pragma once
#define CONFIG_USER_H
#define TAPPING_TERM 200
#ifdef RGBLIGHT_ENABLE
#undef RGBLIGHT_SAT_STEP
#define RGBLIGHT_SAT_STEP 12
#define RGBLIGHT_EFFECT_KNIGHT_LENGTH 7
#define RGBLIGHT_EFFECT_SNAKE_LENGTH 7
#define RGBLIGHT_EFFECT_BREATHE_CENTER 1
#endif // RGBLIGHT_ENABLE
#define FORCE_NKRO
#define MODS_SHIFT_MASK (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT))

View File

@@ -0,0 +1,843 @@
#include QMK_KEYBOARD_H
#include "version.h"
#include "keymap_german.h"
#include "keymap_nordic.h"
enum custom_keycodes {
PLACEHOLDER = SAFE_RANGE, // can always be here
// Programmer's Dvorak "macros" :
// To be paired with get_mods to enable both
// Shift functionality and Programmer's Dvorak
DVP_ESC, // Grave escape basically i think
DVP_AMPR,
DVP_LBRACKET,
DVP_LCBR,
DVP_RCBR,
DVP_LPRN,
DVP_AT,
DVP_EQUAL,
DVP_ASTERISK,
DVP_RPRN,
DVP_PLUS,
DVP_RBRACKET,
DVP_EXLM,
DVP_HASH,
RU_2,
RU_3,
RU_4,
RU_6,
RU_7,
RU_DOT,
SHFT_COMMA,
SHFT_DOT,
RGB_SLD,
RGB_FF0000,
RGB_008000,
RGB_0000FF,
RGB_FFFFFF,
RGB_800080
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// Programmer's Dvorak layer
[0] = LAYOUT_ergodox(
DVP_ESC, DVP_AMPR, DVP_LBRACKET, DVP_LCBR, DVP_RCBR, DVP_LPRN, DVP_AT,
KC_TAB, KC_SCOLON, KC_COMMA, KC_DOT, KC_P, KC_Y, MO(4),
MO(3), KC_A, KC_O, KC_E, KC_U, KC_I,
KC_LSHIFT, KC_QUOTE, KC_Q, KC_J, KC_K, KC_X, KC_HYPR,
KC_LCTL, KC_LALT, KC_LGUI, LCTL(KC_C), LCTL(KC_V),
KC_MS_BTN3, TO(1), KC_HOME, KC_SPACE, MO(4), KC_END,
DVP_EQUAL, DVP_ASTERISK, DVP_RPRN, DVP_PLUS, DVP_RBRACKET, DVP_EXLM, DVP_HASH,
TT(4), KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLASH,
KC_D, KC_H, KC_T, KC_N, KC_S, KC_MINUS,
KC_MEH, KC_B, KC_M, KC_W, KC_V, KC_Z, MO(3),
KC_DELETE, KC_BSLASH, KC_RGUI, KC_RCTL, LCTL(KC_F),
KC_F17, KC_F18, KC_PGUP, KC_PGDOWN, KC_ENTER, KC_BSPACE
),
// Gaming QWERTY layer
[1] = LAYOUT_ergodox(
KC_ESCAPE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_F14,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_F23,
MO(3), KC_A, KC_S, KC_D, KC_F, KC_G,
KC_LSHIFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_F24,
KC_LCTL, KC_F8, KC_LALT, KC_F14, KC_F13,
KC_HOME, TO(0), KC_F15, KC_SPACE, KC_LCTL, KC_LALT,
KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQUAL,
KC_F24, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLASH,
KC_H, KC_J, KC_K, KC_L, KC_SCOLON, KC_QUOTE,
KC_F17, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLASH, KC_RSHIFT,
KC_DELETE, KC_F19, KC_LGUI, KC_F21, KC_F22,
KC_F17, KC_F18, KC_PGUP, KC_PGDOWN, KC_ENTER, KC_BSPACE
),
[2] = LAYOUT_ergodox(
KC_ESCAPE, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_C,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, TO(0),
MO(3), KC_1, KC_2, KC_3, KC_4, KC_5,
KC_LSHIFT, KC_6, KC_7, KC_8, KC_9, KC_0, KC_NO,
KC_LCTL, KC_F8, KC_LALT, KC_I, KC_S,
KC_MS_BTN3, TO(1), KC_HOME, KC_SPACE, KC_LSHIFT, KC_END,
KC_NO, KC_NUMLOCK, KC_KP_SLASH, KC_KP_ASTERISK, KC_KP_MINUS, KC_NO, KC_NO,
TO(0), KC_KP_7, KC_KP_8, KC_KP_9, KC_KP_PLUS, KC_NO, KC_NO,
KC_KP_4, KC_KP_5, KC_KP_6, KC_EQUAL, KC_NO, KC_NO,
KC_NO, KC_KP_1, KC_KP_2, KC_KP_3, KC_KP_ENTER, KC_NO, KC_NO,
KC_KP_0, KC_KP_DOT, KC_NO, KC_NO, KC_NO,
TO(0), KC_F18, KC_PGUP, KC_PGDOWN, KC_ENTER, KC_BSPACE
),
// Function Layer
[3] = LAYOUT_ergodox(
KC_DLR, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_TRANSPARENT,
KC_TRANSPARENT, KC_TRANSPARENT, KC_MEDIA_PREV_TRACK,KC_MEDIA_PLAY_PAUSE,KC_MEDIA_NEXT_TRACK,KC_NO, TT(4),
KC_TRANSPARENT, KC_TRANSPARENT, KC_AUDIO_VOL_DOWN, KC_AUDIO_VOL_UP, KC_AUDIO_MUTE, KC_TRANSPARENT,
KC_LSHIFT, LALT(KC_Z), KC_TRANSPARENT, KC_TRANSPARENT, KC_F12, KC_TRANSPARENT, ALL_T(KC_NO),
KC_LCTL, KC_LALT, KC_LGUI, KC_CAPSLOCK, LSFT(KC_F12),
KC_PSCREEN, KC_PGUP, KC_PGDOWN, KC_SPACE, KC_LSHIFT, KC_INSERT,
KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,
KC_NO, KC_HOME, KC_TRANSPARENT, KC_PSCREEN, KC_SLCK, KC_TRANSPARENT, KC_TRANSPARENT,
KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_TRANSPARENT, KC_TRANSPARENT,
MEH_T(KC_NO), KC_CALCULATOR, KC_TRANSPARENT, KC_TRANSPARENT, KC_TRANSPARENT, KC_TRANSPARENT, KC_RSHIFT,
KC_DELETE, KC_INSERT, KC_TRANSPARENT, KC_F19, KC_RCTL,
TO(2),KC_TRANSPARENT,KC_TRANSPARENT,LALT(KC_F10),KC_ENTER,KC_BSPACE
),
// Keypad, Lighting, and Mouse emulation layer
///*
[4] = LAYOUT_ergodox(
KC_ESCAPE, KC_NO, KC_NO, KC_MS_BTN3, KC_NO, KC_NO, KC_NO,
KC_TAB, KC_NO, KC_MS_BTN2, KC_MS_UP, KC_MS_BTN1, KC_MS_WH_UP, TO(0),
KC_NO, KC_NO, KC_MS_LEFT, KC_MS_DOWN, KC_MS_RIGHT, KC_MS_WH_DOWN,
KC_LSHIFT, KC_NO, KC_NO, KC_UP, KC_NO, KC_NO, TO(5),
KC_LCTL, KC_NO, KC_LEFT, KC_DOWN, KC_RIGHT,
KC_MS_BTN3, TO(1), KC_HOME, KC_SPACE, KC_LSHIFT, KC_END,
KC_NO, KC_NUMLOCK, KC_KP_SLASH, KC_KP_ASTERISK, KC_CALCULATOR, KC_NO, RGB_VAI,
TO(0), KC_KP_7, KC_KP_8, KC_KP_9, KC_KP_MINUS, KC_NO, RGB_VAD,
KC_KP_4, KC_KP_5, KC_KP_6, KC_KP_PLUS, KC_NO, RGB_HUI,
KC_NO, KC_KP_1, KC_KP_2, KC_KP_3, KC_EQUAL, RGB_SLD, RGB_HUD,
KC_KP_0, KC_KP_DOT, KC_KP_ENTER, RGB_MOD, RGB_TOG,
KC_F17, KC_F18, KC_PGUP, KC_PGDOWN, KC_ENTER, KC_BSPACE
)
//*/
/*
// Keypad, Lighting, and Mouse emulation layer
[4] = KEYMAP(
KC_ESCAPE, KC_NO, KC_NO, KC_MS_BTN3, KC_NO, KC_NO, KC_NO,
KC_TAB, KC_NO, KC_MS_BTN2, KC_MS_UP, KC_MS_BTN1, KC_MS_WH_UP, TO(0),
KC_NO, KC_NO, KC_MS_LEFT, KC_MS_DOWN, KC_MS_RIGHT, KC_MS_WH_DOWN,
KC_LSHIFT, KC_NO, KC_NO, KC_UP, KC_NO, KC_NO, TO(5),
KC_LCTL, KC_NO, KC_LEFT, KC_DOWN, KC_RIGHT,
KC_MS_BTN3, TO(1), KC_HOME, KC_SPACE, KC_LSHIFT, KC_END,
KC_NO, KC_I, KC_NUMLOCK, KC_KP_SLASH, KC_KP_ASTERISK, KC_CALCULATOR, RGB_VAI,
TO(0), KC_G, KC_KP_7, KC_KP_8, KC_KP_9, KC_KP_MINUS, RGB_VAD,
SHFT_COMMA, KC_KP_4, KC_KP_5, KC_KP_6, KC_KP_PLUS, RGB_HUI,
KC_NO, SHFT_DOT, KC_KP_1, KC_KP_2, KC_KP_3, KC_EQUAL, RGB_HUD,
KC_NO, KC_KP_0, KC_KP_DOT, KC_KP_ENTER, RGB_TOG,
KC_F17, KC_F18, KC_PGUP, KC_PGDOWN, KC_ENTER, KC_BSPACE
)
*/
};
void led_set_keymap(uint8_t usb_led) {
}
void matrix_init_user (void) {
}
bool left_shift_down = false;
bool right_shift_down = false;
bool numlock = false;
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case KC_LSHIFT:
if (record->event.pressed)
{
left_shift_down = true;
return true;
}
else
{
left_shift_down = false;
return true;
}
break;
case KC_RSHIFT:
if (record->event.pressed)
{
right_shift_down = true;
return true;
}
else
{
right_shift_down = false;
return true;
}
break;
case KC_NUMLOCK:
if (record->event.pressed)
{
numlock = !numlock;
}
break;
case DVP_ESC:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
SEND_STRING("~");
return false;
}
else
{
if(record->event.pressed)
SEND_STRING(SS_DOWN(X_ESCAPE));
else
SEND_STRING(SS_UP(X_ESCAPE));
return false;
}
break;
case DVP_AMPR:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
SEND_STRING("%");
}
}
else
{
if(record->event.pressed)
SEND_STRING("&");
}
return false;
break;
case SHFT_DOT:
if(record->event.pressed)
SEND_STRING(">");
break;
case SHFT_COMMA:
if(record->event.pressed)
SEND_STRING("<");
break;
case DVP_LBRACKET:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_7);
unregister_code(KC_7);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("[");
}
return false;
return false;
break;
case DVP_LCBR:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_5);
unregister_code(KC_5);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("{");
}
return false;
break;
case DVP_RCBR:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_3);
unregister_code(KC_3);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("}");
}
return false;
break;
case DVP_LPRN:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_1);
unregister_code(KC_1);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("(");
}
return false;
break;
case DVP_AT:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_LSHIFT);
register_code(KC_6);
unregister_code(KC_6);
unregister_code(KC_LSHIFT);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("@");
}
return false;
break;
case DVP_EQUAL:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_9);
unregister_code(KC_9);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("=");
}
return false;
break;
case DVP_ASTERISK:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_0);
unregister_code(KC_0);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("*");
}
return false;
break;
case DVP_RPRN:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_2);
unregister_code(KC_2);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING(")");
}
return false;
break;
case DVP_PLUS:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_4);
unregister_code(KC_4);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("+");
}
return false;
break;
case DVP_RBRACKET:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_6);
unregister_code(KC_6);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("]");
}
return false;
break;
case DVP_EXLM:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_8);
unregister_code(KC_8);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("!");
}
return false;
break;
case DVP_HASH:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
// Russian
case RU_2:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case RU_3:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case RU_4:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case RU_6:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case RU_7:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case RU_DOT:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case RGB_SLD:
if (record->event.pressed) {
rgblight_mode(1);
}
return false;
break;
case RGB_FF0000:
if (record->event.pressed) {
#ifdef RGBLIGHT_ENABLE
rgblight_enable();
rgblight_mode(1);
rgblight_setrgb(0xff,0x00,0x00);
#endif
}
return false;
break;
case RGB_008000:
if (record->event.pressed) {
#ifdef RGBLIGHT_ENABLE
rgblight_enable();
rgblight_mode(1);
rgblight_setrgb(0x00,0x80,0x00);
#endif
}
return false;
break;
case RGB_0000FF:
if (record->event.pressed) {
#ifdef RGBLIGHT_ENABLE
rgblight_enable();
rgblight_mode(1);
rgblight_setrgb(0x00,0x00,0xff);
#endif
}
return false;
break;
case RGB_FFFFFF:
if (record->event.pressed) {
#ifdef RGBLIGHT_ENABLE
rgblight_enable();
rgblight_mode(1);
rgblight_setrgb(0xff,0xff,0xff);
#endif
}
return false;
break;
case RGB_800080:
if (record->event.pressed) {
#ifdef RGBLIGHT_ENABLE
rgblight_enable();
rgblight_mode(1);
rgblight_setrgb(0x80,0x00,0x80);
#endif
}
return false;
break;
}
return true;
}
uint32_t layer_state_set_user(uint32_t state) {
uint8_t layer = biton32(state);
// ergodox_board_led_off();
ergodox_right_led_1_off();
ergodox_right_led_2_off();
ergodox_right_led_3_off();
switch (layer) {
case 0:
break;
case 1:
ergodox_right_led_1_on();
break;
case 2:
ergodox_right_led_2_on();
break;
case 3:
ergodox_right_led_3_on();
break;
case 4:
ergodox_right_led_1_on();
ergodox_right_led_3_on();
break;
default:
break;
}
return state;
};

View File

@@ -0,0 +1,3 @@
# Lukaus' keymap
Programmer's Dvorak as default layer with Qwerty gaming layer and two function layers

View File

@@ -0,0 +1 @@
#UNICODE_ENABLE = yes

View File

@@ -3,7 +3,7 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* BASE layer: Default Layer
* ,--------------------------------------------------------------------------------------------------.
* | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | Backspace | | Ins |
* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | Backspace | | Ins |
* |-----------------------------------------------------------------------------------------+ +-----+
* | Tab | Q | W | E | R | T | Y | U | I | O | P | [ | ] | Bksp | | Del |
* |-----------------------------------------------------------------------------------------+ +-----+
@@ -15,7 +15,7 @@ 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_INS,
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_INS,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC,KC_RBRC,KC_BSLS, KC_DEL,
KC_LCTL,KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT, KC_ENT,
KC_LSFT,KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM,KC_DOT, KC_SLSH,KC_RSFT, KC_UP,
@@ -23,7 +23,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
),
/* FN layer
* ,--------------------------------------------------------------------------------------------------.
* | ` | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | | | |
* | Esc| F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | | | |
* |-----------------------------------------------------------------------------------------+ +-----+
* | | | | | | | | |PrtSc| Slck| Paus| | | | | |
* |-----------------------------------------------------------------------------------------+ +-----+
@@ -35,7 +35,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
* `--------------------------------------------------------------------------------------------------´
*/
[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_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_SLCK,KC_PAUS,_______,_______,_______, _______,
_______,KC_VOLD,KC_VOLU,KC_MUTE,KC_EJCT,_______,_______,_______,KC_HOME,KC_PGUP,_______,_______, _______,
_______,KC_MPRV,KC_MPLY,KC_MNXT,_______,_______,_______,_______,KC_END, KC_PGDN,_______,_______, _______,

View File

@@ -0,0 +1,51 @@
/* Copyright 2018 Funderburker
*
* 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
// Fillers to make layering more clear
#define _______ KC_TRNS
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/*
ISO HHKB layout:
* 2u Backspace
* ISO Enter
* split left Shift
* split right Shift
* Caps as Control
* 1u/1.5u/7u/1.5u//1u bottom row
*/
/* 0: QWERTY */
[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_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_NO,
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_BSLS, KC_ENT,
KC_LSFT, KC_GRV, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, MO(1), KC_RSFT,
KC_NO, KC_LALT, KC_LGUI, KC_SPC, KC_NO, KC_NO, KC_RALT, KC_CAPSLOCK, KC_NO
),
/* 1: Fn layer */
[1] = LAYOUT(
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_HOME, KC_END, KC_UP, _______, _______,
_______, KC_MUTE, KC_VOLD, KC_VOLU, _______, _______, _______, _______, _______, KC_PGUP, KC_LEFT, KC_RGHT, _______, _______,
_______, KC_MPRV, KC_MPLY, KC_MNXT, _______, _______, _______, _______, _______, _______, KC_PGDN, KC_DOWN, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______
),
};

View File

@@ -0,0 +1,190 @@
/*
Copyright 2018 REPLACE_WITH_YOUR_NAME
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 0x0000
#define DEVICE_VER 0x0001
#define MANUFACTURER IBM
#define PRODUCT IBM Model M 122 key
#define DESCRIPTION Mapping by github.com/lukexorz
/* key matrix size */
#define MATRIX_ROWS 8
#define MATRIX_COLS 20
/*
* 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_COL_PINS { E6, B7, D0, D1, D2, D3, D4, D5, D6, D7, E0, E1, C0, C1, C2, C3, C4, C5, C7, F1 }
#define MATRIX_ROW_PINS { F0, B5, B4, B3, B2, B1, B0, E7 }
#define UNUSED_PINS
/* COL2ROW, ROW2COL, or CUSTOM_MATRIX */
#define DIODE_DIRECTION ROW2COL
// #define BACKLIGHT_PIN B7
// #define BACKLIGHT_BREATHING
// #define BACKLIGHT_LEVELS 3
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
#define DEBOUNCING_DELAY 15
/* define if matrix has ghost (lacks anti-ghosting diodes) */
//#define MATRIX_HAS_GHOST
/* number of backlight levels */
/* 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)) \
)
#define B6_AUDIO
#define C6_AUDIO
/* 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

View File

@@ -0,0 +1,43 @@
/* Copyright 2018 REPLACE_WITH_YOUR_NAME
*
* 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 "ibm122m.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);
}

View File

@@ -0,0 +1,42 @@
/* Copyright 2018 REPLACE_WITH_YOUR_NAME
*
* 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"
// This a shortcut to help you visually see your layout.
// The following is an example using the Planck MIT layout
// The first section contains all of the arguments
// The second converts the arguments into a two-dimensional array
#define LAYOUT( \
k09, k19, k1A, k29, k39, k3A, k49, k59, k5A, k69, k79, k7A, k3G, k3H, k2G, \
k0A, k0B, k1B, k2A, k2B, k3B, k4A, k4B, k5B, k6A, k6B, k7B, k1G, k5G, k4G, \
k31, k32, k34, k24, k25, k26, k27, k37, k38, k28, k2C, k2D, k2E, k3E, k3C, k3F, k2F, k2H, k2I, k20, \
k21, k41, k42, k44, k45, k46, k47, k57, k58, k48, k4C, k4D, k4E, k5E, k5C, k6F, k4F, k4H, k4I, k40, \
k51, k52, k62, k14, k15, k16, k17, k07, k08, k18, k1C, k1D, k1E, k0E, k6E, k1F, k1H, k1I, k10, \
k11, k12, k73, k74, k64, k65, k66, k67, k77, k78, k68, k6C, k6D, k7E, k63, k0G, k61, k6H, k6I, k7J, \
k02, k01, k00, k70, k71, k03, k72, k60, k0J, k1J, k7H, k7I, \
k0F \
) \
{ \
{ k00, k01, k02, k03, KC_NO, KC_NO, KC_NO, k07, k08, k09, k0A, k0B, KC_NO, KC_NO, k0E, k0F, k0G, KC_NO, KC_NO, k0J }, \
{ k10, k11, k12, KC_NO, k14, k15, k16, k17, k18, k19, k1A, k1B, k1C, k1D, k1E, k1F, k1G, k1H, k1I, k1J }, \
{ k20, k21, KC_NO, KC_NO, k24, k25, k26, k27, k28, k29, k2A, k2B, k2C, k2D, k2E, k2F, k2G, k2H, k2I, KC_NO }, \
{ KC_NO, k31, k32, KC_NO, k34, KC_NO, KC_NO, k37, k38, k39, k3A, k3B, k3C, KC_NO, k3E, k3F, k3G, k3H, KC_NO, KC_NO }, \
{ k40, k41, k42, KC_NO, k44, k45, k46, k47, k48, k49, k4A, k4B, k4C, k4D, k4E, k4F, k4G, k4H, k4I, KC_NO }, \
{ KC_NO, k51, k52, KC_NO, KC_NO, KC_NO, KC_NO, k57, k58, k59, k5A, k5B, k5C, KC_NO, k5E, KC_NO, k5G, KC_NO, KC_NO, KC_NO }, \
{ k60, k61, k62, k63, k64, k65, k66, k67, k68, k69, k6A, k6B, k6C, k6D, k6E, k6F, KC_NO, k6H, k6I, KC_NO }, \
{ k70, k71, k72, k73, k74, KC_NO, KC_NO, k77, k78, k79, k7A, k7B, KC_NO, KC_NO, k7E, KC_NO, KC_NO, k7H, k7I, k7J }, \
}

View File

View File

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

View File

@@ -0,0 +1,46 @@
/* Copyright 2018 REPLACE_WITH_YOUR_NAME
*
* 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
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// Original Layer
[0] = LAYOUT(
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_INS, KC_HOME, KC_PGUP,
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_END, KC_PGDN,
KC_ESC, KC_NO, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQL, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
KC_NO, KC_NO, 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_ENTER, KC_P7, KC_P8, KC_P9, KC_PPLS,
KC_NO, KC_NO, KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCOLON, KC_QUOT, KC_BSLS, KC_P4, KC_P5, KC_P6, KC_BSPC,
KC_NO, KC_NO, KC_LSHIFT,KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_NO, KC_NO, KC_LCTRL, KC_LALT, KC_SPC, KC_RALT, KC_RCTRL, KC_LEFT, KC_NO, KC_RIGHT,KC_P0, KC_PDOT,
KC_DOWN),
};
void matrix_init_user(void) {
}
void matrix_scan_user(void) {
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
return true;
}
void led_set_user(uint8_t usb_led) {
}

View File

@@ -0,0 +1,2 @@
# The default keymap for ibm122m2
The 10 keys to the left of the alphanumerics are unbound (other than Escape on the top-left one) as I have no idea what is supposed to go there.

View File

@@ -0,0 +1,19 @@
/* Copyright 2018 REPLACE_WITH_YOUR_NAME
*
* 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,587 @@
/* Copyright 2018 REPLACE_WITH_YOUR_NAME
*
* 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 custom_keycodes {
PLACEHOLDER = SAFE_RANGE,
DVP_ESC, // Grave escape basically i think
DVP_AMPR,
DVP_LBRACKET,
DVP_LCBR,
DVP_RCBR,
DVP_LPRN,
DVP_AT,
DVP_EQUAL,
DVP_ASTERISK,
DVP_RPRN,
DVP_PLUS,
DVP_RBRACKET,
DVP_EXLM,
DVP_HASH,
SHFT_DOT,
SHFT_COMMA
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// Programmer's Dvorak
[0] = LAYOUT(
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_INS, KC_HOME, KC_PGUP,
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_END, KC_PGDN,
KC_ESC, TO(1), DVP_ESC, DVP_AMPR, DVP_LBRACKET, DVP_LCBR, DVP_RCBR, DVP_LPRN, DVP_EQUAL,DVP_ASTERISK, DVP_RPRN, DVP_PLUS, DVP_RBRACKET, DVP_EXLM, DVP_HASH, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
KC_NO, TO(2), KC_TAB, KC_SCOLON,KC_COMMA, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH, DVP_AT, KC_ENTER, KC_P7, KC_P8, KC_P9, KC_PPLS,
KC_NO, KC_NO, MO(3), KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_MINUS, KC_BSLS, KC_P4, KC_P5, KC_P6, MO(4),
LCTL(KC_F), KC_LALT, KC_LSHIFT,KC_ESC, KC_QUOT, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
LCTL(KC_C), LCTL(KC_V), KC_LCTRL, KC_LGUI, KC_SPC, KC_RALT, KC_RCTRL, KC_LEFT, KC_BTN3, KC_RIGHT, KC_P0, KC_PDOT,
KC_DOWN
),
// Qwerty layer + function
[1] = LAYOUT(
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_INS, KC_HOME, KC_PGUP,
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_END, KC_PGDN,
KC_ESC, TO(0), KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQL, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
KC_NO, KC_NO, 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_ENTER, KC_P7, KC_P8, KC_P9, KC_PPLS,
KC_NO, KC_NO, MO(3), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCOLON, KC_QUOT, KC_BSLS, KC_P4, KC_P5, KC_P6, KC_BSPC,
KC_NO, KC_NO, KC_LSHIFT,KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_NO, KC_LALT,KC_LCTRL, KC_LGUI, KC_SPC, KC_RALT, KC_RCTRL, KC_LEFT, KC_WH_D, KC_RIGHT,KC_P0, KC_PDOT,
KC_DOWN
),
// Orirginal Layer
[2] = LAYOUT(
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_INS, KC_HOME, KC_PGUP,
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_END, KC_PGDN,
KC_ESC, TO(1), KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQL, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
KC_NO, TO(0), 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_ENTER, KC_P7, KC_P8, KC_P9, KC_PPLS,
KC_NO, KC_NO, KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCOLON, KC_QUOT, KC_BSLS, KC_P4, KC_P5, KC_P6, KC_BSPC,
KC_NO, KC_NO, KC_LSHIFT,KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT,
KC_NO, KC_LALT,KC_LCTRL, KC_LGUI, KC_SPC, KC_RALT, KC_RCTRL, KC_LEFT, KC_WH_D, KC_RIGHT,KC_P0, KC_PDOT,
KC_DOWN
),
// Function Layer
[3] = LAYOUT(
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_HOME, KC_PGUP,
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_DEL, KC_END, KC_PGDN,
MU_TOG, KC_NO, KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQL, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
MU_MOD, KC_NO, KC_TAB, KC_NO, KC_MEDIA_PREV_TRACK, KC_MEDIA_PLAY_PAUSE, KC_MEDIA_NEXT_TRACK, KC_NO, KC_NO, KC_PGUP, KC_DEL, KC_NO, KC_NO, KC_LBRC, KC_RBRC,KC_ENTER, KC_NO, KC_NO, KC_NO, KC_PPLS,
KC_NO, KC_NO, KC_TRNS, KC_NO, KC_AUDIO_VOL_DOWN, KC_AUDIO_VOL_UP, KC_AUDIO_MUTE, KC_NO, KC_LEFT, KC_DOWN, KC_UP, KC_RIGHT, KC_SCOLON, KC_QUOT, KC_BSLS, LSFT(KC_E), LSFT(KC_F), KC_NO, KC_BSPC,
KC_NO, KC_LALT, KC_LSHIFT,KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_PGDN, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, LSFT(KC_B), LSFT(KC_C), LSFT(KC_D), KC_PENT,
KC_NO, KC_NO, KC_LCTRL, KC_LGUI, KC_SPC, KC_RALT, KC_CAPS, KC_LEFT, KC_WH_D, KC_RIGHT,LSFT(KC_A), KC_PDOT,
KC_DOWN
),
// Literally just the numpad is different
[4] = LAYOUT(
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_INS, KC_HOME, KC_PGUP,
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_END, KC_PGDN,
KC_ESC, TO(1), DVP_ESC, DVP_AMPR, DVP_LBRACKET, DVP_LCBR, DVP_RCBR, DVP_LPRN, DVP_EQUAL,DVP_ASTERISK, DVP_RPRN, DVP_PLUS, DVP_RBRACKET, DVP_EXLM, DVP_HASH, KC_BSPC, KC_NO, KC_NO, KC_NO, KC_NO,
KC_NO, TO(2), KC_TAB, KC_SCOLON,KC_COMMA, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L, KC_SLSH, DVP_AT, KC_ENTER, KC_BTN1, KC_MS_U, KC_BTN2, KC_NO,
KC_NO, KC_NO, TO(0), KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S, KC_MINUS, KC_BSLS, KC_MS_L, KC_NO, KC_MS_R, KC_TRNS,
LCTL(KC_F), KC_LALT, KC_LSHIFT,KC_NO, KC_QUOT, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z, KC_RSFT, KC_UP, KC_GT, KC_MS_D, KC_GT, KC_PENT,
LCTL(KC_C), LCTL(KC_V), KC_LCTRL, KC_LGUI, KC_SPC, KC_RALT, KC_RCTRL, KC_LEFT, KC_BTN3, KC_RIGHT, KC_BTN1, KC_PDOT,
KC_DOWN
),
/*
[4] = LAYOUT(
KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_F18, KC_F19, KC_F20, KC_F21, KC_F22, KC_F23, KC_F24, KC_INS, KC_HOME, KC_PGUP,
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_END, KC_PGDN,
MU_TOG, TO(0), KC_DLR, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINUS, KC_EQL, KC_BSPC, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS,
MU_MOD, KC_NO, KC_TAB, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_LBRC, KC_RBRC,KC_ENTER, KC_NO, KC_NO, KC_NO, KC_PPLS,
KC_NO, KC_NO, KC_TRNS, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_QUOT, KC_BSLS, LSFT(KC_E), LSFT(KC_F), KC_NO, KC_BSPC,
KC_NO, KC_LALT, KC_LSHIFT,KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_COMMA, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, LSFT(KC_B), LSFT(KC_C), LSFT(KC_D), KC_PENT,
KC_NO, KC_LGUI, KC_LCTRL, KC_LALT, KC_SPC, KC_RALT, KC_RCTRL, KC_LEFT, KC_WH_D, KC_RIGHT, LSFT(KC_A), KC_PDOT,
KC_DOWN
),*/
/*[0] = LAYOUT(
KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_NO,TO(1),KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1, KC_1,
KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, TO(2),KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2, KC_2,
KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3, KC_3,
KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_4, KC_BSPC,KC_4,KC_4,KC_4, KC_4,
KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5, KC_5,
KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6, KC_6,
KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7, KC_7,
KC_8, KC_SPC,KC_8,KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, KC_8, TO(1)
),
[1] = LAYOUT(
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, TO(0),KC_NO,KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, TO(2),KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, KC_L, KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, KC_L, KC_M, KC_N, KC_O, KC_BSPC,KC_Q,KC_R,KC_S, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, KC_L, KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, KC_L, KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, KC_L, KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, KC_T,
KC_A, KC_SPC,KC_C,KC_D, KC_E, KC_F, KC_G, KC_H, KC_I, KC_J, KC_K, KC_L, KC_M, KC_N, KC_O, KC_P, KC_Q, KC_R, KC_S, TO(0)
),
[2] = LAYOUT(
KC_LCTRL, KC_LALT, KC_C, KC_RALT, KC_E, KC_F, KC_G, KC_G, KC_H, KC_J, TO(0), TO(1), KC_M, KC_N, KC_QUOT, KC_DOWN, KC_UP, KC_R, KC_S, KC_ENTER,
KC_PPLS, KC_B, KC_C, KC_D, KC_A, KC_S, KC_D, KC_F, KC_J, KC_J, KC_K, KC_NO, KC_K, KC_L, KC_SCOLON, KC_P4, KC_DEL, KC_P5, KC_P6, KC_RIGHT,
KC_PMNS, KC_1, KC_C, KC_D, KC_1, KC_2, KC_3, KC_4, KC_7, KC_J, KC_K, KC_L, KC_8, KC_9, KC_0, KC_NLCK, KC_PGUP,KC_PSLS, KC_PAST, KC_T,
KC_A, KC_ESC, TO(0),KC_D, KC_GRV, KC_F, KC_G, KC_5, KC_6, KC_J, KC_K, KC_L, KC_EQL, KC_N, KC_MINUS, KC_BSPC, KC_INS, KC_HOME, KC_S, KC_T,
KC_PPLS, KC_NO, KC_TAB, KC_D, KC_Q, KC_W, KC_E, KC_R, KC_U, KC_J, KC_K, KC_L, KC_I, KC_O, KC_P, KC_P7, KC_PGDN,KC_P8, KC_P9, KC_T,
KC_A, KC_B, KC_C, KC_D, KC_E, KC_F, KC_G, KC_T, KC_Y, KC_J, KC_K, KC_L, KC_RBRC, KC_N, KC_LBRC, KC_P, KC_END, KC_R, KC_S, KC_T,
KC_LEFT, KC_P1, KC_CAPS, KC_RSFT, KC_Z, KC_X, KC_C, KC_V, KC_M, KC_J, KC_K, KC_L, KC_COMMA, KC_DOT, KC_BSLS, KC_PENT, KC_Q, KC_P2, KC_P3, KC_T,
KC_LGUI, KC_SPACE, KC_RCTRL, KC_LSHIFT, KC_E, KC_F, KC_G, KC_B, KC_N, KC_J, KC_K, KC_L, KC_M, KC_N, KC_SLSH, KC_P, KC_Q, KC_P0, KC_PDOT, KC_KP_ENTER
),*/
};
const uint16_t PROGMEM fn_actions[] = {
};
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
{
// MACRODOWN only works in this function
switch(id) {
case 0:
if (record->event.pressed) {
register_code(KC_RSFT);
} else {
unregister_code(KC_RSFT);
}
break;
}
return MACRO_NONE;
};
void matrix_init_user(void) {
}
void matrix_scan_user(void) {
}
bool left_shift_down = false;
bool right_shift_down = false;
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case KC_LSHIFT:
if (record->event.pressed)
{
left_shift_down = true;
return true;
}
else
{
left_shift_down = false;
return true;
}
break;
case KC_RSHIFT:
if (record->event.pressed)
{
right_shift_down = true;
return true;
}
else
{
right_shift_down = false;
return true;
}
break;
case DVP_ESC:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
SEND_STRING("~");
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("$");
return false;
}
break;
case DVP_AMPR:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
SEND_STRING("%");
}
}
else
{
if(record->event.pressed)
SEND_STRING("&");
return false;
}
break;
case DVP_LBRACKET:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_7);
unregister_code(KC_7);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("[");
return false;
}
break;
case DVP_LCBR:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_5);
unregister_code(KC_5);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("{");
return false;
}
break;
case DVP_RCBR:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_3);
unregister_code(KC_3);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("}");
return false;
}
break;
case DVP_LPRN:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_1);
unregister_code(KC_1);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("(");
return false;
}
break;
//
case DVP_AT:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_LSHIFT);
register_code(KC_6);
unregister_code(KC_6);
unregister_code(KC_LSHIFT);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("@");
return false;
}
break;
case DVP_EQUAL:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_9);
unregister_code(KC_9);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("=");
return false;
}
break;
case DVP_ASTERISK:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_0);
unregister_code(KC_0);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING("*");
return false;
}
break;
case DVP_RPRN:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_2);
unregister_code(KC_2);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
return false;
}
else
{
if(record->event.pressed)
SEND_STRING(")");
return false;
}
break;
case DVP_PLUS:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_4);
unregister_code(KC_4);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("+");
}
return false;
break;
case DVP_RBRACKET:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_6);
unregister_code(KC_6);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("]");
}
return false;
break;
case DVP_EXLM:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_8);
unregister_code(KC_8);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("!");
}
return false;
break;
case DVP_HASH:
if (left_shift_down || right_shift_down)
{
if(record->event.pressed)
{
if(left_shift_down)
unregister_code(KC_LSHIFT);
if(right_shift_down)
unregister_code(KC_RSHIFT);
register_code(KC_GRAVE);
unregister_code(KC_GRAVE);
if(left_shift_down)
register_code(KC_LSHIFT);
if(right_shift_down)
register_code(KC_RSHIFT);
}
}
else
{
if(record->event.pressed)
SEND_STRING("#");
}
return false;
break;
case SHFT_DOT:
if(record->event.pressed)
SEND_STRING(">");
break;
case SHFT_COMMA:
if(record->event.pressed)
SEND_STRING("<");
break;
}
return true;
}
void led_set_user(uint8_t usb_led) {
}

View File

@@ -0,0 +1,2 @@
# Lukaus' for ibm122m2
Programmer's Dvorak as the default layer with a Qwerty layer that can access a function layer. Also includes the default layout, slightly modified

View File

@@ -0,0 +1,16 @@
# ibm122m
![IBM Model M 122 key](https://i.imgur.com/Oo3Ozqz.jpg)
This is a keymap for the IBM Model M 122 key terminal keyboard running on a Teensy 2.0++
I wired it to weird pins on mine (mainly to accomodate speakers), so make sure to update the pin arrays.
Keyboard Maintainer: [Luke Stanley](https://github.com/lukexorz)
Hardware Supported: Teensy 2.0++
Hardware Availability: https://www.pjrc.com/store/teensypp.html
Make example for this keyboard (after setting up your build environment):
make handwired/ibm122m:default
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.

View File

@@ -0,0 +1,67 @@
# MCU name
MCU = at90usb1286
BOOTLOADER = halfKay
# Processor frequency.
# This will define a symbol, F_CPU, in all source code files equal to the
# processor frequency in Hz. You can then use this symbol in your source code to
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
# automatically to create a 32-bit value in your source code.
#
# This will be an integer division of F_USB below, as it is sourced by
# F_USB after it has run through any CPU prescalers. Note that this value
# does not *change* the processor frequency - it should merely be updated to
# reflect the processor speed set externally so that the code can use accurate
# software delays.
F_CPU = 16000000
#
# LUFA specific
#
# Target architecture (see library "Board Types" documentation).
ARCH = AVR8
# Input clock frequency.
# This will define a symbol, F_USB, in all source code files equal to the
# input clock frequency (before any prescaling is performed) in Hz. This value may
# differ from F_CPU if prescaling is used on the latter, and is required as the
# raw input clock is fed directly to the PLL sections of the AVR for high speed
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
# at the end, this will be done automatically to create a 32-bit value in your
# source code.
#
# If no clock division is performed on the input clock inside the AVR (via the
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
F_USB = $(F_CPU)
# Interrupt driven control endpoint task(+60)
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
# Boot Section Size in *bytes*
# Teensy halfKay 512
# Teensy++ halfKay 1024
# Atmel DFU loader 4096
# LUFA bootloader 4096
# USBaspLoader 2048
# Build Options
# change yes to no to disable
#
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 = 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 = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
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 = yes # Audio output on port C6
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches

View File

@@ -1,25 +0,0 @@
SSD1306 OLED Display via I2C
======
Features
--------
Some features supported by the firmware:
* I2C connection between the two halves is required as the OLED display will use this connection as well. Note this
requires pull-up resistors on the data and clock lines.
* OLED display will connect from either side
Wiring
------
Work in progress...
OLED Configuration
-------------------------------
Work in progress...

View File

@@ -0,0 +1,49 @@
/*
This is the c configuration file for the keymap
Copyright 2012 Jun Wako <wakojun@gmail.com>
Copyright 2015 Jack Humbert
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
#define TAPPING_TERM 200
#ifdef MOUSEKEY_ENABLE
#undef MOUSEKEY_INTERVAL
#define MOUSEKEY_INTERVAL 5
#undef MOUSEKEY_TIME_TO_MAX
#define MOUSEKEY_TIME_TO_MAX 150
#undef MOUSEKEY_MAX_SPEED
#define MOUSEKEY_MAX_SPEED 3
#undef MOUSEKEY_MOVE_DELTA
#define MOUSEKEY_MOVE_DELTA 3
#undef MOUSEKEY_DELAY
#define MOUSEKEY_DELAY 0
#endif
#undef BACKLIGHT_LEVELS
#define BACKLIGHT_LEVELS 15
// #undef BACKLIGHT_LEVELS
// #define BACKLIGHT_BREATHING
// #undef BREATHING_PERIOD
// #define BREATHING_PERIOD 4

View File

@@ -0,0 +1,200 @@
#include QMK_KEYBOARD_H
#define _QWERTY 0
#define _LOWER 3
#define _RAISE 4
#define _ADJUST 16
enum custom_keycodes {
LOWER = SAFE_RANGE,
RAISE,
ADJUST,
RGBRST
};
#define KC______ KC_TRNS
#define KC_XXXXX KC_NO
#define KC_KANJI KC_GRV
#define KC_LOWER LOWER
#define KC_RAISE RAISE
#define KC_ADJST ADJUST
#define KC_RST RESET
#define KC_LRST RGBRST
#define KC_LTOG RGB_TOG
#define KC_LHUI RGB_HUI
#define KC_LHUD RGB_HUD
#define KC_LSAI RGB_SAI
#define KC_LSAD RGB_SAD
#define KC_LVAI RGB_VAI
#define KC_LVAD RGB_VAD
#define KC_LSMOD RGB_SMOD
#define KC_BTOG BL_TOGG
#define KC_BINC BL_INC
#define KC_BDEC BL_DEC
// #define KC_BRTG BL_BRTG
#define KC_KNRM AG_NORM
#define KC_KSWP AG_SWAP
// Layer Mode aliases
// #define KC_L_LO MO(_LOWER)
// #define KC_L_RA MO(_RAISE)
// #define KC_L_AD MO(_ADJUST)
#define KC_TBSF LSFT_T(KC_TAB)
// #define KC_SPSF LSFT_T(KC_SPC)
// #define KC_GUAP LALT_T(KC_APP)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = KC_LAYOUT_ortho_4x12( \
//,-----------------------------------------------------------------------------------.
ESC, Q, W, E, R, T, Y, U, I, O, P, MINS,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
TBSF, A, S, D, F, G, H, J, K, L, SCLN, ENT,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
LSFT, Z, X, C, V, B, N, M, COMM, DOT, UP, RSFT,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
LCTRL, LALT, LGUI, ADJST, LOWER, BSPC, SPC, RAISE, APP, LEFT, DOWN, RGHT \
//|------+------+------+------+------+-------------+------+------+------+------+------|
),
[_LOWER] = KC_LAYOUT_ortho_4x12( \
//,-----------------------------------------------------------------------------------.
TAB, F1, F2, F3, F4, F5, XXXXX, MINS, EQL, JYEN, LBRC, RBRC,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
_____, F6, F7, F8, F9, F10, XXXXX, XXXXX, XXXXX, SCLN, QUOT, BSLS,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
_____, F11, F12, XXXXX, KANJI, ENT, XXXXX, XXXXX, COMM, DOT, SLSH, RO,\
//|------+------+------+------+------+-------------+------+------+------+------+------|
_____, _____, _____, _____, _____, DEL, _____, _____, _____, _____, _____, _____ \
//|------+------+------+------+------+-------------+------+------+------+------+------|
),
[_RAISE] = KC_LAYOUT_ortho_4x12( \
//,-----------------------------------------------------------------------------------.
_____, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, MINS,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
_____, XXXXX, XXXXX, XXXXX, XXXXX, XXXXX, XXXXX, 4, 5, 6, QUOT, PLUS,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
_____, XXXXX, XXXXX, XXXXX, XXXXX, XXXXX, 0, 1, 2, 3, DOT, SLSH,\
//|------+------+------+------+------+-------------+------+------+------+------+------|
_____, _____, _____, _____, _____, BSPC, _____, _____, _____, _____, _____, _____ \
//|------+------+------+------+------+-------------+------+------+------+------+------|
),
[_ADJUST] = KC_LAYOUT_ortho_4x12( \
//,-----------------------------------------------------------------------------------.
XXXXX, RST, LRST, KNRM, KSWP, XXXXX, XXXXX, WH_L, WH_U, HOME, PGUP, XXXXX,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
XXXXX, LTOG, LHUI, LSAI, LVAI, BTOG, BINC, WH_R, WH_D, END, PGDN, XXXXX,\
//|------+------+------+------+------+------|------+------+------+------+------+------|
XXXXX, LSMOD, LHUD, LSAD, LVAD, XXXXX, BDEC, XXXXX, BTN1, BTN2, MS_U, XXXXX,\
//|------+------+------+------+------+-------------+------+------+------+------+------|
_____, _____, _____, _____, _____, XXXXX, XXXXX, _____, _____, MS_L, MS_D, MS_R \
//|------+------+------+------+------+-------------+------+------+------+------+------|
)
};
#ifdef BACKLIGHT_ENABLE
extern backlight_config_t backlight_config;
inline void enable_backright(bool on) {
backlight_config.enable = on;
if (backlight_config.raw == 1) // enabled but level = 0
backlight_config.level = 1;
eeconfig_update_backlight(backlight_config.raw);
// dprintf("backlight toggle: %u\n", backlight_config.enable);
backlight_set(backlight_config.enable ? backlight_config.level : 0);
}
uint8_t bl_breath_count;
uint8_t bl_breath_speed = 10;
int8_t bl_breath_updown = 1;
bool bl_breath_on;
backlight_config_t bl_breath_backup;
void bl_breath_start(uint8_t speed) {
bl_breath_on = true;
bl_breath_speed = speed;
bl_breath_backup = backlight_config;
}
void bl_breath_end(void) {
bl_breath_on = false;
backlight_config = bl_breath_backup;
eeconfig_update_backlight(backlight_config.raw);
backlight_set(backlight_config.enable ? backlight_config.level : 0);
}
void bl_breath_update(void) {
if (bl_breath_on) {
++bl_breath_count;
if (bl_breath_count > bl_breath_speed) {
bl_breath_count = 0;
backlight_config.level += bl_breath_updown;
bl_breath_updown = (backlight_config.level > BACKLIGHT_LEVELS) ? -1 :
(backlight_config.level <= 0) ? 1 :
bl_breath_updown;
enable_backright(true);
}
}
}
#define BL_BREATH_START bl_breath_start
#define BL_BREATH_END bl_breath_end
#define BL_BREATH_UPDATE bl_breath_update
#else
#define BL_BREATH_START(a)
#define BL_BREATH_END()
#define BL_BREATH_UPDATE()
#endif
// Loop
void matrix_scan_user(void) {
BL_BREATH_UPDATE();
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case LOWER:
if (record->event.pressed) {
BL_BREATH_START(50);
layer_on(_LOWER);
} else {
BL_BREATH_END();
layer_off(_LOWER);
}
break;
case RAISE:
if (record->event.pressed) {
BL_BREATH_START(100);
layer_on(_RAISE);
} else {
BL_BREATH_END();
layer_off(_RAISE);
}
break;
case ADJUST:
if (record->event.pressed) {
layer_on(_ADJUST);
} else {
layer_off(_ADJUST);
}
break;
default:
return true;
}
return false;
}

View File

@@ -0,0 +1,5 @@
MOUSEKEY_ENABLE = yes
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend

View File

@@ -4,7 +4,8 @@ A WKL Hot Swap Double USB C 60%
Keyboard Maintainer: [MechMerlin](https://github.com/mechmerlin)
Hardware Supported: KBD6x PCB
Hardware Availability: [KBDFans](https://kbdfans.cn/products/kbd6x-wkl-hot-swap-60-double-type-c-pcb)
Hardware Availability: [KBDFans](https://kbdfans.cn/products/kbd6x-wkl-hot-swap-60-double-type-c-pcb)
Make example for this keyboard (after setting up your build environment):
make kbd6x:default

View File

@@ -51,7 +51,7 @@ OPT_DEFS += -DBOOTLOADER_SIZE=4096
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
BOOTMAGIC_ENABLE = yes # 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)

View File

@@ -16,6 +16,12 @@
#define TAPPING_TERM 150
/* default layer sounds */
#define DEFAULT_LAYER_SONGS { SONG(QWERTY_SOUND), \
SONG(GAME_SOUND), \
SONG(COLEMAK_SOUND) \
}
//#undef RGBLED_NUM
//#define RGBLIGHT_ANIMATIONS
//#define RGBLED_NUM 12

View File

@@ -4,7 +4,7 @@ extern keymap_config_t keymap_config;
#define _QWERTY 0
#define _COLEMAK 1
#define _DVORAK 2
#define _GAME 2
#define _NUMB 3
#define _CODE 4
#define _SYS 5
@@ -14,7 +14,7 @@ extern keymap_config_t keymap_config;
enum custom_keycodes {
QWERTY = SAFE_RANGE,
COLEMAK,
DVORAK,
GAME,
NUMB,
CODE,
SYS,
@@ -25,13 +25,9 @@ enum custom_keycodes {
#define KC_ KC_TRNS
#define _______ KC_TRNS
#define KC_CAPW LGUI(LSFT(KC_3)) // Capture whole screen
#define KC_CPYW LGUI(LSFT(LCTL(KC_3))) // Copy whole screen
#define KC_CAPP LGUI(LSFT(KC_4)) // Capture portion of screen
#define KC_CPYP LGUI(LSFT(LCTL(KC_4))) // Copy portion of screen
#define KC_X1 CODE
#define KC_X2 NUMB
#define KC_X3 SYS
#define KC_X3 MO(_SYS)
#define KC_X4 MT(MOD_LSFT, KC_ENT)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
@@ -60,25 +56,25 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
//`----+----+----+----+----+----' `----+----+----+----+----+----'
),
[_DVORAK] = LAYOUT_kc(
[_GAME] = LAYOUT_kc(
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
TAB ,QUOT,COMM,DOT , P , Y , F , G , C , R , L ,MINS,
TAB , Q , W , E , R , T , Y , U , I , O , P ,MINS,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
BSPC, A , O , E , U , I , D , H , T , N , S ,SLSH,
ESC , A , S , D , F , G , H , J , K , L ,SCLN,QUOT,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
LSFT,SCLN, Q , J , K , X , B , M , W , V , Z , X4 ,
LSFT, Z , X , C , V , B , N , M ,COMM,DOT ,SLSH, X4 ,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
X3 ,LCTL,LALT,LGUI, X1 ,LALT, SPC , X2 ,LEFT,DOWN, UP ,RGHT
X3 ,LCTL,LALT,LGUI, X2 , SPC, SPC , X1 ,LEFT,DOWN, UP ,RGHT
//`----+----+----+----+----+----' `----+----+----+----+----+----'
),
[_NUMB] = LAYOUT_kc(
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
TILD,EXLM, AT ,HASH,DLR ,PERC, CIRC,AMPR,ASTR,LPRN,RPRN,PMNS,
TILD,EXLM, AT ,HASH,DLR ,PERC, CIRC,AMPR,ASTR,LPRN,RPRN, DEL,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
GRV , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 0 ,UNDS,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
, ,MPRV,MPLY,MNXT, , ,VOLD,VOLU,MUTE, , ,
, ,MPRV,MNXT,MPLY, , ,VOLD,VOLU,MUTE, , ,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
, , , , ,LALT, , , , , ,
//`----+----+----+----+----+----' `----+----+----+----+----+----'
@@ -90,7 +86,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
//|----+------+----+----+----+----| |----+----+----+----+----+----|
CAPS,SELECT,LEFT,DOWN,RGHT,DEL , PGDN, END,LBRC,RBRC,MINS,UNDS,
//|----+------+----+----+----+----| |----+----+----+----+----+----|
, UNDO ,CUT ,COPY,PASTE, , LEFT,RGHT,LCBR,RCBR,PLUS,PEQL,
LSFT, UNDO ,CUT ,COPY,PASTE, , LEFT,RGHT,LCBR,RCBR,PLUS,PEQL,
//|----+------+----+----+----+----| |----+----+----+----+----+----|
, , , , ,LALT, , , , , ,
//`----+------+----+----+----+----' `----+----+----+----+----+----'
@@ -98,9 +94,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_SYS] = LAYOUT_kc(
//,----+----+----+----+----+----. ,----+----+----+----+----+----.
F12 , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , F9 ,F10 ,F11 ,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
, , , , , , , , , , , ,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
F12 , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , F9 ,F10 ,F11 ,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
, , , , , , , , , , , ,
//|----+----+----+----+----+----| |----+----+----+----+----+----|
@@ -121,7 +117,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
*/
[_ADJUST] = LAYOUT_ortho_4x12( \
_______, RESET , RGB_TOG, RGB_MOD, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, RGB_VAD, RGB_VAI, _______, _______, \
_______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, DVORAK, _______, _______, \
_______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, GAME , _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
)
@@ -129,43 +125,23 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
#ifdef AUDIO_ENABLE
float tone_qwerty[][2] = SONG(QWERTY_SOUND);
float tone_dvorak[][2] = SONG(DVORAK_SOUND);
float tone_colemak[][2] = SONG(COLEMAK_SOUND);
#endif
void persistent_default_layer_set(uint16_t default_layer) {
eeconfig_update_default_layer(default_layer);
default_layer_set(default_layer);
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case QWERTY:
if (record->event.pressed) {
#ifdef AUDIO_ENABLE
PLAY_SONG(tone_qwerty);
#endif
persistent_default_layer_set(1UL<<_QWERTY);
set_single_persistent_default_layer(_QWERTY);
}
return false;
break;
case COLEMAK:
if (record->event.pressed) {
#ifdef AUDIO_ENABLE
PLAY_SONG(tone_colemak);
#endif
persistent_default_layer_set(1UL<<_COLEMAK);
set_single_persistent_default_layer(_COLEMAK);
}
return false;
break;
case DVORAK:
case GAME:
if (record->event.pressed) {
#ifdef AUDIO_ENABLE
PLAY_SONG(tone_dvorak);
#endif
persistent_default_layer_set(1UL<<_DVORAK);
set_single_persistent_default_layer(_GAME);
}
return false;
break;

View File

@@ -19,6 +19,7 @@ enum alt_keycodes {
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
@@ -37,7 +38,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
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_TRNS, \
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, KC_TRNS, TG_NKRO, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PGUP, KC_VOLD, \
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 \
),
/*
@@ -68,6 +69,8 @@ void matrix_scan_user(void) {
#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) {
@@ -194,6 +197,15 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
CDC_print("\r\n");
}
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

@@ -0,0 +1,212 @@
#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_LALT, KC_LGUI, KC_SPC, KC_RGUI, 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_TRNS, \
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 \
),
*/
};
const uint16_t PROGMEM fn_actions[] = {
};
// 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) {
usb_extra_manual = !usb_extra_manual;
CDC_print("USB extra port manual mode ");
CDC_print(usb_extra_manual ? "enabled" : "disabled");
CDC_print("\r\n");
}
return false;
case U_T_AGCR:
if (record->event.pressed && MODS_SHIFT && MODS_CTRL) {
usb_gcr_auto = !usb_gcr_auto;
CDC_print("USB GCR auto mode ");
CDC_print(usb_gcr_auto ? "enabled" : "disabled");
CDC_print("\r\n");
}
return false;
case DBG_TOG:
if (record->event.pressed) {
debug_enable = !debug_enable;
CDC_print("Debug mode ");
CDC_print(debug_enable ? "enabled" : "disabled");
CDC_print("\r\n");
}
return false;
case DBG_MTRX:
if (record->event.pressed) {
debug_matrix = !debug_matrix;
CDC_print("Debug matrix ");
CDC_print(debug_matrix ? "enabled" : "disabled");
CDC_print("\r\n");
}
return false;
case DBG_KBD:
if (record->event.pressed) {
debug_keyboard = !debug_keyboard;
CDC_print("Debug keyboard ");
CDC_print(debug_keyboard ? "enabled" : "disabled");
CDC_print("\r\n");
}
return false;
case DBG_MOU:
if (record->event.pressed) {
debug_mouse = !debug_mouse;
CDC_print("Debug mouse ");
CDC_print(debug_mouse ? "enabled" : "disabled");
CDC_print("\r\n");
}
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

@@ -66,85 +66,85 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
{ .id = 6, .x = 4.875, .y = 0, .adr = { .drv = 2, .cs = 7, .swr = 5, .swg = 4, .swb = 6 }, .scan = 5 }, \
{ .id = 7, .x = 5.625, .y = 0, .adr = { .drv = 2, .cs = 8, .swr = 5, .swg = 4, .swb = 6 }, .scan = 6 }, \
{ .id = 8, .x = 6.375, .y = 0, .adr = { .drv = 1, .cs = 1, .swr = 5, .swg = 4, .swb = 6 }, .scan = 7 }, \
{ .id = 9, .x = 7.125, .y = 0, .adr = { .drv = 1, .cs = 2, .swr = 5, .swg = 4, .swb = 6 }, .scan = 90 }, \
{ .id = 10, .x = 8.25, .y = 0, .adr = { .drv = 1, .cs = 3, .swr = 5, .swg = 4, .swb = 6 }, .scan = 91 }, \
{ .id = 11, .x = 9, .y = 0, .adr = { .drv = 1, .cs = 4, .swr = 5, .swg = 4, .swb = 6 }, .scan = 92 }, \
{ .id = 12, .x = 9.75, .y = 0, .adr = { .drv = 1, .cs = 5, .swr = 5, .swg = 4, .swb = 6 }, .scan = 93 }, \
{ .id = 13, .x = 10.5, .y = 0, .adr = { .drv = 1, .cs = 6, .swr = 5, .swg = 4, .swb = 6 }, .scan = 94 }, \
{ .id = 14, .x = 11.625, .y = 0, .adr = { .drv = 1, .cs = 7, .swr = 5, .swg = 4, .swb = 6 }, .scan = 95 }, \
{ .id = 15, .x = 12.375, .y = 0, .adr = { .drv = 1, .cs = 8, .swr = 5, .swg = 4, .swb = 6 }, .scan = 96 }, \
{ .id = 16, .x = 13.125, .y = 0, .adr = { .drv = 1, .cs = 9, .swr = 5, .swg = 4, .swb = 6 }, .scan = 97 }, \
{ .id = 17, .x = 0, .y = -1.125, .adr = { .drv = 2, .cs = 1, .swr = 8, .swg = 7, .swb = 9 }, .scan = 15 }, \
{ .id = 18, .x = 0.75, .y = -1.125, .adr = { .drv = 2, .cs = 2, .swr = 8, .swg = 7, .swb = 9 }, .scan = 16 }, \
{ .id = 19, .x = 1.5, .y = -1.125, .adr = { .drv = 2, .cs = 3, .swr = 8, .swg = 7, .swb = 9 }, .scan = 17 }, \
{ .id = 20, .x = 2.25, .y = -1.125, .adr = { .drv = 2, .cs = 4, .swr = 8, .swg = 7, .swb = 9 }, .scan = 18 }, \
{ .id = 21, .x = 3, .y = -1.125, .adr = { .drv = 2, .cs = 5, .swr = 8, .swg = 7, .swb = 9 }, .scan = 19 }, \
{ .id = 22, .x = 3.75, .y = -1.125, .adr = { .drv = 2, .cs = 6, .swr = 8, .swg = 7, .swb = 9 }, .scan = 20 }, \
{ .id = 23, .x = 4.5, .y = -1.125, .adr = { .drv = 2, .cs = 7, .swr = 8, .swg = 7, .swb = 9 }, .scan = 21 }, \
{ .id = 24, .x = 5.25, .y = -1.125, .adr = { .drv = 2, .cs = 8, .swr = 8, .swg = 7, .swb = 9 }, .scan = 22 }, \
{ .id = 25, .x = 6, .y = -1.125, .adr = { .drv = 1, .cs = 1, .swr = 8, .swg = 7, .swb = 9 }, .scan = 105 }, \
{ .id = 26, .x = 6.75, .y = -1.125, .adr = { .drv = 1, .cs = 2, .swr = 8, .swg = 7, .swb = 9 }, .scan = 106 }, \
{ .id = 27, .x = 7.5, .y = -1.125, .adr = { .drv = 1, .cs = 3, .swr = 8, .swg = 7, .swb = 9 }, .scan = 107 }, \
{ .id = 28, .x = 8.25, .y = -1.125, .adr = { .drv = 1, .cs = 4, .swr = 8, .swg = 7, .swb = 9 }, .scan = 108 }, \
{ .id = 29, .x = 9, .y = -1.125, .adr = { .drv = 1, .cs = 5, .swr = 8, .swg = 7, .swb = 9 }, .scan = 109 }, \
{ .id = 30, .x = 10.125, .y = -1.125, .adr = { .drv = 1, .cs = 6, .swr = 8, .swg = 7, .swb = 9 }, .scan = 110 }, \
{ .id = 31, .x = 11.625, .y = -1.125, .adr = { .drv = 1, .cs = 7, .swr = 8, .swg = 7, .swb = 9 }, .scan = 111 }, \
{ .id = 32, .x = 12.375, .y = -1.125, .adr = { .drv = 1, .cs = 8, .swr = 8, .swg = 7, .swb = 9 }, .scan = 112 }, \
{ .id = 33, .x = 13.125, .y = -1.125, .adr = { .drv = 1, .cs = 9, .swr = 8, .swg = 7, .swb = 9 }, .scan = 142 }, \
{ .id = 34, .x = 0.188, .y = -1.875, .adr = { .drv = 2, .cs = 1, .swr = 11, .swg = 10, .swb = 12 }, .scan = 30 }, \
{ .id = 35, .x = 1.125, .y = -1.875, .adr = { .drv = 2, .cs = 2, .swr = 11, .swg = 10, .swb = 12 }, .scan = 31 }, \
{ .id = 36, .x = 1.875, .y = -1.875, .adr = { .drv = 2, .cs = 3, .swr = 11, .swg = 10, .swb = 12 }, .scan = 32 }, \
{ .id = 37, .x = 2.625, .y = -1.875, .adr = { .drv = 2, .cs = 4, .swr = 11, .swg = 10, .swb = 12 }, .scan = 33 }, \
{ .id = 38, .x = 3.375, .y = -1.875, .adr = { .drv = 2, .cs = 5, .swr = 11, .swg = 10, .swb = 12 }, .scan = 34 }, \
{ .id = 39, .x = 4.125, .y = -1.875, .adr = { .drv = 2, .cs = 6, .swr = 11, .swg = 10, .swb = 12 }, .scan = 35 }, \
{ .id = 40, .x = 4.875, .y = -1.875, .adr = { .drv = 2, .cs = 7, .swr = 11, .swg = 10, .swb = 12 }, .scan = 36 }, \
{ .id = 41, .x = 5.625, .y = -1.875, .adr = { .drv = 2, .cs = 8, .swr = 11, .swg = 10, .swb = 12 }, .scan = 37 }, \
{ .id = 42, .x = 6.375, .y = -1.875, .adr = { .drv = 1, .cs = 1, .swr = 11, .swg = 10, .swb = 12 }, .scan = 120 }, \
{ .id = 43, .x = 7.125, .y = -1.875, .adr = { .drv = 1, .cs = 2, .swr = 11, .swg = 10, .swb = 12 }, .scan = 121 }, \
{ .id = 44, .x = 7.875, .y = -1.875, .adr = { .drv = 1, .cs = 3, .swr = 11, .swg = 10, .swb = 12 }, .scan = 122 }, \
{ .id = 45, .x = 8.625, .y = -1.875, .adr = { .drv = 1, .cs = 4, .swr = 11, .swg = 10, .swb = 12 }, .scan = 123 }, \
{ .id = 46, .x = 9.375, .y = -1.875, .adr = { .drv = 1, .cs = 5, .swr = 11, .swg = 10, .swb = 12 }, .scan = 124 }, \
{ .id = 47, .x = 10.312, .y = -1.875, .adr = { .drv = 1, .cs = 6, .swr = 11, .swg = 10, .swb = 12 }, .scan = 125 }, \
{ .id = 48, .x = 11.625, .y = -1.875, .adr = { .drv = 1, .cs = 7, .swr = 11, .swg = 10, .swb = 12 }, .scan = 126 }, \
{ .id = 49, .x = 12.375, .y = -1.875, .adr = { .drv = 1, .cs = 8, .swr = 11, .swg = 10, .swb = 12 }, .scan = 127 }, \
{ .id = 50, .x = 13.125, .y = -1.875, .adr = { .drv = 1, .cs = 9, .swr = 11, .swg = 10, .swb = 12 }, .scan = 141 }, \
{ .id = 51, .x = 0.281, .y = -2.625, .adr = { .drv = 2, .cs = 1, .swr = 5, .swg = 4, .swb = 6 }, .scan = 45 }, \
{ .id = 52, .x = 1.313, .y = -2.625, .adr = { .drv = 2, .cs = 2, .swr = 5, .swg = 4, .swb = 6 }, .scan = 46 }, \
{ .id = 53, .x = 2.063, .y = -2.625, .adr = { .drv = 2, .cs = 13, .swr = 11, .swg = 10, .swb = 12 }, .scan = 47 }, \
{ .id = 54, .x = 2.812, .y = -2.625, .adr = { .drv = 2, .cs = 12, .swr = 11, .swg = 10, .swb = 12 }, .scan = 48 }, \
{ .id = 55, .x = 3.562, .y = -2.625, .adr = { .drv = 2, .cs = 11, .swr = 11, .swg = 10, .swb = 12 }, .scan = 49 }, \
{ .id = 56, .x = 4.312, .y = -2.625, .adr = { .drv = 2, .cs = 6, .swr = 5, .swg = 4, .swb = 6 }, .scan = 50 }, \
{ .id = 57, .x = 5.062, .y = -2.625, .adr = { .drv = 2, .cs = 10, .swr = 11, .swg = 10, .swb = 12 }, .scan = 51 }, \
{ .id = 58, .x = 5.812, .y = -2.625, .adr = { .drv = 2, .cs = 9, .swr = 11, .swg = 10, .swb = 12 }, .scan = 52 }, \
{ .id = 59, .x = 6.562, .y = -2.625, .adr = { .drv = 1, .cs = 16, .swr = 11, .swg = 10, .swb = 12 }, .scan = 135 }, \
{ .id = 60, .x = 7.312, .y = -2.625, .adr = { .drv = 1, .cs = 15, .swr = 11, .swg = 10, .swb = 12 }, .scan = 136 }, \
{ .id = 61, .x = 8.062, .y = -2.625, .adr = { .drv = 1, .cs = 14, .swr = 11, .swg = 10, .swb = 12 }, .scan = 137 }, \
{ .id = 62, .x = 8.812, .y = -2.625, .adr = { .drv = 1, .cs = 13, .swr = 11, .swg = 10, .swb = 12 }, .scan = 138 }, \
{ .id = 63, .x = 10.031, .y = -2.625, .adr = { .drv = 1, .cs = 12, .swr = 11, .swg = 10, .swb = 12 }, .scan = 139 }, \
{ .id = 64, .x = 0.469, .y = -3.375, .adr = { .drv = 2, .cs = 14, .swr = 5, .swg = 4, .swb = 6 }, .scan = 60 }, \
{ .id = 65, .x = 1.688, .y = -3.375, .adr = { .drv = 2, .cs = 13, .swr = 5, .swg = 4, .swb = 6 }, .scan = 61 }, \
{ .id = 66, .x = 2.438, .y = -3.375, .adr = { .drv = 2, .cs = 12, .swr = 8, .swg = 7, .swb = 9 }, .scan = 62 }, \
{ .id = 67, .x = 3.188, .y = -3.375, .adr = { .drv = 2, .cs = 12, .swr = 5, .swg = 4, .swb = 6 }, .scan = 63 }, \
{ .id = 68, .x = 3.938, .y = -3.375, .adr = { .drv = 2, .cs = 11, .swr = 5, .swg = 4, .swb = 6 }, .scan = 64 }, \
{ .id = 69, .x = 4.688, .y = -3.375, .adr = { .drv = 2, .cs = 10, .swr = 5, .swg = 4, .swb = 6 }, .scan = 65 }, \
{ .id = 70, .x = 5.438, .y = -3.375, .adr = { .drv = 2, .cs = 9, .swr = 5, .swg = 4, .swb = 6 }, .scan = 66 }, \
{ .id = 71, .x = 6.188, .y = -3.375, .adr = { .drv = 2, .cs = 9, .swr = 8, .swg = 7, .swb = 9 }, .scan = 67 }, \
{ .id = 72, .x = 6.938, .y = -3.375, .adr = { .drv = 1, .cs = 16, .swr = 8, .swg = 7, .swb = 9 }, .scan = 150 }, \
{ .id = 73, .x = 7.688, .y = -3.375, .adr = { .drv = 1, .cs = 15, .swr = 8, .swg = 7, .swb = 9 }, .scan = 151 }, \
{ .id = 74, .x = 8.438, .y = -3.375, .adr = { .drv = 1, .cs = 14, .swr = 8, .swg = 7, .swb = 9 }, .scan = 152 }, \
{ .id = 75, .x = 9.844, .y = -3.375, .adr = { .drv = 1, .cs = 13, .swr = 8, .swg = 7, .swb = 9 }, .scan = 153 }, \
{ .id = 76, .x = 12.375, .y = -3.375, .adr = { .drv = 1, .cs = 11, .swr = 8, .swg = 7, .swb = 9 }, .scan = 140 }, \
{ .id = 77, .x = 0.094, .y = -4.125, .adr = { .drv = 2, .cs = 14, .swr = 11, .swg = 10, .swb = 12 }, .scan = 75 }, \
{ .id = 78, .x = 1.031, .y = -4.125, .adr = { .drv = 2, .cs = 14, .swr = 8, .swg = 7, .swb = 9 }, .scan = 76 }, \
{ .id = 79, .x = 1.969, .y = -4.125, .adr = { .drv = 2, .cs = 13, .swr = 8, .swg = 7, .swb = 9 }, .scan = 77 }, \
{ .id = 80, .x = 4.781, .y = -4.125, .adr = { .drv = 2, .cs = 10, .swr = 8, .swg = 7, .swb = 9 }, .scan = 78 }, \
{ .id = 81, .x = 7.594, .y = -4.125, .adr = { .drv = 1, .cs = 16, .swr = 5, .swg = 4, .swb = 6 }, .scan = 79 }, \
{ .id = 82, .x = 8.531, .y = -4.125, .adr = { .drv = 1, .cs = 15, .swr = 5, .swg = 4, .swb = 6 }, .scan = 80 }, \
{ .id = 83, .x = 9.469, .y = -4.125, .adr = { .drv = 1, .cs = 14, .swr = 5, .swg = 4, .swb = 6 }, .scan = 81 }, \
{ .id = 84, .x = 10.406, .y = -4.125, .adr = { .drv = 1, .cs = 13, .swr = 5, .swg = 4, .swb = 6 }, .scan = 82 }, \
{ .id = 85, .x = 11.625, .y = -4.125, .adr = { .drv = 1, .cs = 12, .swr = 8, .swg = 7, .swb = 9 }, .scan = 154 }, \
{ .id = 86, .x = 12.375, .y = -4.125, .adr = { .drv = 1, .cs = 12, .swr = 5, .swg = 4, .swb = 6 }, .scan = 155 }, \
{ .id = 87, .x = 13.125, .y = -4.125, .adr = { .drv = 1, .cs = 11, .swr = 5, .swg = 4, .swb = 6 }, .scan = 156 }, \
{ .id = 9, .x = 7.125, .y = 0, .adr = { .drv = 1, .cs = 2, .swr = 5, .swg = 4, .swb = 6 }, .scan = 48 }, \
{ .id = 10, .x = 8.25, .y = 0, .adr = { .drv = 1, .cs = 3, .swr = 5, .swg = 4, .swb = 6 }, .scan = 49 }, \
{ .id = 11, .x = 9, .y = 0, .adr = { .drv = 1, .cs = 4, .swr = 5, .swg = 4, .swb = 6 }, .scan = 50 }, \
{ .id = 12, .x = 9.75, .y = 0, .adr = { .drv = 1, .cs = 5, .swr = 5, .swg = 4, .swb = 6 }, .scan = 51 }, \
{ .id = 13, .x = 10.5, .y = 0, .adr = { .drv = 1, .cs = 6, .swr = 5, .swg = 4, .swb = 6 }, .scan = 52 }, \
{ .id = 14, .x = 11.625, .y = 0, .adr = { .drv = 1, .cs = 7, .swr = 5, .swg = 4, .swb = 6 }, .scan = 53 }, \
{ .id = 15, .x = 12.375, .y = 0, .adr = { .drv = 1, .cs = 8, .swr = 5, .swg = 4, .swb = 6 }, .scan = 54 }, \
{ .id = 16, .x = 13.125, .y = 0, .adr = { .drv = 1, .cs = 9, .swr = 5, .swg = 4, .swb = 6 }, .scan = 55 }, \
{ .id = 17, .x = 0, .y = -1.125, .adr = { .drv = 2, .cs = 1, .swr = 8, .swg = 7, .swb = 9 }, .scan = 8 }, \
{ .id = 18, .x = 0.75, .y = -1.125, .adr = { .drv = 2, .cs = 2, .swr = 8, .swg = 7, .swb = 9 }, .scan = 9 }, \
{ .id = 19, .x = 1.5, .y = -1.125, .adr = { .drv = 2, .cs = 3, .swr = 8, .swg = 7, .swb = 9 }, .scan = 10 }, \
{ .id = 20, .x = 2.25, .y = -1.125, .adr = { .drv = 2, .cs = 4, .swr = 8, .swg = 7, .swb = 9 }, .scan = 11 }, \
{ .id = 21, .x = 3, .y = -1.125, .adr = { .drv = 2, .cs = 5, .swr = 8, .swg = 7, .swb = 9 }, .scan = 12 }, \
{ .id = 22, .x = 3.75, .y = -1.125, .adr = { .drv = 2, .cs = 6, .swr = 8, .swg = 7, .swb = 9 }, .scan = 13 }, \
{ .id = 23, .x = 4.5, .y = -1.125, .adr = { .drv = 2, .cs = 7, .swr = 8, .swg = 7, .swb = 9 }, .scan = 14 }, \
{ .id = 24, .x = 5.25, .y = -1.125, .adr = { .drv = 2, .cs = 8, .swr = 8, .swg = 7, .swb = 9 }, .scan = 15 }, \
{ .id = 25, .x = 6, .y = -1.125, .adr = { .drv = 1, .cs = 1, .swr = 8, .swg = 7, .swb = 9 }, .scan = 56 }, \
{ .id = 26, .x = 6.75, .y = -1.125, .adr = { .drv = 1, .cs = 2, .swr = 8, .swg = 7, .swb = 9 }, .scan = 57 }, \
{ .id = 27, .x = 7.5, .y = -1.125, .adr = { .drv = 1, .cs = 3, .swr = 8, .swg = 7, .swb = 9 }, .scan = 58 }, \
{ .id = 28, .x = 8.25, .y = -1.125, .adr = { .drv = 1, .cs = 4, .swr = 8, .swg = 7, .swb = 9 }, .scan = 59 }, \
{ .id = 29, .x = 9, .y = -1.125, .adr = { .drv = 1, .cs = 5, .swr = 8, .swg = 7, .swb = 9 }, .scan = 60 }, \
{ .id = 30, .x = 10.125, .y = -1.125, .adr = { .drv = 1, .cs = 6, .swr = 8, .swg = 7, .swb = 9 }, .scan = 61 }, \
{ .id = 31, .x = 11.625, .y = -1.125, .adr = { .drv = 1, .cs = 7, .swr = 8, .swg = 7, .swb = 9 }, .scan = 62 }, \
{ .id = 32, .x = 12.375, .y = -1.125, .adr = { .drv = 1, .cs = 8, .swr = 8, .swg = 7, .swb = 9 }, .scan = 63 }, \
{ .id = 33, .x = 13.125, .y = -1.125, .adr = { .drv = 1, .cs = 9, .swr = 8, .swg = 7, .swb = 9 }, .scan = 79 }, \
{ .id = 34, .x = 0.188, .y = -1.875, .adr = { .drv = 2, .cs = 1, .swr = 11, .swg = 10, .swb = 12 }, .scan = 16 }, \
{ .id = 35, .x = 1.125, .y = -1.875, .adr = { .drv = 2, .cs = 2, .swr = 11, .swg = 10, .swb = 12 }, .scan = 17 }, \
{ .id = 36, .x = 1.875, .y = -1.875, .adr = { .drv = 2, .cs = 3, .swr = 11, .swg = 10, .swb = 12 }, .scan = 18 }, \
{ .id = 37, .x = 2.625, .y = -1.875, .adr = { .drv = 2, .cs = 4, .swr = 11, .swg = 10, .swb = 12 }, .scan = 19 }, \
{ .id = 38, .x = 3.375, .y = -1.875, .adr = { .drv = 2, .cs = 5, .swr = 11, .swg = 10, .swb = 12 }, .scan = 20 }, \
{ .id = 39, .x = 4.125, .y = -1.875, .adr = { .drv = 2, .cs = 6, .swr = 11, .swg = 10, .swb = 12 }, .scan = 21 }, \
{ .id = 40, .x = 4.875, .y = -1.875, .adr = { .drv = 2, .cs = 7, .swr = 11, .swg = 10, .swb = 12 }, .scan = 22 }, \
{ .id = 41, .x = 5.625, .y = -1.875, .adr = { .drv = 2, .cs = 8, .swr = 11, .swg = 10, .swb = 12 }, .scan = 23 }, \
{ .id = 42, .x = 6.375, .y = -1.875, .adr = { .drv = 1, .cs = 1, .swr = 11, .swg = 10, .swb = 12 }, .scan = 64 }, \
{ .id = 43, .x = 7.125, .y = -1.875, .adr = { .drv = 1, .cs = 2, .swr = 11, .swg = 10, .swb = 12 }, .scan = 65 }, \
{ .id = 44, .x = 7.875, .y = -1.875, .adr = { .drv = 1, .cs = 3, .swr = 11, .swg = 10, .swb = 12 }, .scan = 66 }, \
{ .id = 45, .x = 8.625, .y = -1.875, .adr = { .drv = 1, .cs = 4, .swr = 11, .swg = 10, .swb = 12 }, .scan = 67 }, \
{ .id = 46, .x = 9.375, .y = -1.875, .adr = { .drv = 1, .cs = 5, .swr = 11, .swg = 10, .swb = 12 }, .scan = 68 }, \
{ .id = 47, .x = 10.312, .y = -1.875, .adr = { .drv = 1, .cs = 6, .swr = 11, .swg = 10, .swb = 12 }, .scan = 69 }, \
{ .id = 48, .x = 11.625, .y = -1.875, .adr = { .drv = 1, .cs = 7, .swr = 11, .swg = 10, .swb = 12 }, .scan = 70 }, \
{ .id = 49, .x = 12.375, .y = -1.875, .adr = { .drv = 1, .cs = 8, .swr = 11, .swg = 10, .swb = 12 }, .scan = 71 }, \
{ .id = 50, .x = 13.125, .y = -1.875, .adr = { .drv = 1, .cs = 9, .swr = 11, .swg = 10, .swb = 12 }, .scan = 78 }, \
{ .id = 51, .x = 0.281, .y = -2.625, .adr = { .drv = 2, .cs = 1, .swr = 5, .swg = 4, .swb = 6 }, .scan = 24 }, \
{ .id = 52, .x = 1.313, .y = -2.625, .adr = { .drv = 2, .cs = 2, .swr = 5, .swg = 4, .swb = 6 }, .scan = 25 }, \
{ .id = 53, .x = 2.063, .y = -2.625, .adr = { .drv = 2, .cs = 13, .swr = 11, .swg = 10, .swb = 12 }, .scan = 26 }, \
{ .id = 54, .x = 2.812, .y = -2.625, .adr = { .drv = 2, .cs = 12, .swr = 11, .swg = 10, .swb = 12 }, .scan = 27 }, \
{ .id = 55, .x = 3.562, .y = -2.625, .adr = { .drv = 2, .cs = 11, .swr = 11, .swg = 10, .swb = 12 }, .scan = 28 }, \
{ .id = 56, .x = 4.312, .y = -2.625, .adr = { .drv = 2, .cs = 6, .swr = 5, .swg = 4, .swb = 6 }, .scan = 29 }, \
{ .id = 57, .x = 5.062, .y = -2.625, .adr = { .drv = 2, .cs = 10, .swr = 11, .swg = 10, .swb = 12 }, .scan = 30 }, \
{ .id = 58, .x = 5.812, .y = -2.625, .adr = { .drv = 2, .cs = 9, .swr = 11, .swg = 10, .swb = 12 }, .scan = 31 }, \
{ .id = 59, .x = 6.562, .y = -2.625, .adr = { .drv = 1, .cs = 16, .swr = 11, .swg = 10, .swb = 12 }, .scan = 72 }, \
{ .id = 60, .x = 7.312, .y = -2.625, .adr = { .drv = 1, .cs = 15, .swr = 11, .swg = 10, .swb = 12 }, .scan = 73 }, \
{ .id = 61, .x = 8.062, .y = -2.625, .adr = { .drv = 1, .cs = 14, .swr = 11, .swg = 10, .swb = 12 }, .scan = 74 }, \
{ .id = 62, .x = 8.812, .y = -2.625, .adr = { .drv = 1, .cs = 13, .swr = 11, .swg = 10, .swb = 12 }, .scan = 75 }, \
{ .id = 63, .x = 10.031, .y = -2.625, .adr = { .drv = 1, .cs = 12, .swr = 11, .swg = 10, .swb = 12 }, .scan = 76 }, \
{ .id = 64, .x = 0.469, .y = -3.375, .adr = { .drv = 2, .cs = 14, .swr = 5, .swg = 4, .swb = 6 }, .scan = 32 }, \
{ .id = 65, .x = 1.688, .y = -3.375, .adr = { .drv = 2, .cs = 13, .swr = 5, .swg = 4, .swb = 6 }, .scan = 33 }, \
{ .id = 66, .x = 2.438, .y = -3.375, .adr = { .drv = 2, .cs = 12, .swr = 8, .swg = 7, .swb = 9 }, .scan = 34 }, \
{ .id = 67, .x = 3.188, .y = -3.375, .adr = { .drv = 2, .cs = 12, .swr = 5, .swg = 4, .swb = 6 }, .scan = 35 }, \
{ .id = 68, .x = 3.938, .y = -3.375, .adr = { .drv = 2, .cs = 11, .swr = 5, .swg = 4, .swb = 6 }, .scan = 36 }, \
{ .id = 69, .x = 4.688, .y = -3.375, .adr = { .drv = 2, .cs = 10, .swr = 5, .swg = 4, .swb = 6 }, .scan = 37 }, \
{ .id = 70, .x = 5.438, .y = -3.375, .adr = { .drv = 2, .cs = 9, .swr = 5, .swg = 4, .swb = 6 }, .scan = 38 }, \
{ .id = 71, .x = 6.188, .y = -3.375, .adr = { .drv = 2, .cs = 9, .swr = 8, .swg = 7, .swb = 9 }, .scan = 39 }, \
{ .id = 72, .x = 6.938, .y = -3.375, .adr = { .drv = 1, .cs = 16, .swr = 8, .swg = 7, .swb = 9 }, .scan = 80 }, \
{ .id = 73, .x = 7.688, .y = -3.375, .adr = { .drv = 1, .cs = 15, .swr = 8, .swg = 7, .swb = 9 }, .scan = 81 }, \
{ .id = 74, .x = 8.438, .y = -3.375, .adr = { .drv = 1, .cs = 14, .swr = 8, .swg = 7, .swb = 9 }, .scan = 82 }, \
{ .id = 75, .x = 9.844, .y = -3.375, .adr = { .drv = 1, .cs = 13, .swr = 8, .swg = 7, .swb = 9 }, .scan = 83 }, \
{ .id = 76, .x = 12.375, .y = -3.375, .adr = { .drv = 1, .cs = 11, .swr = 8, .swg = 7, .swb = 9 }, .scan = 77 }, \
{ .id = 77, .x = 0.094, .y = -4.125, .adr = { .drv = 2, .cs = 14, .swr = 11, .swg = 10, .swb = 12 }, .scan = 40 }, \
{ .id = 78, .x = 1.031, .y = -4.125, .adr = { .drv = 2, .cs = 14, .swr = 8, .swg = 7, .swb = 9 }, .scan = 41 }, \
{ .id = 79, .x = 1.969, .y = -4.125, .adr = { .drv = 2, .cs = 13, .swr = 8, .swg = 7, .swb = 9 }, .scan = 42 }, \
{ .id = 80, .x = 4.781, .y = -4.125, .adr = { .drv = 2, .cs = 10, .swr = 8, .swg = 7, .swb = 9 }, .scan = 43 }, \
{ .id = 81, .x = 7.594, .y = -4.125, .adr = { .drv = 1, .cs = 16, .swr = 5, .swg = 4, .swb = 6 }, .scan = 44 }, \
{ .id = 82, .x = 8.531, .y = -4.125, .adr = { .drv = 1, .cs = 15, .swr = 5, .swg = 4, .swb = 6 }, .scan = 45 }, \
{ .id = 83, .x = 9.469, .y = -4.125, .adr = { .drv = 1, .cs = 14, .swr = 5, .swg = 4, .swb = 6 }, .scan = 46 }, \
{ .id = 84, .x = 10.406, .y = -4.125, .adr = { .drv = 1, .cs = 13, .swr = 5, .swg = 4, .swb = 6 }, .scan = 47 }, \
{ .id = 85, .x = 11.625, .y = -4.125, .adr = { .drv = 1, .cs = 12, .swr = 8, .swg = 7, .swb = 9 }, .scan = 84 }, \
{ .id = 86, .x = 12.375, .y = -4.125, .adr = { .drv = 1, .cs = 12, .swr = 5, .swg = 4, .swb = 6 }, .scan = 85 }, \
{ .id = 87, .x = 13.125, .y = -4.125, .adr = { .drv = 1, .cs = 11, .swr = 5, .swg = 4, .swb = 6 }, .scan = 86 }, \
{ .id = 88, .x = 13.433, .y = -4.43, .adr = { .drv = 1, .cs = 11, .swr = 2, .swg = 1, .swb = 3 }, .scan = 255 }, \
{ .id = 89, .x = 12.285, .y = -4.535, .adr = { .drv = 1, .cs = 12, .swr = 2, .swg = 1, .swb = 3 }, .scan = 255 }, \
{ .id = 90, .x = 11.14, .y = -4.535, .adr = { .drv = 1, .cs = 13, .swr = 2, .swg = 1, .swb = 3 }, .scan = 255 }, \
@@ -182,8 +182,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define USB_LED_INDICATOR_ENABLE //Comment out to disable indicator functionality
#ifdef USB_LED_INDICATOR_ENABLE //Scan codes refer to actual key matrix codes, not KC_* (255 to disable)
#define USB_LED_NUM_LOCK_SCANCODE 255
#define USB_LED_CAPS_LOCK_SCANCODE 45
#define USB_LED_SCROLL_LOCK_SCANCODE 96
#define USB_LED_CAPS_LOCK_SCANCODE 24
#define USB_LED_SCROLL_LOCK_SCANCODE 54
#define USB_LED_COMPOSE_SCANCODE 255
#define USB_LED_KANA_SCANCODE 255
#endif //USB_LED_INDICATOR_ENABLE

View File

@@ -19,6 +19,7 @@ enum ctrl_keycodes {
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
@@ -39,7 +40,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
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_MPLY, KC_MSTP, KC_VOLU, \
L_T_BR, L_PSD, L_BRI, L_PSI, KC_TRNS, KC_TRNS, KC_TRNS, U_T_AUTO,U_T_AGCR,KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MPRV, KC_MNXT, KC_VOLD, \
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_TRNS, L_T_MD, L_T_ONF, KC_TRNS, KC_TRNS, KC_TRNS, TG_NKRO, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
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_TRNS, \
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS \
),
/*
@@ -71,6 +72,8 @@ void matrix_scan_user(void) {
#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) {
@@ -197,7 +200,16 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
CDC_print("\r\n");
}
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

@@ -19,6 +19,7 @@ enum ctrl_keycodes {
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
@@ -71,6 +72,8 @@ void matrix_scan_user(void) {
#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) {
@@ -197,6 +200,15 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
CDC_print("\r\n");
}
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

@@ -3,7 +3,7 @@
#include "quantum.h"
#define LAYOUT( \
#define LAYOUT_68_ansi( \
K00, K01, K02, K03, K04, K05, K06, K07, K08, K10, K11, K12, K13, K14, K15, K16, \
K17, K18, K20, K21, K22, K23, K24, K25, K26, K27, K28, K30, K31, K32, K33, K34, \
K35, K36, K37, K38, K40, K41, K42, K43, K44, K45, K46, K47, K48, \
@@ -26,7 +26,7 @@
K35, K36, K37, K38, K40, K41, K42, K43, K44, K45, K46, K47, K48, \
K50, K51, K52, K53, K54, K55, K56, K57, K58, K60, K61, K62, K63, \
K64, K65, K66, K67, K68, K70, K71, K72, K73, K74 \
) LAYOUT( \
) LAYOUT_68_ansi( \
KC_##K00, KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, KC_##K08, \
KC_##K10, KC_##K11, KC_##K12, KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, KC_##K18, \
KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_##K24, KC_##K25, KC_##K26, KC_##K27, KC_##K28, \

View File

@@ -64,3 +64,5 @@ MIDI_ENABLE ?= no # MIDI controls
UNICODE_ENABLE ?= no # Unicode
BLUETOOTH_ENABLE ?= no # Enable Bluetooth with the Adafruit EZ-Key HID
AUDIO_ENABLE ?= no # Audio output on port C6
LAYOUTS = 68_ansi

View File

@@ -3,7 +3,7 @@
#include "quantum.h"
#define LAYOUT( \
#define LAYOUT_68_ansi( \
K00, K01, K02, K03, K04, K05, K06, K07, K08, K10, K11, K12, K13, K14, K15, K16, \
K17, K18, K20, K21, K22, K23, K24, K25, K26, K27, K28, K30, K31, K32, K33, K34, \
K35, K36, K37, K38, K40, K41, K42, K43, K44, K45, K46, K47, K48, \
@@ -26,7 +26,7 @@
K35, K36, K37, K38, K40, K41, K42, K43, K44, K45, K46, K47, K48, \
K50, K51, K52, K53, K54, K55, K56, K57, K58, K60, K61, K62, K63, \
K64, K65, K66, K67, K68, K70, K71, K72, K73, K74 \
) LAYOUT( \
) LAYOUT_68_ansi( \
KC_##K00, KC_##K01, KC_##K02, KC_##K03, KC_##K04, KC_##K05, KC_##K06, KC_##K07, KC_##K08, \
KC_##K10, KC_##K11, KC_##K12, KC_##K13, KC_##K14, KC_##K15, KC_##K16, KC_##K17, KC_##K18, \
KC_##K20, KC_##K21, KC_##K22, KC_##K23, KC_##K24, KC_##K25, KC_##K26, KC_##K27, KC_##K28, \

View File

@@ -1,12 +1,21 @@
#ifndef CONFIG_USER_H
#define CONFIG_USER_H
#include "../../config.h"
#ifdef MITOSIS_DATAGROK_SLOWUART
// This is the highest possible baud rate that a pro micro clocked at 8Mhz can
// support without errors. I don't notice any difference in behavior at this
// slower speed. (So I think it should maybe be the default, to allow a single
// codebase to support both available flavors of pro micro.) This requires a
// corresponding change to the wireless module firmware; see
// https://github.com/reversebias/mitosis/pull/10
#undef SERIAL_UART_BAUD // avoids redefinition warning
#define SERIAL_UART_BAUD 250000
#endif
// I want to place an underscore as tap behavior on the right shift key. But
// RSFT_T(KC_UNDS) doesn't work; mod-tap doesn't work with pre-shifted keys. So
// instead we take advantage of Space Cadet Shift that does something similar
// and just tweak it to use the -_ key instead of 0) See
// instead I take advantage of Space Cadet Shift that does something similar
// and just tweak it to use the -/_ key instead of 0/). See
// https://github.com/qmk/qmk_firmware/pull/2055
#define RSPC_KEY KC_MINS
@@ -18,11 +27,12 @@
//#define NO_ACTION_FUNCTION
#ifdef AUDIO_ENABLE
#define STARTUP_SONG SONG(PLANCK_SOUND)
// #define STARTUP_SONG SONG(NO_SOUND)
#define DEFAULT_LAYER_SONGS { SONG(QWERTY_SOUND), \
SONG(COLEMAK_SOUND), \
SONG(DVORAK_SOUND) \
#define STARTUP_SONG SONG(MARIO_MUSHROOM)
#define DEFAULT_LAYER_SONGS { \
SONG(QWERTY_SOUND), \
SONG(COLEMAK_SOUND), \
SONG(DVORAK_SOUND), \
SONG(ZELDA_TREASURE), \
}
#define AUDIO_VOICES
#define AUDIO_CLICKY
@@ -30,3 +40,18 @@
#endif
#endif
#define LAYOUT_bottomspace( \
k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, \
k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, \
k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, \
k31, k32, k33, k34, k35, k36, k37, k38, \
k41, k42, k43, k44, k45, k46, k47, k48 \
) \
{ \
{ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09 }, \
{ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19 }, \
{ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29 }, \
{ KC_NO, k31, k32, k43, k44, k45, k46, k37, k38, KC_NO }, \
{ KC_NO, k41, k42, k33, k34, k35, k36, k47, k48, KC_NO } \
}

View File

@@ -1,16 +1,34 @@
#include QMK_KEYBOARD_H
#ifdef AUDIO_ENABLE
#include "audio.h"
#ifdef DEFAULT_LAYER_SONGS
extern float default_layer_songs[][16][2];
#endif
#endif
enum mitosis_layers
{
{
_xQ, // qwerty
_xC, // colemak
_xD, // dvorak
_xW, // workman
_xS, // symbols
_xN, // numbers
_xF // functions
};
};
enum mitosis_keycodes
{
KC_LAYO = SAFE_RANGE
};
// Setting MITOSIS_DATAGROK_BOTTOMSPACE in rules.mk will swap the upper and
// lower center four thumb-keys. See keymaps/datagrok/rules.mk.
#ifdef MITOSIS_DATAGROK_BOTTOMSPACE
#undef LAYOUT
#define LAYOUT LAYOUT_bottomspace
#endif
// Fillers to make layering more clear
#define _______ KC_TRNS // Transparent
@@ -31,58 +49,125 @@ enum mitosis_layers
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_xQ] = LAYOUT(
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, KC_SCLN,
KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_QUOT,
/*, */ KC_LGUI, KC_LCTL, MO(_xS), KC_TAB, KC_SPC, MO(_xS), KC_RCTL, KC_RGUI,
/*, */ KC_HENK, KC_LALT, MO(_xN), KC_LSFT, KC_RSPC, MO(_xN), KC_RALT, KC_MHEN),
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, KC_SCLN,
KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_QUOT,
/*, */ KC_LGUI, KC_LCTL, MO(_xS), KC_BSPC, KC_SPC, MO(_xS), KC_RCTL, KC_RGUI,
/*, */ KC_HENK, KC_LALT, MO(_xN), LSFT_T(KC_TAB), KC_RSPC, MO(_xN), KC_RALT, KC_MHEN),
[_xC] = LAYOUT(
KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN,
KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O,
KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_QUOT,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______),
[_xD] = LAYOUT(
KC_QUOT, KC_COMM, KC_DOT, KC_P, KC_Y, KC_F, KC_G, KC_C, KC_R, KC_L,
KC_A, KC_O, KC_E, KC_U, KC_I, KC_D, KC_H, KC_T, KC_N, KC_S,
KC_SCLN, KC_Q, KC_J, KC_K, KC_X, KC_B, KC_M, KC_W, KC_V, KC_Z,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______),
[_xW] = LAYOUT(
KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, KC_SCLN,
KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I,
KC_Z, KC_X, KC_M, KC_C, KC_V, KC_K, KC_L, KC_COMM, KC_DOT, KC_QUOT,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______),
KC_Q, KC_D, KC_R, KC_W, KC_B, KC_J, KC_F, KC_U, KC_P, KC_SCLN,
KC_A, KC_S, KC_H, KC_T, KC_G, KC_Y, KC_N, KC_E, KC_O, KC_I,
KC_Z, KC_X, KC_M, KC_C, KC_V, KC_K, KC_L, KC_COMM, KC_DOT, KC_QUOT,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______),
[_xS] = LAYOUT(
KC_ESC, KC_GRV , KC_UP, KC_EQL , KC_TILD, KC_PLUS, KC_CIRC, KC_AMPR, KC_PERC, KC_MINS,
KC_BSPC, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_PIPE, KC_AT, KC_DLR, KC_HASH, KC_ENT,
KC_BSLS, KC_LABK, KC_LCBR, KC_LPRN, KC_LBRC, KC_RBRC, KC_RCBR, KC_RPRN, KC_RABK, KC_SLSH,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______,
/*, */ _______, _______, MO(_xF), _______, _______, MO(_xF), _______, _______),
KC_ESC, KC_GRV , KC_UP, KC_EQL , KC_TILD, KC_PLUS, KC_CIRC, KC_AMPR, KC_PERC, KC_MINS,
_______, KC_LEFT, KC_DOWN, KC_RGHT, _______, KC_PIPE, KC_AT, KC_DLR, KC_HASH, KC_ENT,
KC_BSLS, KC_LABK, KC_LCBR, KC_LPRN, KC_LBRC, KC_RBRC, KC_RPRN, KC_RCBR, KC_RABK, KC_SLSH,
/*, */ _______, _______, _______, KC_DEL, _______, _______, _______, _______,
/*, */ _______, _______, TT(_xF), _______, _______, TT(_xF), _______, _______),
[_xN] = LAYOUT(
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_PPLS, KC_7, KC_8, KC_9, KC_PMNS,
_______, KC_F4, KC_F5, KC_F6, KC_F11, KC_NLCK, KC_4, KC_5, KC_6, KC_PENT,
_______, KC_F1, KC_F2, KC_F3, KC_F12, KC_PAST, KC_1, KC_2, KC_3, KC_PSLS,
/*, */ _______, _______, MO(_xF), _______, _______, MO(_xF), KC_0, KC_PDOT,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______),
KC_PSCR, KC_F7, KC_F8, KC_F9, KC_F10, KC_PPLS, KC_7, KC_8, KC_9, KC_PMNS,
KC_SLCK, KC_F4, KC_F5, KC_F6, KC_F11, KC_NLCK, KC_4, KC_5, KC_6, KC_PENT,
KC_PAUS, KC_F1, KC_F2, KC_F3, KC_F12, KC_PAST, KC_1, KC_2, KC_3, KC_PSLS,
/*, */ _______, _______, TT(_xF), _______, _______, TT(_xF), KC_0, KC_DOT,
/*, */ _______, _______, _______, _______, _______, _______, _______, _______),
[_xF] = LAYOUT(
RESET, KC_INS, KC_PGUP, KC_DEL, KC_VOLU, KC_PPLS, KC_P7, KC_P8, KC_P9, KC_PMNS,
CK_TOGG, KC_HOME, KC_PGDN, KC_END, KC_VOLD, KC_NLCK, KC_P4, KC_P5, KC_P6, KC_PENT,
TG(_xW), KC_MPRV, KC_MPLY, KC_MNXT, KC_MUTE, KC_PAST, KC_P1, KC_P2, KC_P3, KC_PSLS,
/*, */ CK_UP, MU_TOG, _______, _______, _______, _______, KC_P0, KC_PDOT,
/*, */ CK_DOWN, MU_MOD, _______, _______, _______, KC_PSCR, KC_SLCK, KC_PAUS),
RESET, KC_INS, KC_PGUP, DEBUG, KC_VOLU, KC_PPLS, KC_P7, KC_P8, KC_P9, KC_PMNS,
CK_TOGG, KC_HOME, KC_PGDN, KC_END, KC_VOLD, KC_NLCK, KC_P4, KC_P5, KC_P6, KC_PENT,
KC_LAYO, KC_MPRV, KC_MPLY, KC_MNXT, KC_MUTE, KC_PAST, KC_P1, KC_P2, KC_P3, KC_PSLS,
/*, */ CK_UP, MU_TOG, _______, _______, _______, _______, KC_P0, KC_PDOT,
/*, */ CK_DOWN, MU_MOD, _______, _______, _______, _______, _______, _______),
};
const bool defaultlayers[] = {
[_xQ] = true,
[_xC] = true,
[_xD] = true,
[_xW] = true,
[_xS] = false,
[_xN] = false,
[_xF] = false,
};
const size_t defaultlayers_n = sizeof(defaultlayers) / sizeof(defaultlayers[0]);
// This is a hack to place <question mark> on <shift-comma> and <exclaimation
// New keycode KC_LAYO rotates between available default layers (for e.g.,
// selecting a base layout). Shift+KC_LAYO makes the current one persistent.
bool process_record_layout(uint16_t keycode, keyrecord_t *record) {
uint32_t default_layer;
uint8_t i;
#if defined(AUDIO_ENABLE)
float saved_song[][2] = SONG(COIN_SOUND);
#endif
if (keycode != KC_LAYO || !record->event.pressed) {
return true;
}
if (get_mods() & (MOD_BIT(KC_LSHIFT)|MOD_BIT(KC_RSHIFT))) { // shift pressed
// save default layer. whatever the current default layer is, store that
eeconfig_update_default_layer(default_layer_state);
#if defined(AUDIO_ENABLE)
PLAY_SONG(saved_song);
#endif
} else {
// rotate default layer.
// find the current default layer
default_layer = biton32(default_layer_state);
// find next valid default layer
for (i = 1; i < defaultlayers_n; i++) {
if (defaultlayers[(default_layer + i) % defaultlayers_n]) {
break;
}
}
if (i == defaultlayers_n) {
// we fell out of the loop without finding another default layer to switch
// to.
return false;
}
default_layer = (default_layer + i) % defaultlayers_n;
default_layer_set(1U<<default_layer);
led_set(host_keyboard_leds());
#if defined(AUDIO_ENABLE) && defined(DEFAULT_LAYER_SONGS)
PLAY_SONG(default_layer_songs[default_layer]);
#endif
}
return false;
}
// This is a hack to place <question mark> on <shift-comma> and <exclamation
// mark> on <shift-period>, when using an operating system configured for a
// US/qwerty layout.
// cdeq = "comma dot exclamation question"
bool comm_shifted = false;
bool ques_shifted = false;
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
bool process_record_cdeq(uint16_t keycode, keyrecord_t *record) {
uint8_t shifted;
uint16_t s_keycode;
bool *k_shifted;
switch (keycode) {
case KC_COMM:
s_keycode = KC_SLSH;
k_shifted = &comm_shifted;
break;
case KC_DOT:
s_keycode = KC_1;
k_shifted = &ques_shifted;
break;
default:
return true;
case KC_COMM:
s_keycode = KC_SLSH;
k_shifted = &comm_shifted;
break;
case KC_DOT:
s_keycode = KC_1;
k_shifted = &ques_shifted;
break;
default:
return true;
}
shifted = get_mods() & (MOD_BIT(KC_LSHIFT)|MOD_BIT(KC_RSHIFT));
@@ -104,47 +189,29 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
}
}
#ifdef AUDIO_ENABLE
float tone_qwerty[][2] = SONG(QWERTY_SOUND);
float tone_dyn_macro_rec[][2] = SONG(DVORAK_SOUND);
float tone_dyn_macro_play[][2] = SONG(COLEMAK_SOUND);
float tone_fnpc[][2] = SONG(PLOVER_SOUND);
float tone_fnmac[][2] = SONG(PLOVER_GOODBYE_SOUND);
void startup_user()
{
float tone_startup[][2] = SONG(STARTUP_SOUND);
_delay_ms(20); // gets rid of tick
PLAY_SONG(tone_startup);
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
return \
process_record_cdeq(keycode, record) && \
process_record_layout(keycode, record);
}
void shutdown_user()
{
float tone_goodbye[][2] = SONG(GOODBYE_SOUND);
PLAY_SONG(tone_goodbye);
_delay_ms(150);
stop_all_notes();
}
void music_on_user(void)
{
music_scale_user();
}
void music_scale_user(void)
{
float music_scale[][2] = SONG(MUSIC_SCALE_SOUND);
PLAY_SONG(music_scale);
}
#endif
// Set the bits of A selected by MASK to the corresponding bits of B
#define setbits(A, B, MASK) A = (A & (B | ~MASK)) | (B & MASK)
void matrix_scan_user(void) {
void led_set_user(uint8_t usb_leds) {
// A simple (but technically inaccurate) model of the momentary layer state:
// Red layer active -> indicator = red
// Blue layer active -> indicator = blue
// Purple layer active -> indicator = purple
// the Pro Micro tx LED displays Num Lock status.
//
// Workman layout active -> indicator = green
// Workman red layer -> indicator = yellow (red + green)
// Workman blue layer -> indicator = cyan (blue + green)
// Workman purple layer -> indicator = white (red + blue + green)
// Bit # 7 6 5 4 3 2 1 0
// layer_state: [ | | | _xF | _xN | _xS | _xQ | _xW ]
// layer_state: [ | _xF | _xN | _xS | _xW | _xD | _xC | _xQ ]
// usb_led [ | | |kana |cmps |scrl |caps | num ]
// PORTB: [ NC | 10 | 9 | 8 | 14 | 16 | 15 |rxled]
// PORTC: [ NC | 5 | | | | | | ]
@@ -158,16 +225,16 @@ void matrix_scan_user(void) {
// board. Each may be connected to an LED by way of a resistor (4.7k to
// match the others) for a total of 14 additional indicators.
// A simple (but technically inaccurate) model of the momentary layer state:
// Fn1 key makes _xS active; indicator = red
// Fn2 key makes _xN active; indicator = blue
// Both keys make _xF active; indicator = purple
// Toggling QWERTY mode makes indicator include green, so (red/blue/purple becomes yellow/cyan/white)
uint32_t portf_bits = \
((layer_state|default_layer_state)&0b01100000)>>1 | \
((layer_state|default_layer_state)&0b00010000)<<1 | \
((layer_state|default_layer_state)&0b01000000)>>2;
uint32_t portd_bits = \
(usb_leds&0b1)<<5 | \
((layer_state|default_layer_state)&0b1000)>>2;
// negated because for ports 0=LED on.
uint32_t portf_bits = ~(layer_state|layer_state<<1|(layer_state&0b100)<<3);
setbits(PORTF, portf_bits, 0b00110000);
setbits(PORTD, ~layer_state, 0b00000010);
setbits(PORTF, ~portf_bits, 0b00110000);
setbits(PORTD, ~portd_bits, 0b00100010);
}
// vim: set sw=2 et:

View File

@@ -1,54 +1,59 @@
# a layout for the Mitosis
- Emphasis on momentary modifiers, all usable from either hand, arranged symmetrically, but left/right distinguishable by the OS.
Shift, Red ("Lower"), Blue ("Raise"), Super ("Windows"), Meta ("Alt"), Hyper (actually Henkan/Muhenkan).
I place left- and right-versions of Shift, GUI ("Super"), and Alt ("Meta"), and Henkan/Muhenkan (which I plan to overload for "Hyper").
I'm going for a [Space Cadet](https://en.wikipedia.org/wiki/Space-cadet_keyboard) aesthetic;
I want a keyboard that can (even just in theory) make use of all the bucky bits my operating system can support.
- Red and Blue are used to momentary-enable (like a shift key) one of three layers:
- Red key and Blue key momentary-enable (like a shift key) one of three layers:
- Red: Symbols layer
- Blue: Numbers layer
- "Purple" (both Red and Blue): Functions layer
This tri-state layer mechanism is a bit similar to Planck and Preonic's "Raise," "Lower," and "Adjust."
- The base layer is QWERTY.
A slight variant of [Workman][] may be toggled using `Red`+`Blue`+`Z`.
[Colemak][], [Dvorak][], and [Workman][] may be toggled using `Red`+`Blue`+`Z`.
When you find the one you like, save it with `Shift`+`Red`+`Blue`+`Z`.
- Minimize hand travel, so as not to lose orientation with home row.
- `?` and `!` are moved to take the place of `<` and `>`. Rationale: unmodded
and shifted keys should be for prose, while symbols useful for programming
should be colocated on their own layer.
- `?` and `!` are moved to take the place of `<` and `>`.
Rationale: unmodded and shifted keys should be for prose, while symbols useful for programming should be colocated on their own layer.
- Key positions chosen for mnemonics.
For example, you can distinguish between alphanumeric numerals and keypad numerals, but they occupy the same key positions.
## Layout Images
![mitosis:datagrok layout base layer](https://imgur.com/9LoLQUk.png)
![mitosis:datagrok layout base layer](https://i.imgur.com/tap5Pjf.png)
Base layer. Notes:
- customized comma and period, which have exclamation point and question mark on their shift layer.
- tap right-shift for underscore
- tap right-shift for underscore, tap left-shift for tab.
![mitosis:datagrok layout red layer](https://imgur.com/B5bnPGM.png)
![mitosis:datagrok layout red layer](https://i.imgur.com/sMGr34T.png)
Red layer. Intended for common navigation and programming symbols. Notes:
- symmetric layout of paired braces/brackets/slashes for easier memorization
- arrows placed directly on home position
![mitosis:datagrok layout blue layer](https://imgur.com/HGJ4G1U.png)
![mitosis:datagrok layout blue layer](https://i.imgur.com/dDb2563.png)
Blue layer. Intended for "number pad." Notes:
- Keycodes generated for numbers, enter key, and mathematical symbols are from the alphanumeric keys, not keypad. This way they are not influenced by the state of Num Lock. If you want to send the keypad equivalents, just use Red and Blue modifiers simultaneously.
- Keycodes generated for numbers, enter key, and mathematical symbols are from the alphanumeric keys, not keypad.
This way they are not influenced by the state of Num Lock.
If you want to send the keypad equivalents, just press Blue as well to access keypad numbers in the same positions in the Purple layer.
![mitosis:datagrok layout purple layer](https://imgur.com/lNsKDtA.png)
![mitosis:datagrok layout purple layer](https://i.imgur.com/pESzy2u.png)
Purple (Red+Blue) layer. Intended for "true keypad" and various functions. Notes:
- Numbers on this layer send Keypad codes, so the result will be affected by the state of Num Lock.
- "Switch Layout" toggles the alphabet keys between QWERTY and Workman
- Page Up / Page Down / Home / End are placed on similar arrows
- To press Print Screen it is necessary to use the left-side Red and Blue modifiers.
- "Switch Layout" toggles the alphabet keys between QWERTY, Colemak, Dvorak, and Workman.
Shift + "Switch Layout" stores the currently selected alphabet layout in eeprom, so the selection persists across reboots and computers.
- Page Up / Page Down / Home / End are placed on corresponding arrow keys.
Keyboard layout editor sources:
[base](http://www.keyboard-layout-editor.com/#/gists/bc2d06a3203d1bc3a14ed2245cf39643)
@@ -56,14 +61,41 @@ Keyboard layout editor sources:
[blue](http://www.keyboard-layout-editor.com/#/gists/240e807f3d7e1d3ddabe1b69ee675048)
[purple](http://www.keyboard-layout-editor.com/#/gists/9559f0f8bb1ee47677c8f2b4d766829d)
[Imgur album](https://imgur.com/a/KSoVgPx)
[Imgur album](https://imgur.com/a/hm4bbdM)
## Indicators
- When Red layer is active, the RGB indicator turns red.
- When Blue layer is active, the RGB indicator turns blue.
- When Purple layer is active, the RGB indicator turns purple.
- When the Workman layer is active, the RGB indicator turns green.
Currently, this means that activating the Red layer while using the Workman layout will make the indicator show yellow. (red + green.)
- The Num Lock status is shown on the Pro Micro tx LED.
- If you attach a speaker to PC6 (pin 5) and compile with AUDIO_ENABLE=yes, music will be played at startup, when switching default layers, and when saving the default layer.
## Variants
Some additional compile-time options for this layout are available by editing rules.mk or compiling like so:
Normal compilation:
```make mitosis:datagrok```
Swap Space onto bottom thumb row: swaps Red/Backspace/Space/Red with Blue/Shift/Shift/Blue:
```make mitosis:datagrok MITOSIS_DATAGROK_BOTTOMSPACE=yes```
Lower baud UART. Useful when using an 8Mhz pro micro; corresponding changes required in wireless firmware. See rules.mk for details.
```make mitosis:datagrok MITOSIS_DATAGROK_SLOWUART=yes```
## Design notes
### Workman layout
- I'm learning a new physical key placement, so I might as well go all-out and
use an optimal non-QWERTY layout.
- I'm learning a new physical key placement, so I might as well go all-out and use an optimal non-QWERTY layout.
Bonus: it's easy to switch back to QWERTY on a traditional row-staggered keyboard.
The designer of the Mitosis had [a similar experience](https://www.reddit.com/r/MechanicalKeyboards/comments/66588f/wireless_split_qmk_mitosis/dgfr22q/).
- I like the way Workman feels and some of its advantages over Colemak.
Unfortunately, it was designed using a weighting system based on a standard
@@ -78,14 +110,10 @@ Keyboard layout editor sources:
The next fastest baudrate that works without errors is 250k baud.
So if you want to do the same:
- Set the Pro Micro clock rate correctly in `rules.mk`:
- Set the Pro Micro clock and baud rate correctly in `rules.mk`:
```
F_CPU = 800000
```
- Configure it to communicate at 250k baud in `config.h`:
```
#undef SERIAL_UART_BAUD // avoids redefinition warning
#define SERIAL_UART_BAUD 250000
MITOSIS_DATAGROK_SLOWUART = yes
```
- Configure the receiver's wireless module to communicate at 250k baud in `main.c`. See https://github.com/reversebias/mitosis/pull/10
```
@@ -99,7 +127,7 @@ Keyboard layout editor sources:
- Arrow keys are in the home position on the Red layer.
- Blue+Arrows = PgUp/PgDn/Home/End, which is intuitive for me.
- Blue+Arrows = PgUp/PgDn/Home/End, which is intuitive for me and similar to what is done on Apple and some Dell keyboards.
- The number pad: I placed the ten-key number pad on the Blue layer.
However, this would do the wrong thing when Num Lock was not enabled.
@@ -111,11 +139,7 @@ Keyboard layout editor sources:
- The Function-keys are arranged to mimic the order of the ten-key pad.
- Enter is now in a more qwerty-familiar location, and may be activated with one hand.
Numpad Enter is in the same position.
- Rather than place Backspace opposite Space, I intentionally place it on a layer where it takes some effort to activate.
Backspace is one of the keys I most dislike on a QWERTY keyboard because it moves me away from homerow and I need to use it so often.
Rather than make it easier to strike, I want to discourage myself from using it by learning to type more accurately.
Numpad Enter is in the same position for mnemonics.
- Why do I dislike [snake\_case](https://en.wikipedia.org/wiki/Snake_case) (`__variable_names_that_use_underscores_`)?
Maybe because it's hard to type all those underscores requiring the shift key?
@@ -126,6 +150,22 @@ Keyboard layout editor sources:
### Current
- Discard "intentionally difficult backspace" idea.
Tab returns to left-shift.
Del returns to Red+Backspace
- "High Profile mode:" Swap Red/Backspace/Space/Red with Blue/Shift/Shift/Blue (placing space on lower thumb keys) using `MITOSIS_DATAGROK_BOTTOMSPACE=yes` when compiling.
- Move Print Screen / Scroll Lock / Pause to pinky column on Blue layer.
- Let's try using TT instead of MO so we can e.g. lock-on the keypad.
- We still use MO for first modifier, so e.g. Red + tapping Blue will lock purple.
So far it feels a bit janky, we'll see.
- One key `KC_LAYO` to cycle through available base layers instead of a dedicated key for each;
Shift + `KC_LAYO` stores current base layer selection in eeprom so it comes back after disconnecting or a reset.
- Added Colemak and Dvorak as default layers that may be selected.
- Set UART to 250kbaud with make argument `MITOSIS_DATAGROK_SLOWUART=yes`, for use with 8Mhz Pro Micros.
- Display Num Lock status on tx LED
### 0.6.60
- Experiment: no-modifier underscore on right shift key.
- New combined numbers + keypad arrangement.
No more worrying about Num Lock key.
@@ -168,27 +208,33 @@ Keyboard layout editor sources:
### Abandoned ideas
- "Since QWERTY and Workman keep angle brackets together, place other
enclosing symbols on the same keys. This informs the numbers placement,
which informs the function-key placement."
- Abandoned: intentionally-difficult backspace.
"Backspace is one of the keys I most dislike on a QWERTY keyboard because it moves me away from homerow and I need to use it so often.
Rather than make it easier to strike, I want to discourage myself from using it and train myself to type more accurately."
- Many other people like an easy-to-reach backspace.
- Many other split-spacebar ergo boards place backspace at the thumbs.
- I can still train myself to type well with it in an easy location.
- I couldn't think of anything really better to put opposite space.
- I tried this and it was bad. I don't like having to pick the right
modifier to get the right flavor of bracket. Instead, now, one modifier
activates a symbols layer where all brackets are easily accessible.
- Abandoned: pile all brackets onto one pair of keys.
"Since QWERTY and Workman keep angle brackets together, place other enclosing symbols on the same keys."
- Space/Enter to the left of layer select for Enter
- I didn't like having to pick the right modifier to get the right flavor of bracket.
Instead, now, one modifier activates a symbols layer where all brackets are easily accessible.
- Doesn't work well; I always trigger space first when mashing the keys
- Abandoned: chorded Enter without proper chording detection
- I tried to make Red+Space = Enter with the intention that I could hit both with my thumb.
That didn't work well; I always trigger space first when mashing the keys
simultaneously. ~~This might not continue to be true if I change the angle
at which I strike the keys e.g. with a neoprene base or a wrist support.~~
Even with a wrist rest or low-profile, this is hard to do with one hand.
Need to adjust the firmware to understand chorded thumb keys.
- I used to have Blue on ring finger, but that was too hard to use in
conjunction with shift.
## To do
- Ctrl+'+' doesn't seem to work; fix.
- **Shared Layouts.**
Figure out how to make use of QMK's common `layouts/`
- **Chorded Combos.**
@@ -203,16 +249,23 @@ Keyboard layout editor sources:
Do any of my applications use it?
Should I have the firmware ensure it is set how I want it?
Maybe cause it to be momentary active with Blue?
See [@drashna's comment](https://github.com/qmk/qmk_firmware/pull/2366#issuecomment-404951953)
- Store default base layer in eeprom?
See [@drashna's comment](https://github.com/qmk/qmk_firmware/pull/2366#issuecomment-404951953) for code to force it always-on, which I don't know if I want.
- ~~Store default layer in eeprom?~~
- Allow "!? on ,." to be easily toggled-off.
- Modularize "!? on ,." so it can be easily used on any QMK keyboard. (about half done)
- See if the henkan/muhenkan placement is at all useful for Japanese speakers,
or abuse different keysyms for Left/Right Hyper. (Original space cadet used
scancodes 145/175. 145 is LANG2, 175 is "reserved" in USB HID spec.)
- Implement "layer lock" key
- Feature parity with popular boards e.g. Planck?
- Layers for ~~Dvorak, Coleman,~~ Plover
- More music and midi stuff
- Macros?
- Improve tri-layer behavior
- Find a better location for PrintScr/SysRq, Scroll Lock, Pause/Break, Caps Lock.
- ~~Figure out where to place non-numpad numbers so we don't need num lock turned
on to type them?~~
- Find out what `update_tri_layer_state` offers that my simple layers arrangement lacks.
- ~~Find a better location for Caps Lock, PrintScr/SysRq, Scroll Lock, Pause/Break,~~.
Placed on Blue layer. Caps will be Shift+"Layer Lock," once I get that working.
- ~~Figure out where to place non-numpad numbers so we don't need num lock turned on to type them?~~
- ~~Add Insert, PrintScr, Pause/Break~~
- ~~Make QWERTY base layer for people who customize layout in software?~~
I default to QWERTY now.

View File

@@ -1,4 +1,19 @@
AUDIO_ENABLE = yes # audio output
# Space and "Red" modifier are keys I want in the easiest-to-reach position in
# the thumb row. Depending on the angle and height of the Mitosis and the type
# of keycaps you use, the upper row or the lower row of thumb keys might be more
# comfortable for you. I put red/space on the upper row and blue/shift on the
# lower, but to swap that, set MITOSIS_DATAGROK_BOTTOMSPACE = yes. This has the
# effect of swapping only the four center keys on the upper row of thumb keys with that
# of the lower row of thumb keys.
MITOSIS_DATAGROK_BOTTOMSPACE = no
# I used to use a pro micro clocked at 8Mhz. It can't reach the same baud rate
# that the standard 16Mhz-clocked pro micro can, so the baud rate needs to be
# lowered. Set this to "yes" to do that. See also
# https://github.com/reversebias/mitosis/pull/10
MITOSIS_DATAGROK_SLOWUART = no
AUDIO_ENABLE = no # audio output
FAUXCLICKY_ENABLE = no
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
@@ -9,4 +24,12 @@ UNICODE_ENABLE = no # Unicode
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
MIDI_ENABLE = no # MIDI controls
ifeq ($(strip $(MITOSIS_DATAGROK_BOTTOMSPACE)), yes)
OPT_DEFS += -DMITOSIS_DATAGROK_BOTTOMSPACE
endif
ifeq ($(strip $(MITOSIS_DATAGROK_SLOWUART)), yes)
OPT_DEFS += -DMITOSIS_DATAGROK_SLOWUART
endif
# vim: set ts=8 noet:

View File

@@ -5,13 +5,12 @@ void uart_init(void) {
}
void led_init(void) {
DDRD |= (1<<1);
PORTD |= (1<<1);
DDRF |= (1<<4) | (1<<5);
PORTF |= (1<<4) | (1<<5);
DDRD |= (1<<1); // Pin to green, set as output
PORTD |= (1<<1); // Turn it off
DDRF |= (1<<4) | (1<<5); // Pins to red and blue, set as output
PORTF |= (1<<4) | (1<<5); // Turn them off
}
void matrix_init_kb(void) {
// put your keyboard start-up code here
// runs once when the firmware starts up
@@ -20,16 +19,6 @@ void matrix_init_kb(void) {
led_init();
}
void matrix_scan_kb(void) {
// put your looping keyboard code here
// runs every cycle (a lot)
matrix_scan_user();
}
void led_set_kb(uint8_t usb_led) {
}
#ifdef SWAP_HANDS_ENABLE
__attribute__ ((weak))
const keypos_t hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {

View File

@@ -53,15 +53,14 @@
k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, \
k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, \
k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, \
k31, k32, k33, k34, k35, k36, k37, k38, \
k41, k42, k43, k44, k45, k46, k47, k48 \
k31, k32, k33, k34, k35, k36, k37, k38, \
k41, k42, k43, k44, k45, k46, k47, k48 \
) \
{ \
{ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09 }, \
{ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19 }, \
{ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29 }, \
{ KC_NO, k31, k32, k33, k34, k35, k36, k37, k38, KC_NO }, \
{ KC_NO, k41, k42, k43, k44, k45, k46, k47, k48, KC_NO } \
}
{ \
{ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09 }, \
{ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19 }, \
{ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29 }, \
{ KC_NO, k31, k32, k33, k34, k35, k36, k37, k38, KC_NO }, \
{ KC_NO, k41, k42, k43, k44, k45, k46, k47, k48, KC_NO } \
}
#endif

View File

@@ -0,0 +1,41 @@
#pragma once
/* Prevent stuck modifiers */
#define PREVENT_STUCK_MODIFIERS
#ifdef AUDIO_ENABLE
#define STARTUP_SONG SONG(PLANCK_SOUND)
#define DEFAULT_LAYER_SONGS { SONG(QWERTY_SOUND), \
SONG(COLEMAK_SOUND) \
}
#endif
#define MUSIC_MASK (keycode != KC_NO)
/*
* MIDI options
*/
/* Prevent use of disabled MIDI features in the keymap */
//#define MIDI_ENABLE_STRICT 1
/* enable basic MIDI features:
- MIDI notes can be sent when in Music mode is on
*/
#define MIDI_BASIC
/* enable advanced MIDI features:
- MIDI notes can be added to the keymap
- Octave shift and transpose
- Virtual sustain, portamento, and modulation wheel
- etc.
*/
//#define MIDI_ADVANCED
/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
//#define MIDI_TONE_KEYCODE_OCTAVES 2
// Most tactile encoders have detents every 4 stages
#define ENCODER_RESOLUTION 4

View File

@@ -0,0 +1,204 @@
// This is the canonical layout file for the Quantum project. If you want to add another keyboard,
// this is the style you want to emulate.
#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.
enum planck_layers {
_QWERTY,
_COLEMAK,
_LOWER,
_RAISE,
_TOUCHCURSOR,
_MOUSE,
_ADJUST
};
enum planck_keycodes {
QWERTY = SAFE_RANGE,
COLEMAK,
LOWER,
RAISE,
};
#define LOWER MO(_LOWER)
#define RAISE MO(_RAISE)
// Taps
#define CTL_ESC CTL_T(KC_ESC) // Tap for Esc, hold for Ctr
#define SFT_ENT SFT_T(KC_ENT) // Tap for Enter, hold for Shift
#define LT_TC LT(_TOUCHCURSOR, KC_SPC) // L-ayer T-ap T-ouch C-ursor
#define LT_ML LT(_MOUSE, KC_A) // L-ayer T-ap M-ouse C-ursor (on A)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Qwerty
* ,--------------------------------------------------------------------------------------.
* | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
* |--------+------+------+------+------+-------------+------+------+------+------+-------|
* |Ctrl/Esc| ML/A | S | D | F | G | H | J | K | L | ; | " |
* |--------+------+------+------+------+------|------+------+------+------+------+-------|
* | Shift | Z | X | C | V | B | N | M | , | . | / |Sft/Ent|
* |--------+------+------+------+------+------+------+------+------+------+------+-------|
* | Power | ~ | Alt | GUI |Lower | TC/Space |Raise | Next | Vol- | Vol+ | Play |
* `--------------------------------------------------------------------------------------'
*/
[_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,
CTL_ESC, LT_ML, 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, SFT_ENT,
KC_CAPS, KC_TILD, KC_LALT, KC_LGUI, LOWER, LT_TC, LT_TC, RAISE, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY
),
/* Colemak
* ,-------------------------------------------------------------------------------------.
* | Tab | Q | W | F | P | G | J | L | U | Y | ; | Bksp |
* |--------+------+------+------+------+-------------+------+------+------+------+------|
* |Ctrl/Esc| ML/A | R | S | T | D | H | N | E | I | O | " |
* |--------+------+------+------+------+------|------+------+------+------+------+------|
* | Shift | Z | X | C | V | B | K | M | , | . | / |Enter |
* |--------+------+------+------+------+------+------+------+------+------+------+------|
* | Power | ~ | Alt | GUI |Lower | TC/Space |Raise | Next | Vol- | Vol+ | Play |
* `-------------------------------------------------------------------------------------'
*/
[_COLEMAK] = LAYOUT_planck_grid(
KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_BSPC,
CTL_ESC, LT_ML, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT,
KC_CAPS, KC_TILD, KC_LALT, KC_LGUI, LOWER, LT_TC, LT_TC, RAISE, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY
),
/* Lower
* ,-----------------------------------------------------------------------------------.
* | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | | F1 | F2 | F3 | F4 | F5 | F6 | - | + | { | } | ` |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | \ | F7 | F8 | F9 | F10 | F11 | F12 | _ | = | [ | ] | / |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* |Sleep | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_LOWER] = LAYOUT_planck_grid(
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC,
KC_PIPE, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_PLUS, KC_LCBR, KC_RCBR, KC_GRV,
KC_BSLS, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_UNDS, KC_EQL, KC_LBRC, KC_RBRC, KC_SLSH,
KC_SLEP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* Raise
* ,-----------------------------------------------------------------------------------.
* | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | ^ | 4 | 5 | 6 | . | + | * | 4 | 5 | 6 | - | $ |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | = | 7 | 8 | 9 | 0 | - | / | 1 | 2 | 3 | . |Enter |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* |Sleep | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_RAISE] = LAYOUT_planck_grid(
KC_0, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
KC_CIRC, KC_4, KC_5, KC_6, KC_DOT, KC_PLUS, KC_ASTR, KC_4, KC_5, KC_6, KC_MINS, KC_DLR,
KC_EQL, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_SLSH, KC_1, KC_2, KC_3, KC_DOT, KC_ENT,
KC_SLEP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* TouchCursor layer (http://martin-stone.github.io/touchcursor/) plus personal customizations
* ,-----------------------------------------------------------------------------------.
* | | | |Shift | GUI | ~ |Insert| Home | Up | End | Bksp | |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | Alt |Space | | Find |Again | PgUp | Left | Down |Right | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | | Undo | Cut | Copy |Paste | ` | PgDn | Del | | | | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*
* The KC_UNDO, KC_CUT, KC_COPY, KC_PASTE, KC_FIND, and KC_AGAIN keycodes don't
* seem to work on Mac. Presumably they'll work under Windows.
*/
[_TOUCHCURSOR] = LAYOUT_planck_grid(
_______, _______, _______, KC_LSFT, KC_LGUI, KC_TILD, KC_INS, KC_HOME, KC_UP, KC_END, KC_BSPC, _______,
_______, KC_LALT, KC_SPC, _______, KC_FIND,KC_AGAIN, KC_PGUP, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______,
_______, KC_UNDO, KC_CUT, KC_COPY, KC_PASTE,KC_GRV, KC_PGDN, KC_DEL, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* Mouse Layer
* ,-----------------------------------------------------------------------------------.
* | | |ACCL0 |ACCL1 |ACCL2 |ACCL2 | |WHL_L | Up |WHL_R | BTN2 | |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | | | BTN3 | BTN1 | BTN4 |WHL_Up| Left | Down |Right | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | | | | | BTN2 | BTN5 |WHL_Dn| BTN1 | | | | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_MOUSE] = LAYOUT_planck_grid(
_______, _______, KC_ACL0, KC_ACL1, KC_ACL2, KC_ACL2, _______, KC_WH_L, KC_MS_U, KC_WH_R, KC_BTN2, _______,
_______, _______, _______, KC_BTN3, KC_BTN1, KC_BTN4, KC_WH_U, KC_MS_L, KC_MS_D, KC_MS_R, _______, _______,
_______, _______, _______, _______, KC_BTN2, KC_BTN5, KC_WH_D, KC_BTN1, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* Adjust (Lower + Raise)
* ,-----------------------------------------------------------------------------------.
* | | Reset| | | | | | | | | | Del |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | | |Aud on|Audoff|AGnorm|AGswap|Qwerty|Colemk| | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | |Voice-|Voice+|Mus on|Musoff|MIDIon|MIDIof| | | | | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | | | | |
* `-----------------------------------------------------------------------------------'
*/
[_ADJUST] = LAYOUT_planck_grid(
_______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL,
_______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, QWERTY, COLEMAK, _______, _______, _______,
_______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
)
};
uint32_t layer_state_set_user(uint32_t state) {
return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case QWERTY:
if (record->event.pressed) {
set_single_persistent_default_layer(_QWERTY);
}
return false;
break;
case COLEMAK:
if (record->event.pressed) {
set_single_persistent_default_layer(_COLEMAK);
}
return false;
break;
}
return true;
}
bool music_mask_user(uint16_t keycode) {
switch (keycode) {
case RAISE:
case LOWER:
return false;
default:
return true;
}
}

View File

@@ -0,0 +1,17 @@
# The Am Planck Layout
Heavily inspired by other layouts out there, and fine tuned to work well on emacs (most recently spacemacs with vim bindings).
It features:
- Media keys (bottom right)
- Focused on Qwerty and Colemak
- Number pads (normal and reversed)
- TouchCursor layer
- Mouse layer
## Build
Making planck/rev4 with keymap am and target dfu
make planck/rev4:am:dfu

View File

@@ -0,0 +1,10 @@
# 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
#
MOUSEKEY_ENABLE = yes # 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 = yes # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
AUDIO_ENABLE = yes # Audio output on port C6

View File

@@ -22,7 +22,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
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_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, \
KC_LCTL, KC_LALT, KC_LGUI, MO(_FN1),KC_SPC, KC_BSPC, KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT
KC_LCTL, KC_LALT, KC_LGUI, MO(_FN1),KC_SPC, MO(_FN1),KC_BSPC, KC_RALT, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT
),
[_FN1] = LAYOUT(
@@ -30,6 +30,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
RGB_TOG, RGB_MOD, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, _______, _______,\
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
KC_TILD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
KC_TILD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
)
};

View File

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

View File

@@ -0,0 +1,35 @@
#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,
};
#define _______ KC_TRNS
#define XXXXXXX KC_NO
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_BASE] = LAYOUT_65(
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_DEL, KC_BSPC, KC_PGUP, \
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_PGDN, \
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_HOME, \
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_END, \
KC_LCTL, KC_LALT, KC_LGUI, MO(_FN1),KC_SPC, MO(_FN1),KC_SPC, KC_RALT, KC_RCTL, KC_RGUI, KC_LEFT, KC_DOWN, KC_RGHT
),
[_FN1] = LAYOUT_65(
KC_GESC, 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_BSPC, _______, \
RGB_TOG, RGB_MOD, _______, KC_UP, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
KC_TILD, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
)
};

View File

@@ -26,15 +26,15 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define DEVICE_VER 0x0100
#define MANUFACTURER Keebio
#define PRODUCT Quefrency
#define DESCRIPTION Split 60 percent staggered keyboard
#define DESCRIPTION Split 60/65 percent staggered keyboard
/* key matrix size */
// Rows are doubled-up
#define MATRIX_ROWS 10
#define MATRIX_ROWS 12
#define MATRIX_COLS 8
// wiring of each half
#define MATRIX_ROW_PINS { F4, D4, D7, E6, B4 }
#define MATRIX_ROW_PINS { F4, D4, D7, E6, B4, B5 }
#define MATRIX_COL_PINS { F5, F6, F7, B1, B3, B2, B6, C6 }
#define SPLIT_HAND_PIN D2

View File

@@ -18,7 +18,7 @@
LB1, LB2, LB3, LB4, LB5, LB6, RB1, RB2, RB3, RB4, RB5, RB6, RB7, RB8, \
LC1, LC2, LC3, LC4, LC5, LC6, RC1, RC2, RC3, RC4, RC5, RC6, RC8, \
LD1, LD3, LD4, LD5, LD6, LD7, RD1, RD2, RD3, RD4, RD6, RD7, RD8, \
LE1, LE2, LE3, LE5, LE7, RE1, RE4, RE5, RE6, RE7, RE8 \
LE1, LE2, LE3, LE5, LE7, RE1, RE2, RE4, RE5, RE6, RE7, RE8 \
) \
{ \
{ LA1, LA2, LA3, LA4, LA5, LA6, LA7, KC_NO }, \
@@ -26,9 +26,33 @@
{ LC1, LC2, LC3, LC4, LC5, LC6, KC_NO, KC_NO }, \
{ LD1, KC_NO, LD3, LD4, LD5, LD6, LD7, KC_NO }, \
{ LE1, LE2, LE3, KC_NO, LE5, KC_NO, LE7, KC_NO }, \
{ KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO }, \
{ RA1, RA2, RA3, RA4, RA5, RA6, RA7, RA8 }, \
{ RB1, RB2, RB3, RB4, RB5, RB6, RB7, RB8 }, \
{ RC1, RC2, RC3, RC4, RC5, RC6, KC_NO, RC8 }, \
{ RD1, RD2, RD3, RD4, KC_NO, RD6, RD7, RD8 }, \
{ RE1, KC_NO, KC_NO, RE4, RE5, RE6, RE7, RE8 } \
{ RE1, RE2, KC_NO, RE4, RE5, RE6, RE7, RE8 }, \
{ KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO } \
}
#define LAYOUT_65( \
LA1, LA2, LA3, LA4, LA5, LA6, LA7, RA1, RA2, RA3, RA4, RA5, RA6, RA7, RA8, RA9, \
LB1, LB2, LB3, LB4, LB5, LB6, RB1, RB2, RB3, RB4, RB5, RB6, RB7, RB8, RB9, \
LC1, LC2, LC3, LC4, LC5, LC6, RC1, RC2, RC3, RC4, RC5, RC6, RC8, RC9, \
LD1, LD3, LD4, LD5, LD6, LD7, RD1, RD2, RD3, RD4, RD6, RD7, RD8, RD9, \
LE1, LE2, LE3, LE5, LE7, RE1, RE2, RE4, RE5, RE6, RE7, RE8, RE9 \
) \
{ \
{ LA1, LA2, LA3, LA4, LA5, LA6, LA7, KC_NO }, \
{ LB1, LB2, LB3, LB4, LB5, LB6, KC_NO, KC_NO }, \
{ LC1, LC2, LC3, LC4, LC5, LC6, KC_NO, KC_NO }, \
{ LD1, KC_NO, LD3, LD4, LD5, LD6, LD7, KC_NO }, \
{ LE1, LE2, LE3, KC_NO, LE5, KC_NO, LE7, KC_NO }, \
{ KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO }, \
{ RA1, RA2, RA3, RA4, RA5, RA6, RA7, RA8 }, \
{ RB1, RB2, RB3, RB4, RB5, RB6, RB7, RB8 }, \
{ RC1, RC2, RC3, RC4, RC5, RC6, RC9, RC8 }, \
{ RD1, RD2, RD3, RD4, RD9, RD6, RD7, RD8 }, \
{ RE1, RE2, RE9, RE4, RE5, RE6, RE7, RE8 }, \
{ KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, RA9, RB9 } \
}

View File

@@ -0,0 +1,40 @@
/*
Copyright 2018 Jeremy Herve <jeremy@jeremy.hu>
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 */
/* Change the default tapping toggle value (normally 5) */
#define TAPPING_TOGGLE 2
#define USE_SERIAL
//#define USE_I2C
/* Select hand configuration */
#define MASTER_LEFT
// #define MASTER_RIGHT
// #define EE_HANDS
#undef RGBLED_NUM
//#define RGBLIGHT_ANIMATIONS
#define RGBLED_NUM 14
#define RGBLIGHT_HUE_STEP 8
#define RGBLIGHT_SAT_STEP 8
#define RGBLIGHT_VAL_STEP 8
#define RGBLIGHT_SLEEP

View File

@@ -0,0 +1,282 @@
#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 _COLEMAK 0
#define _SYMB 1
#define _NAV 2
#define _INTER 3
#define _ADJUST 4
enum custom_keycodes {
COLEMAK = SAFE_RANGE,
SYMB,
NAV,
INTER,
ADJUST,
// These use process_record_user()
M_BRACKET_LEFT,
M_BRACKET_RIGHT,
SHRUG,
WAVE,
YOSHI,
THUMB_UP,
NBSP
};
// Fillers to make layering more clear
#define KC_ KC_TRNS
#define _______ KC_TRNS
#define XXXXXXX KC_NO
// Make macros a bit simpler with this shortcut.
#define TAP_ONCE(code) \
register_code (code); \
unregister_code (code)
// Is shift being held? Let's store this in a bool.
static bool shift_held = false;
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch(keycode) {
case SHRUG:
if (record->event.pressed) {
unicode_input_start(); register_hex(0xaf); unicode_input_finish();
TAP_ONCE (KC_BSLS);
register_code (KC_RSFT); TAP_ONCE (KC_MINS); TAP_ONCE (KC_9); unregister_code (KC_RSFT);
unicode_input_start (); register_hex(0x30c4); unicode_input_finish();
register_code (KC_RSFT); TAP_ONCE (KC_0); TAP_ONCE (KC_MINS); unregister_code (KC_RSFT);
TAP_ONCE (KC_SLSH);
unicode_input_start (); register_hex(0xaf); unicode_input_finish();
}
return false;
break;
case YOSHI:
if (record->event.pressed) {
SEND_STRING(":yellow_yoshi:");
}
return false;
break;
case THUMB_UP:
if (record->event.pressed) {
SEND_STRING(SS_LALT("D83D+DC4D"));
}
return false;
break;
case WAVE:
if (record->event.pressed) {
SEND_STRING(SS_LALT("D83D+DC4B"));
}
return false;
break;
case NBSP:
if (record->event.pressed) {
SEND_STRING("&nbsp;");
}
return false;
break;
case KC_LSFT:
shift_held = record->event.pressed;
return true;
break;
case KC_RSFT:
shift_held = record->event.pressed;
return true;
break;
case M_BRACKET_LEFT: {
if (record->event.pressed) {
if (shift_held) {
unregister_code(KC_LSFT);
unregister_code(KC_RSFT);
register_code(KC_LBRC);
} else {
register_code(KC_LSFT);
register_code(KC_9);
}
} else { // Release the key
unregister_code(KC_LBRC);
unregister_code(KC_LSFT);
unregister_code(KC_RSFT);
unregister_code(KC_9);
}
return false;
break;
}
case M_BRACKET_RIGHT: {
if (record->event.pressed) {
if (shift_held) {
unregister_code(KC_LSFT);
unregister_code(KC_RSFT);
register_code(KC_RBRC);
} else {
register_code(KC_LSFT);
register_code(KC_0);
}
} else { // Release the key
unregister_code(KC_RBRC);
unregister_code(KC_LSFT);
unregister_code(KC_RSFT);
unregister_code(KC_0);
}
return false;
break;
}
}
return true;
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* COLEMAK
* ,------------------------------------------------. ,------------------------------------------------.
* | ` | 1 | 2 | 3 | 4 | 5 | Esc | | Exp | 6 | 7 | 8 | 9 | 0 | = |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | Tab | Q | W | F | P | G | ( | | ) | J | L | U | Y | ; | \ |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | Lay1 | A | R | S | T | D | Lay2 | | Lay2 | H | N | E | I | O |'/Lay1|
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | Shift| Z | X | C | V | B | Lay1 | | Lay1 | K | M | , | . | / |Shift |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | Lay3 | Ctrl | Hyper| Alt | Cmd |Bcksp | Ctrl | |Enter |Space | Cmd | Lay4 | Hyper| Ctrl | Lay3 |
* `------------------------------------------------' `------------------------------------------------'
*/
[_COLEMAK] = LAYOUT(
//,----+----+----+----+----+----+----. ,----+----+----+----+----+----+----.
KC_GRV , KC_1 , KC_2 , KC_3 , KC_4 , KC_5 ,KC_ESC, LCTL(KC_DOWN), KC_6 , KC_7 , KC_8 , KC_9 , KC_0 , KC_EQL,
//|----+----+----+----+----+----+----| |----+----+----+----+----+----+----|
KC_TAB , KC_Q , KC_W , KC_F , KC_P , KC_G , M_BRACKET_LEFT, M_BRACKET_RIGHT , KC_J , KC_L , KC_U , KC_Y , KC_SCLN , KC_BSLS,
//|----+----+----+----+----+----+----| |----+----+----+----+----+----+----|
MO(_SYMB) , KC_A , KC_R , KC_S , KC_T , KC_D ,TT(_NAV), TT(_NAV) , KC_H , KC_N , KC_E , KC_I , KC_O , LT(_SYMB,KC_QUOT),
//|----+----+----+----+----+----+----| |----+----+----+----+----+----+----|
KC_LSFT , KC_Z , KC_X , KC_C , KC_V , KC_B ,TT(_SYMB), TT(_SYMB) , KC_K , KC_M , KC_COMM , KC_DOT , KC_SLSH , KC_RSFT,
//|----+----+----+----+----+----+----| |----+----+----+----+----+----+----|
MO(_INTER),KC_LCTL,KC_HYPR,KC_LALT, KC_LCMD, KC_BSPC,KC_LCTL, KC_ENT,KC_SPC , KC_RCMD , TT(_ADJUST),KC_HYPR,KC_RCTL,MO(_INTER)
//`----+----+----+----+----+----+----' `----+----+----+----+----+----+----'
),
/* Symbols
* ,------------------------------------------------. ,------------------------------------------------.
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | 1 | 2 | 3 | 4 | 5 | | | | 6 | 7 | 8 | 9 | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | ! | @ | # | $ | % | | | | ^ | & | * | - | _ | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* `------------------------------------------------' `------------------------------------------------'
*/
[_SYMB] = LAYOUT(
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, KC_1 , KC_2 , KC_3 , KC_4 , KC_5 , KC_LCBR, KC_RCBR, KC_6 , KC_7 , KC_8 , KC_9 , KC_0 , _______,
_______, KC_EXLM, KC_AT , KC_HASH, KC_DLR , KC_PERC, _______, _______, KC_CIRC, KC_AMPR, KC_ASTR, KC_MINS, KC_UNDS, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* Navigation
* ,------------------------------------------------. ,------------------------------------------------.
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | |VOLDOW|VOL UP| MUTE | | | | LEFT | DOWN | UP |RIGHT | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* `------------------------------------------------' `------------------------------------------------'
*/
[_NAV] = LAYOUT(
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, KC_VOLD, KC_VOLU, KC_MUTE, XXXXXXX, _______, _______, XXXXXXX, KC_LEFT, KC_DOWN, KC_UP , KC_RIGHT, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, _______
),
/* i18n + emoji
* ,------------------------------------------------. ,------------------------------------------------.
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | à | 👋 | | | | | | | | ü | è | YOSHI| ö | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | á | |SHRUG | 👍 | | | | | | ú | é | í | ó | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | â | | ç | | | | | | | ű | ê | | ő | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* `------------------------------------------------' `------------------------------------------------'
*/
[_INTER] = LAYOUT(
XXXXXXX, _______ , _______, _______ , _______ , _______, _______, _______, _______, _______, _______, _______, _______, _______,
XXXXXXX, UC(0x00E0), WAVE , XXXXXXX , XXXXXXX , XXXXXXX, _______, _______, XXXXXXX, UC(0x00FC), UC(0x00E8), YOSHI, UC(0x00F6), XXXXXXX,
_______, UC(0x00E1), XXXXXXX, SHRUG , THUMB_UP, XXXXXXX, _______, _______, XXXXXXX, UC(0x00F9), UC(0x00E9), UC(0x00ED) , UC(0x00F3), _______,
XXXXXXX, UC(0x00E2), XXXXXXX, UC(0x00E7), XXXXXXX , XXXXXXX, _______, _______, XXXXXXX, UC(0x0171), UC(0x00EA), XXXXXXX, UC(0x0151), XXXXXXX,
_______, XXXXXXX , XXXXXXX, XXXXXXX , XXXXXXX , XXXXXXX, _______, _______, NBSP, XXXXXXX, _______, XXXXXXX, XXXXXXX, _______
),
/* Adjust keyboard settings
* ,------------------------------------------------. ,------------------------------------------------.
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | RGB- | RGB+ |RGB ON| | | | | | RESET| DEBUG|AUD ON| | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
* | | | | | | | | | | | | | | | |
* `------------------------------------------------' `------------------------------------------------'
*/
[_ADJUST] = LAYOUT(
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
_______, XXXXXXX, RGB_VAD, RGB_VAI, RGB_TOG, XXXXXXX, _______, _______, XXXXXXX, RESET , DEBUG , AU_TOG , XXXXXXX, _______,
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, _______, XXXXXXX, XXXXXXX, _______
)
};
#ifdef AUDIO_ENABLE
float tone_colemak[][2] = SONG(ZELDA_TREASURE);
#endif
void persistent_default_layer_set(uint16_t default_layer) {
eeconfig_update_default_layer(default_layer);
default_layer_set(default_layer);
}
// Set unicode in Mac OS.
void matrix_init_user(void) {
set_unicode_input_mode(UC_OSX);
};
// Change LED colors depending on the layer.
uint32_t layer_state_set_user(uint32_t state) {
switch (biton32(state)) {
case _SYMB:
rgblight_setrgb_orange();
break;
case _NAV:
rgblight_setrgb_springgreen();
break;
case _INTER:
rgblight_setrgb_teal();
break;
case _ADJUST:
rgblight_setrgb_red();
break;
default: // for any other layers, or the default layer
rgblight_setrgb_yellow();
break;
}
return state;
};

View File

@@ -0,0 +1,37 @@
# A Colemak keymap for the Redox keyboard
----
![jeherve-redox-layout-3](https://user-images.githubusercontent.com/426388/45171716-69888200-b203-11e8-822d-7bc91f9f6c07.jpg)
----
This keymap is **a work in progress**, and is meant to be used on macOS, with the "Unicode Hex Input" keyboard input.
![macOS keyboard input setting](https://user-images.githubusercontent.com/426388/43962498-1ee9e3fc-9cb8-11e8-88e3-dbb068ec5c67.png)
I may change a lot of the keys over the next few months, and will update this repo when I do so.
[View on KLE](http://www.keyboard-layout-editor.com/#/gists/3d5368842d87a8462c8f95d4382c4a19)
## Layers
My keymap uses 5 layers:
1. The default base layer, using [Colemak](https://colemak.com/).
2. A Symbol layer, so all symbols can be accessed from the home row. (top right legends)
3. A Navigation / Media layer, with both sound control and arrows on the home row. (bottom right legends)
4. An international / Emoji layer so I can type accented characters commonly used in France and in Hungary, as well as a few Emoji I often use. (top center legends)
5. A keyboard control layer, not pictured above, allowing me to control the LED lighting as well as the keyboard debug functions.
## Changelog
- 2018.09.06
- Initial submission to QMK. It's alive! ⌨️
## Credits
- Redox keyboard design by [Mattia Dal Ben](https://github.com/mattdibi/redox-keyboard).
- This keymap is based off the default keymap for the Redox keyboard, available [here](https://github.com/qmk/qmk_firmware/tree/master/keyboards/redox) and also build by Mattia Dal Ben (thank you!).
- This layout uses [QMK keyboard controller firmware](https://github.com/qmk/qmk_firmware/).
I've also read posts by [Gergely Nagy](https://asylum.madhouse-project.org/blog/2016/10/15/multi-purpose-keys/), [Rebecca Le](https://sevenseacat.net/posts/2018/unicode-in-qmk-on-osx/), and [Justin Rogers](https://implementsblog.com/2016/10/16/my-ergodox-ezs-custom-layout/#comments) for inspiration.

View File

@@ -0,0 +1,3 @@
RGBLIGHT_ENABLE = yes
UNICODE_ENABLE = yes
AUDIO_ENABLE = yes

View File

@@ -0,0 +1,56 @@
#include QMK_KEYBOARD_H
#include "action_layer.h"
#define _DEFAULT 0
#define _FN 1
enum planck_keycodes {
DEFAULT = SAFE_RANGE
};
// Fillers to make layering more clear
#define ______ KC_TRNS
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Qwerty gui/alt/space/alt/gui
* ,-----------------------------------------------------------------------------------------.
* | Esc | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | - | = | \ | ` |
* |-----------------------------------------------------------------------------------------+
* | Tab | Q | W | E | R | T | Y | U | I | O | P | [ | ] | Bksp |
* |-----------------------------------------------------------------------------------------+
* | Ctrl | A | S | D | F | G | H | J | K | L | ; | ' | Enter |
* |-----------------------------------------------------------------------------------------+
* | Shift | Z | X | C | V | B | N | M | , | . | / | RShift | FN |
* |-----------------------------------------------------------------------------------------+
* |LGUI | LAlt | 7U Space | RAlt |RGUI |
* `-----------------------------------------------------------------'
*/
[_DEFAULT] = LAYOUT_60_hhkb( /* Basic QWERTY */
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_BSLS, 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_BSPC, \
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_ENT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(_FN), \
______, KC_LGUI,KC_LALT, KC_SPC, ______,KC_RALT, KC_RGUI, ______ \
),
/* FN Layer
* ,-----------------------------------------------------------------------------------------.
* | | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Ins | Del |
* |-----------------------------------------------------------------------------------------+
* | CAPS | | | | | | | | Psc | Slck| Paus| Up | | |
* |-----------------------------------------------------------------------------------------+
* | | Vol-| Vol+| Mute| | | * | / | Home| PgUp| Left|Right| |
* |-----------------------------------------------------------------------------------------+
* | | BL | BL- | BL+ | | | + | - | End |PgDn| Down| | |
* |-----------------------------------------------------------------------------------------+
* | | | | | |
* `-----------------------------------------------------------------'
*/
[_FN] = LAYOUT_60_hhkb( /* Layer 1 */
______, 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_INS, KC_DEL, \
KC_CAPS, ______, ______, ______, ______, ______, ______, ______, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, ______, ______, \
______, KC_VOLD,KC_VOLU,KC_MUTE,______, ______, KC_PAST,KC_PSLS,KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, ______, \
______, BL_DEC,BL_INC,BL_TOGG,______, ______, KC_PPLS,KC_PMNS,KC_END, KC_PGDN, KC_DOWN, ______, ______, \
______, ______, ______, ______, ______, ______, ______, ______ \
)
};

View File

@@ -0,0 +1,9 @@
# Dbroqua HHKB like Layout
Like the HHKB but with a Satan GH60 PCB :D.
# Programming Instructions:
Enter into programming mode and run the following command.
```
$ sudo KEYMAP=dbroqua_hhkb make dfu
```

View File

@@ -0,0 +1,3 @@
#pragma once
// place overrides here

View File

@@ -0,0 +1,47 @@
#include QMK_KEYBOARD_H
#define BL 0
#define FN 1
/*
* Default HHKB Layout
*/
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* 0: Default layer
┌─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┐
│ Esc │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ - │ = │ \ │ ` │
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │BkSpc│█████│
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│Ctrl │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │█████│Enter│█████│
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│Shift│█████│ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │█████│Shift│ Fn │
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│█████│ Gui │ Alt │█████│█████│Space│█████│█████│█████│█████│█████│ Alt │ Gui │█████│█████│
└─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┘
*/
[BL] = LAYOUT_60_hhkb(
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_BSLS, 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_BSPC, \
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_ENT, \
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(FN), \
KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI ),
/* 1: HHKB Fn layer
┌─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┐
│ │ F1 │ F2 │ F3 │ F4 │ F5 │ F6 │ F7 │ F8 │ F9 │ F10 │ F11 │ F12 │ Ins │ Del │
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│Caps │ RGB │RGBfw│RGBrv│BLtog│BLstp│ │ │ Psc │ Slk │ Pus │ Up │ │ │█████│
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│ │ VoD │ VoU │ Mut │ │ │NP_* │NP_/ │Home │PgUp │Left │Right│█████│NPEnt│█████│
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│ │█████│ │ │Calc │ │ │NP_+ │NP_- │ End │PgDwn│Down │█████│ │ │
├─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
│█████│ │ │█████│█████│█████│ │█████│█████│█████│█████│ │ │█████│█████│
└─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┘
*/
[FN]= LAYOUT_60_hhkb(
KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL, \
KC_CAPS, RGB_TOG, RGB_MOD, RGB_RMOD, BL_TOGG, BL_STEP, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, KC_TRNS, \
KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_TRNS, KC_TRNS, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_PENT, \
KC_TRNS, KC_TRNS, KC_TRNS, KC_CALC, KC_TRNS, KC_TRNS, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS, \
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS ),
};

View File

@@ -0,0 +1,5 @@
[{a:7},"","","","","","","","","","","","","",{w:2},"",{x:0.25},"",""],
[{w:1.5},"","","","","","","","","","","","","",{w:1.5},"",{x:0.25},"",""],
[{w:1.75},"","","","","","","","","","","","",{w:2.25},""],
[{w:2.25},"","","","","","","","","","","",{w:2.75},"",{x:0.25},""],
[{w:1.25},"",{w:1.25},"",{w:1.25},"",{w:6.25},"",{w:1.25},"",{w:1.25},"",{w:1.25},"",{x:0.5},"","",""]

View File

@@ -0,0 +1,18 @@
#include QMK_KEYBOARD_H
#include "mechmerlin.h"
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_BL] = LAYOUT_68_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_INS, KC_PGUP,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_PGDN,
KC_CTCP, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(_FL), KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT),
[_FL] = LAYOUT_68_ansi(\
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_DEL, 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_MUTE, KC_VOLD, KC_VOLU, 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),
};

View File

@@ -0,0 +1 @@
USER_NAME := mechmerlin

View File

@@ -0,0 +1,5 @@
# 68_ansi
LAYOUT_68_ansi
This is the 68 key ANSI layout made popular by boards such as the Magicforce 68 and Varmilo VA68M.

View File

@@ -0,0 +1,33 @@
#pragma once
#define ADVENTURE_TIME \
H__NOTE(_F5), \
Q__NOTE(_F5), \
H__NOTE(_F5), \
H__NOTE(_G5), \
H__NOTE(_E5), \
H__NOTE(_E5), \
H__NOTE(_D5), \
H__NOTE(_C5), \
HD_NOTE(_C6),
#ifdef AUDIO_ENABLE
#define STARTUP_SONG SONG(ADVENTURE_TIME)
#define AUDIO_CLICKY
#define AUDIO_CLICKY_ON
#define AUDIO_CLICKY_FREQ_MAX 2500.0f
#define AUDIO_CLICKY_FREQ_RANDOMNESS 0.2f
#define AUDIO_CLICKY_FREQ_DEFAULT 110.0f
#endif
// for some reason the LSvi rev1 disables action tapping...
#ifdef NO_ACTION_TAPPING
#undef NO_ACTION_TAPPING
#endif
#undef BACKLIGHT_LEVELS
#define BACKLIGHT_LEVELS 15
// let's split configuration:
#define USE_I2C
#define EE_HANDS

View File

@@ -0,0 +1,5 @@
#pragma once
void flicker_toggle(void);
void flicker_keydown(void);
void flicker_keyup(void);

View File

@@ -0,0 +1,230 @@
#include QMK_KEYBOARD_H
#ifdef BACKLIGHT_ENABLE
#include "flicker.h"
#endif
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.
enum planck_layers {
_QWERTY,
_LOWER,
_RAISE,
_ADJUST
};
// keycodes custom to this keymap:
enum planck_keycodes {
QWERTY = SAFE_RANGE,
BL_FLICKER
};
// flicker state:
#ifdef BACKLIGHT_ENABLE
bool flicker_enable = true;
bool flicker_isdown = false;
const uint8_t flicker_min_levels = 2;
const uint8_t flicker_max_levels = 7;
uint8_t flicker_restore_level = 0;
#endif
// Fillers to make layering more clear
#define _______ KC_TRNS
#define XXXXXXX KC_NO
#define LOWER MO(_LOWER)
#define RAISE MO(_RAISE)
// mod tap definitions:
#define CTRL_ESC MT(MOD_LCTL, KC_ESC)
#define HYPR_SPC MT(MOD_HYPR, KC_SPC)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Qwerty
* ,-----------------------------------------------------------------------------------.
* | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | Ctrl | A | S | D | F | G | H | J | K | L | ; | ' |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | Shift| Z | X | C | V | B | N | M | , | . | / |Enter |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | Esc | Del | GUI | Alt |Lower |HyprSp|Space |Raise | Left | Down | Up |Right |
* `-----------------------------------------------------------------------------------'
*/
[_QWERTY] = LAYOUT_ortho_4x12(
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
CTRL_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_ENT , \
KC_MPLY, KC_DEL, KC_LGUI, KC_LALT, LOWER, HYPR_SPC, KC_SPC, RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT \
),
/* Lower
* ,-----------------------------------------------------------------------------------.
* | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | Home | End | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | Next | Vol- | Vol+ | Play |
* `-----------------------------------------------------------------------------------'
*/
[_LOWER] = LAYOUT_ortho_4x12(
KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, \
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, \
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, S(KC_NUHS), S(KC_NUBS), KC_HOME, KC_END, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
),
/* Raise
* ,-----------------------------------------------------------------------------------.
* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / |Pg Up |Pg Dn | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | | Next | Vol- | Vol+ | Play |
* `-----------------------------------------------------------------------------------'
*/
[_RAISE] = LAYOUT_ortho_4x12(
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, \
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, \
_______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, KC_PGUP, KC_PGDN, _______, \
_______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY \
),
/* Adjust (Lower + Raise)
* ,-----------------------------------------------------------------------------------.
* | | Reset| | | | | | | | | | Del |
* |------+------+------+------+------+-------------+------+------+------+------+------|
* | | | |Aud on|Audoff|AGnorm|AGswap| | | | | |
* |------+------+------+------+------+------|------+------+------+------+------+------|
* | |Voice-|Voice+|Mus on|Musoff|MIDIon|MIDIof| | | | | |
* |------+------+------+------+------+------+------+------+------+------+------+------|
* | | | | | | | |Clicky|ClkDn |ClkUp |ClkRst|
* `-----------------------------------------------------------------------------------'
*/
[_ADJUST] = LAYOUT_ortho_4x12(
_______, RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_DEL, \
_______, _______, _______, AU_ON, AU_OFF, AG_NORM, AG_SWAP, _______, _______, _______, _______, _______, \
_______, MUV_DE, MUV_IN, MU_ON, MU_OFF, MI_ON, MI_OFF, _______, BL_TOGG, BL_DEC, BL_INC, BL_FLICKER, \
_______, _______, _______, _______, _______, _______, _______, _______, CLICKY_TOGGLE, CLICKY_DOWN, CLICKY_UP, CLICKY_RESET \
),
}; // end keymaps
// if backlighting is enabled, configure it on boot
#ifdef BACKLIGHT_ENABLE
void matrix_init_user(void) {
// set to max
backlight_level(BACKLIGHT_LEVELS);
flicker_restore_level = get_backlight_level();
// if breathing happens to be compiled in, turn it off
#ifdef BACKLIGHT_BREATHING
breathing_disable();
#endif
}
#endif
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
{
return MACRO_NONE;
};
void persistant_default_layer_set(uint16_t default_layer) {
eeconfig_update_default_layer(default_layer);
default_layer_set(default_layer);
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
// handle the _ADJUST layer and custom keycodes:
switch (keycode) {
case LOWER:
if (record->event.pressed) {
layer_on(_LOWER);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
} else {
layer_off(_LOWER);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
}
return false;
break;
case RAISE:
if (record->event.pressed) {
layer_on(_RAISE);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
} else {
layer_off(_RAISE);
update_tri_layer(_LOWER, _RAISE, _ADJUST);
}
return false;
break;
#ifdef BACKLIGHT_ENABLE
case BL_FLICKER:
if (record->event.pressed) {
flicker_toggle();
}
return false;
break;
#endif
} // end switch case over custom keycodes
#ifdef BACKLIGHT_ENABLE
if (flicker_enable) {
if (record->event.pressed) {
flicker_keydown();
} else {
flicker_keyup();
}
}
#endif
return true;
}
void encoder_update(bool clockwise) {
if (clockwise) {
register_code(KC_VOLU);
unregister_code(KC_VOLU);
} else {
register_code(KC_VOLD);
unregister_code(KC_VOLD);
}
}
// flicker implementation:
#ifdef BACKLIGHT_ENABLE
void flicker_toggle(void) {
flicker_enable = !flicker_enable;
}
void flicker_keydown(void) {
// guard condition: only set the level to restore if the flicker is NOT already down
if (!flicker_isdown) {
flicker_restore_level = get_backlight_level();
flicker_isdown = true;
}
// calculate a random flicker level between min and max
uint8_t flicker_level = (rand() % (flicker_max_levels - flicker_min_levels)) + flicker_min_levels;
uint8_t level_to_set = flicker_level <= flicker_restore_level ? flicker_restore_level - flicker_level : 0;
backlight_level(level_to_set);
}
void flicker_keyup(void) {
backlight_level(flicker_restore_level);
flicker_isdown = false;
}
#endif

View File

@@ -0,0 +1,19 @@
# Josh's 4x12 layout
Notable features:
* Esc is Ctrl on hold
* Left space is `MOD_HYPER` on hold
* Backspace is still backspace on `RAISE` and `LOWER`
* Faux clicky controls are on the arrow keys on the `ADJUST` layer, and the backlight controls are directly above that
* Backlight breathing is disabled; backlight flickering is implemented instead
* Colemak and other layouts are thoroughly disabled
* Rotary encoder controls media volume on base layer
This layout has been tested on:
* Let's Split (rev 2)
* Let's Split Vitamins Included (rev 1)
* Planck (rev 4)
It builds for the Planck rev 6 but has not been tested yet.

View File

@@ -0,0 +1,26 @@
# none of my keyboards need LTO and it screws up I2C on my LSVI:
EXTRAFLAGS:=$(filter-out -flto,$(EXTRAFLAGS))
# turning off backlighting and audio for the split keebs
ifneq (,$(findstring lets_split,$(KEYBOARD)))
BACKLIGHT_ENABLE = no
BACKLIGHT_BREATHING = no
AUDIO_ENABLE = no
endif
ifneq (,$(findstring vitamins_included,$(KEYBOARD)))
BACKLIGHT_ENABLE = no
BACKLIGHT_BREATHING = no
AUDIO_ENABLE = no
endif
# both my plancks use audio but only the rev4 has backlighting
ifneq (,$(findstring planck,$(KEYBOARD)))
ifneq (,$(findstring rev4,$(KEYBOARD)))
BACKLIGHT_ENABLE = yes
BACKLIGHT_BREATHING = no
else
BACKLIGHT_ENABLE = no
BACKLIGHT_BREATHING = no
endif
AUDIO_ENABLE = yes
endif

View File

@@ -0,0 +1,11 @@
#include QMK_KEYBOARD_H
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* layer 0: qwerty */
[0] = LAYOUT_65_ansi(\
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_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_PGUP,
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_PGDN,
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_END,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT)
};

View File

@@ -0,0 +1,5 @@
["","","","","","","","","","","","","",{w:2},"",""],
[{w:1.5},"","","","","","","","","","","","","",{w:1.5},"",""],
[{w:1.75},"","","","","","","","","","","","",{w:2.25},"",""],
[{w:2.25},"","","","","","","","","","","",{w:1.75},"","",""],
[{w:1.25},"",{w:1.25},"",{w:1.25},"",{w:6.25},"","","","","","",""]

View File

@@ -0,0 +1,5 @@
# 65_ansi
LAYOUT_65_ansi
This is the 65% ANSI layout made popular by boards such as the [Input Club Whitefox](https://github.com/qmk/qmk_firmware/tree/master/keyboards/whitefox) and [RAMA M65-A](https://github.com/qmk/qmk_firmware/tree/master/keyboards/jc65).

View File

@@ -3,9 +3,9 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* layer 0: qwerty */
[0] = LAYOUT_68_ansi(\
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_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_PGUP,
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_PGDN,
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_END,
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_INS, KC_PGUP,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_PGDN,
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT)
};

View File

@@ -1,5 +1,5 @@
["","","","","","","","","","","","","",{w:2},"",""],
[{w:1.5},"","","","","","","","","","","","","",{w:1.5},"",""],
[{w:1.75},"","","","","","","","","","","","",{w:2.25},"",""],
[{w:2.25},"","","","","","","","","","","",{w:1.75},"","",""],
[{w:1.25},"",{w:1.25},"",{w:1.25},"",{w:6.25},"","","","","","",""]
[{a:7},"","","","","","","","","","","","","",{w:2},"",{x:0.25},"",""],
[{w:1.5},"","","","","","","","","","","","","",{w:1.5},"",{x:0.25},"",""],
[{w:1.75},"","","","","","","","","","","","",{w:2.25},""],
[{w:2.25},"","","","","","","","","","","",{w:2.75},"",{x:0.25},""],
[{w:1.25},"",{w:1.25},"",{w:1.25},"",{w:6.25},"",{w:1.25},"",{w:1.25},"",{w:1.25},"",{x:0.5},"","",""]

View File

@@ -1,3 +1,5 @@
# 68_ansi
LAYOUT_68_ansi
LAYOUT_68_ansi
This is the 68 key ANSI layout made popular by boards such as the Magicforce 68 and Varmilo VA68M.

View File

@@ -41,8 +41,8 @@
#define NO_DLR_MAC LSFT(KC_4) // $
#define NO_GRV_MAC ALGR(NO_BSLS) // `
#define NO_GRTR_MAC LSFT(KC_GRV) // >
#define NO_LCBR_MAC ALGR(LSFT(KC_8)) // }
#define NO_LESS_MAC KC_GRV // >
#define NO_LCBR_MAC ALGR(LSFT(KC_8)) // {
#define NO_LESS_MAC KC_GRV // <
#define NO_PIPE_MAC ALGR(KC_7) // |
#define NO_RCBR_MAC ALGR(LSFT(KC_9)) // }

View File

@@ -71,8 +71,8 @@ static matrix_row_t matrix_debouncing[MATRIX_ROWS];
static uint8_t error_count = 0;
static const uint8_t row_pins[MATRIX_ROWS] = MATRIX_ROW_PINS;
static const uint8_t col_pins[MATRIX_COLS] = MATRIX_COL_PINS;
static uint8_t row_pins[MATRIX_ROWS] = MATRIX_ROW_PINS;
static uint8_t col_pins[MATRIX_COLS] = MATRIX_COL_PINS;
/* matrix state(1:on, 0:off) */
static matrix_row_t matrix[MATRIX_ROWS];
@@ -137,6 +137,21 @@ void matrix_init(void)
debug_enable = true;
debug_matrix = true;
debug_mouse = true;
// Set pinout for right half if pinout for that half is defined
if (!isLeftHand) {
#ifdef MATRIX_ROW_PINS_RIGHT
const uint8_t row_pins_right[MATRIX_ROWS] = MATRIX_ROW_PINS_RIGHT;
for (uint8_t i = 0; i < MATRIX_ROWS; i++)
row_pins[i] = row_pins_right[i];
#endif
#ifdef MATRIX_COL_PINS_RIGHT
const uint8_t col_pins_right[MATRIX_COLS] = MATRIX_COL_PINS_RIGHT;
for (uint8_t i = 0; i < MATRIX_COLS; i++)
col_pins[i] = col_pins_right[i];
#endif
}
// initialize row and col
#if (DIODE_DIRECTION == COL2ROW)
unselect_rows();

View File

@@ -15,5 +15,35 @@
*/
#include "bootloader.h"
#include "samd51j18a.h"
void bootloader_jump(void) {}
//Set watchdog timer to reset. Directs the bootloader to stay in programming mode.
void bootloader_jump(void)
{
//Keyboards released with certain bootloader can not enter bootloader from app until workaround is created
uint8_t ver_no_jump[] = "v2.18Jun 22 2018 17:28:08";
uint8_t *ver_check = ver_no_jump;
uint8_t *boot_check = (uint8_t *)0x21A0;
while (*ver_check && *boot_check == *ver_check)
{
ver_check++;
boot_check++;
}
if (!*ver_check)
{
//Version match
//Software workaround would go here
return; //No software restart method implemented... must use hardware reset button
}
WDT->CTRLA.bit.ENABLE = 0;
while (WDT->SYNCBUSY.bit.ENABLE) {}
while (WDT->CTRLA.bit.ENABLE) {}
WDT->CONFIG.bit.WINDOW = 0;
WDT->CONFIG.bit.PER = 0;
WDT->EWCTRL.bit.EWOFFSET = 0;
WDT->CTRLA.bit.ENABLE = 1;
while (WDT->SYNCBUSY.bit.ENABLE) {}
while (!WDT->CTRLA.bit.ENABLE) {}
while (1) {} //Wait on timeout
}

View File

@@ -41,8 +41,8 @@ void m15_print(uint32_t x)
//Display unsigned 32-bit number through debug led
//Read as follows: 1230 = [*] [* *] [* * *] [**] (note zero is fast double flash)
#define DLED_ONTIME 600000
#define DLED_PAUSE 1000000
#define DLED_ONTIME 1000000
#define DLED_PAUSE 1500000
volatile uint32_t w;
void dled_print(uint32_t x, uint8_t long_pause)
{

View File

@@ -225,6 +225,8 @@ int main(void)
{
if (usb_state == USB_STATE_POWERDOWN)
{
uint32_t timer_led = timer_read32();
led_on;
if (led_enabled)
{
@@ -233,7 +235,10 @@ int main(void)
I2C3733_Control_Set(0);
}
}
while (usb_state == USB_STATE_POWERDOWN) {}
while (usb_state == USB_STATE_POWERDOWN)
{
if (timer_read32() - timer_led > 1000) led_off; //Good to indicate went to sleep, but only for a second
}
if (led_enabled)
{
for (drvid=0;drvid<ISSI3733_DRIVER_COUNT;drvid++)

View File

@@ -142,10 +142,15 @@ int main(void) {
/* Wait until the USB or serial link is active */
while (true) {
#if defined(WAIT_FOR_USB) || defined(SERIAL_LINK_ENABLE)
if(USB_DRIVER.state == USB_ACTIVE) {
driver = &chibios_driver;
break;
}
#else
driver = &chibios_driver;
break;
#endif
#ifdef SERIAL_LINK_ENABLE
if(is_serial_link_connected()) {
driver = get_serial_link_driver();
@@ -178,6 +183,7 @@ int main(void) {
/* Main loop */
while(true) {
#if !defined(NO_USB_STARTUP_CHECK)
if(USB_DRIVER.state == USB_SUSPENDED) {
print("[s]");
#ifdef VISUALIZER_ENABLE
@@ -205,6 +211,7 @@ int main(void) {
visualizer_resume();
#endif
}
#endif
keyboard_task();
#ifdef CONSOLE_ENABLE

View File

@@ -1,5 +1,5 @@
#!/bin/sh
if grep ID /etc/os-release | grep -q rhel; then
if grep ID /etc/os-release | grep -qE "rhel|fedora"; then
# RPM based OS
sudo dnf install gcc unzip wget zip dfu-util dfu-programmer avr-gcc \
avr-libc binutils-avr32-linux-gnu arm-none-eabi-gcc-cs \
@@ -9,7 +9,7 @@ elif grep ID /etc/os-release | grep -q debian; then
sudo apt-get install gcc unzip wget zip gcc-avr binutils-avr avr-libc \
dfu-programmer dfu-util gcc-arm-none-eabi binutils-arm-none-eabi \
libnewlib-arm-none-eabi
elif grep ID /etc/os-release | grep -q arch; then
elif grep ID /etc/os-release | grep -q 'arch\|manjaro'; then
sudo pacman -S gcc unzip wget zip avr-gcc avr-binutils avr-libc \
dfu-util arm-none-eabi-gcc arm-none-eabi-binutils \
arm-none-eabi-newlib