Compare commits

...

785 Commits

Author SHA1 Message Date
Jordan Orelli c10264ef79 media next/prev track buttons 6 years ago
Jordan Orelli 8fd107f135 audio control keys 6 years ago
Jordan Orelli d9b5a46610 make these macros more pretty 6 years ago
Jordan Orelli 7a880ed8f0 customize the layout macros
the original macros have every possible switch position for the board,
but there are a handful of switch positions that I'm not using. It's not
actually possible to use them all at once, since some of them would
cause keys to collide. I removed the uneeded positions to fit my layout.
6 years ago
Jordan Orelli 412367253f clean up some dead code 6 years ago
Jordan Orelli 6dd1e90943 remove mouse support from the firmware
wasn't being used
6 years ago
Jordan Orelli 2dad7e3f90 fn+f5 toggles nkey rollover
I don't know why, but this board shipped with nkey rollover not working.
By adding a bootmagic key to enable nkey rollover, we can get the board
to actually utilize nkey rollover. Prior to that, we were only seeing a
rollover of 6 keys.
6 years ago
Jordan Orelli 5f01a03c14 alt/gui swapping is now fn+f1-f4
- fn+f1: swap alt and gui on both sides
- fn+f2: swap alt and gui on the left side
- fn+f3: swap alt and gui on the right side
- fn+f4: undo swaps, returning keys to their defaults

in this setup, the default key layout is a windows-style key layout, but
the keyboard can be put into a mac-style key layout by pressing fn+f1.
the keyboard can be returned to its windows-style key layout by pressing
fn+f4.
6 years ago
Jordan Orelli b9edd005e6 define a delete key, add a function key 6 years ago
Jordan Orelli fb2d6ab442 remove dead code
also creates a new key sequence: fn+esc swaps the left alt and left gui
keys to toggle the keyboard between windows and mac mode
6 years ago
Jordan Orelli 62c63908c7 hhkb-style keys on the default layer
- caps lock key is now CTRL
- tilde key is now ESC (yes there are two esc keys on this layout)
- \ key is now backspace
- set up the 1u \ and ` keys above the backspace like the hhkb
6 years ago
Andy 19aa2c34e8 Add dz60 iso layout with vim-style arrows (#2837) 6 years ago
Drashna Jaelre 6f37bd6678 Fix Clicky Down code 6 years ago
krasmaralde 3d6119856a Addkeymap/tada fakb (#2830)
* edited keymap and fitted for tada68

* edited rules to make mouse work

* filled config.h to make mouse cursor move more smooth

* added descriptive readme
6 years ago
Pawnerd 5dc60c06a9 Add knops mini info json and implemented latest QMK standards (#2832)
* added info.json to knops mini keypad.

* updated the keyboard to follow the latest qmk standards.
6 years ago
bspsbee 01a85b780c Add RGB keymap to UT47 (#2826)
* Create readme.md

* RGB keymap

* Update matrix.c

Remove serial when not used.
6 years ago
Eric 4afd970dc4 QMK Configurator updates to Tada68 (#2825)
* Added Tada68 ISO Config

* Fixed missing up-arrow on Tada68 info.json
6 years ago
Evan c17d15a305 Add keymap diagram (#2819)
* Add personal Tada68 keymaps

* remove uneccessary tada68 folder

* recommit with temp name

* remove bad folder name

* fix bullet list format

* rename to fezzant

* remove unnecessary config.h file

* Add info.json

add QMK Configurator .json file

* Delete helix_rev_2.json

* add diagram to UT47 keymap file

* add remaining keymap diagrams for ut47 keymap
6 years ago
noroadsleft 625a243be8 QMK Configurator updates for Mechmini v2 (#2820)
* Mechmini 2 updates for QMK Configurator

* Update info.json
6 years ago
MechMerlin 0d98822144 QMK Configurator Support (#2821)
- Change all KEYMAP to LAYOUT
- Add info.json
- Add QMK_KEYBOARD_H
6 years ago
Eric 102433d8bc QMK Configurator Support for HHKB and Staryu (#2823)
* added hhkb eric

* dz60 and hhkb

* editted eric hhkb and dz60

* Added HHKB Config

* Removed HHKB Config

* Added HHKB Config

* Changed the legends on HHKB info.json

* Added Tada68 ISO Config and Staryu

* Removed Tada68 ISO Config
6 years ago
Drashna Jaelre 376a384b23
Fix UT47 matrix (#2824)
* Fix UT47 matrix

* Use both spots in the matrix for the space bar
6 years ago
Salt-Peanuts 34ce1ed016 Updated tri-layer block in keymap file. (#2827)
* Updated info and fixed minor errors

* Updated folder name; overdue updates to keymap and readme files

Updated folder name; overdue updates to keymap and readme files

* Updated tri-layer feature

* Revert "Updated tri-layer feature"

This reverts commit 59b8b85761740e24f671e10fceea869f06a33ade.

* Updated tri-layer on keymap

* Fixed typos
6 years ago
Yan-Fa Li 17223166ce Add missing 7U and 4U layouts to 2x1800 (#2829)
This prevents the layouts from loading in configurator
6 years ago
MechMerlin 33671e5cd1 New Numpad Support: naKey from ckeys.org (#2828)
* Add naKey on behalf of ckeys

* Update James's code to more modern QMK standards

* Add info.json for QMK Configurator support

* Fix that build breakage

* Rename naKey.c to nakey.c

* Rename naKey.h to nakey.h
6 years ago
Erin Call 050c21d35f Bring dactyl/matrix.c in line with quantum/matrix.c (#2613)
* Use the new debounce algorithm in dactyl/matrix.c [#2065]

This incorporates the fixed/optimized debounce code added to
quantum/matrix.c in:

* 508eddf8ba
* 4c6960835c
* 32f88c0717
* f403028974
* a06115df19

* Fix the row/column swap in dactyl [#2065]

With a column-driven keyboard, reading from the mcp23081 returns a
column-state, which takes some extra work to translate into the
row-state used in the actual matrix. The ergodox_ez code sidestepped
that problem by calling rows "columns" and columns "rows." With this
change, the dactyl now calls rows "rows" and columns "columns."

* Cleanup: variable names, documentation [#2065]

* Support MATRIX_MASKED in dactyl/matrix.c [#2065]

* Only unselect one col in unselect_col [#2065]

Bonus: saves one i2c transaction per matrix_scan!

* Implement COL2ROW in dactyl/matrix.c [#2065]

* Fix a typo in dactyl/matrix.c

This entirely doesn't matter. The PORT values are set during
init_keyboard and never change. They're repeatedly set to the same
thing. These PORT lines shouldn't even exist, but since they do, they
should at least look right.

* Implement COL_PINS/ROW_PINS for dactyl [#2065]

* Rename "mcp23018" to "expander" [#2065]

I honestly don't know whether/how well this code works with other I/O
expanders, but at least in theory, it should be generic enough to work
with others. Given that, the variable names shouldn't refer to a
specific model of expander.

* Remove matrix_power_up from dactyl/matrix.c [#2065]

It's commented out in quantum/matrix.c, and the dactyl has no power
up/down behavior beyond being unplugged (which goes to matrix_init), so
there's no sense keeping it around.

* Only initialize expander_input_mask once [#2065]

...and rename input_mask to expander_input_mask, since now that it isn't
scoped to init_expander it isn't clear that it's only for the expander.
6 years ago
MechMerlin 642bf00baf FC660C Configurator Support (#2817)
* Change KEYMAP to LAYOUT

* Add info.json for configurator support
6 years ago
Nick Choi 510510e9db avocado toast change (#2816) 6 years ago
MechMerlin 6b45e8aec1 QMK Configurator Support MF68 (#2815)
* Add QMK Configurator support for MF68

* Add QMK Configurator support for MF68 BLE

* change to QMK_KEYBOARD_H in keymaps
6 years ago
MechMerlin 8d65d69b8d More QMK Configurator Support for Pearl (#2814)
* Rename LAYOUT to LAYOUT_all
Add additional layouts for the pearl with all splits
and the pearl with splits but a 6.25u spacebar.

* add new layouts to info.json
6 years ago
Yan-Fa Li 535a4d55ae Keymap Fixes for 7U layout, RGB and Audio support (#2779)
- confused KC_COMM, KC_SLSH, KC_DOT order
 - KC_INS -> KC_DEL
 - Document audio on C4 and B7, set default RGB to pin C6
6 years ago
Martin Sandiford 66e40529aa Change handling of adjust layer to make it more LT(...) friendly. (#1625)
* Change handling of adjust layer to make it more LT(...) friendly.

* Update based on feedback from drashna.

* Change handling of adjust layer to make it more LT(...) friendly.  This reworks handling to make it a little more friendly to include in keymaps.
6 years ago
James 80ccbc7b54 QMK Configurator update for the Pearl 40% (#2810)
* QMK Configurator updates for the Pearl 40%

Attempt to get the physical layout as displayed in the Configurator more true-to-life.

* Bugfixes per mechmerlin

"By changing KEYMAP to LAYOUT in the .h file, all the keymaps who rely on KEYMAP are now broken. You need to go into the keymap directory and fix all the keymaps affected by this change. Should just be an issue of renaming KEYMAP to LAYOUT."

* Merge pull request #2 from noroadsleft/noroadsleft-patch-20180425

Bugfixes per mechmerlin

* keymap.c updates for Pearl

-#include "pearl.h"
+#QMK_KEYBOARD_H
6 years ago
David Wen Riccardi-Zhu 644efe48bf Update piemod keymap (#2786)
Add RGB control, fix keymap to work with latest QMK.

Squashed commit of the following:

commit 3c5d95e4809d446fe5304aab9274d527182835e6
Author: dwrz <dwrz@dwrz.net>
Date:   Sat Apr 21 18:26:58 2018 +0000

    Make rules.mk for Let's Split piemod

commit 0cc5fc135220f0eb48509d2b027e4cad033d74a5
Author: dwrz <dwrz@dwrz.net>
Date:   Sat Apr 21 18:26:25 2018 +0000

    Add RGB control keys to function layer

commit d1b6bfa5f34123658534f99c97471b779b971ffb
Author: dwrz <dwrz@dwrz.net>
Date:   Sat Apr 21 18:26:03 2018 +0000

    Refactor MACROS to COMBOS

    MACROS was conflicting with existing code.

commit ce2f47b13fb3bfab9d63292ddba466879d300051
Author: dwrz <dwrz@dwrz.net>
Date:   Sat Apr 21 18:25:26 2018 +0000

    Add typing options to config.h

commit cb0aa62b81a17aaaee1f9843138495b9ca14b6d4
Author: dwrz <dwrz@dwrz.net>
Date:   Sat Apr 21 18:25:10 2018 +0000

    Add RGB options to config.h
6 years ago
muffinlynx 10d287d1aa ScrabblePad updates (#2809)
* Update config.h

Matrix pinout updated to current revision.

* Add updated matrix, define RGB pin

Matrix updated to current pinout, pin for WS2812 defined.
6 years ago
Danny eb89a372ec Add BFO-9000 keyboard (#2807) 6 years ago
MechMerlin 1c6b9323b2 Fix QMK Configurator bug with rendering the Eagle layout (#2806) 6 years ago
Carlos 4ad37331d3 Fix missed key assignment (#2803) 6 years ago
yiancar 4674664c4a Cu75 iso fix (#2801)
* Added Modular keyboards L,R and NUM

Created code modules for the 3 modules of the modular keyboard.
Original idea by MechboardsUK. Uses i2c implementation similar to lets
split

* Remove modular from master

This is to fix incorrect branching

* CU75 keymap fix

Incorrect keymap now fixed
6 years ago
Carlos 32446eeeb6 UT47 layout (#2791)
* Add new project files for UT47

* Copy over keymap and related files

* Add LED_controls.ino

* Add README instructions

* Attempt sending press byte data

* Disable mousekeys

* Enable sending serial data to LED controller

* Update LED mode names

* Remove extra file

* Add LED enable flag

* Update READMEs with more info

* Credit original author

* Update copyrights

* Update docs

* Changed based on review

* Move layout screenshot to Imgur

* Append to src

* Enable mousekeys to fix bad keycodes

* Additional changes based on feedback

* Fix fn layer keys
6 years ago
nariox 1feb42a108 DZ60: Add Caps Lock LED for default keymap (#2800)
Commit b546da0 added better init handling, but removed Caps Lock LED handling. This re-adds it (in the right place).
6 years ago
Kurth O'Connor 7d08e48c50 Syntax update (#2660)
* initial commit

* init qmk keymap

* update docs

* update documentation

consolidate readme files; update `make` instructions
revise ascii keymap representation

* update documentation

* edit and update `make` syntax

- `make` syntax update
- fix typo
- add link to teensy video (already linked from online configurator)

* permissions restored

* remove superfluous files from branch

* reset idiosyncratic execute permissions

* reset idiosyncratic execute permission
6 years ago
MakotoKurauchi d1481172bc Helix oled rgb compile sw (#2606)
* Helix keyboard OLED, RGBLIGHT enable/disable control integrate into rules.mk

rules.mk: add 4 Variables for compile control.

   # Helix keyboard customize
   # you can edit follows 4 Variables
   #  jp: 以下の4つの変数を必要に応じて編集します。
   OLED_ENABLE = no            # OLED_ENABLE
   LED_BACK_ENABLE = no        # LED backlight (Enable WS2812 RGB underlight.)
   LED_UNDERGLOW_ENABLE = no   # LED underglow (Enable WS2812 RGB underlight.)
   LED_ANIMATIONS = yes        # LED animations

config.h: auto set RGBLED_NUM by HELIX_ROWS and rules.mk's define

* HELIX_ROWS define move from config.h to rules.mk

* add readme.md

* rename readme.md to readme_jp.md

* add readme.md and modify readme_jp.md
6 years ago
Jack Humbert f440bbbc11 Update readme.md (#2687) 6 years ago
Eric eef75b82bd Edited keymaps for eric/dz60 (#2793)
* added hhkb eric

* dz60 and hhkb

* editted eric hhkb and dz60
6 years ago
Daniel H Klein 6beb9d3ac2 Changes to danielhklein nyquist config (#2783)
* nyquist

* danielhklein nyquist setup

* shift left controls

* remove readme

* cleanup before pr

* ready for pr

* updated bootmagic, arrows, and special chars

* allow gui on arrows

* replace arrows with right modifiers

* documentation re-added

* updated personal repo

* fixes to layers
6 years ago
David Rambo 2286cedb70 Update personal colemak Iris layout and deleted redundant folders (#2794)
* DRambo Planck keymap in Colemak

* DRambo Planck keymap in Colemak

* Satan GH60 keymap for Bri

QWERTY layout with Navigation layer toggled with "Caps Lock" key.

* xd75 keymap in Colemak for Mac and Win

* DRambo Planck keymap in Colemak

* Satan GH60 keymap for Bri

QWERTY layout with Navigation layer toggled with "Caps Lock" key.

* xd75 keymap in Colemak for Mac and Win

* Added Iris Colemak layout for Mac, Windows, and Gaming.

* changed comment text

* DRambo Planck keymap in Colemak

* Satan GH60 keymap for Bri

QWERTY layout with Navigation layer toggled with "Caps Lock" key.

* xd75 keymap in Colemak for Mac and Win

* Added Iris Colemak layout for Mac, Windows, and Gaming.

* changed comment text

* Added Iris keymap from DavidRambo

* Added planck keymap from DavidRambo

* Added xd75 keymap from DavidRambo

* Added readme

* Deleted redundant repos in Iris, Planck, and XD75 keymaps.

* Tweaked XD75 keymap

* DRambo Planck keymap in Colemak

* Tweaked XD75 keymap

* Merge branch 'master' of https://github.com/DavidRambo/qmk_firmware

Removed redundant repos with "Rambo" title.

* changed iris nav layers

* changed nav layers for xd75

* Updated Iris, tweaked nav on xd75
6 years ago
MechMerlin a0a4c9102c Add Generic Keymap for my boards (#2795)
* add mechmerlin 60 ansi layout

* put meaningful #defines

* missed the backslash

* add merlin split layout

* rename to have a -ansi

* Add appropriate readme files

* rename KEYMAP to LAYOUT

* support for default layout

* support for the community keymaps

* make sure I don't break the configurator

* Don't break the configurator Merlin
6 years ago
MechMerlin fda23af281 Support for new keyboard: Meme (#2797)
* initial commit for meme keyboard

* Fix that row by column

* Fix those dimensions

* work in progress commit

* got that switch matrix to work

* add all supported layouts

* add info.json for QMK configurator support

* let my name be known
6 years ago
Luciano Malavasi 70101cf611 Formatting changes to Alpha readme.md (#2781)
* alpha with firmware added to list of keyboards, ready to push

* revised according to drashna's fixes

* keymap -> layout?

* fixed macro and improved layout issuesOC

* Update rules.mk

* Update alpha.h

* Update and rename keyboards/alpha/layouts/default/28_alpha/keymap.c to keyboards/alpha/keymaps/default/keymap.c

* alpha/readme.md added according to qmk templateOC

* resolved a careless merge conflict

* bugfix

* Fixed /keyboards/alpha/readme.md formatting issues
7 years ago
Shinichi Ohki fb5115f6cd Fix command line options prefix. (#2790) 7 years ago
Joe Wasson 7801356bd4 Add layouts to 1up60rgb. (#2789)
* Add layouts to 1up60rgb.

* Fix build break in header file for 1up60rgb.
7 years ago
MechMerlin 5d5b161d80 ALF X2 QMK Configurator Support (#2788)
* Add microswitch information for visiblity in QMK Configurator

* Add info.json with layouts for ALF X2

* Add new LAYOUTs

* remove that extra comma
7 years ago
Drashna Jaelre 7cb3c0e466 Add pretty layout to all ergodox clones (#2686)
* Add pretty layout to all ergodox clones

* Info.json cleanup for EZ

* Add info.json for ergodone

* info.json cleanup
7 years ago
Evan 3c224bffc8 Add personal Tada68 Keymap (#2633)
* Add personal Tada68 keymaps

* remove uneccessary tada68 folder

* recommit with temp name

* remove bad folder name

* fix bullet list format

* rename to fezzant

* remove unnecessary config.h file
7 years ago
Joe Wasson 5ca9aecfb4 Talljoe's layout with common keymap. (#2764)
* Add userspace to talljoe layout.

* Move more authority to userspace and create Bananasplit layout.

* Move more things into userspace.

* Common Core example

* More work on common layout.

* Num layer.

* talljoe-ansi layout

* Updates for Zeal60

* Add Zeal60 to 60_ansi_split_bs_rshift

* Swap Escape and Grave

* Num-layer tweaks

* More tweaks.

* Add 1up60rgb to world of layouts.

* Rename ansi_split_bs_rshift layout to hhkb.

* Control RGB Backlight.

* change capslock led

* Remove obsolete line from rules.mk.

* Add user-friendly userspace override.

* Fix enter for 1uprgb60

* Revert "Rename ansi_split_bs_rshift layout to hhkb."

This reverts commit 53133719db25c7cb6a199108bbf5d980481a45f4.
7 years ago
Drashna Jaelre 33fdd1d255 Fix Audio Clicky sub-feature (#2784)
* Fix Audio Clicky feature

* Add to features
7 years ago
Mike Kozlowski d1c3419d2a Rework layer function docs (#2656)
* Rework layer function docs

* Update per PR feedback
7 years ago
fixed 9a7347e357 Adds config for ALF X2 60% keyboard (#2765)
* Adds initial keyboard config and layouts for ALF X2 60%

* Cleans up empty if/else blocks

* Renames KEYMAP to LAYOUT across the alf_x2 config files.

* Replaces include in alf_x2 keymaps with QMK_KEYBOARD_H macro
7 years ago
bjacques e36d6bbbe3 Update feature_tap_dance.md (#2643) 7 years ago
MechMerlin 14b2a35571 Use QMK_KEYBOARD_H instead of the mykeyboard.h (#2780) 7 years ago
Drashna Jaelre 1bb77c0875
Update to drashna keymaps and userspace (#2756)
* Re-add NO_SECRETS option

* Add Thumb Clusters defines for default layout

* Minor tweaks

* More Minor tweaks

* Revert Orthodox layers and move function keys around

* Fix keymap so it will compile under the Infinity

Since I haven't added 'pretty' layouts to it yet

* Cleanup of userspace

* Cleanup keymaps

* OMG fix Workman

* Move mods layer key around

* Reduce debounce in Ergodox EZ

* Fix Infinity layers

* Add list of pins used by Ergdox EZ for easy reference

* Revert "Reduce debounce in Ergodox EZ"

This reverts commit 8a3db2673b419ef8032c40a6d29156cef632f9cd.

* Add Clicky toggle to Orthodox

* Fix Audio Clicky keycode

* Enable Faux Clicky by default

* Add Unicode stuff
7 years ago
Drashna Jaelre 4e4101efdf
Fix Merge issue that reverted LS default keymap to KEYMAP (#2778) 7 years ago
Fayek Helmi 46d12d90df changed the ALTFN layer key position and Readme file 7 years ago
Danny c604cd6fd7 Add Nyquist Rev. 2 (#2414) 7 years ago
Luciano Malavasi 2a63e21279 Firmware for Alpha (28-key keyboard) (#2755)
* alpha with firmware added to list of keyboards, ready to push

* revised according to drashna's fixes

* keymap -> layout?

* fixed macro and improved layout issuesOC

* Update rules.mk

* Update alpha.h

* Update and rename keyboards/alpha/layouts/default/28_alpha/keymap.c to keyboards/alpha/keymaps/default/keymap.c

* alpha/readme.md added according to qmk templateOC

* resolved a careless merge conflict

* bugfix
7 years ago
Christian Hartlage 503335be25 Added GH60 Satan ISO layout with split right shift and split backspace (#2773)
* added an iso layout that supports split backspace and split rshift

* added a keymap which uses the iso layout with split backspace and split rshift

* added a #define LAYOUT_ for the KEYMAP_

* fixed missing newline
7 years ago
Kenneth Aloysius 0912c42f04 Add Staryu macropad support (#2768)
* Add M6-A keymap

* Update XD60 keymap

* Update XD60 keymap readme

* Update JJ40 and Let's Split keymaps

* Add readme for M6-A

* Fix typo, update JJ40 README

* Update jj40 readme

* Cleanup jj40 keymap

* Revert Let's Split QWERTY layer to default before #2010

* Update numpad layers

* Fix: Let's Split keymap getting stuck mods due to having keycodes assigned on the Raise layer

* Keep ASCII art consistent with keymap

* Staryu: initial port

* Add personal keymap

* Added and updated READMEs

* Fix: default keymap for staryu

* Rudimentary backlight support.

* Enabled mousekeys for default keymap

* use QMK_KEYBOARD_H and LAYOUT

* Update readme.md for NIU mini: flash using avrdude

* Fix missing linebreaks for Staryu README

* Update readme.md
7 years ago
Thanh Hai Mai 3ea8bcb8ae Add Carpalx keymap for Kinesis (#2771) 7 years ago
Eric 0ce2cc8915 Added dz60/eric and hhkb/eric (#2772)
* added hhkb eric

* dz60 and hhkb
7 years ago
Salt-Peanuts ded9390944 Updated folder name; overdue updates to keymap and readme files (#2770)
* Updated info and fixed minor errors

* Updated folder name; overdue updates to keymap and readme files

Updated folder name; overdue updates to keymap and readme files
7 years ago
MechMerlin 3cab04dfa3 QMK Configurator support for alps64 pcb (#2774)
* Change KEYMAP to LAYOUT

* add layouts that match the layouts hasu has defined for alps64

* add layouts in info.json for aek, standard, and infinity

* Add LAYOUT_iso and LAYOUT_all along with respective info.json LAYOUTs
7 years ago
That-Canadian 1de6458921 Launchpad (#2767)
* Line ending stuff again

* Added base launchpad files and a default layout

* Updated KEYMAP to LAYOUT, also editing default keymap a bit and added a readme
7 years ago
Salt-Peanuts 3bb647910a Updated info and fixed minor errors (#2769) 7 years ago
Josh Asplund 5ec3bd9e40 Adds default IC keymap (#2677) 7 years ago
Kenneth Aloysius d3c6da7aff Updated personal keymaps, fixed Let's Split default keymap, updated JJ40 README (#2704)
* Add M6-A keymap

* Update XD60 keymap

* Update XD60 keymap readme

* Update JJ40 and Let's Split keymaps

* Add readme for M6-A

* Fix typo, update JJ40 README

* Update jj40 readme

* Cleanup jj40 keymap

* Revert Let's Split QWERTY layer to default before #2010

* Update numpad layers

* Fix: Let's Split keymap getting stuck mods due to having keycodes assigned on the Raise layer

* Keep ASCII art consistent with keymap
7 years ago
Cole Markham 47f55f417b Implement magic 8-ball mode for big series switch (#2763) 7 years ago
MechMerlin eaa0b24335 ScrabblePad Support (#2760)
* Initial commit for donutcat's 15x15 monstrosity

* modify readmes to be more descriptive

* Add info.json to support QMK Configurator

* Update copyright and change REPLACE_WITH_YOUR_NAME to MechMerlin

* update naming convention for ScrabblePad

* remove .vscode directory as per Jack's comments
7 years ago
Christian Richter 75360ebdae Add gh60 chaser Layout (#2757) 7 years ago
Harry Mills 8ec2269519 Add magic backspace to my layout (#2758)
* Add Haegin's keymap

* Potential improvements to the keyboard

* Add haegin minidox layout

* Add Haegin's keyboard to ergodox layouts

* Update Haegin's minidox keymap

* Add home, end, and page up and down

* Magic Backspace

Backspace still acts as control when you hold it down, but if you tap it
twice and hold it's a held backspace. Tapping it more than twice it
continues to act as backspace, but it deletes more characters with each
tap with the quantity deleted based on the fibonacci sequence.

* Switch to deleting words after 4 taps

When hitting backspace, after 4 taps this switches to deleting by word
because if you're hitting backspace that frantically you must need to
delete a lot of stuff. Holding backspace after 4 taps will delete words
in the same way that holding alt+backspace deletes words on a normal
keyboard.
7 years ago
Joe Wasson 5226e4c79b Correct documentation for `PREVENT_STUCK_MODIFIERS` 7 years ago
blindassassin111 7dda7158fb added omnikey_blackheart keyboard support (#2688)
* added omnikey_blackheart keyboard support

* fixing omnikey_blackheart layout

* fixing omnikey_blackheart NKRO
7 years ago
Drashna Jaelre 8b0b17a369 Add Faux Clicking as subset of Audio feature (#2748)
* Add Faux Clicky to main Audio feature

* Make clicky settings user configurable

* Add additional documentation

* Don't play when music mode is enabled (hopefully)
7 years ago
Cole Markham 23b45710ac Add support for Big Series 1-key PCB by Woodkeys.click 7 years ago
Cole Markham b4bdebab9a Meira updates for bluetooth and audio (#2731)
* Add audio output

* Update Miera to fix bluetooth issues, bootloader definition.

* Added keymap with audio example

* Cleanup Meira audio code
7 years ago
adiron 3d3c093173 Added bending to MIDI (#2740)
This is done via MI_BENDD and MI_BENDU. At the moment the value is
hardcoded and cannot be adjusted (future commit?) and is the max for the
`midi_send_pitchbend` function (up or down).

`MI_BENDD` and `MI_BENDU` both require `#define MIDI_ADVANCED`

MIDI pitch bend was already implemented in `protocol/midi.c`, I merely
added the keycodes to trigger them. :) (thanks to Jack, two years ago
in commit fb4fe52c apparently)
7 years ago
internetirl a7fca47686 Link to Atmel's flip is broken. (#2752)
The link to Atmel's flip is broken. It re-directs to http://www.microchip.com/. Please update!

I think this is the correct link. Please verify.

http://www.microchip.com/developmenttools/productdetails.aspx?partno=flip
7 years ago
Ethan Madden 9ab786d1d8 Added amj40 keymap (#2754)
fixed shift area

keymap updates to try to make this thing usable

documentation tweaks

fix readme mismatch

clean up and finish docs
7 years ago
zwnk ec9058f227 impstyle keymap added (#2753) 7 years ago
Maarten Dekkers 5aada76f12 Update maartenwut's keymaps (tada68, atom47) and add GH60 layout (#2751) 7 years ago
fredizzimo e9d32b60b7 Add a custom USB driver for ARM (#2750)
* Copy Chibios serial_usb_driver into the chibios/protocol

It's renamed to usb_driver to avoid name conflicts

* Make the usb driver compile

* Disable ChibiOS serial usb driver for all keyboards

* Change usb_main to use QMKUSBDriver

* Initialize the usb driver buffers

* Add support for fixed size queues

* Fix USB driver initialization

* Don't transfer an empty packet for fixed size streams
7 years ago
Takeshi ISHII e2fb3079c7 update Helix keymap 'five_rows' (#2635)
* add 'HELIX=' option for build

* add IOS_DEVICE_ENABLE for iPad

* shrink size to helix five_rows keymap.c

* shrink size. _ADJUST number change

* add KEYPAD layer

* modify keypad leyer

* display RGB mode on slave side OLED

* fix Colemak, Dvorak center DEL to BS

* change LEFT BS to LEFT SP and add AUX layer for try old map

* update update_base_layer()

* add right keypad and keypad func layer

* use MO() macro insted of LOWER,RAISE,ADJUST custom key-code

* remove LOWER,RAISE,ADJUST custom key-code
* use MO(_LOWER|_RAISE|_ADJUST)
* relayout ADJUST layer

* modify Function Layer. PGUP,PGDN swap HOME,END

* add Keypad aux layer for '00' send

* update README.md, README_jp.md

* fix README.md

* fix README.md, README_jp.md
7 years ago
Biacco42 13cdfb465d Add Illustrator keymap layout for Ergo42 (#2658) 7 years ago
Spencer 1b711453ca Updated Levinson and Fourier keymaps (#2685)
* 	new file:   keyboards/dilly/keymaps/delmo/config.h
	new file:   keyboards/dilly/keymaps/delmo/keymap.c
	new file:   keyboards/dilly/keymaps/delmo/rules.mk
	new file:   keyboards/fourier/config.h
	new file:   keyboards/fourier/fourier.c
	new file:   keyboards/fourier/fourier.h
	new file:   keyboards/fourier/i2c.c
	new file:   keyboards/fourier/i2c.h
	new file:   keyboards/fourier/keymaps/default/config.h
	new file:   keyboards/fourier/keymaps/default/keymap.c
	new file:   keyboards/fourier/keymaps/default/rules.mk
	new file:   keyboards/fourier/keymaps/valgrahf/config.h
	new file:   keyboards/fourier/keymaps/valgrahf/keymap.c
	new file:   keyboards/fourier/keymaps/valgrahf/rules.mk
	new file:   keyboards/fourier/matrix.c
	new file:   keyboards/fourier/readme.md
	new file:   keyboards/fourier/rev1/config.h
	new file:   keyboards/fourier/rev1/rev1.c
	new file:   keyboards/fourier/rev1/rev1.h
	new file:   keyboards/fourier/rev1/rules.mk
	new file:   keyboards/fourier/rules.mk
	new file:   keyboards/fourier/serial.c
	new file:   keyboards/fourier/serial.h
	new file:   keyboards/fourier/split_util.c
	new file:   keyboards/fourier/split_util.h

* 	new file:   keyboards/levinson/keymaps/valgrahf/config.h
	new file:   keyboards/levinson/keymaps/valgrahf/keymap.c
	new file:   keyboards/levinson/keymaps/valgrahf/rules.mk

* 	modified:   keyboards/levinson/keymaps/valgrahf/keymap.c

* 	deleted:    keyboards/dilly/keymaps/delmo/config.h
	deleted:    keyboards/dilly/keymaps/delmo/keymap.c
	deleted:    keyboards/dilly/keymaps/delmo/rules.mk

* 	modified:   keyboards/fourier/keymaps/valgrahf/keymap.c

* 	deleted:    keyboards/fourier/config.h
	deleted:    keyboards/fourier/fourier.c
	deleted:    keyboards/fourier/fourier.h
	deleted:    keyboards/fourier/i2c.c
	deleted:    keyboards/fourier/i2c.h
	deleted:    keyboards/fourier/keymaps/default/config.h
	deleted:    keyboards/fourier/keymaps/default/keymap.c
	deleted:    keyboards/fourier/keymaps/default/rules.mk
	deleted:    keyboards/fourier/keymaps/valgrahf/config.h
	deleted:    keyboards/fourier/keymaps/valgrahf/keymap.c
	deleted:    keyboards/fourier/keymaps/valgrahf/rules.mk
	deleted:    keyboards/fourier/matrix.c
	deleted:    keyboards/fourier/readme.md
	deleted:    keyboards/fourier/rev1/config.h
	deleted:    keyboards/fourier/rev1/rev1.c
	deleted:    keyboards/fourier/rev1/rev1.h
	deleted:    keyboards/fourier/rev1/rules.mk
	deleted:    keyboards/fourier/rules.mk
	deleted:    keyboards/fourier/serial.c
	deleted:    keyboards/fourier/serial.h
	deleted:    keyboards/fourier/split_util.c
	deleted:    keyboards/fourier/split_util.h

* 	deleted:    keyboards/fourier/config.h
	deleted:    keyboards/fourier/fourier.c
	deleted:    keyboards/fourier/fourier.h
	deleted:    keyboards/fourier/i2c.c
	deleted:    keyboards/fourier/i2c.h
	deleted:    keyboards/fourier/keymaps/default/config.h
	deleted:    keyboards/fourier/keymaps/default/keymap.c
	deleted:    keyboards/fourier/keymaps/default/rules.mk
	deleted:    keyboards/fourier/keymaps/valgrahf/config.h
	deleted:    keyboards/fourier/keymaps/valgrahf/keymap.c
	deleted:    keyboards/fourier/keymaps/valgrahf/rules.mk
	deleted:    keyboards/fourier/matrix.c
	deleted:    keyboards/fourier/readme.md
	deleted:    keyboards/fourier/rev1/config.h
	deleted:    keyboards/fourier/rev1/rev1.c
	deleted:    keyboards/fourier/rev1/rev1.h
	deleted:    keyboards/fourier/rev1/rules.mk
	deleted:    keyboards/fourier/rules.mk
	deleted:    keyboards/fourier/serial.c
	deleted:    keyboards/fourier/serial.h
	deleted:    keyboards/fourier/split_util.c
	deleted:    keyboards/fourier/split_util.h

	keyboards/fourier/

* 	new file:   keyboards/fourier/config.h
	new file:   keyboards/fourier/fourier.c
	new file:   keyboards/fourier/fourier.h
	new file:   keyboards/fourier/i2c.c
	new file:   keyboards/fourier/i2c.h
	new file:   keyboards/fourier/keymaps/default/config.h
	new file:   keyboards/fourier/keymaps/default/keymap.c
	new file:   keyboards/fourier/keymaps/default/rules.mk
	new file:   keyboards/fourier/keymaps/valgrahf/config.h
	new file:   keyboards/fourier/keymaps/valgrahf/keymap.c
	new file:   keyboards/fourier/keymaps/valgrahf/rules.mk
	new file:   keyboards/fourier/matrix.c
	new file:   keyboards/fourier/readme.md
	new file:   keyboards/fourier/rev1/config.h
	new file:   keyboards/fourier/rev1/rev1.c
	new file:   keyboards/fourier/rev1/rev1.h
	new file:   keyboards/fourier/rev1/rules.mk
	new file:   keyboards/fourier/rules.mk
	new file:   keyboards/fourier/serial.c
	new file:   keyboards/fourier/serial.h
	new file:   keyboards/fourier/split_util.c
	new file:   keyboards/fourier/split_util.h

* 	modified:   keyboards/fourier/keymaps/valgrahf/keymap.c

* 	modified:   keyboards/fourier/keymaps/valgrahf/keymap.c
7 years ago
youdroid 5d36118eaa Add French Layout for XD75 (#2681) 7 years ago
markhuguet b7d095fdc3 Added Factory Style LED Controls (#2678)
* This adds a keymap to the MF68 labeled factory.  It is an attempt to mimic the layout on the factory keycaps of the non-backlit board.

There are some small differences:

1) FN+WASD are an arrow cluster
2) FN+Z (Start media player) and FN+] (Start Calculator) are not mapped
3) FN+GHJKL are Backlight controls
4) An FN2 layer exists for future growth
5) The CAPS key is maped as FN2, for CAPS Lock use FN+CAPS

* Changed the CAPS key to be CAPS Lock on short press, FN2 on hold

Added LED controls to FN+Arrow Keys to better mimic factory backlit boards.
7 years ago
ajp10304 ed62c6e146 Ajp10304 (#2719)
* AJP10304 layouts for Planck and JJ40 now have mouse support. Moved macros onto Adjust layer

* .gitignore for intellij iml files.

* Updated Macros to use send string
7 years ago
David Rambo 32fd5e4f61 keymaps for Iris, Planck, Satan, and XD75 (#2747)
* DRambo Planck keymap in Colemak

* DRambo Planck keymap in Colemak

* Satan GH60 keymap for Bri

QWERTY layout with Navigation layer toggled with "Caps Lock" key.

* xd75 keymap in Colemak for Mac and Win

* DRambo Planck keymap in Colemak

* Satan GH60 keymap for Bri

QWERTY layout with Navigation layer toggled with "Caps Lock" key.

* xd75 keymap in Colemak for Mac and Win

* Added Iris Colemak layout for Mac, Windows, and Gaming.

* changed comment text

* DRambo Planck keymap in Colemak

* Satan GH60 keymap for Bri

QWERTY layout with Navigation layer toggled with "Caps Lock" key.

* xd75 keymap in Colemak for Mac and Win

* Added Iris Colemak layout for Mac, Windows, and Gaming.

* changed comment text

* Added Iris keymap from DavidRambo

* Added planck keymap from DavidRambo

* Added xd75 keymap from DavidRambo

* Added readme
7 years ago
Fayek Helmi fe8b9d0d0f adding the 256k HHKB layout to the library (#2742)
* adding the 256k HHKB layout to the library

* changed the layouts for the modifying layers and added a readme file to explain my layout
7 years ago
Oliver Ladner 412af0f4e7 New DZ60 layout (#2744)
* initial commit

* - Move layout to readme
- Finish first (0) layer

* remove cruft

* fix ASCII keymap in readme

* fix ASCII keymap in readme #2

* fix ASCII keymap in readme

* rename layers

* use 2 shift layout

* rename layers, populate additional layers

* final layout (TM)

* fix RGB saturation increase position
7 years ago
Campbell Barton d55ee204db qwerty_code_friendly: optional 80 key layout (#2745) 7 years ago
Kevin Foley cdb967f22b Fix link to command page 7 years ago
mechmerlin 28307be72f Add chiwi60 layout for the do60
Add info.json to support the layouts for QMK Configurator
Rename LAYOUT to LAYOUT_all
7 years ago
walkerstop 530dd446cb Fix incorrect port direction setting in my previous pull request for pins B5, B6, B7 (#2739)
* Added support for audio using pins C4, C5, B6, B7

* Fixed bug where port direction wasn't set correctly for B5, B6, B7 audio ports
7 years ago
Michael L. Walker 22215a0e92 Added support for audio using pins C4, C5, B6, B7 7 years ago
MechMerlin 5319667c55 Support upcoming caps_unlocked boards in QMK Configurator (#2738)
* Change KEYMAP macro to LAYOUT macro

* Add CU24 QMK Configurator Support

- Change KEYMAP macro to LAYOUT macro
- Add new LAYOUTS to support a default numpad

* QMK Configurator Support for CU75

Add LAYOUT_all to support all layouts
Add corresponding info.json
7 years ago
skullY f10a0ae547 Remove bootloader from info.jsons 7 years ago
Phil 3d3716bbf7 Beginning implementation of Pearl backlight. Levels and breathing not working yet. 7 years ago
fauxpark 6982e63a4a Tabs to spaces in usb_descriptor.h 7 years ago
Cole Markham e8082b5f9e Add support for NovelPad/NumChoc by NovelKeys and Woodkeys 7 years ago
MechMerlin 4cfd1e30fc More QMK Configurator Warning/Error Fixes (#2720)
* Add readme with brief description
Change KEYMAP to LAYOUT

* Add readme.md with brief description
Use LAYOUT macro

* add a readme.md file

* Add readme.md with brief description
Use LAYOUT macro

* Add readme.md with brief description
Use LAYOUT macro

* Fix "Warning: contra: Missing layout pp macro for ['planck_mit', 'planck_grid']",

* Use LAYOUT macro
7 years ago
Domantas Petrauskas 0c4a6bf2db Improve JJ40 Cockpit documentation (#2729)
* Add JJ40 Cockpit keymap

* Fix lower layer symbols

* Improve documentation JJ40 Cockpit
7 years ago
Kenta Suzuki 3caf0761cd jj40 Personal keymap added (#2728)
* fix: Miss commnts.

* edit: Enter position

* Add: config.h

* Edit: Double space key

* fix: Lower and Raise

* delete: Not used keys.

* edit: change position Lower and Raise

* Add: Functions
7 years ago
Matthew Treadwell 05dcb48aa9 Added personal keymap (#2727) 7 years ago
Jason Barnachea 244b1ef79b Personal keymap added (#2723)
Personal keymap added.
7 years ago
Matt DiCarlo 0545428c14 Added mattdicarlo Tada68 layout. (#2721) 7 years ago
MechMerlin 885f06c6cf Add readme for "major" keyboards to eliminate more QMK Configurator errors (#2718)
* add readme to ktype keyboard

* add readme to m10a

* add readme to mini1800

* add readme to parent directory
7 years ago
Domantas Petrauskas a33c0949e0 Add JJ40 Cockpit personal keymap (#2713)
* Add JJ40 Cockpit keymap

* Fix lower layer symbols
7 years ago
Enochen 955a6586a3 hhkb jp personal keymap (#2698) 7 years ago
Jorge Porras f32e0200ed Normacos keymap for let's split keyboard (#2691)
* Cheers let's split keymap

* fixed typo on norman layer of cheers keymap for let's split

* fixed right handed mappings for home row

* cheers keymap for let's split redefinition

* updated Cheers keymap for let's split

* cheers keymap for let's split updated with some terminal macros

* renamed cheers let's split keymap to a more appropriate normacos

* updated normacos keymap doc / removed non functional keys

* reset let's split rules to default values

* added more spotlight search macros

* normalized keymap comments

* Moved numpad on lower layer
7 years ago
MechMerlin 1f77868427 More Configurator Warning Fixes (#2716)
* mf68_ble did not have the correct .c and .h files

* Fix JC65 KEYMAP to LAYOUT

* Change KEYMAP to LAYOUT for s60_x

* Convert KEYMAP to LAYOUT for lets_split boards

* Convert KEYMAP to LAYOUT

* more fixes to keymap for iris

* convert KEYMAP to LAYOUT for levinson keyboard

* change losinggeneration's KEYMAP to LAYOUT

* convert KEYMAP to LAYOUT

* convert KEYMAP to LAYOUT for nyquist

* convert KEYMAP to LAYOUT

* convert KEYMAP to LAYOUT for viterbi

* convert KEYMAP to LAYOUT

* convert KEYMAP and its subsidiries to the LAYOUT standard

* convert KEYMAP and its subsidiries to the new LAYOUT standard
7 years ago
skullydazed 958521c359
Clean up some long-standing errors when populating the API (#2715) 7 years ago
skullydazed 3b525dcf9c
Remove obsolete info.json entries (#2712) 7 years ago
skullydazed f4a9e98383
Pull information from config.h and rules.mk (#2711)
* Pull information from config.h and rules.mk

* Readd the kbd75 maintainer
7 years ago
Seebs c0baf2a964 Improve state/chord handling and clean up namespace
Some values that can never, ever, change were held in local
variables, rather than in PROGMEM. Fixed.

Change "pressed" to a signed int so the test for < 0 makes
sense, and to avoid possible weird failure modes in the
case where a key release comes in when pressed is already
zero. (Shouldn't happen, sure, but computers are weird.)

A lot of things in process_steno had external linkage for no
particular reason. They've been marked static. Stuff still
builds.

Distinguish between currently-held keys and keys that have
been held, and expose these values through a nicely-named API
so other code could, say, check on the current set of steno
chording in order to make displays. Also in passing fix up the
"state" value having external linkage so it could clash with
other people's variable declarations.

The API also provides hooks for key processing and steno chord
events, so you can monitor those events without having to
run in matrix_scan_user and recheck the values directly. Also
document these.

There is no path through processing a key that doesn't
end with a return false, so the nested return foo() are
gone and we just return false.
7 years ago
MechMerlin 5f4c2dfd84 Fix some Configurator Warnings regarding LAYOUT vs KEYMAP (#2708)
* change diverge 3 KC_KEYMAP to LAYOUT

* Change KEYMAP to LAYOUT for handwired arrow pad

* change M10A to LAYOUT for m10-a

* Change KC_KEYMAP to LAYOUT_kc and KEYMAP to LAYOUT for mf68

* change KC_KEYMAP to LAYOUT for nano

* Refactor to LAYOUT

* refactor to LAYOUT-ansi and LAYOUT_iso for s65

* LAYOUT conversions for lfkkeyboards

* missed a few renames

* mini1800 for lfkeyobards support of LAYOUT
7 years ago
Yan-Fa Li b7dc17ef33 Small fixes to TKC1800
- adjust F-row to use 0.25 spacing
 - split left shift
 - add key_count
7 years ago
MechMerlin a859a2ee96 Fix KC60 info.json file (#2707)
* change KEYMAP to LAYOUT in all the KC60 files

* Redo the info.json file
7 years ago
Paul Ewing 0f0c2da983 Add the Speedo keyboard 7 years ago
Yan-Fa Li d78e630641 Clueboard 60 info.json
- adds
   - LAYOUT_60_ansi
   - LAYOUT_60_iso
   - KEYMAP_AEK
   - KEYMAP
   - LAYOUT_60_ansi_split_bs_rshift
7 years ago
mdnt 8478ef648f Add TKC1800 info.json
Created an info.json for the tkc1800.
7 years ago
Yan-Fa Li 4cb7907547 Add 2 missing F-Row keys 7 years ago
Yan-Fa Li 25b1d02157 Adds Phantom TKL support (#2696)
* Add an info.json to phantom keyboard

* Add layouts

 - KEYMAP_WINKEYLESS
 - KEYMAP_7BIT
 - KEYMAP_ISO
 - KEYMAP_ISO_WINKEYLESS

* Add key_counts
7 years ago
Daniel H Klein 4feaf1fd76 Add Nyquist keymap (#2692)
* nyquist

* danielhklein nyquist setup

* shift left controls

* remove readme

* cleanup before pr

* ready for pr
7 years ago
Maarten Dekkers d777a05864 Add support for rev3 of the Atom47 (#2672)
* Added support for rev3 of the Atom47

* Updated Atom47 readme's

* Fix redefine error on rev2 and add maartenwut's keymap

* Fix redefine error on LEdiodes keymap
7 years ago
mechmerlin 7bbc9ccc31 change KEYMAP to LAYOUT for all new keyboards made using this script 7 years ago
Kaleb Elwert 0d0664a214 Various tweaks for some Input:Club build processes 7 years ago
adiabatic 011039afca Zweihander: swap space and enter keys (#2665)
* zweihander-osx: Remove app keys, etc.

- add right command keys
- add F16 on ;' for Siri
- remove command-Q (too easy to hit)

* Rename zweihander-osx to zweihander-macos

zweihander-macos: / / ^ → / / ⌥; README revamp

zweihander: rename, ⌃ → ⌥, README revamp

* Zweihander: swap space, enter keys

Left thumb needs a break.
7 years ago
Nicholas 6cc9d59ee8 Enables unicode for Mitosis (#2668)
* fixed comment typo

* Fixes invalid capitalization

Uppercase yes is invalid, so make treats it as no, which is
confusing when it seems like it should have found the method
definition for unicode.

* Own keymap, comma in mitosis

Own keymap is qwerty, workman, numbers, punctuation, function/mouse
layers, gaming, unicode, numberpad.
7 years ago
Florian f281f7dc3a i got a new toy (#2673)
Personal keymap for Waples
7 years ago
markhuguet ba2cab1a89 This adds a keymap to the MF68 labeled factory. It is an attempt to mimic the layout on the factory keycaps of the non-backlit board. (#2674)
There are some small differences:

1) FN+WASD are an arrow cluster
2) FN+Z (Start media player) and FN+] (Start Calculator) are not mapped
3) FN+GHJKL are Backlight controls
4) An FN2 layer exists for future growth
5) The CAPS key is maped as FN2, for CAPS Lock use FN+CAPS
7 years ago
Kaleb Elwert 738588618b Update input:club boards to use the proper vendor and device 7 years ago
QMK Bot 67268db576 convert to unix line-endings [skip ci] 7 years ago
mechmerlin c25f0e6983 Fix readme to explicitly call out that there are two different versions of this board and how to compile them 7 years ago
Kaleb Elwert f6b3c67678 Update whitefox to use the K-Type teensy workaround 7 years ago
MechMerlin 67053712f8 Refactor/eagle viper with new layouts for QMK Configurator (#2659)
* rename KEYMAP to LAYOUT_ALL

* Standard Layout Eagle Refactor

New layout LAYOUT_EAGLE
Got standard layout backspace working

* Remove split right shift support for standard layout eagle

* add back the KC_NO for split right shift

* Remove KC_NO from bottom row to support standard 60 layout

* Fix formatting issues with mechmerlin keymap

* remove extra KC_NO from split right shift in LAYOUT_EAGLE

* Preliminary checkin for new layout LAYOUT_VIPER

* Remove some of the KC_NO from the layout

* Fix formatting

* missed a KC_NO for the LAYOUT_EAGLE

* remove KC_NO from enter key of LAYOUT_VIPER

* some more formatting changes

* Default 60 with split left right shift and backspace

* add info.json layouts to match the new LAYOUTs

* change formatting of LAYOUT names

* propogate renames to info.json
7 years ago
skullydazed 0ca6b53f89
Clueboard Double 1800 support (#2655) 7 years ago
Birkir Rafn Guðjónsson 6f3cbdb5f7 Added birkir's keymap (#2653) 7 years ago
Drashna Jaelre 162a67cbc5 Add userspace config.h handling to build script (#2640)
* Add userspace 'config.h' file

* Add more robust docs

* Remove config.h code from drashna userspace

* Spelling error

* Include links to Config Options page

* Remove config.h documentation from userspace doc, as it's no longer needed
7 years ago
Mike Kozlowski cc323df9ba Fix broken Markdown (#2652)
Fix links in Keyboard Guidelines page
7 years ago
Drashna Jaelre deb5a4b6a9 Convert all Preonic keymaps to layout format (#2644)
* Convert all Preonic keymaps to layout format

* Make sure preonic layouts are using QMK_KEYBOARD_H
7 years ago
Drashna Jaelre 61a2169ff9 Update to Drashna Keymaps and Userspace (#2650)
* Change global config.h settings

* Make Shift LED brighter

* Compatibility Tweaks

* Update ASCII art and layer comments

* Add comments about MOD layer

* Change ASCII art for reset, since it was out of date

* Use Overwatch theme for Workman layer

* Fix RGB define comments

* Make sure RGB set list matches

* Stop all notes for custom Faux Click

* Switch to OSM for everything, and remove RGB Sleep

* Never use KEYMAP now

* Only enable RGB Sleep on Non-Ergodox boards

* Cleanup do to new rgblight_list.h file

* Add redirect message for RGB codes

* Update userspace documentation

* Cleanup of Userspace

Add unicode support, and cleaned up comments for ifdef statements

* Remove unneeded slashes

* Unicode handling

* Force NKRO
7 years ago
mechmerlin adae37f19f Add XD60 support to QMK Configurator
Add info.json

Change KEYMAP to LAYOUT_ALL to better reflect that this is a
LAYOUT that fits ALL the possible positions for switches.

We will need to make better LAYOUTS for the future.
7 years ago
MechMerlin 015aed50a3 AMJ96 Support (#2651)
* Initial commit: Get things compiling

* port the custom matrix code

* Update readme

* make second layer fully transparent

* populate config.h identifiers with more correct information

* Add in switch backlight support

* Enable backlight LEDs, and change pin for RGB

* port TMK version over

* remove all that TMK stuff, it didn't work lol

* Updated readme

* Fix keymap

- Change KEYMAP to LAYOUT
- Adjust formatting of table

* Edit readme to reflect NOTES

* add info.json for QMK configurator support

* Replaced placeholder with MechMerlin
7 years ago
MechMerlin c6b5ce61e8 Fix Octagon info.json issues (#2649)
Change KEYMAP to LAYOUT while I'm at it.
V1 and V2 now have their own info.jsons
7 years ago
Ryan McLean a74f866941 Just a multilayered Layout using tapdance (#2645)
* Ported JJ40 Layout to Contra

* Update readme.md
7 years ago
U-LANDSRAAD\drashna c31f7ff91b Hopefully fix Travis Auto-Incrementation
This reverts the changes in #2491, so that Travis will hopefully return to automatic incrementing.
But this includes the layout and userspace excepts, as well.
7 years ago
U-LANDSRAAD\drashna c2bec5b3f0 Properly always copy firmware
This finishes fixing #2314, which mostly copies the firmware when compiling.
However, it misses `:teensy`, `:avrdude` and most importantly, `:production`
7 years ago
Chris Peters fb34fdbbc9 Added cpeters1982 keymap folder in lets_split (#2583)
* Added cpeters1982 keymap folder in lets_split

* Deleted tap dance. need to research error

* Changed keymap to better facilitate SpaceFn

* Trying to get backlighting to work

* Added RGB backlight support

* cleared some cache files per Drashna's instructions
7 years ago
Jonathan A. Kollasch 5641b1da20 layouts/default: fill in 60_ansi keymaps 7 years ago
nachie 931a52d1ae Support for the Paladin64 PCB (#2639)
* Support for the Paladin64 PCB

* Paladin64: Added readme. Added the bootloader option to rules.mk

* Fixed the formatting

* fixed the flash command
7 years ago
U-LANDSRAAD\drashna 331288233d Add rgblist to docs 7 years ago
U-LANDSRAAD\drashna c1b46206a7 Fix commands and update my userspace (for testing) 7 years ago
U-LANDSRAAD\drashna 9cfeb4e6cf add RGB commands as global functions 7 years ago
U-LANDSRAAD\drashna bdb718af0d Fix RGB Sleep code 7 years ago
Jacob Jerrell c39780b8e1 Add Support for Software Workman (#2632)
This adds the keymap translations and sendstring definitions to support software workman.
7 years ago
Harry Mills b5e899ede7 Adding Haegin's keyboard layout for the ergodox and minidox (#2637)
* Add Haegin's keymap

* Potential improvements to the keyboard

* Add haegin minidox layout

* Add Haegin's keyboard to ergodox layouts

* Update Haegin's minidox keymap
7 years ago
Jason Janse van Rensburg 01c72e8dce changed super key to left super key (#2631) 7 years ago
Michael F. Lamb b61974b301 mitosis:datagrok: minor layout improvements (#2366)
* mitosis/datagrok: make qwerty the default layout

* mitosis/datagrok: update readme to match qwerty default

* mitosis:datagrok: remove redundant name for transparent

meh, decided i don't need an extra key to represent "key that is
transparent because it's a modifier on a layer below." it's a maintenance
burden when moving other keys around

* mitosis:datagrok: add num lock on Blue + QWERTY T

* mitosis:datagrok: tap lshift = tab

we use tab completion a lot so let's get it onto an unmodified key somehow

* mitosis:datagrok: update readme

* mitosis:datagrok: improve notes in README

* mitosis:datagrok: note numlock in README
7 years ago
Benjamin Daschel 9f5a4af09c XD60 ANSI (GH60) layout (#2624)
* configure layer 0 layout for xd60 as ANSI 60%

* update keymap with function key immediately right of spacebar;
shuffle mapping in function layer to my liking

* update readme
7 years ago
Martin Lechner 1305d8de80 [TADA68] Added mac layout with german umlaute on ansi. (#2615) 7 years ago
bjacques 55d0b1f048 Create new 'tada68/iso-uk' layout tailored for boards with the big fat iso enter key (#2612) 7 years ago
mechmerlin d3a0c7e3a6 qmk configurator support for e6v2. Let it be known that this is one of the keymaps I've seen done right 7 years ago
mechmerlin b773d94477 Add qmk configurator support for KBD75
Also changed KEYMAP to KEYMAP_ALL to be more explicit that it's
a layout supporting ALL possible layouts.
7 years ago
dankm 19a1fbaca2 Better non-Linux support (#2524)
* grep -> $(GREP)

Some UNIXy systems (FreeBSD for example) don't use GNU grep by default.
Allow the user to specify which grep implementation to use so that
GNU grep can be specified.

* Allow using versioned avr-gcc command

Don't hardcode "avr-gcc", and allow strings such as "avr-gcc8", or
"avr-gcc-7.3.0" to match checks for "avr-gcc".
7 years ago
Jack Humbert ae7284edb8 rename api docs to internals 7 years ago
Jason Stillwell 66162b2b68 add grave to auto-shift. 7 years ago
mtei 2038a515d9 change rgblight_increase_val() and eeconfig_update_rgblight_default(), use RGBLIGHT_LIMIT_VAL insted of 255. 7 years ago
Otto Rask b922a550dc Add pearl README, add rask's Pearl layout 7 years ago
Drashna Jaelre ee1bb85542 Expand Newb Guide flashing document (#2588)
* Add header info

* Add DFU section

* Add Caterina section

* Add Halfkay section

* Fix Typos

* More typos
7 years ago
Drashna Jaelre 07b90db897 Fixes and updates to docs (#2611)
* Fix advanced keycode headers

* Add caveat for OSM over Remote Desktop

* Hopefully add better anchors to docs

* Add Action code list reference

* Formatting of RGB Underglow doc

* Add brew update issue on macOS

* Revert formatting

* Revert RGB doc formatting

* Make Config Options doc's sections linkable
7 years ago
Drashna Jaelre 0c665696d7
Update to drashna files (#2587)
* Add Colemak Mod-DH vars

* Add Norman Layot vars

* Set Shift Indicator to include CAPS Lock as well

* Change MEH to GUI

* Add Enter to Macro layer

* Switch raise and lower layers to make more sense (to me)

* Replace unused quote on Ergodox

* Add One Shot defines

* Dim indicator LEDs

* Add short codes for KC_SECRET

* Fix typos

* Update OLKB code in userspace

* Add global userspace config.h

* add compile fix

* Automatically include  from userspace

* update readme

* Re-add QMK Scan loop

* Add EEPROM reset code to all keymaps

* Shorten fauxclick sound

* Use layouts instead of keymap, when possible

* Add OSM detection to ergodox

* Convert Viterbi to LAYOUT macro

* Clean up game macros

* Because I accidently removed the C6 AUDIO define from my viterbi... Whoops

* Minor formatting

* Fix Woodpad because it's still there

* Move Ergodox keymap into layouts folder

* Add build date to version macro

* Remove PREVENT_STUCK_MODIFIERS from config
7 years ago
Joshua Coffey a09a042b8f New keymap and more songs (#2609)
* Added some new songs and my own keymap

* Made Dodger keymap safe to use with backlight disabled

* edited layer switching and added more songs

* changed keymap to lowercase
7 years ago
RobertDhaene 3d587b1d2f Merge in some custom keymaps from forked repository (#2605)
* Inital layout

* Fix the backspace

* add a number pad

* move the backlight to the adjust layer; move ctrl and delete.

* Update from main repo

* Add initial files for custom keymap

* Light keymap mod

* Change the submodules to match the upstream fork's master branch
7 years ago
skullY c4f9b8f297 make new_project.sh work correctly on osx too 7 years ago
U-LANDSRAAD\drashna e72cad44fa Add Layouts to exclusion 7 years ago
U-LANDSRAAD\drashna f67950df27 Ignore users folder for Travis tagging 7 years ago
U-LANDSRAAD\drashna b23d2a68dc add syscalls.c if autoshift is enabled, to fix compile issue on ChibiOS 7 years ago
U-LANDSRAAD\drashna 34580baccf Fix #1566 - NKRO reseting issue 7 years ago
MechMerlin d9c6e7487b Refactor/v60 type r keymap/layout (#2593)
* Add a proper ANSI layout

Changed v60_type_r.h to have a proper ANSI layout
Modify keymaps to reflect above changes
Fix comments

* Add new layout to info.json
7 years ago
MechMerlin fa0d97a37f info.json configurator support for popular 65% keyboards (#2589)
* Support for tada68 ansi layout.

Avoiding the iso layout as it doesn't seem correct

* whitefox support for configurator

* configurator support for jc65 PCB featuring both the qmk and ps2avrgb versions
7 years ago
Wilba6582 59a784500b Initial support for RAMA M6-A (#2600)
* Initial commit of RAMA M6-A firmware.

* Added LED support

* Added Knops support

* Fixed compile error for knops keymap.

* updated readme.md

* updated readme.md

* updated readme.md
7 years ago
WarmCat 00dfa73e4c Added basic support for JJ50 (preonic-like based on atmega32A) (#2546)
* Added support for JJ50 from KPRepublic, no rgb or backlight control yet. Added as a layout of ymd96 at the moment (same microprocessor). Basic keymap with three layers to get started.

* Added support for JJ50
7 years ago
myrtle 4adc333455 Fix mechmini2 ortho keymapping layout
A misconfiguration in the ortho layout, K306 key was registered as k305
7 years ago
Danny 4e92dceed8 Add Fourier Keyboard (#2596)
* Initial commit of Fourier keyboard

* Revise keymap, add key to bottom row

* Fix readme
7 years ago
Danny Nguyen f77ecb8960 Add Laplace keyboard 7 years ago
U-LANDSRAAD\drashna d965d72d4a Fix custom functions documation for layer_state_set* 7 years ago
skullY 70cf46d4f1 fix the moxygen invocation 7 years ago
Daniel Hoek 3ee59a79aa Add HSV value specification (#2481)
* Update feature_rgblight.md

I got caught out with this as most color pickers use a percentage NOT 0-255 for this number

* Amended description

Woops! Was focused on s/v not being a percentage i got h wrong.
7 years ago
Takeshi ISHII 824d584d8c New keymap for The Helix keyboard("five_rows") (#2592)
* duplicate keyboards/helix/rev2/keymaps/default to keyboards/helix/rev2/keymaps/five_rows

* OLED Layer display 'Qwerty','Colemak','Dvorak'

* set Qwerty, Lower, Raise map

* set Colemak map

* set Dvorak map

* OLED Layer display 'Raise','Lower' change to 'Extra char','Function'

* fix ExtraChar Layer Shift-key disable

* Raise,Lower,Adjust layer modify

some key change KC_TRNS to KC_NO
add KANA, EISU key

* refine keymaps/five_rows/{config.h,rules.mk} for easy and safe customize

* modify Adjust layer: all function into left hand, remove F1..F12,DEL

* Add Helix five_rows keymap README.md and README_jp.md

* Raise Layer modify: enable Raise(Extr)+Lower(Func)==Adjust

* fix image file url in README.md,README_jp.md

* change Layer display on OLED

* change OLED display base name position
7 years ago
Yida Xu 3a49ad06cd New keymaps for bananasplit (#2586)
* New bananasplit keymap with toggable capslock led.

* Update comments.

* Update readme.md

* Updated keymap name

* update some keys.

* new layout for bananasplit

* update comment

* Update readme.md
7 years ago
Takeshi ISHII f56ded3214 add README.md into keyboards/helix/rev2/keymaps/led_test/ (#2582) 7 years ago
john McCormick 6b060bb9ad Add atlacat keymap (#2581) 7 years ago
Andrew Macpherson d0054c41e2 Fix typo in autoshift docs: statn (#2579) 7 years ago
XP 8575249411 Add a basic keymap for Contra. (#2564) 7 years ago
24-bit-8 8621fd8bbd ekis_isa keymap for HHKB'ish layout (#2562) 7 years ago
James Kay 4cf4fe80ec Just personal layout tweaks :) (#2557)
* More ergonomic mousekeys

* integrate some recent hardware changes by changing the Plover keymap

* use TX Bolt support instead of Plover toggles

* switching to steno is no longer as intrusive, so this can move back to BASE
7 years ago
J. Eric Mason ec5cc02bf0 Preonic Ergodox-Like Mac keymap: Bucktooth (#2553)
* Preonic Ergodox-Like Mac keymap: Bucktooth

This is a layout unlike most Preonics, it is taken partially from
Ergodox and classic C64 keyboards with a ton of Mac-specific features.

* Fix Mouse Left keycode
7 years ago
Ivan Smirnov 7a86a67d99 Fix broken markdown headers. (#2548) 7 years ago
akrob 6706e1af6c Add new keymap for iris transmogrified (#2361)
* Create config.h

* Create rules.mk

* Create keymap.c
7 years ago
MechMerlin 426c71de74 Add new bfake "FaceW" keymap (#2360)
* Add mechmerlin keymap and readme for facew board

* Fix keymap
- Backspace as on the wrong key
- HHKB backspace changed to backslash

* Update keymap.c

Change TO to TG for toggle.
7 years ago
David Collom b3e7149a65 yet another keymap (#2356)
* added keymap

* added readme
7 years ago
That-Canadian c3c4164faf That-Canadian Preonic layout (#2462)
* Line ending stuff again

* Added my own person keymap to preonic folder

* Updated my preonic keymap

* Updated my preonic keymap
7 years ago
Florian c808680436 initial branch (#2379)
* initial branch

* lazy-push

* Fix schema

Updated README, readded DVORAK to keymap.
Updated dir name to lowercase.

* removed executable bit

* testing switched L_GUI position
7 years ago
skullydazed 7c9d5ace14 Generate API docs from source code comments (#2491)
* Generate api docs from source code

* Add a bunch of doxygen comments

* more doxygen comments

* Add the in-progress api docs

* script to generate docs from travis

* Add doc generation to the travis job

* make travis_docs.sh commit the work it does

* make sure the docs script exits cleanly
7 years ago
Drashna Jaelre f0932a8716 Update info.json for Ergodox EZ (#2577) 7 years ago
Drashna Jaelre f7505ef67c Update info.json for orthodox (#2576) 7 years ago
MechMerlin 971b837009 Edit info.json (#2575)
GH60 had the ansi layout taken care of.
This commit adds hhkb, iso, and the "basic" KEYMAP layout.
7 years ago
MechMerlin e021f44378 Update info.json (#2574)
Change name from LAYOUT to KEYMAP.
7 years ago
MechMerlin 63b1946bfe Configurator support for minivan (tv44) (#2573)
Support all 4 layouts supported by the tv44 pcb.
7 years ago
Drashna Jaelre 780ff68674 Create info.json for Ergodox EZ (#2572)
* Create info.json for Ergodox EZ

* Add Orthodox info.json too
7 years ago
MechMerlin 004df55d7f Add configurator support (info.json) for Input Club K-Type (#2571)
* Add configurator support for Input Club K-Type

* update info.json to remove bootloader and add mcu
7 years ago
snyman 7a5ce36f23 Add macro for momentarily switching to a layer while some mods are active (#2460)
* Macro for a momentary layer switch with mods

Passes through to the existing ACTION_LAYER_MODS macro, albeit with more
limited options due to lack of space in the quantum_keycodes enum.

* Add documentation for LM layer-mod macro

* Clean up Tap Toggle documentation
7 years ago
U-LANDSRAAD\drashna 4ec03111cc Add Pretty Keymaps to Ergodox EZ 7 years ago
MechMerlin 1fbddc6613 Configurator Support(info.json) for 1up Keyboards Sweet16 (#2570)
* Configurator Support

- Add info.json to support existing layouts
- Add comment in sweet16.h to remind people to change info.json if
  the layout changes.

* Fix dlaroe's keymap
7 years ago
MechMerlin 2d8fda614e Configurator/dz60 support for info.json (#2568)
* Add info.json file for qmk_configurator

Unfortunately none of these keymaps look like a board I've seen in
the wild. Some further tweaks will have to be done to the keymaps
directly.

* add comment indicating need to edit info.json when keymap changes
7 years ago
Merlin04 6d66fe0c0c Added bootloader options
I think I got all of them, so I removed the "FIXME".
7 years ago
mechmerlin 6268656e01 add info.json to support both layouts on the contra 7 years ago
Drashna Jaelre ff728a8a01 [Proposal?] Allow RGB Underglow to turn off when host is idle/asleep (#2104)
* Add RGB Underglow Sleeping

* Add RGBLIGHT_SLEEP to toggle/control RGB light behavior

* Update rgb docs

* Update for RGB disable command
7 years ago
mechmerlin 37cc088486 Add info.json file to work with qmk_configurator 7 years ago
MechMerlin 500b060e3d Fix info.json issues to display properly in config.qmk.fm (#2552)
* Fix info.json issues to display properly in config.qmk.fm

* rename LAYOUT to KEYMAP to match .h file
7 years ago
dlaroe 4ca65bb6c6 retry of PR #2540 (#2554)
* reforked, untarred keymaps, added CRS and renamed my keymap folders

* Update readme.md

corrected a typo
7 years ago
Shayne Holmes b6db61b922 Fix logic in macos install
Also fix mixed spaces/tabs
7 years ago
Sebastian ce3adcd6e1 Added a clean target to remove build artifacts
This commit adds a new clean target to the makefile which deletes
the .build directory which removes all build artifacts.
7 years ago
Alexander Fougner 3acaad6600 Initial support for The Unloved Bastard 7 years ago
Jason Stillwell 00b4dce605 Rule to enable Modifiers with Auto-Shift (#2542)
* Re-enable modifiers with auto-shift

* Auto-shift modifiers rule

* missed a line

* Documentation

* fixing whitespace
7 years ago
Kenny Hung bb5c98699f Duplicate KC space to UK (#2541)
* Fix tilde in xd75 skewwhiffy

* Small tidy up

* Tidy up Colemak row

* Tidy up navigation layer

* Symbols layer redefined

* Fix UK Quote issue

* Use UK_QUOT rather than KC_QUOT
7 years ago
U-LANDSRAAD\drashna 682c8a260a Fix audio issues with Split keyboards that missed previously 7 years ago
fauxpark a2e12faa19 Add CMD and WIN aliases for KC_GUI, GUI(kc), GUI_T(kc), etc. 7 years ago
Pittyolo 729e99961c Updated keymap for my Nyquist layout 7 years ago
adiron 04d72590af New keymap for XD75re ("adi") (#2530)
* My XD75 keymap

* Proper readme for `adi` keymap for xd75re
7 years ago
Matthew Yee 4dc3a01fcb Added my keymap (#2529)
* Added my keymap

* maybe that wasn't quite right.

* Reduced the tap time to register layer

* changed the tapping term that fits my typing speed a little better

* Added retro tapping and reduced tapping term duration
7 years ago
Brian Choromanski a3047f1ab3 Added choromanski keymap (#2528)
* Added ergodox layout

* Added preonic layout

* Added readme for exgodox layout

* fixed errors with formatting readme

* Added edited preonic keymap & readme
7 years ago
Joe Wasson 5d771039ad Fix swap-hands tapping.
This is an inelegant hack for #2522 but makes things work. Basically we give `action.c` a chance to handle the hold event early so that we can swap the keyboard for later keys. Later, to allow the hold to happen again quickly we nuke the key record so that tapping is reset. I tried to find a cleaner way, honestly.
7 years ago
Joe Wasson 23ac2a02ef Add keycodes for swap-hands feature. 7 years ago
Joe Wasson 7230923b05 Rename ONEHAND_ENABLE to SWAP_HANDS_ENABLE for consistency 7 years ago
uplus 687c7070a1 fix generate Keyboard.h 7 years ago
Twentylives 598ab478be new handwired keyboard - Dactyl Manuform (#2516)
* adding new handwired keyboard: dactyl-manuform

* adding qwerty layout

* updating readme file.
7 years ago
James OFarrell 241421efd4 Added support for ca66 7 years ago
Takeshi ISHII 3d1801e63a Helix keyboard led test as a keymap (#2513)
* duplicate keyboards/helix/rev2/keymaps/default to keyboards/helix/rev2/keymaps/led_test

* OLED & RGB LED on

* duplicate quantum/rgblight.[ch] to keyboards/helix/rev2/keymaps/led_test

* rgblight.c modify for RGB test
7 years ago
Otto Rask ea070950e7 Add underglow animation support to rask's UK78 (#2512)
* Add rask's Satan layout

* Add rask's Satan layout

* Add rask's BananaSplit60 layout

* Add rask's BS60 readme

* Fix rask's BS60 readme image

* Fix rask's BS60 readme image again

* Add rask's UK78 layout

* Change RGui to be LGui to fix locale switching

On Ubuntu the keyboard seemingly lost RGui when toggling
between typing languages. With LGui toggling works normally.

* Add rask's ErgoDox Infinity layout

* Modify ErgoDox layout and add readme for it

* Add rask's UK78 layout readme

* Add undnerglow animation to rask's UK78 firmware
7 years ago
Drashna Jaelre 54f1cdfb1e Add teensy revision folder for Orthodox Rev3 (#2510)
* Add Rev3 Teensy for Orthodox

* MOve bootloader defines into revision folders

* Finishing touches
7 years ago
Daniel Rodríguez Rivero a730cf6718 Create sendstring_spanish.h
This makes possible to use SEND_STRING with a spanish keyboard for almost all symbols except the ones that require ALT, which are documented on the code comments.
I am not adding any documentation because the functionality is not complete until a way to specify alted symbols is added.
7 years ago
Louis Orleans f139c3db8d layout(preonic): update to dudeofawesome's layout (#2507)
* 🎉 duplicate default Preonic keymap

*  add Workman layout

* 🚚 swap backspace and delete

*  enable hold enter for shift

* 🚚 swap media play and next

* 💄 use Planck startup sound

* 💄 add Workman layer sound

*  add numpad layer

* 💄 add new workman sound

* 📝 add README

* 🎨 fix layout formatting

* 📝 add image of numpad layer

* 📦 changing chibios submodule version

to match upstream/master's version

*  add caps lock key on adjust layer

*  reworking numpad layer to match a real numpad

*  add double tap to activate numpad

* 📝 fix layout comments

* 📝 update numpad layer render

*  adding operator keys to left hand on numpad

* 🎨 shorten numpad keycodes

* 🎨 remove redundant breaks

* 📝 update numpad layer render

* 🎨 fix indentation

* 🔧 add rules file

* 🔊 play sound when switching to numpad layer

* 🔨 use userspace sounds
7 years ago
Louis Orleans 48321c3eee layout(infinity ergodox): update dudeofawesome's layout (#2506)
* 🎉 Building simple flasher

* 🎉 Flashing works

* 🎨 Cleaning up

* 🐛 Being more specific with board identity

* 🐛 Flashing correct keymap

* 🎉 Adding keymap

*  Updating keymap

* 🚨 RGB

*  Revert "🚨 RGB"

This reverts commit 9ceabfb267f8daedaad929231229c703abc12ec4.

*  Improvements to flasher

*  Layout tweaks

* 💄 Messing around with LCD

* 💄 Enabling LCD backlight matching

* 🔧 Updating layout

* 🐛 Fixing console logging

* 🎨 Cleaning up indentation

* 🔧 Adding editorconfig

*  Adding game layer

* 💄 Changing numpad layout

* 🔥 redoing entire layout

It's now more similar to the Planck default layout

*  add workman and dvorak layouts

* 🐛 fix numpad

* 🐛 fix layer orders

* 🐛 fix layer toggling

* 🐛 fix tri-layer switching

* 🐛 fix LCD colors for adjustment layers

* 🔥 remove old flasher project

* 🔥 remove simple_visualizer

* 💄 update LCD colors

* 📝 fix layout comments

* 💄  swapping 2u buttons

* 🔥🔧 removing editorconfig

* 🚨 using 2 spaces

* 📝 add README

*  Revert "💄 Enabling LCD backlight matching"

This reverts commit 51577903dfdc9fea5d33e9ab8cfa9b854e7ae19e.

*  Revert "💄 Messing around with LCD"

This reverts commit fdd9acdae514a3e0e4a7153225053680744980e5.

* 🐛 fix thumb inconsistency in QWERTY

* 🐛 fix media keys

*  add F# shortcuts to vertical 1.5u buttons

*  hold enter for RShift

*  hold for numpad

* 🎨 remove unnecessary breaks

* 🎨 reoganizing layers

*  add Colmak layer

* 🚧🔧 add basic config

*  use more standard numpad layout

* 💄 change layer orders

*  add caps lock on adjust layer

* 🔥 disable space cadet

* 📝 update README

* 🔨 use userspace config

* 🎨 clean up a bit

* 🐛 undefine tapping toggle from base config

* 🔨 rename LED functions
7 years ago
lucwastiaux e424944a57 update to Ergodox / Atreus Dvorak 42 key layouts (#2504)
* add SCREEN_NAV layer for copy/pasting within screen

* working readreg/paste macros

* working read reg / paste macros

* write log and tran patterns, and expand

* add ls -la shortcut, add tab on combined layer

* put delete word on the right pinky key on shell_nav layer

* add TAB on the right side, add reset key

* added Cloud9 macros

* add cloud9 shortcuts to atreus layout

* added BROWSER_CONTROL layer

* finalized browser control layer

* adding comment

* add browser control layer to atreus

* add flashing command line

* remove the tab on combined layer
7 years ago
Nicola Gargagli 4658786436 Add italian keymap 7 years ago
Brian Choromanski 6c74d734c2 Fixed various keymaps and the allocation of "key_combos" (#2526)
* Fixed plank keymaps so that they will compile for planck light

* tv44:budi now compiles

* s60_x:amnesia0287 now compiles

* Fixed allocation of key_combos so that narze keymap for planck can compile correctly

* Disabled rgb on ergodone and infinity

* Enabled tap dance so it compiles

* Added return statement so it compiles

* If compiling on light disable extra functionality

* Properly redefined variable so it compiles
7 years ago
U-LANDSRAAD\drashna ad1a868701 Move Narze keymap into Ergodox Infinity folder 7 years ago
U-LANDSRAAD\drashna 9db908f7d1 Fix Preonic layout 7 years ago
ajp10304 added1f062 Planck ajp10304 (#2519)
* Planck ajp10304 layout clean up

* Planck ajp10304 layout add Mac layer extensions

* JJ40 ajp10304 layout add Mac layer extensions
7 years ago
uplus e8e999dcc0 Fix preonic/rev2 bootloader config 7 years ago
Brian Choromanski 4464d90f4d Fixed plank keymaps so that they will compile for planck light 7 years ago
Joe Wasson 2dacf25f28 Add layout support for contra. 7 years ago
Joe Wasson bfa34d02b0 Add default keymap for contra 7 years ago
Jon Nall 0b82d08e8d Fixed exit status check for brew 7 years ago
adiron fdeb7f7665 Added Contra keyboard support (#2501)
* Added Contra keyboard support

The configuration came from a source distribution of the firmware on the
Contra's official website.

I have also included a simple MIDI keymap. (And it works!)

* Changes to Contra config and README

* Readme has been changed as requested by jackhumbert
* Config has been changed to add the Cartel and Contra names to
  the USB configuration.
7 years ago
sparkyman215 141a52982e update ymdk96 files 7 years ago
Danny ac5326595c Add Viterbi fido keymap (#2454)
* Add fido Viterbi keymap

* Cleanup rules files

* Remove unused WIP code
7 years ago
hypnocrat 400f410c45 XD75 keymap - Germanized (#2441)
* Added a heavily customized German keymap to the XD75RE

* A heavily customized alternative layout for the XD75, for German users

* Fixed capitalization, removed unnecessary files

* Hopefully fixed capitalization, some keymap changes
7 years ago
Brian Choromanski 8d6eadf261 Patched some keyboards that won't compile (#2453) 7 years ago
Louis Orleans 0e6e059ef3 layout(planck): dudeofawesome's layout (#2457)
* layout(planck): new layout initial commit

* feat(planck): add workman layout

* fix(planck): switching to workman

* layout(planck): swapping mnext and mplay

* feat(planck): prep for RGB

* perf(planck): remove plover

saves 256 bytes of memory

* perf(planck): remove colemak

saves 128 bytes

* layout(planck): swapping enter and quote

* perf(planck): disable console

frees 1664 bytes

* feat(planck): RGB under-lighting

* refactor(planck): change RGB pin

Uses pin labeled PB2

* feat(planck): add RGB keycodes

* feat(planck): re-enable audio

* style(planck): fixing indentation

Because who indents like that?

* style(planck): clean up keycodes

* layout(planck): remove del

* feat(planck): add tap-space to layer keys

* docs(planck): specify pin on PCB for RGB

* bug(planck): reducing tap time

* Revert "bug(planck): reducing tap time"

This reverts commit 62606b2dc62c5adcc06cfb5978d7e5305411a658.

* Revert "feat(planck): add tap-space to layer keys"

This reverts commit c74de5a4aa45c5563dcaa463395654c29f50eda3.

* perf(planck): remove backlit case

* feat(planck): swap enter and quote

* bug(planck): moving right shift

* doc(planck): update README

* chore(planck): remove makefile

* 🔨 add userspace config

* 📝 update layer ascii art

* 🔥 disable RGB lighting

*  add Colemak

*  add numpad layer

*  add caps lock on adjust layer

* 📝 update layer renders

* 🔥 remove workman sound def

* 🔨 add userspace config

* 📝 update layer ascii art

* 🔥 disable RGB lighting

*  add Colemak

*  add numpad layer

*  add caps lock on adjust layer

* 📝 update layer renders

* 🔥 remove workman sound def
7 years ago
Campbell Barton 0603dcb1be qwerty_code_friendly: minor updates (#2494)
* qwerty_code_friendly: minor updates

- Correct mistake in ascii keymap.
- Make lower right key delete again, but make it configurable.
- Make double shift for double quotes optional.

* qwerty_code_friendly: shift users title-caps
7 years ago
MakotoKurauchi 3313473004 Usb max power (#2502)
* add some comment about Helix customize and auto-setup RGBLIGHT_LIMIT_VAL

* add define USB_MAX_POWER_CONSUMPTION
7 years ago
Drashna Jael're 3f1d147529 Add SS_RALT for AltGR usage in macros 7 years ago
edwardbrowncross eba4b08a4a Add the OK60 keyboard (#2488)
* Add the OK60 keyboard

* Fix ok60 incorrect ANSI keymap signature
Add support for default ansi and iso 60 keymaps
7 years ago
Oscillope 7d9dc61504 Fixes for JJ40 and Oscillope keymap (#2496)
* Add navigation layer for hjkl arrow keys

* Fix Oscillope keymap after jj40.h changes. Also fix jj40.c so that it can build without rgblight if you don't want that enabled.
7 years ago
skullydazed 566399794a
Disable the glossary linking to fix #2498 (#2499) 7 years ago
That-Canadian 2bdf1731c3 Canadian planck (#2463)
* Line ending stuff again

* Added my personal Planck layout (finally)
7 years ago
MakotoKurauchi 955b17189a Move rows config to keymap (#2464)
* Fork from Let's Split

* Organizing files

* Delete some keymaps

* I2C and serial enabled at the same time

* Change readme

* add #define HELIX_ROWS for multiple rows

* Delete avrdude flashing script

* Delete makefiles

* Subproject elimination

* Fix lufa path

* Remove PLAY_NOTE_ARRAY usages to get rid of warning.

Fix conflicting function name

* Mousekey change default to off

* Fix to oled display adjust

* make rev2

change pin assign
change keymap

* use master_buffer

* Timing adjustment

* Organizing files

* Change Keymap

* Change Keymap

Add EISU and KANA
Correct 4rows

* NKRO default to disable

* EXTRAKEY_ENABLE default to disable

* add rgb reset key

* rgb custom function enable

*  Extend font

* add RGBLED_POWER

default folder to helix/rev2
RGB_ENABLE to no

* renamed directory

* Disable RGBLIGHT_CUSTOM_DRIVER

* Disable LOCKING_SUPPORT_ENABLE

* Update bootloader setting

* Change readme

* Fixed argument error

* Move rows config to keymap
7 years ago
crazyiop 3d7e9425c7 quantum: keympa_extra: add sendstring_bepo.h 7 years ago
crazyiop 483e3cd1cb quantum: keymap_bepo.h: fix typo in BP_COMMMA 7 years ago
Lukas Klingsbo 821b492667 Swedish layout for iris 7 years ago
Cole Markham bd1ad405bf Update Meira for revision 1.1 to enable backlighting by default (#2468)
* Update Meira for revision 1.1 to enable backlighting by default

* Updates to fix other keymaps
7 years ago
Maarten Dekkers 03df19d3f6 Fixed keymap, added capslock led for maartenwut's kbd66 keymap (#2473)
* Fixed keymap, added capslock led

* Removed macro
7 years ago
U-LANDSRAAD\drashna 42e85d2b92 Add layer_state_set_* to custom function lists 7 years ago
U-LANDSRAAD\drashna d27d854913 Examples should all use _user functions for consistency 7 years ago
Sebastian Kaim bec8d58ad8 Fixed compilation of the ps2avrGB keyboard/firmware (resolving #2425) (#2478)
* Fixed compilation of the ps2avrGB keyboard/firmware

This commit fixes the silent compilation error for the ps2avrGB
keyboard/firmware. This error was caused by a lacking default
keymap which it did not have because all keyboards based on it were
moved to another directory. I also added the required config.h
options so it's possible to compile it again and (probably)
flash it on a b.mini.

Lastly, I updated the README to reflect the current state.

This commit fixes #2425

* Referenced the pearl in the ps2avrGB REAMDE

Added a reference to the pearl keyboard in the README of the ps2avrGB keyboard as it is originally based on the firmware as well.
7 years ago
Blake Newman 6c473c5f38 layout(preonic): blake-newman's layout (#2483)
* layout(preonic): blake-newman's layout

- Add keymap
  - Add Number Pad layout
  - Reconfigure other layouts to my opinionated style
- Add `readme.md` with layout information

* layout(preonic): blake-newman's layout

- Move enter to `raise + space` / `lower + space`
- Replace `enter` to `right shift`
- Explicitly map modifier keys
7 years ago
Campbell Barton aadb386de6 qwerty_code_friendly: various updates
- Remove action_get_macro in favor of process_record_user
- Support user defined words on layer 3 (pass via flags)
- Support backspace & del on left thumb cluster.
  (optionally override top right backspace).
7 years ago
Corey T Kump b688c2c0b3 Corvec's Planck layout 7 years ago
Joe Wasson 7b80aea8b2 Add back docs for hand-swapping feature. 7 years ago
Kenny Hung 586aa15cef A small tidy up (#2490)
* Add extra RGUI key to make keyboard more MAC friendly

* Remove enumerators for no longer used layers in layout Skewwhiffy for XD75

* Make layer numbers even better
7 years ago
skullY 48e11240a6 Move the linux tutorials to an info box on newbs_getting_started 7 years ago
skullY 75354f12d7 warn->danger 7 years ago
skullY 6a4e08938e Flesh out the newbs guide 7 years ago
skullydazed 08e48eb6f5
Add a newbie guide for people completely new to QMK (#2480) 7 years ago
Pawnerd 12c8ee956d Add knops configurator support (#2474)
* Committed initial version of the knops configurator.

* Added support for the Knops v1.1
7 years ago
Graham P Heath b36b4382d0 Mention invalid names in the readme. (#2458) 7 years ago
skullydazed e87c39d302
More thoroughly document Bootmagic and Command (#2455) 7 years ago
skullY e5c331e7be Fix the SGUI aliases 7 years ago
skullydazed e3f67e6e7f
Add `SGUI()` and `SGUI_T()` for consistency with `KC_GUI` (#2442)
* Add `SGUI()` as an alias of `SCMD()` for consistency with `KC_GUI`

* Add `SGUI_T()` as an alias of `SCMD_T()` for consistency with `KC_GUI`

* Make SGUI the primary name
7 years ago
Mitchell van Manen 31cae1f1bd Update feature_macros.md (#2387)
break statements are never reached due to the return statement, so unnecessary
7 years ago
Ivan Choi 0092be5925 adding my keymap (#2443) 7 years ago
Maarten Dekkers 381f4e6404 Updated and added maartenwut's layouts (#2444) 7 years ago
fauxpark b713feb6f2 Add a little aside explaining that shifted keys with mod-tap doesn't work (#2446) 7 years ago
Louis Orleans d7f46f3466 layout(preonic): dudeofawesome's layout (#2449)
* 🎉 duplicate default Preonic keymap

*  add Workman layout

* 🚚 swap backspace and delete

*  enable hold enter for shift

* 🚚 swap media play and next

* 💄 use Planck startup sound

* 💄 add Workman layer sound

*  add numpad layer

* 💄 add new workman sound

* 📝 add README

* 🎨 fix layout formatting

* 📝 add image of numpad layer

* 📦 changing chibios submodule version

to match upstream/master's version

*  add caps lock key on adjust layer

*  reworking numpad layer to match a real numpad

*  add double tap to activate numpad

* 📝 fix layout comments

* 📝 update numpad layer render

*  adding operator keys to left hand on numpad

* 🎨 shorten numpad keycodes
7 years ago
Drashna Jaelre 452d23da52 Update to drashna keymaps and userspace (#2450)
* Add OSL keycodes and macro handling

* Re-add AVRDUDE target

* Userspace document cleanup and commenting

* Fix Orthodox keymap layout (cosmetic)

* Add caveat for KEYMAP Macros

* Minor tweaks

* Enable Bootmagic in Ergodox EZ

* Minor tweaks
7 years ago
Brian Choromanski 7f7f763598 Fixed dead links (#2451)
* Fixed typo of 'confid.h' to 'config.h'

* Fixed broken links in docs

* Fixed a lot of dead links
7 years ago
Gam3cat 2b8a82fb9d M10-A, M65-A, GonNerd keymaps (#2418)
* adding my keymap

* update keymap

* adding gamecat keymap for jc65 keyboard

* updating jc65-gamecat keymap

* updating jc65-gamecat keymap

* updating jc65-gamecat keymap

* updating jc65-gamecat keymap

* M10a keymap and M65a updates

* keymap updates

* keymap updates

* M10a/M65a keymap updates

* M10a/M65a keymap updates

* Delete test.txt

* M65 keymap update

* M65 keymap update

* M65 keymap update

* M65/M10 keymap updates

* M65 keymap update

* M65 keymap update

* M65 keymap update

* M65 keymap update

* M65 keymap update

* M65/M10 keymap update

* M65 keymap update

* M65 keymap update

* M65 keymap update

* M65 keymap update

* M65 keymap update

* Set theme jekyll-theme-cayman

* Set theme jekyll-theme-slate

* M65 keymap update

* M10a/M65a keymap updates

* M10a keymap update

* M65a keymap update

* M65a keymap update

* M65a keymap update

* M65a readme update

* M65a/M10a updates

* M65a readme updates

* M65a/M10a updates

* M65A update

* M65A update

* M65A update

* M65A update

* M65A/M10A keymap update

* M10A keymap update

* Set theme jekyll-theme-tactile

* M10A keymap update

* M65A keymap.c update

* M65 keymap added LED backlight toggle, inc/dec to adjust layer.

* M65 keymap/readme updates.

* M65 keymap fix

* M65 keymap update

* remove theme

* fix comments/readme

* update keymap

* LED backlight update, guess based on reading atmega32u4 documentation for DDRB/PORTB regs, believe DDRB should only be written to once not every time CAPS is hit, but really not too sure.

* LED backlight update, guess based on reading atmega32u4 documentation for DDRB/PORTB regs, believe DDRB should only be written to once not every time CAPS is hit, but really not too sure.

* M65 keymap update

* Updated M65, M10, and gonNerd keymaps.

* update

* del

* keymap updates M65, M10, gonnerd

* update keymaps

* adding back readme that somehow got removed.
7 years ago
Brian Choromanski 8e99fbc884 Fixed typo of 'confid.h' to 'config.h' (#2448)
* Fixed typo of 'confid.h' to 'config.h'

* Fixed broken links in docs
7 years ago
Danny 524053e3c0 Remap msys2 usb, fix USB port detection (#2301)
* Add AVRDUDE to MSYS2 setup

* Remap detected USB port in MSYS2 to COM port
7 years ago
Jason Gorman 19b02bf267 Merge of e6v2 stuff as well as my personal keymaps (#2434)
* Checkin of tada keymap and initial commit for e6v2.

* checking in other remaining changes before trying to merge

* Reverting pin change. This was done based on the json orginally provided by exclusive, but it was later determined my map was the correct one based on user testing

* fix extra key for ansi keymap. Didn't include fn as standard ansi shift is not split but still had it in keymap

* Fix default help file and add reset to default
7 years ago
skullY 298ac18dfa remove duplicate #define 7 years ago
skullY c6ce959f49 Test a shrug macro 7 years ago
Yan-Fa Li 3b801880a0 Custom keymap for clueboard 60
My customized keymap for the clueboard 60.

 - Maps MT(LCTL,ESC) to Caps lock
 - Swaps ALT and GUI for OSX
 - Adds layer for WASD key navigation
7 years ago
Alejandro Blanco 21a37a5245 ErgoDox layout similar to Truly Ergonomic 7 years ago
Sean-Li Murmann 3cff95c8df new customized ErgodoxEz keymap with easy to remember modifiers. (#2400)
* First pass keyboard setup!

* More variation

* Final layer for today

* Added brace to middle key
7 years ago
Isaac Hookom 93eabc4b2c new xd60 layout (#2405)
* new xd60 layout

* fix kc_slsh
7 years ago
ajp10304 01f91bf6f4 JJ40 AJP10304 layout (#2407)
* JJ40 AJP10304 layout
Updated AJP10304 readme.md with formatting

* Revert default JJ40 keymap
7 years ago
Michael Wamsley 2c1ba03a98 Add additional 'tada68' layout. 7 years ago
lucwastiaux 27d32378b5 Update Dvorak 42 key layouts (#2420)
* add SCREEN_NAV layer for copy/pasting within screen

* working readreg/paste macros

* working read reg / paste macros

* write log and tran patterns, and expand

* add ls -la shortcut, add tab on combined layer

* put delete word on the right pinky key on shell_nav layer

* add TAB on the right side, add reset key

* added Cloud9 macros

* add cloud9 shortcuts to atreus layout

* added BROWSER_CONTROL layer

* finalized browser control layer

* adding comment
7 years ago
scott-t-wilson 3f3d0551cd Lfkeyboards updates (#2421)
* Update smk65 fn layer, add iso

* Added Fn layer to ISO keymap

* Fix error when backlight is disabled but lighting isn't

* Remove broke mini1800 iso map

* Add keymaps

* Add LFKPad

* Add split delete to lfk78

* Typo

* Custom keymap
7 years ago
Graham P Heath f746174874 Graham's Keymaps. (#2422)
* add my config

* fix backlight, clean up that code

* group background code, restore static var

* qwerty is supposed to be in the middle

* wrap layer change backlight in ifdef

* backlight levels and some more 'emojis'.

* Restructure to make it possible to press cmd ent on the right side of the board with one hand.

* Expose the period through the number layer. Add Hyper keys to mouse layer

* reduce mouse speed

* add a : -P  key

* Thumbs up and down, remove some keys that are duplicated via function keys, clean up

* fix build issues

* add various emoji

* duplicate default Meira keymaps

* Miera updates

* add documented but unmapped emoji

* Sound for the Meira, was stumped by a file size! Thanks drashna!

* add docs

* docs

* revert lib changes...

* clean up

* clean up

* remove make file

* Fixes missing key
7 years ago
Yan-Fa Li a8daf3ffba Document bootmagic hot keys
- covers most of tmk_core/common/bootmagic.h
7 years ago
wanleg 3b4d26e344 flashing instructions, keymap changes
* added flashing instructions for Linux & Windows
* minor keymap changes
7 years ago
ferbie 767f7a8cf0 Fixed formatting for Fedora example 7 years ago
deadencryption ee176f2b27 Adds dead encryption keymap 7 years ago
Mason McAllaster c72c1db68b Planck/NIU_Mini - Mason Layout - Fixing comments, adding missed keys 7 years ago
James Shackleford d469aaa166 tada68: layout: add new layout 'tshack' (#2431)
* Move to a more cross-platform grep command

* Use sed to strip out AVR_SIZE instead

* tada68: layout: add new layout tshack

Adds "James Shackleford's UNIX layout" for the Tada68
7 years ago
Jose Pablo Mora d54de1c5f2 ergobox -> ergodox 7 years ago
Ben Hilburn 8df2ee4ec3 Minor updates to docs (#2406)
* [docs/] Cleaning up some language to make it more clear.

* [docs/] Adding instructions for installing deps on RH / Fedora.
7 years ago
Jason Barnachea 0e92d99cdc Readme img link updates (#2410)
* QMK and JC65 pcb img links updated

link fixes

* personal keymap updates

new v32u4 keymap, updated v32a keymap

* Update readme.md
7 years ago
Danny 3d92b21a3b Update dilly default keymap (#2413)
* Move DEL to correct layer

* Move BNM to the left by one and move Backspace, add more stuff to layers
7 years ago
rempired 78f5a2a3dc 1up60rgb Keyboard Support (#2404)
* Add files via upload

* Update keymap.c

* Update keymap.c

* Update 1up60rgb.c

* Tidy up the code a bit for submission into QMK Master
- Create readme file
- Fix compile issue with standard keymap
- Create default keymap
- Remove unused Makefile

* Keymap Adjustments

* Reworked alternate layouts

* Reworked keymaps

* Update keymap.c

* Update readme.md

Add carriage return to make README cleaner
7 years ago
Danny Nguyen f67c59aa7b Move hexwire layout into 4x12 layout folder 7 years ago
Danny Nguyen 2a5da62728 Add Dilly keyboard 7 years ago
GlenPickle d1ea398fb9 Added Chimera LS and Chimera Ergo (#2335)
* Added Chimera Ortho keymap

* added readme

* fixed hardware link

* Added KC_KEYMAP

* resolving conflict

* Added Chimera LS and Chimera Ergo

* Added rules file

* fixed rule files

* Added Chimera Ortho keymap

* Added KC_KEYMAP

* Added Chimera LS and Chimera Ergo

* fixed rule files

* fixed rule files

* fixed image links

* Added KC_KEYMAP

* Added Chimera LS and Chimera Ergo

* Added Chimera Ortho keymap

* fixed rule files

* fixed rule files

* fixed image links

* Fixed KEYMAP vs KC_KEYMAP
7 years ago
Yan-Fa li bfc2b1205a u/yanfali custom keymap for Iris
Based heavily on the keymap by hexwire.

 1. Moved LALT to LCTL; I don't need CTL because of ESCC.
 1. Moved RAISE to old LALT.
 1. Moved ENTER to old RAISE.
 1. Move QUOTE to old ENTER.
 1. Moved PLUS to old QUOTE.
 1. replaced music next and volume up with browser forward and back
    through history
7 years ago
Pittyolo 7b5c6a895e Update keymap.c 7 years ago
tameone 4f55a7aca1 Iris: Create info.json (#2396)
* Create info.json

* Update info.json
7 years ago
Drashna Jaelre b0e8de1c97 Fix EE HANDS on splits losing handedness if RGB is enabled (#2399)
* Fix EE HANDS on splits losing handedness if RGB is enabled

* Because I'm an idiot and did a bad cut/paste job
7 years ago
ChrissiQ 1af8f1f201 Let's Split: Minor keymap fixes 7 years ago
Oryhara b89e318d35 adding my stuff back after hard reset 7 years ago
Johan Ju 20b5dd80bd Fix swedish NO_GRV 7 years ago
Fred Sundvik 25c7533092 Change the CDC_NOTIFICATION_EPSIZE back to 8 from 32 7 years ago
Fred Sundvik 50038882e0 Set unused USB serial buffer to 1 byte to save memory 7 years ago
Drashna Jaelre 6f5e88277b Update to drashna keymaps (#2381)
* Add to list of predefined rgb colors

* Change layer colors, to reflect new options

* Use Tag Toggle instead

* Clean up macros and add breathing indication for OSM Layer

* Get Viteri Macropad working properly

* Disable unused action features

* Use I2C because that's smaller, apparently

* Remove viterbi-half code
7 years ago
Gomme_Bidule 63df056013 Update feature_auto_shift.md 7 years ago
Kayle Knops 6f1d5f73a4 Committed initial version of the knops configurator. 7 years ago
skullydazed 994d94140e
Clueboard hotswap support (#2376) 7 years ago
skullydazed fa72d4aa5a
Modernize clueboard, add 66_ansi and 66_iso layouts (#2377) 7 years ago
yiancar 88a7fa762f New keyboard: Cu75 (#2374)
* Added Modular keyboards L,R and NUM

Created code modules for the 3 modules of the modular keyboard.
Original idea by MechboardsUK. Uses i2c implementation similar to lets
split

* Remove modular from master

This is to fix incorrect branching

* Addition of cu75

Addition of cu75 keyboard, uses libraries from LFKeyboards directory which are path linked to reduce file duplication.

Minor fix on cu24 readme

* Minor Readme Fix
7 years ago
IslandMan93 cd0c089b49 Diverge 3 initial commit
woo it works

use lets split code

Final working. Uses serial

Update license
7 years ago
Raymond Douglas 5bdc5c1190 Added raylas keymap for TADA68 7 years ago
Jason Barnachea a972b26274 Add JC65 ps2avrGB keyboard (#2351)
* Adds JC65 ps2avrGB keyboard

* Adds default keymap

* Adds personal keymap

* Backlight On/off support

Migrated code from the BFake. Functionality only on BL_ON, BL_OFF,
BL_TOGG.

* Backlighting config adjustment

Only 1 level supported.

* Personal keymap update

BL toggle added and RGB layer updates.

* Renamed jc65 ps2avrgb directory

Renamed directory for more clarity.

* Default keymap and default rules

* Personal keymap and personal rules

* Group JC65 QMK and PS2 versions

Group JC65 QMK and PS2 versions, Split directories, Readme for parent
folder.

* Default keycaps and personal keymaps re-added

Default and personal keymaps re-added. Keymaps, Readme, Rules.mk, and
config.h

* v32a default keymap rules

Default to no.

* RGB and Backlight default settings

Set to yes.

* Rules.mk defaults for personal keymap

Rules.mk defaults for personal keymap

* Revised keyboard readme make paths

Revised.

* Path correction

* jc65 default folder set

set default pcb to qmk version

* default rules for v32a

set to enable backlight and rgb by default.
7 years ago
Fred Sundvik 8c2ae4a470 Fix reset for STM32 devices 7 years ago
Michael F. Lamb fca31693df add conditional to perform check-size only for supported architectures 7 years ago
Michael F. Lamb fae8132295 make check_size work across platforms 7 years ago
Drashna Jaelre 6835ae8209 Add the ability to disable Music Mode completely (#2339)
* Skip process_music in NO_MUSIC_MODE is defined

* Skip matrix_scan_music if NO_MUSIC_MODE is defined

* Skip music_all_notes_off if NO_MUSIC_MODE is defined

* Leave matrix_scan_music in, because it reduces firmware size by 150b....

* Add docs for NO_MUSIC_MODE
7 years ago
Danny Nguyen c5d81a84a0 Switch from echo to printf for output without newlines 7 years ago
Danny Nguyen 361810dca8 Only search through newly detected devices and discard ones that disappeared 7 years ago
fredizzimo 53ff8a31b6 Merge ChibiOS and LUFA descriptor support (#2362)
* Move lufa descriptor to protocol/usb_descriptor

* Try to compile usb_descriptor on ChibiOS

* Add lufa_utils for ChibiOS

Lufa USB descriptors for ChibiOS

* More lufa_util compatibility fixes

* First compiling version of shared USB descriptor

* Send the usb descriptors

* Fix the CONSOLE output on ChibiOS

* Add errors for unsupported interfaces

* Enable support for vitual serial port USB descriptors

* Implement virtual serial port for ChibiOS

* Cleanup the lufa_utils

Use the default lufa header files

* Add raw hid support for ChibiOS

This is completely untested

* Enable midi compilation on ChibiOS

* Move midi functionality out of lufa.c

* Don't register sysex callback when not needed

* ChibiOS compilation fixes

* Update ChibiOS submodule

* Fix the Midi USB descriptor

It didn't work properly when both Midi and Virtual serial port was enabled.

* Add MIDI support for ChibiOS

* Fix USB descriptor strings on ChibiOS

* Use serial usb driver for raw hid

* Generalize the ChibiOS stream like drivers

This makes the initialization much more simple and eliminates a lot of
the code duplication.

* Convert console output to chibios stream driver

* Fixes for ChibiOS update

* Update the ChibiOS contrib submodule

To include the usb data toggle synchronization fixes

* Fix duplicate reset enumeration on ChibiOS

* Add missing include

* Add number of endpoints check for ChibiOS

* Enable serial USB driver on all keyboards

* Add missing includes when API is enabled withot midi

* Add another missing inlcude
7 years ago
Jack Humbert 63c16f4b63
ARM audio fixes, stack size increase (#2365)
* fix up arm audio implementation

* chibios stack size inc

* get one channel working

* update for chibios
7 years ago
jetpacktuxedo 7d79412f99 Fixed my minivan F-keys 7 years ago
Niles Christensen 57dde3ddba Makes layers consistent with comments 7 years ago
Danny Nguyen 8afbd649f0 Replace Right key on base layer with RShift, convert adjust to KC_KEYMAP format 7 years ago
Fred Sundvik 30b90de7c9 Send usb wakeup through ChibiOS 7 years ago
Fred Sundvik 30e413f985 Update Chibios Contrib with 17.6.3 support 7 years ago
Fred Sundvik 6a9617b1c6 Update ChibiOS to 17.6.3 7 years ago
Legonut ad01e3c03a New keyboard added "Zen" (#2347)
* New keyboard added

Zen is a split ortholinear currently in group buy.

* remove bad keymap

Keymap was throwing errors

* remove other bad keymap

I should have checked these before haha

* small fix to update folder name

* renamed temp

* renamed to zen

* update folder name

* Slim down matrix code

Suggested by drashna

* move KC_NO

* Update keymap

* change from rev2 to rev1
7 years ago
Drashna Jaelre 9cfcd49406 Re-add Flip Installer (#2355)
* Re-add Flip Installer

Found the update URL for it.
http://www.microchip.com/developmenttools/productdetails.aspx?partno=flip

* Comment out JRE installer version
7 years ago
QMK Bot f26e6fca8a convert to unix line-endings [skip ci] 7 years ago
KeLorean 0e31d85b8e made changes to my kelorean planck keymap (#2343)
* Planck-swapped up/down arrows,s65x-add dvorak

* Added Dvorak as first layer of default keymap

* planck-swap up and down arrows. s65x-added dvorak

* added colemak to kelorean s65x keymap

* made more changes to kelorean keymap

* just tryinng to fix bc i was not connected upstrem
7 years ago
U-LANDSRAAD\drashna 84a713b05c Remove _quantum functions from custom matrix.c code 7 years ago
skullydazed 9aaa491bc0 Add stm32 to drivers.txt 7 years ago
scauligi 9fcda95363 Fixes to get tap dance to fire at proper places (#2272)
* tap dance fixes: fire immediately upon completion and also get properly interrupted before macros

* bugfix for tapdance improvement

* fix build
7 years ago
KeLorean 2908c0f927 made kelorean keymaps for planck and s65x (#2331)
* Planck-swapped up/down arrows,s65x-add dvorak

* Added Dvorak as first layer of default keymap

* planck-swap up and down arrows. s65x-added dvorak

* added colemak to kelorean s65x keymap
7 years ago
Drashna Jaelre 598384bc10 Update to drashna userspace (Keymap Templating) (#2338)
* Change tapping term to be longer

* Make Audio/Underglow settings permanent

* Use wait_ms rather than _delay_ms

* Readd One Shot Mods

* Switch to Imperial March startup sound

* Move OSM to it's own layer

* Minor Formatting Tweaks

* Keymap Templates and formatting fixes
7 years ago
Harley Laue ac82cd1ba7 Added personal nyquist & levinson layouts 7 years ago
f3d3 31f5229191 Added dz60 custom layout (#2302)
* Add files via upload

* Update keymap.c

* Delete keymap.c

* Added dz60 banana-split layout

* Added dz60 custom layout

Added layout for dz60 with split spacebar, arrows and other customizations.
7 years ago
jirgn 2f65ab183d just a planck layout (#2320)
* added jirgn keymap from dotfiles

* added jirgn s keymap as copy from default

* [TASK] removed unnecessary colemak and dvorak layouts

* [TASK] added right shift with tab to enter

* [TASK] added ctrl keys beside homerow

* [TASK] added Navigation Layer

removed unnecessary BACKLIT
removed Media Controls in Base Layers

* [TASK] added left Navigation mode  fixed some doc

* [Fix] locked navigation layer by adding a transparent key for nav_mod
keys

* [TASK] added some more symbols and removed lower F1-F12 keys

* [TASK] added some README and a layout design

* [FIX] forced for adding to repo

* [FIX] forced for adding to repo

* [FIX] problem with layerswitching and hanging ctrl

* removed image from repo

* removed github image link with permalink from layout designer

* removed github image link with permalink from layout designer

* replaced image with permalink to layout editor
7 years ago
yiancar 8350d7e607 Cu24 keyboard addition (#2330)
* Added Modular keyboards L,R and NUM

Created code modules for the 3 modules of the modular keyboard.
Original idea by MechboardsUK. Uses i2c implementation similar to lets
split

* CU24 Support

Addes Support for the upcoming CU24 keyboard sold by CapsUnlocked

* Removed modular keyboards to make stuff clear

* Lower Case folders

* Remove CU24 - Rename Folder

* Add CU24 - Renamed

* Fixed ignore list

I am stupid
7 years ago
Fred Sundvik e7bb975482 Fix .editorconfig to not mess with line endings 7 years ago
Emily Soldal a6be48681a Map num lock and caps lock LED events to the RXLED and TXLED 7 years ago
HagVcom e9944bfc8e Added "hag" keymap to Iris (#2313)
* Create keymap.c

Add Hag keymap, a heavily modified dvorak swedish keymap with multiple layouts and often used stuff under the alpha cluster.

* Create config.h

* Create rules.mk
7 years ago
Kenneth Aloysius 9303b42e69 Update personal layouts, free up matrix_scan_user for JJ40 (#2319)
* Add NIU Mini keymap from Planck keymap

* Remove old keymap files

* Fix README, removed Planck references

* Add default layout, move Planck layout to separate folder

* Update README

* Add my XD60 keymap

* Change RShift to slash

* Fix keymap: stuck on MO(1)

* Move RESET to Fn+Enter

* Add: RGB saturation cycle

* Add numpad layer to keymap

* Fix last case

* Cleanup Mechmini keymap. Once the custom RGB function is defined, there is no need to manually handle RGB code.

* Change default to KEYMAP_MIT, not KEYMAP_OFFSET

* Add custom RGB code for JJ40

* Reset Mechmini advertised power draw to 500. Will have to test actual maximum power draw later.

* RGB working on JJ40.

* Fix: saturation increase/decrease flipped

* Add new directory for my custom keymap with RGB keycodes

* Swap LAlt and LGUI

* Update JJ40 max power draw with measured value

* Update: fun40 rules.mk to enable underglow; earlier failed Travis CI

* Fix: init RGB LEDs on boot. Also added HHKB-like keymap for XD60.

* Super rudimentary backlight test, init RGB LEDs on boot

* Backlighting works - stays on for now

* Toggling working

* Now can override backlight.c functions. Problem was functions in backlight.c weren't called before due to a lack of matrix_scan_quantum() in matrix.c

* Timers not working

* Delete global.h

* Cleanup

* Compiles

* Good sign: LEDs stop working again

* Handle timer1 overflow

* Progress: fix: forgot to init

* Backlighting fully working now except breathing.

* Revert keymap to original keycodes

* Update XD60 keymap README

* Update JJ40 keymap with backlight toggles

* Breathing working just fine.

* Update references

* Add backlight_set() call

* Cleanup code to disable backlight

* Fix: does not compile

* Fix: missing call to rgblight_task.

* Testing with BACKLIGHT_BREATHING

* Cleanup

* Cleanup comments

* More commenting cleanup.

* Do not enable BACKLIGHT_BREATHING by default

* Update XD60 keymap

* Update: move matrix_scan_kb out from matrix.c to jj40.c (kb-level)

* Cleanup for PR

* Fix conflict in readme.md for NIU mini

* Restore original power consumption figure

* Fix: matrix_scan_user() now has to be defined in the keymaps

* Add weak `matrix_scan_user` so it does not have to be defined in keymap

* Add weak matrix_init_user()
7 years ago
kifinnsson 042a450e24 Personal BEAKL9 based keymap (#2304)
* Adding personal BEAKL9 based keymap

Initial commit, very much a WIP/Proof of concept.

* Updating personal BEAKL9 based layout

* F-keys added to upper layer
7 years ago
jola5 2cf6bfe9ac Not quite neo (#2318)
* planck with a not-quite-neo layout for a de-DE OS/SW keymap

* ergodox infinity with a not-quite-neo layout for a de-DE OS/SW keymap

* add documentation
7 years ago
Donald 2917e55bd4 Added info.json and updated README for Deltasplit75 (#2266)
* Added info.json and updated README

* Updated info.json
7 years ago
Louis Orleans 55d4c9b162 🔧 create info.json for Infinity Ergodox (#2267)
* 🔧 create info.json for Infinity Ergodox

I'm not sure if the bootloader key is set correctly.

* 🐛 fix layout name
7 years ago
Erin Call 904b1b3f99 Use perl directly instead of grep -P
BSD grep (the one on OSX) lacks a -P flag. The grep -P command thus
fails and prints a usage message to the terminal. This fixes that.
7 years ago
mvs 0310eafdcf QWERTY based layout with thumb-chording (SHIFT + SPECIAL) and programming layer. 7 years ago
Stephen Tudor f2459997ba Add smt keymap for KBD75 7 years ago
adiabatic 9f0aac22e9 zweihander: rename, ⌃ → ⌥, README revamp (#2311)
* zweihander-osx: Remove app keys, etc.

- add right command keys
- add F16 on ;' for Siri
- remove command-Q (too easy to hit)

* Rename zweihander-osx to zweihander-macos

zweihander-macos: / / ^ → / / ⌥; README revamp

zweihander: rename, ⌃ → ⌥, README revamp
7 years ago
Brosseau Valentin 3cf752f83f Xd75 : Bépo layout for the XD75 (#2166)
* Add xd75 layout

* Add Readme

* Update layout

* Remove Backlight keys

* Move ENTER / BACKSP / DEL

* Commit my bepo layout instead of the qwerty version since i will not use it

* Use 0 instead of 00

* Fix TODO key

* Update the readme

* Replace wrong key placment

* Update center column

* Update the layout with 2-u key

* Adjust the fn layer

* Adjust the main layer

* Adjust the fn layer
7 years ago
Christian Richter 087fa37b7a Added us based keyboard layout with cursor keys and mouse functionality for SATAN GH60 (#2180)
* Add chaser keymap

* Added missing readme

* Add missing mousewheel und mousebutton 3
7 years ago
Daniel Shields 4a04c7265e Replace custom tap dance keys with mod tap keys in planck/keymaps/dshields 7 years ago
Chris Lee 9584db055b Add support for key backlighting to bfake
If BACKLIGHT_ENABLE is set to `yes` in `rules.mk`, then the user
can use the `BL_*` keycodes to adjust the backlight. At the moment,
only on/off is supported.
7 years ago
Koen Klinkers 38ab86e8f2 updated xd75 layout (#2321)
* plank layout

* ergodone

* x75

* readmes

* added rgb controls

* bslash

* added backlighting based on layer/modifier

* changed colors
7 years ago
Oryhara 7636fdbbd0 Halfkey function for every layer (#2327)
* started work on halfkeyboard

* update to keymap

* halfkey layouts complete for dvorak and qwerty

* added plover layout to halfkeyboard mapping

* fixed error in dvorak layout right hand

* fixed error in dvorak layout right hand, comments updated

* thing

* added minus and equals to normal layouts

* added minus and equals to normal layouts

* adde visualizer matching halfkeyboard mappings

* adde visualizer matching halfkeyboard mappings

* updated keymaps for mirror handedness functionality for all layers.  Also added visualizer code for distinct color for each layer, and LCD text displaying the current layer.

* had a KC_TILD where should have had KC_GRAV

* its spelled KC_GRAVE
7 years ago
Null cee0a33396 added my layout (#2326)
* added my layout

basically just default with proper arrow-keys

* fixed arrow keys now works properly
7 years ago
Mitchell van Manen ee0a2b7dab Imperial Match (Darth Vader's Theme) added
crappy recording: https://clyp.it/0lufqils
7 years ago
Michael Kaylan 91c133f4e0 Add missing parenthesis back to backlight_tick 7 years ago
LEdiodes b0805e38b9 added ATOM47 (Vortex Core QMK powered PCB) & DZ60 Custom config(LEdiodes) (#2310)
* added ATOM47 (Vortex Core QMK powered PCB)

* fixed broken\unfinished comment block

* moved Layer template to default template.

* moved Layer template to default template and removed template from the keymap.c file.

* Added LEdiodes config

* created readme.md

contains an image of 60% board(LEdiodes).

* updated readme.md with images

added images of the PCB and some feature details from https://geekhack.org/index.php?topic=93447.msg2545221#msg2545221

* removed excess words.

* followed the readme template to a T.

* formatting fix : added a return.
7 years ago
sanosis 2480e5d69a Support for YMDK NP21 (#2316)
* ymdk_np21 initial support

Base support of ymdk_np21 - based on jj40. Full grid layout

* Update README.md

Replacing description.

* Adding YMDK NP21 to comunity list.

Adding YMDK NP21 to community supported list.
7 years ago
sanosis 056ecb1463 Adding jj40 to keyboard list (#2315)
* Adding jj40 to keyboard list

Adding jj40 to Community-supported list.

* Update readme.md
7 years ago
skullydazed 9bfaf66792
Always copy the firmware file to the root qmk_firmware directory (#2314)
* Always copy the firmware file to the root qmk_firmware directory

* remove circular dependency
7 years ago
Sam Perman f0f991dd89 update sed to work on mac
See https://stackoverflow.com/questions/19456518/invalid-command-code-despite-escaping-periods-using-sed
7 years ago
MakotoKurauchi bceffdefca Add helix keyboard (#2308)
* Fork from Let's Split

* Organizing files

* Delete some keymaps

* I2C and serial enabled at the same time

* Change readme

* add #define HELIX_ROWS for multiple rows

* Delete avrdude flashing script

* Delete makefiles

* Subproject elimination

* Fix lufa path

* Remove PLAY_NOTE_ARRAY usages to get rid of warning.

Fix conflicting function name

* Mousekey change default to off

* Fix to oled display adjust

* make rev2

change pin assign
change keymap

* use master_buffer

* Timing adjustment

* Organizing files

* Change Keymap

* Change Keymap

Add EISU and KANA
Correct 4rows

* NKRO default to disable

* EXTRAKEY_ENABLE default to disable

* add rgb reset key

* rgb custom function enable

*  Extend font

* add RGBLED_POWER

default folder to helix/rev2
RGB_ENABLE to no

* renamed directory

* Disable RGBLIGHT_CUSTOM_DRIVER

* Disable LOCKING_SUPPORT_ENABLE

* Update bootloader setting

* Change readme

* Fixed argument error
7 years ago
Gabriel Rauter 86225ccc9b katana60: fix bootloader size to work with PCB
Fix the bootloader size so the `RESET` key actually resets to the
bootloader instead of just restarting the boards.
7 years ago
Mason McAllaster 13d288116f Adding personal keymap for planck/niu_mini (#2263)
* Adding mason keymap for planck/niu_mini

* Adding power shortcut
7 years ago
manofinterests a9bbf9ee5c hi there friends 7 years ago
na7thana ed659aa3a8 Hi there :) (#2273) 7 years ago
Alex Vogel b9b67e9614 [Keymap] semi-ISO Spanish HHKB Keymap for Satan Keyboards (#2290)
* ISO HHKB first commit

* First version of my HHKB ISO Spanish Keymap

* Readme.md

* Added more media keys.
Caps Lock added on function layer.
Backlight toggle added on funtion layer.

* RGB support for WS2812B RGB led strip

* RGB and brightness control.
7 years ago
Greizgh 35b44ac699 Fix compilation error when RGB light is disabled 7 years ago
TerryMathews 61d851af65 Add SSD1306 OLED display support to TKC1800 (#2293)
* Add support for SSD1306 OLED display

* Correct keymap

Had tilde on keymap instead of grave, corrected.

* Winkeyless keymap
7 years ago
allo-world 7c3d2d5f64 Added KBD66 (#2292)
* Created default layout for KBD66.

* Added KBD66 ISO layout.
7 years ago
Thomas Järvstrand d837ab586a Make new_project.sh a bit more robust 7 years ago
Danny Nguyen 9a91b42e92 Add Chocopad keyboard 7 years ago
Danny Nguyen c73514a2b7 Update pinout for Rev. 1.0 Iris without LED 7 years ago
Joe DeVivo ac642de9d7 Iris send backlight info over i2c 7 years ago
U-LANDSRAAD\drashna 7d8a20b07f Disable MIDI on Planck so all revisions compile without compilition size errors 7 years ago
Fred Sundvik 894fa0902f Enable FPU on Clueboard60 7 years ago
Fred Sundvik a14d539ad6 Revert back to normal sleeping wait behaviour for STM32 7 years ago
Fred Sundvik 510a8d3339 Fix compiler settings for MCUs with floating point 7 years ago
skullY 2018df1a61 Clarify the format for layout names 7 years ago
Kenneth Aloysius 365b863578 Backlighting for JJ40 and underglow initialisation code (#2260)
* Cleanup Mechmini keymap. Once the custom RGB function is defined, there is no need to manually handle RGB code.

* Change default to KEYMAP_MIT, not KEYMAP_OFFSET

* Add custom RGB code for JJ40

* Reset Mechmini advertised power draw to 500. Will have to test actual maximum power draw later.

* RGB working on JJ40.

* Fix: saturation increase/decrease flipped

* Add new directory for my custom keymap with RGB keycodes

* Swap LAlt and LGUI

* Update JJ40 max power draw with measured value

* Update: fun40 rules.mk to enable underglow; earlier failed Travis CI

* Fix: init RGB LEDs on boot. Also added HHKB-like keymap for XD60.

* Super rudimentary backlight test, init RGB LEDs on boot

* Backlighting works - stays on for now

* Toggling working

* Now can override backlight.c functions. Problem was functions in backlight.c weren't called before due to a lack of matrix_scan_quantum() in matrix.c

* Timers not working

* Delete global.h

* Cleanup

* Compiles

* Good sign: LEDs stop working again

* Handle timer1 overflow

* Progress: fix: forgot to init

* Backlighting fully working now except breathing.

* Revert keymap to original keycodes

* Update XD60 keymap README

* Update JJ40 keymap with backlight toggles

* Breathing working just fine.

* Update references

* Add backlight_set() call

* Cleanup code to disable backlight

* Fix: does not compile

* Fix: missing call to rgblight_task.

* Testing with BACKLIGHT_BREATHING

* Cleanup

* Cleanup comments

* More commenting cleanup.

* Do not enable BACKLIGHT_BREATHING by default
7 years ago
amanda flagg 5b22ddf526 add dz60 map with arrow keys (#2270) 7 years ago
stephengrier c776c1ce82 Adding stephengrier keymap for the tada68 keyboard. (#2269) 7 years ago
Drashna Jaelre ccaacde4d6 Update to drashna keymaps (#2281)
* Move faux clicky into userspace

* Get Audio and RGB enabled on Orthodox-rev1

* Add faux click to userspace

* Add Orthodox Rev3 check to macros

* Hack Orthodox Name for drashna keymap

* No more One Shots

* Ergodox product name hack

* Enable Audio on Orthodox by default
7 years ago
skullydazed 5836d1a06a Fix up the ARM audio support (#2136)
* Get audio working on clueboard/60

* add keys for music mode

* Change doubles to floats

* add keys for all the songs

* revert to the default startup sound

* Remove music mode until we can figure out why it crashes
7 years ago
manofinterests fd359e23e8 Update info.json 7 years ago
Jack Humbert 4aef0318aa
Update info.json 7 years ago
Marco Scannadinari 8209304904 Reset color after submodule warning message
Fixes leaking bold text
7 years ago
noisebomb44 6bbe2366ec Update ergodone.c 7 years ago
Kaleb Elwert 3be81a2daf Fix call to memset for various keyboards 7 years ago
chancellorr 586a5e8d1d Adding my Tada68 Keymap. 7 years ago
Daniel Gordon 383a3c1e08 Add Daniel Gordon's Ergodox Infinity and Chimera
* gordon.c defines many aliases for KC codes.
   * gordon.c defines many advanced tap dance functions.
   * This is a squashed commit of about 6 months of work on chimera and
     ergodox infinity changes.
   * Ignore the change-id below.

Change-Id: I83927139e8a80fe08992ae91ec7d62571498f7f7
7 years ago
Mikkel Jeppesen e2352d4fbf Updated files to better support sockets version (#2255) 7 years ago
Mason McAllaster 3a2acd4475 Updating default niu mini keymap to better reflect product 7 years ago
Kyle Sargent ee15d2fe5e Layout for BananaSplit60 (#2257)
* Kamon bananasplit layout

* readme
7 years ago
pmalecka a01dc4dd48 added the possibility to hav shifted(modded) tap dance 7 years ago
fauxpark 4764e77121 Clarify that we actually have max 16 total backlight levels 7 years ago
fauxpark cfcf0fd36b Remove reference to BL_x in keycodes.md, and add BL_BRTG 7 years ago
Oryhara dcb2627237 Halfkeyboard functionality for dvorak and qwerty (#2261)
* started work on halfkeyboard

* update to keymap

* halfkey layouts complete for dvorak and qwerty
7 years ago
Danny Nguyen fe8942e55c Add -e to enable interpretation of escape characters 7 years ago
farmakon 8e0d9e2637 Adding XMMX (#2236)
* gh80_3000

* Add files via upload
7 years ago
Jack Humbert 81ae0fb10e
Update info.json 7 years ago
Jack Humbert e659bc4467
Info json fixes (#2232)
* Update info.json

* Update info.json

* Update info.json

* Update info.json
7 years ago
Jack Humbert e3541853a9
Update info.json 7 years ago
Jack Humbert 0ea6cf719e
Update info.json 7 years ago
Hannes Egler c9d23f50f6 Added RGB and in-switch LED controls (#2227)
* Default layout with RGB and in-switch LED controls

This is a variation of the default keymap with added RGB underglow and in-switch LED controls.

* Readme for default_rgb keymap

* ISO keymap with RGB and in-switch LED controls

This is a variation of the default ISO keymap with added RGB Underglow and in-switch LED controls.

* readme for iso_rgb keymap
7 years ago
rooski15 c5c35f5f4b Rooski15: Update Prime_R ReadMe & Keymap (#2228)
* Rooski15: Updated prime_r Keymaps

* Rooski15: Updated Prime_R:Rooski

* Rooski15: Updated Prime_R readme

* Rooski15: Updated Prime_R readme

* Rooski15: Updated Prime_R readme
7 years ago
TurboMech 6b584a23c0 Updated ACR60, Mechmini, ALU84 readme information and config.h descripters (#2231)
* Updated ACR60, Mechmini, ALU84 readme information and config.h descripters

Update MECHKEYS keyboards to be uniform in readmes and config.h's PID, MANUFACTORER, and DESCRIPTIONS.   This allows the keyboards to be more uniform amongst the different types.

* Rename keyboards/alu84/keymaps/TurboMech/config.h to keyboards/alu84/keymaps/turbomech

* Rename keyboards/alu84/keymaps/turbomech to keyboards/alu84/keymaps/TurboMech/config.h

* Fixed folder naming for alu84/keymaps/turbomech

* fixed error from compile

removed double `return MACRO_NONE;` and `switch (id) {`
7 years ago
rooski15 6bb3fbd4e0 Prime_R (#2221)
* Rooski15: Add Prime_R Keyboard

* Rooski15: Added keymaps to xd60, xd75, planck, and prime_r

* Rooski15: Updated prime_r keymap

* Rooski15: Added Prime_R and Documentation

* Rooski15: Added Prime_R and Documentation

* Rooski15: Prime_R - Added futher documentation.

* Update config.h

Added device information

* Update readme.md

Updated Planck:EmilyH Readme

* Update readme.md

Updated XD75:EmilyH Readme
7 years ago
profanum429 9e0b244a34 profanum429@gmail.com (#2222)
* Added initial in-switch LED support for the Eagle/Viper V2.
Currently only has four modes: All ON, Mods/Nums ON, Alphas ON, or All OFF

* Revert keymap changes

* Changed switch curly bracket to match style.
7 years ago
Daniel Gordon 4b7fcf0af0 Add info.json file for Chimera Ortho (#2217)
* Add info.json file for Chimera Ortho

* Correct LAYOUT to KEYMAP 

Correct LAYOUT to KEYMAP in chimera ortho's json.info
7 years ago
MechMerlin 22b9303e2a Keeb json layouts (#2219)
* info.json committed to support the qmk configurator project

These are info.json for each of the keyboards I've contributed to
during my time here at QMK

* change LAYOUT to KEYMAP to adhere to matrix definitions
7 years ago
skullY e956c11bc9 Update the urls for atmel tools 7 years ago
MechMerlin cbc5de67be Duck Eagle/Viper V2 support (#2216)
* Preliminary support for Duck Eagle/Viper V2 60% board. This is a copy of the octagon/v2 with things changed to reach a compiling state

* Get a 60% keymap compiling, this might not be what the eagle/viper
really supports

* Update readme to point to correct GeekHack link

* Get keymap working on a Duck Eagle

* Add code submitted by profanum429

- Add HHKB style top row to v2.h
- Modify read_rows function to take into accout the caps lock firmware key
- Modify default keymap to match the new v2.h
- Adjust readmes

* Fix bug related to col 0 not working

* Add keymap for mechmerlin

* Add profanum429's viper hhkb layout

* Add visual representation for mechmerlin layout
Add navigation keys to keymap

* Add a better visual representation to the mechmerlin keymap

* Add profanum429's Viper layout!

* Updated profanum429 keymap to match a full HHKB
Enabled media keys in rules.mk

* Revert "Updated profanum429 keymap to match a full HHKB"

This reverts commit ed914160d7e27e6412d2c7c5c1c4fa0a04838667.

* Fix default keymap for Eagle

* Enable extra keys for audio control support

* Modified timings in indicator_leds to accomodate the WS2811S chips on the Eagle/Viper2 PCBs at 800kHz with a 16mHz clock
Modified the backlight settings to not interfere with the default RGB underglow code from QMK
Modified the order of the LEDs in the LED status bar at the top of the Eagle/Viper2 PCBs (3,2,1,6,5,4,8,7 order)

* Cleaned up indicator code to remove unused functions as the RGB underglow uses the
default driver provided by QMK

Commented out backlighting code in v2.c

* update readmes to reflect profanum's awesome contributions and fix typo in make instructions

* Remove custom RGB logic and just rely on QMK RGB underglow. We'll leave the backlighting in place for now
7 years ago
TurboMech 9cb1d36974 Added Mechmini 2.0 to Mechmini keyboard folder
This creates a v1 and v2 subproject.  V1 retains all the same implementations of the bootmapper-ported Mechmnini 1 including #2196.  V2 adds the Mechmini 2.0 kayboard support (I know it took me way to long to get it a pull request in).

All readme's updated to reflect compiling the two seperate keyboards.  Simply either `make mechmini/v1:default` or `make mechmini/v2:defualt`.  Utilizing the rules.mk using `make mechmini:default` will automatically create the Mechmini 2 default keymap as this is the current version and has a much wider user base.
7 years ago
Rickard von Essen 0a5d302622 Let's Split: Minor fixes in keymap.c comments
- Single quote (') is the un-shifted key, not double quote (")
- Fixed alignment
7 years ago
YouCanFly 6c24e28b8d ADD RGBLIGHT_LIMIT_VAL (#2214) 7 years ago
Jack Humbert d19805f9de
update avr url 7 years ago
Rickard von Essen 4beb5e72f8 macOS also requires avrdude 7 years ago
Stacy Devino 5f0a2e078f JC65 - Adding in CapsLock LED support and my personal keymap
Signed-off-by: Stacy Devino <stacydevino@gmail.com>
7 years ago
benlyall feac994f6f Added support for V60 Type R Polestar backlight and RGB underglow (#1852)
* Added V60 Type R Polestar Backlight and RGB Underglow support

* made RGB Underglow stuff optional, to support the non Polestar V60

* updated readme and rules

* fixed typo in readme
7 years ago
Balz Guenat 4931510ad3 backlight breathing overhaul (#2187)
* add breathing to bananasplit

* backlight breathing overhaul

* fix the backlight_tick thing.

* fix for vision_division backlight

* fix a few keymaps and probably break breathing for some weirdly set-up boards.

* remove BL_x keycodes because they made unreasonable assumptions

* some fixes for BL keycodes

* integer cie lightness scaling

* use cie lightness for non-breathing backlight and make breathing able to reach true max brightness
7 years ago
John Ramsay d6215ad6af Aviator Keymap (#2204)
* Create aviator.txt

* Add files via upload

* Delete aviator.txt

* Delete readme.md

* Add files via upload

* Update readme.md

* Update readme.md

* Delete keyboard-layout.png

* Update readme.md

* Update readme.md

* Update readme.md
7 years ago
Kenneth Aloysius eba4cb7a04 RGB underglow support for JJ40, clean up redundant code in Mechmini keymap (#2196)
* Cleanup Mechmini keymap. Once the custom RGB function is defined, there is no need to manually handle RGB code.

* Change default to KEYMAP_MIT, not KEYMAP_OFFSET

* Add custom RGB code for JJ40

* Reset Mechmini advertised power draw to 500. Will have to test actual maximum power draw later.

* RGB working on JJ40.

* Fix: saturation increase/decrease flipped

* Add new directory for my custom keymap with RGB keycodes

* Swap LAlt and LGUI

* Update JJ40 max power draw with measured value

* Update: fun40 rules.mk to enable underglow; earlier failed Travis CI
7 years ago
James Neill 85ea963931 Remove residual Makefiles from the keyboards directory (#2193)
* Removed residual Makefiles from keyboards directory

* Removed reference to Makefile
7 years ago
wanleg 492a16308a wanleg's gherkin layout
my layout for the Gherkin
7 years ago
Drashna Jaelre 17200f4712 Clean up and tweaks of drashna keymaps and userspace (#2200)
* Minor tweaks

	modified:   users/drashna/drashna.c

* Fix Workman ASCII art

* Add OSM for shifts

* Make Viterbi's 00 code consistant

* Minor Cleanup off Userspace

* Change Tapping Term on Ergodox

* Re-add EEPROM code

* Minor updates and tweaks

* Use QMK_H variables to make keymaps more universal

* Forgot 'break;' for covecube layer

* Tweak Viterbi files now that I have hands on

* Add secrets to Ergodox

* RGB tweaks to Viterbi

* Viterbi RGB layout tweeks

* Minor tweaks

* Add One Shot Mod tap toggle

* Add Faux Clicky to Viterbi, and disable controller's LEDs

* Minor tweaks

* Move D3 keycode defines into userspace

* Updated Userspace Readme
7 years ago
Takahiro Miyamoto eb903c7623 Add meira/takmiya keymap 7 years ago
Hannes Egler c58921c64c KBD75 ISO support (#2201)
* iso_de_mac

ISO-DE layout with mac media controls

* Delete keymap.c

* iso_de_mac

ISO-DE support with Mac media keys

* Add files via upload

Layout overview

* iso layout support

Adds support for the extra key of ISO

* Update keymap.c

typo-fix

* fixed mac next key

* Delete Layout.png

* Delete keymap.c
7 years ago
Mikkel Jeppesen 9fc3e26f70 Fix of #2094 7 years ago
TurboMech e9f44ee96d added ALU84 keyboard and TurboMech user space (#2206)
* Added ALU84

Added ALU84 from mechkeys.ca.  TurboMech keymap is MacOS oriented, need to still update the defualt keymap.

* added alu84 and TurboMech userspace

* updated keymap, config.h and rules.mk for alu84
7 years ago
skullY 9cb80d68e2 Add the missing rules.mk for my layout 7 years ago
skullY 4932f9566a capslock led fix for clueboard 60 7 years ago
Colin Miller 97c6b8143c Adding a Zelda Treasure sound.
It's the sound that's made when opening a treasure chest.
7 years ago
Ryan Mitchell 3b9e4967b8 fix breaking build: remove merge conflict text 7 years ago
adiabatic 7c57104b51 Zweihander: remove app keys, etc. (#2167)
* zweihander-osx: Remove app keys, etc.

- add right command keys
- add F16 on ;' for Siri
- remove command-Q (too easy to hit)

* Zweihander: update readme
7 years ago
Oscillope 846598541b Oscillope keymap: handy programming macros (#2176)
* Added macro to type -> since that symbol requres much finger acrobatics otherwise.

* Added macros for braces
7 years ago
MechMerlin c68597d9ad Octagon V1 Support (Port) (#2184)
* Preliminary commit for Octagon V1 support

This is essentially a cp -R v2 v1 with a few things changed to
get it to compile and build.

* The Octagon V1 supports up to 84 keys as opposed to the V2 which
supports up to 86. This commit changes the keymap to match it.

* Temporary default keymap just to get things to compile

* Update readme file

* Fix switch matrix

* Fix underglow lighting option

* Fix keymap to take care of shifted columns

* Fix keymap formatting

* Remove un-needed files left over from rasmusx

* Make Octagon V1 have its own keymap directory with default keymap

* Make Octagon V2 have its own keymap directory with default keymap

* Cleanups and readme edits
7 years ago
U-LANDSRAAD\drashna 5ffec5d9b0 Disable MIDI on preonic to fix firmware compilation errors 7 years ago
Nicolas Guelpa a8eaf0b666 Adding pok3r like layout to the let's split (#2135)
* adding new layout for the planck that helps when coming from the pok3r

* Fixing the function layer

* Update readme.md

* Update keymap.c

Making some small adjustments

* Update keymap.c

switching GUI and Esc

* Update keymap.c

* adding mod tap on left and right shift

* adding mod tap on left and right shift

* poker keymap for lets split

* fixing the FN layer

* removing unused file
7 years ago
Drashna Jael're 4f484bc1c9 Add on/off/toggle keycodes for Auto Shift 7 years ago
U-LANDSRAAD\drashna a1fa70f94d Add toggle option to AutoShift 7 years ago
Hugo Gayosso d8f0faabda Fixed typo 7 years ago
Kaleb Elwert 818042b2c3 k_type: add belak keymap 7 years ago
Jason Rosenman 8910f9b87e Marked util/atmega32a_program.py as executable so that programming script works. 7 years ago
MechMerlin 9dd3e08fdd Octagon V2 Refactor (#2170)
* rename octagon_v2 directory to octagon directory

* Move octagon_v2 files to v2 sub-directory

* Edit readme files

* setup header files for building multiple versions of the Duck
Octagon.

* Changes as per Jack's PR 2170 comments
7 years ago
fauxpark b3bcafcc4b Unsign key argument in add_key_to_report 7 years ago
Arda Kılıçdağı b8f08d936d Added Ardakilic keymap for Tada68 (#2174)
* Added Ardakilic keymap

more key fixes

* power key instead of eject
7 years ago
kimkimkeren dd37245373 Custom Keymaps for Certain Layouts (#2161)
* Add keymap for my friend's KBD75\nBug : RGUI is read as RALT

* Add keymap for Nyquist

* Add Keymap for Whitefox (Truefox layout only)

* Add Keymap for XD75 and XD73 (XD75 with 1u blocker each on left and right bottom
7 years ago
kamisamamizu eab41f7b38 Added default case to process_record_user
I tried using process_record_user and if I had to add the default case for it to compile.
7 years ago
Vlad Buslov cca3dcc5ec Add my keymap for dz60 7 years ago
kamisamamizu 12e66330c5 Add COSPAD to QMK and add functions to read HSV (#2156)
* Added functions to read HSV values

I have added three functions to rgb_light.c to be able to read the hue, saturation and value from other places.
They are rgblight_get_hue(), rgblight_get_sat(), adn rgblight_get_val().

* Create keymap.c

* Add COSPAD support to QMK

I have ported the COSPAD numpad to qmk.

* Update readme.md

* Update cospad.c
7 years ago
That-Canadian d91c9858c5 Christmas tree (#2160)
* Line ending stuff again

* Added initial files for Christmas Tree PCB

* Updated Readme and info json's, also config.

* Cleaned up keymap file, added proper comments for keymap. Removed readme leftover from original copy of planck folder structure.

* Forgot to push rules.mk for the V2017 folder, fixed now.
7 years ago
U-LANDSRAAD\drashna 8a0997709b Remove MIDI from Planck Rev5 to fix compile build size issue 7 years ago
Jack Humbert 0e1a731446
Update readme.md 7 years ago
Jack Humbert 57ef8a54e4
deletes the extra mechmini readme [doh] 7 years ago
root 1add90a6d2 reforked master and added changes to 7u and 6u iso layouts 7 years ago
Budi Dharmawan e4230c84d0 [budi] tv44 arrow dvorak (#2151)
* [budi] tv44 arrow dvorak

* [tv44/budi] Removed qwerty, added readme
7 years ago
mechmerlin 1485cc1d26 Found some broken links while looking up ARM keyboard support 7 years ago
Colin T.A. Gray 4ea3bbdb4c add tests for action_layer.c and reset layer state after tests 7 years ago
Colin T.A. Gray bad839e6ac make 'layer_state_set' visible to user code 7 years ago
Colin T.A. Gray 3aec9a4354 fixes 'layer_state_cmp' when layer is '1' (aka layer 0, aka layer 1<<0) 7 years ago
MechMerlin 163ddd5d15 Duck Octagon V2 QMK Support (#2153)
* Initial commit for Octagon V2 Support

This is still basically just a copy of lightsaver support with
names changed.

* Port xauser keymap from: https://github.com/xauser/tmk_keyboard/blob/xauser/keyboard/octagon_v2/keymap_common.h

* Temporary default keymap just to get things compiling

* Modify config.h to have the right keyboard info

* Partial port of xauser matrix code for octagon v2

* Fix readme.md
1. Fix link to geekhack GB
2. Add microchips
3. Add appropriate attributions

* Fix PORTD

* Intermediate fix to get LEDs working

* Update BACKLIGHT_AREAS enum

* Port the following:
backlight_set
backlight_toggle_rgb
backlight_set_rgb

and resolve dependencies in header files

* Port backlight_update_state to led_set_kb

* Change copyright notice author to MechMerlin

* Remove Rasmus keymap

* Get a default keymap that actually does something and let's you reset.

* Convert keymap into KC_XXXX format.

* Better formatting of the default keymap to make it more readable

* Fix keymap

* Get that Fn key working!

* Some code cleanup and small refactor

* Fix keymap in octagon_v2.h
7 years ago
Josh Sankey dc7cc26dff Christmas tree (#2105)
* Line ending stuff again

* Added initial files for Christmas Tree PCB

* Updated Readme and info json's, also config.

* Cleaned up keymap file, added proper comments for keymap. Removed readme leftover from original copy of planck folder structure.
7 years ago
JWhy a6e46b99b9 Fix reset key in Iris default keymap 7 years ago
Kaleb Elwert ab197af2ea Initial K-Type support (#1963)
* Initial K-Type support

* Copy PJRC_TEENSY_3_1 to work around watchdog issues

* K-Type: Remove bootloader offset in rules.mk

* Ensure matrix and scan quantum functions are called when needed

This is porting a fix from f5422a70b6
7 years ago
Jean Olivier Simoneau 1226c69f4f Adding my xd60 layout. (#2078)
* Added xd60:Jos keymap

* Corrected Layout image for xd60:Jos layout

* Update README for xd60:Jos layout

* Created rules.mk for xd60:Jos layout

* Fixed an edge case for xd60:Jos layout

* Now using a specific  for xd60:Jos layout instead of modifying the main one

* Better physical layout image for xd60:Jos layout
7 years ago
Zach Richard 8a1e656099 new planck keymap, new feature - hybrid shift/enter action key (great for small keyboards!) (#2100)
* new planck keymap, new feature - hybrid shift/enter action key (great for small keyboards!)

* corrected documentation to specify rules.mk file instead of Makefile
7 years ago
Jon Nelson 56f266173c Adding my personal keymap (#2116)
* my personal keymap

* Add files via upload

* Delete baseLayer.JPG

* Delete fnLayer.JPG

* Update readme.md

* Update readme.md

* Update readme.md

* Update readme.md

* Update readme.md
7 years ago
Cole Markham 2dfdafbd5b Update '?=' references in rules.mk. Add support for ortho_4x12 layout. 7 years ago
Cole Markham 5fe0fe3756 Fix keyboard not working if I2C pullups not enabled.
Disable backlighting by default.
7 years ago
Cole Markham cc0d4b6513 Cleanup old code and comments 7 years ago
Drashna Jael're 23b1889241 Update revision default 7 years ago
Drashna Jael're 6cd001e337 Fixed orthodox KEYMAP so no londer requires blanks in keymap.c, and added orthodox rev3 7 years ago
Koen Klinkers e4f26a9fcc Personal layout planck,ergodone,xd75 (#2140)
* plank layout

* ergodone

* x75

* readmes
7 years ago
mkende 9cda36238f Add a keymap for the Ergodox EZ meant to be used with a Bépo keyboard layout (French ergonomic layout) (#2141)
* Initial version of the Ergodox EZ Bépo keymap, TypeMatrix style.

* Update the readme file and add some handling of the keyboard LEDs.

* Toggling layer requires 2 taps.

* Remove a constant as it conflicts with an earier definition.

* Fix a typo in a type name.

* Fix the arrow layer that had a bad number.

* Second main version of my bepo keymap, after the tests of the first one.

* Fix the triggering of the function layer and the handling of the LED.

* Reduce the shining of the LEDs.

* Fix the swap layer (that required a keypress on the other side of the keyboard to be deactivated).

* Duplicate some of the mouse button for easy access.

* Move some of the secondary functions out of the center keys.

* Slightly slow down the mouse and mouse wheel.

* Update the comment and readme.md for the V2 of the keymap.

* Invert button 2 and 3 of the mouse. Really fix the SWAP layer.

* Test with the right alt modifier added as secondary function (on hold) of the space keys. The right alt key becomes a left alt one.

* Add specific shift/ctrl for the FN layer; move some mouse keys around to help with that.

* Remove one FN modifier-on-hold key that was not useful.

* Duplicate the FN layer inside the MOUSE layer.

* Add support (not tested yet) for macro recording and play on a single key as a tap dance.

* Allow to stop recording the macro by tapping once on the macro key (still un-tested).

* Add support for macro recording using some tap dance.

* shorten a comment.

* Reinstate the FN toggle on the percent key (so that there is an FN toggle on the right-hand-side).

* Fix some comments and update the link to the most up-to-date image.

* Small fix to the keymap images.
7 years ago
kristmascane 52630f6611 adds @kristmascane's keymap (#2144) 7 years ago
Drashna Jaelre 2ec1ab2b35 Update Drashna keymaps (#2145)
* Change overwatch to Gamepad

* Remove secrets file

* Add sample sensitive.h file

* Borrow @colinta's secrets.h include method

* Remove unnessary placeholder for macros

* Set secrets to use PROGMEM for char string

* Add readme files to my keymaps and userspace
7 years ago
Nico Hormazábal 557745ba9f Updated keymap and readme (#2147)
* added own keymap for planck

* Update Readme.md

* Update Readme.md

* Update Readme.md

* Update Readme.md

* Update Readme.md

* dynamic macros

* Update Readme.md

* moved the reset button

* Update readme for volume explanation

* Format

* Update Readme.md

* Update Readme.md

* added safe double shift

* changed the modified shift to regular shift, for allowing shift + F keys
7 years ago
bunnybugslpat f229d22416 added iso support
added a keymap for an iso layout with 7u spacebar
7 years ago
Benny Powers 98ac32b417 Vim Layout for Ergodox-EZ (mac only) (#2112)
* ignore libs

* Clang complete file

* Add VIM_A, VIM_S, VIM_COMMAND_SHIFT_D, and VIM_COMMAND_SHIFT_A

Add VIM_A, VIM_S, VIM_COMMAND_SHIFT_D, and VIM_COMMAND_SHIFT_A

a s O

* Comment blocks for minimap

generated at
http://patorjk.com/software/taag/#p=display&h=0&v=0&c=c&f=Banner&t=COMMENT

* Be explicit

* More Comment blocks

* Add J

* add A, C, D, J, S, O

* Make h j k l explicitly vim commands (useful for JOIN)

* add cb ce cw ch cj ck cl db de dw dh dj dk dl vb ve vh vj vk vl x ciw diw viw

* debug messages for ci di vi

* Var capitalized

* Save bytes by disabling mouse keys

* Add Y P

* Be more explicit about which key was pressed

* Be more explicit about which key was sent

* Move project to new directory structure

* Remove non-vim layout folder

* Replace KC_TRNS with KC_NO on normal layer

* Insert Mode as default

* Try to prevent crashes

* Put normal mode back

* Revert "ignore libs"

This reverts commit 4c5d7592d6c1b70e689c0b9400afca19c71970a7.

* add rules.mk

* Add mouse bindings

* Checkout most recent keymap following rebase

* Realign mouse button keys

* Make a macro for TO(NORMAL_MODE)
7 years ago
Balz Guenat eeb6443767 actuation point adjustment for fc980c and fc660c (#2134)
* add i2c lib submodule

* add actuation point adjustment to fc980c

* add actuation point adjustment to fc660c also.

* use https for i2c submodule

* move to existing i2c lib

* properly remove old submodule

* oops, forgot some files for the fc660c
7 years ago
That-Canadian c1a6ca46a7 The ruler (#2138)
* Line ending stuff again

* Added initital files and layout for the PCB Ruler keyboard/macro pad thing

* Updated Readme

* Changed make command to new format
7 years ago
Rasmus Schults 7c5428b56d Add rasmus keymap and fix default keymap readme 7 years ago
farmakon d9983082c2 adds the gh80_3000 project (#2132) 7 years ago
Rasmus Schults 41d5d3e655 Add Lightsaver V3 keyboard 7 years ago
Jack Humbert e6b91549e3 fixes audio/midi combinations 7 years ago
Jack Humbert 58898f77e3 fixes midi compile error 7 years ago
Jack Humbert c2f4c4e29e update planck settings 7 years ago
Jack Humbert a7c61f2947 fix up midi stuff w/music mode 7 years ago
Seebs d1feb8744a Don't "unselect" left-hand rows
"unselecting" left-hand rows is a wasted i2c transaction.

On the left-hand side, the ergodox uses a GPIO expander. It
does *not* change "direction" (input/output) of pins, it just
sets pins high or low.

But all the pins are written at once. There's no way to
change just one pin's value; you send a full byte of all eight
row pins. (Not all of them are in use, but that doesn't matter.)
So every pin is either +V or ground. This is in contrast
with the right-hand side, which is using input mode to make pins
be neutral.

So there's no need to "deselect" the rows on the left side
at all. To select row 0, you set the GPIO register for the
rows to 0xFE. The previous code would then set it back to
0xFF, then set it to 0xFD on the next cycle. But we can just
omit the intervening step, and set it to 0xFD next cycle,
and get the same results.

And yes, I tested that the keyboard still works.

On my system, scan rate as reported by DEBUG_SCAN_RATE goes
from 445 or so to 579 or so, thus, from ~2.24ms to ~1.73ms.

Signed-off-by: seebs <seebs@seebs.net>
7 years ago
Balz Guenat 6d1b45fb84 change the ?= assignments to = 7 years ago
Balz Guenat 2c2e103457 some planck keymap shiftings and include proper-making 7 years ago
Balz Guenat 7235c93827 clean up bananasplit keymap 7 years ago
fauxpark bb53635f33 Trim trailing whitespace 7 years ago
fauxpark af37bb2f78 Fix some of the more obvious typos 7 years ago
fauxpark 4c675a83ba Format keycode tables 7 years ago
fauxpark 7b0356d1d4 Convert all headings to Title Case 7 years ago
Nico Hormazábal 6eb89ae906 New Planck Layout (#2123)
* added own keymap for planck

* Update Readme.md

* Update Readme.md

* Update Readme.md

* Update Readme.md

* Update Readme.md
7 years ago
Fredric Silberberg b781cbf7e2 Turn on prevent stuck modifiers for my keymaps. 7 years ago
Cole Markham a14518bf57 Updated copyright headers and peer review fixes 7 years ago
Cole Markham f74f0ac06b Update Meira readme 7 years ago
Cole Markham a9a46adba0 Add support for Meira 7 years ago
Scott Wilson c51dfef958 Add support for LFKeyboard products: LFK78, LFK87 and SMK65 7 years ago
Balz Guenat 8b1862330a fix link for grave escape in docs 7 years ago
Martin Gondermann dc6b341cf9 Updated readme 7 years ago
Martin Gondermann 155660ff9d Updated color for base layer to better match my key caps (Dasher) 7 years ago
Gaëtan Ark 6e25220eed Pointing to the right build URL
The previous URI used to point to the Nyquist keyboard build guide.
7 years ago
Colin T.A. Gray 16546ee06f Add 'rgblight_disable' and 'rgblight_setrgb_at/rgblight_sethsv_at'
Refactors rgblight_toggle to use rgblight_enable or rgblight_disable
Use 'rgblight_setrgb_at/rgblight_sethsv_at' to control an individual LED
7 years ago
Colin T.A. Gray 1620d78e73 helper to compare current layer_state to user layer
Performs the same bit comparison that the layer_move
functions perform
7 years ago
Cosmin Cojocar fc54d62111 Add a slightly modified ordinary layout for OSX 7 years ago
andy f5422a70b6 Enable tap dance and other features for Whitefox
The custom matrix code was missing calls to matrix_*_quantum, disabling quantum features.
7 years ago
Unknown e3b3c1ef82 add do60 support 7 years ago
Jack Humbert bba871df2f move lcd_backlight_keyframes to correct location 7 years ago
Biacco42 5bbad3147c Add support for 7x4 ortholinear split KB Ergo42 7 years ago
Colin T.A. Gray 2bac7cf414 F5 pin doesn't support PWM, so breathing isn't an option 7 years ago
Colin T.A. Gray b7c76fda31 fixes case where BACKLIGHT_BREATHING is enabled, but pin doesn't support PWM 7 years ago
Drashna Jaelre d5a76e899d Updates to drashna keymaps and userspace (#2093)
* Add "secret" macor

* Updating secret macros

* Re-add RGB to Ergodox

* Fixed issue when RGB was disabled

* Consistency changes

* Updated bootloader macro

* Fixing audio setup

* Fix bootloader typo

* Update to full list of stings (for completeness)

* Template fix

* Finally got woodpad to force numlock

* Fix for new RGB mode
7 years ago
Baris Tosun dd05bf0d96 Katana60 (#2068)
* Add files via upload

* katana60 defaults, initial pull-request

* removed icons from google drive

* added simple readme files

* pull-request updates

* readme file updated

* readme file formatting

* improvements before live

* colemak readme

* updated readme files

* removed makefiles and updated readme
7 years ago
Drashna Jael're 95e68c4ae8 Fix Audio chime overrides in split keyboards 7 years ago
Colin T.A. Gray d299d0e72d adds led control functions to XD75 layout 7 years ago
Cole Markham 6fddb31c4c Add Crawlpad 2017 files. 7 years ago
Colin T.A. Gray 53b043d4ef adds 'RGB_RMOD' to go through RGB modes in reverse 7 years ago
Drashna Jaelre 7b51f050d7 Fix typo in make example
It has `:all" when it clearly is referencing the command without `:all`.
7 years ago
Harshit Goel 7730dc3e5c Magicforce68 now in bluetooth flavour (#2051)
* Added working code for mf68_ble

* update read.md

* update read.md

* update read.md

* update readme

* Update README.md

* Update README.md

* added reddit post

* Update README.md

* Update README.md
7 years ago
mmikeww 0740e84d63 update advanced_keycodes; oneshot = sticky/dead keys 7 years ago
mmikeww c917888262 update glossary; oneshot key = sticky/dead key 7 years ago
skullY 0b54e7f5ae Flesh out the grave escape overrides 7 years ago
Drashna Jaelre 8cac6088c6 Remove unnecessary audio code from orthodox (#2076)
* Remove unnecessary startup/shutdown code

* Leave functions intact

* Update rev1.c
7 years ago
khitsule 1548f4c24f Add keymap for atreus and minidox (#2079)
* keymap for atreus and minidox

* minidox keymap khitsule cleaned
7 years ago
mmikeww b9f426ae1e Fix broken link in docs
This link was broken. And the latest, live version of that keymap link doesn't line up with the docs below, so the link will now point to the older version of the file in the git history
7 years ago
Ethan Madden 52b0ad649c Modified default keymap to match ps2avrgb default 7 years ago
Tim Dierks c9d0f210bc Change awk detector to work with mawk; fixes #2073 7 years ago
Devin J. Pohly 7aaef16266 Fix internal links in docs/ (#2080)
One link in the summary (Modding your keyboard) referred to a page that
was deleted; the rest have been updated to point to the new names.
7 years ago
Drashna Jael're 28874a9f33 Fixed minor typo in bootloader code 7 years ago
Drashna Jael're 319ff649ab 16 byte optimization of macro ;) 7 years ago
Drashna Jael're 92f6d6ec02 Update Userspace info to include Bootloader detection 7 years ago
Jack Humbert 9fdc276260
Updates bootloader settings, adds file size check (#2029)
* pull fuse settings for bootloader jump

* fix 32a chips

* make automatic bootloader selection optional

* quantify bootloaders

* fixs #164, speeds up dfu reset

* fix for chips w/o usb

* missing an n

* fix bootloader sizes, use words for addresses

* fix bmini, pearl, and [[ issue, make things quiet

* ignore avr errors on arm for now

* update settings for the light

* document bootloader stuff

* add bootloader title
7 years ago
RandTrawick 9113f3387a JJ40 updates (#2056)
* my bits

* fixed
safdb

* readme

* readme

* better name, fixed compile error

* fixed matrix user

* cleanup
7 years ago
Erez Zukerman 0bd453b527
Merge pull request #2047 from seebs/seebs/ergodox_brightness
Make brightness easier to change
7 years ago
Erin Call b697e1bff3 Fix build instructions in the Dactyl readme
Reflects the changes in #1784
7 years ago
Roman Volosatovs 833ec84921 shell.nix: add teensy loader 7 years ago
TerryMathews 53ad7375c7 Initial support for TKC1800 PCB (#2062)
* Initial support for TKC1800

* Correct typo
7 years ago
Eiji Onchi 5fd400faa9 Fixed bootloader access key 7 years ago
Erin Call f2a0b0ee20 Handwired/Dactyl keyboard (#2058)
* Copy the ergodox_ez code to handwired/dactyl

Differences from the Ergodox:

* Use QMK_SUBPROJECT_H instead of QMK_KEYBOARD_H, since it's under
    handwired
* Omitted several keymaps. They'll eventually be broken (since the
    Dactyl has fewer keys), and I don't want to try to fix them.
* Omitted the keymap images for the default layout, since they depict
    a different keyboard.
* Everything that said Ergodox now says Dactyl, naturally.

* [whitespace] Delete trailing whitespace

My editor does this automatically so it's just gonna keep cropping up...

* Cut the dactyl down to the right number of columns

(Remember, throughout matrix.c, everything called "row" is really a
column, and vice-versa).

* Remove LED-related code

* Tighten up the Dactyl's build options

* Whitespace cleanup in twimaster.c

* Hardtabs -> spaces
* No more trailing whitespace

* Typo fix

* Correct the CPU frequency units

The Teensy's CPU definitely doesn't run at 16 petahertz...

* Restore access to ONEHAND_ENABLE

I turned it off in 26d47cb42622d990a7c3335e7fcc151aa3edfbf0 while
desperately debugging; I just wanted to ensure it wasn't causing the
problem I was seeing. It was not, in fact, causing the problem, so it's
back.

Also fixed the swap matrix in dactyl.c, since it still referred to
columns that exist in the Ergodox but not the Dactyl.

* Clearer phrasing about TWI's effect on scan rate

* Fix up the Dactyl's firmware-loading instructions

Sadly, the Dactyl has no hole for the onboard reset button.

* Dvorak keymap for the Dactyl

* The Erincalling Layout

* Erincalling layout: Add a := key

I've been working in Go, which uses := a lot, and it's awkward to type
in this layout.

* Dactyl README: link to the dactyl-keyboard repo

* Add a missing copyright line

I don't know how much this matters? Honestly, it's enough for me that my
name is on the git commit. But hey, let's be consistent until there's a
specific reason not to be, right?

* Dactyl: remove commented-out code

I hate it I hate it I hate it

There's not even any information about what it was trying to do!!!! >:(

* Add a note about the row/column ridiculousness

* [whitespace] realign some constants

* Don't claim B4 is tied to VCC

It doesn't matter at all? I honestly don't know what the reason ever
was. It looks like it dates back to the original ErgoDox and I've never
seen one sentence about the purpose.

I've been skipping that wire for some time, and I promise it works fine.

* Dactyl keymaps: Send RALT for right-hand alt key

Not terribly important but I just like things tidy OK

* typo fix

* Refer to "dactyl.h" explicitly

QMK_SUBPROJECT_H has been working locally, but fails in CI. Strange!

* Dactyl: Don't use QMK_SUBPROJECT_H at all

It's still breaking in CI, even though it was a never a problem locally.
7 years ago
Balz Guenat 18525aa17b Fc660c port (#2060)
* Port Hasu's FC660C controller to QMK

* fix column mask
7 years ago
Add Chan ac3d9ab761 added addcninblue's layout (#2049)
* added addcninblue's layout

* vim layer
7 years ago
Callum Oakley 2fc727c154 Keymap update (#2045)
* linux shake-around

* move terminal and browser spawning keys

* add a shift to window resizing keys to free combo up for window management

* "jump to tab" shortcuts for firefox

* change window resize modifiers

* change wm keys

* change wm keys again, and reformat keymap to 80chars

* typos

* language key

* qwerty layer for SO, general cleanup
7 years ago
shela d76cc09ed6 Update my keymap (#2042)
* fix bug

* update keymap
7 years ago
Colin T.A. Gray 2c0323bc98 Adds my XD75 layout (#2040)
* adds my xd75 layout

* add secret strings to 'secrets.h' behind compile flag, assign defaults

* macro keys now have defaults (hidden in colinta.h) before any recording, and after clearing the dynamic macros.

* fixed whitespace - using 4 spaces instead of 2
7 years ago
Seebs 7fbe6c3594 improve ergodox ez performance
With these changes, the ergodox ez goes from 315 scans per second
when no keys are pressed (~3.17ms/scan) to 447 (~2.24ms/scan).

The changes to the pin read are just condensing the logic, and
replacing a lot of conditional operations with a single bitwise
inversion.

The change to row scanning is more significant, and merits
explanation. In general, you can only scan one row of a keyboard
at a time, because if you scan two rows, you no longer know
which row is pulling a given column down. But in the Ergodox
design, this isn't the case; the left hand is controlled by an
I2C-based GPIO expander, and the columns and rows are *completely
separate* electrically from the columns and rows on the right-hand
side.

So simply reading rows in parallel offers two significant
improvements. One is that we no longer need the 30us delay after
each right-hand row, because we're spending more than 30us
communicating with the left hand over i2c. Another is that we're
no longer wastefully sending i2c messages to the left hand
to unselect rows when no rows had actually been selected in the
first place. These delays were, between them, coming out to
nearly 30% of the time spent in each scan.

Signed-off-by: seebs <seebs@seebs.net>
7 years ago
Seebs 55f3cd37af fix typo 7 years ago
Paul Ewing d0f3c0576c Add my Atreus62 keymap 7 years ago
Balz Guenat 7d9070c514 I forgot to add a README.md for the FC980C
sorry for forgetting it in the first PR.
7 years ago
Seebs 534cd9d45e Make brightness easier to change
Don't make the #defines unconditional, make them
optional so users can override them with per-keymap
settings more easily.
7 years ago
Balz Guenat 2f5bb2506a QMK port of Hasu's fc980c alt controller (#2043)
* fc980c port, builds but yet untested.

* add my own keymap
7 years ago
Colin T.A. Gray 3e2fd64279 I found a typo! 7 years ago
Colin T.A. Gray 5b4b471a4f this number just looks wrong, should be 4096 not 4996 7 years ago
Maarten Dekkers b8217eeff4 Add maartenwut's handwire build 7 years ago
Max dcc363390f Added Daisy port (#2016)
* Add files via upload

* Update readme.md

* Update readme.md

* Update readme.md

* Add files via upload

* Delete config.h

* Delete rules.mk

* Add files via upload

* Update config.h

* revised config files

* revised readme

* Update readme.md

* Update readme.md
7 years ago
Jack Humbert 62eed0e4a3
Update config_options.md 7 years ago
Jack Humbert c8bdc75e1d
Update feature_layouts.md 7 years ago
Seebs 39d3d92364 Allow multiple process_record() calls per scan
This is particularly relevant for, e.g., the ergodox EZ and
other keyboards with slow scan rates. Without changing the API or
behavior of individual process_record() calls, we allow a
configuration flag to make multiple calls in a single scan.

This will probably have miniscule effects on non-steno users,
and it's not enabled by default for any keyboards. Added note
about it to ergodox README.

Signed-off-by: seebs <seebs@seebs.net>
7 years ago
Jack Humbert b669d115c2 adds planck light keyboard 7 years ago
Gilbert Consellado 7ff96877d2 added SS_LSFT to featured macros 7 years ago
yellowmoneybank c6cdd5422f Neo2Planck (#2032)
* Documentation

* Enabled Mouse-Keys in Makefile

* Layer 1 finished

* Small Bugfixes

* Updated documentation
7 years ago
d_r0ck d6ca4e555a Added files 7 years ago
TerryMathews d8aa018995 Kona_classic: ANSI arrows keymap with locking caps lock support 7 years ago
Marcus Young 08dab374da Add my layout 7 years ago
Drashna Jaelre dbd33782f2 Update to drashna keymaps (#4)
* Minor updates to keymaps

* Minor updates to keymaps
7 years ago
Jack Humbert 1d703a476a update build script to not delete files 7 years ago
Jack Humbert f5a9758cea
Adds serial number string to USB descriptors (#1996)
* add serial number string to usb descriptors

* better name for serial number
7 years ago
Robert Llewellyn f07e2cdd9d DZ60 own true HHKB layout after dz60.h fix (#2012) 7 years ago
Jack Humbert f2c32b3ea4
Splits up ps2avrGB boards into their own folders (#2014)
* move underglow led count from parent to child

* Added pearl support

* Added personal keymap for pearl

* start splitting up ps2avrGB boards

* clean up ps2avrgb boards

* Move keycodes to their own section

* Clarify `KC_PWR` vs `KC_POWER`. Fixes #1994.

*  Cleaned uppersonal userspace and keymaps (#1998)

* Cleanup of keymaps

* Remove Tap Dance from Orthodox keymap

* Cleaned up userspace and keymaps

* Added sample (template)userspace files to my folder

* Document the Teensy hardware reset problem

* add mfluid keymap to atreus62

* Update hand_wire.md

Change "Resin" to "Rosin"

* Add keyboard: mt40 (#2001)

* add keyboard: chinese planck clone

* rename chinese_planck to mt40

* add image for the mt40 board

* lets_split: Fix matrix_init for ROW2COL

Signed-off-by: Marian Rusu <rusumarian91@gmail.com>

* Add Keymap for Whitefox Truefox layout

* Add keyboard: ACR60 (#1999)

* base acr60 keyboard folder created

* mitch acr60 keymap updates, documentation

* latest keymap updates

* slight modifications to layer switching

* Changes to Atreus and Ergodox EZ Dvorak 42key layout (#1997)

* importing 42 key dvorak layout

* added comment for build instructions

* adding atreus dvorak 42 key layout

* added readme

* add readme

* build instructions

* additional MEH shortcuts

* added shifted symbols on symbols layer

* working extra symbols on COMBINED layer

* bring atreus layout inline with the ergodox one

* add necessary macros

* working ls macro

* added more shell macros

* added screen rename / screen number macros

* add ctrl-a key in shell-nav to use screen more easily

* added shell screen layer

* assign screen switching macros to screen layer

* define all screen switching macros

* more screen-related shortcuts added on shell screen layer

* change shell nav bottom right row to match base layer (backspace / delete)

* remove some mappings on SHELL_NAV layer as they are now in the screen layer

* added more screen macros

* changes to COMBINED layer (pipe on the right) and modified shell nav

* moved pipe/backslash to then right

* documented SHELL_SCREEN layer

* put backspace/delete on SHELL_NAV layer

* add an explicit lisence file for github to pickup

* Updated keymaps to allow base layer alternation for QWERTY, Colemak & Dvorak (#1962)

* First commit of the Terminus_Mini firmware and the DivergeJM version of the Nyquist firmware

* Fix terminus_mini & nyquist/DivergeJM readme files

Previously an outdated copy of the default readme. Updated to match the  Nyquist/DivergeJM format (DivergeJM is a split 5x12 implementation of the terminus_mini layout)

* Update makefiles to rules.mk

Renamed both Makefiles to rules.mk, removed references to makefiles

* Updated rules.mk

Inadvertantly removed important code from the rules.mk in previous commit. This has been restored.

Also disabled Tap_Dance in both rules.mk files

* Moved terminus_mini to handwired

Realised that existing directory was not appropriate for the terminus_mini project, moved to handwired.

* New Frosty Flake layout for QFR TKL

Added a TKL layout for the Frosty Flake with a navigation cluster on LOWER under the left hand and a similarly functioning MOUSE layer that includes mouse navigation functionality.

* README fix & keymap update for 3 keyboards

Fixed the markdown for the handwired/terminus_mini:default, Nyqyist:DivergeJM & frosty_flake:QFR_JM.

Added TAPPING_TERM =  150 to config.h for all keyboards

Switched LT(LOWER) and LAlt on the mod row for ortholinear boards.

* Update readme for QFR_JM to include make instructions

* Revert "Merge branch 'master' of https://github.com/mogranjm/qmk_firmware"

This reverts commit a45f264ada09acc14fb85390407bc7ff5bb021e3, reversing
changes made to 62349c33410671a33d4041d50cf27de1d6bdd9cf.

* Revert "Revert "Merge branch 'master' of https://github.com/mogranjm/qmk_firmware""

This reverts commit eae54fb3be2c60dffd704261f84bab98c9e06f93.

* Added QWERTY support to the QFR_JM

Implemented variable default base layer from the Planck default keymap.

* Update README to reflect QWERTY support

* Nyquist:DivergeJM - Update RESET location

Add a reset button to both hands, accessible when halves are disconnected.

* Typo fix

* Update DivergeJM

Switched master to Left hand,
Moved Reset key to a different location

* Added macros to send R pointer & dplyr pipe

Macros added as a string of keypresses, couldn't figure out how to get SEND_STRING to work.

* Added ADJUST -> QWERTY, DVORAK, COLEMAK

Re-implemented update_tri_layer fuctionality to reset base layer for Terminus_Mini & DivergeJM Nyquist keymaps to QWERTY, DVORAK or COLEMAK via the ADJUST layer.

Updated ReadMe files accordingly.

* Fix base layout diagram for Terminus_Mini

Remove split from diagram

* Changed the R operators to SEND_STRING, rather than keypress macros

* Added Dvorak to the QFR_JM keymap

* fixed duplicate row in Nyquist keymap

* Fix readme - LAlt location on mouse layer

* Set EE_HANDS to allow either Nyquist hand to work as master.

* Update R operator strings, clean up layering for terminus_mini, QFR_JM and DivergeJM

"<-" to " <- "
"%>%" to " %>% "

Also played around with the layering, removed unnecessary TAP_TOGGLE for LOWER and shuffled FUNCTION and MOUSE momentary actions to reflect layer order.

* Update bottom alpha row to output symbols on LOWER

This row now outputs the following (z -> /) when in the LOWER layer:
 <-
 %>%
{
[
`
|
]
}
.
/

* Updated readme files for QFR_JM, terminus_mini & DivergeJM

QFR_JM readme reflects correct LOWER bottom row symbol output,
terminus_mini & DivergeJM reflect correct command line make instructions.

* Add media keys to QFR_JM LOWER - Replicate QFR default functionality

* Fix issue with Mouse layering

Stuck on mouse layer because the wrong macro was assigned to the 'exit layer' key. Reassigned that key.

* Changed " <- " to "<- " for QFR_JM, terminus_mini & DivergeJM

* Add "KC_MAKE" to userspace example

* QMK DFU bootloader generation (#2009)

* adds :bootloader target

* update planck and preonic revisions

* remove references to .h files for planck

* update preonic keymap

* only add keyboard.h files that exist

* add production target

* hook things up with the new lufa variables

* update rules for planck/preonic

* back backlight key turn of status led when pressed

* add manufacturer/product strings to bootloader

* fix push script

* Added support for let's split kailh socket version (#2010)

* Added support for socket version of the let's split

* renamed files

* socket-version-works

* fix up lets_split keymaps

* fix up lets_split keymaps

* shrink preonic by a bit

* fix lets_split keyboards

* update travis script

* update travis script

* update version silencing
7 years ago
Jack Humbert 92d47a55d4 update chibios 7 years ago
Jack Humbert 41f3f01167
Update .gitmodules 7 years ago
Damien a8c4af5a45 Updated dbroqua layout for HHKB keyboard (#1990)
* - 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!).
7 years ago
Balz Guenat 858c09f370 add example keymap 7 years ago
Balz Guenat 179d64d33c extend macro docs a bit 7 years ago
Jack Humbert eac4bab342 update version silencing 7 years ago
Jack Humbert a8466df62d update travis script 7 years ago
Jack Humbert cb64a886e9 update travis script 7 years ago
Jack Humbert dbabfb082c fix lets_split keyboards 7 years ago
Jack Humbert 607876187d shrink preonic by a bit 7 years ago
Jack Humbert 7f3539aa76 fix up lets_split keymaps 7 years ago
Jack Humbert 4ad0bbd672 fix up lets_split keymaps 7 years ago
Mikkel Jeppesen 85172f4f85 Added support for let's split kailh socket version (#2010)
* Added support for socket version of the let's split

* renamed files

* socket-version-works
7 years ago
Jack Humbert b702c08825 fix push script 7 years ago
Jack Humbert ec3e065f0d
QMK DFU bootloader generation (#2009)
* adds :bootloader target

* update planck and preonic revisions

* remove references to .h files for planck

* update preonic keymap

* only add keyboard.h files that exist

* add production target

* hook things up with the new lufa variables

* update rules for planck/preonic

* back backlight key turn of status led when pressed

* add manufacturer/product strings to bootloader
7 years ago
drashna 3c15c48e6a Add "KC_MAKE" to userspace example 7 years ago
James Morgan 49d8f1c5ed Updated keymaps to allow base layer alternation for QWERTY, Colemak & Dvorak (#1962)
* First commit of the Terminus_Mini firmware and the DivergeJM version of the Nyquist firmware

* Fix terminus_mini & nyquist/DivergeJM readme files

Previously an outdated copy of the default readme. Updated to match the  Nyquist/DivergeJM format (DivergeJM is a split 5x12 implementation of the terminus_mini layout)

* Update makefiles to rules.mk

Renamed both Makefiles to rules.mk, removed references to makefiles

* Updated rules.mk

Inadvertantly removed important code from the rules.mk in previous commit. This has been restored.

Also disabled Tap_Dance in both rules.mk files

* Moved terminus_mini to handwired

Realised that existing directory was not appropriate for the terminus_mini project, moved to handwired.

* New Frosty Flake layout for QFR TKL

Added a TKL layout for the Frosty Flake with a navigation cluster on LOWER under the left hand and a similarly functioning MOUSE layer that includes mouse navigation functionality.

* README fix & keymap update for 3 keyboards

Fixed the markdown for the handwired/terminus_mini:default, Nyqyist:DivergeJM & frosty_flake:QFR_JM.

Added TAPPING_TERM =  150 to config.h for all keyboards

Switched LT(LOWER) and LAlt on the mod row for ortholinear boards.

* Update readme for QFR_JM to include make instructions

* Revert "Merge branch 'master' of https://github.com/mogranjm/qmk_firmware"

This reverts commit a45f264ada09acc14fb85390407bc7ff5bb021e3, reversing
changes made to 62349c33410671a33d4041d50cf27de1d6bdd9cf.

* Revert "Revert "Merge branch 'master' of https://github.com/mogranjm/qmk_firmware""

This reverts commit eae54fb3be2c60dffd704261f84bab98c9e06f93.

* Added QWERTY support to the QFR_JM

Implemented variable default base layer from the Planck default keymap.

* Update README to reflect QWERTY support

* Nyquist:DivergeJM - Update RESET location

Add a reset button to both hands, accessible when halves are disconnected.

* Typo fix

* Update DivergeJM

Switched master to Left hand,
Moved Reset key to a different location

* Added macros to send R pointer & dplyr pipe

Macros added as a string of keypresses, couldn't figure out how to get SEND_STRING to work.

* Added ADJUST -> QWERTY, DVORAK, COLEMAK

Re-implemented update_tri_layer fuctionality to reset base layer for Terminus_Mini & DivergeJM Nyquist keymaps to QWERTY, DVORAK or COLEMAK via the ADJUST layer.

Updated ReadMe files accordingly.

* Fix base layout diagram for Terminus_Mini

Remove split from diagram

* Changed the R operators to SEND_STRING, rather than keypress macros

* Added Dvorak to the QFR_JM keymap

* fixed duplicate row in Nyquist keymap

* Fix readme - LAlt location on mouse layer

* Set EE_HANDS to allow either Nyquist hand to work as master.

* Update R operator strings, clean up layering for terminus_mini, QFR_JM and DivergeJM

"<-" to " <- "
"%>%" to " %>% "

Also played around with the layering, removed unnecessary TAP_TOGGLE for LOWER and shuffled FUNCTION and MOUSE momentary actions to reflect layer order.

* Update bottom alpha row to output symbols on LOWER

This row now outputs the following (z -> /) when in the LOWER layer:
 <-
 %>%
{
[
`
|
]
}
.
/

* Updated readme files for QFR_JM, terminus_mini & DivergeJM

QFR_JM readme reflects correct LOWER bottom row symbol output,
terminus_mini & DivergeJM reflect correct command line make instructions.

* Add media keys to QFR_JM LOWER - Replicate QFR default functionality

* Fix issue with Mouse layering

Stuck on mouse layer because the wrong macro was assigned to the 'exit layer' key. Reassigned that key.

* Changed " <- " to "<- " for QFR_JM, terminus_mini & DivergeJM
7 years ago
Jack Humbert 5cdf47a79e
add an explicit lisence file for github to pickup 7 years ago
Marian Rusu 3f1aab0c2e lets_split: Fix matrix_init for ROW2COL
Signed-off-by: Marian Rusu <rusumarian91@gmail.com>
7 years ago
Andy Holder 43edc83998 Add Keymap for Whitefox Truefox layout 7 years ago
lucwastiaux dd60038eeb Changes to Atreus and Ergodox EZ Dvorak 42key layout (#1997)
* importing 42 key dvorak layout

* added comment for build instructions

* adding atreus dvorak 42 key layout

* added readme

* add readme

* build instructions

* additional MEH shortcuts

* added shifted symbols on symbols layer

* working extra symbols on COMBINED layer

* bring atreus layout inline with the ergodox one

* add necessary macros

* working ls macro

* added more shell macros

* added screen rename / screen number macros

* add ctrl-a key in shell-nav to use screen more easily

* added shell screen layer

* assign screen switching macros to screen layer

* define all screen switching macros

* more screen-related shortcuts added on shell screen layer

* change shell nav bottom right row to match base layer (backspace / delete)

* remove some mappings on SHELL_NAV layer as they are now in the screen layer

* added more screen macros

* changes to COMBINED layer (pipe on the right) and modified shell nav

* moved pipe/backslash to then right

* documented SHELL_SCREEN layer

* put backspace/delete on SHELL_NAV layer
7 years ago
Ryan Mitchell 716ff76f5b Add keyboard: ACR60 (#1999)
* base acr60 keyboard folder created

* mitch acr60 keymap updates, documentation

* latest keymap updates

* slight modifications to layer switching
7 years ago
Thomas Dehaeze eef94b0b40 add mfluid keymap to atreus62 7 years ago
James 309a400b3e Update hand_wire.md
Change "Resin" to "Rosin"
7 years ago
Thomas Dehaeze c2c3aa4f08 Add keyboard: mt40 (#2001)
* add keyboard: chinese planck clone

* rename chinese_planck to mt40

* add image for the mt40 board
7 years ago
Erin Call 392121b10e Document the Teensy hardware reset problem 7 years ago
drashna 0533362e82 Cleaned uppersonal userspace and keymaps (#1998)
* Cleanup of keymaps

* Remove Tap Dance from Orthodox keymap

* Cleaned up userspace and keymaps

* Added sample (template)userspace files to my folder
7 years ago
skullY 4df4fa7c26 Clarify `KC_PWR` vs `KC_POWER`. Fixes #1994. 7 years ago
skullY 66f13e4972 Move keycodes to their own section 7 years ago
Jack Humbert bb11df6b7a update some docs 7 years ago
Zach Burchill e236f1eba1 Fixed some grammar and typos on the docs (#1989)
* fixed grammar and references

* fixed typo
7 years ago
Erez Zukerman 847ade44fc
Merge pull request #1988 from qmk/hf/disable_shine_leds_default
disables Shine LED layer indication for now
7 years ago
Erez Zukerman 7044dafe59
Merge pull request #1986 from ideasman42/code-friendly-qwerty
qwerty_code_friendly: Expose caps-lock & fix typo
7 years ago
Erez Zukerman fd1a0d6753 disables Shine LED layer indication for now 7 years ago
Campbell Barton c2c9d9b386 qwerty_code_friendly: Expose caps-lock & fix typo 7 years ago
Oscillope 05f15b789f More "oscillope" keymap fixes. (#1982)
* More keymap fixes. F-row on bottom layer wasn't fully setup, also switched raise/lower keys to use tap-toggle.

* Added PrScr, put Tab back on top layer.

* Fixed build breakage with default keymap (unneeded rgblight.h include)
7 years ago
Florian Beeres 7e2223f822 Improved README of yuuki and added RGB commands (#1983)
* Add yuuki keymap

Documentation is still a TODO and the keymap may not be final

* GRV on colon

* add KC_GRV to FN ESC

* more RGB modes

* Update README.md

Add image of layout and fix typo

* switch from jpg to png

For some reason the JPG had red outlines around the keys.

* remove whitespace

* add instruction to reset keyboard before flashing

* gh60 stytle layout

* moved the GH60 style layout to new folder

* add HOME and END

* Add heading

* moved ayanami to other branch
7 years ago
Balz Guenat 3b5381d689 restructure converters (#1825)
* restructure converters

each converter is its own keyboard and different hardware variants are different subprojects.

remove (seemingly) old method of loading layouts from main Makefile

* call led_set_kb() from overridden led_set()

* put converter back into one folder

* revert some structure changes to bring in line with #1784.

Also attempt to get the BLE thing more properly integrated.
Also also fix led_set() to call led_set_kb().
7 years ago
Campbell Barton aee6785476 qwerty_code_friendly: configurable left thumb
Also add mouse-wheel keys.
7 years ago
drashna 363aa8aa2e Migrated most code from keymaps to userspace (#1980)
* Add woodpad

* Cleanup

* Remove misc layouts for woodpad

* Move woodpad to handwired

* Updated RGB Underglow info

* Cleanup macros

* Tweaked RGB lighting stuff

* Start to merge orthodox/ergodox keymaps (persistant layers)

* Add woodpad

* Add forced NKRO

* Added default layer (qwerty/colemak/dvorak) detection to RGB Underglow

* Updated macros and added workman keymaps

* Fixed RGB lighting for Workman layout

* Add leader keys

* Remove force NKRO

* Add Viterbi one handed layout and minor tweaks to others

* Finishing up Viterbi keyboard layout, and NKRO tweaks to other layouts

* Made "make" keystroke universal

* Clean up and updates of drashna keymaps

* Add workman layer to planck

* Update to keymaps

* Fix makefile toggle code in ez keymap
Finish adding RGB code to orthodox

* Updated RGB Underglow layer indication code due to discovery of the layer_state_set_kb function

* Remove unnecessary planck layout

* Fixed Workman song

* update make command and added lit reset

* Fixed formatting to fall in line with official standards

* Minor tweaks

* Removed Leader Keys from Ergodox EZ Keymap
Added KC_RESET that resets board and sets underglow to red

* Tweak reset code

* Cleanup

* Remove misc layouts for woodpad

* Move woodpad to handwired

* Updated RGB Underglow info

* Cleanup macros

* Tweaked RGB lighting stuff

* Start to merge orthodox/ergodox keymaps (persistant layers)

* Add forced NKRO

* Added default layer (qwerty/colemak/dvorak) detection to RGB Underglow

* Updated macros and added workman keymaps

* Fixed RGB lighting for Workman layout

* Add leader keys

* Remove force NKRO

* Add Viterbi one handed layout and minor tweaks to others

* Finishing up Viterbi keyboard layout, and NKRO tweaks to other layouts

* Made "make" keystroke universal

* Clean up and updates of drashna keymaps

* Add workman layer to planck

* Update to keymaps

* Fix makefile toggle code in ez keymap
Finish adding RGB code to orthodox

* Updated RGB Underglow layer indication code due to discovery of the layer_state_set_kb function

* Remove unnecessary planck layout

* Fixed Workman song

* update make command and added lit reset

* Fixed formatting to fall in line with official standards

* Minor tweaks

* Removed Leader Keys from Ergodox EZ Keymap
Added KC_RESET that resets board and sets underglow to red

* Tweak reset code

* Fix rebasing issues

* remove head files

* Fix "macro" issue

* Rename ez keymaps for userspace

* Revert "Rename ez keymaps for userspace"

This reverts commit c25425911852e41711a5f0273b5741adb16e5bd4.

* Renamed Ergodox EZ layouts so that all of my personal layouts are on the same name, in prep for using userspaces

* Fix ergodox code

* Remove "drashna-ez" keymap as it's no longer needed

* Migrate majority of code to Userspace
7 years ago
Fredric Silberberg ef2961798c Small ergodox config fix and update. 7 years ago
drashna 3e861c2fd5 Update and move around drashna keymaps (#1976)
* Add woodpad

* Cleanup

* Remove misc layouts for woodpad

* Move woodpad to handwired

* Updated RGB Underglow info

* Cleanup macros

* Tweaked RGB lighting stuff

* Start to merge orthodox/ergodox keymaps (persistant layers)

* Add woodpad

* Add forced NKRO

* Added default layer (qwerty/colemak/dvorak) detection to RGB Underglow

* Updated macros and added workman keymaps

* Fixed RGB lighting for Workman layout

* Add leader keys

* Remove force NKRO

* Add Viterbi one handed layout and minor tweaks to others

* Finishing up Viterbi keyboard layout, and NKRO tweaks to other layouts

* Made "make" keystroke universal

* Clean up and updates of drashna keymaps

* Add workman layer to planck

* Update to keymaps

* Fix makefile toggle code in ez keymap
Finish adding RGB code to orthodox

* Updated RGB Underglow layer indication code due to discovery of the layer_state_set_kb function

* Remove unnecessary planck layout

* Fixed Workman song

* update make command and added lit reset

* Fixed formatting to fall in line with official standards

* Minor tweaks

* Removed Leader Keys from Ergodox EZ Keymap
Added KC_RESET that resets board and sets underglow to red

* Tweak reset code

* Cleanup

* Remove misc layouts for woodpad

* Move woodpad to handwired

* Updated RGB Underglow info

* Cleanup macros

* Tweaked RGB lighting stuff

* Start to merge orthodox/ergodox keymaps (persistant layers)

* Add forced NKRO

* Added default layer (qwerty/colemak/dvorak) detection to RGB Underglow

* Updated macros and added workman keymaps

* Fixed RGB lighting for Workman layout

* Add leader keys

* Remove force NKRO

* Add Viterbi one handed layout and minor tweaks to others

* Finishing up Viterbi keyboard layout, and NKRO tweaks to other layouts

* Made "make" keystroke universal

* Clean up and updates of drashna keymaps

* Add workman layer to planck

* Update to keymaps

* Fix makefile toggle code in ez keymap
Finish adding RGB code to orthodox

* Updated RGB Underglow layer indication code due to discovery of the layer_state_set_kb function

* Remove unnecessary planck layout

* Fixed Workman song

* update make command and added lit reset

* Fixed formatting to fall in line with official standards

* Minor tweaks

* Removed Leader Keys from Ergodox EZ Keymap
Added KC_RESET that resets board and sets underglow to red

* Tweak reset code

* Fix rebasing issues

* remove head files

* Fix "macro" issue

* Rename ez keymaps for userspace

* Revert "Rename ez keymaps for userspace"

This reverts commit c25425911852e41711a5f0273b5741adb16e5bd4.

* Renamed Ergodox EZ layouts so that all of my personal layouts are on the same name, in prep for using userspaces

* Fix ergodox code

* Remove "drashna-ez" keymap as it's no longer needed
7 years ago
Takayuki Matsubara f113f1927f make it easy to customize logo image 7 years ago
Takayuki Matsubara 27ee425892 add pgm_read_dword for Infinity ErgoDox
avoid the following error when `UNICODEMAP_ENABLE = yes`:

```
quantum/process_keycode/process_unicodemap.c:52:21: error: implicit declaration of function 'pgm_read_dword'
```
7 years ago
Fred Silberberg 89357b96d4 333fred layout update (#1971)
* Set up tap dance for layers on the lower button.

* Refactored code to share in the users directory between my two keyboard layouts.

* Small keyboard layout change.

* Updated documentation on oneshot usage in macros/tap dance.
7 years ago
J. Eric Mason 16843bc8c9 Pete's 40th XD64 Layout
Mac layout based on yuuki with some other changes, for Pete's 40th birthday keyboard
7 years ago
lucwastiaux 7854746704 Ergodox EZ and Atreus 42 key dvorak layout updates (#1964)
* importing 42 key dvorak layout

* added comment for build instructions

* adding atreus dvorak 42 key layout

* added readme

* add readme

* build instructions

* additional MEH shortcuts

* added shifted symbols on symbols layer

* working extra symbols on COMBINED layer

* bring atreus layout inline with the ergodox one

* add necessary macros

* working ls macro

* added more shell macros

* added screen rename / screen number macros

* add ctrl-a key in shell-nav to use screen more easily

* added shell screen layer

* assign screen switching macros to screen layer

* define all screen switching macros

* more screen-related shortcuts added on shell screen layer

* change shell nav bottom right row to match base layer (backspace / delete)

* remove some mappings on SHELL_NAV layer as they are now in the screen layer

* added more screen macros
7 years ago
Jeremy Cowgar 245b3376d6 Correct the rules.mk documentation for auto shift.
fixes #1965
7 years ago
drashna 2c703b1528 Fix RGBLIGHT startup color (#1975)
* Fix RGBLIGHT startup color

While it's awesome to see the layer indicating code in here (no really!), and the general rule is to not alter the default keymap/code....

The problem with the layer_state_set_kb call handling this, is that the code doesn't seem to be called at startup.  So the default layer color won't ever get set on startup.  It needs to be called in the init function to be properly set. 

I've played with this extensively, and if you check my keymaps, that is precisely why I have the setrgb/sethsv in the init function.

* Removed typo (pipe)
7 years ago
Erez Zukerman 90a6fea4e8
Merge pull request #1974 from qmk/f/ez_shine_layer_leds
Shine layer indication
7 years ago
Erez Zukerman e45290a62e adds indication up to layer 7 7 years ago
Jack Humbert 1d3a19757c restore default mode/color if no 0 color 7 years ago
Jack Humbert cf9f6bbd91 adds per-layer rgb color option to ez 7 years ago
Jack Humbert 41df0dc9a7 update gh60 info 7 years ago
Jack Humbert 30dc34d529 add gh60 info.json 7 years ago
Michael F. Lamb e899cb8940 several improvements for mitosis:datagrok (#1960)
* mitosis/datagrok: reduce features from rules.mk

* mitosis/datagrok: make both layer keys neighbor shift

* mitosis/datagrok: (no-op) tweak some comments

* mitosis/datagrok: set baudrate to 250k

This requires a corresponding change to the mitosis wireless firmware:
https://github.com/reversebias/mitosis/pull/10

* mitosis/datagrok: move design description from code comment to a readme

* mitosis/datagrok: new layout, new shifted keys, efficient LED code

This is experimental, but compiles and seems to work correctly.

* mitosis/datagrok: whoops, move readme.md

* mitosis/datagrok: a minor layout improvement simplifies custom-shifted code

instead of [, .] [? !], using [, ?] [. !] greatly simplifies the code
needed to perform the shifted-key switching. (And keeps , and . on the
same keys that they are under qwerty.)

also: layout improvements for symbols

* mitosis/datagrok: make my code conform to QMK style guidelines

* mitosis/datagrok: TODO note for layout table in README

* mitosis/datagrok: remove led_set_user until i figure out other changes

need to see if the corresponding changes needed in the keyboard-level code
is okay.

* mitosis/datagrok: simpler layer indicator

* mitosis/datagrok: undo change to keyboard baud; make it in my layout dir.

* mitosis/datagrok: apply same punctuation hack to qwerty layer

* mitosis/datagrok: enable qwerty layer toggle

* mitosis/datagrok: update readme
7 years ago
M Rawash 80e489e122 Added hand-swap matrix to the mitosis 7 years ago
Jennifer 29d1abff07 have led default to off on start up 7 years ago
Jennifer b546da0a19 make more generic, and properly handle inits 7 years ago
skullY f357bd0ccc fix a typo 7 years ago
skullY 685d4c2f97 Do some cleanup for the API 7 years ago
skullY 535c2f60a9 use real greater than and less than chars 7 years ago
skullY 65eaab8a1a fix labels 7 years ago
skullY 18f3cd1123 add labels to the clueboard layout 7 years ago
skullY e45ce2dcb3 Merge branch 'master' of github.com:qmk/qmk_firmware 7 years ago
skullY 137456e5b1 fix the clueboard layout json 7 years ago
Jack Humbert ec59147507 fix 2u alignment in info.jsons 7 years ago
Jack Humbert 074b78700a update preonic, add info.json 7 years ago
skullY 432674781a Document info.json files 7 years ago
skullY 4e41beeaa6 Fix a typo 7 years ago
Jack Humbert 00733f4b87 update contributing guidelines 7 years ago
dkrieger 19753788c1 Add satan keymap: HHKB-alike based on dbroqua's, with mouse functionality (#1948)
* Add satan keymap: HHKB-alike based on dbroqua's, with mouse functionality and without LED functionality

* move mouse layer to DOUBLE_HOLD, add UTIL layer for TRIPLE_HOLD

- UTIL layer
    - currently has "RESET" key and nothing else.
    - functionality otherwise covered by bootmagic should go here

- small bugfix: dispatch of [QTY]_HOLD should be based on range tap count
  falls in, not exact count.
7 years ago
Pawnerd 54a8abd785 Added support for Knops Mini (3x2 macropad) keyboard. (#1953)
* Added support for Knops Mini (3x2 macropad) keyboard.

* Added better documentation, according to the QMK standards.

* Fixed typo.

* Changed names of files to comply with QMK standards.

* Ignored makefile in keymap.

* Removed makefiles and added my credentials in the copyrights.
7 years ago
Jack Humbert d6ad9787a0 update template readme 7 years ago
Jack Humbert e2e387f8f8 update qmk template 7 years ago
Jack Humbert 039cc8c932 ignore more makefiles 7 years ago
QMK Bot 004826e1b8 convert to unix line-endings [skip ci] 7 years ago
Jack Humbert f445a7f971 adds .hex for teensy 2.0 using B0 as reset 7 years ago
Danny Nguyen 13e1388f2d Add nano switch pad 7 years ago
Jack Humbert fe56fffe7d
Adds .qmk file type as a target for QMK Toolbox (#1084)
* adds .qmk file type as a target

* adds info.json with vendor and product

* add files for qmk info script

* add layout file for planck

* ignore .qmk files

* more settings

* update rules for avr and chibios

* update .qmk generation for info.json and inheritence
7 years ago
Jack Humbert d069a42c07
Update getting_started_github.md 7 years ago
Jack Humbert 029234f1f1
adds other layouts to rules.mk 7 years ago
Jack Humbert ddf49e8b21 Merge branch 'master' of https://github.com/qmk/qmk_firmware 7 years ago
Jack Humbert 371922ad61 update layout macros for planck 7 years ago
skullY f868a3bb86 Fix the json for clueboard 7 years ago
skullY 5329a80f6c fixup json 7 years ago
Arialdo Martini 32bb8f6b8a Improvements to documentation (#1919)
* Typo: Github => GitHub

* Typo: windows => Windows, docker => Docker, and some punctuations

* "QMK Introduction" links to the right file

* "Unix" rather than "UNIX", which is a trademark

* Directory name is "keyboards", not "keyboard"

* "handwired" is a subdirectory of "keyboards"

* Punctuation and minor fixes

* macOS rather than Mac

* Punctuation and other minor fixes

* Vagrant Guide links to an existing file

* Jun Wako referenced with his name rather than his nickname

* Saxon genitive 's outside the link
7 years ago
Jack Humbert 1683d3a559 adds info.json files to planck 7 years ago
drashna b79a4cfeba Updated personal keymaps (#1945)
* Add woodpad

* Cleanup

* Remove misc layouts for woodpad

* Move woodpad to handwired

* Updated RGB Underglow info

* Cleanup macros

* Fix odd merge issue

* Tweaked RGB lighting stuff

* Start to merge orthodox/ergodox keymaps (persistant layers)

* Add forced NKRO

* Added Colemak and Dvorak layers to default orthodox keymap

* Added default layer (qwerty/colemak/dvorak) detection to RGB Underglow

* Updated macros and added workman keymaps

* Fixed RGB lighting for Workman layout

* Add leader keys

* Remove force NKRO

* Add Viterbi one handed layout and minor tweaks to others

* Finishing up Viterbi keyboard layout, and NKRO tweaks to other layouts

* Made "make" keystroke universal

* Clean up and updates of drashna keymaps

* Add workman layer to planck

* Update to keymaps

* Fix accidental commit because I don't know how to git

* Fix makefile toggle code in ez keymap
Finish adding RGB code to orthodox

* missing underscore in init function declaration

* Updated RGB Underglow layer indication code due to discovery of the layer_state_set_kb function

* Remove unnecessary planck layout
7 years ago
skullY 44d9ad95b7 Add info.json files for clueboard 66 7 years ago
Danny Nguyen fad967af4c Remove extra underscore from MASTER_RIGHT define 7 years ago
DangerousParts 20e18d15e3 Created Kona Classic config (#1791)
* Created Kona Classic config

* Fixed KonaClassic config

* Updated README

* Updated Readme to conform to format standards

* Added ANSI and ISO layout options

* Fixed images in Readme

* Added labels to images

* Added absolute links to images in Readme

* Image link updates again

* Fixed bottom row keys in some layouts

* Fixed Grave and Tilde

* Fixed Underglow in Kona Classic configs

* Renamed KonaClassic to kona_classic
7 years ago
Danny 83af62322c Add Levinson rev2 (#1939)
* Add levinson rev2 files

* Add hexwire keymap

* Remove redefinition of backlight defines
7 years ago
Rob Rogers 2d77f9cbb9 Fix pointing device feature 7 years ago
Danny Nguyen c9a0436422 Add 6-ball macropad 7 years ago
GlenPickle fca03e15b9 Chimera Ortho Readme (#1943)
* Added Chimera Ortho keymap

* added readme

* fixed hardware link
7 years ago
Erez Zukerman bc98b0d9eb
Merge pull request #1915 from dondelelcaro/ergodox_ez_left_leds
Ergodox ez left leds support
7 years ago
Jack Humbert 38261920a9
update hand wiring link 7 years ago
Danny Nguyen f9881793e3 Add hexwire keymap for Eco 7 years ago
tsankuanglee 04b9b62bdc RETRO_TAPPING (#1922)
* add RETRO_TAP: tap anyway, even after TAP_TERM, if no interruption

* consistent variable name

* add option doc

* change name for consistency

* make RETRO_TAPPING default to off
7 years ago
Louis Orleans b2bbbc2dfc layout(infinity ergodox): dudeofawesome's layout (#1932)
* 🎉 Building simple flasher

* 🎉 Flashing works

* 🎨 Cleaning up

* 🐛 Being more specific with board identity

* 🐛 Flashing correct keymap

* 🎉 Adding keymap

*  Updating keymap

* 🚨 RGB

*  Revert "🚨 RGB"

This reverts commit 9ceabfb267f8daedaad929231229c703abc12ec4.

*  Improvements to flasher

*  Layout tweaks

* 💄 Messing around with LCD

* 💄 Enabling LCD backlight matching

* 🔧 Updating layout

* 🐛 Fixing console logging

* 🎨 Cleaning up indentation

* 🔧 Adding editorconfig

*  Adding game layer

* 💄 Changing numpad layout

* 🔥 redoing entire layout

It's now more similar to the Planck default layout

*  add workman and dvorak layouts

* 🐛 fix numpad

* 🐛 fix layer orders

* 🐛 fix layer toggling

* 🐛 fix tri-layer switching

* 🐛 fix LCD colors for adjustment layers

* 🔥 remove old flasher project

* 🔥 remove simple_visualizer

* 💄 update LCD colors

* 📝 fix layout comments

* 💄  swapping 2u buttons

* 🔥🔧 removing editorconfig

* 🚨 using 2 spaces

* 📝 add README

*  Revert "💄 Enabling LCD backlight matching"

This reverts commit 51577903dfdc9fea5d33e9ab8cfa9b854e7ae19e.

*  Revert "💄 Messing around with LCD"

This reverts commit fdd9acdae514a3e0e4a7153225053680744980e5.
7 years ago
Louis Orleans 6169cd52ba Add EditorConfig file (#1930)
* 🔧 add editorconfig

This makes supported editors automatically change their settings to match desired code styles

* 🔧 add extension recommendation for VSCode

This will cause VS Code to prompt the user to install the EditorConfig extension when they open the project.

If this is felt to be too opinionated, I can revert it.
7 years ago
drashna 101b998ac2 Fix Pointing Device code (#1934)
* Fix pointer device options

when the feature was added, the appropriate option definition wasn't created.  This needs to be added to function properly.

* Update common_features.mk

* missing underscore in init function declaration
7 years ago
Takayuki Matsubara 7b65b7e948 fix Logical Maximum to be recognized as 255 instead of -1
SEE ALSO: https://github.com/qmk/qmk_firmware/issues/312
7 years ago
Zach Burchill 4c1164c469 fixed two typos
I'm almost 100% sure "else if (state->count = 2) {" was a typo (it should have two ='s for a logical operator), and I'm *pretty* sure "if (state->interrupted || state->!pressed) return SINGLE_TAP;" has a typo. At least, it returns an error on my machine saying something about an unexpected '!'.  
I changed it to a slightly longer form (i.e., "state->pressed==0"), and that worked fine.
7 years ago
Gun Pinyo e555e42aae add Thai layers for the GunP planck (#1910)
* Add a layout of planck named GunP, ready for pull request review.

* add Thai layers for the GunP planck
7 years ago
William Wilson 38da7795f4 Added Chimera Ortho keymap 7 years ago
Pentti Laitinen 8c10b60c5f Initial commit for nordic layout for ergodox infinity.
- Added nordic infinity ergodox layout
- Fixed typo in ergodox infinity readme.md
7 years ago
Nathan Sharfi c8fca10f0d zweihander-osx: Remove app keys, etc.
- add right command keys
- add F16 on ;' for Siri
- remove command-Q (too easy to hit)
7 years ago
Louis Orleans 1f6002db3f layout(planck): dudeofawesome's layout with simultaneous RGB and audio support (#1929)
* layout(planck): new layout initial commit

* feat(planck): add workman layout

* fix(planck): switching to workman

* layout(planck): swapping mnext and mplay

* feat(planck): prep for RGB

* perf(planck): remove plover

saves 256 bytes of memory

* perf(planck): remove colemak

saves 128 bytes

* layout(planck): swapping enter and quote

* perf(planck): disable console

frees 1664 bytes

* feat(planck): RGB under-lighting

* refactor(planck): change RGB pin

Uses pin labeled PB2

* feat(planck): add RGB keycodes

* feat(planck): re-enable audio

* style(planck): fixing indentation

Because who indents like that?

* style(planck): clean up keycodes

* layout(planck): remove del

* feat(planck): add tap-space to layer keys

* docs(planck): specify pin on PCB for RGB

* bug(planck): reducing tap time

* Revert "bug(planck): reducing tap time"

This reverts commit 62606b2dc62c5adcc06cfb5978d7e5305411a658.

* Revert "feat(planck): add tap-space to layer keys"

This reverts commit c74de5a4aa45c5563dcaa463395654c29f50eda3.

* perf(planck): remove backlit case

* feat(planck): swap enter and quote

* bug(planck): moving right shift

* doc(planck): update README

* chore(planck): remove makefile
7 years ago
James Morgan 07017871e5 README, keymap & config update to 3 keyboards (#1911)
* First commit of the Terminus_Mini firmware and the DivergeJM version of the Nyquist firmware

* Fix terminus_mini & nyquist/DivergeJM readme files

Previously an outdated copy of the default readme. Updated to match the  Nyquist/DivergeJM format (DivergeJM is a split 5x12 implementation of the terminus_mini layout)

* Update makefiles to rules.mk

Renamed both Makefiles to rules.mk, removed references to makefiles

* Updated rules.mk

Inadvertantly removed important code from the rules.mk in previous commit. This has been restored.

Also disabled Tap_Dance in both rules.mk files

* Moved terminus_mini to handwired

Realised that existing directory was not appropriate for the terminus_mini project, moved to handwired.

* New Frosty Flake layout for QFR TKL

Added a TKL layout for the Frosty Flake with a navigation cluster on LOWER under the left hand and a similarly functioning MOUSE layer that includes mouse navigation functionality.

* README fix & keymap update for 3 keyboards

Fixed the markdown for the handwired/terminus_mini:default, Nyqyist:DivergeJM & frosty_flake:QFR_JM.

Added TAPPING_TERM =  150 to config.h for all keyboards

Switched LT(LOWER) and LAlt on the mod row for ortholinear boards.

* Update readme for QFR_JM to include make instructions

* Revert "Merge branch 'master' of https://github.com/mogranjm/qmk_firmware"

This reverts commit a45f264ada09acc14fb85390407bc7ff5bb021e3, reversing
changes made to 62349c33410671a33d4041d50cf27de1d6bdd9cf.

* Revert "Revert "Merge branch 'master' of https://github.com/mogranjm/qmk_firmware""

This reverts commit eae54fb3be2c60dffd704261f84bab98c9e06f93.

* Added QWERTY support to the QFR_JM

Implemented variable default base layer from the Planck default keymap.

* Update README to reflect QWERTY support
7 years ago
Jody Foo f4949fdd32 Fix for issue https://github.com/qmk/qmk_firmware/issues/1751 7 years ago
Shihpin Tseng 750f8ec94e Fix process_combo.c compile warning 7 years ago
Jeremy Cowgar 49c32021db Added missing RGB and Auto Shift in main feature list. Also standardized on period at the end of each feature list item. 7 years ago
Jeremy Cowgar 76d807fe7d Fix code example in auto shift docs 7 years ago
Jeremy Cowgar bf1fedc05e Fixed various feature links 7 years ago
Maxr1998 5960d0349c Add grave key 7 years ago
Sebastian Kaim 0afaed8535 Extended the hint of the programmer to link to the relevant README part instead of giving a generic hint. 7 years ago
Sebastian Kaim 688343f218 Added a better description for the bootloader key 7 years ago
Jack Humbert 4d421ee31c adds flashing docs 7 years ago
Campbell Barton 91683d56fa ergodox qwerty_code_friendly: add macro keys (#1918)
Also add more configurable keys.
7 years ago
Pentti Laitinen 9ee207acac Added Iso(ish) layout for tada68. (#1924)
- Basic layout with one function layer.
- Added correct mapping for ISO layout into tada68.h.
- Readme for the keymap.
7 years ago
Don Armstrong 0bb457e573 document how to define LEFT_LEDS and how that hack is done 7 years ago
Don Armstrong 364aeeec53 implement ergodox_left_leds_update in ergodox_ez
Previously, this code was implemented in keymap.c, but I'm unaware of
someone with a different implementation of this particular hack. [If
someone has it, we can add another #ifdef in the future.]
7 years ago
Don Armstrong 2e3b99f7f1 update left led support 7 years ago
Don Armstrong bcfba27101 add initial support for left leds on an ergodox ez 7 years ago
Ethan Madden b45b223389 Small documentation and keymap tweaks for my minivan layout (#1891)
* Added personal minivan keymap

more consistent layer setup

documentation!

slide some things around

more doc jiggling

* Small layout and documentation tweaks

Small documentation updates

dropped Makefile that for some reason was still in my branch

* found and removed extra makefile
7 years ago
Sebastian Kaim 7b754e1a5a added bfake support as a subproject (#1903)
* added bfake support as a subproject

also moved existing bmini stuff to a subproject

fixed columns

minor keymap update

making this a subproject

remove old stuff

got subproject stuff figured out

* travis was upset because a board didn't have a default keymap
7 years ago
Manassarn Manoonchai a3f53aeaa1 Add narze keymaps for Ergodox & Planck with SuperDuper mode implementation (#1883)
* Fork default planck keymap

* Esc -> CapsLock

* Swap Tilde & Grave in Lower & Raise

* Replace Blacklight key with Raise

* Add Hyper/Esc & Shift/Enter key

* Add super duper mode using S+D combo

* Change superduper mode sound

* Add more functionality to superduper mode

* Fork default

* Replace all left shift to shift/parensopen (space cadet)

* Super / Underscore

* Try superduper on z/slash held

* Use function/macro instead, LGUI_UNDS alone not working

*  Add mouse layer 🐭

* 🐛 Fix superduper

*  Fix GUI_UNDS

* 🐛 Fix registering underscore when releasing too fast

* 🐛 Fix Shift/( with LT z

*  Add superduper for colemak

*  Add Qwerty on software Colemak layout & make Superduper available on multile layouts

*  Enable/disable superduper mode & fix layer switching

* 🐛 Fix superduper not unregister mods

*  Update planck-like ergodox (wip)

* 🐛 Fix return before changing tap count & modify comments

*  Replace with planck code

* 📝 Update readme

*  Fix SuperDuper by using intermediate layers

* Remove LT from inner lower & raise for ease of use

* Change TG to LG

* Add options & disable audio

* 🔧 Enable ignore mod tap interrupt & shorting tapping term

* 📝 Update readme

* Remove including quantum makefile

* 📝 Update readme

* Rename Makefiles
7 years ago
Doug Krieger 6c4639bfac Add RESET to satan:dbroqua mapping 7 years ago
skullydazed 67cc5cebc0 Restructure the hardware and feature docs to make things easier to find (#1888)
* fix #1313 by documenting more config.h options

* Clean up and organize documentation
7 years ago
heartrobotninja 8892c50336 Moving LOCK and adding RUN. Fixing equal key to actually use equal keycode. 7 years ago
Dylan Khor 9128ed50c2 Add macro to sleep Windows 10 7 years ago
Sebastian Kaim 1f43495922 Added a new keycode for cycling through RBG modes which reverses directions when shift is hold.
This commit adds a new keycode `RGB_SMOD` which is the same as `RGB_MOD` (cycle through all modes),
but when it is used in combination with shift it will reverse the direction.
7 years ago
Gun Pinyo 21dfa29c28 Add a layout of planck named GunP, ready for pull request review. 7 years ago
Bernardo Farah 4c960ad7c4 Added berfarah's custom keyboard layout 7 years ago
ajp10304 a08287b0a0 Added ajp10304 Planck layout (#1887)
* Added ajp10304 Planck layout

* Removed Makefile from planck ajp10304 keymap
7 years ago
alex-paget af83c6a4cb My layout to suit my needs 7 years ago
Damien e54c8df453 DZ60 changes (#1890)
* - 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
7 years ago
James c2b8a47604 Some finishing touches on space_oddity (#1892)
* Add verbose comments, ASCII layout pictures, and re-word readme.md

* Fix omission of F(2) on the third layer.
7 years ago
Dylan Khor 07ec609fad Missing line break in NIU Mini readme (#1886)
* Missing line break

* More specific URL to the product
7 years ago
mogranjm a66e75609e Added new TKL layout for the Frosty flake - Quickfire Rapid (#1854)
* First commit of the Terminus_Mini firmware and the DivergeJM version of the Nyquist firmware

* Fix terminus_mini & nyquist/DivergeJM readme files

Previously an outdated copy of the default readme. Updated to match the  Nyquist/DivergeJM format (DivergeJM is a split 5x12 implementation of the terminus_mini layout)

* Update makefiles to rules.mk

Renamed both Makefiles to rules.mk, removed references to makefiles

* Updated rules.mk

Inadvertantly removed important code from the rules.mk in previous commit. This has been restored.

Also disabled Tap_Dance in both rules.mk files

* Moved terminus_mini to handwired

Realised that existing directory was not appropriate for the terminus_mini project, moved to handwired.

* New Frosty Flake layout for QFR TKL

Added a TKL layout for the Frosty Flake with a navigation cluster on LOWER under the left hand and a similarly functioning MOUSE layer that includes mouse navigation functionality.
7 years ago
drashna f3534f999f Updated keymaps (#1853)
* Add woodpad

* Cleanup

* Remove misc layouts for woodpad

* Move woodpad to handwired

* Updated RGB Underglow info

* Cleanup macros

* Fix odd merge issue

* Tweaked RGB lighting stuff

* Start to merge orthodox/ergodox keymaps (persistant layers)

* Add forced NKRO

* Added Colemak and Dvorak layers to default orthodox keymap

* Added default layer (qwerty/colemak/dvorak) detection to RGB Underglow

* Updated macros and added workman keymaps

* Fixed RGB lighting for Workman layout

* Add leader keys

* Remove force NKRO

* Add Viterbi one handed layout and minor tweaks to others
7 years ago
mondaufgrau 22564d8ee7 Added xd60 ISO keymap (#1865)
* Added xd60 ISO keymap

* renamed ISO to iso

* some cleaning

* added iso keymap

* some cleaning
7 years ago
Carlos Filoteo 736140439d Add links to EEPROM files 7 years ago
Daniel Gordon 725aa5b820 Update to Tap-Dance Docs for Fast Typists
* Quad function tap dance works as intended when typing fast
    * Example 4 in doc has been updated

Change-Id: If33406299e2eed49152c495da92f4977dfdc1e2f
7 years ago
Jack Humbert 06f196c589 Creates a userspace for keymaps (#1559)
* create a user space

* adds example

* document, add readme.md

* jackhumbert userspace, ergodox keymap
7 years ago
skullY 9bb259b660 Fix the naming for clueboard files 7 years ago
James ab3dbd8daa Additional custom handwired layout - Space Oddity (#1868)
* Add existing file

* Add new keyboard layout - initial commit

* Revised readme.md

* Clarified readme.md, reorganized keymap.c, and added license text.

* Fixing last incomplete commit

* Just a little code cleanup to make things more readable.
7 years ago
Pittyolo 1954ad1fd8 Added my Let's Split layout (#1867)
* Add files via upload

* Add files via upload

* Add files via upload

* Add files via upload

* Update keymap.c

* Update keymap.c

* Update keymap.c

* Update keymap.c

* Add files via upload

* Add files via upload

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Add files via upload

* Adding my Let's Split layout

As in my Nyquist layout, ISO Hungrian friendly
7 years ago
James 3276c4c56a Minor punctuation and grammar edits. 7 years ago
Jason Rosenman 3a1ce56aed Added caps lock + key lock 7 years ago
Jason Rosenman 2f24ed1046 Turned off some unnecessary makefile rules 7 years ago
CarVac 50a4b3510b Revise carvac_dv keymap for easier alt-tab (#1871)
* Add carvac_dv keymap for mitosis

* Add mouse keys

* move backspace, etc, and fix tab

* remove commented-out functions in keymap

* Fix scroll buttons and add left/right scrolling

* Make num momentary, add comments, and clean up

* fix mouse scroll acceleration

* Add tab, remove bksp, move print screen

Having tab next to control and alt makes for much easier
alt-tabbing and ctrl-tabbing.

That displaced print screen, but I had never used the non-layer
backspace on the right hand, so I moved printscreen over there.
7 years ago
marcostrauss 57bf00f28f ErgoDone: VID/PID/NKRO (#1872)
* - Fancy default PID and option for corresponding VID.
- Information about official VID/PID.
- Correct manufacturer name.
- NKRO enabled by default.

* Resolved build error with `#ifndef FORCE_NKRO`.
7 years ago
heartrobotninja b25338a809 heartrobotninja ergodox_ez and lets_split layouts (#1874) 7 years ago
Jason Milkins 78923cb884 Fix code backticks on Frequently Asked Build Questions docs 7 years ago
Jason Milkins a860d9d628 Fix missing code backticks 7 years ago
Danny b5464cf20a Add Iris keyboard (#1863)
* Clone Nyquist code to Iris and rename

* Set keymap and pins

* Work in progress Iris default keymap

* Add Iris rev2

* Update Iris files to new build system

* Add lewisridden keymap
7 years ago
Daniel Gordon 383e508bc5 Quad Function Tap Dance added to TD Doc
* Added section to example, detailing how to accomplish the
        'quad-function' tap dance.
    * Refactored TD documentation to clearly separate different complex
        examples

Change-Id: Ifc1495d1142849c771418fdabc458c04c48311e6
7 years ago
skullydazed 3f3fa07918 Reorganize clueboard into a single directory (#1855) 7 years ago
skullydazed ad49db8cd2 Address #1689 by using a formula to define the breathing curve (#1692)
* Address #1689 by using a formula to define the breathing curve and exposing defines to control the shape of the curve.

* Tweak the behavior of breathing for clueboard
7 years ago
mogranjm d3fe6a0588 Add terminus_mini keyboard and nyquist/DivergeJM layout (#1851)
* First commit of the Terminus_Mini firmware and the DivergeJM version of the Nyquist firmware

* Fix terminus_mini & nyquist/DivergeJM readme files

Previously an outdated copy of the default readme. Updated to match the  Nyquist/DivergeJM format (DivergeJM is a split 5x12 implementation of the terminus_mini layout)

* Update makefiles to rules.mk

Renamed both Makefiles to rules.mk, removed references to makefiles

* Updated rules.mk

Inadvertantly removed important code from the rules.mk in previous commit. This has been restored.

Also disabled Tap_Dance in both rules.mk files

* Moved terminus_mini to handwired

Realised that existing directory was not appropriate for the terminus_mini project, moved to handwired.
7 years ago
Max Rumpf af4697cba5 Add Maxr1998's GH60 layout (#1849)
* Maxr1998's GH60 layout

* delete unused makefile

* Remove unneeded include
7 years ago

@ -0,0 +1,24 @@
-I.
-I./drivers
-I./drivers/avr
-I./keyboards/ergodox_ez
-I./keyboards/ergodox_ez/keymaps/vim
-I./lib
-I./lib/lufa
-I./quantum
-I./quantum/api
-I./quantum/audio
-I./quantum/keymap_extras
-I./quantum/process_keycode
-I./quantum/serial_link
-I./quantum/template
-I./quantum/tools
-I./quantum/visualizer
-I./tmk_core
-I./tmk_core/common
-I./tmk_core/common/debug.h
-I./tmk_core/protocol
-I./tmk_core/protocol/lufa
-I./util
-DQMK_KEYBOARD=\"$(KEYBOARD)\" -DQMK_KEYMAP=\"$(KEYMAP)\"

@ -0,0 +1,36 @@
# EditorConfig helps developers define and maintain consistent coding styles between different editors and IDEs
# editorconfig.org
root = true
[*]
indent_style = space
indent_size = 2
# We recommend you to keep these unchanged
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
[*.md]
trim_trailing_whitespace = false
indent_size = 4
# Make these match what we have in .gitattributes
[*.mk]
end_of_line = lf
[Makefile]
end_of_line = lf
[*.sh]
end_of_line = lf
# The gitattributes file will handle the line endings conversion properly according to the operating system settings for other files
# We don't have gitattributes properly for these
# So if the user have for example core.autocrlf set to true
# the line endings would be wrong.
[lib/**]
end_of_line = unset

13
.gitignore vendored

@ -4,6 +4,7 @@
*.eep
*.elf
*.hex
*.qmk
!util/bootloader.hex
!quantum/tools/eeprom_reset.hex
*.log
@ -21,27 +22,39 @@ build/
quantum/version.h
.idea/
CMakeLists.txt
cmake-build-debug
doxygen/
.DS_STORE
/util/wsl_downloaded
/util/win_downloaded
/keyboards/*/Makefile
/keyboards/*/*/Makefile
/keyboards/*/*/*/Makefile
/keyboards/*/*/*/*/Makefile
/keyboards/*/*/*/*/*/Makefile
/keyboards/*/keymaps/Makefile
/keyboards/*/*/keymaps/Makefile
/keyboards/*/*/*/keymaps/Makefile
/keyboards/*/*/*/*/keymaps/Makefile
/keyboards/*/*/*/*/*/keymaps/Makefile
# Eclipse/PyCharm/Other IDE Settings
.cproject
.project
.settings/
.idea
*.iml
.browse.VC.db*
*.stackdump
util/Win_Check_Output.txt
# Let these ones be user specific, since we have so many different configurations
.vscode/c_cpp_properties.json
.vscode/launch.json
.vscode/tasks.json
.vscode/last.sql
.vscode/temp.sql
.stfolder
.tags
# ignore image files
*.png

1
.gitmodules vendored

@ -4,6 +4,7 @@
[submodule "lib/chibios-contrib"]
path = lib/chibios-contrib
url = https://github.com/qmk/ChibiOS-Contrib
branch = k-type-fix
[submodule "lib/ugfx"]
path = lib/ugfx
url = https://github.com/qmk/uGFX

@ -11,15 +11,17 @@ env:
global:
- secure: vBTSL34BDPxDilKUuTXqU4CJ26Pv5hogD2nghatkxSQkI1/jbdnLj/DQdPUrMJFDIY6TK3AltsBx72MaMsLQ1JO/Ou24IeHINHXzUC1FlS9yQa48cpxnhX5kzXNyGs3oa0qaFbvnr7RgYRWtmD52n4bIZuSuW+xpBv05x2OCizdT2ZonH33nATaHGFasxROm4qYZ241VfzcUv766V6RVHgL4x9V08warugs+RENVkfzxxwhk3NmkrISabze0gSVJLHBPHxroZC6EUcf/ocobcuDrCwFqtEt90i7pNIAFUE7gZsN2uE75LmpzAWin21G7lLPcPL2k4FJVd8an1HiP2WmscJU6U89fOfMb2viObnKcCzebozBCmKGtHEuXZo9FcReOx49AnQSpmESJGs+q2dL/FApkTjQiyT4J6O5dJpoww0/r57Wx0cmmqjETKBb5rSgXM51Etk3wO09mvcPHsEwrT7qH8r9XWdyCDoEn7FCLX3/LYnf/D4SmZ633YPl5gv3v9XEwxR5+04akjgnvWDSNIaDbWBdxHNb7l4pMc+WR1bwCyMyA7KXj0RrftEGOrm9ZRLe6BkbT4cycA+j77nbPOMcyZChliV9pPQos+4TOJoTzcK2L8yWVoY409aDNVuAjdP6Yum0R2maBGl/etLmIMpJC35C5/lZ+dUNjJAM=
before_install:
- wget http://www.atmel.com/images/avr8-gnu-toolchain-3.5.4.1709-linux.any.x86_64.tar.gz || wget http://qmk.fm/avr8-gnu-toolchain-3.5.4.1709-linux.any.x86_64.tar.gz
- wget http://ww1.microchip.com/downloads/en/DeviceDoc/avr8-gnu-toolchain-3.5.4.1709-linux.any.x86_64.tar.gz || wget http://qmk.fm/avr8-gnu-toolchain-3.5.4.1709-linux.any.x86_64.tar.gz
install:
- tar -zxf avr8-gnu-toolchain-3.5.4.1709-linux.any.x86_64.tar.gz
- export PATH="$PATH:$TRAVIS_BUILD_DIR/avr8-gnu-toolchain-linux_x86_64/bin"
- npm install -g moxygen
before_script:
- avr-gcc --version
script:
- make test:all AUTOGEN=false
- bash util/travis_build.sh
- bash util/travis_docs.sh
addons:
apt:
packages:
@ -30,6 +32,7 @@ addons:
- libnewlib-arm-none-eabi
- diffutils
- dos2unix
- doxygen
after_success:
bash util/travis_compiled_push.sh
notifications:
@ -38,4 +41,4 @@ notifications:
- https://webhooks.gitter.im/e/afce403d65f143dfac09
on_success: always # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
on_start: never # options: [always|never|change] default: always
on_start: never # options: [always|never|change] default: always

@ -0,0 +1,6 @@
// Suggested extensions
{
"recommendations": [
"EditorConfig.EditorConfig"
]
}

@ -0,0 +1,266 @@
# Doxyfile 1.8.14
# This file describes the settings to be used by the documentation system
# doxygen (www.doxygen.org) for qmk_firmware (github.com/qmk/qmk_firmware)
#
# All text after a double hash (##) is considered a comment and is placed in
# front of the TAG it is preceding.
#
# All text after a single hash (#) is considered a comment and will be ignored.
# The format is:
# TAG = value [value, ...]
# For lists, items can also be appended using:
# TAG += value [value, ...]
# Values that contain spaces should be placed between quotes (\" \").
#---------------------------------------------------------------------------
# Project related configuration options
#---------------------------------------------------------------------------
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = "QMK Firmware"
PROJECT_NUMBER = https://github.com/qmk/qmk_firmware
PROJECT_BRIEF = "Keyboard controller firmware for Atmel AVR and ARM USB families"
OUTPUT_DIRECTORY = doxygen
ALLOW_UNICODE_NAMES = NO
OUTPUT_LANGUAGE = English
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ABBREVIATE_BRIEF = "The $name class" \
"The $name widget" \
"The $name file" \
is \
provides \
specifies \
contains \
represents \
a \
an \
the
ALWAYS_DETAILED_SEC = NO
INLINE_INHERITED_MEMB = NO
FULL_PATH_NAMES = YES
STRIP_FROM_PATH =
STRIP_FROM_INC_PATH =
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = NO
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
INHERIT_DOCS = YES
SEPARATE_MEMBER_PAGES = NO
TAB_SIZE = 4
ALIASES =
TCL_SUBST =
OPTIMIZE_OUTPUT_FOR_C = YES
OPTIMIZE_OUTPUT_JAVA = NO
OPTIMIZE_FOR_FORTRAN = NO
OPTIMIZE_OUTPUT_VHDL = NO
EXTENSION_MAPPING =
MARKDOWN_SUPPORT = YES
TOC_INCLUDE_HEADINGS = 2
AUTOLINK_SUPPORT = YES
BUILTIN_STL_SUPPORT = NO
CPP_CLI_SUPPORT = NO
SIP_SUPPORT = NO
IDL_PROPERTY_SUPPORT = YES
DISTRIBUTE_GROUP_DOC = NO
GROUP_NESTED_COMPOUNDS = NO
SUBGROUPING = YES
INLINE_GROUPED_CLASSES = NO
INLINE_SIMPLE_STRUCTS = NO
TYPEDEF_HIDES_STRUCT = NO
LOOKUP_CACHE_SIZE = 0
#---------------------------------------------------------------------------
# Build related configuration options
#---------------------------------------------------------------------------
EXTRACT_ALL = NO
EXTRACT_PRIVATE = NO
EXTRACT_PACKAGE = NO
EXTRACT_STATIC = NO
EXTRACT_LOCAL_CLASSES = YES
EXTRACT_LOCAL_METHODS = NO
EXTRACT_ANON_NSPACES = NO
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = NO
HIDE_SCOPE_NAMES = YES
HIDE_COMPOUND_REFERENCE= NO
SHOW_INCLUDE_FILES = YES
SHOW_GROUPED_MEMB_INC = NO
FORCE_LOCAL_INCLUDES = NO
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = NO
SORT_MEMBERS_CTORS_1ST = NO
SORT_GROUP_NAMES = NO
SORT_BY_SCOPE_NAME = NO
STRICT_PROTO_MATCHING = NO
GENERATE_TODOLIST = YES
GENERATE_TESTLIST = YES
GENERATE_BUGLIST = YES
GENERATE_DEPRECATEDLIST= YES
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
SHOW_USED_FILES = YES
SHOW_FILES = YES
SHOW_NAMESPACES = YES
FILE_VERSION_FILTER =
LAYOUT_FILE =
CITE_BIB_FILES =
#---------------------------------------------------------------------------
# Configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_NO_PARAMDOC = NO
WARN_AS_ERROR = NO
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# Configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = tmk_core quantum drivers
INPUT_ENCODING = UTF-8
FILE_PATTERNS = *.c \
*.cc \
*.cxx \
*.cpp \
*.c++ \
*.h \
*.hh \
*.hxx \
*.hpp \
*.h++
RECURSIVE = YES
EXCLUDE =
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXCLUDE_SYMBOLS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS = *
EXAMPLE_RECURSIVE = NO
IMAGE_PATH =
INPUT_FILTER =
FILTER_PATTERNS =
FILTER_SOURCE_FILES = NO
FILTER_SOURCE_PATTERNS =
USE_MDFILE_AS_MAINPAGE =
#---------------------------------------------------------------------------
# Configuration options related to source browsing
#---------------------------------------------------------------------------
SOURCE_BROWSER = YES
INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = NO
REFERENCES_RELATION = NO
REFERENCES_LINK_SOURCE = YES
SOURCE_TOOLTIPS = YES
USE_HTAGS = NO
VERBATIM_HEADERS = YES
#---------------------------------------------------------------------------
# Configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = YES
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# Configuration options related to disabled outputs
#---------------------------------------------------------------------------
GENERATE_HTML = NO
GENERATE_LATEX = NO
GENERATE_RTF = NO
GENERATE_MAN = NO
GENERATE_DOCBOOK = NO
GENERATE_AUTOGEN_DEF = NO
GENERATE_PERLMOD = NO
#---------------------------------------------------------------------------
# Configuration options related to the XML output
#---------------------------------------------------------------------------
GENERATE_XML = YES
XML_OUTPUT = xml
XML_PROGRAMLISTING = YES
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
ENABLE_PREPROCESSING = YES
MACRO_EXPANSION = NO
EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
PREDEFINED =
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
# Configuration options related to external references
#---------------------------------------------------------------------------
TAGFILES =
GENERATE_TAGFILE =
ALLEXTERNALS = NO
EXTERNAL_GROUPS = YES
EXTERNAL_PAGES = YES
PERL_PATH = /usr/bin/perl
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
CLASS_DIAGRAMS = YES
MSCGEN_PATH =
DIA_PATH =
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = NO
DOT_NUM_THREADS = 0
DOT_FONTNAME = Helvetica
DOT_FONTSIZE = 10
DOT_FONTPATH =
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
GROUP_GRAPHS = YES
UML_LOOK = NO
UML_LIMIT_NUM_FIELDS = 10
TEMPLATE_RELATIONS = NO
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
CALL_GRAPH = NO
CALLER_GRAPH = NO
GRAPHICAL_HIERARCHY = YES
DIRECTORY_GRAPH = YES
DOT_IMAGE_FORMAT = png
INTERACTIVE_SVG = NO
DOT_PATH =
DOTFILE_DIRS =
MSCFILE_DIRS =
DIAFILE_DIRS =
PLANTUML_JAR_PATH =
PLANTUML_CFG_FILE =
PLANTUML_INCLUDE_PATH =
DOT_GRAPH_MAX_NODES = 50
MAX_DOT_GRAPH_DEPTH = 0
DOT_TRANSPARENT = NO
DOT_MULTI_TARGETS = NO
GENERATE_LEGEND = YES
DOT_CLEANUP = YES

@ -0,0 +1,339 @@
GNU GENERAL PUBLIC LICENSE
Version 2, June 1991
Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users. This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it. (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.) You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have. You must make sure that they, too, receive or can get the
source code. And you must show them these terms so they know their
rights.
We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.
Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software. If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary. To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.
The precise terms and conditions for copying, distribution and
modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language. (Hereinafter, translation is included without limitation in
the term "modification".) Each licensee is addressed as "you".
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.
1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.
You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.
2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) You must cause the modified files to carry prominent notices
stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License.
c) If the modified program normally reads commands interactively
when run, you must cause it, when started running for such
interactive use in the most ordinary way, to print or display an
announcement including an appropriate copyright notice and a
notice that there is no warranty (or else, saying that you provide
a warranty) and that users may redistribute the program under
these conditions, and telling the user how to view a copy of this
License. (Exception: if the Program itself is interactive but
does not normally print such an announcement, your work based on
the Program is not required to print an announcement.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.
In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:
a) Accompany it with the complete corresponding machine-readable
source code, which must be distributed under the terms of Sections
1 and 2 above on a medium customarily used for software interchange; or,
b) Accompany it with a written offer, valid for at least three
years, to give any third party, for a charge no more than your
cost of physically performing source distribution, a complete
machine-readable copy of the corresponding source code, to be
distributed under the terms of Sections 1 and 2 above on a medium
customarily used for software interchange; or,
c) Accompany it with the information you received as to the offer
to distribute corresponding source code. (This alternative is
allowed only for noncommercial distribution and only if you
received the program in object code or executable form with such
an offer, in accord with Subsection b above.)
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.
If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.
4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.
5. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Program or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.
6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.
7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all. For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation. If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.
10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission. For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this. Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.
NO WARRANTY
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
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, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
Also add information on how to contact you by electronic and paper mail.
If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:
Gnomovision version 69, Copyright (C) year name of author
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
`Gnomovision' (which makes passes at compilers) written by James Hacker.
<signature of Ty Coon>, 1 April 1989
Ty Coon, President of Vice
This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License.

@ -19,10 +19,12 @@ endif
# Otherwise the [OK], [ERROR] and [WARN] messages won't be displayed correctly
override SILENT := false
ifndef SUB_IS_SILENT
QMK_VERSION := $(shell git describe --abbrev=0 --tags 2>/dev/null)
ifneq ($(QMK_VERSION),)
$(info QMK Firmware $(QMK_VERSION))
endif
endif
ON_ERROR := error_occurred=1
@ -114,6 +116,20 @@ list-keyboards:
echo $(KEYBOARDS)
exit 0
define PRINT_KEYBOARD
$(info $(PRINTING_KEYBOARD))
endef
generate-keyboards-file:
$(foreach PRINTING_KEYBOARD,$(KEYBOARDS),$(eval $(call PRINT_KEYBOARD)))
exit 0
clean:
echo -n 'Deleting .build ... '
rm -rf $(BUILD_DIR)
echo 'done'
exit 0
#Compatibility with the old make variables, anything you specify directly on the command line
# always overrides the detected folders
ifdef keyboard

@ -0,0 +1,62 @@
# Copyright 2017 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/>.
# If it's possible that multiple bootloaders can be used for one project,
# you can leave this unset, and the correct size will be selected
# automatically.
#
# Sets the bootloader defined in the keyboard's/keymap's rules.mk
# Current options:
# atmel-dfu
# lufa-dfu
# qmk-dfu
# halfkay
# caterina
# bootloadHID
#
# BOOTLOADER_SIZE can still be defined manually, but it's recommended
# you add any possible configuration to this list
ifeq ($(strip $(BOOTLOADER)), atmel-dfu)
OPT_DEFS += -DBOOTLOADER_ATMEL_DFU
OPT_DEFS += -DBOOTLOADER_DFU
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(BOOTLOADER)), lufa-dfu)
OPT_DEFS += -DBOOTLOADER_LUFA_DFU
OPT_DEFS += -DBOOTLOADER_DFU
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(BOOTLOADER)), qmk-dfu)
OPT_DEFS += -DBOOTLOADER_QMK_DFU
OPT_DEFS += -DBOOTLOADER_DFU
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(BOOTLOADER)), halfkay)
OPT_DEFS += -DBOOTLOADER_HALFKAY
BOOTLOADER_SIZE = 512
endif
ifeq ($(strip $(BOOTLOADER)), caterina)
OPT_DEFS += -DBOOTLOADER_CATERINA
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(BOOTLOADER)), bootloadHID)
OPT_DEFS += -DBOOTLOADER_BOOTLOADHID
BOOTLOADER_SIZE = 4096
endif
ifdef BOOTLOADER_SIZE
OPT_DEFS += -DBOOTLOADER_SIZE=$(strip $(BOOTLOADER_SIZE))
endif

@ -94,15 +94,33 @@ endif
OPT_DEFS += -DKEYBOARD_$(KEYBOARD_FILESAFE)
ifneq ("$(wildcard $(KEYBOARD_PATH_1)/$(KEYBOARD_FOLDER_1).h)","")
QMK_KEYBOARD_H = $(KEYBOARD_FOLDER_1).h
endif
ifneq ("$(wildcard $(KEYBOARD_PATH_2)/$(KEYBOARD_FOLDER_2).h)","")
QMK_KEYBOARD_H = $(KEYBOARD_FOLDER_2).h
endif
ifneq ("$(wildcard $(KEYBOARD_PATH_3)/$(KEYBOARD_FOLDER_3).h)","")
QMK_KEYBOARD_H = $(KEYBOARD_FOLDER_3).h
endif
ifneq ("$(wildcard $(KEYBOARD_PATH_4)/$(KEYBOARD_FOLDER_4).h)","")
QMK_KEYBOARD_H = $(KEYBOARD_FOLDER_4).h
endif
ifneq ("$(wildcard $(KEYBOARD_PATH_5)/$(KEYBOARD_FOLDER_5).h)","")
QMK_KEYBOARD_H = $(KEYBOARD_FOLDER_5).h
endif
# We can assume a ChibiOS target When MCU_FAMILY is defined , since it's not used for LUFA
ifdef MCU_FAMILY
FIRMWARE_FORMAT=bin
PLATFORM=CHIBIOS
else
PLATFORM=AVR
FIRMWARE_FORMAT=hex
endif
ifeq ($(PLATFORM),CHIBIOS)
include $(TMK_PATH)/protocol/chibios.mk
include $(TMK_PATH)/chibios.mk
OPT_OS = chibios
ifneq ("$(wildcard $(KEYBOARD_PATH_5)/bootloader_defs.h)","")
@ -125,6 +143,8 @@ ifeq ($(PLATFORM),CHIBIOS)
OPT_DEFS += -include $(KEYBOARD_PATH_1)/bootloader_defs.h
else ifneq ("$(wildcard $(KEYBOARD_PATH_1)/boards/$(BOARD)/bootloader_defs.h)","")
OPT_DEFS += -include $(KEYBOARD_PATH_1)/boards/$(BOARD)/bootloader_defs.h
else ifneq ("$(wildcard $(TOP_DIR)/drivers/boards/$(BOARD)/bootloader_defs.h)","")
OPT_DEFS += -include $(TOP_DIR)/drivers/boards/$(BOARD)/bootloader_defs.h
endif
endif
@ -178,11 +198,23 @@ else ifneq ("$(wildcard $(MAIN_KEYMAP_PATH_1)/keymap.c)","")
KEYMAP_PATH := $(MAIN_KEYMAP_PATH_1)
else ifneq ($(LAYOUTS),)
include build_layout.mk
else
else
$(error Could not find keymap)
# this state should never be reached
endif
# User space stuff
ifeq ("$(USER_NAME)","")
USER_NAME := $(KEYMAP)
endif
USER_PATH := users/$(USER_NAME)
-include $(USER_PATH)/rules.mk
ifneq ("$(wildcard users/$(KEYMAP)/config.h)","")
CONFIG_H += users/$(KEYMAP)/config.h
endif
# Object files directory
# To put object files in current directory, use a dot (.), do NOT make
# this an empty or blank macro!
@ -204,10 +236,12 @@ SRC += $(KEYBOARD_SRC) \
VPATH += $(KEYMAP_PATH)
VPATH += $(KEYBOARD_PATHS)
VPATH += $(COMMON_VPATH)
VPATH += $(USER_PATH)
include common_features.mk
include $(TMK_PATH)/protocol.mk
include $(TMK_PATH)/common.mk
include bootloader.mk
SRC += $(TMK_COMMON_SRC)
OPT_DEFS += $(TMK_COMMON_DEFS)
@ -222,16 +256,22 @@ endif
include $(TMK_PATH)/avr.mk
endif
ifeq ($(PLATFORM),CHIBIOS)
include $(TMK_PATH)/protocol/chibios.mk
endif
ifeq ($(strip $(VISUALIZER_ENABLE)), yes)
VISUALIZER_DIR = $(QUANTUM_DIR)/visualizer
VISUALIZER_PATH = $(QUANTUM_PATH)/visualizer
include $(VISUALIZER_PATH)/visualizer.mk
endif
ALL_CONFIGS := $(PROJECT_CONFIG) $(CONFIG_H)
OUTPUTS := $(KEYMAP_OUTPUT) $(KEYBOARD_OUTPUT)
$(KEYMAP_OUTPUT)_SRC := $(SRC)
$(KEYMAP_OUTPUT)_DEFS := $(OPT_DEFS) $(GFXDEFS) \
-DQMK_KEYBOARD=\"$(KEYBOARD)\" -DQMK_KEYBOARD_H=\"$(KEYBOARD_FOLDER_1).h\" -DQMK_KEYBOARD_CONFIG_H=\"$(KEYBOARD_PATH_1)/config.h\" \
-DQMK_KEYBOARD=\"$(KEYBOARD)\" -DQMK_KEYBOARD_H=\"$(QMK_KEYBOARD_H)\" -DQMK_KEYBOARD_CONFIG_H=\"$(KEYBOARD_PATH_1)/config.h\" \
-DQMK_KEYMAP=\"$(KEYMAP)\" -DQMK_KEYMAP_H=\"$(KEYMAP).h\" -DQMK_KEYMAP_CONFIG_H=\"$(KEYMAP_PATH)/config.h\" \
-DQMK_SUBPROJECT -DQMK_SUBPROJECT_H -DQMK_SUBPROJECT_CONFIG_H
$(KEYMAP_OUTPUT)_INC := $(VPATH) $(EXTRAINCDIRS)
@ -242,10 +282,10 @@ $(KEYBOARD_OUTPUT)_INC := $(PROJECT_INC) $(GFXINC)
$(KEYBOARD_OUTPUT)_CONFIG := $(PROJECT_CONFIG)
# Default target.
all: build sizeafter
all: build check-size
# Change the build target to build a HEX file or a library.
build: elf hex
build: elf cpfirmware
#build: elf hex eep lss sym
#build: lib

@ -34,7 +34,12 @@ ifeq ($(strip $(AUDIO_ENABLE)), yes)
OPT_DEFS += -DAUDIO_ENABLE
MUSIC_ENABLE := 1
SRC += $(QUANTUM_DIR)/process_keycode/process_audio.c
SRC += $(QUANTUM_DIR)/audio/audio.c
SRC += $(QUANTUM_DIR)/process_keycode/process_clicky.c
ifeq ($(PLATFORM),AVR)
SRC += $(QUANTUM_DIR)/audio/audio.c
else
SRC += $(QUANTUM_DIR)/audio/audio_arm.c
endif
SRC += $(QUANTUM_DIR)/audio/voices.c
SRC += $(QUANTUM_DIR)/audio/luts.c
endif
@ -70,6 +75,8 @@ ifeq ($(strip $(FAUXCLICKY_ENABLE)), yes)
endif
ifeq ($(strip $(POINTING_DEVICE_ENABLE)), yes)
OPT_DEFS += -DPOINTING_DEVICE_ENABLE
OPT_DEFS += -DMOUSE_ENABLE
SRC += $(QUANTUM_DIR)/pointing_device.c
endif
@ -126,6 +133,9 @@ endif
ifeq ($(strip $(AUTO_SHIFT_ENABLE)), yes)
OPT_DEFS += -DAUTO_SHIFT_ENABLE
SRC += $(QUANTUM_DIR)/process_keycode/process_auto_shift.c
ifeq ($(strip $(AUTO_SHIFT_MODIFIERS)), yes)
OPT_DEFS += -DAUTO_SHIFT_MODIFIERS
endif
endif
ifeq ($(strip $(SERIAL_LINK_ENABLE)), yes)
@ -149,6 +159,9 @@ endif
ifeq ($(strip $(BACKLIGHT_ENABLE)), yes)
ifeq ($(strip $(VISUALIZER_ENABLE)), yes)
CIE1931_CURVE = yes
endif
ifeq ($(strip $(BACKLIGHT_CUSTOM_DRIVER)), yes)
OPT_DEFS += -DBACKLIGHT_CUSTOM_DRIVER
endif
endif

@ -4,13 +4,13 @@
QMK (*Quantum Mechanical Keyboard*) is an open source community that maintains QMK Firmware, QMK Flasher, qmk.fm, and these docs. QMK Firmware is a keyboard firmware based on the [tmk\_keyboard](http://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR controllers, and more specifically, the [OLKB product line](http://olkb.com), the [ErgoDox EZ](http://www.ergodox-ez.com) keyboard, and the [Clueboard product line](http://clueboard.co/). It has also been ported to ARM chips using ChibiOS. You can use it to power your own hand-wired or custom keyboard PCB.
## How to get it {#how-to-get-it}
## How to Get It {#how-to-get-it}
If you plan on contributing a keymap, keyboard, or features to QMK, the easiest thing to do is [fork the repo through Github](https://github.com/qmk/qmk_firmware#fork-destination-box), and clone your repo locally to make your changes, push them, then open a [Pull Request](https://github.com/qmk/qmk_firmware/pulls) from your fork.
Otherwise, you can either download it directly ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), or clone it via git (`git@github.com:qmk/qmk_firmware.git`), or https (`https://github.com/qmk/qmk_firmware.git`).
## How to compile {#how-to-compile}
## How to Compile {#how-to-compile}
Before you are able to compile, you'll need to [install an environment](getting_started_build_tools.md) for AVR or/and ARM development. Once that is complete, you'll use the `make` command to build a keyboard and keymap with the following notation:
@ -20,6 +20,6 @@ This would build the `rev4` revision of the `planck` with the `default` keymap.
make preonic:default
## How to customize {#how-to-customize}
## How to Customize {#how-to-customize}
QMK has lots of [features](features.md) to explore, and a good deal of [reference documentation](http://docs.qmk.fm) to dig through. Most features are taken advantage of by modifying your [keymap](keymap.md), and changing the [keycodes](keycodes.md).

@ -1,10 +1,18 @@
* [Getting started](README.md)
* [Getting Started](README.md)
* [QMK Introduction](getting_started_introduction.md)
* [Install Build Tools](getting_started_build_tools.md)
* Alternative: [Vagrant Guide](getting_started_vagrant_guide.md)
* [Build/Compile instructions](getting_started_make_guide.md)
* Alternative: [Vagrant Guide](getting_started_vagrant.md)
* [Build/Compile Instructions](getting_started_make_guide.md)
* [Flashing Firmware](flashing.md)
* [Contributing to QMK](contributing.md)
* [How to Use Github](getting_started_github.md)
* [Getting Help](getting_started_getting_help.md)
* [Complete Newbs Guide](newbs.md)
* [Getting Started](newbs_getting_started.md)
* [Building Your First Firmware](newbs_building_firmware.md)
* [Flashing Firmware](newbs_flashing.md)
* [Testing and Debugging](newbs_testing_debugging.md)
* [FAQ](faq.md)
* [General FAQ](faq_general.md)
@ -12,56 +20,66 @@
* [Debugging/Troubleshooting QMK](faq_debug.md)
* [Keymap](faq_keymap.md)
* [Hardware](hardware.md)
* [Keyboard Guidelines](hardware_keyboard_guidelines.md)
* [AVR Processors](hardware_avr.md)
* ARM Processors (TBD)
* [Drivers](hardware_drivers.md)
* [Features](features.md)
* [Layouts](feature_layouts.md)
* [Common Shortcuts](feature_common_shortcuts.md)
* [Advanced Keycodes](feature_advanced_keycodes.md)
* [Audio](feature_audio.md)
* [Auto Shift](feature_auto_shift.md)
* [Backlight](feature_backlight.md)
* [Bootmagic](feature_bootmagic.md)
* [Dynamic Macros](dynamic_macros.md)
* [Key Lock](key_lock.md)
* [Command](feature_command.md)
* [Dynamic Macros](feature_dynamic_macros.md)
* [Grave Escape](feature_grave_esc.md)
* [Key Lock](feature_key_lock.md)
* [Layouts](feature_layouts.md)
* [Leader Key](feature_leader_key.md)
* [Macros](macros.md)
* [Mouse keys](mouse_keys.md)
* [Macros](feature_macros.md)
* [Mouse Keys](feature_mouse_keys.md)
* [Pointing Device](feature_pointing_device.md)
* [PS2 Mouse](feature_ps2_mouse.md)
* [Space Cadet](space_cadet_shift.md)
* [Tap Dance](tap_dance.md)
* [Audio](feature_audio.md)
* [Thermal Printer](feature_thermal_printer.md)
* [Stenography](stenography.md)
* [Unicode](unicode.md)
* [PS/2 Mouse](feature_ps2_mouse.md)
* [RGB Lighting](feature_rgblight.md)
* [Space Cadet](feature_space_cadet.md)
* [Stenography](feature_stenography.md)
* [Swap Hands](feature_swap_hands.md)
* [Tap Dance](feature_tap_dance.md)
* [Terminal](feature_terminal.md)
* [Thermal Printer](feature_thermal_printer.md)
* [Unicode](feature_unicode.md)
* [Userspace](feature_userspace.md)
* [Keycodes](keycodes.md)
* [Backlight](feature_backlight.md#backlight-keycodes)
* [Basic](keycodes_basic.md)
* [Bluetooth](feature_bluetooth.md#bluetooth-keycodes)
* [Bootmagic](feature_bootmagic.md#bootmagic-keycodes)
* [Layer Switching](feature_advanced_keycodes.md#switching-and-toggling-layers)
* [Mod+Key](feature_advanced_keycodes.md#modifier-keys)
* [Mod Tap](feature_advanced_keycodes.md#mod-tap)
* [One Shot Keys](feature_advanced_keycodes.md#one-shot-keys)
* [Quantum](quantum_keycodes.md)
* [RGB Light](feature_rgblight.md#rgblight-keycodes)
* [Shifted Keys](feature_advanced_keycodes.md#shifted-keycodes)
* [Stenography](feature_stenography.md#keycode-reference)
* [Thermal Printer](feature_thermal_printer.md#thermal-printer-keycodes)
* [US ANSI Shifted Keys](keycodes_us_ansi_shifted.md)
* Reference
* [Glossary](glossary.md)
* [Keymap overview](keymap.md)
* [Keycodes](keycodes.md)
* [Basic](keycodes_basic.md)
* [Quantum](quantum_keycodes.md)
* [Backlight](feature_backlight.md#backlight-keycodes)
* [Bluetooth](feature_bluetooth.md#bluetooth-keycodes)
* [Bootmagic](feature_bootmagic.md#bootmagic-keycodes)
* [Layer Switching](feature_common_shortcuts.md#switching-and-toggling-layers)
* [Mod+Key](feature_common_shortcuts.md#modifier-keys)
* [Mod Tap](feature_common_shortcuts.md#mod-tap)
* [One Shot Keys](feature_common_shortcuts.md#one-shot-keys)
* [Shifted Keys](feature_common_shortcuts.md#shifted-keycodes)
* [Stenography](stenography.md#keycode-reference)
* [RGB Light](feature_rgblight.md#rgblight-keycodes)
* [Thermal Printer](feature_thermal_printer.md#thermal-printer-keycodes)
* [US ANSI Shifted Keys](keycodes_us_ansi_shifted.md)
* [The `config.h` File](config_options.md)
* [Config Options](config_options.md)
* [Customizing Functionality](custom_quantum_functions.md)
* [Documentation Best Practices](documentation_best_practices.md)
* [Documentation Templates](documentation_templates.md)
* [Glossary](reference_glossary.md)
* [Keymap Overview](keymap.md)
* [Unit Testing](unit_testing.md)
* For Makers and Modders
* [Adding a keyboard to QMK](adding_a_keyboard_to_qmk.md)
* [Hand Wiring Guide](hand_wiring.md)
* [ISP flashing guide](isp_flashing_guide.md)
* [Modding your keyboard](modding_your_keyboard.md)
* [Porting your keyboard to QMK](porting_your_keyboard_to_qmk.md)
* [Hand Wiring Guide](hand_wire.md)
* [ISP Flashing Guide](isp_flashing_guide.md)
* For a Deeper Understanding
* [How Keyboards Work](how_keyboards_work.md)
@ -69,3 +87,12 @@
* Other Topics
* [Using Eclipse with QMK](eclipse.md)
* QMK Internals (In Progress)
* [Defines](internals_defines.md)
* [Input Callback Reg](internals_input_callback_reg.md)
* [Midi Device](internals_midi_device.md)
* [Midi Device Setup Process](internals_midi_device_setup_process.md)
* [Midi Util](internals_midi_util.md)
* [Send Functions](internals_send_functions.md)
* [Sysex Tools](internals_sysex_tools.md)

@ -1,35 +0,0 @@
# Adding your keyboard to QMK
We welcome all keyboard projects into QMK, but ask that you try to stick to a couple guidelines that help us keep things organised and consistent.
## Naming your directory/project
All names should be lowercase alphanumeric, and separated by an underscore (`_`), but not begin with one. Your directory and your `.h` and `.c` files should have exactly the same name. All folders should follow the same format.
## `readme.md`
All projects need to have a `readme.md` file that explains what the keyboard is, who made it, where it is available, and links to move information (template coming).
## Image/Hardware files
In an effort to keep the repo size down, we're no longer accepting images of any format in the repo, with few exceptions. Hosting them elsewhere (imgur) and linking them in the readme.md is the preferred method.
Any sort of hardware file (plate, case, pcb) can't be stored in qmk_firmware, but we have the [qmk.fm repo](https://github.com/qmk/qmk.fm) where such files (as well as in-depth info) can be store, and viewed on [qmk.fm](http://qmk.fm). Downloadable files are stored in `/<keyboard>/` (name follows the same format as above) which are served at `http://qmk.fm/<keyboard>/`, and pages are generated from `/_pages/<keyboard>/` which are served at the same location (.md files are generated into .html files through Jekyll). Check out the `lets_split` directory for an example.
## Non-production/handwired projects
We're happy to accept any project that uses QMK, including prototypes and handwired ones, but we have a separate `/keyboards/handwired/` folder for them, so the main `/keyboards/` folder doesn't get overcrowded. If a prototype project becomes a production project at some point in the future, we'd be happy to move it to the main `/keyboards/` folder!
## Warnings as errors
When developing your keyboard, keep in mind that all warnings will be treated as errors - these small warnings can build-up and cause larger errors down the road (and keeping them is generally a bad practice).
## Licenses
If you're adapting your keyboard's setup from another project, but not using the same code, but sure to update the copyright header at the top of the files to show your name, in this format:
Copyright 2017 Your Name <your@email.com>
## Technical details
If you're looking for more information on making your keyboard work with QMK, [check out this guide](porting_your_keyboard_to_qmk.md)!

@ -4,4 +4,4 @@ A QMK collaborator is a keyboard maker/designer that is interested in helping QM
* **Maintain the your keyboard's directory** - this may just require an initial setup to get your keyboard working, but it could also include accommodating changes made to QMK's core.
* **Approve and merge your keyboard's keymap pull requests** - we like to encourage users to contribute their keymaps for others to see and work from when creating their own.
If you feel you meet these requirements, shoot us an email at hello@qmk.fm with an introduction and some links to your keyboard!
If you feel you meet these requirements, shoot us an email at hello@qmk.fm with an introduction and some links to your keyboard!

@ -22,4 +22,4 @@ You can also use any ARM processor that [ChibiOS](http://www.chibios.org) suppor
* [Kinetis MKL26Z64](http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/kinetis-cortex-m-mcus/l-series-ultra-low-power-m0-plus/kinetis-kl2x-48-mhz-usb-ultra-low-power-microcontrollers-mcus-based-on-arm-cortex-m0-plus-core:KL2x)
* [Kinetis MK20DX128](http://www.nxp.com/assets/documents/data/en/data-sheets/K20P64M50SF0.pdf)
* [Kinetis MK20DX128](http://www.nxp.com/assets/documents/data/en/data-sheets/K20P64M50SF0.pdf)
* [Kinetis MK20DX256](http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/kinetis-cortex-m-mcus/k-series-performance-m4/k2x-usb/kinetis-k20-72-mhz-full-speed-usb-mixed-signal-integration-microcontrollers-mcus-based-on-arm-cortex-m4-core:K20_72)
* [Kinetis MK20DX256](http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/kinetis-cortex-m-mcus/k-series-performance-m4/k2x-usb/kinetis-k20-72-mhz-full-speed-usb-mixed-signal-integration-microcontrollers-mcus-based-on-arm-cortex-m4-core:K20_72)

@ -1,129 +1,226 @@
# The `config.h` file
# Configuring QMK
This is a c header file that is one of the first things included, and will persist over the whole project (if included). Lots of variables can be set here and accessed elsewhere (namely keymaps). This file can exist at a couple different levels:
QMK is nearly infinitely configurable. Wherever possible we err on the side of allowing users to customize their keyboard, even at the expense of code size. That level of flexibility makes for a daunting configuration experience, however.
## Keyboard
```c
#ifndef CONFIG_H
#define CONFIG_H
#include "config_common.h"
// config options
There are two main types of configuration files in QMK- `config.h` and `rules.mk`. These files exist at various levels in QMK and all files of the same type are combined to build the final configuration. The levels, from lowest priority to highest priority, are:
#endif
```
* QMK Default
* Keyboard
* Folders (Up to 5 levels deep)
* Keymap
This file contains config options that should apply to the whole keyboard, and won't change in revisions, or most keymaps. The revision block here only applies to keyboards with revisions.
## QMK Default
## Revisions
Every available setting in QMK has a default. If that setting is not set at the Keyboard, Folder, or Keymap level this is the setting that will be used.
```c
#ifndef <revision>_CONFIG_H
#define <revision>_CONFIG_H
#include "config_common.h"
## Keyboard
// config options
This level contains config options that should apply to the whole keyboard. Some settings won't change in revisions, or most keymaps. Other settings are merely defaults for this keyboard and can be overridden by folders and/or keymaps.
#endif
```
## Folders
For keyboards that have revisions, this file contains config options that should apply to only that revisions, and won't change in most keymaps.
Some keyboards have folders and sub-folders to allow for different hardware configurations. Most keyboards only go 1 folder deep, but QMK supports structures up to 5 folders deep. Each folder can have its own `config.h` and `rules.mk` files that are incorporated into the final configuration.
## Keymap
```c
#ifndef CONFIG_USER_H
#define CONFIG_USER_H
#include "config_common.h"
// config options
#endif
```
This file contains all of the options for that particular keymap. If you wish to override a previous declaration, you can use `#undef <variable>` to undefine it, where you can then redefine it without an error.
# Config Options
```c
#define VENDOR_ID 0x1234 // defines your VID, and for most DIY projects, can be whatever you want
#define PRODUCT_ID 0x5678 // defines your PID, and for most DIY projects, can be whatever you want
#define DEVICE_VER 0 // defines the device version (often used for revisions)
#define MANUFACTURER Me // generally who/whatever brand produced the board
#define PRODUCT Board // the name of the keyboard
#define DESCRIPTION a keyboard // a short description of what the keyboard is
#define MATRIX_ROWS 5 // the number of rows in your keyboard's matrix
#define MATRIX_COLS 15 // the number of columns in your keyboard's matrix
#define MATRIX_ROW_PINS { D0, D5, B5, B6 } // pins of the rows, from top to bottom
#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7 } // pins of the columns, from left to right
#define UNUSED_PINS { D1, D2, D3, B1, B2, B3 } // pins unused by the keyboard for reference
#define MATRIX_HAS_GHOST // define is matrix has ghost (unlikely)
#define DIODE_DIRECTION COL2ROW // COL2ROW or ROW2COL - how your matrix is configured
// COL2ROW means the black mark on your diode is facing to the rows, and between the switch and the rows
#define AUDIO_VOICES // turns on the alternate audio voices (to cycle through)
#define C6_AUDIO // enables audio on pin C6
#define B5_AUDIO // enables audio on pin B5 (duophony is enable if both are enabled)
#define BACKLIGHT_PIN B7 // pin of the backlight - B5, B6, B7 use PWM, others use softPWM
#define BACKLIGHT_LEVELS 3 // number of levels your backlight will have (not including off)
#define DEBOUNCING_DELAY 5 // the delay when reading the value of the pin (5 is default)
#define LOCKING_SUPPORT_ENABLE // mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap
#define LOCKING_RESYNC_ENABLE // tries to keep switch state consistent with keyboard LED state
#define IS_COMMAND() ( \ // key combination that allows the use of magic commands (useful for debugging)
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
)
// the following options can save on file size at the expense of that feature
#define NO_DEBUG // disable debuging (saves on file size)
#define NO_PRINT // disable printing (saves of file size)
#define NO_ACTION_LAYER // no layers
#define NO_ACTION_TAPPING // no tapping for layers/mods
#define NO_ACTION_ONESHOT // no oneshot for layers/mods
#define NO_ACTION_MACRO // no macros
#define NO_ACTION_FUNCTION // no functions
#define FORCE_NKRO // NKRO by default requires to be turned on, this forces it to be on always
#define PREVENT_STUCK_MODIFIERS // when switching layers, this will release all mods
#define TAPPING_TERM 200 // how long before a tap becomes a hold
#define TAPPING_TOGGLE 2 // how many taps before triggering the toggle
#define PERMISSIVE_HOLD // makes tap and hold keys work better for fast typers who don't want tapping term set above 500
#define LEADER_TIMEOUT 300 // how long before the leader key times out
#define ONESHOT_TIMEOUT 300 // how long before oneshot times out
#define ONESHOT_TAP_TOGGLE 2 // how many taps before oneshot toggle is triggered
#define IGNORE_MOD_TAP_INTERRUPT // makes it possible to do rolling combos (zx) with keys that convert to other keys on hold
// ws2812 options
#define RGB_DI_PIN D7 // pin the DI on the ws2812 is hooked-up to
#define RGBLIGHT_ANIMATIONS // run RGB animations
#define RGBLED_NUM 15 // number of LEDs
#define RGBLIGHT_HUE_STEP 12 // units to step when in/decreasing hue
#define RGBLIGHT_SAT_STEP 25 // units to step when in/decresing saturation
#define RGBLIGHT_VAL_STEP 12 // units to step when in/decreasing value (brightness)
#define RGBW_BB_TWI // bit-bangs twi to EZ RGBW LEDs (only required for Ergodox EZ)
// mousekey options (self-describing)
#define MOUSEKEY_INTERVAL 20
#define MOUSEKEY_DELAY 0
#define MOUSEKEY_TIME_TO_MAX 60
#define MOUSEKEY_MAX_SPEED 7
#define MOUSEKEY_WHEEL_DELAY 0
```
This level contains all of the options for that particular keymap. If you wish to override a previous declaration, you can use `#undef <variable>` to undefine it, where you can then redefine it without an error.
# The `config.h` File
This is a C header file that is one of the first things included, and will persist over the whole project (if included). Lots of variables can be set here and accessed elsewhere. The `config.h` file shouldn't be including other `config.h` files, or anything besides this:
#include "config_common.h"
## Hardware Options
* `#define VENDOR_ID 0x1234`
* defines your VID, and for most DIY projects, can be whatever you want
* `#define PRODUCT_ID 0x5678`
* defines your PID, and for most DIY projects, can be whatever you want
* `#define DEVICE_VER 0`
* defines the device version (often used for revisions)
* `#define MANUFACTURER Me`
* generally who/whatever brand produced the board
* `#define PRODUCT Board`
* the name of the keyboard
* `#define DESCRIPTION a keyboard`
* a short description of what the keyboard is
* `#define MATRIX_ROWS 5`
* the number of rows in your keyboard's matrix
* `#define MATRIX_COLS 15`
* the number of columns in your keyboard's matrix
* `#define MATRIX_ROW_PINS { D0, D5, B5, B6 }`
* pins of the rows, from top to bottom
* `#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7 }`
* pins of the columns, from left to right
* `#define UNUSED_PINS { D1, D2, D3, B1, B2, B3 }`
* pins unused by the keyboard for reference
* `#define MATRIX_HAS_GHOST`
* define is matrix has ghost (unlikely)
* `#define DIODE_DIRECTION COL2ROW`
* COL2ROW or ROW2COL - how your matrix is configured. COL2ROW means the black mark on your diode is facing to the rows, and between the switch and the rows.
* `#define AUDIO_VOICES`
* turns on the alternate audio voices (to cycle through)
* `#define C4_AUDIO`
* enables audio on pin C4
* `#define C5_AUDIO`
* enables audio on pin C5
* `#define C6_AUDIO`
* enables audio on pin C6
* `#define B5_AUDIO`
* enables audio on pin B5 (duophony is enables if one of B[5-7]_AUDIO is enabled along with one of C[4-6]_AUDIO)
* `#define B6_AUDIO`
* enables audio on pin B6 (duophony is enables if one of B[5-7]_AUDIO is enabled along with one of C[4-6]_AUDIO)
* `#define B7_AUDIO`
* enables audio on pin B7 (duophony is enables if one of B[5-7]_AUDIO is enabled along with one of C[4-6]_AUDIO)
* `#define BACKLIGHT_PIN B7`
* pin of the backlight - B5, B6, B7 use PWM, others use softPWM
* `#define BACKLIGHT_LEVELS 3`
* number of levels your backlight will have (maximum 15 excluding off)
* `#define BACKLIGHT_BREATHING`
* enables backlight breathing (only works with backlight pins B5, B6 and B7)
* `#define BREATHING_PERIOD 6`
* the length of one backlight "breath" in seconds
* `#define DEBOUNCING_DELAY 5`
* the delay when reading the value of the pin (5 is default)
* `#define LOCKING_SUPPORT_ENABLE`
* mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap
* `#define LOCKING_RESYNC_ENABLE`
* tries to keep switch state consistent with keyboard LED state
* `#define IS_COMMAND() ( keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) )`
* key combination that allows the use of magic commands (useful for debugging)
## Features That Can Be Disabled
If you define these options you will disable the associated feature, which can save on code size.
* `#define NO_DEBUG`
* disable debugging
* `#define NO_PRINT`
* disable printing/debugging using hid_listen
* `#define NO_ACTION_LAYER`
* disable layers
* `#define NO_ACTION_TAPPING`
* disable tap dance and other tapping features
* `#define NO_ACTION_ONESHOT`
* disable one-shot modifiers
* `#define NO_ACTION_MACRO`
* disable all macro handling
* `#define NO_ACTION_FUNCTION`
* disable the action function (deprecated)
## Features That Can Be Enabled
If you define these options you will enable the associated feature, which may increase your code size.
* `#define FORCE_NKRO`
* NKRO by default requires to be turned on, this forces it on during keyboard startup regardless of EEPROM setting. NKRO can still be turned off but will be turned on again if the keyboard reboots.
* `#define PREVENT_STUCK_MODIFIERS`
* stores the layer a key press came from so the same layer is used when the key is released, regardless of which layers are enabled
## Behaviors That Can Be Configured
* `#define TAPPING_TERM 200`
* how long before a tap becomes a hold
* `#define RETRO_TAPPING`
* tap anyway, even after TAPPING_TERM, if there was no other key interruption between press and release
* `#define TAPPING_TOGGLE 2`
* how many taps before triggering the toggle
* `#define PERMISSIVE_HOLD`
* makes tap and hold keys work better for fast typers who don't want tapping term set above 500
* `#define LEADER_TIMEOUT 300`
* how long before the leader key times out
* `#define ONESHOT_TIMEOUT 300`
* how long before oneshot times out
* `#define ONESHOT_TAP_TOGGLE 2`
* how many taps before oneshot toggle is triggered
* `#define IGNORE_MOD_TAP_INTERRUPT`
* makes it possible to do rolling combos (zx) with keys that convert to other keys on hold
* `#define QMK_KEYS_PER_SCAN 4`
* Allows sending more than one key per scan. By default, only one key event gets
sent via `process_record()` per scan. This has little impact on most typing, but
if you're doing a lot of chords, or your scan rate is slow to begin with, you can
have some delay in processing key events. Each press and release is a separate
event. For a keyboard with 1ms or so scan times, even a very fast typist isn't
going to produce the 500 keystrokes a second needed to actually get more than a
few ms of delay from this. But if you're doing chording on something with 3-4ms
scan times? You probably want this.
## RGB Light Configuration
* `#define RGB_DI_PIN D7`
* pin the DI on the ws2812 is hooked-up to
* `#define RGBLIGHT_ANIMATIONS`
* run RGB animations
* `#define RGBLED_NUM 15`
* number of LEDs
* `#define RGBLIGHT_HUE_STEP 12`
* units to step when in/decreasing hue
* `#define RGBLIGHT_SAT_STEP 25`
* units to step when in/decreasing saturation
* `#define RGBLIGHT_VAL_STEP 12`
* units to step when in/decreasing value (brightness)
* `#define RGBW_BB_TWI`
* bit-bangs TWI to EZ RGBW LEDs (only required for Ergodox EZ)
## Mouse Key Options
* `#define MOUSEKEY_INTERVAL 20`
* `#define MOUSEKEY_DELAY 0`
* `#define MOUSEKEY_TIME_TO_MAX 60`
* `#define MOUSEKEY_MAX_SPEED 7`
* `#define MOUSEKEY_WHEEL_DELAY 0`
# The `rules.mk` File
This is a [make](https://www.gnu.org/software/make/manual/make.html) file that is included by the top-level `Makefile`. It is used to set some information about the MCU that we will be compiling for as well as enabling and disabling certain features.
## Build Options
* `DEFAULT_FOLDER`
* Used to specify a default folder when a keyboard has more than one sub-folder.
* `SRC`
* Used to add files to the compilation/linking list.
* `LAYOUTS`
* A list of [layouts](feature_layouts.md) this keyboard supports.
## AVR MCU Options
* `MCU = atmega32u4`
* `F_CPU = 16000000`
* `ARCH = AVR8`
* `F_USB = $(F_CPU)`
* `OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT`
* `BOOTLOADER = atmel-dfu` with the following options:
* `atmel-dfu`
* `lufa-dfu`
* `qmk-dfu`
* `halfkay`
* `caterina`
* `bootloadHID`
## Feature Options
Use these to enable or disable building certain features. The more you have enabled the bigger your firmware will be, and you run the risk of building a firmware too large for your MCU.
* `BOOTMAGIC_ENABLE`
* Virtual DIP switch configuration(+1000)
* `MOUSEKEY_ENABLE`
* Mouse keys(+4700)
* `EXTRAKEY_ENABLE`
* Audio control and System control(+450)
* `CONSOLE_ENABLE`
* Console for debug(+400)
* `COMMAND_ENABLE`
* Commands for debug and configuration
* `NKRO_ENABLE`
* USB N-Key Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
* `AUDIO_ENABLE`
* Enable the audio subsystem.
* `RGBLIGHT_ENABLE`
* Enable keyboard underlight functionality
* `MIDI_ENABLE`
* MIDI controls
* `UNICODE_ENABLE`
* Unicode
* `BLUETOOTH_ENABLE`
* Enable Bluetooth with the Adafruit EZ-Key HID

@ -1,4 +1,4 @@
# How To Contribute
# How to Contribute
👍🎉 First off, thanks for taking the time to read this and contribute! 🎉👍
@ -9,7 +9,7 @@ Third-party contributions help us grow and improve QMK. We want to make the pull
* [General Guidelines](#general-guidelines)
* [What does the Code of Conduct mean for me?](#what-does-the-code-of-conduct-mean-for-me)
## I Don't Want To Read This Whole Thing I Just Have a Question!
## I Don't Want to Read This Whole Thing! I Just Have a Question!
If you'd like to ask questions about QMK you can do so on the [OLKB Subreddit](https://reddit.com/r/olkb) or on [Gitter](https://gitter.im/qmk/qmk_firmware).
@ -27,7 +27,7 @@ QMK is largely written in C, with specific features and parts written in C++. It
<!-- FIXME: We should include a list of resources for learning C here. -->
# Where can I go for help?
# Where Can I Go for Help?
If you need help you can [open an issue](https://github.com/qmk/qmk_firmware/issues) or [chat on gitter](http://gitter.im/QMK/qmk_firmware).
@ -52,7 +52,7 @@ Never made an open source contribution before? Wondering how contributions work
14. Make changes to the pull request if the reviewing maintainer recommends them.
15. Celebrate your success after your pull request is merged!
# Coding conventions
# Coding Conventions
Most of our style is pretty easy to pick up on, but right now it's not entirely consistent. You should match the style of the code surrounding your change, but if that code is inconsistent or unclear use the following guidelines:
@ -64,7 +64,7 @@ Most of our style is pretty easy to pick up on, but right now it's not entirely
* Optional Braces: Always include optional braces.
* Good: if (condition) { return false; }
* Bad: if (condition) return false;
* We use C style comments: /* */
* We use C style comments: `/* */`
* Think of them as a story describing the feature
* Use them liberally to explain why particular decisions were made.
* Do not write obvious comments
@ -75,12 +75,12 @@ Most of our style is pretty easy to pick up on, but right now it's not entirely
We have a few different types of changes in QMK, each requiring a different level of rigor. We'd like you to keep the following guidelines in mind no matter what type of change you're making.
* Separate PR's into logical units. For example, do not submit one PR covering two separate features, instead submit a separate PR for each feature.
* Separate PR's into logical units. For example, do not submit one PR covering two separate features, instead submit a separate PR for each feature.
* Check for unnecessary whitespace with `git diff --check` before committing.
* Make sure your code change actually compiles.
* Keymaps: Make sure that `make keyboard:your_new_keymap` does not return an error
* Keyboards: Make sure that `make keyboard:all` does not return any errors
* Core: Make sure that `make allkb` does not return any errors.
* Core: Make sure that `make all` does not return any errors.
* Make sure commit messages are understandable on their own. You should put a short description (no more than 70 characters) on the first line, the second line should be empty, and on the 3rd and later lines you should describe your commit in detail, if required. Example:
```
@ -104,20 +104,25 @@ Most first-time QMK contributors start with their personal keymaps. We try to ke
* Write a `readme.md` using [the template](https://docs.qmk.fm/documentation_templates.html#).
* All Keymap PR's are squashed, so if you care about how your commits are squashed you should do it yourself
* Do not lump features in with keymap PR's. Submit the feature first and then a second PR for the keymap.
* Do not include `Makefile`s in your keymap folder (they're no longer used)
* Update copyrights in file headers (look for `REPLACE_WITH_YOUR_NAME `)
## Keyboards
Keyboards are the raison d'être for QMK. Some keyboards are community maintained, while others are maintained by the people responsible for making a particular keyboard. The `readme.md` should tell you who maintains a particular keyboard. If you have questions relating to a particular keyboard you can [Open An Issue](https://github.com/qmk/qmk_firmware/issues) and tag the maintainer in your question.
We also ask that you follow these guidelines:
We also ask that you follow these guidelines:
* Write a `readme.md` using [the template](https://docs.qmk.fm/documentation_templates.html#).
* Keep the number of commits reasonable or we will squash your PR
* Do not lump core features in with new keyboards. Submit the feature first and then submit a separate PR for the keyboard.
* Name `.c`/`.h` file after the immediate parent folder, eg `/keyboards/<kb1>/<kb2>/<kb2>.[ch]`
* Do not include `Makefile`s in your keyboard folder (they're no longer used)
* Update copyrights in file headers (look for `REPLACE_WITH_YOUR_NAME `)
## Quantum/TMK Core
Before you put a lot of work into building your new feature you should make sure you are implementing it in the best way. You can get a basic understanding of QMK by reading [Understaning QMK](understanding_qmk.html), which will take you on a tour of the QMK program flow. From here you should talk to us to get a sense of the best way to implement your idea. There are two main ways to do this:
Before you put a lot of work into building your new feature you should make sure you are implementing it in the best way. You can get a basic understanding of QMK by reading [Understanding QMK](understanding_qmk.md), which will take you on a tour of the QMK program flow. From here you should talk to us to get a sense of the best way to implement your idea. There are two main ways to do this:
* [Chat on Gitter](https://gitter.im/qmk/qmk_firmware)
* [Open an Issue](https://github.com/qmk/qmk_firmware/issues/new)
@ -131,7 +136,7 @@ Here are some things to keep in mind when working on your feature or bug fix.
* **Consider revisions and different chip-bases** - there are several keyboards that have revisions that allow for slightly different configurations, and even different chip-bases. Try to make a feature supported in ARM and AVR, or automatically disabled on platforms it doesn't work on.
* **Explain your feature** - Document it in `docs/`, either as a new file or as part of an existing file. If you don't document it other people won't be able to benefit from your hard work.
We also ask that you follow these guidelines:
We also ask that you follow these guidelines:
* Keep the number of commits reasonable or we will squash your PR
* Do not lump keyboards or keymaps in with core changes. Submit your core changes first.
@ -142,6 +147,6 @@ We also ask that you follow these guidelines:
To maintain a clear vision of how things are laid out in QMK we try to plan out refactors in-depth and have a collaborator make the changes. If you have an idea for refactoring, or suggestions, [open an issue](https://github.com/qmk/qmk_firmware/issues), we'd love to talk about how QMK can be improved.
# What does the Code of Conduct mean for me?
# What Does the Code of Conduct Mean for Me?
Our Code of Conduct means that you are responsible for treating everyone on the project with respect and courtesy regardless of their identity. If you are the victim of any inappropriate behavior or comments as described in our Code of Conduct, we are here for you and will do the best to ensure that the abuser is reprimanded appropriately, per our code.
Our [Code of Conduct](https://github.com/qmk/qmk_firmware/blob/master/CODE_OF_CONDUCT.md) means that you are responsible for treating everyone on the project with respect and courtesy regardless of their identity. If you are the victim of any inappropriate behavior or comments as described in our Code of Conduct, we are here for you and will do the best to ensure that the abuser is reprimanded appropriately, per our code.

@ -1,8 +1,8 @@
# How To Customize Your Keyboard's Behavior
# How to Customize Your Keyboard's Behavior
For a lot of people a custom keyboard is about more than sending button presses to your computer. You want to be able to do things that are more complex than simple button presses and macros. QMK has hooks that allow you to inject code, override functionality, and otherwise customize how your keyboard behaves in different situations.
For a lot of people a custom keyboard is about more than sending button presses to your computer. You want to be able to do things that are more complex than simple button presses and macros. QMK has hooks that allow you to inject code, override functionality, and otherwise customize how your keyboard behaves in different situations.
This page does not assume any special knowledge about QMK, but reading [Understanding QMK](understanding_qmk.html) will help you understand what is going on at a more fundamental level.
This page does not assume any special knowledge about QMK, but reading [Understanding QMK](understanding_qmk.md) will help you understand what is going on at a more fundamental level.
## A Word on Core vs Keyboards vs Keymap
@ -34,13 +34,13 @@ enum my_keycodes {
};
```
## Programming The Behavior Of Any Keycode
## Programming the Behavior of Any Keycode
When you want to override the behavior of an existing key, or define the behavior for a new key, you should use the `process_record_kb()` and `process_record_user()` functions. These are called by QMK during key processing before the actual key event is handled. If these functions return `true` QMK will process the keycodes as usual. That can be handy for extending the functionality of a key rather than replacing it. If these functions return `false` QMK will skip the normal key handling, and it will be up you to send any key up or down events that are required.
When you want to override the behavior of an existing key, or define the behavior for a new key, you should use the `process_record_kb()` and `process_record_user()` functions. These are called by QMK during key processing before the actual key event is handled. If these functions return `true` QMK will process the keycodes as usual. That can be handy for extending the functionality of a key rather than replacing it. If these functions return `false` QMK will skip the normal key handling, and it will be up to you to send any key up or down events that are required.
These function are called every time a key is pressed or released.
### Example `process_record_user()` implementation
### Example `process_record_user()` Implementation
This example does two things. It defines the behavior for a custom keycode called `FOO`, and it supplements our Enter key by playing a tone whenever it is pressed.
@ -60,18 +60,20 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
PLAY_NOTE_ARRAY(tone_qwerty);
}
return true; // Let QMK send the enter press/release events
default:
return true; // Process all other keycodes normally
}
}
```
### `process_record_*` Function documentation
### `process_record_*` Function Documentation
* Keyboard/Revision: `bool process_record_kb(uint16_t keycode, keyrecord_t *record)`
* Keyboard/Revision: `bool process_record_kb(uint16_t keycode, keyrecord_t *record)`
* Keymap: `bool process_record_user(uint16_t keycode, keyrecord_t *record)`
The `keycode` argument is whatever is defined in your keymap, eg `MO(1)`, `KC_L`, etc. You should use a `switch...case` block to handle these events.
The `record` argument contains infomation about the actual press:
The `record` argument contains information about the actual press:
```
keyrecord_t record {
@ -96,10 +98,10 @@ This allows you to control the 5 LED's defined as part of the USB Keyboard spec.
* `USB_LED_COMPOSE`
* `USB_LED_KANA`
### Example `led_set_kb()` implementation
### Example `led_set_user()` Implementation
```
void led_set_kb(uint8_t usb_led) {
void led_set_user(uint8_t usb_led) {
if (usb_led & (1<<USB_LED_NUM_LOCK)) {
PORTB |= (1<<0);
} else {
@ -128,23 +130,22 @@ void led_set_kb(uint8_t usb_led) {
}
```
### `led_set_*` Function documentation
### `led_set_*` Function Documentation
* Keyboard/Revision: `void led_set_kb(uint8_t usb_led)`
* Keyboard/Revision: `void led_set_kb(uint8_t usb_led)`
* Keymap: `void led_set_user(uint8_t usb_led)`
# Matrix Initialization Code
Before a keyboard can be used the hardware must be initialized. QMK handles initialization of the keyboard matrix itself, but if you have other hardware like LED's or i&#xb2;c controllers you will need to set up that hardware before it can be used.
### Example `matrix_init_kb()` implementation
### Example `matrix_init_user()` Implementation
This example, at the keyboard level, sets up B1, B2, and B3 as LED pins.
```
void matrix_init_kb(void) {
void matrix_init_user(void) {
// Call the keymap level matrix init.
matrix_init_user();
// Set our LED pins as output
DDRB |= (1<<1);
@ -153,20 +154,20 @@ void matrix_init_kb(void) {
}
```
### `matrix_init_*` Function documentation
### `matrix_init_*` Function Documentation
* Keyboard/Revision: `void matrix_init_kb(void)`
* Keyboard/Revision: `void matrix_init_kb(void)`
* Keymap: `void matrix_init_user(void)`
# Matrix Scanning Code
Whenever possible you should customize your keyboard by using `process_record_*()` and hooking into events that way, to ensure that your code does not have a negative performance impact on your keyboard. However, in rare cases it is necessary to hook into the matrix scanning. Be extremely careful with the performance of code in these functions, as it will be called at least 10 times per second.
### Example `matrix_scan_*` implementation
### Example `matrix_scan_*` Implementation
This example has been deliberately omitted. You should understand enough about QMK internals to write this without an example before hooking into such a performance sensitive area. If you need help please [open an issue](https://github.com/qmk/qmk_firmware/issues/new) or [chat with us on gitter](https://gitter.im/qmk/qmk_firmware).
### `matrix_scan_*` Function documentation
### `matrix_scan_*` Function Documentation
* Keyboard/Revision: `void matrix_scan_kb(void)`
* Keymap: `void matrix_scan_user(void)`
@ -174,3 +175,41 @@ This example has been deliberately omitted. You should understand enough about Q
This function gets called at every matrix scan, which is basically as often as the MCU can handle. Be careful what you put here, as it will get run a lot.
You should use this function if you need custom matrix scanning code. It can also be used for custom status output (such as LED's or a display) or other functionality that you want to trigger regularly even when the user isn't typing.
# Layer Change Code
Thir runs code every time that the layers get changed. This can be useful for layer indication, or custom layer handling.
### Example `layer_state_set_*` Implementation
This example shows how to set the [RGB Underglow](feature_rgblight.md) lights based on the layer, using the Planck as an example
```
uint32_t layer_state_set_user(uint32_t state) {
switch (biton32(state)) {
case _RAISE:
rgblight_setrgb (0x00, 0x00, 0xFF);
break;
case _LOWER:
rgblight_setrgb (0xFF, 0x00, 0x00);
break;
case _PLOVER:
rgblight_setrgb (0x00, 0xFF, 0x00);
break;
case _ADJUST:
rgblight_setrgb (0x7A, 0x00, 0xFF);
break;
default: // for any other layers, or the default layer
rgblight_setrgb (0x00, 0xFF, 0xFF);
break;
}
return state;
}
```
### `layer_state_set_*` Function Documentation
* Keyboard/Revision: `void uint32_t layer_state_set_kb(uint32_t state)`
* Keymap: `uint32_t layer_state_set_user(uint32_t state)`
The `state` is the bitmask of the active layers, as explained in the [Keymap Overview](keymap.md#keymap-layer-status)

@ -4,7 +4,7 @@ This page exists to document best practices when writing documentation for QMK.
# Page Opening
Your documentation page should generally start with an H1 heading, followed by a 1 paragrah description of what the user will find on this page. Keep in mind that this heading and paragraph will sit next to the Table of Contents, so keep the heading short and avoid long strings with no whitespace.
Your documentation page should generally start with an H1 heading, followed by a 1 paragraph description of what the user will find on this page. Keep in mind that this heading and paragraph will sit next to the Table of Contents, so keep the heading short and avoid long strings with no whitespace.
Example:
@ -78,7 +78,7 @@ What about an error message?
# Documenting Features
If you create a new feature for QMK, create a documentation page for it. It doesn't have to be very long, a few sentances describing your feature and a table listing any relevant keycodes is enough. Here is a basic template:
If you create a new feature for QMK, create a documentation page for it. It doesn't have to be very long, a few sentences describing your feature and a table listing any relevant keycodes is enough. Here is a basic template:
```markdown
# My Cool Feature

@ -1,63 +0,0 @@
# Dynamic macros: record and replay macros in runtime
QMK supports temporarily macros created on the fly. We call these Dynamic Macros. They are defined by the user from the keyboard and are lost when the keyboard is unplugged or otherwise rebooted.
You can store one or two macros and they may have a combined total of 128 keypresses. You can increase this size at the cost of RAM.
To enable them, first add a new element to the `planck_keycodes` enum — `DYNAMIC_MACRO_RANGE`:
```c
enum planck_keycodes {
QWERTY = SAFE_RANGE,
COLEMAK,
DVORAK,
PLOVER,
LOWER,
RAISE,
BACKLIT,
EXT_PLV,
DYNAMIC_MACRO_RANGE,
};
```
It must be the last element because `dynamic_macros.h` will add some more keycodes after it.
Below it include the `dynamic_macro.h` header:
```c
#include "dynamic_macro.h"`
```
Add the following keys to your keymap:
* `DYN_REC_START1` — start recording the macro 1,
* `DYN_REC_START2` — start recording the macro 2,
* `DYN_MACRO_PLAY1` — replay the macro 1,
* `DYN_MACRO_PLAY2` — replay the macro 2,
* `DYN_REC_STOP` — finish the macro that is currently being recorded.
Add the following code to the very beginning of your `process_record_user()` function:
```c
if (!process_record_dynamic_macro(keycode, record)) {
return false;
}
```
That should be everything necessary. To start recording the macro, press either `DYN_REC_START1` or `DYN_REC_START2`. To finish the recording, press the `DYN_REC_STOP` layer button. To replay the macro, press either `DYN_MACRO_PLAY1` or `DYN_MACRO_PLAY2`.
Note that it's possible to replay a macro as part of a macro. It's ok to replay macro 2 while recording macro 1 and vice versa but never create recursive macros i.e. macro 1 that replays macro 1. If you do so and the keyboard will get unresponsive, unplug the keyboard and plug it again.
For users of the earlier versions of dynamic macros: It is still possible to finish the macro recording using just the layer modifier used to access the dynamic macro keys, without a dedicated `DYN_REC_STOP` key. If you want this behavior back, use the following snippet instead of the one above:
```c
uint16_t macro_kc = (keycode == MO(_DYN) ? DYN_REC_STOP : keycode);
if (!process_record_dynamic_macro(macro_kc, record)) {
return false;
}
```
If the LED's start blinking during the recording with each keypress, it means there is no more space for the macro in the macro buffer. To fit the macro in, either make the other macro shorter (they share the same buffer) or increase the buffer size by setting the `DYNAMIC_MACRO_SIZE` preprocessor macro (default value: 128; please read the comments for it in the header).
For the details about the internals of the dynamic macros, please read the comments in the `dynamic_macro.h` header.

@ -1,6 +1,6 @@
# Setting Up Eclipse for QMK Development
# Setting up Eclipse for QMK Development
[Eclipse](https://en.wikipedia.org/wiki/Eclipse_(software)) is an open-source [Integrated Development Environment](https://en.wikipedia.org/wiki/Integrated_development_environment) (IDE) widely used for Java development, but with an extensible plugin system that allows to customize it for other languages and usages.
[Eclipse][1] is an open-source [Integrated Development Environment](https://en.wikipedia.org/wiki/Integrated_development_environment) (IDE) widely used for Java development, but with an extensible plugin system that allows to customize it for other languages and usages.
Using an IDE such as Eclipse provides many advantages over a plain text editor, such as:
* intelligent code completion
@ -16,16 +16,16 @@ The purpose of the is page is to document how to set-up Eclipse for developing A
Note that this set-up has been tested on Ubuntu 16.04 only for the moment.
# Prerequisites
## Build environment
Before starting, you must have followed the [Getting Started](home.md#getting-started) section corresponding to your system. In particular, you must have been able to build the firmware with [the `make` command](../#the-make-command).
## Build Environment
Before starting, you must have followed the [Getting Started](README.md#getting-started) section corresponding to your system. In particular, you must have been able to build the firmware with [the `make` command](../#the-make-command).
## Java
Eclipse is a Java application, so you will need to install Java 8 or more recent to be able to run it. You may choose between the JRE or the JDK, the latter being useful if you intend to do Java development.
# Install Eclipse and its plugins
# Install Eclipse and Its Plugins
Eclipse comes in [several flavours](http://www.eclipse.org/downloads/eclipse-packages/) depending on the target usage that you will have. There is no package comprising the AVR stack, so we will need to start from Eclipse CDT (C/C++ Development Tooling) and install the necessary plugins.
## Download and install Eclipse CDT
## Download and Install Eclipse CDT
If you already have Eclipse CDT on your system, you can skip this step. However it is advised to keep it up-to-date for better support.
If you have another Eclipse package installed, it is normally possible to [install the CDT plugin over it](https://eclipse.org/cdt/downloads.php). However it is probably better to reinstall it from scratch to keep it light and avoid the clutter of tools that you don't need for the projects you will be working on.
@ -41,10 +41,10 @@ When you are prompted with the Workspace Selector, select a directory that will
Once started, click the <kbd>Workbench</kbd> button at the top right to switch to the workbench view (there is a also checkbox at the bottom to skip the welcome screen at startup).
## Install the necessary plugins
## Install the Necessary Plugins
Note: you do not need to restart Eclipse after installing each plugin. Simply restart once all plugins are installed.
### [The AVR plugin](http://avr-eclipse.sourceforge.net/)
### [The AVR Plugin](http://avr-eclipse.sourceforge.net/)
This is the most important plugin as it will allow Eclipse to _understand_ AVR C code. Follow [the instructions for using the update site](http://avr-eclipse.sourceforge.net/wiki/index.php/Plugin_Download#Update_Site), and agree with the security warning for unsigned content.
### [ANSI Escape in Console](https://marketplace.eclipse.org/content/ansi-escape-console)
@ -58,7 +58,7 @@ This plugin is necessary to properly display the colored build output generated
Once both plugins are installed, restart Eclipse as prompted.
# Configure Eclipse for QMK
## Importing the project
## Importing the Project
1. Click <kbd><kbd>File</kbd> > <kbd>New</kbd> > <kbd>Makefile Project with Existing Code</kbd></kbd>
2. On the next screen:
* Select the directory where you cloned the repository as _Existing Code Location_;
@ -72,7 +72,7 @@ Once both plugins are installed, restart Eclipse as prompted.
¹ There might be issues for importing the project with a custom name. If it does not work properly, try leaving the default project name (i.e. the name of the directory, probably `qmk_firmware`).
## Build your keyboard
## Build Your Keyboard
We will now configure a make target that cleans the project and builds the keymap of your choice.
1. On the right side of the screen, select the <kbd>Make Target</kbd> tab
@ -84,3 +84,5 @@ We will now configure a make target that cleans the project and builds the keyma
7. (Optional) Toggle the <kbd>Hide Empty Folders</kbd> icon button above the targets tree to only show your build target.
8. Double-click the build target you created to trigger a build.
9. Select the <kbd>Console</kbd> view at the bottom to view the running build.
[1]: https://en.wikipedia.org/wiki/Eclipse_(software)

@ -1,40 +1,25 @@
# Frequently Asked Build Questions
This page covers questions about building QMK. If you have not yet you should read the [Build Environment Setup](getting_started_build_tools.md) and [Make Instructions](make_instructions.md) guides.
This page covers questions about building QMK. If you haven't yet done so, you should read the [Build Environment Setup](getting_started_build_tools.md) and [Make Instructions](getting_started_make_guide.md) guides.
## Can't program on Linux
You will need proper permission to operate a device. For Linux users see udev rules below. Easy way is to use `sudo` command, if you are not familiar with this command check its manual with `man sudo` or this page on line.
## Can't Program on Linux
You will need proper permissions to operate a device. For Linux users, see the instructions regarding `udev` rules, below. If you have issues with `udev`, a work-around is to use the `sudo` command. If you are not familiar with this command, check its manual with `man sudo` or [see this webpage](https://linux.die.net/man/8/sudo).
An example of using `sudo`, when your controller is ATMega32u4:
In short when your controller is ATMega32u4,
$ sudo dfu-programmer atmega32u4 erase --force
$ sudo dfu-programmer atmega32u4 flash your.hex
$ sudo dfu-programmer atmega32u4 reset
or just
or just:
$ sudo make <keyboard>:<keymap>:dfu
But to run `make` with root privilege is not good idea. Use former method if possible.
## WINAVR is obsolete
It is no longer recommended and may cause some problem.
See [TMK Issue #99](https://github.com/tmk/tmk_keyboard/issues/99).
## USB VID and PID
You can use any ID you want with editing `config.h`. Using any presumably unused ID will be no problem in fact except for very low chance of collision with other product.
Most boards in QMK use `0xFEED` as the vendor ID. You should look through other keyboards to make sure you pick a unique Product ID.
Also see this.
https://github.com/tmk/tmk_keyboard/issues/150
Note that running `make` with `sudo` is generally *not* a good idea, and you should use one of the former methods, if possible.
You can buy a really unique VID:PID here. I don't think you need this for personal use.
- http://www.obdev.at/products/vusb/license.html
- http://www.mcselec.com/index.php?page=shop.product_details&flypage=shop.flypage&product_id=92&option=com_phpshop&Itemid=1
## Linux udev rules
On Linux you need proper privilege to access device file of MCU, you'll have to use `sudo` when flashing firmware. You can circumvent this with placing these files in `/etc/udev/rules.d/`.
## Linux `udev` Rules
On Linux, you'll need proper privileges to access the MCU. You can either use
`sudo` when flashing firmware, or place these files in `/etc/udev/rules.d/`.
**/etc/udev/rules.d/50-atmel-dfu.rules:**
```
@ -52,8 +37,23 @@ SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff0", MODE:="066
SUBSYSTEMS=="usb", ATTRS{idVendor}=="feed", MODE:="0666"
```
## WINAVR is Obsolete
It is no longer recommended and may cause some problem.
See [TMK Issue #99](https://github.com/tmk/tmk_keyboard/issues/99).
## USB VID and PID
You can use any ID you want with editing `config.h`. Using any presumably unused ID will be no problem in fact except for very low chance of collision with other product.
Most boards in QMK use `0xFEED` as the vendor ID. You should look through other keyboards to make sure you pick a unique Product ID.
Also see this.
https://github.com/tmk/tmk_keyboard/issues/150
You can buy a really unique VID:PID here. I don't think you need this for personal use.
- http://www.obdev.at/products/vusb/license.html
- http://www.mcselec.com/index.php?page=shop.product_details&flypage=shop.flypage&product_id=92&option=com_phpshop&Itemid=1
## Cortex: cstddef: No such file or directory
## Cortex: `cstddef: No such file or directory`
GCC 4.8 of Ubuntu 14.04 had this problem and had to update to 4.9 with this PPA.
https://launchpad.net/~terry.guo/+archive/ubuntu/gcc-arm-embedded
@ -61,8 +61,7 @@ https://github.com/tmk/tmk_keyboard/issues/212
https://github.com/tmk/tmk_keyboard/wiki/mbed-cortex-porting#compile-error-cstddef
https://developer.mbed.org/forum/mbed/topic/5205/
## 'clock_prescale_set' and 'clock_div_1' not available
## `clock_prescale_set` and `clock_div_1` Not Available
Your toolchain is too old to support the MCU. For example WinAVR 20100110 doesn't support ATMega32u2.
```
@ -81,11 +80,27 @@ make: *** [obj_alps64/protocol/lufa/lufa.o] Error 1
Note that Teensy2.0++ bootloader size is 2048byte. Some Makefiles may have wrong comment.
```
# Boot Section Size in *bytes*
# Teensy halfKay 512
# Teensy++ halfKay 2048
# Boot Section Size in *bytes*
# Teensy halfKay 512
# Teensy++ halfKay 2048
# Atmel DFU loader 4096 (TMK Alt Controller)
# LUFA bootloader 4096
# USBaspLoader 2048
# LUFA bootloader 4096
# USBaspLoader 2048
OPT_DEFS += -DBOOTLOADER_SIZE=2048
```
## `avr-gcc: internal compiler error: Abort trap: 6 (program cc1)` on MacOS
This is an issue with updating on brew, causing symlinks that avr-gcc depend on getting mangled.
The solution is to remove and reinstall all affected modules.
```
brew rm avr-gcc
brew rm dfu-programmer
brew rm gcc-arm-none-eabi
brew rm avrdude
brew install avr-gcc
brew install dfu-programmer
brew install gcc-arm-none-eabi
brew install avrdude
```

@ -4,14 +4,14 @@ This page details various common questions people have about troubleshooting the
# Debug Console
## hid_listen can't recognize device
## `hid_listen` Can't Recognize Device
When debug console of your device is not ready you will see like this:
```
Waiting for device:.........
```
once the device is pluged in then *hid_listen* finds it you will get this message:
once the device is plugged in then *hid_listen* finds it you will get this message:
```
Waiting for new device:.........................
@ -23,7 +23,7 @@ If you can't get this 'Listening:' message try building with `CONSOLE_ENABLE=yes
You may need privilege to access the device on OS like Linux.
- try `sudo hid_listen`
## Can't get message on console
## Can't Get Message on Console
Check:
- *hid_listen* finds your device. See above.
- Enable debug with pressing **Magic**+d. See [Magic Commands](https://github.com/tmk/tmk_keyboard#magic-commands).
@ -31,7 +31,7 @@ Check:
- try using 'print' function instead of debug print. See **common/print.h**.
- disconnect other devices with console function. See [Issue #97](https://github.com/tmk/tmk_keyboard/issues/97).
## Linux or UNIX like system requires Super User privilege
## Linux or UNIX Like System Requires Super User Privilege
Just use 'sudo' to execute *hid_listen* with privilege.
```
$ sudo hid_listen
@ -82,46 +82,46 @@ Size after:
consume extra memory; watch out for BOOTMAGIC_ENABLE,
MOUSEKEY_ENABLE, EXTRAKEY_ENABLE, CONSOLE_ENABLE, API_SYSEX_ENABLE
- DFU tools do /not/ allow you to write into the bootloader (unless
you throw in extra fruitsalad of options), so there is little risk
you throw in extra fruit salad of options), so there is little risk
there.
- EEPROM has around a 100000 write cycle. You shouldn't rewrite the
firmware repeatedly and continually; that'll burn the EEPROM
eventually.
## NKRO Doesn't work
First you have to compile frimware with this build option `NKRO_ENABLE` in **Makefile**.
First you have to compile firmware with this build option `NKRO_ENABLE` in **Makefile**.
Try `Magic` **N** command(`LShift+RShift+N` by default) when **NKRO** still doesn't work. You can use this command to toggle between **NKRO** and **6KRO** mode temporarily. In some situations **NKRO** doesn't work you need to switch to **6KRO** mode, in particular when you are in BIOS.
If your firmware built with `BOOTMAGIC_ENABLE` you need to turn its switch on by `BootMagic` **N** command(`Space+N` by default). This setting is stored in EEPROM and keeped over power cycles.
If your firmware built with `BOOTMAGIC_ENABLE` you need to turn its switch on by `BootMagic` **N** command(`Space+N` by default). This setting is stored in EEPROM and kept over power cycles.
https://github.com/tmk/tmk_keyboard#boot-magic-configuration---virtual-dip-switch
## TrackPoint needs reset circuit(PS/2 mouse support)
Without reset circuit you will have inconsistent reuslt due to improper initialize of the hardware. See circuit schematic of TPM754.
## TrackPoint Needs Reset Circuit (PS/2 Mouse Support)
Without reset circuit you will have inconsistent result due to improper initialize of the hardware. See circuit schematic of TPM754.
- http://geekhack.org/index.php?topic=50176.msg1127447#msg1127447
- http://www.mikrocontroller.net/attachment/52583/tpm754.pdf
## Can't read column of matrix beyond 16
## Can't Read Column of Matrix Beyond 16
Use `1UL<<16` instead of `1<<16` in `read_cols()` in [matrix.h] when your columns goes beyond 16.
In C `1` means one of [int] type which is [16bit] in case of AVR so you can't shift left more than 15. You will get unexpected zero when you say `1<<16`. You have to use [unsigned long] type with `1UL`.
In C `1` means one of [int] type which is [16 bit] in case of AVR so you can't shift left more than 15. You will get unexpected zero when you say `1<<16`. You have to use [unsigned long] type with `1UL`.
http://deskthority.net/workshop-f7/rebuilding-and-redesigning-a-classic-thinkpad-keyboard-t6181-60.html#p146279
## Bootloader jump doesn't work
## Bootloader Jump Doesn't Work
Properly configure bootloader size in **Makefile**. With wrong section size bootloader won't probably start with **Magic command** and **Boot Magic**.
```
# Size of Bootloaders in bytes:
# Atmel DFU loader(ATmega32U4) 4096
# Atmel DFU loader(AT90USB128) 8192
# LUFA bootloader(ATmega32U4) 4096
# Arduino Caterina(ATmega32U4) 4096
# USBaspLoader(ATmega***) 2048
# Teensy halfKay(ATmega32U4) 512
# Atmel DFU loader(ATmega32U4) 4096
# Atmel DFU loader(AT90USB128) 8192
# LUFA bootloader(ATmega32U4) 4096
# Arduino Caterina(ATmega32U4) 4096
# USBaspLoader(ATmega***) 2048
# Teensy halfKay(ATmega32U4) 512
# Teensy++ halfKay(AT90USB128) 2048
OPT_DEFS += -DBOOTLOADER_SIZE=4096
```
@ -135,14 +135,14 @@ byte Atmel/LUFA(ATMega32u4) byte Atmel(AT90SUB1286)
| | | |
| | | |
| Application | | Application |
| | | |
| | | |
= = = =
| | 32KB-4KB | | 128KB-8KB
0x6000 +---------------+ 0x1E000 +---------------+
| Bootloader | 4KB | Bootloader | 8KB
0x7FFF +---------------+ 0x1FFFF +---------------+
byte Teensy(ATMega32u4) byte Teensy++(AT90SUB1286)
0x0000 +---------------+ 0x00000 +---------------+
| | | |
@ -159,15 +159,16 @@ byte Teensy(ATMega32u4) byte Teensy++(AT90SUB1286)
And see this discussion for further reference.
https://github.com/tmk/tmk_keyboard/issues/179
If you are using a TeensyUSB, there is a [known bug](https://github.com/qmk/qmk_firmware/issues/164) in which the hardware reset button prevents the RESET key from working. Unplugging the keyboard and plugging it back in should resolve the problem.
## Special Extra key doesn't work(System, Audio control keys)
## Special Extra Key Doesn't Work (System, Audio Control Keys)
You need to define `EXTRAKEY_ENABLE` in `rules.mk` to use them in QMK.
```
EXTRAKEY_ENABLE = yes # Audio control and System control
```
## Wakeup from sleep doesn't work
## Wakeup from Sleep Doesn't Work
In Windows check `Allow this device to wake the computer` setting in Power **Management property** tab of **Device Manager**. Also check BIOS setting.
@ -180,11 +181,11 @@ Pressing any key during sleep should wake host.
- http://arduino.cc/en/uploads/Main/arduino-leonardo-schematic_3b.pdf
- http://arduino.cc/en/uploads/Main/arduino-micro-schematic.pdf
Arduino leonardo and micro have **ATMega32U4** and can be used for TMK, though Arduino bootloader may be a problem.
Arduino Leonardo and micro have **ATMega32U4** and can be used for TMK, though Arduino bootloader may be a problem.
## Using PF4-7 pins of USB AVR?
You need to set JTD bit of MCUCR yourself to use PF4-7 as GPIO. Those pins are configured to serve JTAG function by default. MCUs like ATMega*U* or AT90USB* are affeteced with this.
## Using PF4-7 Pins of USB AVR?
You need to set JTD bit of MCUCR yourself to use PF4-7 as GPIO. Those pins are configured to serve JTAG function by default. MCUs like ATMega*U* or AT90USB* are affected with this.
If you are using Teensy this isn't needed. Teensy is shipped with JTAGEN fuse bit unprogrammed to disable the function.
@ -199,7 +200,7 @@ https://github.com/tmk/tmk_keyboard/blob/master/keyboard/hbkb/matrix.c#L67
And read **26.5.1 MCU Control Register MCUCR** of ATMega32U4 datasheet.
## Adding LED indicators of Lock keys
## Adding LED Indicators of Lock Keys
You need your own LED indicators for CapsLock, ScrollLock and NumLock? See this post.
http://deskthority.net/workshop-f7/tmk-keyboard-firmware-collection-t4478-120.html#p191560
@ -217,26 +218,26 @@ http://arduino.cc/en/Main/ArduinoBoardMicro
https://geekhack.org/index.php?topic=14290.msg1563867#msg1563867
## USB 3 compatibility
## USB 3 Compatibility
I heard some people have a problem with USB 3 port, try USB 2 port.
## Mac compatibility
## Mac Compatibility
### OS X 10.11 and Hub
https://geekhack.org/index.php?topic=14290.msg1884034#msg1884034
## Problem on BIOS(UEFI)/Resume(Sleep&Wake)/Power cycles
## Problem on BIOS (UEFI)/Resume (Sleep & Wake)/Power Cycles
Some people reported their keyboard stops working on BIOS and/or after resume(power cycles).
As of now root of its cause is not clear but some build options seem to be related. In Makefile try to disable those options like `CONSOLE_ENABLE`, `NKRO_ENABLE`, `SLEEP_LED_ENABLE` and/or others.
As of now root of its cause is not clear but some build options seem to be related. In Makefile try to disable those options like `CONSOLE_ENABLE`, `NKRO_ENABLE`, `SLEEP_LED_ENABLE` and/or others.
https://github.com/tmk/tmk_keyboard/issues/266
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
## FLIP doesn't work
### AtLibUsbDfu.dll not found
## FLIP Doesn't Work
### `AtLibUsbDfu.dll` Not Found
Remove current driver and reinstall one FLIP provides from DeviceManager.
http://imgur.com/a/bnwzy

@ -4,17 +4,16 @@
[QMK](https://github.com/qmk), short for Quantum Mechanical Keyboard, is a group of people building tools for custom keyboards. We started with the [QMK firmware](https://github.com/qmk/qmk_firmware), a heavily modified fork of [TMK](https://github.com/tmk/tmk_keyboard).
### Why the name Quantum?
### Why the Name Quantum?
<!-- FIXME -->
## What Differences Are There Between QMK and TMK?
TMK was originally designed and implemented by [Jun Wako](https://github.com/tmk). QMK started as [Jack Humbert's](https://github.com/jackhumbert) fork of TMK for the Planck. After a while Jack's fork had diverged quite a bit from TMK, and in 2015 Jack decided to rename his fork to QMK.
TMK was originally designed and implemented by [Jun Wako](https://github.com/tmk). QMK started as [Jack Humbert](https://github.com/jackhumbert)'s fork of TMK for the Planck. After a while Jack's fork had diverged quite a bit from TMK, and in 2015 Jack decided to rename his fork to QMK.
From a technical standpoint QMK builds upon TMK by adding several new features. Most notably QMK has expanded the number of available keycodes and uses these to implement advanced features like `S()`, `LCTL()`, and `MO()`. You can see a complete list of these keycodes in [Keycodes](keycodes.md).
From a project and community management standpoint TMK maintains all the officially supported keyboards by himself, with a bit of community support. Separate community maintained forks exist or can be created for other keyboards. Only a few keymaps are provided by default, so users typically don't share keymaps with each other. QMK encourages sharing of both keyboards and keymaps through a centrally managed repository, accepting all pull requests that follow the quality standards. These are mostly community maintained, but the QMK team also helps when necessary.
Both approaches have their merits and their drawbacks, and code flows freely between TMK and QMK when it makes sense.

@ -7,37 +7,57 @@ See [Keycodes](keycodes.md) for an index of keycodes available to you. These lin
Keycodes are actually defined in [common/keycode.h](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/keycode.h).
## `KC_SYSREQ` isn't working
## What Are the Default Keycodes?
There are 3 standard keyboard layouts in use around the world- ANSI, ISO, and JIS. North America primarily uses ANSI, Europe and Africa primarily use ISO, and Japan uses JIS. Regions not mentioned typically use either ANSI or ISO. The keycodes corresponding to these layouts are shown here:
<!-- Source for this image: http://www.keyboard-layout-editor.com/#/gists/9ce023dc6caadc0cf11c88c782350a8c -->
![Keyboard Layout Image](https://i.imgur.com/45m4mRf.png)
## Some Of My Keys Are Swapped Or Not Working
QMK has two features, Bootmagic and Command, which allow you to change the behavior of your keyboard on the fly. This includes, but is not limited to, swapping Ctrl/Caps, disabling Gui, swapping Alt/Gui, swapping Backspace/Backslash, disabling all keys, and other behavioral modifications.
As a quick fix try holding down `Space`+`Backspace` while you plug in your keyboard. This will reset the stored settings on your keyboard, returning those keys to normal operation. If that doesn't work look here:
* [Bootmagic](feature_bootmagic.md)
* [Command](feature_command.md)
## The Menu Key Isn't Working
The key found on most modern keyboards that is located between `KC_RGUI` and `KC_RCTL` is actually called `KC_APP`. This is because when that key was invented there was already a key named `MENU` in the relevant standards, so MS chose to call that the `APP` key.
## `KC_SYSREQ` Isn't Working
Use keycode for Print Screen(`KC_PSCREEN` or `KC_PSCR`) instead of `KC_SYSREQ`. Key combination of 'Alt + Print Screen' is recognized as 'System request'.
See [issue #168](https://github.com/tmk/tmk_keyboard/issues/168) and
- http://en.wikipedia.org/wiki/Magic_SysRq_key
- http://en.wikipedia.org/wiki/System_request
* http://en.wikipedia.org/wiki/Magic_SysRq_key
* http://en.wikipedia.org/wiki/System_request
## Power key doesn't work
## Power Key Doesn't Work
Use `KC_PWR` instead of `KC_POWER` or vice versa.
- `KC_PWR` works with Windows and Linux, not with OSX.
- `KC_POWER` works with OSX and Linux, not with Windows.
* `KC_PWR` works with Windows and Linux, not with OSX.
* `KC_POWER` works with OSX and Linux, not with Windows.
More info: http://geekhack.org/index.php?topic=14290.msg1327264#msg1327264
## Oneshot modifier
Solves my personal 'the' problem. I often got 'the' or 'THe' wrongly instead of 'The'. Oneshot Shift mitgates this for me.
## One Shot Modifier
Solves my personal 'the' problem. I often got 'the' or 'THe' wrongly instead of 'The'. One Shot Shift mitigates this for me.
https://github.com/tmk/tmk_keyboard/issues/67
## Modifier/Layer stuck
## Modifier/Layer Stuck
Modifier keys or layers can be stuck unless layer switching is configured properly.
For Modifier keys and layer actions you have to place `KC_TRANS` on same position of destination layer to unregister the modifier key or return to previous layer on release event.
- https://github.com/tmk/tmk_core/blob/master/doc/keymap.md#31-momentary-switching
- http://geekhack.org/index.php?topic=57008.msg1492604#msg1492604
- https://github.com/tmk/tmk_keyboard/issues/248
* https://github.com/tmk/tmk_core/blob/master/doc/keymap.md#31-momentary-switching
* http://geekhack.org/index.php?topic=57008.msg1492604#msg1492604
* https://github.com/tmk/tmk_keyboard/issues/248
## Mechanical Lock Switch Support
This feature is for *mechanical lock switch* like [this Alps one](http://deskthority.net/wiki/Alps_SKCL_Lock). You can enable it by adding this to your `config.h`:
```
#define LOCKING_SUPPORT_ENABLE
#define LOCKING_RESYNC_ENABLE
@ -47,7 +67,7 @@ After enabling this feature use keycodes `KC_LCAP`, `KC_LNUM` and `KC_LSCR` in y
Old vintage mechanical keyboards occasionally have lock switches but modern ones don't have. ***You don't need this feature in most case and just use keycodes `KC_CAPS`, `KC_NLCK` and `KC_SLCK`.***
## Input special charactors other than ASCII like Cédille 'Ç'
## Input Special Characters Other Than ASCII like Cédille 'Ç'
NO UNIVERSAL METHOD TO INPUT THOSE WORKS OVER ALL SYSTEMS. You have to define **MACRO** in way specific to your OS or layout.
See this post for example **MACRO** code.
@ -55,20 +75,20 @@ See this post for example **MACRO** code.
http://deskthority.net/workshop-f7/tmk-keyboard-firmware-collection-t4478-120.html#p195620
On **Windows** you can use `AltGr` key or **Alt code**.
- http://en.wikipedia.org/wiki/AltGr_key
- http://en.wikipedia.org/wiki/Alt_code
* http://en.wikipedia.org/wiki/AltGr_key
* http://en.wikipedia.org/wiki/Alt_code
On **Mac** OS defines `Option` key combinations.
- http://en.wikipedia.org/wiki/Option_key#Alternative_keyboard_input
* http://en.wikipedia.org/wiki/Option_key#Alternative_keyboard_input
On **Xorg** you can use `compose` key, instead.
- http://en.wikipedia.org/wiki/Compose_key
* http://en.wikipedia.org/wiki/Compose_key
And see this for **Unicode** input.
- http://en.wikipedia.org/wiki/Unicode_input
* http://en.wikipedia.org/wiki/Unicode_input
## Apple/Mac keyboard Fn
## Apple/Mac Keyboard `Fn`
Not supported.
Apple/Mac keyboard sends keycode for Fn unlike most of other keyboards.
@ -77,13 +97,13 @@ I think you can send Apple Fn key using Apple venter specific Page 0xff01 and us
https://opensource.apple.com/source/IOHIDFamily/IOHIDFamily-606.1.7/IOHIDFamily/AppleHIDUsageTables.h
## Media control keys in Mac OSX
#### KC_MNXT and KC_MPRV does not work on Mac
## Media Control Keys in Mac OSX
#### KC_MNXT and KC_MPRV Does Not Work on Mac
Use `KC_MFFD`(`KC_MEDIA_FAST_FORWARD`) and `KC_MRWD`(`KC_MEDIA_REWIND`) instead of `KC_MNXT` and `KC_MPRV`.
See https://github.com/tmk/tmk_keyboard/issues/195
## Keys supported in Mac OSX?
## Keys Supported in Mac OSX?
You can know which keycodes are supported in OSX from this source code.
`usb_2_adb_keymap` array maps Keyboard/Keypad Page usages to ADB scancodes(OSX internal keycodes).
@ -95,7 +115,7 @@ And `IOHIDConsumer::dispatchConsumerEvent` handles Consumer page usages.
https://opensource.apple.com/source/IOHIDFamily/IOHIDFamily-606.1.7/IOHIDFamily/IOHIDConsumer.cpp
## JIS keys in Mac OSX
## JIS Keys in Mac OSX
Japanese JIS keyboard specific keys like `無変換(Muhenkan)`, `変換(Henkan)`, `ひらがな(hiragana)` are not recognized on OSX. You can use **Seil** to enable those keys, try following options.
* Enable NFER Key on PC keyboard
@ -105,23 +125,21 @@ Japanese JIS keyboard specific keys like `無変換(Muhenkan)`, `変換(Henkan)`
https://pqrs.org/osx/karabiner/seil.html
## RN-42 Bluetooth doesn't work with Karabiner
## RN-42 Bluetooth Doesn't Work with Karabiner
Karabiner - Keymapping tool on Mac OSX - ignores inputs from RN-42 module by default. You have to enable this option to make Karabiner working with your keyboard.
https://github.com/tekezo/Karabiner/issues/403#issuecomment-102559237
See these for the deail of this problem.
See these for the detail of this problem.
https://github.com/tmk/tmk_keyboard/issues/213
https://github.com/tekezo/Karabiner/issues/403
## Esc and `~ on a key
Use `GRAVE_ESC` or `KC_GESC` in your keymap. `GUI`+`GRAVE_ESC` results in `` ` `` and `SHIFT`+`GRAVE_ESC` results in `~`.
## Esc and <code>&#96;</code> on a Single Key
Note that this will break the CTRL+SHIFT+ESC shortcut to the Windows task manager. Use `#define GRAVE_ESC_CTRL_OVERRIDE` in your `config.h` to get the shortcut back. With this option, `ESC_GRAVE` results in `ESC` if `CTRL` is held, even if `SHIFT` or `GUI` are also held.
See the [Grave Escape](feature_grave_esc.md) feature.
## Arrow on Right Modifier keys with Dual-Role
This turns right modifer keys into arrow keys when the keys are tapped while still modifiers when the keys are hold. In TMK the dual-role function is dubbed **TAP**.
## Arrow on Right Modifier Keys with Dual-Role
This turns right modifier keys into arrow keys when the keys are tapped while still modifiers when the keys are hold. In TMK the dual-role function is dubbed **TAP**.
```
#include "keymap_common.h"
@ -172,18 +190,18 @@ It seems Windows 10 ignores the code and Linux/Xorg recognizes but has no mappin
Not sure what keycode Eject is on genuine Apple keyboard actually. HHKB uses `F20` for Eject key(`Fn+f`) on Mac mode but this is not same as Apple Eject keycode probably.
## What's weak_mods and real_mods in action_util.c
## What's `weak_mods` and `real_mods` in `action_util.c`
___TO BE IMPROVED___
real_mods is intended to retains state of real/physical modifier key state, while
weak_mods retains state of virtual or temprary modifiers which should not affect state real modifier key.
weak_mods retains state of virtual or temporary modifiers which should not affect state real modifier key.
Let's say you hold down physical left shift key and type ACTION_MODS_KEY(LSHIFT, KC_A),
Let's say you hold down physical left shift key and type ACTION_MODS_KEY(LSHIFT, KC_A),
with weak_mods,
* (1) hold down left shift: real_mods |= MOD_BIT(LSHIFT)
* (2) press ACTION_MODS_KEY(LSHIFT, KC_A): weak_mods |= MOD_BIT(LSHIFT)
* (3) release ACTION_MODS_KEY(LSHIFT, KC_A): waek_mods &= ~MOD_BIT(LSHIFT)
* (3) release ACTION_MODS_KEY(LSHIFT, KC_A): weak_mods &= ~MOD_BIT(LSHIFT)
real_mods still keeps modifier state.
without weak mods,
@ -195,7 +213,7 @@ here real_mods lost state for 'physical left shift'.
weak_mods is ORed with real_mods when keyboard report is sent.
https://github.com/tmk/tmk_core/blob/master/common/action_util.c#L57
## Timer functionality
## Timer Functionality
It's possible to start timers and read values for time-specific events - here's an example:

@ -0,0 +1,179 @@
# Advanced Keycodes
Your keymap can include keycodes that are more advanced than normal, for example shifted keys. This page documents the functions that are available to you.
### Assigning Custom Names
People often define custom names using `#define`. For example:
```c
#define FN_CAPS LT(_FL, KC_CAPSLOCK)
#define ALT_TAB LALT(KC_TAB)
```
This will allow you to use `FN_CAPS` and `ALT_TAB` in your `KEYMAP()`, keeping it more readable.
### Limits of These Aliases
Currently, the keycodes able to used with these functions are limited to the [Basic Keycodes](keycodes_basic.md), meaning you can't use keycodes like `KC_TILD`, or anything greater than 0xFF. For a full list of the keycodes able to be used see [Basic Keycodes](keycodes_basic.md).
# Switching and Toggling Layers
These functions allow you to activate layers in various ways. Note that layers are not generally independent layouts -- multiple layers can be activated at once, and it's typical for layers to use `KC_TRNS` to allow keypresses to pass through to lower layers. For a detailed explanation of layers, see [Keymap Overview](keymap.md#keymap-and-layers)
* `DF(layer)` - switches the default layer. The default layer is the always-active base layer that other layers stack on top of. See below for more about the default layer. This might be used to switch from QWERTY to Dvorak layout. (Note that this is a temporary switch that only persists until the keyboard loses power. To modify the default layer in a persistent way requires deeper customization, such as calling the `set_single_persistent_default_layer` function inside of [process_record_user](custom_quantum_functions.md#programming-the-behavior-of-any-keycode).)
* `MO(layer)` - momentarily activates *layer*. As soon as you let go of the key, the layer is deactivated.
* `LM(layer, mod)` - Momentarily activates *layer* (like `MO`), but with modifier(s) *mod* active. Only supports layers 0-15 and the left modifiers.
* `LT(layer, kc)` - momentarily activates *layer* when held, and sends *kc* when tapped.
* `TG(layer)` - toggles *layer*, activating it if it's inactive and vice versa
* `TO(layer)` - activates *layer* and de-activates all other layers (except your default layer). This function is special, because instead of just adding/removing one layer to your active layer stack, it will completely replace your current active layers, uniquely allowing you to replace higher layers with a lower one. This is activated on keydown (as soon as the key is pressed).
* `TT(layer)` - Layer Tap-Toggle. If you hold the key down, *layer* is activated, and then is de-activated when you let go (like `MO`). If you repeatedly tap it, the layer will be toggled on or off (like `TG`). It needs 5 taps by default, but you can change this by defining `TAPPING_TOGGLE` -- for example, `#define TAPPING_TOGGLE 2` to toggle on just two taps.
# Working with Layers
Care must be taken when switching layers, it's possible to lock yourself into a layer with no way to deactivate that layer (without unplugging your keyboard.) We've created some guidelines to help users avoid the most common problems.
### Beginners
If you are just getting started with QMK you will want to keep everything simple. Follow these guidelines when setting up your layers:
* Setup layer 0 as your default, "base" layer. This is your normal typing layer, and could be whatever layout you want (qwerty, dvorak, colemak, etc.). It's important to set this as the lowest layer since it will typically have most or all of the keyboard's keys defined, so would block other layers from having any effect if it were above them (i.e., had a higher layer number).
* Arrange your layers in a "tree" layout, with layer 0 as the root. Do not try to enter the same layer from more than one other layer.
* In a layer's keymap, only reference higher-numbered layers. Because layers are processed from the highest-numbered (topmost) active layer down, modifying the state of lower layers can be tricky and error-prone.
### Intermediate Users
Sometimes you need more than one base layer. For example, if you want to switch between QWERTY and Dvorak, switch between layouts for different countries, or switch your layout for different videogames. Your base layers should always be the lowest numbered layers. When you have multiple base layers you should always treat them as mutually exclusive. When one base layer is on the others are off.
### Advanced Users
Once you have a good feel for how layers work and what you can do, you can get more creative. The rules listed in the beginner section will help you be successful by avoiding some of the tricker details but they can be constraining, especially for ultra-compact keyboard users. Understanding how layers work will allow you to use them in more advanced ways.
Layers stack on top of each other in numerical order. When determining what a keypress does, QMK scans the layers from the top down, stopping when it reaches the first active layer that is not set to `KC_TRNS`. As a result if you activate a layer that is numerically lower than your current layer, and your current layer (or another layer that is active and higher than your target layer) has something other than `KC_TRNS`, that is the key that will be sent, not the key on the layer you just activated. This is the cause of most people's "why doesn't my layer get switched" problem.
Sometimes, you might want to switch between layers in a macro or as part of a tap dance routine. `layer_on` activates a layer, and `layer_off` deactivates it. More layer-related functions can be found in [action_layer.h](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/action_layer.h).
# Modifier Keys
These functions allow you to combine a mod with a keycode. When pressed the keydown for the mod will be sent first, and then *kc* will be sent. When released the keyup for *kc* will be sent and then the mod will be sent.
* `LSFT(kc)` or `S(kc)` - applies left Shift to *kc* (keycode)
* `RSFT(kc)` - applies right Shift to *kc*
* `LCTL(kc)` - applies left Control to *kc*
* `RCTL(kc)` - applies right Control to *kc*
* `LALT(kc)` - applies left Alt to *kc*
* `RALT(kc)` - applies right Alt to *kc*
* `LGUI(kc)` - applies left GUI (command/win) to *kc*
* `RGUI(kc)` - applies right GUI (command/win) to *kc*
* `HYPR(kc)` - applies Hyper (all modifiers) to *kc*
* `MEH(kc)` - applies Meh (all modifiers except Win/Cmd) to *kc*
* `LCAG(kc)` - applies CtrlAltGui to *kc*
You can also chain these, like this:
LALT(LCTL(KC_DEL)) -- this makes a key that sends Alt, Control, and Delete in a single keypress.
# Shifted Keycodes
The following shortcuts automatically add `LSFT()` to keycodes to get commonly used symbols.
|Key |Aliases |Description |
|------------------------|------------------|-------------------|
|`KC_TILDE` |`KC_TILD` |`~` |
|`KC_EXCLAIM` |`KC_EXLM` |`!` |
|`KC_AT` | |`@` |
|`KC_HASH` | |`#` |
|`KC_DOLLAR` |`KC_DLR` |`$` |
|`KC_PERCENT` |`KC_PERC` |`%` |
|`KC_CIRCUMFLEX` |`KC_CIRC` |`^` |
|`KC_AMPERSAND` |`KC_AMPR` |`&` |
|`KC_ASTERISK` |`KC_ASTR` |`*` |
|`KC_LEFT_PAREN` |`KC_LPRN` |`(` |
|`KC_RIGHT_PAREN` |`KC_RPRN` |`)` |
|`KC_UNDERSCORE` |`KC_UNDS` |`_` |
|`KC_PLUS` | |`+` |
|`KC_LEFT_CURLY_BRACE` |`KC_LCBR` |`{` |
|`KC_RIGHT_CURLY_BRACE` |`KC_RCBR` |`}` |
|`KC_PIPE` | |<code>&#124;</code>|
|`KC_COLON` |`KC_COLN` |`:` |
|`KC_DOUBLE_QUOTE` |`KC_DQT`/`KC_DQUO`|`"` |
|`KC_LEFT_ANGLE_BRACKET` |`KC_LT`/`KC_LABK` |`<` |
|`KC_RIGHT_ANGLE_BRACKET`|`KC_GT`/`KC_RABK` |`>` |
|`KC_QUESTION` |`KC_QUES` |`?` |
# Mod Tap
`MT(mod, kc)` - is *mod* (modifier key - MOD_LCTL, MOD_LSFT) when held, and *kc* when tapped. In other words, you can have a key that sends Esc (or the letter O or whatever) when you tap it, but works as a Control key or a Shift key when you hold it down.
These are the values you can use for the `mod` in `MT()` and `OSM()`:
* MOD_LCTL
* MOD_LSFT
* MOD_LALT
* MOD_LGUI
* MOD_RCTL
* MOD_RSFT
* MOD_RALT
* MOD_RGUI
* MOD_HYPR
* MOD_MEH
These can also be combined like `MOD_LCTL | MOD_LSFT` e.g. `MT(MOD_LCTL | MOD_LSFT, KC_ESC)` which would activate Control and Shift when held, and send Escape when tapped.
We've added shortcuts to make common modifier/tap (mod-tap) mappings more compact:
* `CTL_T(kc)` - is LCTL when held and *kc* when tapped
* `SFT_T(kc)` - is LSFT when held and *kc* when tapped
* `ALT_T(kc)` - is LALT when held and *kc* when tapped
* `ALGR_T(kc)` - is AltGr when held and *kc* when tapped
* `GUI_T(kc)` - is LGUI when held and *kc* when tapped
* `ALL_T(kc)` - is Hyper (all mods) when held and *kc* when tapped. To read more about what you can do with a Hyper key, see [this blog post by Brett Terpstra](http://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/)
* `LCAG_T(kc)` - is CtrlAltGui when held and *kc* when tapped
* `MEH_T(kc)` - is like Hyper, but not as cool -- does not include the Cmd/Win key, so just sends Alt+Ctrl+Shift.
{% hint style='info' %}
Due to the way that keycodes are structured, any modifiers specified as part of `kc`, such as `LCTL()` or `KC_LPRN`, will only activate when held instead of tapped.
Additionally, if there is at least one right modifier, any other modifiers will turn into their right equivalents, so it is not possible to "mix and match" the two.
{% endhint %}
# One Shot Keys
One shot keys are keys that remain active until the next key is pressed, and then are released. This allows you to type keyboard combinations without pressing more than one key at a time. These keys are usually called "Sticky keys" or "Dead keys".
For example, if you define a key as `OSM(MOD_LSFT)`, you can type a capital A character by first pressing and releasing shift, and then pressing and releasing A. Your computer will see the shift key being held the moment shift is pressed, and it will see the shift key being released immediately after A is released.
One shot keys also work as normal modifiers. If you hold down a one shot key and type other keys, your one shot will be released immediately after you let go of the key.
You can control the behavior of one shot keys by defining these in `config.h`:
```c
#define ONESHOT_TAP_TOGGLE 5 /* Tapping this number of times holds the key until tapped this number of times again. */
#define ONESHOT_TIMEOUT 5000 /* Time (in ms) before the one shot key is released */
```
* `OSM(mod)` - Momentarily hold down *mod*. You must use the `MOD_*` keycodes as shown in [Mod Tap](#mod-tap), not the `KC_*` codes.
* `OSL(layer)` - momentary switch to *layer*.
Sometimes, you want to activate a one-shot layer as part of a macro or tap dance routine. To do this, you need to call `set_oneshot_layer(LAYER, ONESHOT_START)` on key down, and `set_oneshot_layer(ONESHOT_PRESSED)` on key up. If you want to cancel the oneshot, call `reset_oneshot_layer()`. For more complicated actions, take a look at the oneshot implementation in [`process_record`](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/action.c#L429).
If you're having issues with OSM translating over Remote Desktop Connection, this can be fixed by opening the settings, going to the "Local Resources" tap, and in the keyboard section, change the drop down to "On this Computer". This will fix the issue and allow OSM to function properly over Remote Desktop.
# Permissive Hold
As of [PR#1359](https://github.com/qmk/qmk_firmware/pull/1359/), there is a new `config.h` option:
```
#define PERMISSIVE_HOLD
```
This makes it easier for fast typists to use dual-function keys. Without this, if you let go of a held key inside the tapping term, it won't register.
Example: (Tapping Term = 200ms)
- SHFT_T(KC_A) Down
- KC_X Down
- KC_X Up
- SHFT_T(KC_A) Up
With defaults, if above is typed within tapping term, this will emit `ax`. With permissive hold, if above is typed within tapping term, this will emit `X` (so, Shift+X).

@ -1,6 +1,17 @@
# Audio
Your keyboard can make sounds! If you've got a Planck, Preonic, or basically any AVR keyboard that allows access to the C6 or B5 port (`#define C6_AUDIO` and/or `#define B5_AUDIO`), you can hook up a simple speaker and make it beep. You can use those beeps to indicate layer transitions, modifiers, special keys, or just to play some funky 8bit tunes.
Your keyboard can make sounds! If you've got a Planck, Preonic, or basically any AVR keyboard that allows access to certain PWM-capable pins, you can hook up a simple speaker and make it beep. You can use those beeps to indicate layer transitions, modifiers, special keys, or just to play some funky 8bit tunes.
Up to two simultaneous audio voices are supported, one driven by timer 1 and another driven by timer 3. The following pins can be defined as audio outputs in config.h:
Timer 1:
`#define B5_AUDIO`
`#define B6_AUDIO`
`#define B7_AUDIO`
Timer 3:
`#define C4_AUDIO`
`#define C5_AUDIO`
`#define C6_AUDIO`
If you add `AUDIO_ENABLE = yes` to your `rules.mk`, there's a couple different sounds that will automatically be enabled without any other configuration:
@ -47,9 +58,9 @@ PLAY_LOOP(my_song);
It's advised that you wrap all audio features in `#ifdef AUDIO_ENABLE` / `#endif` to avoid causing problems when audio isn't built into the keyboard.
## Music mode
## Music Mode
The music mode maps your columns to a chromatic scale, and your rows to octaves. This works best with ortholinear keyboards, but can be made to work with others. All keycodes less than `0xFF` get blocked, so you won't type while playing notes - if you have special keys/mods, those will still work. A work-around for this is to jump to a different layer with KC_NOs before (or after) enabling music mode.
The music mode maps your columns to a chromatic scale, and your rows to octaves. This works best with ortholinear keyboards, but can be made to work with others. All keycodes less than `0xFF` get blocked, so you won't type while playing notes - if you have special keys/mods, those will still work. A work-around for this is to jump to a different layer with KC_NOs before (or after) enabling music mode.
Recording is experimental due to some memory issues - if you experience some weird behavior, unplugging/replugging your keyboard will fix things.
@ -82,7 +93,41 @@ The pitch standard (`PITCH_STANDARD_A`) is 440.0f by default - to change this, a
#define PITCH_STANDARD_A 432.0f
## MIDI functionalty
You can completely disable Music Mode as well. This is useful, if you're pressed for space on your controller. To disable it, add this to your `config.h`:
#define NO_MUSIC_MODE
## Faux Click
This adds a click sound each time you hit a button, to simulate click sounds from the keyboard. And the sounds are slightly different for each keypress, so it doesn't sound like a single long note, if you type rapidly.
* `CK_TOGG` - Toggles the status (will play sound if enabled)
* `CK_RST` - Resets the frequency to the default state
* `CK_UP` - Increases the frequency of the clicks
* `CK_DOWN` - Decreases the frequency of the clicks
The feature is disabled by default, to save space. To enable it, add this to your `config.h`:
#define AUDIO_CLICKY
Additionally, even when enabled, the feature is not enabled by default, so you would need to turn it on first. And since we don't use EEPROM to store the setting (yet), you can default this to on by adding this to your `config.h`:
#define AUDIO_CLICKY_ON
You can configure the default, min and max frequencies, the stepping and built in randomness by defining these values:
| Option | Default Value | Description |
|--------|---------------|-------------|
| `AUDIO_CLICKY_FREQ_DEFAULT` | 440.0f | Sets the default/starting audio frequency for the clicky sounds. |
| `AUDIO_CLICKY_FREQ_MIN` | 65.0f | Sets the lowest frequency (under 60f are a bit buggy). |
| `AUDIO_CLICKY_FREQ_MAX` | 1500.0f | Sets the the highest frequency. Too high may result in coworkers attacking you. |
| `AUDIO_CLICKY_FREQ_FACTOR` | 1.18921f| Sets the stepping of UP/DOWN key codes. |
| `AUDIO_CLICKY_FREQ_RANDOMNESS` | 0.05f | Sets a factor of randomness for the clicks, Setting this to `0f` will make each click identical. |
## MIDI Functionality
This is still a WIP, but check out `quantum/keymap_midi.c` to see what's happening. Enable from the Makefile.

@ -1,7 +1,7 @@
# Auto Shift: Why do we need a shift key?
# Auto Shift: Why Do We Need a Shift Key?
Tap a key and you get its character. Tap a key, but hold it *slightly* longer
and you get its shifted state. Viola! No shift key needed!
and you get its shifted state. Voilà! No shift key needed!
## Why Auto Shift?
@ -10,7 +10,7 @@ fingers repetitively long distances. For us on the keyboard, the pinky does that
all too often when reaching for the shift key. Auto Shift looks to alleviate that
problem.
## How does it work?
## How Does It Work?
When you tap a key, it stays depressed for a short period of time before it is
then released. This depressed time is a different length for everyone. Auto Shift
@ -20,7 +20,7 @@ when you release the key. If the time depressed is greater than or equal to the
`AUTO_SHIFT_TIMEOUT`, then a shifted version of the key is emitted. If the time
is less than the `AUTO_SHIFT_TIMEOUT` time, then the normal state is emitted.
## Are there limitations to Auto Shift?
## Are There Limitations to Auto Shift?
Yes, unfortunately.
@ -28,26 +28,35 @@ Yes, unfortunately.
characters, you could press and hold the 'a' key for a second or two. This no
longer works with Auto Shift because it is timing your depressed time instead
of emitting a depressed key state to your operating system.
2. Auto Shift is disabled for any key press that is accompanied by one or more
modifiers. Thus, Ctrl+A that you hold for a really long time is not the same
as Ctrl+Shift+A.
3. You will have characters that are shifted when you did not intend on shifting, and
2. You will have characters that are shifted when you did not intend on shifting, and
other characters you wanted shifted, but were not. This simply comes down to
practice. As we get in a hurry, we think we have hit the key long enough
for a shifted version, but we did not. On the other hand, we may think we are
tapping the keys, but really we have held it for a little longer than
anticipated.
## How do I enable Auto Shift?
## How Do I Enable Auto Shift?
Add to your `rules.mk` in the keymap folder:
AUTO_SHIFT_ENABLE = YES
AUTO_SHIFT_ENABLE = yes
If no `rules.mk` exists, you can create one.
Then compile and install your new firmware with Auto Key enabled! That's it!
## Modifiers
By default, Auto Shift is disabled for any key press that is accompanied by one or more
modifiers. Thus, Ctrl+A that you hold for a really long time is not the same
as Ctrl+Shift+A.
You can re-enable Auto Shift for modifiers by adding another rule to your `rules.mk`
AUTO_SHIFT_MODIFIERS = yes
In which case, Ctrl+A held past the `AUTO_SHIFT_TIMEOUT` will be sent as Ctrl+Shift+A
## Configuring Auto Shift
If desired, there is some configuration that can be done to change the
@ -66,7 +75,7 @@ A sample is
#endif
### AUTO_SHIFT_TIMEOUT (value in ms)
### AUTO_SHIFT_TIMEOUT (Value in ms)
This controls how long you have to hold a key before you get the shifted state.
Obviously, this is different for everyone. For the common person, a setting of
@ -75,7 +84,7 @@ is the default value. Then work down from there. The idea is to have the shortes
Play with this value until things are perfect. Many find that all will work well
at a given value, but one or two keys will still emit the shifted state on
occassion. This is simply due to habit and holding some keys a little longer
occasion. This is simply due to habit and holding some keys a little longer
than others. Once you find this value, work on tapping your problem keys a little
quicker than normal and you will be set.
@ -86,7 +95,7 @@ quick. See "Auto Shift Setup" for more details!
### NO_AUTO_SHIFT_SPECIAL (simple define)
Do not Auto Shift special keys, which include -_, =+, [{, ]}, ;:, '", ,<, .>,
Do not Auto Shift special keys, which include -\_, =+, [{, ]}, ;:, '", ,<, .>,
and /?
### NO_AUTO_SHIFT_NUMERIC (simple define)
@ -99,7 +108,7 @@ Do not Auto Shift alpha characters, which include A through Z.
## Using Auto Shift Setup
This will enable you to define three keys temporailiy to increase, decrease and report your `AUTO_SHIFT_TIMEOUT`.
This will enable you to define three keys temporarily to increase, decrease and report your `AUTO_SHIFT_TIMEOUT`.
### Setup
@ -110,6 +119,9 @@ Map three keys temporarily in your keymap:
| KC_ASDN | Lower the Auto Shift timeout variable (down) |
| KC_ASUP | Raise the Auto Shift timeout variable (up) |
| KC_ASRP | Report your current Auto Shift timeout value |
| KC_ASON | Turns on the Auto Shift Function |
| KC_ASOFF | Turns off the Auto Shift Function |
| KC_ASTG | Toggles the state of the Auto Shift feature |
Compile and upload your new firmware.
@ -134,27 +146,25 @@ completely normal and with no intention of shifted keys.
9. Remove the key bindings `KC_ASDN`, `KC_ASUP` and `KC_ASRP`.
10. Compile and upload your new firmware.
#### An example run
#### An Example Run
'''
hello world. my name is john doe. i am a computer programmer playing with
keyboards right now.
hello world. my name is john doe. i am a computer programmer playing with
keyboards right now.
[PRESS KC_ASDN quite a few times]
[PRESS KC_ASDN quite a few times]
heLLo woRLd. mY nAMe is JOHn dOE. i AM A compUTeR proGRaMMER PlAYiNG witH
KEYboArDS RiGHT NOw.
heLLo woRLd. mY nAMe is JOHn dOE. i AM A compUTeR proGRaMMER PlAYiNG witH
KEYboArDS RiGHT NOw.
[PRESS KC_ASUP a few times]
[PRESS KC_ASUP a few times]
hello world. my name is john Doe. i am a computer programmer playing with
keyboarDs right now.
hello world. my name is john Doe. i am a computer programmer playing with
keyboarDs right now.
[PRESS KC_ASRP]
[PRESS KC_ASRP]
115
'''
115
The keyboard typed `115` which represents your current `AUTO_SHIFT_TIMEOUT`
value. You are now set! Practice on the *D* key a little bit that showed up
in the testing and you'll be golden.
in the testing and you'll be golden.

@ -6,12 +6,34 @@
These keycodes control the backlight. Most keyboards use this for single color in-switch lighting.
|Name|Description|
|----|-----------|
|`BL_x`|Set a specific backlight level between 0-9|
|`BL_ON`|An alias for `BL_9`|
|`BL_OFF`|An alias for `BL_0`|
|`BL_DEC`|Turn the backlight level down by 1|
|`BL_INC`|Turn the backlight level up by 1|
|`BL_TOGG`|Toggle the backlight on or off|
|`BL_STEP`|Step through backlight levels, wrapping around to 0 when you reach the top.|
|Key |Description |
|---------|------------------------------------------|
|`BL_TOGG`|Turn the backlight on or off |
|`BL_STEP`|Cycle through backlight levels |
|`BL_ON` |Set the backlight to max brightness |
|`BL_OFF` |Turn the backlight off |
|`BL_INC` |Increase the backlight level |
|`BL_DEC` |Decrease the backlight level |
|`BL_BRTG`|Toggle backlight breathing |
Note that for backlight breathing, you need to have `#define BACKLIGHT_BREATHING` in your config.h.
## Configuration Options in `config.h`
* `BACKLIGHT_PIN B7` defines the pin that controlls the LEDs. Unless you design your own keyboard, you don't need to set this.
* `BACKLIGHT_LEVELS 3` defines the number of brightness levels (maximum 15 excluding off).
* `BACKLIGHT_BREATHING` if defined, enables backlight breathing. Note that this is only available if `BACKLIGHT_PIN` is B5, B6 or B7.
* `BREATHING_PERIOD 6` defines the length of one backlight "breath" in seconds.
## Notes on Implementation
To change the brightness when using pins B5, B6 or B7, the PWM (Pulse Width Modulation) functionality of the on-chip timer is used.
The timer is a counter that counts up to a certain TOP value (`0xFFFF` set in ICR1) before resetting to 0.
We also set an OCR1x register.
When the counter reaches the value stored in that register, the PWM pin drops to low.
The PWM pin is pulled high again when the counter resets to 0.
Therefore, OCR1x basically sets the duty cycle of the LEDs and as such the brightness where `0` is the darkest and `0xFFFF` the brightest setting.
To enable the breathing effect, we register an interrupt handler to be called whenever the counter resets (with `ISR(TIMER1_OVF_vect)`).
In this handler, which gets called roughly 244 times per second, we compute the desired brightness using a precomputed brightness curve.
To disable breathing, we can just disable the respective interrupt vector and reset the brightness to the desired level.

@ -1,6 +1,6 @@
# Bluetooth
## Bluetooth functionality
## Bluetooth Functionality
This requires [some hardware changes](https://www.reddit.com/r/MechanicalKeyboards/comments/3psx0q/the_planck_keyboard_with_bluetooth_guide_and/?ref=search_posts), but can be enabled via the Makefile. The firmware will still output characters via USB, so be aware of this when charging via a computer. It would make sense to have a switch on the Bluefruit to turn it off at will.
@ -10,8 +10,8 @@ This requires [some hardware changes](https://www.reddit.com/r/MechanicalKeyboar
This is used when multiple keyboard outputs can be selected. Currently this only allows for switching between USB and Bluetooth on keyboards that support both.
|Name|Description|
|----|-----------|
|`OUT_AUTO`|auto mode|
|`OUT_USB`|usb only|
|`OUT_BT`|bluetooth|
|Name |Description |
|----------|----------------------------------------------|
|`OUT_AUTO`|Automatically switch between USB and Bluetooth|
|`OUT_USB` |USB only |
|`OUT_BT` |Bluetooth only |

@ -1,29 +1,89 @@
# Bootmagic
<!-- FIXME: Describe the bootmagic feature here. -->
## Bootmagic Keycodes
Shortcuts for bootmagic options. You can use these even when bootmagic is off.
|Name|Description|
|----|-----------|
|`MAGIC_SWAP_CONTROL_CAPSLOCK`|Swap Capslock and Left Control|
|`MAGIC_CAPSLOCK_TO_CONTROL`|Treat Capslock like a Control Key|
|`MAGIC_SWAP_LALT_LGUI`|Swap the left Alt and GUI keys|
|`MAGIC_SWAP_RALT_RGUI`|Swap the right Alt and GUI keys|
|`MAGIC_NO_GUI`|Disable the GUI key|
|`MAGIC_SWAP_GRAVE_ESC`|Swap the Grave and Esc key.|
|`MAGIC_SWAP_BACKSLASH_BACKSPACE`|Swap backslash and backspace|
|`MAGIC_HOST_NKRO`|Force NKRO on|
|`MAGIC_SWAP_ALT_GUI`/`AG_SWAP`|Swap Alt and Gui on both sides|
|`MAGIC_UNSWAP_CONTROL_CAPSLOCK`|Disable the Control/Capslock swap|
|`MAGIC_UNCAPSLOCK_TO_CONTROL`|Disable treating Capslock like Control |
|`MAGIC_UNSWAP_LALT_LGUI`|Disable Left Alt and GUI switching|
|`MAGIC_UNSWAP_RALT_RGUI`|Disable Right Alt and GUI switching|
|`MAGIC_UNNO_GUI`|Enable the GUI key |
|`MAGIC_UNSWAP_GRAVE_ESC`|Disable the Grave/Esc swap |
|`MAGIC_UNSWAP_BACKSLASH_BACKSPACE`|Disable the backslash/backspace swap|
|`MAGIC_UNHOST_NKRO`|Force NKRO off|
|`MAGIC_UNSWAP_ALT_GUI`/`AG_NORM`|Disable the Alt/GUI switching|
|`MAGIC_TOGGLE_NKRO`|Turn NKRO on or off|
# Bootmagic and Magic Keycodes
There are 3 separate but related features that allow you to change the behavior of your keyboard without reflashing. While each of them have similar functionality you access that functionality in different ways depending on how your keyboard is configured.
Bootmagic is a system for configuring your keyboard while it initializes. To trigger a Bootmagic command you hold down the bootmagic key (`KC_SPACE` on most keyboards) and one or more command keys.
Bootmagic Keycodes allow you to access the Bootmagic functionality after your keyboard has initialized. To use Bootmagic Keycodes you assign keycodes starting with `MAGIC_`, much in the same way you define any other key.
Command is a feature that allows you to control different aspects of your keyboard. Command used to be called Magic. Command is typically accessed by holding Left and Right Shift at the same time, although that can be customized. While it shares some functionality with Bootmagic it also allows you to access functionality that Bootmagic does not. For more information see the [Command](feature_command.md) documentation page.
## Enabling Bootmagic
Bootmagic is disabled by default. To use Bootmagic you need to enable it in your `rules.mk` file:
BOOTMAGIC_ENABLE = yes
## Bootmagic Hotkeys and Keycodes
This table describes the default Hotkeys for Bootmagic and the Keycodes for Magic. These may be overriden at the Keyboard or Keymap level. Some functionality is not available in both methods.
To use the Hotkey hold down `BOOTMAGIC_KEY_SALT` (`KC_SPACE` by default) and the Hotkey while plugging in your keyboard. To use the Keycode assign that keycode to a layer. For example, if you hold down Space+B while plugging in most keyboards, you will enter bootloader mode.
|Hotkey |Keycode |Description |
|-----------|----------------------------------|--------------------------------------------------------|
|`ESC` | |Skip bootmagic and saved eeprom configuration |
|`B` |`RESET` |Enter bootloader instead of firmware |
|`D` |`DEBUG` |Enable debugging (writes messages to serial) |
|`X` | |Enable matrix debugging |
|`K` | |Enable keyboard debugging |
|`M` | |Enable mouse debugging |
|`BACKSPACE`| |Clear the saved settings from flash |
|`CAPSLOCK` |`MAGIC_CAPSLOCK_TO_CONTROL` |Treat `Capslock` as `Control` |
| |`MAGIC_UNCAPSLOCK_TO_CONTROL` |Stop treating CapsLock as Control |
|`LCTRL` |`MAGIC_SWAP_CONTROL_CAPSLOCK` |Swap `Control` and `Capslock` |
| |`MAGIC_UNSWAP_CONTROL_CAPSLOCK` |Unswap Left Control and Caps Lock |
| |`MAGIC_SWAP_ALT_GUI` |Swap Alt and GUI on both sides |
| |`MAGIC_UNSWAP_ALT_GUI` |Unswap Left Alt and GUI |
|`LALT` |`MAGIC_SWAP_LALT_LGUI` |Swap Left `Alt` and `GUI`, e.g. for OSX Opt and Cmd |
| |`MAGIC_UNSWAP_LALT_LGUI` |Unswap Left Alt and GUI |
|`RALT` |`MAGIC_SWAP_RALT_RGUI` |Swap Right `Alt` and `GUI` |
| |`MAGIC_UNSWAP_RALT_RGUI` |Unswap Right Alt and GUI |
|`LGUI` |`MAGIC_NO_GUI` |Disable GUI key - e.g. disable Windows key during gaming|
| |`MAGIC_UNNO_GUI` |Enable the GUI key |
|`GRAVE` |`MAGIC_SWAP_GRAVE_ESC` |Swap `\`~` and `ESC` |
| |`MAGIC_UNSWAP_GRAVE_ESC` |Unswap `\`~` and Escape |
|`BACKSLASH`|`MAGIC_SWAP_BACKSLASH_BACKSPACE` |Swap Blackslash and Backspace |
| |`MAGIC_UNSWAP_BACKSLASH_BACKSPACE`|Unswap Backslash and Backspace |
|`N` |`MAGIC_HOST_NKRO` |Force N-Key Rollover (NKRO) on |
| |`MAGIC_UNHOST_NKRO` |Force NKRO off |
| |`MAGIC_TOGGLE_NKRO` |Toggle NKRO on or off |
|`0` |`DF(0)` |Make Layer 0 the default layer at bootup |
|`1` |`DF(1)` |Make Layer 1 the default layer at bootup |
|`2` |`DF(2)` |Make Layer 2 the default layer at bootup |
|`3` |`DF(3)` |Make Layer 3 the default layer at bootup |
|`4` |`DF(4)` |Make Layer 4 the default layer at bootup |
|`5` |`DF(5)` |Make Layer 5 the default layer at bootup |
|`6` |`DF(6)` |Make Layer 6 the default layer at bootup |
|`7` |`DF(7)` |Make Layer 7 the default layer at bootup |
## Bootmagic Configuration
When setting up your keyboard and/or keymap there are a number of `#define`s that control the behavior of Bootmagic. To use these put them in your `config.h`, either at the keyboard or keymap level.
|Define |Default|Description |
|-------|-------|------------|
|`BOOTMAGIC_KEY_SALT`|`KC_SPACE`|The key to hold down to trigger Bootmagic during initialization.|
|`BOOTMAGIC_KEY_SKIP`|`KC_ESC`|The Hotkey to ignore saved eeprom configuration.|
|`BOOTMAGIC_KEY_EEPROM_CLEAR`|`KC_BSPACE`|The hotkey to clear the saved eeprom configuration.|
|`BOOTMAGIC_KEY_BOOTLOADER`|`KC_B`|The hotkey to enter the bootloader.|
|`BOOTMAGIC_KEY_DEBUG_ENABLE`|`KC_D`|The hotkey to enable debug mode.|
|`BOOTMAGIC_KEY_DEBUG_MATRIX`|`KC_X`|The hotkey to enable matrix debugging mode.|
|`BOOTMAGIC_KEY_DEBUG_KEYBOARD`|`KC_K`|The hotkey to enable keyboard debugging mode.|
|`BOOTMAGIC_KEY_DEBUG_MOUSE`|`KC_M`|The hotkey to enable mouse debugging mode.|
|`BOOTMAGIC_KEY_SWAP_CONTROL_CAPSLOCK`|`KC_LCTRL`||
|`BOOTMAGIC_KEY_CAPSLOCK_TO_CONTROL`|`KC_CAPSLOCK`||
|`BOOTMAGIC_KEY_SWAP_LALT_LGUI`|`KC_LALT`||
|`BOOTMAGIC_KEY_SWAP_RALT_RGUI`|`KC_RALT`||
|`BOOTMAGIC_KEY_NO_GUI`|`KC_LGUI`||
|`BOOTMAGIC_KEY_SWAP_GRAVE_ESC`|`KC_GRAVE`||
|`BOOTMAGIC_KEY_SWAP_BACKSLASH_BACKSPACE`|`KC_BSLASH`||
|`BOOTMAGIC_HOST_NKRO`|`KC_N`||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_0`|`KC_0`|Hotkey to set Layer 0 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_1`|`KC_1`|Hotkey to set Layer 1 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_2`|`KC_2`|Hotkey to set Layer 2 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_3`|`KC_3`|Hotkey to set Layer 3 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_4`|`KC_4`|Hotkey to set Layer 4 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_5`|`KC_5`|Hotkey to set Layer 5 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_6`|`KC_6`|Hotkey to set Layer 6 as the default layer|
|`BOOTMAGIC_KEY_DEFAULT_LAYER_7`|`KC_7`|Hotkey to set Layer 7 as the default layer|

@ -0,0 +1,52 @@
# Command (Formerly known as Magic)
Command is a way to change your keyboard's behavior without having to flash or unplug it to use [Bootmagic](feature_bootmagic.md). There is a lot of overlap between this functionality and the [Bootmagic Keycodes](feature_bootmagic.md). Whenever possible we encourage you to use that functionality instead of Command.
## Enabling Command
By default Command is disabled. You can enable it in your `rules.mk` file:
COMMAND_ENABLE = yes
## Usage
To use Command you hold down the key combination defined by `IS_COMMAND`. By default that combination is both shift keys. While holding the key combination press the key corresponding to the command you want.
For example, to write the current QMK version to the QMK Toolbox console, you can press `Left Shift`+`Right Shift`+`V`.
## Configuration
The following values can be defined in `config.h` to control the behavior of Command.
|Define |Default | Description |
|-------|--------|-------------|
|`IS_COMMAND()` |`(keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)))`|Key combination to activate Command|
|`MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS` |`true` |Do layer switching with Function row|
|`MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS` |`true` |Do layer switching with number keys.|
|`MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM`|`false` |Do layer switching with custom keys (`MAGIC_KEY_LAYER0..9` below.)|
|`MAGIC_KEY_HELP1` |`H` |Show help.|
|`MAGIC_KEY_HELP2` |`SLASH` |Show help.|
|`MAGIC_KEY_DEBUG` |`D` |Turn on debug mode.|
|`MAGIC_KEY_DEBUG_MATRIX` |`X` |Turn on matrix debugging.|
|`MAGIC_KEY_DEBUG_KBD` |`K` |Turn on keyboard debugging.|
|`MAGIC_KEY_DEBUG_MOUSE` |`M` |Turn on mouse debugging.|
|`MAGIC_KEY_VERSION` |`V` |Write the QMK version to the console|
|`MAGIC_KEY_STATUS` |`S` |Show the current keyboard status|
|`MAGIC_KEY_CONSOLE` |`C` |Enable the Command Console|
|`MAGIC_KEY_LAYER0_ALT1` |`ESC` |Alternate access to layer 0|
|`MAGIC_KEY_LAYER0_ALT2` |`GRAVE` |Alternate access to layer 0|
|`MAGIC_KEY_LAYER0` |`0` |Change default layer to 0|
|`MAGIC_KEY_LAYER1` |`1` |Change default layer to 1|
|`MAGIC_KEY_LAYER2` |`2` |Change default layer to 2|
|`MAGIC_KEY_LAYER3` |`3` |Change default layer to 3|
|`MAGIC_KEY_LAYER4` |`4` |Change default layer to 4|
|`MAGIC_KEY_LAYER5` |`5` |Change default layer to 5|
|`MAGIC_KEY_LAYER6` |`6` |Change default layer to 6|
|`MAGIC_KEY_LAYER7` |`7` |Change default layer to 7|
|`MAGIC_KEY_LAYER8` |`8` |Change default layer to 8|
|`MAGIC_KEY_LAYER9` |`9` |Change default layer to 9|
|`MAGIC_KEY_BOOTLOADER` |`PAUSE` |Exit keyboard and enter bootloader|
|`MAGIC_KEY_LOCK` |`CAPS` |Lock the keyboard so nothing can be typed|
|`MAGIC_KEY_EEPROM` |`E` |Erase EEPROM settings|
|`MAGIC_KEY_NKRO` |`N` |Toggle NKRO on/off|
|`MAGIC_KEY_SLEEP_LED` |`Z` |Toggle LED when computer is sleeping on/off|

@ -1,163 +0,0 @@
# Common Keymap Shortcuts
Your keymap can include shortcuts to common operations, for example shifted keys. This page documents the functions that are available to you.
People often define custom names using `#define`. For example:
```c
#define FN_CAPS LT(_FL, KC_CAPSLOCK)
#define ALT_TAB LALT(KC_TAB)
```
This will allow you to use `FN_CAPS` and `ALT_TAB` in your `KEYMAP()`, keeping it more readable.
### Limits of these aliases
Currently, the keycodes able to used with these functions are limited to the [Basic Keycodes](keycodes_basic.html), meaning you can't use keycodes like `KC_TILD`, or anything greater than 0xFF. For a full list of the keycodes able to be used see [Basic Keycodes](keycodes_basic.html).
## Switching and toggling layers
These functions allow you to activate layers in various ways.
* `MO(layer)` - momentary switch to *layer*. As soon as you let go of the key, the layer is deactivated and you pop back out to the previous layer.
* `LT(layer, kc)` - momentary switch to *layer* when held, and *kc* when tapped.
* `TG(layer)` - toggles a layer on or off.
* `TO(layer)` - Goes to a layer. This code is special, because it lets you go either up or down the stack -- just goes directly to the layer you want. So while other codes only let you go _up_ the stack (from layer 0 to layer 3, for example), `TO(2)` is going to get you to layer 2, no matter where you activate it from -- even if you're currently on layer 5. This gets activated on keydown (as soon as the key is pressed).
* `TT(layer)` - Layer Tap-Toggle. If you hold the key down, the layer becomes active, and then deactivates when you let go. And if you tap it, the layer simply becomes active (toggles on). It needs 5 taps by default, but you can set it by defining `TAPPING_TOGGLE`, for example, `#define TAPPING_TOGGLE 2` for just two taps.
## Working With Layers
Care must be taken when switching layers, it's possible to lock yourself into a layer with no way to deactivate that layer (without unplugging your keyboard.) We've created some guidelines to help users avoid the most common problems.
### Beginners
If you are just getting started with QMK you will want to keep everything simple. Follow these guidelines when setting up your layers:
* Setup layer 0 as your "base" layer. This is your normal typing layer, and could be whatever layout you want (qwerty, dvorak, colemak, etc.)
* Arrange your layers in a "tree" layout, with layer 0 as the root. Do not try to enter the same layer from more than one other layer.
* Never try to stack a higher numbered layer on top of a lower numbered layer. Doing so is tricky and error prone.
### Intermediate Users
Sometimes you need more than one base layer. For example, if you want to switch between QWERTY and Dvorak, switch between layouts for different countries, or switch your layout for different videogames. Your base layers should always be the lowest numbered layers. When you have multiple base layers you should always treat them as mutually exclusive. When one base layer is on the others are off.
### Advanced Users
Once you have a good feel for how layers work and what you can do, you can get more creative. The rules listed in the beginner section will help you be successful by avoiding some of the tricker details but they can be constraining, especially for ultra-compact keyboard users. Understanding how layers work will allow you to use them in more advanced ways.
Layers stack on top of each other in numerical order. When determining what a keypress does, QMK scans the layers from the top down, stopping when it reaches the first active layer that is not set to `KC_TRNS`. As a result if you activate a layer that is numerically lower than your current layer, and your current layer (or another layer that is active and higher than your target layer) has something other than `KC_TRNS`, that is the key that will be sent, not the key on the layer you just activated. This is the cause of most people's "why doesn't my layer get switched" problem.
## Modifier keys
These functions allow you to combine a mod with a keycode. When pressed the keydown for the mod will be sent first, and then *kc* will be sent. When released the keyup for *kc* will be sent and then the mod will be sent.
* `LSFT(kc)` or `S(kc)` - applies left Shift to *kc* (keycode)
* `RSFT(kc)` - applies right Shift to *kc*
* `LCTL(kc)` - applies left Control to *kc*
* `RCTL(kc)` - applies right Control to *kc*
* `LALT(kc)` - applies left Alt to *kc*
* `RALT(kc)` - applies right Alt to *kc*
* `LGUI(kc)` - applies left GUI (command/win) to *kc*
* `RGUI(kc)` - applies right GUI (command/win) to *kc*
* `HYPR(kc)` - applies Hyper (all modifiers) to *kc*
* `MEH(kc)` - applies Meh (all modifiers except Win/Cmd) to *kc*
* `LCAG(kc)` - applies CtrlAltGui to *kc*
You can also chain these, like this:
LALT(LCTL(KC_DEL)) -- this makes a key that sends Alt, Control, and Delete in a single keypress.
## Shifted Keycodes
The following shortcuts automatically add `LSFT()` to keycodes to get commonly used symbols.
|Name|Description|
|----|-----------|
| KC_TILD | ~ |
| KC_EXLM | ! |
| KC_QUES | ? |
| KC_AT | @ |
| KC_HASH | # |
| KC_DLR | $ |
| KC_PERC | % |
| KC_CIRC | ^ |
| KC_AMPR | & |
| KC_ASTR | * |
| KC_LPRN | ( |
| KC_RPRN | ) |
| KC_UNDS | _ |
| KC_PLUS | + |
| KC_DQUO | " |
| KC_LCBR | { |
| KC_RCBR | } |
| KC_LABK | < |
| KC_RABK | > |
| KC_PIPE | &#x7C; |
| KC_COLN | : |
## Mod Tap
`MT(mod, kc)` - is *mod* (modifier key - MOD_LCTL, MOD_LSFT) when held, and *kc* when tapped. In other words, you can have a key that sends Esc (or the letter O or whatever) when you tap it, but works as a Control key or a Shift key when you hold it down.
These are the values you can use for the `mod` in `MT()` and `OSM()`:
* MOD_LCTL
* MOD_LSFT
* MOD_LALT
* MOD_LGUI
* MOD_RCTL
* MOD_RSFT
* MOD_RALT
* MOD_RGUI
* MOD_HYPR
* MOD_MEH
These can also be combined like `MOD_LCTL | MOD_LSFT` e.g. `MT(MOD_LCTL | MOD_LSFT, KC_ESC)` which would activate Control and Shift when held, and send Escape when tapped. Note however, that you cannot mix right and left side modifiers.
We've added shortcuts to make common modifier/tap (mod-tap) mappings more compact:
* `CTL_T(kc)` - is LCTL when held and *kc* when tapped
* `SFT_T(kc)` - is LSFT when held and *kc* when tapped
* `ALT_T(kc)` - is LALT when held and *kc* when tapped
* `ALGR_T(kc)` - is AltGr when held and *kc* when tapped
* `GUI_T(kc)` - is LGUI when held and *kc* when tapped
* `ALL_T(kc)` - is Hyper (all mods) when held and *kc* when tapped. To read more about what you can do with a Hyper key, see [this blog post by Brett Terpstra](http://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/)
* `LCAG_T(kc)` - is CtrlAltGui when held and *kc* when tapped
* `MEH_T(kc)` - is like Hyper, but not as cool -- does not include the Cmd/Win key, so just sends Alt+Ctrl+Shift.
## One Shot Keys
One shot keys are keys that remain active until the next key is pressed, and then are releasd. This allows you to type keyboard combinations without pressing more than one key at a time.
For example, if you define a key as `OSM(MOD_LSFT)`, you can type a capital A character by first pressing and releasing shift, and then pressing and releasing A. Your computer will see the shift key being held the moment shift is pressed, and it will see the shift key being released immediately after A is released.
One shot keys also work as normal modifiers. If you hold down a one shot key and type other keys, your one shot will be released immediately after you let go of the key.
You can control the behavior of one shot keys by defining these in `config.h`:
```c
#define ONESHOT_TAP_TOGGLE 5 /* Tapping this number of times holds the key until tapped this number of times again. */
#define ONESHOT_TIMEOUT 5000 /* Time (in ms) before the one shot key is released */
```
* `OSM(mod)` - Momentarily hold down *mod*. You must use the `MOD_*` keycodes as shown in [Mod Tap](#mod-tap), not the `KC_*` codes.
* `OSL(layer)` - momentary switch to *layer*.
## Permissive Hold
As of [PR#1359](https://github.com/qmk/qmk_firmware/pull/1359/), there is a new `config.h` option:
```
#define PERMISSIVE_HOLD
```
This makes it easier for fast typists to use dual-function keys. Without this, if you let go of a held key inside the tapping term, it won't register.
Example: (Tapping Term = 200ms)
- SHFT_T(KC_A) Down
- KC_X Down
- KC_X Up
- SHFT_T(KC_A) Up
With defaults, if above is typed within tapping term, this will emit `ax`. With permissive hold, if above is typed within tapping term, this will emit `X` (so, Shift+X).

@ -0,0 +1,63 @@
# Dynamic Macros: Record and Replay Macros in Runtime
QMK supports temporary macros created on the fly. We call these Dynamic Macros. They are defined by the user from the keyboard and are lost when the keyboard is unplugged or otherwise rebooted.
You can store one or two macros and they may have a combined total of 128 keypresses. You can increase this size at the cost of RAM.
To enable them, first add a new element to the `planck_keycodes` enum — `DYNAMIC_MACRO_RANGE`:
```c
enum planck_keycodes {
QWERTY = SAFE_RANGE,
COLEMAK,
DVORAK,
PLOVER,
LOWER,
RAISE,
BACKLIT,
EXT_PLV,
DYNAMIC_MACRO_RANGE,
};
```
It must be the last element because `dynamic_macros.h` will add some more keycodes after it.
Below it, include the `dynamic_macro.h` header:
```c
#include "dynamic_macro.h"`
```
Add the following keys to your keymap:
* `DYN_REC_START1` — start recording the macro 1,
* `DYN_REC_START2` — start recording the macro 2,
* `DYN_MACRO_PLAY1` — replay the macro 1,
* `DYN_MACRO_PLAY2` — replay the macro 2,
* `DYN_REC_STOP` — finish the macro that is currently being recorded.
Add the following code to the very beginning of your `process_record_user()` function:
```c
if (!process_record_dynamic_macro(keycode, record)) {
return false;
}
```
That should be everything necessary. To start recording the macro, press either `DYN_REC_START1` or `DYN_REC_START2`. To finish the recording, press the `DYN_REC_STOP` layer button. To replay the macro, press either `DYN_MACRO_PLAY1` or `DYN_MACRO_PLAY2`.
Note that it's possible to replay a macro as part of a macro. It's ok to replay macro 2 while recording macro 1 and vice versa but never create recursive macros i.e. macro 1 that replays macro 1. If you do so and the keyboard will get unresponsive, unplug the keyboard and plug it again.
For users of the earlier versions of dynamic macros: It is still possible to finish the macro recording using just the layer modifier used to access the dynamic macro keys, without a dedicated `DYN_REC_STOP` key. If you want this behavior back, use the following snippet instead of the one above:
```c
uint16_t macro_kc = (keycode == MO(_DYN) ? DYN_REC_STOP : keycode);
if (!process_record_dynamic_macro(macro_kc, record)) {
return false;
}
```
If the LEDs start blinking during the recording with each keypress, it means there is no more space for the macro in the macro buffer. To fit the macro in, either make the other macro shorter (they share the same buffer) or increase the buffer size by setting the `DYNAMIC_MACRO_SIZE` preprocessor macro (default value: 128; please read the comments for it in the header).
For the details about the internals of the dynamic macros, please read the comments in the `dynamic_macro.h` header.

@ -0,0 +1,17 @@
# Grave Escape
Grave Escape is a feature that allows you to share the grave key (<code>&#96;</code> and `~`) on the same key as Escape. When `KC_GESC` is used it will act as `KC_ESC`, unless Shift or GUI is pressed, in which case it will act as `KC_GRAVE`.
|Key |Aliases |Description |
|---------|-----------|------------------------------------------------------------------|
|`KC_GESC`|`GRAVE_ESC`|Escape when pressed, <code>&#96;</code> when Shift or GUI are held|
There are several possible key combinations this will break, among them Ctrl+Shift+Esc on Windows and Cmd+Opt+Esc on macOS. You can use these options in your `config.h` to work around this:
| Option | Description |
|--------|-------------|
| `GRAVE_ESC_ALT_OVERRIDE` | Always send Escape if Alt is pressed. |
| `GRAVE_ESC_CTRL_OVERRIDE` | Always send Escape if Ctrl is pressed. |
| `GRAVE_ESC_GUI_OVERRIDE` | Always send Escape if GUI is pressed. |
| `GRAVE_ESC_SHIFT_OVERRIDE` | Always send Escape if SHIFT is pressed. |

@ -0,0 +1,11 @@
## Key Lock: Holding Down Keys for You
Sometimes, you need to hold down a specific key for a long period of time. Whether this is while typing in ALL CAPS, or playing a video game that hasn't implemented auto-run, Key Lock is here to help. Key Lock adds a new keycode, `KC_LOCK`, that will hold down the next key you hit for you. The key is released when you hit it again. Here's an example: let's say you need to type in all caps for a few sentences. You hit KC_LOCK, and then shift. Now, shift will be considered held until you hit it again. You can think of key lock as caps lock, but supercharged.
Here's how to use it:
1. Pick a key on your keyboard. This will be the key lock key. Assign it the keycode `KC_LOCK`. This will be a single-action key: you won't be able to use it for anything else.
2. Enable key lock by including `KEY_LOCK_ENABLE = yes` in your Makefile.
3. That's it!
Important: switching layers does not cancel the key lock. Additionally, key lock is only able to hold standard action keys and One Shot modifier keys (for example, if you have your shift defined as `OSM(KC_LSFT)`; see [One Shot Keys](quantum_keycodes.md#one-shot-keys)). This does not include any of the QMK special functions (except One Shot modifiers), or shifted versions of keys such as KC_LPRN. If it's in the [Basic Keycodes](keycodes_basic.md) list, it can be held. If it's not, then it can't be.

@ -1,6 +1,6 @@
# Layouts: Using a keymap with multiple keyboards
# Layouts: Using a Keymap with Multiple Keyboards
The `layouts/` folder contains different physical key layouts that can apply to different keyboards.
The `layouts/` folder contains different physical key layouts that can apply to different keyboards.
```
layouts/
@ -21,7 +21,7 @@ layouts/
| + ...
```
The `layouts/default/` and `layouts/community/` are two examples of layout "repositories" - currently `default` will contain all of the information concerning the layout, and one default keymap named `default_<layout>`, for users to use as a reference. `community` contains all of the community keymaps, with the eventual goal of being split-off into a separate repo for users to clone into `layouts/`. QMK searches through all folders in `layouts/`, so it's possible to have multiple reposistories here.
The `layouts/default/` and `layouts/community/` are two examples of layout "repositories" - currently `default` will contain all of the information concerning the layout, and one default keymap named `default_<layout>`, for users to use as a reference. `community` contains all of the community keymaps, with the eventual goal of being split-off into a separate repo for users to clone into `layouts/`. QMK searches through all folders in `layouts/`, so it's possible to have multiple repositories here.
Each layout folder is named (`[a-z0-9_]`) after the physical aspects of the layout, in the most generic way possible, and contains a `readme.md` with the layout to be defined by the keyboard:
@ -33,12 +33,14 @@ Each layout folder is named (`[a-z0-9_]`) after the physical aspects of the layo
New names should try to stick to the standards set by existing layouts, and can be discussed in the PR/Issue.
## Supporting a layout
## Supporting a Layout
For a keyboard to support a layout, the variable (`[a-z0-9_]`) must be defined in it's `<keyboard>.h`, and match the number of arguments/keys (and preferrably the physical layout):
For a keyboard to support a layout, the variable must be defined in it's `<keyboard>.h`, and match the number of arguments/keys (and preferably the physical layout):
#define LAYOUT_60_ansi KEYMAP_ANSI
The name of the layout must match this regex: `[a-z0-9_]+`
The folder name must be added to the keyboard's `rules.mk`:
LAYOUTS = 60_ansi
@ -49,16 +51,12 @@ The folder name must be added to the keyboard's `rules.mk`:
but the `LAYOUT_<layout>` variable must be defined in `<folder>.h` as well.
## Tips for making layouts keyboard-agnostic
## Tips for Making Layouts Keyboard-Agnostic
Instead of using `#include "planck.h"`, you can use this line to include whatever `<keyboard>.h` (`<folder>.h` should not be included here) file that is being compiled:
#include QMK_KEYBOARD_H
In your config.h, you can also use this variable to include the keyboard's `config.h`:
#include QMK_KEYBOARD_CONFIG_H
If you want to keep some keyboard-specific code, you can use these variables to escape it with an `#ifdef` statement:
* `KEYBOARD_<folder1>_<folder2>`
@ -73,4 +71,4 @@ For example:
#endif
```
Note that the names are lowercase and match the folder/file names for the keyboard/revision exactly.
Note that the names are lowercase and match the folder/file names for the keyboard/revision exactly.

@ -1,4 +1,4 @@
# The Leader key: A new kind of modifier
# The Leader Key: A New Kind of Modifier
If you've ever used Vim, you know what a Leader key is. If not, you're about to discover a wonderful concept. :) Instead of hitting Alt+Shift+W for example (holding down three keys at the same time), what if you could hit a _sequence_ of keys instead? So you'd hit our special modifier (the Leader key), followed by W and then C (just a rapid succession of keys), and something would happen.
@ -34,4 +34,4 @@ void matrix_scan_user(void) {
}
```
As you can see, you have three function. you can use - `SEQ_ONE_KEY` for single-key sequences (Leader followed by just one key), and `SEQ_TWO_KEYS` and `SEQ_THREE_KEYS` for longer sequences. Each of these accepts one or more keycodes as arguments. This is an important point: You can use keycodes from **any layer on your keyboard**. That layer would need to be active for the leader macro to fire, obviously.
As you can see, you have three function. you can use - `SEQ_ONE_KEY` for single-key sequences (Leader followed by just one key), and `SEQ_TWO_KEYS` and `SEQ_THREE_KEYS` for longer sequences. Each of these accepts one or more keycodes as arguments. This is an important point: You can use keycodes from **any layer on your keyboard**. That layer would need to be active for the leader macro to fire, obviously.

@ -0,0 +1,265 @@
# Macros
Macros allow you to send multiple keystrokes when pressing just one key. QMK has a number of ways to define and use macros. These can do anything you want: type common phrases for you, copypasta, repetitive game movements, or even help you code.
{% hint style='danger' %}
**Security Note**: While it is possible to use macros to send passwords, credit card numbers, and other sensitive information it is a supremely bad idea to do so. Anyone who gets a hold of your keyboard will be able to access that information by opening a text editor.
{% endhint %}
## The New Way: `SEND_STRING()` & `process_record_user`
Sometimes you just want a key to type out words or phrases. For the most common situations we've provided `SEND_STRING()`, which will type out your string (i.e. a sequence of characters) for you. All ASCII characters that are easily translated to a keycode are supported (e.g. `\n\t`).
Here is an example `keymap.c` for a two-key keyboard:
```c
enum custom_keycodes {
MY_CUSTOM_MACRO = SAFE_RANGE
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (record->event.pressed) {
switch(keycode) {
case MY_CUSTOM_MACRO:
SEND_STRING("QMK is the best thing ever!"); // this is our macro!
return false;
}
}
return true;
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = {
{MY_CUSTOM_MACRO, KC_ESC}
}
};
```
What happens here is this:
We first define a new custom keycode in the range not occupied by any other keycodes.
Then we use the `process_record_user` function, which is called whenever a key is pressed or released, to check if our custom keycode has been activated.
If yes, we send the string `"QMK is the best thing ever!"` to the computer via the `SEND_STRING` macro (this is a C preprocessor macro, not to be confused with QMK macros).
We return `false` to indicate to the caller that the key press we just processed need not be processed any further.
Finally, we define the keymap so that the first button activates our macro and the second button is just an escape button.
You might want to add more than one macro.
You can do that by adding another keycode and adding another case to the switch statement, like so:
```c
enum custom_keycodes {
MY_CUSTOM_MACRO = SAFE_RANGE,
MY_OTHER_MACRO
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (record->event.pressed) {
switch(keycode) {
case MY_CUSTOM_MACRO:
SEND_STRING("QMK is the best thing ever!");
return false;
case MY_OTHER_MACRO:
SEND_STRING(SS_LCTRL("ac")); // selects all and copies
return false;
}
}
return true;
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = {
{MY_CUSTOM_MACRO, MY_OTHER_MACRO}
}
};
```
### TAP, DOWN and UP
You may want to use keys in your macros that you can't write down, such as `Ctrl` or `Home`.
You can send arbitrary keycodes by wrapping them in:
* `SS_TAP()` presses and releases a key.
* `SS_DOWN()` presses (but does not release) a key.
* `SS_UP()` releases a key.
For example:
SEND_STRING(SS_TAP(X_HOME));
Would tap `KC_HOME` - note how the prefix is now `X_`, and not `KC_`. You can also combine this with other strings, like this:
SEND_STRING("VE"SS_TAP(X_HOME)"LO");
Which would send "VE" followed by a `KC_HOME` tap, and "LO" (spelling "LOVE" if on a newline).
There's also a couple of mod shortcuts you can use:
* `SS_LCTRL(string)`
* `SS_LGUI(string)`
* `SS_LALT(string)`
* `SS_LSFT(string)`
* `SS_RALT(string)`
These press the respective modifier, send the supplied string and then release the modifier.
They can be used like this:
SEND_STRING(SS_LCTRL("a"));
Which would send LCTRL+a (LCTRL down, a, LCTRL up) - notice that they take strings (eg `"k"`), and not the `X_K` keycodes.
### Alternative Keymaps
By default, it assumes a US keymap with a QWERTY layout; if you want to change that (e.g. if your OS uses software Colemak), include this somewhere in your keymap:
#include <sendstring_colemak.h>
### Strings in Memory
If for some reason you're manipulating strings and need to print out something you just generated (instead of being a literal, constant string), you can use `send_string()`, like this:
```c
char my_str[4] = "ok.";
send_string(my_str);
```
The shortcuts defined above won't work with `send_string()`, but you can separate things out to different lines if needed:
```c
char my_str[4] = "ok.";
SEND_STRING("I said: ");
send_string(my_str);
SEND_STRING(".."SS_TAP(X_END));
```
## The Old Way: `MACRO()` & `action_get_macro`
{% hint style='info' %}
This is inherited from TMK, and hasn't been updated - it's recommend that you use `SEND_STRING` and `process_record_user` instead.
{% endhint %}
By default QMK assumes you don't have any macros. To define your macros you create an `action_get_macro()` function. For example:
```c
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
if (record->event.pressed) {
switch(id) {
case 0:
return MACRO(D(LSFT), T(H), U(LSFT), T(I), D(LSFT), T(1), U(LSFT), END);
case 1:
return MACRO(D(LSFT), T(B), U(LSFT), T(Y), T(E), D(LSFT), T(1), U(LSFT), END);
}
}
return MACRO_NONE;
};
```
This defines two macros which will be run when the key they are assigned to is pressed. If instead you'd like them to run when the key is released you can change the if statement:
if (!record->event.pressed) {
### Macro Commands
A macro can include the following commands:
* I() change interval of stroke in milliseconds.
* D() press key.
* U() release key.
* T() type key(press and release).
* W() wait (milliseconds).
* END end mark.
### Mapping a Macro to a Key
Use the `M()` function within your `KEYMAP()` to call a macro. For example, here is the keymap for a 2-key keyboard:
```c
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = KEYMAP(
M(0), M(1)
),
};
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
if (record->event.pressed) {
switch(id) {
case 0:
return MACRO(D(LSFT), T(H), U(LSFT), T(I), D(LSFT), T(1), U(LSFT), END);
case 1:
return MACRO(D(LSFT), T(B), U(LSFT), T(Y), T(E), D(LSFT), T(1), U(LSFT), END);
}
}
return MACRO_NONE;
};
```
When you press the key on the left it will type "Hi!" and when you press the key on the right it will type "Bye!".
### Naming Your Macros
If you have a bunch of macros you want to refer to from your keymap while keeping the keymap easily readable you can name them using `#define` at the top of your file.
```c
#define M_HI M(0)
#define M_BYE M(1)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = KEYMAP(
M_HI, M_BYE
),
};
```
## Advanced Macro Functions
There are some functions you may find useful in macro-writing. Keep in mind that while you can write some fairly advanced code within a macro if your functionality gets too complex you may want to define a custom keycode instead. Macros are meant to be simple.
### `record->event.pressed`
This is a boolean value that can be tested to see if the switch is being pressed or released. An example of this is
```c
if (record->event.pressed) {
// on keydown
} else {
// on keyup
}
```
### `register_code(<kc>);`
This sends the `<kc>` keydown event to the computer. Some examples would be `KC_ESC`, `KC_C`, `KC_4`, and even modifiers such as `KC_LSFT` and `KC_LGUI`.
### `unregister_code(<kc>);`
Parallel to `register_code` function, this sends the `<kc>` keyup event to the computer. If you don't use this, the key will be held down until it's sent.
### `clear_keyboard();`
This will clear all mods and keys currently pressed.
### `clear_mods();`
This will clear all mods currently pressed.
### `clear_keyboard_but_mods();`
This will clear all keys besides the mods currently pressed.
## Advanced Example: Single-Key Copy/Paste
This example defines a macro which sends `Ctrl-C` when pressed down, and `Ctrl-V` when released.
```c
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
switch(id) {
case 0: {
if (record->event.pressed) {
return MACRO( D(LCTL), T(C), U(LCTL), END );
} else {
return MACRO( D(LCTL), T(V), U(LCTL), END );
}
break;
}
}
return MACRO_NONE;
};
```

@ -0,0 +1,81 @@
# Mousekeys
Mousekeys is a feature that allows you to emulate a mouse using your keyboard. You can move the pointer around, click up to 5 buttons, and even scroll in all 4 directions. QMK uses the same algorithm as the X Window System MouseKeysAccel feature. You can read more about it [on Wikipedia](https://en.wikipedia.org/wiki/Mouse_keys).
## Adding Mousekeys to a Keymap
There are two steps to adding Mousekeys support to your keyboard. You must enable support in the `rules.mk` file and you must map mouse actions to keys on your keyboard.
### Adding Mousekeys Support in the `rules.mk`
To add support for Mousekeys you simply need to add a single line to your keymap's `rules.mk`:
```
MOUSEKEY_ENABLE = yes
```
You can see an example here: https://github.com/qmk/qmk_firmware/blob/master/keyboards/clueboard/66/keymaps/mouse_keys/rules.mk
### Mapping Mouse Actions to Keyboard Keys
You can use these keycodes within your keymap to map button presses to mouse actions:
|Key |Aliases |Description |
|----------------|---------|---------------------------|
|`KC_MS_UP` |`KC_MS_U`|Mouse Cursor Up |
|`KC_MS_DOWN` |`KC_MS_D`|Mouse Cursor Down |
|`KC_MS_LEFT` |`KC_MS_L`|Mouse Cursor Left |
|`KC_MS_RIGHT` |`KC_MS_R`|Mouse Cursor Right |
|`KC_MS_BTN1` |`KC_BTN1`|Mouse Button 1 |
|`KC_MS_BTN2` |`KC_BTN2`|Mouse Button 2 |
|`KC_MS_BTN3` |`KC_BTN3`|Mouse Button 3 |
|`KC_MS_BTN4` |`KC_BTN4`|Mouse Button 4 |
|`KC_MS_BTN5` |`KC_BTN5`|Mouse Button 5 |
|`KC_MS_WH_UP` |`KC_WH_U`|Mouse Wheel Up |
|`KC_MS_WH_DOWN` |`KC_WH_D`|Mouse Wheel Down |
|`KC_MS_WH_LEFT` |`KC_WH_L`|Mouse Wheel Left |
|`KC_MS_WH_RIGHT`|`KC_WH_R`|Mouse Wheel Right |
|`KC_MS_ACCEL0` |`KC_ACL0`|Set mouse acceleration to 0|
|`KC_MS_ACCEL1` |`KC_ACL1`|Set mouse acceleration to 1|
|`KC_MS_ACCEL2` |`KC_ACL2`|Set mouse acceleration to 2|
You can see an example in the `_ML` here: https://github.com/qmk/qmk_firmware/blob/master/keyboards/clueboard/66/keymaps/mouse_keys/keymap.c#L46
## Configuring the Behavior of Mousekeys
The default speed for controlling the mouse with the keyboard is intentionally slow. You can adjust these parameters by adding these settings to your keymap's `config.h` file. All times are specified in milliseconds (ms).
```
#define MOUSEKEY_DELAY 300
#define MOUSEKEY_INTERVAL 50
#define MOUSEKEY_MAX_SPEED 10
#define MOUSEKEY_TIME_TO_MAX 20
#define MOUSEKEY_WHEEL_MAX_SPEED 8
#define MOUSEKEY_WHEEL_TIME_TO_MAX 40
```
### `MOUSEKEY_DELAY`
When one of the mouse movement buttons is pressed this setting is used to define the delay between that button press and the mouse cursor moving. Some people find that small movements are impossible if this setting is too low, while settings that are too high feel sluggish.
### `MOUSEKEY_INTERVAL`
When a movement key is held down this specifies how long to wait between each movement report. Lower settings will translate into an effectively higher mouse speed.
### `MOUSEKEY_MAX_SPEED`
As a movement key is held down the speed of the mouse cursor will increase until it reaches `MOUSEKEY_MAX_SPEED`.
### `MOUSEKEY_TIME_TO_MAX`
How long you want to hold down a movement key for until `MOUSEKEY_MAX_SPEED` is reached. This controls how quickly your cursor will accelerate.
### `MOUSEKEY_WHEEL_MAX_SPEED`
The top speed for scrolling movements.
### `MOUSEKEY_WHEEL_TIME_TO_MAX`
How long you want to hold down a scroll key for until `MOUSEKEY_WHEEL_MAX_SPEED` is reached. This controls how quickly your scrolling will accelerate.

@ -1,6 +1,6 @@
## Pointing Device
Pointing Device is a generic name for a feature intended to be generic: moving the system pointer arround. There are certainly other options for it - like mousekeys - but this aims to be easily modifiable and lightweight. You can implement custom keys to control functionality, or you can gather information from other peripherals and insert it directly here - let QMK handle the processing for you.
Pointing Device is a generic name for a feature intended to be generic: moving the system pointer around. There are certainly other options for it - like mousekeys - but this aims to be easily modifiable and lightweight. You can implement custom keys to control functionality, or you can gather information from other peripherals and insert it directly here - let QMK handle the processing for you.
To enable Pointing Device, uncomment the following line in your rules.mk:
@ -44,4 +44,4 @@ case MS_SPECIAL:
break;
```
Recall that the mouse report is set to zero (except the buttons) whenever it is sent, so the scrolling would only occur once in each case.
Recall that the mouse report is set to zero (except the buttons) whenever it is sent, so the scrolling would only occur once in each case.

@ -6,7 +6,7 @@ To hook up a Trackpoint, you need to obtain a Trackpoint module (i.e. harvest fr
There are three available modes for hooking up PS/2 devices: USART (best), interrupts (better) or busywait (not recommended).
### Busywait version
### Busywait Version
Note: This is not recommended, you may encounter jerky movement or unsent inputs. Please use interrupt or USART version if possible.
@ -32,7 +32,7 @@ In your keyboard config.h:
#endif
```
### Interrupt version
### Interrupt Version
The following example uses D2 for clock and D5 for data. You can use any INT or PCINT pin for clock, and any pin for data.
@ -70,7 +70,7 @@ In your keyboard config.h:
#endif
```
### USART version
### USART Version
To use USART on the ATMega32u4, you have to use PD5 for clock and PD2 for data. If one of those are unavailable, you need to use interrupt version.
@ -129,13 +129,13 @@ In your keyboard config.h:
### Additional Settings
#### PS/2 mouse features
#### PS/2 Mouse Features
These enable settings supported by the PS/2 mouse protocol: http://www.computer-engineering.org/ps2mouse/
```
/* Use remote mode instead of the default stream mode (see link) */
#define PS2_MOUSE_USE_REMOTE_MODE
#define PS2_MOUSE_USE_REMOTE_MODE
/* Enable the scrollwheel or scroll gesture on your mouse or touchpad */
#define PS2_MOUSE_ENABLE_SCROLLING
@ -170,7 +170,7 @@ void ps2_mouse_set_resolution(ps2_mouse_resolution_t resolution);
void ps2_mouse_set_sample_rate(ps2_mouse_sample_rate_t sample_rate);
```
#### Fine control
#### Fine Control
Use the following defines to change the sensitivity and speed of the mouse.
Note: you can also use `ps2_mouse_set_resolution` for the same effect (not supported on most touchpads).
@ -181,7 +181,7 @@ Note: you can also use `ps2_mouse_set_resolution` for the same effect (not suppo
#define PS2_MOUSE_V_MULTIPLIER 1
```
#### Scroll button
#### Scroll Button
If you're using a trackpoint, you will likely want to be able to use it for scrolling.
Its possible to enable a "scroll button/s" that when pressed will cause the mouse to scroll instead of moving.
@ -227,7 +227,7 @@ Fine control over the scrolling is supported with the following defines:
#define PS2_MOUSE_SCROLL_DIVISOR_V 2
```
#### Invert mouse and scroll axes
#### Invert Mouse and Scroll Axes
To invert the X and Y axes you can put:
@ -247,7 +247,7 @@ To reverse the scroll axes you can put:
into config.h.
#### Debug settings
#### Debug Settings
To debug the mouse, add `debug_mouse = true` or enable via bootmagic.

@ -41,6 +41,9 @@ You can change the behavior of the RGB Lighting by setting these configuration v
| `RGBLIGHT_HUE_STEP` | 10 | How many hues you want to have available. |
| `RGBLIGHT_SAT_STEP` | 17 | How many steps of saturation you'd like. |
| `RGBLIGHT_VAL_STEP` | 17 | The number of levels of brightness you want. |
| `RGBLIGHT_LIMIT_VAL` | 255 | Limit the val of HSV to limit the maximum brightness simply. |
| `RGBLIGHT_SLEEP` | | `#define` this will shut off the lights when the host goes to sleep |
### Animations
@ -49,8 +52,10 @@ If you have `#define RGBLIGHT_ANIMATIONS` in your `config.h` you will have a num
| Option | Default Value | Description |
|--------|---------------|-------------|
| `RGBLIGHT_ANIMATIONS` | | `#define` this to enable animation modes. |
| `RGBLIGHT_EFFECT_SNAKE_LENGTH` | 4 | The number of LEDs to light up for the "snake" mode. |
| `RGBLIGHT_EFFECT_KNIGHT_LENGTH` | 3 | The number of LEDs to light up for the "knight" mode. |
| `RGBLIGHT_EFFECT_BREATHE_CENTER` | 1.85 | Used to calculate the curve for the breathing animation. Valid values 1.0-2.7. |
| `RGBLIGHT_EFFECT_BREATHE_MAX` | 255 | The maximum brightness for the breathing mode. Valid values 1-255. |
| `RGBLIGHT_EFFECT_SNAKE_LENGTH` | 4 | The number of LEDs to light up for the "snake" animation. |
| `RGBLIGHT_EFFECT_KNIGHT_LENGTH` | 3 | The number of LEDs to light up for the "knight" animation. |
| `RGBLIGHT_EFFECT_KNIGHT_OFFSET` | 0 | Start the knight animation this many LEDs from the start of the strip. |
| `RGBLIGHT_EFFECT_KNIGHT_LED_NUM` | RGBLED_NUM | The number of LEDs to have the "knight" animation travel. |
| `RGBLIGHT_EFFECT_CHRISTMAS_INTERVAL` | 1000 | How long to wait between light changes for the "christmas" animation. Specified in ms. |
@ -78,28 +83,46 @@ const uint8_t RGBLED_KNIGHT_INTERVALS[] PROGMEM = {127, 63, 31};
const uint16_t RGBLED_GRADIENT_RANGES[] PROGMEM = {360, 240, 180, 120, 90};
```
### LED Control
Look in `rgblights.h` for all available functions, but if you want to control all or some LEDs your goto functions are:
```c
rgblight_disable(); // turn all lights off
rgblight_enable(); // turn lights on, based on their previous state (stored in EEPROM)
rgblight_setrgb(r, g, b); // where r/g/b is a number from 0..255. Turns all the LEDs to this color
rgblight_sethsv(h, s, v); // HSV color control - h is a value from 0..360 and s/v is a value from 0..255
rgblight_setrgb_at(r,g,b, LED); // control a single LED. 0 <= LED < RGBLED_NUM
rgblight_sethsv_at(h,s,v, LED); // control a single LED. 0 <= LED < RGBLED_NUM
```
You can find a list of predefined colors at [`quantum/rgblight_list.h`](https://github.com/qmk/qmk_firmware/blob/master/quantum/rgblight_list.h). Free to add to this list!
## RGB Lighting Keycodes
These control the RGB Lighting functionality.
| Long Name | Short Name | Description |
|-----------|------------|-------------|
||`RGB_TOG`|toggle on/off|
||`RGB_MOD`|cycle through modes|
||`RGB_HUI`|hue increase|
||`RGB_HUD`|hue decrease|
||`RGB_SAI`|saturation increase|
||`RGB_SAD`|saturation decrease|
||`RGB_VAI`|value (brightness) increase|
||`RGB_VAD`|value (brightness) decrease|
|`RGB_MODE_PLAIN`|`RGB_M_P `| Switch to the static no animation mode |
|`RGB_MODE_BREATHE`|`RGB_M_B`| Switch to the breathing mode |
|`RGB_MODE_RAINBOW`|`RGB_M_R`| Switch to the rainbow mode ||
|`RGB_MODE_SWIRL`|`RGB_M_SW`| Switch to the swirl mode |
|`RGB_MODE_SNAKE`|`RGB_M_SN`| Switch to the snake mode |
|`RGB_MODE_KNIGHT`|`RGB_M_K`| Switch to the knight animation |
|`RGB_MODE_XMAS`|`RGB_M_X`| Switch to the Christmas animation |
|`RGB_MODE_GRADIENT`|`RGB_M_G`| Switch to the static gradient mode |
|Key |Aliases |Description |
|-------------------|----------|--------------------------------------------------------------------|
|`RGB_TOG` | |Toggle RGB lighting on or off |
|`RGB_MODE_FORWARD` |`RGB_MOD` |Cycle through modes, reverse direction when Shift is held |
|`RGB_MODE_REVERSE` |`RGB_RMOD`|Cycle through modes in reverse, forward direction when Shift is held|
|`RGB_HUI` | |Increase hue |
|`RGB_HUD` | |Decrease hue |
|`RGB_SAI` | |Increase saturation |
|`RGB_SAD` | |Decrease saturation |
|`RGB_VAI` | |Increase value (brightness) |
|`RGB_VAD` | |Decrease value (brightness) |
|`RGB_MODE_PLAIN` |`RGB_M_P `|Static (no animation) mode |
|`RGB_MODE_BREATHE` |`RGB_M_B` |Breathing animation mode |
|`RGB_MODE_RAINBOW` |`RGB_M_R` |Rainbow animation mode |
|`RGB_MODE_SWIRL` |`RGB_M_SW`|Swirl animation mode |
|`RGB_MODE_SNAKE` |`RGB_M_SN`|Snake animation mode |
|`RGB_MODE_KNIGHT` |`RGB_M_K` |"Knight Rider" animation mode |
|`RGB_MODE_XMAS` |`RGB_M_X` |Christmas animation mode |
|`RGB_MODE_GRADIENT`|`RGB_M_G` |Static gradient animation mode |
note: for backwards compatibility, `RGB_SMOD` is an alias for `RGB_MOD`.
## Hardware Modification

@ -0,0 +1,24 @@
## Space Cadet Shift: The Future, Built In
Steve Losh [described](http://stevelosh.com/blog/2012/10/a-modern-space-cadet/) the Space Cadet Shift quite well. Essentially, you hit the left Shift on its own, and you get an opening parenthesis; hit the right Shift on its own, and you get the closing one. When hit with other keys, the Shift key keeps working as it always does. Yes, it's as cool as it sounds.
To use it, use `KC_LSPO` (Left Shift, Parenthesis Open) for your left Shift on your keymap, and `KC_RSPC` (Right Shift, Parenthesis Close) for your right Shift.
It's defaulted to work on US keyboards, but if your layout uses different keys for parenthesis, you can define those in your `config.h` like this:
#define LSPO_KEY KC_9
#define RSPC_KEY KC_0
You can also choose between different rollover behaviors of the shift keys by defining:
#define DISABLE_SPACE_CADET_ROLLOVER
in your `config.h`. Disabling rollover allows you to use the opposite shift key to cancel the space cadet state in the event of an erroneous press instead of emitting a pair of parentheses when the keys are released.
The only other thing you're going to want to do is create a `Makefile` in your keymap directory and set the following:
```
COMMAND_ENABLE = no # Commands for debug and configuration
```
This is just to keep the keyboard from going into command mode when you hold both Shift keys at the same time.

@ -0,0 +1,26 @@
## Space Cadet Shift Enter: The future, built in
Based on the Space Cadet Shift by Steve Losh [described](http://stevelosh.com/blog/2012/10/a-modern-space-cadet/)
Essentially, you hit the Shift on its own, and it acts as the enter key. When hit with other keys, the Shift key keeps working as it always does. Yes, it's as cool as it sounds. This solution works better than using a macro since the timers defined in quantum allow us to tell when another key is pressed, rather than just having a janky timer than results in accidental endlines.
To use it, use `KC_SFTENT` (Shift, Enter) for any Shift on your keymap.
It's defaulted to work on US keyboards, but if you'd like to use a different key for Enter, you can define those in your `config.h` like this:
#define SFTENT_KEY KC_ENT
The only other thing you're going to want to do is create a `rules.mk` in your keymap directory and set the following:
```
COMMAND_ENABLE = no # Commands for debug and configuration
```
This is just to keep the keyboard from going into command mode when you hold both Shift keys at the same time.
PLEASE NOTE: this feature uses the same timers as the Space Cadet Shift feature, so using them in tandem may produce unwanted results.

@ -0,0 +1,132 @@
# Stenography in QMK
[Stenography](https://en.wikipedia.org/wiki/Stenotype) is a method of writing most often used by court reports, closed-captioning, and real-time transcription for the deaf. In stenography words are chorded syllable by syllable with a mixture of spelling, phonetic, and shortcut (briefs) strokes. Professional stenographers can reach 200-300 WPM without any of the strain usually found in standard typing and with far fewer errors (>99.9% accuracy).
The [Open Steno Project](http://www.openstenoproject.org/) has built an open-source program called Plover that provides real-time translation of steno strokes into words and commands. It has an established dictionary and supports
## Plover with QWERTY Keyboard
Plover can work with any standard QWERTY keyboard, although it is more efficient if the keyboard supports NKRO (n-key rollover) to allow Plover to see all the pressed keys at once. An example keymap for Plover can be found in `planck/keymaps/default`. Switching to the `PLOVER` layer adjusts the position of the keyboard to support the number bar.
To use Plover with QMK just enable NKRO and optionally adjust your layout if you have anything other than a standard layout. You may also want to purchase some steno-friendly keycaps to make it easier to hit multiple keys.
## Plover with Steno Protocol
Plover also understands the language of several steno machines. QMK can speak a couple of these languages, TX Bolt and GeminiPR. An example layout can be found in `planck/keymaps/steno`.
When QMK speaks to Plover over a steno protocol Plover will not use the keyboard as input. This means that you can switch back and forth between a standard keyboard and your steno keyboard, or even switch layers from Plover to standard and back without needing to activate/deactivate Plover.
In this mode Plover expects to speak with a steno machine over a serial port so QMK will present itself to the operating system as a virtual serial port in addition to a keyboard. By default QMK will speak the TX Bolt protocol but can be switched to GeminiPR; the last protocol used is stored in non-volatile memory so QMK will use the same protocol on restart.
> Note: Due to hardware limitations you may not be able to run both a virtual serial port and mouse emulation at the same time.
### TX Bolt
TX Bolt communicates the status of 24 keys over a very simple protocol in variable-sized (1-5 byte) packets.
### GeminiPR
GeminiPR encodes 42 keys into a 6-byte packet. While TX Bolt contains everything that is necessary for standard stenography, GeminiPR opens up many more options, including supporting non-English theories.
## Configuring QMK for Steno
Firstly, enable steno in your keymap's Makefile. You may also need disable mousekeys, extra keys, or another USB endpoint to prevent conflicts. The builtin USB stack for some processors only supports a certain number of USB endpoints and the virtual serial port needed for steno fills 3 of them.
```Makefile
STENO_ENABLE = yes
MOUSEKEY_ENABLE = no
```
In your keymap create a new layer for Plover. You will need to include `keymap_steno.h`. See `planck/keymaps/steno/keymap.c` for an example. Remember to create a key to switch to the layer as well as a key for exiting the layer. If you would like to switch modes on the fly you can use the keycodes `QK_STENO_BOLT` and `QK_STENO_GEMINI`. If you only want to use one of the protocols you may set it up in your initialization function:
```C
void matrix_init_user() {
steno_set_mode(STENO_MODE_GEMINI); // or STENO_MODE_BOLT
}
```
Once you have your keyboard flashed launch Plover. Click the 'Configure...' button. In the 'Machine' tab select the Stenotype Machine that corresponds to your desired protocol. Click the 'Configure...' button on this tab and enter the serial port or click 'Scan'. Baud rate is fine at 9600 (although you should be able to set as high as 115200 with no issues). Use the default settings for everything else (Data Bits: 8, Stop Bits: 1, Parity: N, no flow control).
On the display tab click 'Open stroke display'. With Plover disabled you should be able to hit keys on your keyboard and see them show up in the stroke display window. Use this to make sure you have set up your keymap correctly. You are now ready to steno!
## Learning Stenography
* [Learn Plover!](https://sites.google.com/site/ploverdoc/)
* [QWERTY Steno](http://qwertysteno.com/Home/)
* [Steno Jig](https://joshuagrams.github.io/steno-jig/)
* More resources at the Plover [Learning Stenography](https://github.com/openstenoproject/plover/wiki/Learning-Stenography) wiki
## Interfacing with the code
The steno code has three interceptible hooks. If you define these functions, they will be called at certain points in processing; if they return true, processing continues, otherwise it's assumed you handled things.
```C
bool send_steno_chord_user(steno_mode_t mode, uint8_t chord[6]);
```
This function is called when a chord is about to be sent. Mode will be one of `STENO_MODE_BOLT` or `STENO_MODE_GEMINI`. This represents the actual chord that would be sent via whichever protocol. You can modify the chord provided to alter what gets sent. Remember to return true if you want the regular sending process to happen.
```C
bool process_steno_user(uint16_t keycode, keyrecord_t *record) { return true; }
```
This function is called when a keypress has come in, before it is processed. The keycode should be one of `QK_STENO_BOLT`, `QK_STENO_GEMINI`, or one of the `STN_*` key values.
```C
bool postprocess_steno_user(uint16_t keycode, keyrecord_t *record, steno_mode_t mode, uint8_t chord[6], int8_t pressed);
```
This function is called after a key has been processed, but before any decision about whether or not to send a chord. If `IS_PRESSED(record->event)` is false, and `pressed` is 0 or 1, the chord will be sent shortly, but has not yet been sent. This is where to put hooks for things like, say, live displays of steno chords or keys.
## Keycode Reference
As defined in `keymap_steno.h`.
> Note: TX Bolt does not support the full set of keys. The TX Bolt implementation in QMK will map the GeminiPR keys to the nearest TX Bolt key so that one key map will work for both.
|GeminiPR|TX Bolt|Steno Key|
|--------|-------|-----------|
|`STN_N1`|`STN_NUM`|Number bar #1|
|`STN_N2`|`STN_NUM`|Number bar #2|
|`STN_N3`|`STN_NUM`|Number bar #3|
|`STN_N4`|`STN_NUM`|Number bar #4|
|`STN_N5`|`STN_NUM`|Number bar #5|
|`STN_N6`|`STN_NUM`|Number bar #6|
|`STN_N7`|`STN_NUM`|Number bar #7|
|`STN_N8`|`STN_NUM`|Number bar #8|
|`STN_N9`|`STN_NUM`|Number bar #9|
|`STN_NA`|`STN_NUM`|Number bar #A|
|`STN_NB`|`STN_NUM`|Number bar #B|
|`STN_NC`|`STN_NUM`|Number bar #C|
|`STN_S1`|`STN_SL`| `S-` upper|
|`STN_S2`|`STN_SL`| `S-` lower|
|`STN_TL`|`STN_TL`| `T-`|
|`STN_KL`|`STN_KL`| `K-`|
|`STN_PL`|`STN_PL`| `P-`|
|`STN_WL`|`STN_WL`| `W-`|
|`STN_HL`|`STN_HL`| `H-`|
|`STN_RL`|`STN_RL`| `R-`|
|`STN_A`|`STN_A`| `A` vowel|
|`STN_O`|`STN_O`| `O` vowel|
|`STN_ST1`|`STN_STR`| `*` upper-left |
|`STN_ST2`|`STN_STR`| `*` lower-left|
|`STN_ST3`|`STN_STR`| `*` upper-right|
|`STN_ST4`|`STN_STR`| `*` lower-right|
|`STN_E`|`STN_E`| `E` vowel|
|`STN_U`|`STN_U`| `U` vowel|
|`STN_FR`|`STN_FR`| `-F`|
|`STN_PR`|`STN_PR`| `-P`|
|`STN_RR`|`STN_RR`| `-R`|
|`STN_BR`|`STN_BR`| `-B`|
|`STN_LR`|`STN_LR`| `-L`|
|`STN_GR`|`STN_GR`| `-G`|
|`STN_TR`|`STN_TR`| `-T`|
|`STN_SR`|`STN_SR`| `-S`|
|`STN_DR`|`STN_DR`| `-D`|
|`STN_ZR`|`STN_ZR`| `-Z`|
|`STN_FN`|| (GeminiPR only)|
|`STN_RES1`||(GeminiPR only)|
|`STN_RES2`||(GeminiPR only)|
|`STN_PWR`||(GeminiPR only)|

@ -0,0 +1,30 @@
# Swap-Hands Action
The swap-hands action allows support for one-handed typing without requiring a separate layer. Set `SWAP_HANDS_ENABLE` in the Makefile and define a `hand_swap_config` entry in your keymap. Now whenever the `ACTION_SWAP_HANDS` command key is pressed the keyboard is mirrored. For instance, to type "Hello, World" on QWERTY you would type `^Ge^s^s^w^c W^wr^sd`
## Configuration
The configuration table is a simple 2-dimensional array to map from column/row to new column/row. Example `hand_swap_config` for Planck:
```C
const keypos_t hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
{{11, 0}, {10, 0}, {9, 0}, {8, 0}, {7, 0}, {6, 0}, {5, 0}, {4, 0}, {3, 0}, {2, 0}, {1, 0}, {0, 0}},
{{11, 1}, {10, 1}, {9, 1}, {8, 1}, {7, 1}, {6, 1}, {5, 1}, {4, 1}, {3, 1}, {2, 1}, {1, 1}, {0, 1}},
{{11, 2}, {10, 2}, {9, 2}, {8, 2}, {7, 2}, {6, 2}, {5, 2}, {4, 2}, {3, 2}, {2, 2}, {1, 2}, {0, 2}},
{{11, 3}, {10, 3}, {9, 3}, {8, 3}, {7, 3}, {6, 3}, {5, 3}, {4, 3}, {3, 3}, {2, 3}, {1, 3}, {0, 3}},
};
```
Note that the array indices are reversed same as the matrix and the values are of type `keypos_t` which is `{col, row}` and all values are zero-based. In the example above, `hand_swap_config[2][4]` (third row, fifth column) would return `{7, 2}` (third row, eighth column). Yes, this is confusing.
## Swap Keycodes
|Key |Description |
|-----------|-------------------------------------------------------------------------|
|`SH_T(key)`|Sends `key` with a tap; momentary swap when held. |
|`SW_ON` |Turns on swapping and leaves it on. |
|`SW_OFF` |Turn off swapping and leaves it off. Good for returning to a known state.|
|`SW_MON` |Swaps hands when pressed, returns to normal when released (momentary). |
|`SW_MOFF` |Momentarily turns off swap. |
|`SH_TG` |Toggles swap on and off with every key press. |
|`SH_TT` |Toggles with a tap; momentary when held. |

@ -0,0 +1,250 @@
# Tap Dance: A Single Key Can Do 3, 5, or 100 Different Things
<!-- FIXME: Break this up into multiple sections -->
Hit the semicolon key once, send a semicolon. Hit it twice, rapidly -- send a colon. Hit it three times, and your keyboard's LEDs do a wild dance. That's just one example of what Tap Dance can do. It's one of the nicest community-contributed features in the firmware, conceived and created by [algernon](https://github.com/algernon) in [#451](https://github.com/qmk/qmk_firmware/pull/451). Here's how algernon describes the feature:
With this feature one can specify keys that behave differently, based on the amount of times they have been tapped, and when interrupted, they get handled before the interrupter.
To make it clear how this is different from `ACTION_FUNCTION_TAP`, lets explore a certain setup! We want one key to send `Space` on single tap, but `Enter` on double-tap.
With `ACTION_FUNCTION_TAP`, it is quite a rain-dance to set this up, and has the problem that when the sequence is interrupted, the interrupting key will be send first. Thus, `SPC a` will result in `a SPC` being sent, if they are typed within `TAPPING_TERM`. With the tap dance feature, that'll come out as `SPC a`, correctly.
The implementation hooks into two parts of the system, to achieve this: into `process_record_quantum()`, and the matrix scan. We need the latter to be able to time out a tap sequence even when a key is not being pressed, so `SPC` alone will time out and register after `TAPPING_TERM` time.
But lets start with how to use it, first!
First, you will need `TAP_DANCE_ENABLE=yes` in your `rules.mk`, because the feature is disabled by default. This adds a little less than 1k to the firmware size. Next, you will want to define some tap-dance keys, which is easiest to do with the `TD()` macro, that - similar to `F()`, takes a number, which will later be used as an index into the `tap_dance_actions` array.
This array specifies what actions shall be taken when a tap-dance key is in action. Currently, there are three possible options:
* `ACTION_TAP_DANCE_DOUBLE(kc1, kc2)`: Sends the `kc1` keycode when tapped once, `kc2` otherwise. When the key is held, the appropriate keycode is registered: `kc1` when pressed and held, `kc2` when tapped once, then pressed and held.
* `ACTION_TAP_DANCE_FN(fn)`: Calls the specified function - defined in the user keymap - with the final tap count of the tap dance action.
* `ACTION_TAP_DANCE_FN_ADVANCED(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn)`: Calls the first specified function - defined in the user keymap - on every tap, the second function on when the dance action finishes (like the previous option), and the last function when the tap dance action resets.
The first option is enough for a lot of cases, that just want dual roles. For example, `ACTION_TAP_DANCE_DOUBLE(KC_SPC, KC_ENT)` will result in `Space` being sent on single-tap, `Enter` otherwise.
And that's the bulk of it!
And now, on to the explanation of how it works!
The main entry point is `process_tap_dance()`, called from `process_record_quantum()`, which is run for every keypress, and our handler gets to run early. This function checks whether the key pressed is a tap-dance key. If it is not, and a tap-dance was in action, we handle that first, and enqueue the newly pressed key. If it is a tap-dance key, then we check if it is the same as the already active one (if there's one active, that is). If it is not, we fire off the old one first, then register the new one. If it was the same, we increment the counter and the timer.
This means that you have `TAPPING_TERM` time to tap the key again, you do not have to input all the taps within that timeframe. This allows for longer tap counts, with minimal impact on responsiveness.
Our next stop is `matrix_scan_tap_dance()`. This handles the timeout of tap-dance keys.
For the sake of flexibility, tap-dance actions can be either a pair of keycodes, or a user function. The latter allows one to handle higher tap counts, or do extra things, like blink the LEDs, fiddle with the backlighting, and so on. This is accomplished by using an union, and some clever macros.
# Examples
## Simple Example
Here's a simple example for a single definition:
1. In your `rules.mk`, add `TAP_DANCE_ENABLE = yes`
2. In your `config.h` (which you can copy from `qmk_firmware/keyboards/planck/config.h` to your keymap directory), add `#define TAPPING_TERM 200`
3. In your `keymap.c` file, define the variables and definitions, then add to your keymap:
```c
//Tap Dance Declarations
enum {
TD_ESC_CAPS = 0
};
//Tap Dance Definitions
qk_tap_dance_action_t tap_dance_actions[] = {
//Tap once for Esc, twice for Caps Lock
[TD_ESC_CAPS] = ACTION_TAP_DANCE_DOUBLE(KC_ESC, KC_CAPS)
// Other declarations would go here, separated by commas, if you have them
};
//In Layer declaration, add tap dance item in place of a key code
TD(TD_ESC_CAPS)
```
## Complex Examples
This section details several complex tap dance examples.
All the enums used in the examples are declared like this:
```c
// Enums defined for all examples:
enum {
CT_SE = 0,
CT_CLN,
CT_EGG,
CT_FLSH,
X_TAP_DANCE
};
```
### Example 1: Send `:` on Single Tap, `;` on Double Tap
```c
void dance_cln_finished (qk_tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
register_code (KC_RSFT);
register_code (KC_SCLN);
} else {
register_code (KC_SCLN);
}
}
void dance_cln_reset (qk_tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
unregister_code (KC_RSFT);
unregister_code (KC_SCLN);
} else {
unregister_code (KC_SCLN);
}
}
//All tap dance functions would go here. Only showing this one.
qk_tap_dance_action_t tap_dance_actions[] = {
[CT_CLN] = ACTION_TAP_DANCE_FN_ADVANCED (NULL, dance_cln_finished, dance_cln_reset)
};
```
### Example 2: Send "Safety Dance!" After 100 Taps
```c
void dance_egg (qk_tap_dance_state_t *state, void *user_data) {
if (state->count >= 100) {
SEND_STRING ("Safety dance!");
reset_tap_dance (state);
}
}
qk_tap_dance_action_t tap_dance_actions[] = {
[CT_EGG] = ACTION_TAP_DANCE_FN (dance_egg)
};
```
### Example 3: Turn LED Lights On Then Off, One at a Time
```c
// on each tap, light up one led, from right to left
// on the forth tap, turn them off from right to left
void dance_flsh_each(qk_tap_dance_state_t *state, void *user_data) {
switch (state->count) {
case 1:
ergodox_right_led_3_on();
break;
case 2:
ergodox_right_led_2_on();
break;
case 3:
ergodox_right_led_1_on();
break;
case 4:
ergodox_right_led_3_off();
_delay_ms(50);
ergodox_right_led_2_off();
_delay_ms(50);
ergodox_right_led_1_off();
}
}
// on the fourth tap, set the keyboard on flash state
void dance_flsh_finished(qk_tap_dance_state_t *state, void *user_data) {
if (state->count >= 4) {
reset_keyboard();
reset_tap_dance(state);
}
}
// if the flash state didn't happen, then turn off LEDs, left to right
void dance_flsh_reset(qk_tap_dance_state_t *state, void *user_data) {
ergodox_right_led_1_off();
_delay_ms(50);
ergodox_right_led_2_off();
_delay_ms(50);
ergodox_right_led_3_off();
}
//All tap dances now put together. Example 3 is "CT_FLASH"
qk_tap_dance_action_t tap_dance_actions[] = {
[CT_SE] = ACTION_TAP_DANCE_DOUBLE (KC_SPC, KC_ENT)
,[CT_CLN] = ACTION_TAP_DANCE_FN_ADVANCED (NULL, dance_cln_finished, dance_cln_reset)
,[CT_EGG] = ACTION_TAP_DANCE_FN (dance_egg)
,[CT_FLSH] = ACTION_TAP_DANCE_FN_ADVANCED (dance_flsh_each, dance_flsh_finished, dance_flsh_reset)
};
```
### Example 4: 'Quad Function Tap-Dance'
By [DanielGGordon](https://github.com/danielggordon)
Allow one key to have 4 (or more) functions, depending on number of presses, and if the key is held or tapped.
Below is a specific example:
* Tap = Send `x`
* Hold = Send `Control`
* Double Tap = Send `Escape`
* Double Tap and Hold = Send `Alt`
The following example can be easily expanded to more than 4 quite easily:
```c
//**************** Definitions needed for quad function to work *********************//
//Enums used to clearly convey the state of the tap dance
enum {
SINGLE_TAP = 1,
SINGLE_HOLD = 2,
DOUBLE_TAP = 3,
DOUBLE_HOLD = 4,
DOUBLE_SINGLE_TAP = 5 //send SINGLE_TAP twice - NOT DOUBLE_TAP
// Add more enums here if you want for triple, quadruple, etc.
};
typedef struct {
bool is_press_action;
int state;
} tap;
int cur_dance (qk_tap_dance_state_t *state) {
if (state->count == 1) {
//If count = 1, and it has been interrupted - it doesn't matter if it is pressed or not: Send SINGLE_TAP
if (state->interrupted || state->pressed==0) return SINGLE_TAP;
else return SINGLE_HOLD;
}
//If count = 2, and it has been interrupted - assume that user is trying to type the letter associated
//with single tap. In example below, that means to send `xx` instead of `Escape`.
else if (state->count == 2) {
if (state->interrupted) return DOUBLE_SINGLE_TAP;
else if (state->pressed) return DOUBLE_HOLD;
else return DOUBLE_TAP;
}
else return 6; //magic number. At some point this method will expand to work for more presses
}
//**************** Definitions needed for quad function to work *********************//
//instanalize an instance of 'tap' for the 'x' tap dance.
static tap xtap_state = {
.is_press_action = true,
.state = 0
};
void x_finished (qk_tap_dance_state_t *state, void *user_data) {
xtap_state.state = cur_dance(state);
switch (xtap_state.state) {
case SINGLE_TAP: register_code(KC_X); break;
case SINGLE_HOLD: register_code(KC_LCTRL); break;
case DOUBLE_TAP: register_code(KC_ESC); break;
case DOUBLE_HOLD: register_code(KC_LALT); break;
case DOUBLE_SINGLE_TAP: register_code(KC_X); unregister_code(KC_X); register_code(KC_X);
//Last case is for fast typing. Assuming your key is `f`:
//For example, when typing the word `buffer`, and you want to make sure that you send `ff` and not `Esc`.
//In order to type `ff` when typing fast, the next character will have to be hit within the `TAPPING_TERM`, which by default is 200ms.
}
}
void x_reset (qk_tap_dance_state_t *state, void *user_data) {
switch (xtap_state.state) {
case SINGLE_TAP: unregister_code(KC_X); break;
case SINGLE_HOLD: unregister_code(KC_LCTRL); break;
case DOUBLE_TAP: unregister_code(KC_ESC); break;
case DOUBLE_HOLD: unregister_code(KC_LALT);
case DOUBLE_SINGLE_TAP: unregister_code(KC_X);
}
xtap_state.state = 0;
}
```
And then simply add this to your list of tap dance functions:
`[X_TAP_DANCE] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, x_finished, x_reset)`

@ -14,9 +14,9 @@ When enabled, a `> ` prompt will appear, where you'll be able to type, backspace
`#define TERMINAL_HELP` enables some other output helpers that aren't really needed with this page.
## Future ideas
## Future Ideas
* Keyboard/user-extendable commands
* Keyboard/user-extensible commands
* Smaller footprint
* Arrow key support
* Command history
@ -30,7 +30,7 @@ When enabled, a `> ` prompt will appear, where you'll be able to type, backspace
* EEPROM read/write
* Audio control
## Current commands
## Current Commands
### `about`
@ -68,13 +68,13 @@ Prints out the entire keymap for a certain layer
```
> keymap 0
0x002b, 0x0014, 0x001a, 0x0008, 0x0015, 0x0017, 0x001c, 0x0018, 0x000c, 0x0012, 0x0013, 0x002a,
0x0029, 0x0004, 0x0016, 0x0007, 0x0009, 0x000a, 0x000b, 0x000d, 0x000e, 0x000f, 0x0033, 0x0034,
0x00e1, 0x001d, 0x001b, 0x0006, 0x0019, 0x0005, 0x0011, 0x0010, 0x0036, 0x0037, 0x0038, 0x0028,
0x002b, 0x0014, 0x001a, 0x0008, 0x0015, 0x0017, 0x001c, 0x0018, 0x000c, 0x0012, 0x0013, 0x002a,
0x0029, 0x0004, 0x0016, 0x0007, 0x0009, 0x000a, 0x000b, 0x000d, 0x000e, 0x000f, 0x0033, 0x0034,
0x00e1, 0x001d, 0x001b, 0x0006, 0x0019, 0x0005, 0x0011, 0x0010, 0x0036, 0x0037, 0x0038, 0x0028,
0x5cd6, 0x00e0, 0x00e2, 0x00e3, 0x5cd4, 0x002c, 0x002c, 0x5cd5, 0x0050, 0x0051, 0x0052, 0x004f,
>
>
```
### `exit`
Exits the terminal - same as `TERM_OFF`.
Exits the terminal - same as `TERM_OFF`.

@ -4,7 +4,7 @@
## Thermal Printer Keycodes
|Name|Description|
|----|-----------|
|`PRINT_ON`|Start printing everything the user types|
|`PRINT_OFF`|Stop printing everything the user types|
|Key |Description |
|-----------|----------------------------------------|
|`PRINT_ON` |Start printing everything the user types|
|`PRINT_OFF`|Stop printing everything the user types |

@ -0,0 +1,54 @@
# Unicode Support
There are three Unicode keymap definition method available in QMK:
## UNICODE_ENABLE
Supports Unicode input up to 0xFFFF. The keycode function is `UC(n)` in
keymap file, where *n* is a 4 digit hexadecimal.
## UNICODEMAP_ENABLE
Supports Unicode up to 0xFFFFFFFF. You need to maintain a separate mapping
table `const uint32_t PROGMEM unicode_map[] = {...}` in your keymap file.
The keycode function is `X(n)` where *n* is the array index of the mapping
table.
## UCIS_ENABLE
TBD
Unicode input in QMK works by inputing a sequence of characters to the OS,
sort of like macro. Unfortunately, each OS has different ideas on how Unicode is inputted.
This is the current list of Unicode input method in QMK:
* UC_OSX: MacOS Unicode Hex Input support. Works only up to 0xFFFF. Disabled by default. To enable: go to System Preferences -> Keyboard -> Input Sources, and enable Unicode Hex.
* UC_OSX_RALT: Same as UC_OSX, but sends the Right Alt key for unicode input
* UC_LNX: Unicode input method under Linux. Works up to 0xFFFFF. Should work almost anywhere on ibus enabled distros. Without ibus, this works under GTK apps, but rarely anywhere else.
* UC_WIN: (not recommended) Windows built-in Unicode input. To enable: create registry key under `HKEY_CURRENT_USER\Control Panel\Input Method\EnableHexNumpad` of type `REG_SZ` called `EnableHexNumpad`, set its value to 1, and reboot. This method is not recommended because of reliability and compatibility issue, use WinCompose method below instead.
* UC_WINC: Windows Unicode input using WinCompose. Requires [WinCompose](https://github.com/samhocevar/wincompose). Works reliably under many (all?) variations of Windows.
# Additional Language Support
In `quantum/keymap_extras/`, you'll see various language files - these work the same way as the alternative layout ones do. Most are defined by their two letter country/language code followed by an underscore and a 4-letter abbreviation of its name. `FR_UGRV` which will result in a `ù` when using a software-implemented AZERTY layout. It's currently difficult to send such characters in just the firmware.
# International Characters on Windows
[AutoHotkey](https://autohotkey.com) allows Windows users to create custom hotkeys among others.
The method does not require Unicode support in the keyboard itself but depends instead of AutoHotkey running in the background.
First you need to select a modifier combination that is not in use by any of your programs.
CtrlAltWin is not used very widely and should therefore be perfect for this.
There is a macro defined for a mod-tab combo `LCAG_T`.
Add this mod-tab combo to a key on your keyboard, e.g.: `LCAG_T(KC_TAB)`.
This makes the key behave like a tab key if pressed and released immediately but changes it to the modifier if used with another key.
In the default script of AutoHotkey you can define custom hotkeys.
<^<!<#a::Send, ä
<^<!<#<+a::Send, Ä
The hotkeys above are for the combination CtrlAltGui and CtrlAltGuiShift plus the letter a.
AutoHotkey inserts the Text right of `Send, ` when this combination is pressed.

@ -0,0 +1,125 @@
# Userspace: Sharing Code Between Keymaps
If you use more than one keyboard with a similar keymap, you might see the benefit in being able to share code between them. Create your own folder in `users/` named the same as your keymap (ideally your github username, `<name>`) with the following structure:
* `/users/<name>/` (added to the path automatically)
* `readme.md` (optional, recommended)
* `rules.mk` (included automatically)
* `<name>.h` (optional)
* `<name>.c` (optional)
* `config.h` (optional)
`<name>.c` will need to be added to the SRC in `rules.mk` like this:
SRC += <name>.c
Additional files may be added in the same way - it's recommended you have one named `<name>`.c/.h though.
All this only happens when you build a keymap named `<name>`, like this:
make planck:<name>
For example,
make planck:jack
Will include the `/users/jack/` folder in the path, along with `/users/jack/rules.mk`.
Additionally, `config.h` here will be processed like the same file in your keymap folder. This is handled separately from the `<name>.h` file.
The reason for this, is that `<name>.h` won't be added in time to add settings (such as `#define TAPPING_TERM 100`), and including the `<name.h>` file in any `config.h` files will result in compile issues.
So you should use the `config.h` for QMK settings, and the `<name>.h` file for user or keymap specific settings.
## Readme
Please include authorship (your name, github username, email), and optionally [a license that's GPL compatible](https://www.gnu.org/licenses/license-list.html#GPLCompatibleLicenses).
## `Config.h`
If you do add a `config,h` file, you want to make sure that it only gets processed once. So you may want to start off with something like this:
```c
#ifndef USERSPACE_CONFIG_H
#define USERSPACE_CONFIG_H
// Put normal config.h settings here:
#endif // !USERSPACE_CONFIG_H
```
You can use any option hre that you could use in your keymap's `config.h` file. You can find a list of vales [here](config_options.md).
## Example
For a brief example, checkout `/users/_example/` , or for a more detailed examples check out [`template.h`](https://github.com/qmk/qmk_firmware/blob/master/users/drashna/template.h) and [`template.c`](https://github.com/qmk/qmk_firmware/blob/master/users/drashna/template.c) in `/users/drashna/` .
### Consolidated Macros
If you wanted to consolidate macros and other functions into your userspace for all of your keymaps, you can do that. The issue is that you then cannot call any function defined in your userspace, or it gets complicated. To better handle this, you can call the functions here and create new functions to use in individual keymaps.
First, you'd want to go through all of your `keymap.c` files and replace `process_record_user` with `process_record_keymap` instead. This way, you can still use keyboard specific codes on those boards, and use your custom "global" keycodes as well. You'll also want to replace `SAFE_RANGE` with `NEW_SAFE_RANGE` so that you wont have any overlapping keycodes
Then add `#include <name.h>` to all of your keymap.c files. This allows you to use these new keycodes without having to redefine them in each keymap.
Once you've done that, you'll want to set the keycode definitions that you need to the `<name>.h` file. For instance:
```
#ifndef USERSPACE
#define USERSPACE
#include "quantum.h"
// Define all of
enum custom_keycodes {
KC_MAKE = SAFE_RANGE,
NEW_SAFE_RANGE //use "NEW_SAFE_RANGE" for keymap specific codes
};
#endif
```
Now you want to create the `<name>.c` file, and add this content to it:
```
#include "<name>.h"
#include "quantum.h"
#include "action.h"
#include "version.h"
__attribute__ ((weak))
bool process_record_keymap(uint16_t keycode, keyrecord_t *record) {
return true;
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case KC_MAKE:
if (!record->event.pressed) {
SEND_STRING("make " QMK_KEYBOARD ":" QMK_KEYMAP
#if (defined(BOOTLOADER_DFU) || defined(BOOTLOADER_LUFA_DFU) || defined(BOOTLOADER_QMK_DFU))
":dfu "
#elif defined(BOOTLOADER_HALFKAY)
":teensy "
#elif defined(BOOTLOADER_CATERINA)
":avrdude "
#endif
SS_TAP(X_ENTER));
}
return false;
break;
}
return process_record_keymap(keycode, record);
}
```
This will add a new `KC_MAKE` keycode that can be used in any of your keymaps. And this keycode will output `make <keyboard>:<keymap">`, making frequent compiling easier. And this will work with any keyboard and any keymap as it will output the current boards info, so that you don't have to type this out every time.
Additionally, this should flash the newly compiled firmware automatically, using the correct utility, based on the bootloader settings (or default to just generating the HEX file). However, it should be noted that this may not work on all systems. AVRDUDE doesn't work on WSL, namely (and will dump the HEX in the ".build" folder instead).
## Override default userspace
By default the userspace used will be the same as the keymap name. In some situations this isn't desirable. For instance, if you use the [layout](feature_layouts.md) feature you can't use the same name for different keymaps (e.g. ANSI and ISO). You can name your layouts `mylayout-ansi` and `mylayout-iso` and add the following line to your layout's `rules.mk`:
```
USER_NAME := mylayout
```

@ -1,105 +1,26 @@
# QMK Features
## Space Cadet Shift: The future, built in
Steve Losh [described](http://stevelosh.com/blog/2012/10/a-modern-space-cadet/) the Space Cadet Shift quite well. Essentially, you hit the left Shift on its own, and you get an opening parenthesis; hit the right Shift on its own, and you get the closing one. When hit with other keys, the Shift key keeps working as it always does. Yes, it's as cool as it sounds. Head on over to the [Space Cadet Shift](space_cadet_shift.md) page to read about it.
## The Leader key: A new kind of modifier
Most modifiers have to be held or toggled. But what if you had a key that indicated the start of a sequence? You could press that key and then rapidly press 1-3 more keys to trigger a macro, or enter a special layer, or anything else you might want to do. To learn more about it check out the [Leader Key](feature_leader_key.md) page.
## Tap Dance: A single key can do 3, 5, or 100 different things
Hit the semicolon key once, send a semicolon. Hit it twice, rapidly -- send a colon. Hit it three times, and your keyboard's LEDs do a wild dance. That's just one example of what Tap Dance can do. Read more about it on the [Tap Dance](tap_dance.md) page.
## Temporarily setting the default layer
`DF(layer)` - sets default layer to _layer_. The default layer is the one at the "bottom" of the layer stack - the ultimate fallback layer. This currently does not persist over power loss. When you plug the keyboard back in, layer 0 will always be the default. It is theoretically possible to work around that, but that's not what `DF` does.
## Macro shortcuts: Send a whole string when pressing just one key
How would you like a single keypress to send a whole word, sentence, paragraph, or even document? Head on over to the [Macros](macros.md) page to read up on all aspects of Simple and Dynamic Macros.
## Additional keycode aliases for software-implemented layouts \(Colemak, Dvorak, etc\)
Everything is assuming you're in Qwerty \(in software\) by default, but there is built-in support for using a Colemak or Dvorak layout by including this at the top of your keymap:
```
#include <keymap_colemak.h>
```
If you use Dvorak, use `keymap_dvorak.h` instead of `keymap_colemak.h` for this line. After including this line, you will get access to:
* `CM_*` for all of the Colemak-equivalent characters
* `DV_*` for all of the Dvorak-equivalent characters
These implementations assume you're using Colemak or Dvorak on your OS, not on your keyboard - this is referred to as a software-implemented layout. If your computer is in Qwerty and your keymap is in Colemak or Dvorak, this is referred to as a firmware-implemented layout, and you won't need these features.
To give an example, if you're using software-implemented Colemak, and want to get an `F`, you would use `CM_F`. Using `KC_F` under these same circumstances would result in `T`.
## Backlight Breathing
In order to enable backlight breathing, the following line must be added to your config.h file.
```
#define BACKLIGHT_BREATHING
```
The following function calls are used to control the breathing effect.
* `breathing_enable()` - Enable the free-running breathing effect.
* `breathing_disable()` - Disable the free-running breathing effect immediately.
* `breathing_self_disable()` - Disable the free-running breathing effect after the current effect ends.
* `breathing_toggle()` - Toggle the free-running breathing effect.
* `breathing_defaults()` - Reset the speed and brightness settings of the breathing effect.
The following function calls are used to control the maximum brightness of the breathing effect.
* `breathing_intensity_set(value)` - Set the brightness of the breathing effect when it is at its max value.
* `breathing_intensity_default()` - Reset the brightness of the breathing effect to the default value based on the current backlight intensity.
The following function calls are used to control the cycling speed of the breathing effect.
* `breathing_speed_set(value)` - Set the speed of the breathing effect - how fast it cycles.
* `breathing_speed_inc(value)` - Increase the speed of the breathing effect by a fixed value.
* `breathing_speed_dec(value)` - Decrease the speed of the breathing effect by a fixed value.
* `breathing_speed_default()` - Reset the speed of the breathing effect to the default value.
The following example shows how to enable the backlight breathing effect when the FUNCTION layer macro button is pressed:
```
case MACRO_FUNCTION:
if (record->event.pressed)
{
breathing_speed_set(3);
breathing_enable();
layer_on(LAYER_FUNCTION);
}
else
{
breathing_speed_set(1);
breathing_self_disable();
layer_off(LAYER_FUNCTION);
}
break;
```
The following example shows how to pulse the backlight on-off-on when the RAISED layer macro button is pressed:
```
case MACRO_RAISED:
if (record->event.pressed)
{
layer_on(LAYER_RAISED);
breathing_speed_set(2);
breathing_pulse();
update_tri_layer(LAYER_LOWER, LAYER_RAISED, LAYER_ADJUST);
}
else
{
layer_off(LAYER_RAISED);
update_tri_layer(LAYER_LOWER, LAYER_RAISED, LAYER_ADJUST);
}
break;
```
QMK has a staggering number of features for building your keyboard. It can take some time to understand all of them and determine which one will achieve your goal.
* [Advanced Keycodes](feature_advanced_keycodes.md) - Change layers, type shifted keys, and more. Go beyond typing simple characters.
* [Audio](feature_audio.md) - Connect a speaker to your keyboard for audio feedback, midi support, and music mode.
* [Auto Shift](feature_auto_shift.md) - Tap for the normal key, hold slightly longer for its shifted state.
* [Backlight](feature_backlight.md) - LED lighting support for your keyboard.
* [Bootmagic](feature_bootmagic.md) - Adjust the behavior of your keyboard using hotkeys.
* [Dynamic Macros](feature_dynamic_macros.md) - Record and playback macros from the keyboard itself.
* [Key Lock](feature_key_lock.md) - Lock a key in the "down" state.
* [Layouts](feature_layouts.md) - Use one keymap with any keyboard that supports your layout.
* [Leader Key](feature_leader_key.md) - Tap the leader key followed by a sequence to trigger custom behavior.
* [Macros](feature_macros.md) - Send multiple key presses when pressing only one physical key.
* [Mouse keys](feature_mouse_keys.md) - Control your mouse pointer from your keyboard.
* [Pointing Device](feature_pointing_device.md) - Framework for connecting your custom pointing device to your keyboard.
* [PS2 Mouse](feature_ps2_mouse.md) - Driver for connecting a PS/2 mouse directly to your keyboard.
* [RGB Light](feature_rgblight.md) - RGB lighting for your keyboard.
* [Space Cadet](feature_space_cadet.md) - Use your left/right shift keys to type parenthesis and brackets.
* [Stenography](feature_stenography.md) - Put your keyboard into Plover mode for stenography use.
* [Tap Dance](feature_tap_dance.md) - Make a single key do as many things as you want.
* [Terminal](feature_terminal.md) - CLI interface to the internals of your keyboard.
* [Thermal Printer](feature_thermal_printer.md) - Connect a thermal printer to your keyboard to be able to toggle on a printed log of everything you type.
* [Unicode](feature_unicode.md) - Unicode input support.
* [Userspace](feature_userspace.md) - Share code between different keymaps and keyboards.

@ -0,0 +1,104 @@
# Flashing Instructions and Bootloader Information
There are quite a few different types of bootloaders that keyboards use, and just about all of the use a different flashing method. Luckily, projects like the [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) aim to be compatible with all the different types without having to think about it much, but this article will describe the different types of bootloaders, and available methods for flashing them.
If you have a bootloader selected with the `BOOTLOADER` variable in your `rules.mk`, QMK will automatically calculate if your .hex file is the right size to be flashed to the device, and output the total size it bytes (along with the max). To run this process manually, compile with the target `check-size`, eg `make planck/rev4:default:check-size`.
## DFU
Atmel's DFU bootloader comes on all atmega32u4 chips by default, and is used by many keyboards that have their own ICs on their PCBs (Older OLKB boards, Clueboards). Some keyboards may also use LUFA's DFU bootloader (or QMK's fork) (Newer OLKB boards) that adds in additional features specific to that hardware.
To ensure compatibility with the DFU bootloader, make sure this block is present your `rules.mk` (optionally with `lufa-dfu` or `qmk-dfu` instead):
# Bootloader
# This definition is optional, and if your keyboard supports multiple bootloaders of
# different sizes, comment this out, and the correct address will be loaded
# automatically (+60). See bootloader.mk for all options.
BOOTLOADER = atmel-dfu
Compatible flashers:
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (recommended GUI)
* [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` in QMK (recommended command line)
* [Atmel's Flip](http://www.microchip.com/developmenttools/productdetails.aspx?partno=flip) (not recommended)
Flashing sequence:
1. Press the `RESET` keycode, or tap the RESET button (or short RST to GND).
2. Wait for the OS to detect the device
3. Erase the memory (may be done automatically)
4. Flash a .hex file
5. Reset the device into application mode (may be done automatically)
or:
make <keyboard>:<keymap>:dfu
### QMK DFU
QMK has a fork of the LUFA DFU bootloader that allows for a simple matrix scan for exiting the bootloader and returning to the application, as well as flashing an LED/making a ticking noise with a speaker when things are happening. To enable these features, use this block in your `config.h` (The key that exits the bootloader needs to be hooked-up to the INPUT and OUTPUT defined here):
#define QMK_ESC_OUTPUT F1 // usually COL
#define QMK_ESC_INPUT D5 // usually ROW
#define QMK_LED E6
#define QMK_SPEAKER C6
The Manufacturer and Product names are automatically pulled from your `config.h`, and "Bootloader" is added to the product.
To generate this bootloader, use the `bootloader` target, eg `make planck/rev4:default:bootloader`.
To generate a production-ready .hex file (containing the application and the bootloader), use the `production` target, eg `make planck/rev4:default:production`.
## Caterina
Arduino boards and their clones use the [Caterina bootloader](https://github.com/arduino/Arduino/tree/master/hardware/arduino/avr/bootloaders/caterina) (any keyboard built with a Pro Micro, or clone), and uses the avr109 protocol to communicate through virtual serial. Bootloaders like [A-Star](https://www.pololu.com/docs/0J61/9) are based on Caterina.
To ensure compatibility with the Caterina bootloader, make sure this block is present your `rules.mk`:
# Bootloader
# This definition is optional, and if your keyboard supports multiple bootloaders of
# different sizes, comment this out, and the correct address will be loaded
# automatically (+60). See bootloader.mk for all options.
BOOTLOADER = caterina
Compatible flashers:
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (recommended GUI)
* [avrdude](http://www.nongnu.org/avrdude/) with avr109 / `:avrdude` (recommended command line)
* [AVRDUDESS](https://github.com/zkemble/AVRDUDESS)
Flashing sequence:
1. Press the `RESET` keycode, or short RST to GND quickly (you only have 7 seconds to flash once it enters)
2. Wait for the OS to detect the device
4. Flash a .hex file
5. Wait for the device to reset automatically
or
make <keyboard>:<keymap>:avrdude
## Halfkay
Halfkay is a super-slim protocol developed by PJRC that uses HID, and come on all Teensys (namely the 2.0).
To ensure compatibility with the Halfkay bootloader, make sure this block is present your `rules.mk`:
# Bootloader
# This definition is optional, and if your keyboard supports multiple bootloaders of
# different sizes, comment this out, and the correct address will be loaded
# automatically (+60). See bootloader.mk for all options.
BOOTLOADER = halfkay
Compatible flashers:
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (recommended GUI)
* [Teensy Loader](https://www.pjrc.com/teensy/loader.html)
* [Teensy Loader Command Line](https://www.pjrc.com/teensy/loader_cli.html) (recommended command line)
Flashing sequence:
1. Press the `RESET` keycode, or short RST to GND quickly (you only have 7 seconds to flash once it enters)
2. Wait for the OS to detect the device
4. Flash a .hex file
5. Reset the device into application mode (may be done automatically)

@ -1,6 +1,6 @@
# Installing Build Tools
This page describes setting up the build environment for QMK. These instructions cover AVR processors (such as the atmega32u4.)
This page describes setting up the build environment for QMK. These instructions cover AVR processors (such as the atmega32u4).
<!-- FIXME: We should have ARM instructions somewhere. -->
@ -31,11 +31,15 @@ git
Install the dependencies with your favorite package manager.
Debian/Ubuntu example:
Debian / Ubuntu example:
sudo apt-get update
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
Fedora / Red Hat example:
sudo dnf install gcc unzip wget zip dfu-util dfu-programmer avr-gcc avr-libc binutils-avr32-linux-gnu arm-none-eabi-gcc-cs arm-none-eabi-binutils-cs arm-none-eabi-newlib
## Nix
If you're on [NixOS](https://nixos.org/), or have Nix installed on Linux or macOS, run `nix-shell` from the repository root to get a build environment.
@ -44,7 +48,7 @@ By default, this will download compilers for both AVR and ARM. If you don't need
nix-shell --arg arm false
## Mac
## macOS
If you're using [homebrew,](http://brew.sh/) you can use the following commands:
brew tap osx-cross/avr
@ -53,15 +57,16 @@ If you're using [homebrew,](http://brew.sh/) you can use the following commands:
brew install avr-gcc
brew install dfu-programmer
brew install gcc-arm-none-eabi
brew install avrdude
This is the recommended method. If you don't have homebrew, [install it!](http://brew.sh/) It's very much worth it for anyone who works in the command line. Note that the `make` and `make install` portion during the homebrew installation of avr-libc can take over 20 minutes and exhibit high CPU usage.
## Windows with msys2 (recommended)
The best environment to use, for Windows Vista through any later version (tested on 7 and 10,) is [msys2](http://www.msys2.org).
The best environment to use, for Windows Vista through any later version (tested on 7 and 10), is [msys2](http://www.msys2.org).
* Install msys2 by downloading and following the instructions here: http://www.msys2.org
* Open the "MSYS2 MingGW 64-bit" shortcut
* Install msys2 by downloading it and following the instructions here: http://www.msys2.org
* Open the ``MSYS2 MingGW 64-bit`` shortcut
* Navigate to your qmk checkout. For example, if it's in the root of your c drive:
* `$ cd /c/qmk_firmware`
* Run `util/msys2_install.sh` and follow the prompts
@ -78,26 +83,26 @@ In addition to the Creators Update, you need Windows 10 Subystem for Linux, so i
### Git
If you already have cloned the repository on your Windows file system you can ignore this section.
You will need to clone the repository to your Windows file system using the normal Git for Windows and **not** the WSL Git. So if you haven't installed Git before, [download](https://git-scm.com/download/win) and install it. Then [set it up](https://git-scm.com/book/en/v2/Getting-Started-First-Time-Git-Setup), it's important that you setup the e-mail and user name, especially if you are planning to contribute.
You will need to clone the repository to your Windows file system using the normal Git for Windows and **not** the WSL Git. So if you haven't installed Git before, [download](https://git-scm.com/download/win) and install it. Then [set it up](https://git-scm.com/book/en/v2/Getting-Started-First-Time-Git-Setup), it's important that you setup the e-mail and user name, especially if you are planning to contribute.
Once Git is installed, open the Git bash command and change the directory to where you want to clone QMK, note that you have to use forward slashes, and that your c drive is accessed like this `/c/path/to/where/you/want/to/go`. Then run `git clone --recurse-submodules https://github.com/qmk/qmk_firmware`, this will create a new folder `qmk_firmware` as a subfolder of the current one.
Once Git is installed, open the Git Bash command and change the directory to where you want to clone QMK; note that you have to use forward slashes, and that your c drive is accessed like this `/c/path/to/where/you/want/to/go`. Then run `git clone --recurse-submodules https://github.com/qmk/qmk_firmware`, this will create a new folder `qmk_firmware` as a subfolder of the current one.
### Toolchain setup
### Toolchain Setup
The Toolchain setup is done through the Windows Subsystem for Linux, and the process is fully automated. If you want to do everything manually, there are no other instructions than the scripts themselves, but you can always open issues and ask for more information.
1. Open "Bash On Ubuntu On Windows" from the start menu.
2. Go to the directory where you cloned `qmk_firmware`. Note that the paths start with `/mnt/` in the WSL, so you have to write for example `cd /mnt/c/path/to/qmk_firmware`.
1. Open "Bash On Ubuntu On Windows" from the start menu.
2. Go to the directory where you cloned `qmk_firmware`. Note that the paths start with `/mnt/` in the WSL, so you have to write for example `cd /mnt/c/path/to/qmk_firmware`.
3. Run `util/wsl_install.sh` and follow the on-screen instructions.
4. Close the Bash command window, and re-open it.
5. You are ready to compile and flash the firmware!
### Some important things to keep in mind
### Some Important Things to Keep in Mind
* You can run `util/wsl_install.sh` again to get all the newest updates.
* Your QMK repository need to be on a Windows file system path, since WSL can't run executables outside it.
* The WSL Git is **not** compatible with the Windows Git, so use the Windows Git Bash or a windows Git GUI for all Git operations
* You can edit files either inside WSL or normally using Windows, but note that if you edit makefiles or shell scripts, make sure you are using an editor that saves the files with Unix line endings. Otherwise the compilation might not work.
## Windows (Vista and later) (Deprecated)
## Windows (Vista and Later) (Deprecated)
These are the old instructions for Windows Vista and later. We recommend you use [MSYS2 as outlined above](#windows-with-msys2-recommended).
@ -118,17 +123,20 @@ If this is a bit complex for you, Docker might be the turn-key solution you need
```bash
# You'll run this every time you want to build a keymap
# modify the keymap and keyboard assigment to compile what you want
# modify the keymap and keyboard assignment to compile what you want
# defaults are ergodox/default
docker run -e keymap=gwen -e keyboard=ergodox_ez --rm -v $('pwd'):/qmk:rw edasque/qmk_firmware
```
# On windows docker seems to have issue with VOLUME tag in Dockerfile, and $('pwd') won't print a windows compliant path, use full path instead like this
docker run -e keymap=default -e keyboard=ergobox_ez --rm -v D:/Users/Sacapuces/Documents/Repositories/qmk:/qmk:rw edasque/qmk_firmware
On Windows Docker seems to have issues with the VOLUME tag in Dockerfile, and `$('pwd')` won't print a Windows compliant path; use full path instead, like this:
```bash
docker run -e keymap=default -e keyboard=ergodox_ez --rm -v D:/Users/Sacapuces/Documents/Repositories/qmk:/qmk:rw edasque/qmk_firmware
```
This will compile the targeted keyboard/keymap and leave it in your QMK directory for you to flash.
## Vagrant
If you have any problems building the firmware, you can try using a tool called Vagrant. It will set up a virtual computer with a known configuration that's ready-to-go for firmware building. OLKB does NOT host the files for this virtual computer. Details on how to set up Vagrant are in the [vagrant guide](vagrant_guide.md).
If you have any problems building the firmware, you can try using a tool called Vagrant. It will set up a virtual computer with a known configuration that's ready-to-go for firmware building. OLKB does NOT host the files for this virtual computer. Details on how to set up Vagrant are in the [vagrant guide](getting_started_vagrant.md).

@ -0,0 +1,21 @@
# Getting Help
There are a lot of resources for getting help with QMK.
## Realtime Chat
You can find QMK developers and users on our main [gitter chat room](https://gitter.im/qmk/qmk_firmware). We also have other rooms for more specific discussion:
* [Main Firmware Chat](https://gitter.im/qmk/qmk_firmware)
* [QMK Toolbox](https://gitter.im/qmk/qmk_toolbox)
* [Hardware Design Discussion](https://gitter.im/qmk/qmk_hardware)
* [Web Configurator](https://gitter.im/qmk/qmk_configurator)
* [Compiler API](https://gitter.im/qmk/qmk_compiler_api)
## OLKB Subreddit
The official QMK forum is [/r/olkb](https://reddit.com/r/olkb) on [reddit.com](https://reddit.com).
## Github Issues
You can open an [issue on GitHub](https://github.com/qmk/qmk_firmware/issues). This is especially handy when your issue will require long-term discussion or debugging.

@ -1,4 +1,4 @@
# How to use Github with QMK
# How to Use Github with QMK
Github can be a little tricky to those that aren't familiar with it - this guide will walk through each step of forking, cloning, and submitting a pull request with QMK.
@ -52,7 +52,7 @@ To https://github.com/whoeveryouare/qmk_firmware.git
+ 20043e64...7da94ac5 master -> master
```
Your changes now exist on your fork on Github - if you go back there (https://github.com/<whoeveryouare>/qmk_firmware), you can create a "New Pull Request" by clicking this button:
Your changes now exist on your fork on Github - if you go back there (`https://github.com/<whoeveryouare>/qmk_firmware`), you can create a "New Pull Request" by clicking this button:
![New Pull Request](http://i.imgur.com/DxMHpJ8.jpg)
@ -60,4 +60,4 @@ Here you'll be able to see exactly what you've committed - if it all looks good,
![Create Pull Request](http://i.imgur.com/Ojydlaj.jpg)
After submitting, we may talk to you about your changes, ask that you make changes, and eventually accept it! Thanks for contributing to QMK :)
After submitting, we may talk to you about your changes, ask that you make changes, and eventually accept it! Thanks for contributing to QMK :)

@ -1,47 +0,0 @@
# Introduction
This page attempts to explain the basic information you need to know to work with the QMK project. It assumes that you are familiar with navigating a UNIX shell, but does not assume you are familiar with C or with compiling using make.
## Basic QMK structure
QMK is a fork of @tmk's [tmk_keyboard](https://github.com/tmk/tmk_keyboard) project. The original TMK code, with modifications, can be found in the `tmk` folder. The QMK additions to the project may be found in the `quantum` folder. Keyboard projects may be found in the `handwired` and `keyboard` folders.
### Keyboard project structure
Within the `handwired` and `keyboard` folders is a directory for each keyboard project, for example `qmk_firmware/keyboards/clueboard`. Within you'll find the following structure:
* `keymaps/`: Different keymaps that can be built
* `rules.mk`: The file that sets the default "make" options. Do not edit this file directly, instead use a keymap specific `Makefile`.
* `config.h`: The file that sets the default compile time options. Do not edit this file directly, instead use a keymap specific `config.h`.
### Keymap structure
In every keymap folder, the following files may be found. Only `keymap.c` is required, if the rest of the files are not found the default options will be chosen.
* `config.h`: the options to configure your keymap
* `keymap.c`: all of your keymap code, required
* `rules.mk`: the features of QMK that are enabled
* `readme.md`: a description of your keymap, how others might use it, and explanations of features. Please upload images to a service like imgur.
# The `config.h` file
There are 2 `config.h` locations:
* keyboard (`/keyboards/<keyboard>/config.h`)
* keymap (`/keyboards/<keyboard>/keymaps/<keymap>/config.h`)
If the keymap `config.h` exists that file is included by the build system and the keyboard `config.h` is not included. If you wish to override settings in your keymap's `config.h` you will need to include some glue code:
```
#ifndef CONFIG_USER_H
#define CONFIG_USER_H
#include "../../config.h"
```
If you want to override a setting from the parent `config.h` file, you need to `#undef` and then `#define` the setting again, like this:
```c
#undef MY_SETTING
#define MY_SETTING 4
```

@ -0,0 +1,47 @@
# Introduction
This page attempts to explain the basic information you need to know to work with the QMK project. It assumes that you are familiar with navigating a Unix shell, but does not assume you are familiar with C or with compiling using make.
## Basic QMK Structure
QMK is a fork of [Jun Wako](https://github.com/tmk)'s [tmk_keyboard](https://github.com/tmk/tmk_keyboard) project. The original TMK code, with modifications, can be found in the `tmk` folder. The QMK additions to the project may be found in the `quantum` folder. Keyboard projects may be found in the `handwired` and `keyboard` folders.
### Keyboard Project Structure
Within the folder `keyboards` and its subfolder `handwired` is a directory for each keyboard project, for example `qmk_firmware/keyboards/clueboard`. Within it you'll find the following structure:
* `keymaps/`: Different keymaps that can be built
* `rules.mk`: The file that sets the default "make" options. Do not edit this file directly, instead use a keymap specific `Makefile`
* `config.h`: The file that sets the default compile time options. Do not edit this file directly, instead use a keymap specific `config.h`.
### Keymap Structure
In every keymap folder, the following files may be found. Only `keymap.c` is required, and if the rest of the files are not found the default options will be chosen.
* `config.h`: the options to configure your keymap
* `keymap.c`: all of your keymap code, required
* `rules.mk`: the features of QMK that are enabled
* `readme.md`: a description of your keymap, how others might use it, and explanations of features. Please upload images to a service like imgur.
# The `config.h` File
There are 2 `config.h` locations:
* keyboard (`/keyboards/<keyboard>/config.h`)
* keymap (`/keyboards/<keyboard>/keymaps/<keymap>/config.h`)
If the keymap `config.h` exists, that file is included by the build system and the keyboard `config.h` is not included. If you wish to override settings in your keymap's `config.h` you will need to include some glue code:
```
#ifndef CONFIG_USER_H
#define CONFIG_USER_H
#include "config_common.h"
```
If you want to override a setting from the parent `config.h` file, you need to `#undef` and then `#define` the setting again, like this:
```c
#undef MY_SETTING
#define MY_SETTING 4
```

@ -1,10 +1,10 @@
# More detailed make instruction
# More Detailed `make` Instructions
The full syntax of the `make` command is `<keyboard_folder>:<keymap>:<target>`, where:
* `<keyboard_folder>` is the path of the keyboard, for example `planck`
* Use `all` to compile all keyboards
* Specify the path to compile a revision, for example `planck/rev4` or `planck/rev3`
* Specify the path to compile a revision, for example `planck/rev4` or `planck/rev3`
* If the keyboard doesn't have any folders, it can be left out
* To compile the default folder, you can leave it out
* `<keymap>` is the name of the keymap, for example `algernon`
@ -13,8 +13,8 @@ The full syntax of the `make` command is `<keyboard_folder>:<keymap>:<target>`,
The `<target>` means the following
* If no target is given, then it's the same as `all` below
* `all` compiles as many keyboard/revision/keymap combinations as specified. For example, `make planck/rev4:default:all` will generate a single .hex, while `make planck/rev4:all` will generate a hex for every keymap available to the planck.
* `dfu`, `teensy` or `dfu-util`, compile and upload the firmware to the keyboard. If the compilation fails, then nothing will be uploaded. The programmer to use depends on the keyboard. For most keyboards it's `dfu`, but for ChibiOS keyboards you should use `dfu-util`, and `teensy` for standard Teensys. To find out which command you should use for your keyboard, check the keyboard specific readme.
* `all` compiles as many keyboard/revision/keymap combinations as specified. For example, `make planck/rev4:default` will generate a single .hex, while `make planck/rev4:all` will generate a hex for every keymap available to the planck.
* `dfu`, `teensy` or `dfu-util`, compile and upload the firmware to the keyboard. If the compilation fails, then nothing will be uploaded. The programmer to use depends on the keyboard. For most keyboards it's `dfu`, but for ChibiOS keyboards you should use `dfu-util`, and `teensy` for standard Teensys. To find out which command you should use for your keyboard, check the keyboard specific readme.
* **Note**: some operating systems need root access for these commands to work, so in that case you need to run for example `sudo make planck/rev4:default:dfu`.
* `clean`, cleans the build output folders to make sure that everything is built from scratch. Run this before normal compilation if you have some unexplainable problems.
@ -30,10 +30,10 @@ The make command itself also has some additional options, type `make --help` for
Here are some examples commands
* `make all:all` builds everything (all keyboard folders, all keymaps). Running just `make` from the `root` will also run this.
* `make ergodox_infinity:algernon:clean` will clean the build output of the Ergodox Infinity keyboard.
* `make ergodox_infinity:algernon:clean` will clean the build output of the Ergodox Infinity keyboard.
* `make planck/rev4:default:dfu COLOR=false` builds and uploads the keymap without color output.
## `rules.mk` options
## `rules.mk` Options
Set these variables to `no` to disable them, and `yes` to enable them.
@ -53,9 +53,9 @@ This allows you to use the system and audio control key codes.
`CONSOLE_ENABLE`
This allows you to print messages that can be read using [`hid_listen`](https://www.pjrc.com/teensy/hid_listen.html).
This allows you to print messages that can be read using [`hid_listen`](https://www.pjrc.com/teensy/hid_listen.html).
By default, all debug (*dprint*) print (*print*, *xprintf*), and user print (*uprint*) messages will be enabled. This will eat up a significant portion of the flash and may make the keyboard .hex file too big to program.
By default, all debug (*dprint*) print (*print*, *xprintf*), and user print (*uprint*) messages will be enabled. This will eat up a significant portion of the flash and may make the keyboard .hex file too big to program.
To disable debug messages (*dprint*) and reduce the .hex file size, include `#define NO_DEBUG` in your `config.h` file.
@ -65,7 +65,7 @@ To disable print messages (*print*, *xprintf*) and **KEEP** user print messages
To see the text, open `hid_listen` and enjoy looking at your printed messages.
**NOTE:** Do not include *uprint* messages in anything other than your keymap code. It must not be used within the QMK system framework. Otherwise, you will bloat other people's .hex files.
**NOTE:** Do not include *uprint* messages in anything other than your keymap code. It must not be used within the QMK system framework. Otherwise, you will bloat other people's .hex files.
Consumes about 400 bytes.
@ -131,9 +131,9 @@ This consumes about 5390 bytes.
`KEY_LOCK_ENABLE`
This enables [key lock](key_lock.md). This consumes an additional 260 bytes.
This enables [key lock](feature_key_lock.md). This consumes an additional 260 bytes.
## Customizing Makefile options on a per-keymap basis
## Customizing Makefile Options on a Per-Keymap Basis
If your keymap directory has a file called `rules.mk` any options you set in that file will take precedence over other `rules.mk` options for your particular keyboard.

@ -10,11 +10,11 @@ Using the `/Vagrantfile` in this repository requires you have [Vagrant](http://w
Other than having Vagrant and Virtualbox installed and possibly a restart of your computer afterwards, you can simple run a 'vagrant up' anywhere inside the folder where you checked out this project and it will start a Linux virtual machine that contains all the tools required to build this project. There is a post Vagrant startup hint that will get you off on the right foot, otherwise you can also reference the build documentation below.
# Flashing the firmware
# Flashing the Firmware
The "easy" way to flash the firmware is using a tool from your host OS:
* [QMK Flasher](https://github.com/qmk/qmk_flasher)
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox) (recommended)
* [Teensy Loader](https://www.pjrc.com/teensy/loader.html)
* [Atmel FLIP](http://www.atmel.com/tools/flip.aspx)

@ -1,170 +0,0 @@
# Glossary of QMK terms
## ARM
A line of 32-bit MCU's produced by a number of companies, such as Atmel, Cypress, Kinetis, NXP, ST, and TI.
## AVR
A line of 8-bit MCU's produced by [Atmel](http://atmel.com). AVR was the original platform that TMK supported.
## AZERTY
The standard Français (French) keyboard layout. Named for the first 6 keys on the keyboard.
## Backlight
A generic term for lighting on a keyboard. The backlight is typically, but not always, an array of LED's that shine through keycaps and/or switches.
## Bluetooth
A short range peer to peer wireless protocol. Most common wireless protocol for a keyboard.
## Bootloader
A special program that is written to a protected area of your MCU that allows the MCU to upgrade its own firmware, typically over USB.
## Bootmagic
A feature that allows for various keyboard behavior changes to happen on the fly, such as swapping or disabling common keys.
## C
A low-level programming language suitable for system code. Most QMK code is written in C.
## Colemak
An alternative keyboard layout that is gaining in popularity.
## Compile
The process of turning human readable code into machine code your MCU can run.
## Dvorak
An alternative keyboard layout developed by Dr. August Dvorak in the 1930's. A shortened form of the Dvorak Simplified Keyboard.
## Dynamic Macro
A macro which has been recorded on the keyboard and which will be lost when the keyboard is unplugged or the computer rebooted.
* [Dynamic Macro Documentation](dynamic_macros.html)
## Eclipse
An IDE that is popular with many C developers.
* [Eclipse Setup Instructions](eclipse.html)
## Firmware
The software that controls your MCU.
## FLIP
Software provided by Atmel for flashing AVR devices. We generally recommend [QMK Flasher](https://github.com/qmk/qmk_flasher) instead, but for some advanced use cases FLIP is required.
## git
Versioning software used at the commandline
## GitHub
The website that hosts most of the QMK project. It provides integration with git, issue tracking, and other features that help us run QMK.
## ISP
In-system programming, a method of programming an AVR chip using external hardware and the JTAG pins.
## hid_listen
An interface for receiving debugging messages from your keyboard. You can view these messages using [QMK Flasher](https://github.com/qmk/qmk_flasher) or [PJRC's hid_listen](https://www.pjrc.com/teensy/hid_listen.html)
## Keycode
A 2-byte number that represents a particular key. `0x00`-`0xFF` are used for [Basic Keycodes](keycodes_basic.html) while `0x100`-`0xFFFF` are used for [Quantum Keycodes](quantum_keycodes.html).
## Key Down
An event that happens when a key is pressed down, but is completed before a key is released.
## Key Up
An event that happens when a key is released.
## Keymap
An array of keycodes mapped to a physical keyboard layout, which are processed on key presses and releases
## Layer
An abstraction used to allow a key to serve multiple purposes. The highest active layer takes precedence.
## Leader Key
A feature that allows you to tap the leader key followed by a sequence of 1, 2, or 3 keys to activate key presses or other quantum features.
* [Leader Key Documentation](feature_leader_key.html)
## LED
Light Emitting Diode, the most common device used for indicators on a keyboard.
## Make
Software package that is used to compile all the source files. You run `make` with various options to compile your keyboard firmware.
## Matrix
A wiring pattern of columns and rows that enables the MCU to detect keypresses with a fewer number of pins. The matrix often incorporates diodes to allow for NKRO.
## Macro
A feature that lets you send muiltple keypress events (hid reports) after having pressed only a single key.
* [Macro Documentation](macros.html)
## MCU
Microcontrol Unit, the processor that powers your keyboard.
## Modifier
A key that is held down while typing another key to modify the action of that key. Examples include Ctrl, Alt, and Shift.
## Mousekeys
A feature that lets you control your mouse cursor and click from your keyboard.
* [Mousekeys Documentation](mouse_keys.html)
## N-Key Rollover (NKRO)
A term that applies to keyboards that are capable of reporting any number of key-presses at once.
## Oneshot Modifier
A modifier that acts as if it is held down until another key is released, so you can press the mod and then press the key, rather than holding the mod while pressing the key.
## ProMicro
A low cost AVR development board. Clones of this device are often found on ebay very inexpensively (under $5) but people often struggle with flashing their pro micros.
## Pull Request
A request to submit code to QMK. We encourage all users to submit Pull Requests for their personal keymaps.
## QWERTY
The standard English keyboard layout, and often a shortcut for other language's standard layouts. Named for the first 6 letters on the keyboard.
## QWERTZ
The standard Deutsche (German) keyboard layout. Named for the first 6 letters on the keyboard.
## Rollover
The term for pressing a key while a key is already held down. Variants include 2KRO, 6KRO, and NKRO.
## Scancode
A 1 byte number that is sent as part of a HID report over USB that represents a single key. These numbers are documented in the [HID Usage Tables](http://www.usb.org/developers/hidpage/Hut1_12v2.pdf) published by the [USB-IF](http://www.usb.org/).
## Space Cadet Shift
A special set of shift keys which allow you to type various types of braces by tapping the left or right shift one or more times.
* [Space Cadet Shift Documentation](space_cadet_shift.html)
## Tap
Pressing and releasing a key. In some situations you will need to distinguish between a key down and a key up event, and Tap always refers to both at once.
## Tap Dance
A feature that lets you assign muiltple keycodes to the same key based on how many times you press it.
* [Tap Dance Documentation](tap_dance.md)
## Teensy
A low-cost AVR development board that is commonly used for hand-wired builds. A teensy is often chosen despite costing a few dollors more due to its halfkay bootloader, which makes flashing very simple.
## Underlight
A generic term for LEDs that light the underside of the board. These LED's typically shine away from the bottom of the PCB and towards the surface the keyboard rests on.
## Unicode
In the larger computer world Unicode is a set of encoding schemes for representing characters in any language. As it relates to QMK it means using various OS schemes to send unicode codepoints instead of scancodes.
* [Unicode Documentation](unicode.md)
## Unit Testing
A framework for running automated tests against QMK. Unit testing helps us be confident that our changes do not break anything.
* [Unit Testing Documentation](unit_testing.md)
## USB
Universal Serial Bus, the most common wired interface for a keyboard.
## USB Host (or simply Host)
The USB Host is your computer, or whatever device your keyboard is plugged into.
# Couldn't find the term you're looking for?
[Open an issue](https://github.com/qmk/qmk_firmware/issues) with your question and the term in question could be added here. Better still, open a pull request with the definition. :)

@ -1,4 +1,4 @@
# Quantum Hand-wiring Guide
# Quantum Hand-Wiring Guide
Parts list:
* *x* keyswitches (MX, Matias, Gateron, etc)
@ -6,12 +6,12 @@ Parts list:
* Keyboard plate (metal, plastic, cardboard, etc)
* Wire (strained for wiring to the Teensy, anything for the rows/columns)
* Soldering iron set at 600ºF or 315ºC (if temperature-controlled)
* Resin-cored solder (leaded or lead-free)
* Rosin-cored solder (leaded or lead-free)
* Adequate ventilation/a fan
* Tweezers (optional)
* Wire cutters/snippers
## How the matrix works (why we need diodes)
## How the Matrix Works (Why We Need Diodes)
The microcontroller (in this case, the Teensy 2.0) will be setup up via the firmware to send a logical 1 to the columns, one at a time, and read from the rows, all at once - this process is called matrix scanning. The matrix is a bunch of open switches that, by default, don't allow any current to pass through - the firmware will read this as no keys being pressed. As soon as you press one key down, the logical 1 that was coming from the column the keyswitch is attached to gets passed through the switch and to the corresponding row - check out the following 2x2 example:
@ -100,9 +100,9 @@ Things act as they should! Which will get us the following data:
The firmware can then use this correct data to detect what it should do, and eventually, what signals it needs to send to the OS.
# The actual hand-wiring
# The Actual Hand-Wiring
## Getting things in place
## Getting Things in Place
When starting this, you should have all of your stabilisers and keyswitches already installed (and optionally keycaps). If you're using a Cherry-type stabiliser (plate-mounted only, obviously), you'll need to install that before your keyswitches. If you're using Costar ones, you can installed them afterwards.
@ -112,7 +112,7 @@ Get your soldering iron heated-up and collect the rest of the materials from the
Before continuing, plan out where you're going to place your Teensy. If you're working with a board that has a large (6.25u) spacebar, it may be a good idea to place it in-between switches against the plate. Otherwise, you may want to trim some of the leads on the keyswitches where you plan on putting it - this will make it a little harder to solder the wire/diodes, but give you more room to place the Teensy.
## Preparing the diodes
## Preparing the Diodes
It's a little easier to solder the diodes in place if you bend them at a 90º angle immediately after the black line - this will help to make sure you put them on the right way (direction matters), and in the correct position. The diodes will look like this when bent (with longer leads):
@ -125,7 +125,7 @@ It's a little easier to solder the diodes in place if you bend them at a 90º an
We'll be using the long lead at the bent end to connect it to the elbow (bent part) of the next diode, creating the row.
## Soldering the diodes
## Soldering the Diodes
Starting at the top-left switch, place the diode (with tweezers if you have them) on the switch so that the diode itself is vertically aligned, and the black line is facing toward you. The straight end of the diode should be touching the left contact on the switch, and the bent end should be facing to the right and resting on the switch there, like this:
@ -133,7 +133,7 @@ Starting at the top-left switch, place the diode (with tweezers if you have them
│o
┌┴┐ o
│ │ O
├─┤
├─┤
└┬┘
└─────────────
```
@ -142,7 +142,7 @@ Letting the diode rest, grab your solder, and touch both it and the soldering ir
The smoke that the rosin releases is harmful, so be careful not to breath it or get it in your eyes/face.
After soldering things in place, it may be helpful to blow on the joint to push the smoke away from your face, and cool the solder quicker. You should see the solder develop a matte (not shiney) surface as it solidifies. Keep in mind that it will still be very hot afterwards, and will take a couple minutes to be cool to touch. Blow on it will accelerate this process.
After soldering things in place, it may be helpful to blow on the joint to push the smoke away from your face, and cool the solder quicker. You should see the solder develop a matte (not shiny) surface as it solidifies. Keep in mind that it will still be very hot afterwards, and will take a couple minutes to be cool to touch. Blow on it will accelerate this process.
When the first diode is complete, the next one will need to be soldered to both the keyswitch, and the previous diode at the new elbow. That will look something like this:
@ -150,7 +150,7 @@ When the first diode is complete, the next one will need to be soldered to both
│o │o
┌┴┐ o ┌┴┐ o
│ │ O │ │ O
├─┤ ├─┤
├─┤ ├─┤
└┬┘ └┬┘
└────────────────┴─────────────
```
@ -159,7 +159,7 @@ After completing a row, use the wire cutters to trim the excess wire from the to
When all of the diodes are completely soldered, it's a good idea to quickly inspect each one to ensure that your solder joints are solid and sturdy - repairing things after this is possible, but more difficult.
## Soldering the columns
## Soldering the Columns
You'll have some options in the next process - it's a good idea to insulate the column wires (since the diodes aren't), but if you're careful enough, you can use exposed wires for the columns - it's not recommended, though. If you're using single-cored wire, stripping the plastic off of the whole wire and feeding it back on is probably the best option, but can be difficult depending on the size and materials. You'll want to leave parts of the wire exposed where you're going to be solder it onto the keyswitch.
@ -169,7 +169,7 @@ Before beginning to solder, it helps to have your wire pre-bent (if using single
If you're not using any insulation, you can try to keep the column wires elevated, and solder them near the tips of the keyswitch contacts - if the wires are sturdy enough, they won't short out to the row wiring an diodes.
## Wiring things to the Teensy
## Wiring Things to the Teensy
Now that the matrix itself is complete, it's time to connect what you've done to the Teensy. You'll be needing the number of pins equal to your number of columns + your number of rows. There are some pins on the Teensy that are special, like D6 (the LED on the chip), or some of the UART, SPI, I2C, or PWM channels, but only avoid those if you're planning something in addition to a keyboard. If you're unsure about wanting to add something later, you should have enough pins in total to avoid a couple.
@ -185,7 +185,7 @@ When you're done with the columns, start with the rows in the same process, from
As you move along, be sure that the Teensy is staying in place - recutting and soldering the wires is a pain!
# Getting some basic firmware set-up
# Getting Some Basic Firmware Set Up
From here, you should have a working keyboard once you program a firmware. Before we attach the Teensy permanently to the keyboard, let's quickly get some firmware loaded onto the Teensy so we can test each keyswitch.
@ -201,13 +201,13 @@ You'll want to navigate to the `keyboards/<project_name>/` folder by typing, lik
cd keyboards/<project_name>
### config.h
### `config.h`
The first thing you're going to want to modify is the `config.h` file. Find `MATRIX_ROWS` and `MATRIX_COLS` and change their definitions to match the dimensions of your keyboard's matrix.
Farther down are `MATRIX_ROW_PINS` and `MATRIX_COL_PINS`. Change their definitions to match how you wired up your matrix (looking from the top of the keyboard, the rows run top-to-bottom and the columns run left-to-right). Likewise, change the definition of `UNUSED_PINS` to match the pins you did not use (this will save power).
### \<project_name\>.h
### `<project_name>.h`
The next file you'll want to look at is `<project_name>.h`. You're going to want to rewrite the `KEYMAP` definition - the format and syntax here is extremely important, so pay attention to how things are setup. The first half of the definition are considered the arguments - this is the format that you'll be following in your keymap later on, so you'll want to have as many k*xy* variables here as you do keys. The second half is the part that the firmware actually looks at, and will contain gaps depending on how you wired your matrix.
@ -271,7 +271,7 @@ This would require our `KEYMAP` definition to look like this:
Notice how the `k11` and `KC_NO` switched places to represent the wiring, and the unused final column on the bottom row. Sometimes it'll make more sense to put a keyswitch on a particular column, but in the end, it won't matter, as long as all of them are accounted for. You can use this process to write out the `KEYMAP` for your entire keyboard - be sure to remember that your keyboard is actually backwards when looking at the underside of it.
### keymaps/<variant>/default.c
### `keymaps/<variant>/default.c`
This is the actual keymap for your keyboard, and the main place you'll make changes as you perfect your layout. `default.c` is the file that gets pull by default when typing `make`, but you can make other files as well, and specify them by typing `make handwired/<keyboard>:<variant>`, which will pull `keymaps/<variant>/keymap.c`.
@ -302,7 +302,7 @@ Note that the layout of the keycodes is similar to the physical layout of our ke
It's also important to use the `KEYMAP` function we defined earlier - this is what allows the firmware to associate our intended readable keymap with the actual wiring.
## Compiling your firmware
## Compiling Your Firmware
After you've written out your entire keymap, you're ready to get the firmware compiled and onto your Teensy. Before compiling, you'll need to get your [development environment set-up](getting_started_build_tools.md) - you can skip the dfu-programmer instructions, but you'll need to download and install the [Teensy Loader](https://www.pjrc.com/teensy/loader.html) to get the firmware on your Teensy.
@ -310,7 +310,7 @@ Once everything is installed, running `make` in the terminal should get you some
Once you have your `<project_name>.hex` file, open up the Teensy loader application, and click the file icon. From here, navigate to your `QMK/keyboards/<project_name>/` folder, and select the `<project_name>.hex` file. Plug in your keyboard and press the button on the Teensy - you should see the LED on the device turn off once you do. The Teensy Loader app will change a little, and the buttons should be clickable - click the download button (down arrow), and then the reset button (right arrow), and your keyboard should be ready to go!
## Testing your firmware
## Testing Your Firmware
Carefully flip your keyboard over, open up a new text document, and try typing - you should get the characters that you put into your keymap. Test each key, and note the ones that aren't working. Here's a quick trouble-shooting guide for non-working keys:
@ -324,7 +324,7 @@ Carefully flip your keyboard over, open up a new text document, and try typing -
If you've done all of these things, keep in mind that sometimes you might have had multiple things affecting the keyswitch, so it doesn't hurt to test the keyswitch by shorting it out at the end.
# Securing the Teensy, finishing your hardware, getting fancier firmware
# Securing the Teensy, Finishing Your Hardware, Getting Fancier Firmware
Now that you have a working board, it's time to get things in their permanent positions. I've often used liberal amounts of hot glue to secure and insulate things, so if that's your style, start spreading that stuff like butter. Otherwise, double-sided tape is always an elegant solution, and electrical tape is a distant second. Due to the nature of these builds, a lot of this part is up to you and how you planned (or didn't plan) things out.

@ -0,0 +1,8 @@
# Hardware
QMK runs on a variety of hardware. If your processor can be targeted by [LUFA](http://www.fourwalledcubicle.com/LUFA.php) or [ChibiOS](http://www.chibios.com) you can probably get QMK running on it. This section explores getting QMK running on, and communicating with, hardware of all kinds.
* [Keyboard Guidelines](hardware_keyboard_guidelines.md)
* [AVR Processors](hardware_avr.md)
* ARM Processors (TBD)
* [Drivers](hardware_drivers.md)

@ -0,0 +1,157 @@
# Keyboards with AVR Processors
This page describes the support for for AVR processors in QMK. AVR processors include the atmega32u4, atmega32u2, at90usb1286, and other processors from Atmel Corporation. AVR processors are 8-bit MCU's that are designed to be easy to work with. The most common AVR processors in keyboards have on-board USB and plenty of GPIO for supporting large keyboard matrices. They are the most popular MCU for use in keyboards today.
If you have not yet you should read the [Keyboard Guidelines](hardware_keyboard_guidelines.md) to get a sense of how keyboards fit into QMK.
## Adding Your AVR Keyboard to QMK
QMK has a number of features to simplify working with AVR keyboards. For most keyboards you don't have to write a single line of code. To get started run the `util/new_project.sh` script:
```
$ util/new_project.sh my_awesome_keyboard
######################################################
# /keyboards/my_awesome_keyboard project created. To start
# working on things, cd into keyboards/my_awesome_keyboard
######################################################
```
This will create all the files needed to support your new keyboard, and populate the settings with default values. Now you just need to customize it for your keyboard.
## `readme.md`
This is where you'll describe your keyboard. Please follow the [Keyboard Readme Template](documentation_templates.md#keyboard-readmemd-template) when writing your `readme.md`. You're encouraged to place an image at the top of your `readme.md`, please use an external service such as [Imgur](http://imgur.com) to host the images.
## `<keyboard>.c`
This is where all the custom logic for your keyboard goes. Many keyboards do not need to put anything at all in here. You can learn more about writing custom logic in [Custom Quantum Functions](custom_quantum_functions.md).
## `<keyboard>.h`
This is the file you define your [Layout Macro(s)](feature_layouts.md) in. At minimum you should have a `#define LAYOUT` for your keyboard that looks something like this:
```
#define LAYOUT( \
k00, k01, k02, \
k10, k11 \
) { \
{ k00, k01, k02 }, \
{ k10, KC_NO, k11 }, \
}
```
The first half of the `LAYOUT` pre-processor macro defines the physical arrangement of keys. The second half of the macro defines the matrix the switches are connected to. This allows you to have a physical arrangement of keys that differs from the wiring matrix.
Each of the `k__` variables needs to be unique, and typically they follow the format `k<row><col>`.
The physical matrix (the second half) must have a number of rows equaling `MATRIX_ROWS`, and each row must have exactly `MATRIX_COLS` elements in it. If you do not have this many physical keys you can use `KC_NO` to fill in the blank spots.
## `config.h`
The `config.h` file is where you configure the hardware and feature set for your keyboard. There are a lot of options that can be placed in that file, too many to list there. For a complete overview of available options see the [Config Options](config_options.md) page.
### Hardware Configuration
At the top of the `config.h` you'll find USB related settings. These control how your keyboard appears to the Operating System. If you don't have a good reason to change you should leave the `VENDOR_ID` as `0xFEED`. For the `PRODUCT_ID` you should pick a number that is not yet in use.
Do change the `MANUFACTURER`, `PRODUCT`, and `DESCRIPTION` lines to accurately reflect your keyboard.
```
#define VENDOR_ID 0xFEED
#define PRODUCT_ID 0x6060
#define DEVICE_VER 0x0001
#define MANUFACTURER You
#define PRODUCT my_awesome_keyboard
#define DESCRIPTION A custom keyboard
```
{% hint style='info' %}
Note: On Windows and macOS the `MANUFACTURER`, `PRODUCT`, and `DESCRIPTION` fields will be displayed in the list of USB devices. On Linux these values will not be visible in `lsusb`, since Linux takes that information from the list published by the USB-IF.
{% endhint %}
### Keyboard Matrix Configuration
The next section of the `config.h` file deals with your keyboard's matrix. The first thing you should set is the matrix's size. This is usually, but not always, the same number of rows and columns as the physical key arrangement.
```
#define MATRIX_ROWS 2
#define MATRIX_COLS 3
```
Once you've defined the size of your matrix you need to define which pins on your MCU are connected to rows and columns. To do so simply specify the names of those pins:
```
#define MATRIX_ROW_PINS { D0, D5 }
#define MATRIX_COL_PINS { F1, F0, B0 }
#define UNUSED_PINS
```
The number of `MATRIX_ROW_PINS` entries must be the same as the number you assigned to `MATRIX_ROWS`, and likewise for `MATRIX_COL_PINS` and `MATRIX_COLS`. You do not have to specify `UNUSED_PINS`, but you can if you want to document what pins are open.
Finally, you can specify the direction your diodes point. This can be `COL2ROW`, `ROW2COL`, or `CUSTOM_MATRIX`.
```
#define DIODE_DIRECTION COL2ROW
```
### Backlight Configuration
By default QMK supports backlighting on pins `B5`, `B6`, and `B7`. If you are using one of those you can simply enable it here. For more details see the [Backlight Documentation](feature_backlight.md).
```
#define BACKLIGHT_PIN B7
#define BACKLIGHT_LEVELS 3
#define BACKLIGHT_BREATHING
#define BREATHING_PERIOD 6
```
{% hint style='info' %}
You can use backlighting on any pin you like, but you will have to do more work to support that. See the [Backlight Documentation](feature_backlight.md) for more details.
{% endhint %}
### Other Configuration Options
There are a lot of features that can be configured or tuned in `config.h`. You should see the [Config Options](config_options.md) page for more details.
## `rules.mk`
You use the `rules.mk` file to tell QMK what files to build and what features to enable. If you are building around an atmega32u4 you can largely leave these defaults alone. If you are using another MCU you may have to tweak some parameters.
### MCU Options
These options tell the build system what CPU to build for. Be very careful if you change any of these settings, you can render your keyboard inoperable.
```
MCU = atmega32u4
F_CPU = 16000000
ARCH = AVR8
F_USB = $(F_CPU)
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
```
### Bootloader Size
The bootloader is a special section of your MCU that allows you to upgrade the code stored on the MCU. Think of it like a Rescue Partition for your keyboard. If you are using a teensy 2.0, or a device like the Ergodox EZ that uses the teensy bootloader you should set this to `512`. Most other bootloaders should be set to `4096`, but `1024` and `2048` are other possible values you may encounter.
#### Teensy 2.0 Bootloader Example
```
OPT_DEFS += -DBOOTLOADER_SIZE=512
```
#### Teensy 2.0++ Bootloader Example
```
OPT_DEFS += -DBOOTLOADER_SIZE=1024
```
#### Atmel DFU Loader Example
```
OPT_DEFS += -DBOOTLOADER_SIZE=4096
```
### Build Options
There are a number of features that can be turned on or off in `rules.mk`. See the [Config Options](config_options.md#feature-options) page for a detailed list and description.

@ -0,0 +1,27 @@
# QMK Hardware Drivers
QMK is used on a lot of different hardware. While support for the most common MCU's and matrix configurations is built-in there are a number of drivers that can be added to a keyboard to support additional hardware. Examples include mice and other pointing devices, i/o expanders for split keyboards, bluetooth modules, and LCD, OLED, and TFT screens.
<!-- FIXME: This should talk about how drivers are integrated into QMK and how you can add your own driver.
# Driver System Overview
-->
# Available Drivers
## ProMicro (AVR Only)
Support for addressing pins on the ProMicro by their Arduino name rather than their AVR name. This needs to be better documented, if you are trying to do this and reading the code doesn't help please [open an issue](https://github.com/qmk/qmk_firmware/issues/new) and we can help you through the process.
## SSD1306 (AVR Only)
Support for SSD1306 based OLED displays. This needs to be better documented, if you are trying to do this and reading the code doesn't help please [open an issue](https://github.com/qmk/qmk_firmware/issues/new) and we can help you through the process.
## uGFX
You can make use of uGFX within QMK to drive character and graphic LCD's, LED arrays, OLED, TFT, and other display technologies. This needs to be better documented, if you are trying to do this and reading the code doesn't help please [open an issue](https://github.com/qmk/qmk_firmware/issues/new) and we can help you through the process.
## WS2812 (AVR Only)
Support for WS2811/WS2812{a,b,c} LED's. For more information see the [RGB Light](feature_rgblight.md) page.

@ -0,0 +1,146 @@
# QMK Keyboard Guidelines
We welcome all keyboard projects into QMK, but ask that you try to stick to a couple guidelines that help us keep things organised and consistent.
## Naming Your Keyboard/Project
All names should be lowercase alphanumeric, and separated by an underscore (`_`), but not begin with one. Your directory and your `.h` and `.c` files should have exactly the same name. All folders should follow the same format. `test`, `keyboard`, and `all` are reserved by make and are not a valid name for a keyboard.
## `readme.md`
All projects need to have a `readme.md` file that explains what the keyboard is, who made it, where it is available, and links to more information. Please follow the [published template](documentation_templates.md#keyboard-readmemd-template).
## Image/Hardware Files
In an effort to keep the repo size down, we're no longer accepting images of any format in the repo, with few exceptions. Hosting them elsewhere (imgur) and linking them in the `readme.md` is the preferred method.
Any sort of hardware file (plate, case, pcb) can't be stored in qmk_firmware, but we have the [qmk.fm repo](https://github.com/qmk/qmk.fm) where such files (as well as in-depth info) can be stored and viewed on [qmk.fm](http://qmk.fm). Downloadable files are stored in `/<keyboard>/` (name follows the same format as above) which are served at `http://qmk.fm/<keyboard>/`, and pages are generated from `/_pages/<keyboard>/` which are served at the same location (.md files are generated into .html files through Jekyll). Check out the `lets_split` directory for an example.
## Keyboard Defaults
Given the amount of functionality that QMK exposes it's very easy to confuse new users. When putting together the default firmware for your keyboard we recommend limiting your enabled features and options to the minimal set needed to support your hardware. Recommendations for specific features follow.
### Bootmagic and Command
[Bootmagic](feature_bootmagic.md) and [Command](feature_command.md) are two related features that allow a user to control their keyboard in non-obvious ways. We recommend you think long and hard about if you're going to enable either feature, and how you will expose this functionality. Keep in mind that users who want this functionality can enable it in their personal keymaps without affecting all the novice users who may be using your keyboard as their first programmable board.
By far the most common problem new users encounter is accidentally triggering Bootmagic while they're plugging in their keyboard. They're holding the keyboard by the bottom, unknowingly pressing in alt and spacebar, and then they find that these keys have been swapped on them. We recommend leaving this feature disabled by default, but if you do turn it on consider setting `BOOTMAGIC_KEY_SALT` to a key that is hard to press while plugging your keyboard in.
If your keyboard does not have 2 shift keys you should provide a working default for `IS_COMMAND`, even when you have set `COMMAND_ENABLE = no`. This will give your users a default to conform to if they do enable Command.
## Custom Keyboard Programming
As documented on [Customizing Functionality](custom_quantum_functions.md) you can define custom functions for your keyboard. Please keep in mind that your users may want to customize that behavior as well, and make it possible for them to do that. If you are providing a custom function, for example `process_record_kb()`, make sure that your function calls the `_user()` version of the call too. You should also take into account the return value of the `_user()` version, and only run your custom code if the user returns `true`.
## Keyboard Metadata
As QMK grows so does the ecosystem surrounding QMK. To make it easier for projects in that ecosystem to tie into QMK as we make changes we are developing a metadata system to expose information about keyboards in QMK.
You can create `info.json` files at every level under `qmk_firmware/keyboards/<name>` to specify this metadata. These files are combined, with more specific files overriding keys in less specific files. This means you do not need to duplicate your metadata information. For example, `qmk_firmware/keyboards/clueboard/info.json` specifies `manufacturer` and `maintainer`, while `qmk_firmware/keyboards/clueboard/66/info.json` specifies more specific information about Clueboard 66%.
### `info.json` Format
The `info.json` file is a JSON formatted dictionary with the following keys available to be set. You do not have to set all of them, merely the keys that apply to your keyboard.
* `keyboard_name`
* A free-form text string describing the keyboard.
* Example: `Clueboard 66%`
* `url`
* A URL to the keyboard's product page, [QMK.fm/keyboards](https://qmk.fm/keyboards) page, or other page describing information about the keyboard.
* `bootloader`
* What bootloader this keyboard uses. Available options:
* `atmel-dfu`
* `kiibohd-dfu-util`
* `lufa-dfu`
* `qmk-dfu`
* `stm32-dfu-util`
* `caterina`
* `halfkay`
* `bootloadHID`
* `maintainer`
* GitHub username of the maintainer, or `qmk` for community maintained boards
* `width`
* Width of the board in Key Units
* `height`
* Height of the board in Key Units
* `layouts`
* Physical Layout representations. See the next section for more detail.
#### Layout Format
Within our `info.json` file the `layouts` portion of the dictionary contains several nested dictionaries. The outer layer consists of QMK layout macros, for example `LAYOUT_ansi` or `LAYOUT_iso`. Within each layout macro are keys for `width`, `height`, and `key_count`, each of which should be self-explanatory.
* `width`
* Optional: The width of the layout in Key Units
* `height`
* Optional: The height of the layout in Key Units
* `key_count`
* **Required**: The number of keys in this layout
* `layout`
* A list of Key Dictionaries describing the physical layout. See the next section for more details.
#### Key Dictionary Format
Each Key Dictionary in a layout describes the physical properties of a key. If you are familiar with the Raw Code for <http://keyboard-layout-editor.com> you will find many of the concepts the same. We re-use the same key names and layout choices wherever possible, but unlike keyboard-layout-editor each key is stateless, inheriting no properties from the keys that came before it.
All key positions and rotations are specified in relation to the top-left corner of the keyboard, and the top-left corner of each key.
* `X`
* **Required**: The absolute position of the key in the horizontal axis, in Key Units.
* `Y`
* **Required**: The absolute position of the key in the vertical axis, in Key Units.
* `W`
* The width of the key, in Key Units. Ignored if `ks` is provided. Default: `1`
* `H`
* The height of the key, in Key Units. Ignored if `ks` is provided. Default: `1`
* `R`
* How many degrees clockwise to rotate the key.
* `RX`
* The absolute position of the point to rotate the key around in the horizontal axis. Default: `x`
* `RY`
* The absolute position of the point to rotate the key around in the vertical axis. Default: `y`
* `KS`
* Key Shape: define a polygon by providing a list of points, in Key Units.
* **Important**: These are relative to the top-left of the key, not absolute.
* Example ISO Enter: `[ [0,0], [1.5,0], [1.5,2], [0.25,2], [0.25,1], [0,1], [0,0] ]`
### How is the Metadata Exposed?
This metadata is primarily used in two ways:
* To allow web-based configurators to dynamically generate UI
* To support the new `make keyboard:keymap:qmk` target, which bundles this metadata up with the firmware to allow QMK Toolbox to be smarter.
Configurator authors can see the [QMK Compiler](https://docs.compile.qmk.fm/api_docs.html) docs for more information on using the JSON API.
## Non-Production/Handwired Projects
We're happy to accept any project that uses QMK, including prototypes and handwired ones, but we have a separate `/keyboards/handwired/` folder for them, so the main `/keyboards/` folder doesn't get overcrowded. If a prototype project becomes a production project at some point in the future, we'd be happy to move it to the main `/keyboards/` folder!
## Warnings as Errors
When developing your keyboard, keep in mind that all warnings will be treated as errors - these small warnings can build-up and cause larger errors down the road (and keeping them is generally a bad practice).
## Copyright Blurb
If you're adapting your keyboard's setup from another project, but not using the same code, but sure to update the copyright header at the top of the files to show your name, in this format:
Copyright 2017 Your Name <your@email.com>
If you are modifying someone else's code and have made only trivial changes you should leave their name in the copyright statement. If you have done significant work on the file you should add your name to theirs, like so:
Copyright 2017 Their Name <original_author@example.com> Your Name <you@example.com>
The year should be the first year the file is created. If work was done to that file in later years you can reflect that by appending the second year to the first, like so:
Copyright 2015-2017 Your Name <you@example.com>
## License
The core of QMK is licensed under the [GNU General Public License](https://www.gnu.org/licenses/licenses.en.html). If you are shipping binaries for AVR processors you may choose either [GPLv2](https://www.gnu.org/licenses/old-licenses/gpl-2.0.html) or [GPLv3](https://www.gnu.org/licenses/gpl.html). If you are shipping binaries for ARM processors you must choose [GPL Version 3](https://www.gnu.org/licenses/gpl.html) to comply with the [ChibiOS](http://www.chibios.org) GPLv3 license.
If your keyboard makes use of the [uGFX](https://ugfx.io) features within QMK you must comply with the [uGFX License](https://ugfx.io/license.html), which requires a separate commercial license before selling a device containing uGFX.
## Technical Details
If you're looking for more information on making your keyboard work with QMK, [check out the hardware section](hardware.md)!

@ -1,10 +1,10 @@
# How keys are registered, and interpreted by computers
# How Keys Are Registered, and Interpreted by Computers
In this file, you can will learn the concepts of how keyboards work over USB,
and you'll be able to better understand what you can expect from changing your
firmware directly.
## Schematic view
## Schematic View
Whenever you type on 1 particular key, here is the chain of actions taking
place:
@ -49,7 +49,7 @@ layout is set to QWERTY, a sample of the matching table is as follow:
| 0x1D | z/Z |
| ... | ... |
## Back to the firmware
## Back to the Firmware
As the layout is generally fixed (unless you create your own), the firmware can actually call a keycode by its layout name directly to ease things for you. This is exactly what is done here with `KC_A` actually representing `0x04` in QWERTY. The full list can be found in [keycodes](keycodes.md).

@ -0,0 +1,78 @@
# group `defines` {#group__defines}
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`define `[`SYSEX_BEGIN`](#group__defines_1ga1a3c39bb790dda8a368c4247caabcf79) |
`define `[`SYSEX_END`](#group__defines_1ga753706d1d28e6f96d7caf1973e80feed) |
`define `[`MIDI_STATUSMASK`](#group__defines_1gab78a1c818a5f5dab7a8946543f126c69) |
`define `[`MIDI_CHANMASK`](#group__defines_1ga239edc0a6f8405d3a8f2804f1590b909) |
`define `[`MIDI_CC`](#group__defines_1ga45f116a1daab76b3c930c2cecfaef215) |
`define `[`MIDI_NOTEON`](#group__defines_1gafd416f27bf3590868c0c1f55c30be4c7) |
`define `[`MIDI_NOTEOFF`](#group__defines_1gabed24bea2d989fd655e2ef2ad0765adc) |
`define `[`MIDI_AFTERTOUCH`](#group__defines_1ga3a322d8cfd53576a2e167c1840551b0f) |
`define `[`MIDI_PITCHBEND`](#group__defines_1gabcc799504e8064679bca03f232223af4) |
`define `[`MIDI_PROGCHANGE`](#group__defines_1gaefb3f1595ffbb9db66b46c2c919a3d42) |
`define `[`MIDI_CHANPRESSURE`](#group__defines_1gaeb3281cc7fcd0daade8ed3d2dfc33dbe) |
`define `[`MIDI_CLOCK`](#group__defines_1gafa5e4e295aafd15ab7893344599b3b89) |
`define `[`MIDI_TICK`](#group__defines_1ga3b99408ff864613765d4c3c2ceb52aa7) |
`define `[`MIDI_START`](#group__defines_1ga8233631c85823aa546f932ad8975caa4) |
`define `[`MIDI_CONTINUE`](#group__defines_1gab24430f0081e27215b0da84dd0ee745c) |
`define `[`MIDI_STOP`](#group__defines_1ga3af9271d4b1f0d22904a0b055f48cf62) |
`define `[`MIDI_ACTIVESENSE`](#group__defines_1gacd88ed42dba52bb4b2052c5656362677) |
`define `[`MIDI_RESET`](#group__defines_1ga02947f30ca62dc332fdeb10c5868323b) |
`define `[`MIDI_TC_QUARTERFRAME`](#group__defines_1gaaa072f33590e236d1bfd8f28e833ae31) |
`define `[`MIDI_SONGPOSITION`](#group__defines_1ga412f6ed33a2150051374bee334ee1705) |
`define `[`MIDI_SONGSELECT`](#group__defines_1gafcab254838b028365ae0259729e72c4e) |
`define `[`MIDI_TUNEREQUEST`](#group__defines_1ga8100b907b8c0a84e58b1c53dcd9bd795) |
`define `[`SYSEX_EDUMANUFID`](#group__defines_1ga5ef855ed955b00a2239ca16afbeb164f) |
## Members
#### `define `[`SYSEX_BEGIN`](#group__defines_1ga1a3c39bb790dda8a368c4247caabcf79) {#group__defines_1ga1a3c39bb790dda8a368c4247caabcf79}
#### `define `[`SYSEX_END`](#group__defines_1ga753706d1d28e6f96d7caf1973e80feed) {#group__defines_1ga753706d1d28e6f96d7caf1973e80feed}
#### `define `[`MIDI_STATUSMASK`](#group__defines_1gab78a1c818a5f5dab7a8946543f126c69) {#group__defines_1gab78a1c818a5f5dab7a8946543f126c69}
#### `define `[`MIDI_CHANMASK`](#group__defines_1ga239edc0a6f8405d3a8f2804f1590b909) {#group__defines_1ga239edc0a6f8405d3a8f2804f1590b909}
#### `define `[`MIDI_CC`](#group__defines_1ga45f116a1daab76b3c930c2cecfaef215) {#group__defines_1ga45f116a1daab76b3c930c2cecfaef215}
#### `define `[`MIDI_NOTEON`](#group__defines_1gafd416f27bf3590868c0c1f55c30be4c7) {#group__defines_1gafd416f27bf3590868c0c1f55c30be4c7}
#### `define `[`MIDI_NOTEOFF`](#group__defines_1gabed24bea2d989fd655e2ef2ad0765adc) {#group__defines_1gabed24bea2d989fd655e2ef2ad0765adc}
#### `define `[`MIDI_AFTERTOUCH`](#group__defines_1ga3a322d8cfd53576a2e167c1840551b0f) {#group__defines_1ga3a322d8cfd53576a2e167c1840551b0f}
#### `define `[`MIDI_PITCHBEND`](#group__defines_1gabcc799504e8064679bca03f232223af4) {#group__defines_1gabcc799504e8064679bca03f232223af4}
#### `define `[`MIDI_PROGCHANGE`](#group__defines_1gaefb3f1595ffbb9db66b46c2c919a3d42) {#group__defines_1gaefb3f1595ffbb9db66b46c2c919a3d42}
#### `define `[`MIDI_CHANPRESSURE`](#group__defines_1gaeb3281cc7fcd0daade8ed3d2dfc33dbe) {#group__defines_1gaeb3281cc7fcd0daade8ed3d2dfc33dbe}
#### `define `[`MIDI_CLOCK`](#group__defines_1gafa5e4e295aafd15ab7893344599b3b89) {#group__defines_1gafa5e4e295aafd15ab7893344599b3b89}
#### `define `[`MIDI_TICK`](#group__defines_1ga3b99408ff864613765d4c3c2ceb52aa7) {#group__defines_1ga3b99408ff864613765d4c3c2ceb52aa7}
#### `define `[`MIDI_START`](#group__defines_1ga8233631c85823aa546f932ad8975caa4) {#group__defines_1ga8233631c85823aa546f932ad8975caa4}
#### `define `[`MIDI_CONTINUE`](#group__defines_1gab24430f0081e27215b0da84dd0ee745c) {#group__defines_1gab24430f0081e27215b0da84dd0ee745c}
#### `define `[`MIDI_STOP`](#group__defines_1ga3af9271d4b1f0d22904a0b055f48cf62) {#group__defines_1ga3af9271d4b1f0d22904a0b055f48cf62}
#### `define `[`MIDI_ACTIVESENSE`](#group__defines_1gacd88ed42dba52bb4b2052c5656362677) {#group__defines_1gacd88ed42dba52bb4b2052c5656362677}
#### `define `[`MIDI_RESET`](#group__defines_1ga02947f30ca62dc332fdeb10c5868323b) {#group__defines_1ga02947f30ca62dc332fdeb10c5868323b}
#### `define `[`MIDI_TC_QUARTERFRAME`](#group__defines_1gaaa072f33590e236d1bfd8f28e833ae31) {#group__defines_1gaaa072f33590e236d1bfd8f28e833ae31}
#### `define `[`MIDI_SONGPOSITION`](#group__defines_1ga412f6ed33a2150051374bee334ee1705) {#group__defines_1ga412f6ed33a2150051374bee334ee1705}
#### `define `[`MIDI_SONGSELECT`](#group__defines_1gafcab254838b028365ae0259729e72c4e) {#group__defines_1gafcab254838b028365ae0259729e72c4e}
#### `define `[`MIDI_TUNEREQUEST`](#group__defines_1ga8100b907b8c0a84e58b1c53dcd9bd795) {#group__defines_1ga8100b907b8c0a84e58b1c53dcd9bd795}
#### `define `[`SYSEX_EDUMANUFID`](#group__defines_1ga5ef855ed955b00a2239ca16afbeb164f) {#group__defines_1ga5ef855ed955b00a2239ca16afbeb164f}

@ -0,0 +1,169 @@
# group `input_callback_reg` {#group__input__callback__reg}
These are the functions you use to register your input callbacks.
The functions are called when the appropriate midi message is matched on the associated device's input.
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`public void `[`midi_register_cc_callback`](#group__input__callback__reg_1ga64ab672abbbe393c9c4a83110c8df718)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` | Register a control change message (cc) callback.
`public void `[`midi_register_noteon_callback`](#group__input__callback__reg_1ga3962f276c17618923f1152779552103e)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` | Register a note on callback.
`public void `[`midi_register_noteoff_callback`](#group__input__callback__reg_1gac847b66051bd6d53b762958be0ec4c6d)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` | Register a note off callback.
`public void `[`midi_register_aftertouch_callback`](#group__input__callback__reg_1gaa95bc901bd9edff956a667c9a69dd01f)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` | Register an after touch callback.
`public void `[`midi_register_pitchbend_callback`](#group__input__callback__reg_1ga071a28f02ba14f53de219be70ebd9a48)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` | Register a pitch bend callback.
`public void `[`midi_register_songposition_callback`](#group__input__callback__reg_1gaf2adfd79637f3553d8f26deb1ca22ed6)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` | Register a song position callback.
`public void `[`midi_register_progchange_callback`](#group__input__callback__reg_1gae6ba1a35a4cde9bd15dd42f87401d127)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` | Register a program change callback.
`public void `[`midi_register_chanpressure_callback`](#group__input__callback__reg_1ga39b31f1f4fb93917ce039b958f21b4f5)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` | Register a channel pressure callback.
`public void `[`midi_register_songselect_callback`](#group__input__callback__reg_1gaf9aafc76a2dc4b9fdbb4106cbda6ce72)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` | Register a song select callback.
`public void `[`midi_register_tc_quarterframe_callback`](#group__input__callback__reg_1ga0a119fada2becc628cb15d753b257e6e)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` | Register a tc quarter frame callback.
`public void `[`midi_register_realtime_callback`](#group__input__callback__reg_1ga764f440e857b89084b1a07f9da2ff93a)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_one_byte_func_t func)` | Register a realtime callback.
`public void `[`midi_register_tunerequest_callback`](#group__input__callback__reg_1gae40ff3ce20bda79fef87da24b8321cb1)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_one_byte_func_t func)` | Register a tune request callback.
`public void `[`midi_register_sysex_callback`](#group__input__callback__reg_1ga63ce9631b025785c1848d0122d4c4c48)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_sysex_func_t func)` | Register a sysex callback.
`public void `[`midi_register_fallthrough_callback`](#group__input__callback__reg_1ga7ed189164aa9682862b3181153afbd94)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_var_byte_func_t func)` | Register fall through callback.
`public void `[`midi_register_catchall_callback`](#group__input__callback__reg_1ga9dbfed568d047a6cd05708f11fe39e99)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_var_byte_func_t func)` | Register a catch all callback.
## Members
#### `public void `[`midi_register_cc_callback`](#group__input__callback__reg_1ga64ab672abbbe393c9c4a83110c8df718)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` {#group__input__callback__reg_1ga64ab672abbbe393c9c4a83110c8df718}
Register a control change message (cc) callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_noteon_callback`](#group__input__callback__reg_1ga3962f276c17618923f1152779552103e)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` {#group__input__callback__reg_1ga3962f276c17618923f1152779552103e}
Register a note on callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_noteoff_callback`](#group__input__callback__reg_1gac847b66051bd6d53b762958be0ec4c6d)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` {#group__input__callback__reg_1gac847b66051bd6d53b762958be0ec4c6d}
Register a note off callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_aftertouch_callback`](#group__input__callback__reg_1gaa95bc901bd9edff956a667c9a69dd01f)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` {#group__input__callback__reg_1gaa95bc901bd9edff956a667c9a69dd01f}
Register an after touch callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_pitchbend_callback`](#group__input__callback__reg_1ga071a28f02ba14f53de219be70ebd9a48)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` {#group__input__callback__reg_1ga071a28f02ba14f53de219be70ebd9a48}
Register a pitch bend callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_songposition_callback`](#group__input__callback__reg_1gaf2adfd79637f3553d8f26deb1ca22ed6)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_three_byte_func_t func)` {#group__input__callback__reg_1gaf2adfd79637f3553d8f26deb1ca22ed6}
Register a song position callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_progchange_callback`](#group__input__callback__reg_1gae6ba1a35a4cde9bd15dd42f87401d127)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` {#group__input__callback__reg_1gae6ba1a35a4cde9bd15dd42f87401d127}
Register a program change callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_chanpressure_callback`](#group__input__callback__reg_1ga39b31f1f4fb93917ce039b958f21b4f5)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` {#group__input__callback__reg_1ga39b31f1f4fb93917ce039b958f21b4f5}
Register a channel pressure callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_songselect_callback`](#group__input__callback__reg_1gaf9aafc76a2dc4b9fdbb4106cbda6ce72)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` {#group__input__callback__reg_1gaf9aafc76a2dc4b9fdbb4106cbda6ce72}
Register a song select callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_tc_quarterframe_callback`](#group__input__callback__reg_1ga0a119fada2becc628cb15d753b257e6e)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_two_byte_func_t func)` {#group__input__callback__reg_1ga0a119fada2becc628cb15d753b257e6e}
Register a tc quarter frame callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_realtime_callback`](#group__input__callback__reg_1ga764f440e857b89084b1a07f9da2ff93a)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_one_byte_func_t func)` {#group__input__callback__reg_1ga764f440e857b89084b1a07f9da2ff93a}
Register a realtime callback.
The callback will be called for all of the real time message types.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_tunerequest_callback`](#group__input__callback__reg_1gae40ff3ce20bda79fef87da24b8321cb1)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_one_byte_func_t func)` {#group__input__callback__reg_1gae40ff3ce20bda79fef87da24b8321cb1}
Register a tune request callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_sysex_callback`](#group__input__callback__reg_1ga63ce9631b025785c1848d0122d4c4c48)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_sysex_func_t func)` {#group__input__callback__reg_1ga63ce9631b025785c1848d0122d4c4c48}
Register a sysex callback.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_fallthrough_callback`](#group__input__callback__reg_1ga7ed189164aa9682862b3181153afbd94)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_var_byte_func_t func)` {#group__input__callback__reg_1ga7ed189164aa9682862b3181153afbd94}
Register fall through callback.
This is only called if a more specific callback is not matched and called. For instance, if you don't register a note on callback but you get a note on message the fall through callback will be called, if it is registered.
#### Parameters
* `device` the device associate with
* `func` the callback function to register
#### `public void `[`midi_register_catchall_callback`](#group__input__callback__reg_1ga9dbfed568d047a6cd05708f11fe39e99)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_var_byte_func_t func)` {#group__input__callback__reg_1ga9dbfed568d047a6cd05708f11fe39e99}
Register a catch all callback.
If registered, the catch all callback is called for every message that is matched, even if a more specific or the fallthrough callback is registered.
#### Parameters
* `device` the device associate with
* `func` the callback function to register

@ -0,0 +1,143 @@
# group `midi_device` {#group__midi__device}
You use the functions when you are implementing your own midi device.
You set a send function to actually send bytes via your device, this method is called when you call a send function with this device, for instance midi_send_cc
You use the midi_device_input to process input data from the device and pass it through the device's associated callbacks.
You use the midi_device_set_pre_input_process_func if you want to have a function called at the beginning of the device's process function, generally to poll for input and pass that into midi_device_input
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`define `[`MIDI_INPUT_QUEUE_LENGTH`](#group__midi__device_1ga4aaa419caebdca2bbdfc1331e79781a8) |
`enum `[`input_state_t`](#group__midi__device_1gac203e877d3df4275ceb8e7180a61f621) |
`public void `[`midi_device_input`](#group__midi__device_1gad8d3db8eb35d9cfa51ef036a0a9d70db)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t cnt,uint8_t * input)` | Process input bytes. This function parses bytes and calls the appropriate callbacks associated with the given device. You use this function if you are creating a custom device and you want to have midi input.
`public void `[`midi_device_set_send_func`](#group__midi__device_1ga59f5a46bdd4452f186cc73d9e96d4673)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_var_byte_func_t send_func)` | Set the callback function that will be used for sending output data bytes. This is only used if you're creating a custom device. You'll most likely want the callback function to disable interrupts so that you can call the various midi send functions without worrying about locking.
`public void `[`midi_device_set_pre_input_process_func`](#group__midi__device_1ga4de0841b87c04fc23cb56b6451f33b69)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_no_byte_func_t pre_process_func)` | Set a callback which is called at the beginning of the midi_device_process call. This can be used to poll for input data and send the data through the midi_device_input function. You'll probably only use this if you're creating a custom device.
`struct `[`_midi_device`](docs/api_midi_device.md#struct__midi__device) | This structure represents the input and output functions and processing data for a midi device.
## Members
#### `define `[`MIDI_INPUT_QUEUE_LENGTH`](#group__midi__device_1ga4aaa419caebdca2bbdfc1331e79781a8) {#group__midi__device_1ga4aaa419caebdca2bbdfc1331e79781a8}
#### `enum `[`input_state_t`](#group__midi__device_1gac203e877d3df4275ceb8e7180a61f621) {#group__midi__device_1gac203e877d3df4275ceb8e7180a61f621}
Values | Descriptions
--------------------------------|---------------------------------------------
IDLE |
ONE_BYTE_MESSAGE |
TWO_BYTE_MESSAGE |
THREE_BYTE_MESSAGE |
SYSEX_MESSAGE |
#### `public void `[`midi_device_input`](#group__midi__device_1gad8d3db8eb35d9cfa51ef036a0a9d70db)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t cnt,uint8_t * input)` {#group__midi__device_1gad8d3db8eb35d9cfa51ef036a0a9d70db}
Process input bytes. This function parses bytes and calls the appropriate callbacks associated with the given device. You use this function if you are creating a custom device and you want to have midi input.
#### Parameters
* `device` the midi device to associate the input with
* `cnt` the number of bytes you are processing
* `input` the bytes to process
#### `public void `[`midi_device_set_send_func`](#group__midi__device_1ga59f5a46bdd4452f186cc73d9e96d4673)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_var_byte_func_t send_func)` {#group__midi__device_1ga59f5a46bdd4452f186cc73d9e96d4673}
Set the callback function that will be used for sending output data bytes. This is only used if you're creating a custom device. You'll most likely want the callback function to disable interrupts so that you can call the various midi send functions without worrying about locking.
#### Parameters
* `device` the midi device to associate this callback with
* `send_func` the callback function that will do the sending
#### `public void `[`midi_device_set_pre_input_process_func`](#group__midi__device_1ga4de0841b87c04fc23cb56b6451f33b69)`(`[`MidiDevice`](#struct__midi__device)` * device,midi_no_byte_func_t pre_process_func)` {#group__midi__device_1ga4de0841b87c04fc23cb56b6451f33b69}
Set a callback which is called at the beginning of the midi_device_process call. This can be used to poll for input data and send the data through the midi_device_input function. You'll probably only use this if you're creating a custom device.
#### Parameters
* `device` the midi device to associate this callback with
* `midi_no_byte_func_t` the actual callback function
# struct `_midi_device` {#struct__midi__device}
This structure represents the input and output functions and processing data for a midi device.
A device can represent an actual physical device [serial port, usb port] or something virtual. You should not need to modify this structure directly.
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`public midi_var_byte_func_t `[`send_func`](docs/api_midi_device.md#struct__midi__device_1a25d4c94b4bbccd5b98f1032b469f3ff9) |
`public midi_three_byte_func_t `[`input_cc_callback`](docs/api_midi_device.md#struct__midi__device_1a6da5236c1bc73877728df92d213a78d1) |
`public midi_three_byte_func_t `[`input_noteon_callback`](docs/api_midi_device.md#struct__midi__device_1aa10b15cf1a7fb825a5df0d2abbe34a1c) |
`public midi_three_byte_func_t `[`input_noteoff_callback`](docs/api_midi_device.md#struct__midi__device_1aaf290043078534d3a5a0ea4c840eba84) |
`public midi_three_byte_func_t `[`input_aftertouch_callback`](docs/api_midi_device.md#struct__midi__device_1acb0b4901c545cec4b28b126f2d8c315f) |
`public midi_three_byte_func_t `[`input_pitchbend_callback`](docs/api_midi_device.md#struct__midi__device_1a305fea672caeb996f2233bf8cd2bef18) |
`public midi_three_byte_func_t `[`input_songposition_callback`](docs/api_midi_device.md#struct__midi__device_1a5f3f13638b3fef3fc561ed1bf301d586) |
`public midi_two_byte_func_t `[`input_progchange_callback`](docs/api_midi_device.md#struct__midi__device_1adaf1da617c9a10a9dcad00ab1959d3da) |
`public midi_two_byte_func_t `[`input_chanpressure_callback`](docs/api_midi_device.md#struct__midi__device_1ab7ca2925c539915d43974eff604d85f7) |
`public midi_two_byte_func_t `[`input_songselect_callback`](docs/api_midi_device.md#struct__midi__device_1a89bed8a5a55376120cfc0a62b42f057f) |
`public midi_two_byte_func_t `[`input_tc_quarterframe_callback`](docs/api_midi_device.md#struct__midi__device_1ad9813e75d22e284f9f65a907d20600f0) |
`public midi_one_byte_func_t `[`input_realtime_callback`](docs/api_midi_device.md#struct__midi__device_1a9448eba4afb7e43650434748db3777be) |
`public midi_one_byte_func_t `[`input_tunerequest_callback`](docs/api_midi_device.md#struct__midi__device_1a0cb8fd53e00cf1d4202d4fa04d038e8d) |
`public midi_sysex_func_t `[`input_sysex_callback`](docs/api_midi_device.md#struct__midi__device_1afff9a0ce641762aaef24c1e6953ec9a2) |
`public midi_var_byte_func_t `[`input_fallthrough_callback`](docs/api_midi_device.md#struct__midi__device_1abb974ec6d734001b4a0e370f292be503) |
`public midi_var_byte_func_t `[`input_catchall_callback`](docs/api_midi_device.md#struct__midi__device_1aae0d535129d4fd650edc98eb3f7584f8) |
`public midi_no_byte_func_t `[`pre_input_process_callback`](docs/api_midi_device.md#struct__midi__device_1aeb0bb8923d66c23d874e177dc4265754) |
`public uint8_t `[`input_buffer`](docs/api_midi_device.md#struct__midi__device_1a7c5684857d6af4ebc4dc12da27bd6b2a) |
`public input_state_t `[`input_state`](docs/api_midi_device.md#struct__midi__device_1a69a687d2d1c449ec15a11c07a5722e39) |
`public uint16_t `[`input_count`](docs/api_midi_device.md#struct__midi__device_1a68dea8e7b6151e89c85c95caa612ee5d) |
`public uint8_t `[`input_queue_data`](docs/api_midi_device.md#struct__midi__device_1ada41de021135dc423abedcbb30f366ff) |
`public `[`byteQueue_t`](#structbyte_queue__t)` `[`input_queue`](#struct__midi__device_1a49c8538a8a02193c58e28a56eb695d8f) |
## Members
#### `public midi_var_byte_func_t `[`send_func`](docs/api_midi_device.md#struct__midi__device_1a25d4c94b4bbccd5b98f1032b469f3ff9) {#struct__midi__device_1a25d4c94b4bbccd5b98f1032b469f3ff9}
#### `public midi_three_byte_func_t `[`input_cc_callback`](docs/api_midi_device.md#struct__midi__device_1a6da5236c1bc73877728df92d213a78d1) {#struct__midi__device_1a6da5236c1bc73877728df92d213a78d1}
#### `public midi_three_byte_func_t `[`input_noteon_callback`](docs/api_midi_device.md#struct__midi__device_1aa10b15cf1a7fb825a5df0d2abbe34a1c) {#struct__midi__device_1aa10b15cf1a7fb825a5df0d2abbe34a1c}
#### `public midi_three_byte_func_t `[`input_noteoff_callback`](docs/api_midi_device.md#struct__midi__device_1aaf290043078534d3a5a0ea4c840eba84) {#struct__midi__device_1aaf290043078534d3a5a0ea4c840eba84}
#### `public midi_three_byte_func_t `[`input_aftertouch_callback`](docs/api_midi_device.md#struct__midi__device_1acb0b4901c545cec4b28b126f2d8c315f) {#struct__midi__device_1acb0b4901c545cec4b28b126f2d8c315f}
#### `public midi_three_byte_func_t `[`input_pitchbend_callback`](docs/api_midi_device.md#struct__midi__device_1a305fea672caeb996f2233bf8cd2bef18) {#struct__midi__device_1a305fea672caeb996f2233bf8cd2bef18}
#### `public midi_three_byte_func_t `[`input_songposition_callback`](docs/api_midi_device.md#struct__midi__device_1a5f3f13638b3fef3fc561ed1bf301d586) {#struct__midi__device_1a5f3f13638b3fef3fc561ed1bf301d586}
#### `public midi_two_byte_func_t `[`input_progchange_callback`](docs/api_midi_device.md#struct__midi__device_1adaf1da617c9a10a9dcad00ab1959d3da) {#struct__midi__device_1adaf1da617c9a10a9dcad00ab1959d3da}
#### `public midi_two_byte_func_t `[`input_chanpressure_callback`](docs/api_midi_device.md#struct__midi__device_1ab7ca2925c539915d43974eff604d85f7) {#struct__midi__device_1ab7ca2925c539915d43974eff604d85f7}
#### `public midi_two_byte_func_t `[`input_songselect_callback`](docs/api_midi_device.md#struct__midi__device_1a89bed8a5a55376120cfc0a62b42f057f) {#struct__midi__device_1a89bed8a5a55376120cfc0a62b42f057f}
#### `public midi_two_byte_func_t `[`input_tc_quarterframe_callback`](docs/api_midi_device.md#struct__midi__device_1ad9813e75d22e284f9f65a907d20600f0) {#struct__midi__device_1ad9813e75d22e284f9f65a907d20600f0}
#### `public midi_one_byte_func_t `[`input_realtime_callback`](docs/api_midi_device.md#struct__midi__device_1a9448eba4afb7e43650434748db3777be) {#struct__midi__device_1a9448eba4afb7e43650434748db3777be}
#### `public midi_one_byte_func_t `[`input_tunerequest_callback`](docs/api_midi_device.md#struct__midi__device_1a0cb8fd53e00cf1d4202d4fa04d038e8d) {#struct__midi__device_1a0cb8fd53e00cf1d4202d4fa04d038e8d}
#### `public midi_sysex_func_t `[`input_sysex_callback`](docs/api_midi_device.md#struct__midi__device_1afff9a0ce641762aaef24c1e6953ec9a2) {#struct__midi__device_1afff9a0ce641762aaef24c1e6953ec9a2}
#### `public midi_var_byte_func_t `[`input_fallthrough_callback`](docs/api_midi_device.md#struct__midi__device_1abb974ec6d734001b4a0e370f292be503) {#struct__midi__device_1abb974ec6d734001b4a0e370f292be503}
#### `public midi_var_byte_func_t `[`input_catchall_callback`](docs/api_midi_device.md#struct__midi__device_1aae0d535129d4fd650edc98eb3f7584f8) {#struct__midi__device_1aae0d535129d4fd650edc98eb3f7584f8}
#### `public midi_no_byte_func_t `[`pre_input_process_callback`](docs/api_midi_device.md#struct__midi__device_1aeb0bb8923d66c23d874e177dc4265754) {#struct__midi__device_1aeb0bb8923d66c23d874e177dc4265754}
#### `public uint8_t `[`input_buffer`](docs/api_midi_device.md#struct__midi__device_1a7c5684857d6af4ebc4dc12da27bd6b2a) {#struct__midi__device_1a7c5684857d6af4ebc4dc12da27bd6b2a}
#### `public input_state_t `[`input_state`](docs/api_midi_device.md#struct__midi__device_1a69a687d2d1c449ec15a11c07a5722e39) {#struct__midi__device_1a69a687d2d1c449ec15a11c07a5722e39}
#### `public uint16_t `[`input_count`](docs/api_midi_device.md#struct__midi__device_1a68dea8e7b6151e89c85c95caa612ee5d) {#struct__midi__device_1a68dea8e7b6151e89c85c95caa612ee5d}
#### `public uint8_t `[`input_queue_data`](docs/api_midi_device.md#struct__midi__device_1ada41de021135dc423abedcbb30f366ff) {#struct__midi__device_1ada41de021135dc423abedcbb30f366ff}
#### `public `[`byteQueue_t`](#structbyte_queue__t)` `[`input_queue`](#struct__midi__device_1a49c8538a8a02193c58e28a56eb695d8f) {#struct__midi__device_1a49c8538a8a02193c58e28a56eb695d8f}

@ -0,0 +1,31 @@
# group `midi_device_setup_process` {#group__midi__device__setup__process}
These are method that you must use to initialize and run a device.
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`public void `[`midi_device_init`](#group__midi__device__setup__process_1gaf29deddc94ea98a59daa0bde1aefd9d9)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Initialize a device.
`public void `[`midi_device_process`](#group__midi__device__setup__process_1gaa3d5993d0e998a1b59bbf5ab9c7b492b)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Process input data.
## Members
#### `public void `[`midi_device_init`](#group__midi__device__setup__process_1gaf29deddc94ea98a59daa0bde1aefd9d9)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__midi__device__setup__process_1gaf29deddc94ea98a59daa0bde1aefd9d9}
Initialize a device.
You must call this before using the device in question.
#### Parameters
* `device` the device to initialize
#### `public void `[`midi_device_process`](#group__midi__device__setup__process_1gaa3d5993d0e998a1b59bbf5ab9c7b492b)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__midi__device__setup__process_1gaa3d5993d0e998a1b59bbf5ab9c7b492b}
Process input data.
This method drives the input processing, you must call this method frequently if you expect to have your input callbacks called.
#### Parameters
* `device` the device to process

@ -0,0 +1,54 @@
# group `midi_util` {#group__midi__util}
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`enum `[`midi_packet_length_t`](#group__midi__util_1gae29ff56aee2b430ffe53933b97e5e79e) | An enumeration of the possible packet length values.
`public bool `[`midi_is_statusbyte`](#group__midi__util_1ga12e3b42ff9cbb4b4f2bc455fc8743ee5)`(uint8_t theByte)` | Test to see if the byte given is a status byte.
`public bool `[`midi_is_realtime`](#group__midi__util_1gad2f52c363e34a8000d80c983c324e2d7)`(uint8_t theByte)` | Test to see if the byte given is a realtime message.
`public `[`midi_packet_length_t`](#group__midi__util_1gae29ff56aee2b430ffe53933b97e5e79e)` `[`midi_packet_length`](#group__midi__util_1gaa168b43af6ae9de0debce1625e4b8175)`(uint8_t status)` | Find the length of the packet associated with the status byte given.
## Members
#### `enum `[`midi_packet_length_t`](#group__midi__util_1gae29ff56aee2b430ffe53933b97e5e79e) {#group__midi__util_1gae29ff56aee2b430ffe53933b97e5e79e}
Values | Descriptions
--------------------------------|---------------------------------------------
UNDEFINED |
ONE |
TWO |
THREE |
An enumeration of the possible packet length values.
#### `public bool `[`midi_is_statusbyte`](#group__midi__util_1ga12e3b42ff9cbb4b4f2bc455fc8743ee5)`(uint8_t theByte)` {#group__midi__util_1ga12e3b42ff9cbb4b4f2bc455fc8743ee5}
Test to see if the byte given is a status byte.
#### Parameters
* `theByte` the byte to test
#### Returns
true if the byte given is a midi status byte
#### `public bool `[`midi_is_realtime`](#group__midi__util_1gad2f52c363e34a8000d80c983c324e2d7)`(uint8_t theByte)` {#group__midi__util_1gad2f52c363e34a8000d80c983c324e2d7}
Test to see if the byte given is a realtime message.
#### Parameters
* `theByte` the byte to test
#### Returns
true if it is a realtime message, false otherwise
#### `public `[`midi_packet_length_t`](#group__midi__util_1gae29ff56aee2b430ffe53933b97e5e79e)` `[`midi_packet_length`](#group__midi__util_1gaa168b43af6ae9de0debce1625e4b8175)`(uint8_t status)` {#group__midi__util_1gaa168b43af6ae9de0debce1625e4b8175}
Find the length of the packet associated with the status byte given.
#### Parameters
* `status` the status byte
#### Returns
the length of the packet, will return UNDEFINED if the byte is not a status byte or if it is a sysex status byte

@ -0,0 +1,241 @@
# group `send_functions` {#group__send__functions}
These are the functions you use to send midi data through a device.
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`public void `[`midi_send_cc`](#group__send__functions_1gaaf884811c92df405ca8fe1a00082f960)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num,uint8_t val)` | Send a control change message (cc) via the given device.
`public void `[`midi_send_noteon`](#group__send__functions_1ga467bcf46dbf03ec269ce565b46bc2775)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num,uint8_t vel)` | Send a note on message via the given device.
`public void `[`midi_send_noteoff`](#group__send__functions_1gaedb7d8805425eef5d47d57ddcb4c7a49)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num,uint8_t vel)` | Send a note off message via the given device.
`public void `[`midi_send_aftertouch`](#group__send__functions_1ga0014847571317a0e34b2ef46a6bc584f)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t note_num,uint8_t amt)` | Send an after touch message via the given device.
`public void `[`midi_send_pitchbend`](#group__send__functions_1gae5a4a1e71611e7534be80af9ce3d3491)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,int16_t amt)` | Send a pitch bend message via the given device.
`public void `[`midi_send_programchange`](#group__send__functions_1ga7b15588ef25e5e1ff09c2afc3151ce86)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num)` | Send a program change message via the given device.
`public void `[`midi_send_channelpressure`](#group__send__functions_1gaf23e69fdf812e89c0036f51f88ab2e1b)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t amt)` | Send a channel pressure message via the given device.
`public void `[`midi_send_clock`](#group__send__functions_1ga4e1b11a7cdb0875f6e03ce7c79c581aa)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a clock message via the given device.
`public void `[`midi_send_tick`](#group__send__functions_1ga2b43c7d433d940c5b907595aac947972)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a tick message via the given device.
`public void `[`midi_send_start`](#group__send__functions_1ga1569749a8d58ccc56789289d7c7245cc)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a start message via the given device.
`public void `[`midi_send_continue`](#group__send__functions_1gaed5dc29d754a27372e89ab8bc20ee120)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a continue message via the given device.
`public void `[`midi_send_stop`](#group__send__functions_1ga026e1a620276cb653ac501aa0d12a988)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a stop message via the given device.
`public void `[`midi_send_activesense`](#group__send__functions_1ga9b6e4c6ce4719d2604187b325620db37)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send an active sense message via the given device.
`public void `[`midi_send_reset`](#group__send__functions_1ga3671e39a6d93ca9568fc493001af1b1b)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a reset message via the given device.
`public void `[`midi_send_tcquarterframe`](#group__send__functions_1ga5b85639910eec280bb744c934d0fd45a)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t time)` | Send a tc quarter frame message via the given device.
`public void `[`midi_send_songposition`](#group__send__functions_1gab1c9eeef3b57a8cd2e6128d18e85eb7f)`(`[`MidiDevice`](#struct__midi__device)` * device,uint16_t pos)` | Send a song position message via the given device.
`public void `[`midi_send_songselect`](#group__send__functions_1ga42de7838ba70d949af9a50f9facc3c50)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t song)` | Send a song select message via the given device.
`public void `[`midi_send_tunerequest`](#group__send__functions_1ga8db6c7e04d48e4d2266dd59118ca0656)`(`[`MidiDevice`](#struct__midi__device)` * device)` | Send a tune request message via the given device.
`public void `[`midi_send_byte`](#group__send__functions_1ga857e85eb90b288385642d4d991e09881)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t b)` | Send a byte via the given device.
`public void `[`midi_send_data`](#group__send__functions_1ga36e2f2e45369d911b76969361679054b)`(`[`MidiDevice`](#struct__midi__device)` * device,uint16_t count,uint8_t byte0,uint8_t byte1,uint8_t byte2)` | Send up to 3 bytes of data.
`public void `[`midi_send_array`](#group__send__functions_1ga245243cb1da18d2cea18d4b18d846ead)`(`[`MidiDevice`](#struct__midi__device)` * device,uint16_t count,uint8_t * array)` | Send an array of formatted midi data.
## Members
#### `public void `[`midi_send_cc`](#group__send__functions_1gaaf884811c92df405ca8fe1a00082f960)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num,uint8_t val)` {#group__send__functions_1gaaf884811c92df405ca8fe1a00082f960}
Send a control change message (cc) via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `num` the cc num
* `val` the value of that cc num
#### `public void `[`midi_send_noteon`](#group__send__functions_1ga467bcf46dbf03ec269ce565b46bc2775)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num,uint8_t vel)` {#group__send__functions_1ga467bcf46dbf03ec269ce565b46bc2775}
Send a note on message via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `num` the note number
* `vel` the note velocity
#### `public void `[`midi_send_noteoff`](#group__send__functions_1gaedb7d8805425eef5d47d57ddcb4c7a49)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num,uint8_t vel)` {#group__send__functions_1gaedb7d8805425eef5d47d57ddcb4c7a49}
Send a note off message via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `num` the note number
* `vel` the note velocity
#### `public void `[`midi_send_aftertouch`](#group__send__functions_1ga0014847571317a0e34b2ef46a6bc584f)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t note_num,uint8_t amt)` {#group__send__functions_1ga0014847571317a0e34b2ef46a6bc584f}
Send an after touch message via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `note_num` the note number
* `amt` the after touch amount
#### `public void `[`midi_send_pitchbend`](#group__send__functions_1gae5a4a1e71611e7534be80af9ce3d3491)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,int16_t amt)` {#group__send__functions_1gae5a4a1e71611e7534be80af9ce3d3491}
Send a pitch bend message via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `amt` the bend amount range: -8192..8191, 0 means no bend
#### `public void `[`midi_send_programchange`](#group__send__functions_1ga7b15588ef25e5e1ff09c2afc3151ce86)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t num)` {#group__send__functions_1ga7b15588ef25e5e1ff09c2afc3151ce86}
Send a program change message via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `num` the program to change to
#### `public void `[`midi_send_channelpressure`](#group__send__functions_1gaf23e69fdf812e89c0036f51f88ab2e1b)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t chan,uint8_t amt)` {#group__send__functions_1gaf23e69fdf812e89c0036f51f88ab2e1b}
Send a channel pressure message via the given device.
#### Parameters
* `device` the device to use for sending
* `chan` the channel to send on, 0-15
* `amt` the amount of channel pressure
#### `public void `[`midi_send_clock`](#group__send__functions_1ga4e1b11a7cdb0875f6e03ce7c79c581aa)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga4e1b11a7cdb0875f6e03ce7c79c581aa}
Send a clock message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_tick`](#group__send__functions_1ga2b43c7d433d940c5b907595aac947972)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga2b43c7d433d940c5b907595aac947972}
Send a tick message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_start`](#group__send__functions_1ga1569749a8d58ccc56789289d7c7245cc)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga1569749a8d58ccc56789289d7c7245cc}
Send a start message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_continue`](#group__send__functions_1gaed5dc29d754a27372e89ab8bc20ee120)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1gaed5dc29d754a27372e89ab8bc20ee120}
Send a continue message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_stop`](#group__send__functions_1ga026e1a620276cb653ac501aa0d12a988)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga026e1a620276cb653ac501aa0d12a988}
Send a stop message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_activesense`](#group__send__functions_1ga9b6e4c6ce4719d2604187b325620db37)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga9b6e4c6ce4719d2604187b325620db37}
Send an active sense message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_reset`](#group__send__functions_1ga3671e39a6d93ca9568fc493001af1b1b)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga3671e39a6d93ca9568fc493001af1b1b}
Send a reset message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_tcquarterframe`](#group__send__functions_1ga5b85639910eec280bb744c934d0fd45a)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t time)` {#group__send__functions_1ga5b85639910eec280bb744c934d0fd45a}
Send a tc quarter frame message via the given device.
#### Parameters
* `device` the device to use for sending
* `time` the time of this quarter frame, range 0..16383
#### `public void `[`midi_send_songposition`](#group__send__functions_1gab1c9eeef3b57a8cd2e6128d18e85eb7f)`(`[`MidiDevice`](#struct__midi__device)` * device,uint16_t pos)` {#group__send__functions_1gab1c9eeef3b57a8cd2e6128d18e85eb7f}
Send a song position message via the given device.
#### Parameters
* `device` the device to use for sending
* `pos` the song position
#### `public void `[`midi_send_songselect`](#group__send__functions_1ga42de7838ba70d949af9a50f9facc3c50)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t song)` {#group__send__functions_1ga42de7838ba70d949af9a50f9facc3c50}
Send a song select message via the given device.
#### Parameters
* `device` the device to use for sending
* `song` the song to select
#### `public void `[`midi_send_tunerequest`](#group__send__functions_1ga8db6c7e04d48e4d2266dd59118ca0656)`(`[`MidiDevice`](#struct__midi__device)` * device)` {#group__send__functions_1ga8db6c7e04d48e4d2266dd59118ca0656}
Send a tune request message via the given device.
#### Parameters
* `device` the device to use for sending
#### `public void `[`midi_send_byte`](#group__send__functions_1ga857e85eb90b288385642d4d991e09881)`(`[`MidiDevice`](#struct__midi__device)` * device,uint8_t b)` {#group__send__functions_1ga857e85eb90b288385642d4d991e09881}
Send a byte via the given device.
This is a generic method for sending data via the given midi device. This would be useful for sending sysex data or messages that are not implemented in this API, if there are any. Please contact the author if you find some so we can add them.
#### Parameters
* `device` the device to use for sending
* `b` the byte to send
#### `public void `[`midi_send_data`](#group__send__functions_1ga36e2f2e45369d911b76969361679054b)`(`[`MidiDevice`](#struct__midi__device)` * device,uint16_t count,uint8_t byte0,uint8_t byte1,uint8_t byte2)` {#group__send__functions_1ga36e2f2e45369d911b76969361679054b}
Send up to 3 bytes of data.
% 4 is applied to count so that you can use this to pass sysex through
#### Parameters
* `device` the device to use for sending
* `count` the count of bytes to send, %4 is applied
* `byte0` the first byte
* `byte1` the second byte, ignored if cnt % 4 != 2
* `byte2` the third byte, ignored if cnt % 4 != 3
#### `public void `[`midi_send_array`](#group__send__functions_1ga245243cb1da18d2cea18d4b18d846ead)`(`[`MidiDevice`](#struct__midi__device)` * device,uint16_t count,uint8_t * array)` {#group__send__functions_1ga245243cb1da18d2cea18d4b18d846ead}
Send an array of formatted midi data.
Can be used for sysex.
#### Parameters
* `device` the device to use for sending
* `count` the count of bytes to send
* `array` the array of bytes

@ -0,0 +1,61 @@
# group `sysex_tools` {#group__sysex__tools}
## Summary
Members | Descriptions
--------------------------------|---------------------------------------------
`public uint16_t `[`sysex_encoded_length`](#group__sysex__tools_1ga061e5607030412d6e62e2390d8013f0a)`(uint16_t decoded_length)` | Compute the length of a message after it is encoded.
`public uint16_t `[`sysex_decoded_length`](#group__sysex__tools_1ga121fc227d3acc1c0ea08c9a5c26fa3b0)`(uint16_t encoded_length)` | Compute the length of a message after it is decoded.
`public uint16_t `[`sysex_encode`](#group__sysex__tools_1ga54d77f8d32f92a6f329daefa2b314742)`(uint8_t * encoded,const uint8_t * source,uint16_t length)` | Encode data so that it can be transmitted safely in a sysex message.
`public uint16_t `[`sysex_decode`](#group__sysex__tools_1gaaad1d9ba2d5eca709a0ab4ba40662229)`(uint8_t * decoded,const uint8_t * source,uint16_t length)` | Decode encoded data.
## Members
#### `public uint16_t `[`sysex_encoded_length`](#group__sysex__tools_1ga061e5607030412d6e62e2390d8013f0a)`(uint16_t decoded_length)` {#group__sysex__tools_1ga061e5607030412d6e62e2390d8013f0a}
Compute the length of a message after it is encoded.
#### Parameters
* `decoded_length` The length, in bytes, of the message to encode.
#### Returns
The length, in bytes, of the message after encodeing.
#### `public uint16_t `[`sysex_decoded_length`](#group__sysex__tools_1ga121fc227d3acc1c0ea08c9a5c26fa3b0)`(uint16_t encoded_length)` {#group__sysex__tools_1ga121fc227d3acc1c0ea08c9a5c26fa3b0}
Compute the length of a message after it is decoded.
#### Parameters
* `encoded_length` The length, in bytes, of the encoded message.
#### Returns
The length, in bytes, of the message after it is decoded.
#### `public uint16_t `[`sysex_encode`](#group__sysex__tools_1ga54d77f8d32f92a6f329daefa2b314742)`(uint8_t * encoded,const uint8_t * source,uint16_t length)` {#group__sysex__tools_1ga54d77f8d32f92a6f329daefa2b314742}
Encode data so that it can be transmitted safely in a sysex message.
#### Parameters
* `encoded` The output data buffer, must be at least sysex_encoded_length(length) bytes long.
* `source` The input buffer of data to be encoded.
* `length` The number of bytes from the input buffer to encode.
#### Returns
number of bytes encoded.
#### `public uint16_t `[`sysex_decode`](#group__sysex__tools_1gaaad1d9ba2d5eca709a0ab4ba40662229)`(uint8_t * decoded,const uint8_t * source,uint16_t length)` {#group__sysex__tools_1gaaad1d9ba2d5eca709a0ab4ba40662229}
Decode encoded data.
#### Parameters
* `decoded` The output data buffer, must be at least sysex_decoded_length(length) bytes long.
* `source` The input buffer of data to be decoded.
* `length` The number of bytes from the input buffer to decode.
#### Returns
number of bytes decoded.

@ -17,11 +17,11 @@ If you're having trouble flashing/erasing your board, and running into cryptic e
atmel.c:1434: Error flashing the block: err -2.
ERROR
Memory write error, use debug for more info.
commands.c:360: Error writing memory data. (err -4)
commands.c:360: Error writing memory data. (err -4)
You're likely going to need to ISP flash your board/device to get it working again. Luckily, this process is pretty straight-forward, provided you have any extra programmable keyboard, Arduino, or Teensy 2.0/Teensy 2.0++. There are also dedicated ISP flashers available for this, but most cost >$15, and it's assumed that if you are googling this error, this is the first you've heard about ISP flashing, and don't have one readily available (whereas you might have some other AVR board). __We'll be using a Teensy 2.0 with Windows 10 in this guide__ - if you are comfortable doing this on another system, please consider editing this guide and contributing those instructions!
## Software needed
## Software Needed
* [The Arduino IDE](https://www.arduino.cc/en/Main/Software)
* [Teensyduino](https://www.pjrc.com/teensy/td_download.html) (if you're using a Teensy)
@ -37,8 +37,8 @@ This is pretty straight-forward - we'll be connecting like-things to like-things
Flasher B3 <-> Keyboard B3 (MISO)
Flasher VCC <-> Keyboard VCC
Flasher GND <-> Keyboard GND
## The ISP firmware
## The ISP Firmware
Make sure your keyboard is unplugged from any device, and plug in your Teensy.
@ -51,31 +51,31 @@ Then scroll down until you see something that looks like this block of code:
// Configure which pins to use:
// The standard pin configuration.
#ifndef ARDUINO_HOODLOADER2
#ifndef ARDUINO_HOODLOADER2
#define RESET 0 // Use 0 (B0) instead of 10
#define LED_HB 11 // Use 11 (LED on the Teensy 2.0)
#define LED_ERR 8 // This won't be used unless you have an LED hooked-up to 8 (D3)
#define LED_PMODE 7 // This won't be used unless you have an LED hooked-up to 7 (D2)
And make the changes in the last four lines. If you're using something besides the Teenys 2.0, you'll want to choose something else that makes sense for `LED_HB`. We define `RESET` as `0`/`B0` because that's what's close - if you want to use another pin for some reason, [you can use the pinouts to choose something else](https://www.pjrc.com/teensy/pinout.html).
Once you've made your changes, you can click the Upload button (right arrow), which will open up the Teensy flasher app - you'll need to press the reset button on the Teensy the first time, but after that, it's automatic (you shouldn't be flashing this more than once, though). Once flashed, the orange LED on the Teensy will flash on and off, indicating it's ready for some action.
And make the changes in the last four lines. If you're using something besides the Teensy 2.0, you'll want to choose something else that makes sense for `LED_HB`. We define `RESET` as `0`/`B0` because that's what's close - if you want to use another pin for some reason, [you can use the pinouts to choose something else](https://www.pjrc.com/teensy/pinout.html).
Once you've made your changes, you can click the Upload button (right arrow), which will open up the Teensy flasher app - you'll need to press the reset button on the Teensy the first time, but after that, it's automatic (you shouldn't be flashing this more than once, though). Once flashed, the orange LED on the Teensy will flash on and off, indicating it's ready for some action.
## The .hex file
## The `.hex` File
Before flashing your firmware, you're going to need to and do a little preparation. We'll be appending [this bootloader (also a .hex file)](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32u4_1_0_0.hex) to the end of our firmware by opening the original .hex file in a text editor, and removing the last line, which should be `:00000001FF` (this is an EOF message). After that's been removed, copy the entire bootloader's contents and paste it at the end of the original file, and save it.
Before flashing your firmware, you're going to need to and do a little preparation. We'll be appending [this bootloader (also a .hex file)](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32u4_1_0_0.hex) to the end of our firmware by opening the original .hex file in a text editor, and removing the last line, which should be `:00000001FF` (this is an EOF message). After that's been removed, copy the entire bootloader's contents and paste it at the end of the original file, and save it.
It's possible to use other bootloaders here in the same way, but __you need a bootloader__, otherwise you'll have to ISP to write new firmware to your keyboard.
## Flashing your firmware
## Flashing Your Firmware
Make sure your keyboard is unplugged from any device, and plug in your Teensy.
Open `cmd` and navigate to your where your modified .hex file is. We'll pretend this file is called `main.hex`, and that your Teensy 2.0 is on the `COM3` port - if you're unsure, you can open your Device Manager, and look for `Ports > USB Serial Device`. Use that COM port here. You can confirm it's the right port with:
avrdude -c avrisp -P COM3 -p atmega32u4
and you should get something like the following output:
avrdude: AVR device initialized and ready to accept instructions
@ -90,8 +90,8 @@ and you should get something like the following output:
Since our keyboard uses an `atmega32u4` (common), that is the chip we'll specify. This is the full command:
avrdude -c avrisp -P COM3 -p atmega32u4 -U flash:w:main.hex:i
avrdude -c avrisp -P COM3 -p atmega32u4 -U flash:w:main.hex:i
You should see a couple of progress bars, then you should see:
avrdude: verifying ...
@ -100,7 +100,7 @@ You should see a couple of progress bars, then you should see:
avrdude: safemode: Fuses OK
avrdude done. Thank you.
Which means everything should be ok! Your board may restart automatically, otherwise, unplug your Teensy and plug in your keyboard - you can leave your Teensy wired to your keyboard while testing things, but it's recommended that you desolder it/remove the wiring once you're sure everything works.
If you have any questions/problems, feel free to [open an issue](https://github.com/qmk/qmk_firmware/issues/new)!

@ -1,11 +0,0 @@
## Key Lock: Holding down keys for you
Sometimes, you need to hold down a specific key for a long period of time. Whether this is while typing in ALL CAPS, or playing a video game that hasn't implemented auto-run, Key Lock is here to help. Key Lock adds a new keycode, `KC_LOCK`, that will hold down the next key you hit for you. The key is released when you hit it again. Here's an example: let's say you need to type in all caps for a few sentences. You hit KC_LOCK, and then shift. Now, shift will be considered held until you hit it again. You can think of key lock as caps lock, but supercharged.
Here's how to use it:
1. Pick a key on your keyboard. This will be the key lock key. Assign it the keycode `KC_LOCK`. This will be a single-action key: you won't be able to use it for anything else.
2. Enable key lock by including `KEY_LOCK_ENABLE = yes` in your Makefile.
3. That's it!
Important: switching layers does not cancel the key lock. Additionally, key lock is only able to hold standard action keys and One Shot modifier keys (for example, if you have your shift defined as `OSM(KC_LSFT)`; see [One Shot Keys](quantum_keycodes.md#one-shot-keys)). This does not include any of the QMK special functions (except One Shot modifiers), or shifted versions of keys such as KC_LPRN. If it's in the [basic_keycodes](basic_keycodes.md) list, it can be held. If it's not, then it can't be.

@ -183,7 +183,7 @@ KC_RSHIFT KC_RSFT E5 Keyboard RightShift
KC_RALT E6 Keyboard RightAlt
KC_RGUI E7 Keyboard Right GUI(Windows/Apple/Meta key)
/*
/*
* Virtual keycodes
*/
/* System Control */

@ -1,315 +1,405 @@
# Overview
When defining a [keymap](keymap.md) each key needs a valid key definition. This page documents the symbols that correspond to keycodes that are available to you in QMK. This is a reference only. Where possible keys link to the page documenting their functionality.
## Keycode Index
|Long Name|Short Name|Description|
|---------|----------|-----------|
|`KC_1`||||
|`KC_2`||||
|`KC_3`||||
|`KC_4`||||
|`KC_5`||||
|`KC_6`||||
|`KC_7`||||
|`KC_8`||||
|`KC_9`||||
|`KC_0`||||
|`KC_F1`||||
|`KC_F2`||||
|`KC_F3`||||
|`KC_F4`||||
|`KC_F5`||||
|`KC_F6`||||
|`KC_F7`||||
|`KC_F8`||||
|`KC_F9`||||
|`KC_F10`||||
|`KC_F11`||||
|`KC_F12`||||
|`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_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_U`||||
|`KC_V`||||
|`KC_W`||||
|`KC_X`||||
|`KC_Y`||||
|`KC_Z`||||
|`KC_ENTER`|`KC_ENT`|`Return (ENTER)`|
|`KC_ESCAPE`|`KC_ESC`|`ESCAPE`|
|`KC_BSPACE`|`KC_BSPC`|`DELETE (Backspace)`|
|`KC_TAB`||`Tab`|
|`KC_SPACE`|`KC_SPC`|Spacebar|
|`KC_MINUS`|`KC_MINS`|`-` and `_`|
|`KC_EQUAL`|`KC_EQL`|`=` and `+`|
|`KC_LBRACKET`|`KC_LBRC`|`[` and `{`|
|`KC_RBRACKET`|`KC_RBRC`|`]` and `}`|
|`KC_BSLASH`|`KC_BSLS`|`\` and <code>&#124;</code> |
|`KC_NONUS_HASH`|`KC_NUHS`|Non-US `#` and `~`|
|`KC_NONUS_BSLASH`|`KC_NUBS`|Non-US `\` and <code>&#124;</code> |
|`KC_INT1`|`KC_RO`|JIS `\` and <code>&#124;</code> |
|`KC_INT2`|`KC_KANA`|International216|
|`KC_INT3`|`KC_JYEN`|Yen Symbol (`¥`)|
|`KC_SCOLON`|`KC_SCLN`|`;` and `:`|
|`KC_QUOTE`|`KC_QUOT`|`` and `“`|
|`KC_GRAVE`|`KC_GRV`|Grave Accent and Tilde|
|`KC_COMMA`|`KC_COMM`|`,` and `<`|
|`KC_DOT`||`.` and `>`|
|`KC_SLASH`|`KC_SLSH`|`/` and `?`|
|`KC_CAPSLOCK`|`KC_CAPS`|Caps Lock|
|`KC_LCTRL`|`KC_LCTL`|LeftControl|
|`KC_LSHIFT`|`KC_LSFT`|LeftShift|
|`KC_LALT`||LeftAlt|
|`KC_LGUI`||Left GUI(Windows/Apple/Meta key)|
|`KC_RCTRL`|`KC_RCTL`|RightControl|
|`KC_RSHIFT`|`KC_RSFT`|RightShift|
|`KC_RALT`||RightAlt|
|`KC_RGUI`||Right GUI(Windows/Apple/Meta key)|
|`KC_LOCKING_CAPS`|`KC_LCAP`|Locking Caps Lock|
|`KC_LOCKING_NUM`|`KC_LNUM`|Locking Num Lock|
|`KC_LOCKING_SCROLL`|`KC_LSCR`|Locking Scroll Lock|
|`KC_INT4`|`KC_HENK`|JIS Henken|
|`KC_INT5`|`KC_MHEN`|JIS Muhenken|
|`KC_PSCREEN`|`KC_PSCR`|PrintScreen|
|`KC_SCROLLLOCK`|`KC_SLCK`|Scroll Lock|
|`KC_PAUSE`|`KC_PAUS`|Pause|
|`KC_INSERT`|`KC_INS`|Insert|
|`KC_HOME`||Home|
|`KC_PGUP`||PageUp|
|`KC_DELETE`|`KC_DEL`|Delete Forward|
|`KC_END`||End|
|`KC_PGDOWN`|`KC_PGDN`|PageDown|
|`KC_RIGHT`|`KC_RGHT`|RightArrow|
|`KC_LEFT`||LeftArrow|
|`KC_DOWN`||DownArrow|
|`KC_UP`||UpArrow|
|`KC_APPLICATION`|`KC_APP`|Application|
|`KC_POWER`||Power|
|`KC_EXECUTE`||Execute|
|`KC_HELP`||Help|
|`KC_MENU`||Menu|
|`KC_SELECT`||Select|
|`KC_AGAIN`||Again|
|`KC_UNDO`||Undo|
|`KC_CUT`||Cut|
|`KC_COPY`||Copy|
|`KC_PASTE`||Paste|
|`KC_FIND`||Find|
|`KC_ALT_ERASE`||Alternate Erase|
|`KC_SYSREQ`||SysReq/Attention|
|`KC_CANCEL`||Cancel|
|`KC_CLEAR`||Clear|
|`KC_PRIOR`||Prior|
|`KC_RETURN`||Return|
|`KC_SEPARATOR`||Separator|
|`KC_OUT`||Out|
|`KC_OPER`||Oper|
|`KC_CLEAR_AGAIN`||Clear/Again|
|`KC_CRSEL`||CrSel/Props|
|`KC_EXSEL`||ExSel|
|`KC_SYSTEM_POWER`|`KC_PWR`|System Power Down|
|`KC_SYSTEM_SLEEP`|`KC_SLEP`|System Sleep|
|`KC_SYSTEM_WAKE`|`KC_WAKE`|System Wake|
|`KC_MAIL`|`KC_MAIL`||
|`KC_CALCULATOR`|`KC_CALC`||
|`KC_MY_COMPUTER`|`KC_MYCM`||
|`KC_WWW_SEARCH`|`KC_WSCH`||
|`KC_WWW_HOME`|`KC_WHOM`||
|`KC_WWW_BACK`|`KC_WBAK`||
|`KC_WWW_FORWARD`|`KC_WFWD`||
|`KC_WWW_STOP`|`KC_WSTP`||
|`KC_WWW_REFRESH`|`KC_WREF`||
|`KC_WWW_FAVORITES`|`KC_WFAV`||
|`KC_STOP`||Stop|
|`KC__MUTE`||Mute (macOS)|
|`KC__VOLUP`||Volume Up (macOS)|
|`KC__VOLDOWN`||Volume Down (macOS)|
|`KC_AUDIO_MUTE`|`KC_MUTE`|Mute (Windows/macOS/Linux)|
|`KC_AUDIO_VOL_UP`|`KC_VOLU`|Volume Up (Windows/macOS/Linux)|
|`KC_AUDIO_VOL_DOWN`|`KC_VOLD`|Volume Down (Windows/macOS/Linux)|
|`KC_MEDIA_NEXT_TRACK`|`KC_MNXT`|Next Track (Windows)|
|`KC_MEDIA_PREV_TRACK`|`KC_MPRV`|Previous Track (Windows)|
|`KC_MEDIA_FAST_FORWARD`|`KC_MFFD`|Next Track (macOS)|
|`KC_MEDIA_REWIND`|`KC_MRWD`|Previous Track (macOS)|
|`KC_MEDIA_STOP`|`KC_MSTP`||
|`KC_MEDIA_PLAY_PAUSE`|`KC_MPLY`||
|`KC_MEDIA_SELECT`|`KC_MSEL`||
|`KC_NUMLOCK`|`KC_NLCK`|Keypad Num Lock and Clear|
|`KC_KP_SLASH`|`KC_PSLS`|Keypad /|
|`KC_KP_ASTERISK`|`KC_PAST`|Keypad *|
|`KC_KP_MINUS`|`KC_PMNS`|Keypad -|
|`KC_KP_PLUS`|`KC_PPLS`|Keypad +|
|`KC_KP_ENTER`|`KC_PENT`|Keypad ENTER`|
|`KC_KP_1`|`KC_P1`|Keypad 1 and End|
|`KC_KP_2`|`KC_P2`|Keypad 2 and Down Arrow|
|`KC_KP_3`|`KC_P3`|Keypad 3 and PageDn|
|`KC_KP_4`|`KC_P4`|Keypad 4 and Left Arrow|
|`KC_KP_5`|`KC_P5`|Keypad 5|
|`KC_KP_6`|`KC_P6`|Keypad 6 and Right Arrow|
|`KC_KP_7`|`KC_P7`|Keypad 7 and Home|
|`KC_KP_8`|`KC_P8`|Keypad 8 and Up Arrow|
|`KC_KP_9`|`KC_P9`|Keypad 9 and PageUp|
|`KC_KP_0`|`KC_P0`|Keypad 0 and Insert|
|`KC_KP_DOT`|`KC_PDOT`|Keypad . and Delete|
|`KC_KP_EQUAL`|`KC_PEQL`|Keypad =|
|`KC_KP_COMMA`|`KC_PCMM`|Keypad Comma|
|`KC_KP_EQUAL_AS400`||Keypad Equal Sign|
|`KC_NO`||Ignore this key. (NOOP) |
|`KC_TRNS`||Make this key transparent to find the key on a lower layer.|
|[`KC_MS_UP`](mouse_keys.md)|`KC_MS_U`|Mouse Cursor Up|
|[`KC_MS_DOWN`](mouse_keys.md)|`KC_MS_D`|Mouse Cursor Down|
|[`KC_MS_LEFT`](mouse_keys.md)|`KC_MS_L`|Mouse Cursor Left|
|[`KC_MS_RIGHT`](mouse_keys.md)|`KC_MS_R`|Mouse Cursor Right|
|[`KC_MS_BTN1`](mouse_keys.md)|`KC_BTN1`|Mouse Button 1|
|[`KC_MS_BTN2`](mouse_keys.md)|`KC_BTN2`|Mouse Button 2|
|[`KC_MS_BTN3`](mouse_keys.md)|`KC_BTN3`|Mouse Button 3|
|[`KC_MS_BTN4`](mouse_keys.md)|`KC_BTN4`|Mouse Button 4|
|[`KC_MS_BTN5`](mouse_keys.md)|`KC_BTN5`|Mouse Button 5|
|[`KC_MS_WH_UP`](mouse_keys.md)|`KC_WH_U`|Mouse Wheel Up|
|[`KC_MS_WH_DOWN`](mouse_keys.md)|`KC_WH_D`|Mouse Wheel Down|
|[`KC_MS_WH_LEFT`](mouse_keys.md)|`KC_WH_L`|Mouse Wheel Left|
|[`KC_MS_WH_RIGHT`](mouse_keys.md)|`KC_WH_R`|Mouse Wheel Right|
|[`KC_MS_ACCEL0`](mouse_keys.md)|`KC_ACL0`|Mouse Acceleration 0|
|[`KC_MS_ACCEL1`](mouse_keys.md)|`KC_ACL1`|Mouse Acceleration 1|
|[`KC_MS_ACCEL2`](mouse_keys.md)|`KC_ACL2`|Mouse Acceleration 2|
|[`RESET`](quantum_keycodes.md#qmk-keycodes)||Put the keyboard into DFU mode for flashing|
|[`DEBUG`](quantum_keycodes.md#qmk-keycodes)||Toggles debug mode|
|[`KC_GESC`](quantum_keycodes.md#qmk-keycodes)|`GRAVE_ESC`|Acts as escape when pressed normally but when pressed with Shift or GUI will send a `~`|
|[`KC_LSPO`](quantum_keycodes.md#qmk-keycodes)||Left shift when held, open paranthesis when tapped|
|[`KC_RSPC`](quantum_keycodes.md#qmk-keycodes)||Right shift when held, close paranthesis when tapped|
|[`KC_LEAD`](feature_leader_key.md)||The leader key|
|[`FUNC(n)`](quantum_keycodes.md#qmk-keycodes)|`F(n)`|Call `fn_action(n)`|
|[`M(n)`](quantum_keycodes.md#qmk-keycodes)||to call macro n|
|[`MACROTAP(n)`](quantum_keycodes.md#qmk-keycodes)||to macro-tap n idk FIXME`|
|[`MAGIC_SWAP_CONTROL_CAPSLOCK`](feature_bootmagic.md)||Swap Capslock and Left Control|
|[`MAGIC_CAPSLOCK_TO_CONTROL`](feature_bootmagic.md)||Treat Capslock like a Control Key|
|[`MAGIC_SWAP_LALT_LGUI`](feature_bootmagic.md)||Swap the left Alt and GUI keys|
|[`MAGIC_SWAP_RALT_RGUI`](feature_bootmagic.md)||Swap the right Alt and GUI keys|
|[`MAGIC_NO_GUI`](feature_bootmagic.md)||Disable the GUI key|
|[`MAGIC_SWAP_GRAVE_ESC`](feature_bootmagic.md)||Swap the Grave and Esc key.|
|[`MAGIC_SWAP_BACKSLASH_BACKSPACE`](feature_bootmagic.md)||Swap backslack and backspace|
|[`MAGIC_HOST_NKRO`](feature_bootmagic.md)||Force NKRO on|
|[`MAGIC_SWAP_ALT_GUI`/`AG_SWAP`](feature_bootmagic.md)||Swap Alt and Gui on both sides|
|[`MAGIC_UNSWAP_CONTROL_CAPSLOCK`](feature_bootmagic.md)||Disable the Control/Capslock swap|
|[`MAGIC_UNCAPSLOCK_TO_CONTROL`](feature_bootmagic.md)||Disable treating Capslock like Control |
|[`MAGIC_UNSWAP_LALT_LGUI`](feature_bootmagic.md)||Disable Left Alt and GUI switching|
|[`MAGIC_UNSWAP_RALT_RGUI`](feature_bootmagic.md)||Disable Right Alt and GUI switching|
|[`MAGIC_UNNO_GUI`](feature_bootmagic.md)||Enable the GUI key |
|[`MAGIC_UNSWAP_GRAVE_ESC`](feature_bootmagic.md)||Disable the Grave/Esc swap |
|[`MAGIC_UNSWAP_BACKSLASH_BACKSPACE`](feature_bootmagic.md)||Disable the backslash/backspace swap|
|[`MAGIC_UNHOST_NKRO`](feature_bootmagic.md)||Force NKRO off|
|[`MAGIC_UNSWAP_ALT_GUI`/`AG_NORM`](feature_bootmagic.md)||Disable the Alt/GUI switching|
|[`MAGIC_TOGGLE_NKRO`](feature_bootmagic.md)||Turn NKRO on or off|
|[`BL_x`](feature_backlight.md)||Set a specific backlight level between 0-9|
|[`BL_ON`](feature_backlight.md)||An alias for `BL_9`|
|[`BL_OFF`](feature_backlight.md)||An alias for `BL_0`|
|[`BL_DEC`](feature_backlight.md)||Turn the backlight level down by 1|
|[`BL_INC`](feature_backlight.md)||Turn the backlight level up by 1|
|[`BL_TOGG`](feature_backlight.md)||Toggle the backlight on or off|
|[`BL_STEP`](feature_backlight.md)||Step through backlight levels, wrapping around to 0 when you reach the top.|
|[`RGB_TOG`](feature_rgblight.md)||toggle on/off|
|[`RGB_MOD`](feature_rgblight.md)||cycle through modes|
|[`RGB_HUI`](feature_rgblight.md)||hue increase|
|[`RGB_HUD`](feature_rgblight.md)||hue decrease|
|[`RGB_SAI`](feature_rgblight.md)||saturation increase|
|[`RGB_SAD`](feature_rgblight.md)||saturation decrease|
|[`RGB_VAI`](feature_rgblight.md)||value increase|
|[`RGB_VAD`](feature_rgblight.md)||value decrease|
|[`PRINT_ON`](feature_thermal_printer.md)||Start printing everything the user types|
|[`PRINT_OFF`](feature_thermal_printer.md)||Stop printing everything the user types|
|[`OUT_AUTO`](feature_bluetooth.md)||auto mode|
|[`OUT_USB`](feature_bluetooth.md)||usb only|
|[`OUT_BT`](feature_bluetooth.md)||bluetooth (when `BLUETOOTH_ENABLE`)|
|[`KC_HYPR`](quantum_keycodes.md#modifiers)||Hold down LCTL + LSFT + LALT + LGUI`|
|[`KC_MEH`](quantum_keycodes.md#modifiers)||Hold down LCTL + LSFT + LALT`|
|[`LCTL(kc)`](quantum_keycodes.md#modifiers)||`LCTL` + `kc`|
|[`LSFT(kc)`](quantum_keycodes.md#modifiers)|[`S(kc)`](quantum_keycodes.md#modifiers)|`LSFT` + `kc`|
|[`LALT(kc)`](quantum_keycodes.md#modifiers)||`LALT` + `kc`|
|[`LGUI(kc)`](quantum_keycodes.md#modifiers)||`LGUI` + `kc`|
|[`RCTL(kc)`](quantum_keycodes.md#modifiers)||`RCTL` + `kc`|
|[`RSFT(kc)`](quantum_keycodes.md#modifiers)||`RSFT` + `kc`|
|[`RALT(kc)`](quantum_keycodes.md#modifiers)||`RALT` + `kc`|
|[`RGUI(kc)`](quantum_keycodes.md#modifiers)||`RGUI` + `kc`|
|[`HYPR(kc)`](quantum_keycodes.md#modifiers)||`LCTL` + `LSFT` + `LALT` + `LGUI` + `kc`|
|[`MEH(kc)`](quantum_keycodes.md#modifiers)||`LCTL` + `LSFT` + `LALT` + `kc`|
|[`LCAG(kc)`](quantum_keycodes.md#modifiers)||`LCTL` + `LALT` + `LGUI` + `kc`|
|[`ALTG(kc)`](quantum_keycodes.md#modifiers)||`RCTL` + `RALT` + `kc`|
|[`SCMD(kc)`](quantum_keycodes.md#modifiers)|[`SWIN(kc)`](quantum_keycodes.md#modifiers)|`LGUI` + `LSFT` + `kc`|
|[`LCA(kc)`](quantum_keycodes.md#modifiers)||`LCTL` + `LALT` + `kc`|
|[`CTL_T(kc)`](quantum_keycodes.md#mod-tap-keys)|[`LCTL_T(kc)`](quantum_keycodes.md#mod-tap-keys)|`LCTL` when held, `kc` when tapped|
|[`RCTL_T(kc)`](quantum_keycodes.md#mod-tap-keys)||[`RCTL` when held, `kc` when tapped|
|[`SFT_T(kc)`](quantum_keycodes.md#mod-tap-keys)|[`LSFT_T(kc)`](quantum_keycodes.md#mod-tap-keys)|`LSFT` when held, `kc` when tapped|
|[`RSFT_T(kc)`](quantum_keycodes.md#mod-tap-keys)||[`RSFT` when held, `kc` when tapped|
|[`ALT_T(kc)`](quantum_keycodes.md#mod-tap-keys)|[`LALT_T(kc)`](quantum_keycodes.md#mod-tap-keys)|`LALT` when held, `kc` when tapped|
|[`RALT_T(kc)`](quantum_keycodes.md#mod-tap-keys)|[`ALGR_T(kc)`](quantum_keycodes.md#mod-tap-keys)|`RALT` when held, `kc` when tapped|
|[`GUI_T(kc)`](quantum_keycodes.md#mod-tap-keys)|[`LGUI_T(kc)`](quantum_keycodes.md#mod-tap-keys)|`LGUI` when held, `kc` when tapped|
|[`RGUI_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`RGUI` when held, `kc` when tapped|
|[`C_S_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`LCTL` + `LSFT` when held, `kc` when tapped|
|[`MEH_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`LCTL` + `LSFT` + `LALT` when held, `kc` when tapped|
|[`LCAG_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`LCTL` + `LALT` + `LGUI` when held, `kc` when tapped|
|[`RCAG_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`RCTL` + `RALT` + `RGUI` when held, `kc` when tapped|
|[`ALL_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`LCTL` + `LSFT` + `LALT` + `LGUI` when held, `kc` when tapped [more info](http://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/)|
|[`SCMD_T(kc)`](quantum_keycodes.md#mod-tap-keys)|[`SWIN_T(kc)`](quantum_keycodes.md#mod-tap-keys)|`LGUI` + `LSFT` when held, `kc` when tapped|
|[`LCA_T(kc)`](quantum_keycodes.md#mod-tap-keys)||`LCTL` + `LALT` when held, `kc` when tapped|
|[`KC_TILD`](keycodes_us_ansi_shifted.md)|`KC_TILDE`|tilde `~`|
|[`KC_EXLM`](keycodes_us_ansi_shifted.md)|`KC_EXCLAIM`|exclamation mark `!`|
|[`KC_AT`](keycodes_us_ansi_shifted.md)||at sign `@`|
|[`KC_HASH`](keycodes_us_ansi_shifted.md)||hash sign `#`|
|[`KC_DLR`](keycodes_us_ansi_shifted.md)|`KC_DOLLAR`|dollar sign `$`|
|[`KC_PERC`](keycodes_us_ansi_shifted.md)|`KC_PERCENT`|percent sign `%`|
|[`KC_CIRC`](keycodes_us_ansi_shifted.md)|`KC_CIRCUMFLEX`|circumflex `^`|
|[`KC_AMPR`](keycodes_us_ansi_shifted.md)|`KC_AMPERSAND`|ampersand `&`|
|[`KC_ASTR`](keycodes_us_ansi_shifted.md)|`KC_ASTERISK`|asterisk `*`|
|[`KC_LPRN`](keycodes_us_ansi_shifted.md)|`KC_LEFT_PAREN`|left parenthesis `(`|
|[`KC_RPRN`](keycodes_us_ansi_shifted.md)|`KC_RIGHT_PAREN`|right parenthesis `)`|
|[`KC_UNDS`](keycodes_us_ansi_shifted.md)|`KC_UNDERSCORE`|underscore `_`|
|[`KC_PLUS`](keycodes_us_ansi_shifted.md)||plus sign `+`|
|[`KC_LCBR`](keycodes_us_ansi_shifted.md)|`KC_LEFT_CURLY_BRACE`|left curly brace `{`|
|[`KC_RCBR`](keycodes_us_ansi_shifted.md)|`KC_RIGHT_CURLY_BRACE`|right curly brace `}`|
|[`KC_LT`/`KC_LABK`](keycodes_us_ansi_shifted.md)|`KC_LEFT_ANGLE_BRACKET`|left angle bracket `<`|
|[`KC_GT`/`KC_RABK`](keycodes_us_ansi_shifted.md)|`KC_RIGHT_ANGLE_BRACKET`|right angle bracket `>`|
|[`KC_COLN`](keycodes_us_ansi_shifted.md)|`KC_COLON`|colon `:`|
|[`KC_PIPE`](keycodes_us_ansi_shifted.md)||pipe `\|`|
|[`KC_QUES`](keycodes_us_ansi_shifted.md)|`KC_QUESTION`|question mark `?`|
|[`KC_DQT`/`KC_DQUO`](keycodes_us_ansi_shifted.md)|`KC_DOUBLE_QUOTE`|double quote `"`|
|[`LT(layer, kc)`](feature_common_shortcuts.md#switching-and-toggling-layers)||turn on layer (0-15) when held, kc ([basic keycodes](keycodes_basic.md)) when tapped|
|[`TO(layer)`](feature_common_shortcuts.md#switching-and-toggling-layers)||turn on layer when depressed|
|[`MO(layer)`](feature_common_shortcuts.md#switching-and-toggling-layers)||momentarily turn on layer when depressed (requires `KC_TRNS` on destination layer)|
|[`DF(layer)`](feature_common_shortcuts.md#switching-and-toggling-layers)||sets the base (default) layer|
|[`TG(layer)`](feature_common_shortcuts.md#switching-and-toggling-layers)||toggle layer on/off|
|[`TT(layer)`](feature_common_shortcuts.md#switching-and-toggling-layers)||tap toggle? idk FIXME`|
|[`OSM(mod)`](quantum_keycodes.md#one-shot-keys)||hold mod for one keypress|
|[`OSL(layer)`](quantum_keycodes.md#one-shot-keys)||switch to layer for one keypress|
|[`UNICODE(n)`](unicode.md)|[`UC(n)`](unicode.md)|if `UNICODE_ENABLE`, this will send characters up to `0x7FFF`|
|[`X(n)`](unicode.md)||if `UNICODEMAP_ENABLE`, also sends unicode via a different method|
# Keycodes Overview
When defining a [keymap](keymap.md) each key needs a valid key definition. This page documents the symbols that correspond to keycodes that are available to you in QMK.
This is a reference only. Each group of keys links to the page documenting their functionality in more detail.
## [Basic Keycodes](keycodes_basic.md)
|Key |Aliases |Description |
|-----------------------|--------------------|-----------------------------------------------|
|`KC_1` | |`1` and `!` |
|`KC_2` | |`2` and `@` |
|`KC_3` | |`3` and `#` |
|`KC_4` | |`4` and `$` |
|`KC_5` | |`5` and `%` |
|`KC_6` | |`6` and `^` |
|`KC_7` | |`7` and `&` |
|`KC_8` | |`8` and `*` |
|`KC_9` | |`9` and `(` |
|`KC_0` | |`0` and `)` |
|`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_F13` | | |
|`KC_F14` | | |
|`KC_F15` | | |
|`KC_F16` | | |
|`KC_F17` | | |
|`KC_F18` | | |
|`KC_F19` | | |
|`KC_F20` | | |
|`KC_F21` | | |
|`KC_F22` | | |
|`KC_F23` | | |
|`KC_F24` | | |
|`KC_A` | |`a` and `A` |
|`KC_B` | |`b` and `B` |
|`KC_C` | |`c` and `C` |
|`KC_D` | |`d` and `D` |
|`KC_E` | |`e` and `E` |
|`KC_F` | |`f` and `F` |
|`KC_G` | |`g` and `G` |
|`KC_H` | |`h` and `H` |
|`KC_I` | |`i` and `I` |
|`KC_J` | |`j` and `J` |
|`KC_K` | |`k` and `K` |
|`KC_L` | |`l` and `L` |
|`KC_M` | |`m` and `M` |
|`KC_N` | |`n` and `N` |
|`KC_O` | |`o` and `O` |
|`KC_P` | |`p` and `P` |
|`KC_Q` | |`q` and `Q` |
|`KC_R` | |`r` and `R` |
|`KC_S` | |`s` and `S` |
|`KC_T` | |`t` and `T` |
|`KC_U` | |`u` and `U` |
|`KC_V` | |`v` and `V` |
|`KC_W` | |`w` and `W` |
|`KC_X` | |`x` and `X` |
|`KC_Y` | |`y` and `Y` |
|`KC_Z` | |`z` and `Z` |
|`KC_ENTER` |`KC_ENT` |Return (Enter) |
|`KC_ESCAPE` |`KC_ESC` |Escape |
|`KC_BSPACE` |`KC_BSPC` |Delete (Backspace) |
|`KC_TAB` | |Tab |
|`KC_SPACE` |`KC_SPC` |Spacebar |
|`KC_MINUS` |`KC_MINS` |`-` and `_` |
|`KC_EQUAL` |`KC_EQL` |`=` and `+` |
|`KC_LBRACKET` |`KC_LBRC` |`[` and `{` |
|`KC_RBRACKET` |`KC_RBRC` |`]` and `}` |
|`KC_BSLASH` |`KC_BSLS` |`\` and <code>&#124;</code> |
|`KC_NONUS_HASH` |`KC_NUHS` |Non-US `#` and `~` |
|`KC_NONUS_BSLASH` |`KC_NUBS` |Non-US `\` and <code>&#124;</code> |
|`KC_INT1` |`KC_RO` |JIS `\` and <code>&#124;</code> |
|`KC_INT2` |`KC_KANA` |JIS Katakana/Hiragana |
|`KC_INT3` |`KC_JYEN` |JIS `¥` |
|`KC_SCOLON` |`KC_SCLN` |`;` and `:` |
|`KC_QUOTE` |`KC_QUOT` |`'` and `"` |
|`KC_GRAVE` |`KC_GRV` |<code>&#96;</code> and `~` |
|`KC_COMMA` |`KC_COMM` |`,` and `<` |
|`KC_DOT` | |`.` and `>` |
|`KC_SLASH` |`KC_SLSH` |`/` and `?` |
|`KC_CAPSLOCK` |`KC_CAPS` |Caps Lock |
|`KC_LCTRL` |`KC_LCTL` |Left Control |
|`KC_LSHIFT` |`KC_LSFT` |Left Shift |
|`KC_LALT` | |Left Alt |
|`KC_LGUI` |`KC_LCMD`, `KC_LWIN`|Left GUI (Windows/Command/Meta key) |
|`KC_RCTRL` |`KC_RCTL` |Right Control |
|`KC_RSHIFT` |`KC_RSFT` |Right Shift |
|`KC_RALT` | |Right Alt |
|`KC_RGUI` |`KC_RCMD`, `KC_RWIN`|Right GUI (Windows/Command/Meta key) |
|`KC_LOCKING_CAPS` |`KC_LCAP` |Locking Caps Lock |
|`KC_LOCKING_NUM` |`KC_LNUM` |Locking Num Lock |
|`KC_LOCKING_SCROLL` |`KC_LSCR` |Locking Scroll Lock |
|`KC_INT4` |`KC_HENK` |JIS Henkan |
|`KC_INT5` |`KC_MHEN` |JIS Muhenkan |
|`KC_PSCREEN` |`KC_PSCR` |Print Screen |
|`KC_SCROLLLOCK` |`KC_SLCK` |Scroll Lock |
|`KC_PAUSE` |`KC_PAUS` |Pause |
|`KC_INSERT` |`KC_INS` |Insert |
|`KC_HOME` | |Home |
|`KC_PGUP` | |Page Up |
|`KC_DELETE` |`KC_DEL` |Forward Delete |
|`KC_END` | |End |
|`KC_PGDOWN` |`KC_PGDN` |Page Down |
|`KC_RIGHT` |`KC_RGHT` |Right Arrow |
|`KC_LEFT` | |Left Arrow |
|`KC_DOWN` | |Down Arrow |
|`KC_UP` | |Up Arrow |
|`KC_APPLICATION` |`KC_APP` |Application (Windows Menu Key) |
|`KC_POWER` | |Deprecated by MS in favor of `KC_SYSTEM_POWER`.|
|`KC_EXECUTE` | |Execute |
|`KC_HELP` | |Help |
|`KC_MENU` | |Menu |
|`KC_SELECT` | |Select |
|`KC_AGAIN` | |Again |
|`KC_UNDO` | |Undo |
|`KC_CUT` | |Cut |
|`KC_COPY` | |Copy |
|`KC_PASTE` | |Paste |
|`KC_FIND` | |Find |
|`KC_ALT_ERASE` | |Alternate Erase |
|`KC_SYSREQ` | |SysReq/Attention |
|`KC_CANCEL` | |Cancel |
|`KC_CLEAR` | |Clear |
|`KC_PRIOR` | |Prior |
|`KC_RETURN` | |Return |
|`KC_SEPARATOR` | |Separator |
|`KC_OUT` | |Out |
|`KC_OPER` | |Oper |
|`KC_CLEAR_AGAIN` | |Clear/Again |
|`KC_CRSEL` | |CrSel/Props |
|`KC_EXSEL` | |ExSel |
|`KC_SYSTEM_POWER` |`KC_PWR` |System Power Down. Recommended over `KC_POWER`.|
|`KC_SYSTEM_SLEEP` |`KC_SLEP` |System Sleep |
|`KC_SYSTEM_WAKE` |`KC_WAKE` |System Wake |
|`KC_MAIL` |`KC_MAIL` | |
|`KC_CALCULATOR` |`KC_CALC` | |
|`KC_MY_COMPUTER` |`KC_MYCM` | |
|`KC_WWW_SEARCH` |`KC_WSCH` | |
|`KC_WWW_HOME` |`KC_WHOM` | |
|`KC_WWW_BACK` |`KC_WBAK` | |
|`KC_WWW_FORWARD` |`KC_WFWD` | |
|`KC_WWW_STOP` |`KC_WSTP` | |
|`KC_WWW_REFRESH` |`KC_WREF` | |
|`KC_WWW_FAVORITES` |`KC_WFAV` | |
|`KC_STOP` | |Stop |
|`KC__MUTE` | |Mute (macOS) |
|`KC__VOLUP` | |Volume Up (macOS) |
|`KC__VOLDOWN` | |Volume Down (macOS) |
|`KC_AUDIO_MUTE` |`KC_MUTE` |Mute (Windows/macOS/Linux) |
|`KC_AUDIO_VOL_UP` |`KC_VOLU` |Volume Up (Windows/macOS/Linux) |
|`KC_AUDIO_VOL_DOWN` |`KC_VOLD` |Volume Down (Windows/macOS/Linux) |
|`KC_MEDIA_NEXT_TRACK` |`KC_MNXT` |Next Track (Windows) |
|`KC_MEDIA_PREV_TRACK` |`KC_MPRV` |Previous Track (Windows) |
|`KC_MEDIA_FAST_FORWARD`|`KC_MFFD` |Next Track (macOS) |
|`KC_MEDIA_REWIND` |`KC_MRWD` |Previous Track (macOS) |
|`KC_MEDIA_STOP` |`KC_MSTP` |Stop Track |
|`KC_MEDIA_PLAY_PAUSE` |`KC_MPLY` |Play/Pause Track |
|`KC_MEDIA_SELECT` |`KC_MSEL` | |
|`KC_NUMLOCK` |`KC_NLCK` |Keypad Num Lock and Clear |
|`KC_KP_SLASH` |`KC_PSLS` |Keypad `/` |
|`KC_KP_ASTERISK` |`KC_PAST` |Keypad `*` |
|`KC_KP_MINUS` |`KC_PMNS` |Keypad `-` |
|`KC_KP_PLUS` |`KC_PPLS` |Keypad `+` |
|`KC_KP_ENTER` |`KC_PENT` |Keypad Enter |
|`KC_KP_1` |`KC_P1` |Keypad `1` and End |
|`KC_KP_2` |`KC_P2` |Keypad `2` and Down Arrow |
|`KC_KP_3` |`KC_P3` |Keypad `3` and Page Down |
|`KC_KP_4` |`KC_P4` |Keypad `4` and Left Arrow |
|`KC_KP_5` |`KC_P5` |Keypad `5` |
|`KC_KP_6` |`KC_P6` |Keypad `6` and Right Arrow |
|`KC_KP_7` |`KC_P7` |Keypad `7` and Home |
|`KC_KP_8` |`KC_P8` |Keypad `8` and Up Arrow |
|`KC_KP_9` |`KC_P9` |Keypad `9` and Page Up |
|`KC_KP_0` |`KC_P0` |Keypad `0` and Insert |
|`KC_KP_DOT` |`KC_PDOT` |Keypad `.` and Delete |
|`KC_KP_EQUAL` |`KC_PEQL` |Keypad `=` |
|`KC_KP_COMMA` |`KC_PCMM` |Keypad `,` |
|`KC_KP_EQUAL_AS400` | |Keypad `=` on AS/400 keyboards |
|`KC_NO` | |Ignore this key (NOOP) |
|`KC_TRANSPARENT` |`KC_TRNS` |Use the next lowest non-transparent key |
## [Mouse Keys](feature_mouse_keys.md)
|Key |Aliases |Description |
|----------------|---------|---------------------------|
|`KC_MS_UP` |`KC_MS_U`|Mouse Cursor Up |
|`KC_MS_DOWN` |`KC_MS_D`|Mouse Cursor Down |
|`KC_MS_LEFT` |`KC_MS_L`|Mouse Cursor Left |
|`KC_MS_RIGHT` |`KC_MS_R`|Mouse Cursor Right |
|`KC_MS_BTN1` |`KC_BTN1`|Mouse Button 1 |
|`KC_MS_BTN2` |`KC_BTN2`|Mouse Button 2 |
|`KC_MS_BTN3` |`KC_BTN3`|Mouse Button 3 |
|`KC_MS_BTN4` |`KC_BTN4`|Mouse Button 4 |
|`KC_MS_BTN5` |`KC_BTN5`|Mouse Button 5 |
|`KC_MS_WH_UP` |`KC_WH_U`|Mouse Wheel Up |
|`KC_MS_WH_DOWN` |`KC_WH_D`|Mouse Wheel Down |
|`KC_MS_WH_LEFT` |`KC_WH_L`|Mouse Wheel Left |
|`KC_MS_WH_RIGHT`|`KC_WH_R`|Mouse Wheel Right |
|`KC_MS_ACCEL0` |`KC_ACL0`|Set mouse acceleration to 0|
|`KC_MS_ACCEL1` |`KC_ACL1`|Set mouse acceleration to 1|
|`KC_MS_ACCEL2` |`KC_ACL2`|Set mouse acceleration to 2|
## [Quantum Keycodes](quantum_keycodes.md#qmk-keycodes)
|Key |Aliases |Description |
|-------------|-----------|---------------------------------------------------------------------|
|`RESET` | |Put the keyboard into DFU mode for flashing |
|`DEBUG` | |Toggle debug mode |
|`KC_GESC` |`GRAVE_ESC`|Escape when tapped, <code>&#96;</code> when pressed with Shift or GUI|
|`KC_LSPO` | |Left Shift when held, `(` when tapped |
|`KC_RSPC` | |Right Shift when held, `)` when tapped |
|`KC_LEAD` | |The [Leader key](feature_leader_key.md) |
|`KC_LOCK` | |The [Lock key](feature_key_lock.md) |
|`FUNC(n)` |`F(n)` |Call `fn_action(n)` (deprecated) |
|`M(n)` | |Call macro `n` |
|`MACROTAP(n)`| |Macro-tap `n` idk FIXME |
## [Bootmagic](feature_bootmagic.md)
|Key |Aliases |Description |
|----------------------------------|---------|------------------------------------|
|`MAGIC_SWAP_CONTROL_CAPSLOCK` | |Swap Caps Lock and Left Control |
|`MAGIC_CAPSLOCK_TO_CONTROL` | |Treat Caps Lock as Control |
|`MAGIC_SWAP_LALT_LGUI` | |Swap Left Alt and GUI |
|`MAGIC_SWAP_RALT_RGUI` | |Swap Right Alt and GUI |
|`MAGIC_NO_GUI` | |Disable the GUI key |
|`MAGIC_SWAP_GRAVE_ESC` | |Swap <code>&#96;</code> and Escape |
|`MAGIC_SWAP_BACKSLASH_BACKSPACE` | |Swap `\` and Backspace |
|`MAGIC_HOST_NKRO` | |Force NKRO on |
|`MAGIC_SWAP_ALT_GUI` |`AG_SWAP`|Swap Alt and GUI on both sides |
|`MAGIC_UNSWAP_CONTROL_CAPSLOCK` | |Unswap Caps Lock and Left Control |
|`MAGIC_UNCAPSLOCK_TO_CONTROL` | |Stop treating Caps Lock as Control |
|`MAGIC_UNSWAP_LALT_LGUI` | |Unswap Left Alt and GUI |
|`MAGIC_UNSWAP_RALT_RGUI` | |Unswap Right Alt and GUI |
|`MAGIC_UNNO_GUI` | |Enable the GUI key |
|`MAGIC_UNSWAP_GRAVE_ESC` | |Unswap <code>&#96;</code> and Escape|
|`MAGIC_UNSWAP_BACKSLASH_BACKSPACE`| |Unswap `\` and Backspace |
|`MAGIC_UNHOST_NKRO` | |Force NKRO off |
|`MAGIC_UNSWAP_ALT_GUI` |`AG_NORM`|Unswap Alt and GUI on both sides |
|`MAGIC_TOGGLE_NKRO` | |Turn NKRO on or off |
## [Backlighting](feature_backlight.md)
|Key |Description |
|---------|------------------------------------------|
|`BL_TOGG`|Turn the backlight on or off |
|`BL_STEP`|Cycle through backlight levels |
|`BL_ON` |Set the backlight to max brightness |
|`BL_OFF` |Turn the backlight off |
|`BL_INC` |Increase the backlight level |
|`BL_DEC` |Decrease the backlight level |
|`BL_BRTG`|Toggle backlight breathing |
## [RGB Lighting](feature_rgblight.md)
|Key |Aliases |Description |
|-------------------|----------|--------------------------------------------------------------------|
|`RGB_TOG` | |Toggle RGB lighting on or off |
|`RGB_MODE_FORWARD` |`RGB_MOD` |Cycle through modes, reverse direction when Shift is held |
|`RGB_MODE_REVERSE` |`RGB_RMOD`|Cycle through modes in reverse, forward direction when Shift is held|
|`RGB_HUI` | |Increase hue |
|`RGB_HUD` | |Decrease hue |
|`RGB_SAI` | |Increase saturation |
|`RGB_SAD` | |Decrease saturation |
|`RGB_VAI` | |Increase value (brightness) |
|`RGB_VAD` | |Decrease value (brightness) |
|`RGB_MODE_PLAIN` |`RGB_M_P `|Static (no animation) mode |
|`RGB_MODE_BREATHE` |`RGB_M_B` |Breathing animation mode |
|`RGB_MODE_RAINBOW` |`RGB_M_R` |Rainbow animation mode |
|`RGB_MODE_SWIRL` |`RGB_M_SW`|Swirl animation mode |
|`RGB_MODE_SNAKE` |`RGB_M_SN`|Snake animation mode |
|`RGB_MODE_KNIGHT` |`RGB_M_K` |"Knight Rider" animation mode |
|`RGB_MODE_XMAS` |`RGB_M_X` |Christmas animation mode |
|`RGB_MODE_GRADIENT`|`RGB_M_G` |Static gradient animation mode |
## [Thermal Printer](feature_thermal_printer.md)
|Key |Description |
|-----------|----------------------------------------|
|`PRINT_ON` |Start printing everything the user types|
|`PRINT_OFF`|Stop printing everything the user types |
## [Bluetooth](feature_bluetooth.md)
|Key |Description |
|----------|----------------------------------------------|
|`OUT_AUTO`|Automatically switch between USB and Bluetooth|
|`OUT_USB` |USB only |
|`OUT_BT` |Bluetooth only |
## [Modifiers](quantum_keycodes.md#modifiers)
|Key |Aliases |Description |
|----------|---------- |----------------------------------------------------|
|`KC_HYPR` | |Hold Left Control, Shift, Alt and GUI |
|`KC_MEH` | |Hold Left Control, Shift and Alt |
|`LCTL(kc)`| |Hold Left Control and press `kc` |
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|`LALT(kc)`| |Hold Left Alt and press `kc` |
|`LGUI(kc)`|`LCMD(kc)`, `LWIN(kc)`|Hold Left GUI and press `kc` |
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|`RALT(kc)`| |Hold Right Alt and press `kc` |
|`RGUI(kc)`|`RCMD(kc)`, `LWIN(kc)`|Hold Right GUI and press `kc` |
|`HYPR(kc)`| |Hold Left Control, Shift, Alt and GUI and press `kc`|
|`MEH(kc)` | |Hold Left Control, Shift and Alt and press `kc` |
|`LCAG(kc)`| |Hold Left Control, Alt and GUI and press `kc` |
|`ALTG(kc)`| |Hold Right Control and Alt and press `kc` |
|`SGUI(kc)`|`SCMD(kc)`, `SWIN(kc)`|Hold Left Shift and GUI and press `kc` |
|`LCA(kc)` | |Hold Left Control and Alt and press `kc` |
## [Mod-Tap Keys](quantum_keycodes.md#mod-tap-keys)
|Key |Aliases |Description |
|------------|---------------------------------------|-------------------------------------------------------|
|`LCTL_T(kc)`|`CTL_T(kc)` |Left Control when held, `kc` when tapped |
|`RCTL_T(kc)`| |Right Control when held, `kc` when tapped |
|`LSFT_T(kc)`|`SFT_T(kc)` |Left Shift when held, `kc` when tapped |
|`RSFT_T(kc)`| |Right Shift when held, `kc` when tapped |
|`LALT_T(kc)`|`ALT_T(kc)` |Left Alt when held, `kc` when tapped |
|`RALT_T(kc)`|`ALGR_T(kc)` |Right Alt when held, `kc` when tapped |
|`LGUI_T(kc)`|`LCMD_T(kc)`, `RWIN_T(kc)`, `GUI_T(kc)`|Left GUI when held, `kc` when tapped |
|`RGUI_T(kc)`|`RCMD_T(kc)`, `RWIN_T(kc)` |Right GUI when held, `kc` when tapped |
|`C_S_T(kc)` | |Left Control and Shift when held, `kc` when tapped |
|`MEH_T(kc)` | |Left Control, Shift and Alt when held, `kc` when tapped|
|`LCAG_T(kc)`| |Left Control, Alt and GUI when held, `kc` when tapped |
|`RCAG_T(kc)`| |Right Control, Alt and GUI when held, `kc` when tapped |
|`ALL_T(kc)` | |Left Control, Shift, Alt and GUI when held, `kc` when tapped - more info [here](http://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/)|
|`SCMD_T(kc)`|`SWIN_T(kc)` |Left Shift and GUI when held, `kc` when tapped |
|`LCA_T(kc)` | |Left Control and Alt when held, `kc` when tapped |
## [US ANSI Shifted Keys](keycodes_us_ansi_shifted.md)
|Key |Aliases |Description |
|------------------------|------------------|-------------------|
|`KC_TILDE` |`KC_TILD` |`~` |
|`KC_EXCLAIM` |`KC_EXLM` |`!` |
|`KC_AT` | |`@` |
|`KC_HASH` | |`#` |
|`KC_DOLLAR` |`KC_DLR` |`$` |
|`KC_PERCENT` |`KC_PERC` |`%` |
|`KC_CIRCUMFLEX` |`KC_CIRC` |`^` |
|`KC_AMPERSAND` |`KC_AMPR` |`&` |
|`KC_ASTERISK` |`KC_ASTR` |`*` |
|`KC_LEFT_PAREN` |`KC_LPRN` |`(` |
|`KC_RIGHT_PAREN` |`KC_RPRN` |`)` |
|`KC_UNDERSCORE` |`KC_UNDS` |`_` |
|`KC_PLUS` | |`+` |
|`KC_LEFT_CURLY_BRACE` |`KC_LCBR` |`{` |
|`KC_RIGHT_CURLY_BRACE` |`KC_RCBR` |`}` |
|`KC_PIPE` | |<code>&#124;</code>|
|`KC_COLON` |`KC_COLN` |`:` |
|`KC_DOUBLE_QUOTE` |`KC_DQT`/`KC_DQUO`|`"` |
|`KC_LEFT_ANGLE_BRACKET` |`KC_LT`/`KC_LABK` |`<` |
|`KC_RIGHT_ANGLE_BRACKET`|`KC_GT`/`KC_RABK` |`>` |
|`KC_QUESTION` |`KC_QUES` |`?` |
## [Switching and Toggling Layers](feature_advanced_keycodes.md#switching-and-toggling-layers)
|Key |Description |
|----------------|----------------------------------------------------------------------------------|
|`LT(layer, kc)` |Turn on `layer` when held, `kc` when tapped |
|`TO(layer)` |Turn on `layer` when pressed |
|`MO(layer)` |Momentarily turn on `layer` when pressed (requires `KC_TRNS` on destination layer)|
|`DF(layer)` |Set the base (default) layer |
|`TG(layer)` |Toggle `layer` on or off |
|`TT(layer)` |Normally acts like MO unless it's tapped multiple times, which toggles `layer` on |
|`LM(layer, mod)`|Momentarily turn on `layer` (like MO) with `mod` active as well. |
## [One Shot Keys](quantum_keycodes.md#one-shot-keys)
|Key |Description |
|------------|----------------------------------|
|`OSM(mod)` |Hold `mod` for one keypress |
|`OSL(layer)`|Switch to `layer` for one keypress|
## [Unicode Support](feature_unicode.md)
|Key |Aliases| |
|------------|-------|-------------------------------------------------|
|`UNICODE(n)`|`UC(n)`|Send Unicode character `n` |
|`X(n)` | |Send Unicode character `n` via a different method|
## [Swap Hands](feature_swap_hands.md)
|Key |Description |
|-----------|-------------------------------------------------------------------------|
|`SH_T(key)`|Sends `key` with a tap; momentary swap when held. |
|`SW_ON` |Turns on swapping and leaves it on. |
|`SW_OFF` |Turn off swapping and leaves it off. Good for returning to a known state.|
|`SH_MON` |Swaps hands when pressed, returns to normal when released (momentary). |
|`SH_MOFF` |Momentarily turns off swap. |
|`SH_TG` |Toggles swap on and off with every key press. |
|`SH_TT` |Toggles with a tap; momentary when held. |

@ -1,192 +1,230 @@
# Basic keycodes
# Basic Keycodes
Basic keycodes are based on [HID Usage Keyboard/Keypad Page(0x07)](http://www.usb.org/developers/hidpage/Hut1_12v2.pdf) with following exceptions:
* `KC_NO` = 0 for no action
* `KC_TRNS` = 1 for layer transparency
* internal special keycodes in the `0xA5-DF` range (tmk heritage).
The basic set of keycodes are based on the [HID Keyboard/Keypad Usage Page (0x07)](http://www.usb.org/developers/hidpage/Hut1_12v2.pdf) with the exception of `KC_NO`, `KC_TRNS` and keycodes in the `0xA5-DF` range. See below for more details.
## Letters and Numbers
|KC_1|KC_2|KC_3|KC_4|KC_5|KC_6|KC_7|KC_8|
|----|----|----|----|----|----|----|----|
|KC_9|KC_0|KC_F1|KC_F2|KC_F3|KC_F4|KC_F5|KC_F6|
|KC_F7|KC_F8|KC_F9|KC_F10|KC_F11|KC_F12|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_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_U|KC_V|
|KC_W|KC_X|KC_Y|KC_Z|||||
|Key |Description|
|------|-----------|
|`KC_A`|`a` and `A`|
|`KC_B`|`b` and `B`|
|`KC_C`|`c` and `C`|
|`KC_D`|`d` and `D`|
|`KC_E`|`e` and `E`|
|`KC_F`|`f` and `F`|
|`KC_G`|`g` and `G`|
|`KC_H`|`h` and `H`|
|`KC_I`|`i` and `I`|
|`KC_J`|`j` and `J`|
|`KC_K`|`k` and `K`|
|`KC_L`|`l` and `L`|
|`KC_M`|`m` and `M`|
|`KC_N`|`n` and `N`|
|`KC_O`|`o` and `O`|
|`KC_P`|`p` and `P`|
|`KC_Q`|`q` and `Q`|
|`KC_R`|`r` and `R`|
|`KC_S`|`s` and `S`|
|`KC_T`|`t` and `T`|
|`KC_U`|`u` and `U`|
|`KC_V`|`v` and `V`|
|`KC_W`|`w` and `W`|
|`KC_X`|`x` and `X`|
|`KC_Y`|`y` and `Y`|
|`KC_Z`|`z` and `Z`|
|`KC_1`|`1` and `!`|
|`KC_2`|`2` and `@`|
|`KC_3`|`3` and `#`|
|`KC_4`|`4` and `$`|
|`KC_5`|`5` and `%`|
|`KC_6`|`6` and `^`|
|`KC_7`|`7` and `&`|
|`KC_8`|`8` and `*`|
|`KC_9`|`9` and `(`|
|`KC_0`|`0` and `)`|
## F Keys
|Key |Description|
|--------|-----------|
|`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_F13`| |
|`KC_F14`| |
|`KC_F15`| |
|`KC_F16`| |
|`KC_F17`| |
|`KC_F18`| |
|`KC_F19`| |
|`KC_F20`| |
|`KC_F21`| |
|`KC_F22`| |
|`KC_F23`| |
|`KC_F24`| |
## Punctuation
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_ENTER|KC_ENT|`Return (ENTER)`|
|KC_ESCAPE|KC_ESC|`ESCAPE`|
|KC_BSPACE|KC_BSPC|`DELETE (Backspace)`|
|KC_TAB||`Tab`|
|KC_SPACE|KC_SPC|Spacebar|
|KC_MINUS|KC_MINS|`-` and `_`|
|KC_EQUAL|KC_EQL|`=` and `+`|
|KC_LBRACKET|KC_LBRC|`[` and `{`|
|KC_RBRACKET|KC_RBRC|`]` and `}`|
|KC_BSLASH|KC_BSLS|`\` and <code>&#124;</code> |
|KC_NONUS_HASH|KC_NUHS|Non-US `#` and `~`|
|KC_NONUS_BSLASH|KC_NUBS|Non-US `\` and <code>&#124;</code> |
|KC_INT1|KC_RO|JIS `\` and <code>&#124;</code> |
|KC_INT2|KC_KANA|International216|
|KC_INT3|KC_JYEN|Yen Symbol (`¥`)|
|KC_SCOLON|KC_SCLN|`;` and `:`|
|KC_QUOTE|KC_QUOT|`` and `“`|
|KC_GRAVE|KC_GRV|Grave Accent and Tilde|
|KC_COMMA|KC_COMM|`,` and `<`|
|KC_DOT||`.` and `>`|
|KC_SLASH|KC_SLSH|`/` and `?`|
|KC_CAPSLOCK|KC_CAPS|Caps Lock|
|Key |Aliases |Description |
|-----------------|---------|----------------------------------|
|`KC_ENTER` |`KC_ENT` |Return (Enter) |
|`KC_ESCAPE` |`KC_ESC` |Escape |
|`KC_BSPACE` |`KC_BSPC`|Delete (Backspace) |
|`KC_TAB` | |Tab |
|`KC_SPACE` |`KC_SPC` |Spacebar |
|`KC_MINUS` |`KC_MINS`|`-` and `_` |
|`KC_EQUAL` |`KC_EQL` |`=` and `+` |
|`KC_LBRACKET` |`KC_LBRC`|`[` and `{` |
|`KC_RBRACKET` |`KC_RBRC`|`]` and `}` |
|`KC_BSLASH` |`KC_BSLS`|`\` and <code>&#124;</code> |
|`KC_NONUS_HASH` |`KC_NUHS`|Non-US `#` and `~` |
|`KC_NONUS_BSLASH`|`KC_NUBS`|Non-US `\` and <code>&#124;</code>|
|`KC_INT1` |`KC_RO` |JIS `\` and <code>&#124;</code> |
|`KC_INT2` |`KC_KANA`|JIS Katakana/Hiragana |
|`KC_INT3` |`KC_JYEN`|JIS `¥` |
|`KC_SCOLON` |`KC_SCLN`|`;` and `:` |
|`KC_QUOTE` |`KC_QUOT`|`'` and `"` |
|`KC_GRAVE` |`KC_GRV` |<code>&#96;</code> and `~` |
|`KC_COMMA` |`KC_COMM`|`,` and `<` |
|`KC_DOT` | |`.` and `>` |
|`KC_SLASH` |`KC_SLSH`|`/` and `?` |
|`KC_CAPSLOCK` |`KC_CAPS`|Caps Lock |
## Modifiers
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_LCTRL|KC_LCTL|LeftControl|
|KC_LSHIFT|KC_LSFT|LeftShift|
|KC_LALT||LeftAlt|
|KC_LGUI||Left GUI(Windows/Apple/Meta key)|
|KC_RCTRL|KC_RCTL|RightControl|
|KC_RSHIFT|KC_RSFT|RightShift|
|KC_RALT||RightAlt|
|KC_RGUI||Right GUI(Windows/Apple/Meta key)|
|KC_LOCKING_CAPS|KC_LCAP|Locking Caps Lock|
|KC_LOCKING_NUM|KC_LNUM|Locking Num Lock|
|KC_LOCKING_SCROLL|KC_LSCR|Locking Scroll Lock|
|KC_INT4|KC_HENK|JIS Henken|
|KC_INT5|KC_MHEN|JIS Muhenken|
|Key |Aliases |Description |
|-------------------|--------------------|------------------------------------|
|`KC_LCTRL` |`KC_LCTL` |Left Control |
|`KC_LSHIFT` |`KC_LSFT` |Left Shift |
|`KC_LALT` | |Left Alt |
|`KC_LGUI` |`KC_LCMD`, `KC_LWIN`|Left GUI (Windows/Command/Meta key) |
|`KC_RCTRL` |`KC_RCTL` |Right Control |
|`KC_RSHIFT` |`KC_RSFT` |Right Shift |
|`KC_RALT` | |Right Alt |
|`KC_RGUI` |`KC_RCMD`, `KC_RWIN`|Right GUI (Windows/Command/Meta key)|
|`KC_LOCKING_CAPS` |`KC_LCAP` |Locking Caps Lock |
|`KC_LOCKING_NUM` |`KC_LNUM` |Locking Num Lock |
|`KC_LOCKING_SCROLL`|`KC_LSCR` |Locking Scroll Lock |
|`KC_INT4` |`KC_HENK` |JIS Henkan |
|`KC_INT5` |`KC_MHEN` |JIS Muhenkan |
## Commands
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_PSCREEN|KC_PSCR|PrintScreen|
|KC_SCROLLLOCK|KC_SLCK|Scroll Lock|
|KC_PAUSE|KC_PAUS|Pause|
|KC_INSERT|KC_INS|Insert|
|KC_HOME||Home|
|KC_PGUP||PageUp|
|KC_DELETE|KC_DEL|Delete Forward|
|KC_END||End|
|KC_PGDOWN|KC_PGDN|PageDown|
|KC_RIGHT|KC_RGHT|RightArrow|
|KC_LEFT||LeftArrow|
|KC_DOWN||DownArrow|
|KC_UP||UpArrow|
|KC_APPLICATION|KC_APP|Application|
|KC_POWER||Power|
|KC_EXECUTE||Execute|
|KC_HELP||Help|
|KC_MENU||Menu|
|KC_SELECT||Select|
|KC_AGAIN||Again|
|KC_UNDO||Undo|
|KC_CUT||Cut|
|KC_COPY||Copy|
|KC_PASTE||Paste|
|KC_FIND||Find|
|KC_ALT_ERASE||Alternate Erase|
|KC_SYSREQ||SysReq/Attention|
|KC_CANCEL||Cancel|
|KC_CLEAR||Clear|
|KC_PRIOR||Prior|
|KC_RETURN||Return|
|KC_SEPARATOR||Separator|
|KC_OUT||Out|
|KC_OPER||Oper|
|KC_CLEAR_AGAIN||Clear/Again|
|KC_CRSEL||CrSel/Props|
|KC_EXSEL||ExSel|
|KC_SYSTEM_POWER|KC_PWR|System Power Down|
|KC_SYSTEM_SLEEP|KC_SLEP|System Sleep|
|KC_SYSTEM_WAKE|KC_WAKE|System Wake|
|KC_MAIL|KC_MAIL||
|KC_CALCULATOR|KC_CALC||
|KC_MY_COMPUTER|KC_MYCM||
|KC_WWW_SEARCH|KC_WSCH||
|KC_WWW_HOME|KC_WHOM||
|KC_WWW_BACK|KC_WBAK||
|KC_WWW_FORWARD|KC_WFWD||
|KC_WWW_STOP|KC_WSTP||
|KC_WWW_REFRESH|KC_WREF||
|KC_WWW_FAVORITES|KC_WFAV||
|Key |Aliases |Description |
|------------------|---------|------------------------------|
|`KC_PSCREEN` |`KC_PSCR`|Print Screen |
|`KC_SCROLLLOCK` |`KC_SLCK`|Scroll Lock |
|`KC_PAUSE` |`KC_PAUS`|Pause |
|`KC_INSERT` |`KC_INS` |Insert |
|`KC_HOME` | |Home |
|`KC_PGUP` | |Page Up |
|`KC_DELETE` |`KC_DEL` |Forward Delete |
|`KC_END` | |End |
|`KC_PGDOWN` |`KC_PGDN`|Page Down |
|`KC_RIGHT` |`KC_RGHT`|Right Arrow |
|`KC_LEFT` | |Left Arrow |
|`KC_DOWN` | |Down Arrow |
|`KC_UP` | |Up Arrow |
|`KC_APPLICATION` |`KC_APP` |Application (Windows Menu Key)|
|`KC_POWER` | |Power |
|`KC_EXECUTE` | |Execute |
|`KC_HELP` | |Help |
|`KC_MENU` | |Menu |
|`KC_SELECT` | |Select |
|`KC_AGAIN` | |Again |
|`KC_UNDO` | |Undo |
|`KC_CUT` | |Cut |
|`KC_COPY` | |Copy |
|`KC_PASTE` | |Paste |
|`KC_FIND` | |Find |
|`KC_ALT_ERASE` | |Alternate Erase |
|`KC_SYSREQ` | |SysReq/Attention |
|`KC_CANCEL` | |Cancel |
|`KC_CLEAR` | |Clear |
|`KC_PRIOR` | |Prior |
|`KC_RETURN` | |Return |
|`KC_SEPARATOR` | |Separator |
|`KC_OUT` | |Out |
|`KC_OPER` | |Oper |
|`KC_CLEAR_AGAIN` | |Clear/Again |
|`KC_CRSEL` | |CrSel/Props |
|`KC_EXSEL` | |ExSel |
## Media Keys
Windows and Mac use different key codes for next track and previous track. Make sure you choose the keycode that corresponds to your OS.
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_STOP||Stop|
|KC__MUTE||Mute (macOS)|
|KC__VOLUP||Volume Up (macOS)|
|KC__VOLDOWN||Volume Down (macOS)|
|KC_AUDIO_MUTE|KC_MUTE|Mute (Windows/macOS/Linux)|
|KC_AUDIO_VOL_UP|KC_VOLU|Volume Up (Windows/macOS/Linux)|
|KC_AUDIO_VOL_DOWN|KC_VOLD|Volume Down (Windows/macOS/Linux)|
|KC_MEDIA_NEXT_TRACK|KC_MNXT|Next Track (Windows)|
|KC_MEDIA_PREV_TRACK|KC_MPRV|Previous Track (Windows)|
|KC_MEDIA_FAST_FORWARD|KC_MFFD|Next Track (macOS)|
|KC_MEDIA_REWIND|KC_MRWD|Previous Track (macOS)|
|KC_MEDIA_STOP|KC_MSTP||
|KC_MEDIA_PLAY_PAUSE|KC_MPLY||
|KC_MEDIA_SELECT|KC_MSEL||
## Numpad
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_NUMLOCK|KC_NLCK|Keypad Num Lock and Clear|
|KC_KP_SLASH|KC_PSLS|Keypad /|
|KC_KP_ASTERISK|KC_PAST|Keypad *|
|KC_KP_MINUS|KC_PMNS|Keypad -|
|KC_KP_PLUS|KC_PPLS|Keypad +|
|KC_KP_ENTER|KC_PENT|Keypad ENTER|
|KC_KP_1|KC_P1|Keypad 1 and End|
|KC_KP_2|KC_P2|Keypad 2 and Down Arrow|
|KC_KP_3|KC_P3|Keypad 3 and PageDn|
|KC_KP_4|KC_P4|Keypad 4 and Left Arrow|
|KC_KP_5|KC_P5|Keypad 5|
|KC_KP_6|KC_P6|Keypad 6 and Right Arrow|
|KC_KP_7|KC_P7|Keypad 7 and Home|
|KC_KP_8|KC_P8|Keypad 8 and Up Arrow|
|KC_KP_9|KC_P9|Keypad 9 and PageUp|
|KC_KP_0|KC_P0|Keypad 0 and Insert|
|KC_KP_DOT|KC_PDOT|Keypad . and Delete|
|KC_KP_EQUAL|KC_PEQL|Keypad =|
|KC_KP_COMMA|KC_PCMM|Keypad Comma|
|KC_KP_EQUAL_AS400||Keypad Equal Sign|
These keycodes are not part of the Keyboard/Keypad usage page. The `SYSTEM_` keycodes are found in the Generic Desktop page, and the rest are located in the Consumer page.
Windows and macOS use different keycodes for "next track" and "previous track". Make sure you choose the keycode that corresponds to your OS.
|Key |Aliases |Description |
|-----------------------|---------|---------------------------------|
|`KC_SYSTEM_POWER` |`KC_PWR` |System Power Down |
|`KC_SYSTEM_SLEEP` |`KC_SLEP`|System Sleep |
|`KC_SYSTEM_WAKE` |`KC_WAKE`|System Wake |
|`KC_MAIL` |`KC_MAIL`| |
|`KC_CALCULATOR` |`KC_CALC`| |
|`KC_MY_COMPUTER` |`KC_MYCM`| |
|`KC_WWW_SEARCH` |`KC_WSCH`| |
|`KC_WWW_HOME` |`KC_WHOM`| |
|`KC_WWW_BACK` |`KC_WBAK`| |
|`KC_WWW_FORWARD` |`KC_WFWD`| |
|`KC_WWW_STOP` |`KC_WSTP`| |
|`KC_WWW_REFRESH` |`KC_WREF`| |
|`KC_STOP` | |Stop |
|`KC_WWW_FAVORITES` |`KC_WFAV`| |
|`KC__MUTE` | |Mute (macOS) |
|`KC__VOLUP` | |Volume Up (macOS) |
|`KC__VOLDOWN` | |Volume Down (macOS) |
|`KC_AUDIO_MUTE` |`KC_MUTE`|Mute (Windows/macOS/Linux) |
|`KC_AUDIO_VOL_UP` |`KC_VOLU`|Volume Up (Windows/macOS/Linux) |
|`KC_AUDIO_VOL_DOWN` |`KC_VOLD`|Volume Down (Windows/macOS/Linux)|
|`KC_MEDIA_NEXT_TRACK` |`KC_MNXT`|Next Track (Windows) |
|`KC_MEDIA_PREV_TRACK` |`KC_MPRV`|Previous Track (Windows) |
|`KC_MEDIA_FAST_FORWARD`|`KC_MFFD`|Next Track (macOS) |
|`KC_MEDIA_REWIND` |`KC_MRWD`|Previous Track (macOS) |
|`KC_MEDIA_STOP` |`KC_MSTP`|Stop Track |
|`KC_MEDIA_PLAY_PAUSE` |`KC_MPLY`|Play/Pause Track |
|`KC_MEDIA_SELECT` |`KC_MSEL`| |
## Number Pad
|Key |Aliases |Description |
|-------------------|---------|------------------------------|
|`KC_NUMLOCK` |`KC_NLCK`|Keypad Num Lock and Clear |
|`KC_KP_SLASH` |`KC_PSLS`|Keypad `/` |
|`KC_KP_ASTERISK` |`KC_PAST`|Keypad `*` |
|`KC_KP_MINUS` |`KC_PMNS`|Keypad `-` |
|`KC_KP_PLUS` |`KC_PPLS`|Keypad `+` |
|`KC_KP_ENTER` |`KC_PENT`|Keypad Enter |
|`KC_KP_1` |`KC_P1` |Keypad `1` and End |
|`KC_KP_2` |`KC_P2` |Keypad `2` and Down Arrow |
|`KC_KP_3` |`KC_P3` |Keypad `3` and Page Down |
|`KC_KP_4` |`KC_P4` |Keypad `4` and Left Arrow |
|`KC_KP_5` |`KC_P5` |Keypad `5` |
|`KC_KP_6` |`KC_P6` |Keypad `6` and Right Arrow |
|`KC_KP_7` |`KC_P7` |Keypad `7` and Home |
|`KC_KP_8` |`KC_P8` |Keypad `8` and Up Arrow |
|`KC_KP_9` |`KC_P9` |Keypad `9` and Page Up |
|`KC_KP_0` |`KC_P0` |Keypad `0` and Insert |
|`KC_KP_DOT` |`KC_PDOT`|Keypad `.` and Delete |
|`KC_KP_EQUAL` |`KC_PEQL`|Keypad `=` |
|`KC_KP_COMMA` |`KC_PCMM`|Keypad `,` |
|`KC_KP_EQUAL_AS400`| |Keypad `=` on AS/400 keyboards|
## Special Keys
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_NO||Ignore this key. (NOOP) |
## Mousekey
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_MS_UP|KC_MS_U|Mouse Cursor Up|
|KC_MS_DOWN|KC_MS_D|Mouse Cursor Down|
|KC_MS_LEFT|KC_MS_L|Mouse Cursor Left|
|KC_MS_RIGHT|KC_MS_R|Mouse Cursor Right|
|KC_MS_BTN1|KC_BTN1|Mouse Button 1|
|KC_MS_BTN2|KC_BTN2|Mouse Button 2|
|KC_MS_BTN3|KC_BTN3|Mouse Button 3|
|KC_MS_BTN4|KC_BTN4|Mouse Button 4|
|KC_MS_BTN5|KC_BTN5|Mouse Button 5|
|KC_MS_WH_UP|KC_WH_U|Mouse Wheel Up|
|KC_MS_WH_DOWN|KC_WH_D|Mouse Wheel Down|
|KC_MS_WH_LEFT|KC_WH_L|Mouse Wheel Left|
|KC_MS_WH_RIGHT|KC_WH_R|Mouse Wheel Right|
|KC_MS_ACCEL0|KC_ACL0|Mouse Acceleration 0|
|KC_MS_ACCEL1|KC_ACL1|Mouse Acceleration 1|
|KC_MS_ACCEL2|KC_ACL2|Mouse Acceleration 2|
In addition to these, keycodes in the range of `0xA5-DF` are reserved for internal use by TMK.
|Key |Aliases |Description |
|----------------|---------|---------------------------------------|
|`KC_NO` | |Ignore this key (NOOP) |
|`KC_TRANSPARENT`|`KC_TRNS`|Use the next lowest non-transparent key|

@ -1,31 +1,31 @@
# US ANSI Shifted symbols
# US ANSI Shifted Symbols
These keycodes correspond to characters that are "shifted" on a standard US ANSI keyboards. They do not have dedicated keycodes but are instead typed by holding down shift and then sending a keycode.
These keycodes correspond to characters that are "shifted" on a standard US ANSI keyboards. They do not have dedicated keycodes but are instead typed by holding down shift and then sending a keycode.
It's important to remember that all of these keycodes send a left shift - this may cause unintended actions if unaccounted for. The short code is preferred in most situations.
## US ANSI Shifted Keycodes
|Short Name|Long Name|Description|
|----------|---------|-----------|
|`KC_TILD`|`KC_TILDE`|tilde `~`|
|`KC_EXLM`|`KC_EXCLAIM`|exclamation mark `!`|
|`KC_AT`||at sign `@`|
|`KC_HASH`||hash sign `#`|
|`KC_DLR`|`KC_DOLLAR`|dollar sign `$`|
|`KC_PERC`|`KC_PERCENT`|percent sign `%`|
|`KC_CIRC`|`KC_CIRCUMFLEX`|circumflex `^`|
|`KC_AMPR`|`KC_AMPERSAND`|ampersand `&`|
|`KC_ASTR`|`KC_ASTERISK`|asterisk `*`|
|`KC_LPRN`|`KC_LEFT_PAREN`|left parenthesis `(`|
|`KC_RPRN`|`KC_RIGHT_PAREN`|right parenthesis `)`|
|`KC_UNDS`|`KC_UNDERSCORE`|underscore `_`|
|`KC_PLUS`||plus sign `+`|
|`KC_LCBR`|`KC_LEFT_CURLY_BRACE`|left curly brace `{`|
|`KC_RCBR`|`KC_RIGHT_CURLY_BRACE`|right curly brace `}`|
|`KC_LT`/`KC_LABK`|`KC_LEFT_ANGLE_BRACKET`|left angle bracket `<`|
|`KC_GT`/`KC_RABK`|`KC_RIGHT_ANGLE_BRACKET`|right angle bracket `>`|
|`KC_COLN`|`KC_COLON`|colon `:`|
|`KC_PIPE`||pipe `\|`|
|`KC_QUES`|`KC_QUESTION`|question mark `?`|
|`KC_DQT`/`KC_DQUO`|`KC_DOUBLE_QUOTE`|double quote `"`|
|Key |Aliases |Description |
|------------------------|------------------|-------------------|
|`KC_TILDE` |`KC_TILD` |`~` |
|`KC_EXCLAIM` |`KC_EXLM` |`!` |
|`KC_AT` | |`@` |
|`KC_HASH` | |`#` |
|`KC_DOLLAR` |`KC_DLR` |`$` |
|`KC_PERCENT` |`KC_PERC` |`%` |
|`KC_CIRCUMFLEX` |`KC_CIRC` |`^` |
|`KC_AMPERSAND` |`KC_AMPR` |`&` |
|`KC_ASTERISK` |`KC_ASTR` |`*` |
|`KC_LEFT_PAREN` |`KC_LPRN` |`(` |
|`KC_RIGHT_PAREN` |`KC_RPRN` |`)` |
|`KC_UNDERSCORE` |`KC_UNDS` |`_` |
|`KC_PLUS` | |`+` |
|`KC_LEFT_CURLY_BRACE` |`KC_LCBR` |`{` |
|`KC_RIGHT_CURLY_BRACE` |`KC_RCBR` |`}` |
|`KC_PIPE` | |<code>&#124;</code>|
|`KC_COLON` |`KC_COLN` |`:` |
|`KC_DOUBLE_QUOTE` |`KC_DQT`/`KC_DQUO`|`"` |
|`KC_LEFT_ANGLE_BRACKET` |`KC_LT`/`KC_LABK` |`<` |
|`KC_RIGHT_ANGLE_BRACKET`|`KC_GT`/`KC_RABK` |`>` |
|`KC_QUESTION` |`KC_QUES` |`?` |

@ -3,7 +3,7 @@
QMK keymaps are defined inside a C source file. The data structure is an array of arrays. The outer array is a list of layer arrays while the inner layer array is a list of keys. Most keyboards define a `KEYMAP()` macro to help you create this array of arrays.
## Keymap and layers
## Keymap and Layers
In QMK, **`const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS]`** holds multiple **layers** of keymap information in **16 bit** data holding the **action code**. You can define **32 layers** at most.
For trivial key definitions, the higher 8 bits of the **action code** are all 0 and the lower 8 bits holds the USB HID usage code generated by the key as **keycode**.
@ -27,18 +27,16 @@ Respective layers can be validated simultaneously. Layers are indexed with 0 to
Sometimes, the action code stored in keymap may be referred as keycode in some documents due to the TMK history.
### Keymap layer status
Keymap layer has its state in two 32 bit parameters:
### Keymap Layer Status
The state of the Keymap layer is determined by two 32 bit parameters:
* **`default_layer_state`** indicates a base keymap layer(0-31) which is always valid and to be referred.
* **`layer_state`** () has current on/off status of the layer on its each bit.
* **`default_layer_state`** indicates a base keymap layer (0-31) which is always valid and to be referred (the default layer).
* **`layer_state`** has current on/off status of each layer in its bits.
Keymap has its state in two parameter **`default_layer`** indicates a base keymap layer(0-31) which is always valid and to be referred, **`keymap_stat`** is 16bit variable which has current on/off status of layers on its each bit.
Keymap layer '0' is usually `default_layer` and which is the only valid layer and other layers is initially off after boot up firmware, though, you can configured them in `config.h`.
To change `default_layer` will be useful when you switch key layout completely, say you want Colmak instead of Qwerty.
Keymap layer '0' is usually the `default_layer`, with other layers initially off after booting up the firmware, although this can configured differently in `config.h`. It is useful to change `default_layer` when you completely switch a key layout, for example, if you want to switch to Colemak instead of Qwerty.
Initial state of Keymap Change base layout
----------------------- ------------------
Initial state of Keymap Change base layout
----------------------- ------------------
31 31
30 30
@ -52,7 +50,7 @@ To change `default_layer` will be useful when you switch key layout completely,
`--- default_layer = 0 `--- default_layer = 1
layer_state = 0x00000001 layer_state = 0x00000002
On the other hand, you shall change `layer_state` to overlay base layer with some layers for feature such as navigation keys, function key(F1-F12), media keys or special actions.
On the other hand, you can change `layer_state` to overlay the base layer with other layers for features such as navigation keys, function keys (F1-F12), media keys, and/or special actions.
Overlay feature layer
--------------------- bit|status
@ -77,9 +75,9 @@ Note that ***higher layer has higher priority on stack of layers***, namely firm
You can place `KC_TRANS` on overlay layer changes just part of layout to fall back on lower or base layer.
Key with `KC_TRANS` (`KC_TRNS` and `_______` are the alias) doesn't has its own keycode and refers to lower valid layers for keycode, instead.
## Anatomy Of A `keymap.c`
## Anatomy of a `keymap.c`
For this example we will walk through the [default Clueboard 66% keymap](https://github.com/qmk/qmk_firmware/blob/master/keyboards/clueboard_66/keymaps/default/keymap.c). You'll find it helpful to open that file in another browser window so you can look at everything in context.
For this example we will walk through an [older version of the default Clueboard 66% keymap](https://github.com/qmk/qmk_firmware/blob/ca01d94005f67ec4fa9528353481faa622d949ae/keyboards/clueboard/keymaps/default/keymap.c). You'll find it helpful to open that file in another browser window so you can look at everything in context.
There are 3 main sections of a `keymap.c` file you'll want to concern yourself with:
@ -100,7 +98,7 @@ At the top of the file you'll find this:
// Each layer gets a name for readability.
// 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
// Layer names don't all need to be of the same
// length, and you can also skip them entirely
// and just use numbers.
#define _BL 0
@ -115,9 +113,9 @@ The main part of this file is the `keymaps[]` definition. This is where you list
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
After this you'll find a list of KEYMAP() macros. A KEYMAP() is simply a list of keys to define a single layer. Typically you'll have one or more "base layers" (such as QWERTY, Dvorak, or Colemak) and then you'll layer on top of that one or more "function" layers. Due to the way layers are processed you can't overlay a "lower" layer on top of a "higher" layer.
After this you'll find a list of KEYMAP() macros. A KEYMAP() is simply a list of keys to define a single layer. Typically you'll have one or more "base layers" (such as QWERTY, Dvorak, or Colemak) and then you'll layer on top of that one or more "function" layers. Due to the way layers are processed you can't overlay a "lower" layer on top of a "higher" layer.
`keymaps[][MATRIX_ROWS][MATRIX_COLS]` in QMK holds the 16 bit action code (sometimes referred as the quantum keycode) in it. For the keycode representing typical keys, its high byte is 0 and its low byte is the USB HID usage ID for keyboard.
`keymaps[][MATRIX_ROWS][MATRIX_COLS]` in QMK holds the 16 bit action code (sometimes referred as the quantum keycode) in it. For the keycode representing typical keys, its high byte is 0 and its low byte is the USB HID usage ID for keyboard.
> TMK from which QMK was forked uses `const uint8_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS]` instead and holds the 8 bit keycode. Some keycode values are reserved to induce execution of certain action codes via the `fn_actions[]` array.
@ -155,11 +153,11 @@ Our function layer is, from a code point of view, no different from the base lay
Some interesting things to note:
* We have used our `_______` definition to turn `KC_TRNS` into `_______`. This makes it easier to spot the keys that have changed on this layer.
* While in this layer if you press one of the `_______` keys it will activate the key in the next lowest active layer.
* While in this layer if you press one of the `_______` keys it will activate the key in the next lowest active layer.
### Custom Functions
At the bottom of the file we've defined a single custom function. This function defines a key that sends `KC_ESC` when pressed without modifiers and `KC_GRAVE` when modifiers are held. There are a couple pieces that need to be in place for this to work, and we will go over both of them.
At the bottom of the file we've defined a single custom function. This function defines a key that sends `KC_ESC` when pressed without modifiers and `KC_GRAVE` when modifiers are held. There are a couple pieces that need to be in place for this to work, and we will go over both of them.
#### `fn_actions[]`
@ -173,6 +171,8 @@ In this case we've instructed QMK to call the `ACTION_FUNCTION` callback, which
> This `fn_actions[]` interface is mostly for backward compatibility. In QMK, you don't need to use `fn_actions[]`. You can directly use `ACTION_FUNCTION(N)` or any other action code value itself normally generated by the macro in `keymaps[][MATRIX_ROWS][MATRIX_COLS]`. N in `F(N)` can only be 0 to 31. Use of the action code directly in `keymaps` unlocks this limitation.
You can get a full list of Action Functions in [action_code.h](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/action_code.h).
#### `action_function()`
To actually handle the keypress event we define an `action_function()`. This function will be called when the key is pressed, and then again when the key is released. We have to handle both situations within our code, as well as determining whether to send/release `KC_ESC` or `KC_GRAVE`.

@ -1,220 +0,0 @@
# Macros
Macros allow you to send multiple keystrokes when pressing just one key. QMK has a number of ways to define and use macros. These can do anything you want: type common phrases for you, copypasta, repetitive game movements, or even help you code.
{% hint style='danger' %}
**Security Note**: While it is possible to use macros to send passwords, credit card numbers, and other sensitive information it is a supremely bad idea to do so. Anyone who gets ahold of your keyboard will be able to access that information by opening a text editor.
{% endhint %}
## The new way: `SEND_STRING()` & `process_record_user`
Sometimes you just want a key to type out words or phrases. For the most common situations we've provided `SEND_STRING()`, which will type out your string for you. All ascii that is easily translated to a keycode is supported (eg `\n\t`).
For example:
```c
enum custom_keycodes {
PRINT_TRUTH = SAFE_RANGE
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
if (record->event.pressed) {
switch(keycode) {
case PRINT_TRUTH:
SEND_STRING("QMK is the best thing ever!");
return false; break;
}
}
return true;
};
```
### Tap/down/up
You can send arbitary keycodes by wrapping them in:
* `SS_TAP()`
* `SS_DOWN()`
* `SS_UP()`
For example:
SEND_STRING(SS_TAP(X_HOME));
Would tap `KC_HOME` - note how the prefix is now `X_`, and not `KC_`. You can also combine this with other strings, like this:
SEND_STRING("VE"SS_TAP(X_HOME)"LO");
Which would send "VE" followed by a `KC_HOME` tap, and "LO" (spelling "LOVE" if on a newline).
There's also a couple of mod shortcuts you can use:
* `SS_LCTRL(string)`
* `SS_LGUI(string)`
* `SS_LALT(string)`
That can be used like this:
SEND_STRING(SS_LCTRL("a"));
Which would send LCTRL+a (LTRL down, a, LTRL up) - notice that they take strings (eg `"k"`), and not the `X_K` keycodes.
### Alternative keymaps
By default, it assumes a US keymap with a QWERTY layout; if you want to change that (e.g. if your OS uses software Colemak), include this somewhere in your keymap:
#include <sendstring_colemak.h>
### Strings in memory
If for some reason you're manipulating strings and need to print out something you just generated (instead of being a literal, constant string), you can use `send_string()`, like this:
```c
char my_str[4] = "ok.";
send_string(my_str);
```
The shortcuts defined above won't work with `send_string()`, but you can separate things out to different lines if needed:
```c
char my_str[4] = "ok.";
SEND_STRING("I said: ");
send_string(my_str);
SEND_STRING(".."SS_TAP(X_END));
```
## The old way: `MACRO()` & `action_get_macro`
{% hint style='info' %}
This is inherited from TMK, and hasn't been updated - it's recommend that you use `SEND_STRING` and `process_record_user` instead.
{% endhint %}
By default QMK assumes you don't have any macros. To define your macros you create an `action_get_macro()` function. For example:
```c
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
if (record->event.pressed) {
switch(id) {
case 0:
return MACRO(D(LSFT), T(H), U(LSFT), T(I), D(LSFT), T(1), U(LSFT), END);
case 1:
return MACRO(D(LSFT), T(B), U(LSFT), T(Y), T(E), D(LSFT), T(1), U(LSFT), END);
}
}
return MACRO_NONE;
};
```
This defines two macros which will be run when the key they are assigned to is pressed. If instead you'd like them to run when the key is released you can change the if statement:
if (!record->event.pressed) {
### Macro Commands
A macro can include the following commands:
* I() change interval of stroke in milliseconds.
* D() press key.
* U() release key.
* T() type key(press and release).
* W() wait (milliseconds).
* END end mark.
### Mapping a Macro to a key
Use the `M()` function within your `KEYMAP()` to call a macro. For example, here is the keymap for a 2-key keyboard:
```c
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = KEYMAP(
M(0), M(1)
),
};
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
if (record->event.pressed) {
switch(id) {
case 0:
return MACRO(D(LSFT), T(H), U(LSFT), T(I), D(LSFT), T(1), U(LSFT), END);
case 1:
return MACRO(D(LSFT), T(B), U(LSFT), T(Y), T(E), D(LSFT), T(1), U(LSFT), END);
}
}
return MACRO_NONE;
};
```
When you press the key on the left it will type "Hi!" and when you press the key on the right it will type "Bye!".
### Naming your macros
If you have a bunch of macros you want to refer to from your keymap while keeping the keymap easily readable you can name them using `#define` at the top of your file.
```c
#define M_HI M(0)
#define M_BYE M(1)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = KEYMAP(
M_HI, M_BYE
),
};
```
## Advanced macro functions
There are some functions you may find useful in macro-writing. Keep in mind that while you can write some fairly advanced code within a macro if your functionality gets too complex you may want to define a custom keycode instead. Macros are meant to be simple.
### `record->event.pressed`
This is a boolean value that can be tested to see if the switch is being pressed or released. An example of this is
```c
if (record->event.pressed) {
// on keydown
} else {
// on keyup
}
```
### `register_code(<kc>);`
This sends the `<kc>` keydown event to the computer. Some examples would be `KC_ESC`, `KC_C`, `KC_4`, and even modifiers such as `KC_LSFT` and `KC_LGUI`.
### `unregister_code(<kc>);`
Parallel to `register_code` function, this sends the `<kc>` keyup event to the computer. If you don't use this, the key will be held down until it's sent.
### `clear_keyboard();`
This will clear all mods and keys currently pressed.
### `clear_mods();`
This will clear all mods currently pressed.
### `clear_keyboard_but_mods();`
This will clear all keys besides the mods currently pressed.
## Advanced Example: Single-key copy/paste
This example defines a macro which sends `Ctrl-C` when pressed down, and `Ctrl-V` when released.
```c
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
switch(id) {
case 0: {
if (record->event.pressed) {
return MACRO( D(LCTL), T(C), U(LCTL), END );
} else {
return MACRO( D(LCTL), T(V), U(LCTL), END );
}
break;
}
}
return MACRO_NONE;
};
```

@ -1,81 +0,0 @@
# Mousekeys
Mousekeys is a feature that allows you to emulate a mouse using your keyboard. You can move the pointer around, click up to 5 buttons, and even scroll in all 4 directions. QMK uses the same algorithm as the X Window System MouseKeysAccel feature. You can read more about it [on Wikipedia](https://en.wikipedia.org/wiki/Mouse_keys).
## Adding Mousekeys To a Keymap
There are two steps to adding Mousekeys support to your keyboard. You must enable support in the Makefile and you must map mouse actions to keys on your keyboard.
### Adding Mousekeys support in the `Makefile`
To add support for Mousekeys you simply need to add a single line to your keymap's `Makefile`:
```
MOUSEKEY_ENABLE = yes
```
You can see an example here: https://github.com/qmk/qmk_firmware/blob/master/keyboards/clueboard/keymaps/mouse_keys/Makefile
### Mapping Mouse Actions To Keyboard Keys
You can use these keycodes within your keymap to map button presses to mouse actions:
|Long Name|Short Name|Description|
|---------|----------|-----------|
|KC_MS_UP|KC_MS_U|Mouse Cursor Up|
|KC_MS_DOWN|KC_MS_D|Mouse Cursor Down|
|KC_MS_LEFT|KC_MS_L|Mouse Cursor Left|
|KC_MS_RIGHT|KC_MS_R|Mouse Cursor Right|
|KC_MS_BTN1|KC_BTN1|Mouse Button 1|
|KC_MS_BTN2|KC_BTN2|Mouse Button 2|
|KC_MS_BTN3|KC_BTN3|Mouse Button 3|
|KC_MS_BTN4|KC_BTN4|Mouse Button 4|
|KC_MS_BTN5|KC_BTN5|Mouse Button 5|
|KC_MS_WH_UP|KC_WH_U|Mouse Wheel Up|
|KC_MS_WH_DOWN|KC_WH_D|Mouse Wheel Down|
|KC_MS_WH_LEFT|KC_WH_L|Mouse Wheel Left|
|KC_MS_WH_RIGHT|KC_WH_R|Mouse Wheel Right|
|KC_MS_ACCEL0|KC_ACL0|Set Mouse Acceleration Speed to 0|
|KC_MS_ACCEL1|KC_ACL1|Set Mouse Acceleration Speed to 1|
|KC_MS_ACCEL2|KC_ACL2|Set Mouse Acceleration Speed to 2|
You can see an example in the `_ML` here: https://github.com/qmk/qmk_firmware/blob/master/keyboards/clueboard/keymaps/mouse_keys/keymap.c#L46
## Configuring the behavior of Mousekeys
The default speed for controlling the mouse with the keyboard is intentionaly slow. You can adjust these parameters by adding these settings to your keymap's `config.h` file. All times are specified in miliseconds (ms).
```
#define MOUSEKEY_DELAY 300
#define MOUSEKEY_INTERVAL 50
#define MOUSEKEY_MAX_SPEED 10
#define MOUSEKEY_TIME_TO_MAX 20
#define MOUSEKEY_WHEEL_MAX_SPEED 8
#define MOUSEKEY_WHEEL_TIME_TO_MAX 40
```
### `MOUSEKEY_DELAY`
When one of the mouse movement buttons is pressed this setting is used to define the delay between that button press and the mouse cursor moving. Some people find that small movements are impossible if this setting is too low, while settings that are too high feel sluggish.
### `MOUSEKEY_INTERVAL`
When a movement key is held down this specifies how long to wait between each movement report. Lower settings will translate into an effectively higher mouse speed.
### `MOUSEKEY_MAX_SPEED`
As a movement key is held down the speed of the mouse cursor will increase until it reaches `MOUSEKEY_MAX_SPEED`.
### `MOUSEKEY_TIME_TO_MAX`
How long you want to hold down a movement key for until `MOUSEKEY_MAX_SPEED` is reached. This controls how quickly your cursor will accelerate.
### `MOUSEKEY_WHEEL_MAX_SPEED`
The top speed for scrolling movements.
### `MOUSEKEY_WHEEL_TIME_TO_MAX`
How long you want to hold down a scroll key for until `MOUSEKEY_WHEEL_MAX_SPEED` is reached. This controls how quickling your scrolling will accelerate.

@ -0,0 +1,16 @@
# The Compelete Newbs Guide To QMK
QMK is a powerful Open Source firmware for your mechanical keyboard. You can use QMK to customize your keyboard in ways both simple and powerful. People of all skill levels, from complete newbie to master programmer, have successfully used QMK to customize their keyboard. This guide will help you do the same, no matter your skill level.
Not sure if your keyboard can run QMK? If it's a mechanical keyboard you built yourself chances are good it can. We support a [large number of hobbyist boards](http://qmk.fm/keyboards/), so even if your current keyboard can't run QMK you shouldn't have trouble finding one to suit your needs.
## Overview
There are 4 main sections to this guide:
* [Getting Started](newbs_getting_started.md)
* [Building Your First Firmware](newbs_building_firmware.md)
* [Flashing Firmware](newbs_flashing.md)
* [Testing and Debugging](newbs_testing_debugging.md)
This guide is focused on helping someone who has never compiled software before. It makes choices and recommendations based on that viewpoint. There are alternative methods for many of these procedures, and we support most of those alternatives. If you have any doubt about how to accomplish a task you can [ask us for guidance](getting_started_getting_help.md).

@ -0,0 +1,73 @@
# Building Your First Firmware
Now that you have setup your build environment you are ready to start building custom firmware. For this section of the guide we will bounce between 3 programs- your file manager, your text editor, and your terminal window. Keep all 3 open until you are done and happy with your keyboard firmware.
If you have closed and reopened your terminal window since following the first part of the guide, don't forget to `cd qmk_firmware` so that your terminal is in the correct directory.
## Navigate To Your Keymaps Folder
Start by navigating to the `keymaps` folder for your keyboard.
{% hint style='info' %}
If you are on macOS or Windows there are commands you can use to easily open the keymaps folder.
macOS:
open keyboards/<keyboard_folder>/keymaps
Windows:
start keyboards/<keyboard_folder>/keymaps
{% endhint %}
## Create a Copy Of The `default` Keymap
Once you have the `keymaps` folder open you will want to create a copy of the `default` folder. We highly recommend you name your folder the same as your GitHub username, but you can use any name you want as long as it contains only lower case letters, numbers, and the underscore character.
## Open `keymap.c` In Your Favorite Text Editor
Open up your `keymap.c`. Inside this file you'll find the structure that controls how your keyboard behaves. At the top of `keymap.c` there may be some defines and enums that make the keymap easier to read. Farther down you'll find a line that looks like this:
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
This line indicates the start of the list of Layers. Below that you'll find lines containing either `LAYOUT` or `KEYMAP`, and these lines indicate the start of a layer. Below that line is the list of keys that comprise a that particular layer.
{% hint style='danger' %}
When editing your keymap file be careful not to add or remove any commas. If you do you will prevent your firmware from compiling and it may not be easy to figure out where the extra, or missing, comma is.
{% endhint %}
## Customize The Layout To Your Liking
How to complete this step is entirely up to you. Make the one change that's been bugging you, or completely rework everything. You can remove layers if you don't need all of them, or add layers up to a total of 32. Check the following documentation to find out what you can define here:
* [Keycodes](keycodes.md)
* [Features](features.md)
* [FAQ](faq.md)
{% hint style='info' %}
While you get a feel for how keymaps work, keep each change small. Bigger changes make it harder to debug any problems that arise.
{% endhint %}
## Build Your Firmware
When your changes to the keymap are complete you will need to build the firmware. To do so go back to your terminal window and run the build command:
make <my_keyboard>:<my_keymap>
For example, if your keymap is named "xyverz" and you're building a keymap for a rev5 planck, you'll use this command:
make planck/rev5:xyverz
While this compiles you will have a lot of output going to the screen informing you of what files are being compiled. It should end with output that looks similar to this:
```
Linking: .build/planck_rev5_xyverz.elf [OK]
Creating load file for flashing: .build/planck_rev5_xyverz.hex [OK]
Copying planck_rev5_xyverz.hex to qmk_firmware folder [OK]
Checking file size of planck_rev5_xyverz.hex [OK]
* File size is fine - 18392/28672
```
## Flash Your Firmware
Move on to [Flashing Firmware](newbs_flashing.md) to learn how to write your new firmware to your keyboard.

@ -0,0 +1,242 @@
# Flashing Your Keyboard
Now that you've built a custom firmware file you'll want to flash your keyboard.
## Flashing Your Keyboard with QMK Toolbox
The simplest way to flash your keyboard will be with the [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases).
However, the QMK Toolbox is only available for Windows and macOS currently. If you're using Linux (or just wish to flash the firmware from the command line), you'll have to use the [method outlined below](newbs_flashing.md#flash-your-keyboard-from-the-command-line).
### Load The File Into QMK Toolbox
Begin by opening the QMK Toolbox application. You'll want to locate the firmware file in Finder or Explorer. Your keyboard firmware may be in one of two formats- `.hex` or `.bin`. QMK tries to copy the appropriate one for your keyboard into the root `qmk_firmware` directory.
{% hint style='info' %}
If you are on Windows or macOS there are commands you can use to easily open the current firmware folder in Explorer or Finder.
Windows:
start .
macOS:
open .
{% endhint %}
The firmware file always follows this naming format:
<keyboard_name>_<keymap_name>.{bin,hex}
For example, the `plank/rev5` with a `default` keymap will have this filename:
planck_rev5_default.hex
Once you have located your firmware file drag it into the "Local file" box in QMK Toolbox, or click "Open" and navigate to where your firmware file is stored.
### Put Your Keyboard Into DFU (Bootloader) Mode
In order to flash your custom firmware you have to put your keyboard into a special flashing mode. While it is in this mode you will not be able to type or otherwise use your keyboard. It is very important that you do not unplug your keyboard or otherwise interrupt the flashing process while the firmware is being written.
Different keyboards have different ways to enter this special mode. If your PCB currently runs QMK or TMK and you have not been given specific instructions try the following, in order:
* Hold down both shift keys and press `Pause`
* Hold down both shift keys and press `B`
* Unplug your keyboard, hold down the Spacebar and `B` at the same time, plug in your keyboard and wait a second before releasing the keys
* Press the physical `RESET` button on the bottom of the PCB
* Locate header pins on the PCB labeled `BOOT0` or `RESET`, short those together while plugging your PCB in
When you are successful you will see a message similar to this in QMK Toolbox:
```
*** Clueboard - Clueboard 66% HotSwap disconnected -- 0xC1ED:0x2390
*** DFU device connected
```
### Flash Your Keyboard
Click the `Flash` button in QMK Toolbox. You will see output similar to the following:
```
*** Clueboard - Clueboard 66% HotSwap disconnected -- 0xC1ED:0x2390
*** DFU device connected
*** Attempting to flash, please don't remove device
>>> dfu-programmer atmega32u4 erase --force
Erasing flash... Success
Checking memory from 0x0 to 0x6FFF... Empty.
>>> dfu-programmer atmega32u4 flash /Users/skully/qmk_firmware/clueboard_66_hotswap_gen1_skully.hex
Checking memory from 0x0 to 0x55FF... Empty.
0% 100% Programming 0x5600 bytes...
[>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
0% 100% Reading 0x7000 bytes...
[>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
Validating... Success
0x5600 bytes written into 0x7000 bytes memory (76.79%).
>>> dfu-programmer atmega32u4 reset
*** DFU device disconnected
*** Clueboard - Clueboard 66% HotSwap connected -- 0xC1ED:0x2390
```
## Flash your Keyboard from the Command Line
First thing you'll need to know is which bootloader that your keyboard uses. There are four main bootloaders that are used, usually. Pro-Micro and clones use CATERINA, and Teensy's use Halfkay, OLKB boards use QMK-DFU, and other atmega32u4 chips use DFU.
You can find more information about the bootloaders in the [Flashing Instructions and Bootloader Information](flashing.md) page.
If you know what bootloader that you're using, then when compiling the firmware, you can actually add some extra text to the `make` command to automate the flashing process.
### DFU
For the DFU bootloader, when you're ready to compile and flash your firmware, open up your terminal window and run the built command:
make <my_keyboard>:<my_keymap>:dfu
For example, if your keymap is named "xyverz" and you're building a keymap for a rev5 planck, you'll use this command:
make planck/rev5:xyverz:dfu
Once it finishes compiling, it should output the following:
```
Linking: .build/planck_rev5_xyverz.elf [OK]
Creating load file for flashing: .build/planck_rev5_xyverz.hex [OK]
Copying planck_rev5_xyverz.hex to qmk_firmware folder [OK]
Checking file size of planck_rev5_xyverz.hex
* File size is fine - 18574/28672
```
After it gets to this point, the build script will look for the DFU bootloader every 5 seconds. It will repeat the following until the device is found or you cancel it.
dfu-programmer: no device present.
Error: Bootloader not found. Trying again in 5s.
Once it does this, you'll want to reset the controller. It should then show output similiar to this:
```
*** Attempting to flash, please don't remove device
>>> dfu-programmer atmega32u4 erase --force
Erasing flash... Success
Checking memory from 0x0 to 0x6FFF... Empty.
>>> dfu-programmer atmega32u4 flash /Users/skully/qmk_firmware/clueboard_66_hotswap_gen1_skully.hex
Checking memory from 0x0 to 0x55FF... Empty.
0% 100% Programming 0x5600 bytes...
[>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
0% 100% Reading 0x7000 bytes...
[>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>] Success
Validating... Success
0x5600 bytes written into 0x7000 bytes memory (76.79%).
>>> dfu-programmer atmega32u4 reset
```
If you have any issues with this, you may need to this:
sudo make <my_keyboard>:<my_keymap>:dfu
### Caterina
For Arduino boards and their close (such as the SparkFun ProMicro), when you're ready to compile and flash your firmware, open up your terminal window and run the built command:
make <my_keyboard>:<my_keymap>:avrdude
For example, if your keymap is named "xyverz" and you're building a keymap for a rev2 Lets Split, you'll use this command:
make lets_split/rev2:xyverz:avrdude
Once the firmware finishes compiling, it will output something like this:
```
Linking: .build/lets_split_rev2_xyverz.elf [OK]
Creating load file for flashing: .build/lets_split_rev2_xyverz.hex [OK]
Checking file size of lets_split_rev2_xyverz.hex [OK]
* File size is fine - 27938/28672
Detecting USB port, reset your controller now..............
```
At this point, reset the board and then the script will detect the bootloader and then flash the board. The output should look something like this:
```
Detected controller on USB port at /dev/ttyS15
Connecting to programmer: .
Found programmer: Id = "CATERIN"; type = S
Software Version = 1.0; No Hardware Version given.
Programmer supports auto addr increment.
Programmer supports buffered memory access with buffersize=128 bytes.
Programmer supports the following devices:
Device code: 0x44
avrdude.exe: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude.exe: Device signature = 0x1e9587 (probably m32u4)
avrdude.exe: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude.exe: erasing chip
avrdude.exe: reading input file "./.build/lets_split_rev2_xyverz.hex"
avrdude.exe: input file ./.build/lets_split_rev2_xyverz.hex auto detected as Intel Hex
avrdude.exe: writing flash (27938 bytes):
Writing | ################################################## | 100% 2.40s
avrdude.exe: 27938 bytes of flash written
avrdude.exe: verifying flash memory against ./.build/lets_split_rev2_xyverz.hex:
avrdude.exe: load data flash data from input file ./.build/lets_split_rev2_xyverz.hex:
avrdude.exe: input file ./.build/lets_split_rev2_xyverz.hex auto detected as Intel Hex
avrdude.exe: input file ./.build/lets_split_rev2_xyverz.hex contains 27938 bytes
avrdude.exe: reading on-chip flash data:
Reading | ################################################## | 100% 0.43s
avrdude.exe: verifying ...
avrdude.exe: 27938 bytes of flash verified
avrdude.exe: safemode: Fuses OK (E:CB, H:D8, L:FF)
avrdude.exe done. Thank you.
```
If you have any issues with this, you may need to this:
sudo make <my_keyboard>:<my_keymap>:avrdude
## HalfKay
For the PJRC devices (Teensy's), when you're ready to compile and flash your firmware, open up your terminal window and run the built command:
make <my_keyboard>:<my_keymap>:teensy
For example, if your keymap is named "xyverz" and you're building a keymap for an Ergodox or Ergodox EZ, you'll use this command:
make erdogox_ez:xyverz:teensy
Once the firmware finishes compiling, it will output something like this:
```
Linking: .build/ergodox_ez_xyverz.elf [OK]
Creating load file for flashing: .build/ergodox_ez_xyverz.hex [OK]
Checking file size of ergodox_ez_xyverz.hex [OK]
* File size is fine - 25584/32256
Teensy Loader, Command Line, Version 2.1
Read "./.build/ergodox_ez_xyverz.hex": 25584 bytes, 79.3% usage
Waiting for Teensy device...
(hint: press the reset button)
```
At this point, reset your board. Once you've done that, you'll see output like this:
```
Found HalfKay Bootloader
Read "./.build/ergodox_ez_drashna.hex": 28532 bytes, 88.5% usage
Programming............................................................................................................................................................................
...................................................
Booting
```
## Test It Out!
Congrats! Your custom firmware has been programmed to your keyboard!
Give it a try and make sure everything works the way you want it to. We've written [Testing and Debugging](newbs_testing_debugging.md) to round out this Newbie Guide, so head over there to learn about how to troubleshoot your custom functionality.

@ -0,0 +1,98 @@
# Introduction
Your computer keyboard has a processor inside of it, not unlike the one inside your computer. This processor runs software that is responsible for detecting button presses and sending reports about the state of the keyboard when they are pressed or released. QMK fills the role of that software, detecting button presses and passing that information on to the host computer. When you build your custom layout you are creating the equivalent of an .exe for your keyboard.
QMK tries to put a lot of power into your hands by making easy things easy, and hard things possible. You don't have to know how to program to create powerful layouts, you only have to follow a few simple syntax rules.
# Getting Started
Before you can build keymaps you need to install some software and setup your build environment. This only has to be done one time no matter how many keyboards you want to compile firmware for.
## Download Software
### Text Editor
You'll need a program that can edit and save **plain text** files. If you are on Windows you can make due with Notepad, and on Linux you can use Gedit, both of which are simple but functional text editors. On macOS you can not use TextEdit.app, it will not save plain text files. You will need to install another program such as Sublime Text.
{% hint style='info' %}
Not sure which text editor to use? Laurence Bradford wrote [a great introduction](https://learntocodewith.me/programming/basics/text-editors/) to the subject.
{% endhint %}
### QMK Toolbox
QMK Toolbox is a Windows and macOS program that allows you to both program and debug your custom keyboard. You will want to install it so that you can easily flash your keyboard and receive the debugging messages that your keyboard will print.
* [Newest Release](https://github.com/qmk/qmk_toolbox/releases/latest)
* [Source Code](https://github.com/qmk/qmk_toolbox/)
## Environment Setup
We've tried to make QMK as easy to setup as possible. You only have to prepare your Linux or Unix environment and let QMK install the rest.
{% hint style="info" %}
If you haven't worked with the Linux/Unix command line before there are a few basic concepts and commands you should learn. These resources will teach you enough to work with QMK:
* [Must Know Linux Commands](https://www.guru99.com/must-know-linux-commands.html)
* [Some Basic Unix Commands](https://www.tjhsst.edu/~dhyatt/superap/unixcmd.html)
{% endhint %}
### Windows
You will need to install msys2 and git.
* Follow the installation instructions on the msys2 homepage: http://www.msys2.org
* Close any open msys2 terminals, and open a new terminal
* Install git by running this command: `pacman -S git`
### macOS
You will need to install homebrew. Follow the instructions on the homebrew homepage: https://brew.sh
### Linux
You will need to install git. It's extremely likely you already have it, but if not one of the following commands should install it:
* Debian/Ubuntu/Devuan: `apt-get install git`
* Fedora/Redhat/Centos: `yum install git`
* Arch: `pacman -S git`
## Download QMK
Once you have setup your Linux/Unix environment you are ready to download QMK. We will do this by using git to "clone" the QMK repository. Open a Terminal or MSYS2 Console window and leave it open for the remainder of this guide. Inside that window run these two commands:
git clone https://github.com/qmk/qmk_firmware.git
cd qmk_firmware
{% hint style='info' %}
If you already know [how to use GitHub](getting_started_github.md) we recommend you create and clone your own fork instead. If you don't know what that means you can safely ignore this message.
{% endhint %}
## Setup QMK
QMK comes with a script to help you setup the rest of what you'll need. You should run it now by typing in this command:
./util/qmk_install.sh
## Test Your Build Environment
Now that your QMK build environment is setup you can build a firmware for your keyboard. Start by trying to build the default layout for your keyboard. You should be able to do that with a command in this format:
make <keyboard>:default
For example, to build a firmware for a Clueboard 66% use:
make clueboard/66/rev3:default
When it is done you should have a lot of output that ends similar to this:
```
Linking: .build/clueboard_66_rev2_default.elf [OK]
Creating load file for flashing: .build/clueboard_66_rev2_default.hex [OK]
Copying clueboard_66_rev2_default.hex to qmk_firmware folder [OK]
Checking file size of clueboard_66_rev2_default.hex [OK]
* File size is fine - 25174/28672
```
## Creating Your Layout
Now you are ready to create your own personal layout. Move on to [Building Your First Firmware](newbs_building_firmware.md) for that.

@ -0,0 +1,33 @@
# Testing and Debugging
Once you've flashed your keyboard with a custom firmware you're ready to test it out. With a little bit of luck everything will work perfectly, but if not this document will help you figure out what's wrong.
## Testing
Testing your keyboard is usually pretty straightforward. Press every single key and make sure it sends the keys you expect. There are even programs that will help you make sure that no key is missed.
Note: These programs are not provided by or endorsed by QMK.
* [Switch Hitter](https://elitekeyboards.com/switchhitter.php) (Windows Only)
* [Keyboard Viewer](https://www.imore.com/how-use-keyboard-viewer-your-mac) (Mac Only)
* [Keyboard Tester](http://www.keyboardtester.com) (Web Based)
* [Keyboard Checker](http://keyboardchecker.com) (Web Based)
## Debugging With QMK Toolbox
[QMK Toolbox](https://github.com/qmk/qmk_toolbox) will show messages from your keyboard if you have `CONSOLE_ENABLE = yes` in your `rules.mk`. By default the output is very limited, but you can turn on debug mode to increase the amount of debug output. Use the `DEBUG` keycode in your keymap, or use the [Command](feature_command.md) feature to enable debug mode.
<!-- FIXME: Describe the debugging messages here. -->
## Sending Your Own Debug Messages
Sometimes it's useful to print debug messages from within your [custom code](custom_quantum_functions.md). Doing so is pretty simple. Start by including `print.h` at the top of your file:
#include <print.h>
After that you can use a few different print functions:
* `print("string")`: Print a simple string.
* `sprintf("%s string", var)`: Print a formatted string
* `dprint("string")` Print a simple string, but only when debug mode is enabled
* `dprintf("%s string", var)`: Print a formatted string, but only when debug mode is enabled

@ -1,63 +0,0 @@
# Porting your keyboard to QMK
This page describes the technical details of porting an existing keyboard to QMK. If you're looking to add your keyboard to QMK, please [look through these guidelines](adding_a_keyboard_to_qmk.md)!
If your keyboard is running an Atmega chip (atmega32u4 and others), it's pretty easy to get things setup for compiling your own firmware to flash onto your board. There is a `/util/new_project.sh <keyboard>` script to help get you started - you can simply pass your keyboard's name into the script, and all of the necessary files will be created. The components of each are described below.
## `/keyboards/<keyboard>/config.h`
The `USB Device descriptor parameter` block contains parameters are used to uniquely identify your keyboard, but they don't really matter to the machine.
Your `MATRIX_ROWS` and `MATRIX_COLS` are the numbers of rows and cols in your keyboard matrix - this may be different than the number of actual rows and columns on your keyboard. There are some tricks you can pull to increase the number of keys in a given matrix, but most keyboards are pretty straight-forward.
The `MATRIX_ROW_PINS` and `MATRIX_COL_PINS` are the pins your MCU uses on each row/column. Your schematic (if you have one) will have this information on it, and the values will vary depending on your setup. This is one of the most important things to double-check in getting your keyboard setup correctly.
For the `DIODE_DIRECTION`, most hand-wiring guides will instruct you to wire the diodes in the `COL2ROW` position, but it's possible that they are in the other - people coming from EasyAVR often use `ROW2COL`. Nothing will function if this is incorrect.
`BACKLIGHT_PIN` is the pin that your PWM-controlled backlight (if one exists) is hooked-up to. Currently only B5, B6, and B7 are supported.
`BACKLIGHT_BREATHING` is a fancier backlight feature that adds breathing/pulsing/fading effects to the backlight. It uses the same timer as the normal backlight. These breathing effects must be called by code in your keymap.
`BACKLIGHT_LEVELS` is how many levels exist for your backlight - max is 15, and they are computed automatically from this number.
## `/keyboards/<keyboard>/rules.mk`
The values at the top likely won't need to be changed, since most boards use the `atmega32u4` chip. The `BOOTLOADER_SIZE` will need to be adjusted based on your MCU type. It's defaulted to the Teensy, since that's the most common controller. Below is quoted from the `Makefile`.
```
# Boot Section Size in *bytes*
# Teensy halfKay 512
# Teensy++ halfKay 1024
# Atmel DFU loader 4096
# LUFA bootloader 4096
# USBaspLoader 2048
OPT_DEFS += -DBOOTLOADER_SIZE=512
```
At the bottom of the file, you'll find lots of features to turn on and off - all of these options should be set with `?=` to allow for the keymap overrides. `?=` only assigns if the variable was previously undefined. For the full documenation of these features, see the [Makefile options](getting_started_make_guide.md#makefile-options).
## `/keyboards/<keyboard>/readme.md`
This is where you'll describe your keyboard - please write as much as you can about it! Talking about default functionality/features is useful here. Feel free to link to external pages/sites if necessary. Images can be included here as well, as long as they're hosted elsewhere (imgur).
## `/keyboards/<keyboard>/<keyboard>.c`
This is where all of the custom logic for your keyboard goes - you may not need to put anything in this file, since a lot of things are configured automatically. All of the `*_kb()` functions are defined here. If you modify them, remember to keep the calls to `*_user()`, or things in the keymaps might not work. You can read more about the functions [here](custom_quantum_functions.md).
## `/keyboards/<keyboard>/<keyboard>.h`
Here is where you can (optionally) define your `KEYMAP` function to remap your matrix into a more readable format. With ortholinear boards, this isn't always necessary, but it can help to accomodate the dead spots on your matrix, where there are keys that take up more than one space (2u, staggering, 6.25u, etc). The example shows the difference between the physical keys, and the matrix design:
```
#define KEYMAP( \
k00, k01, k02, \
k10, k11 \
) \
{ \
{ k00, k01, k02 }, \
{ k10, KC_NO, k11 }, \
}
```
Each of the `kxx` variables needs to be unique, and usually follows the format `k<row><col>`. You can place `KC_NO` where your dead keys are in your matrix.

@ -42,7 +42,7 @@ The values at the top likely won't need to be changed, since most boards use the
OPT_DEFS += -DBOOTLOADER_SIZE=512
```
At the bottom of the file, you'll find lots of features to turn on and off - all of these options should be set with `?=` to allow for the keymap overrides. `?=` only assigns if the variable was previously undefined. For the full documenation of these features, see the [Makefile options](#makefile-options).
At the bottom of the file, you'll find lots of features to turn on and off - all of these options should be set with `?=` to allow for the keymap overrides. `?=` only assigns if the variable was previously undefined. For the full documentation of these features, see the [Makefile options](#makefile-options).
## `/keyboards/<keyboard>/readme.md`
@ -54,7 +54,7 @@ This is where all of the custom logic for your keyboard goes - you may not need
## `/keyboards/<keyboard>/<keyboard>.h`
Here is where you can (optionally) define your `KEYMAP` function to remap your matrix into a more readable format. With ortholinear boards, this isn't always necessary, but it can help to accomodate the dead spots on your matrix, where there are keys that take up more than one space (2u, staggering, 6.25u, etc). The example shows the difference between the physical keys, and the matrix design:
Here is where you can (optionally) define your `KEYMAP` function to remap your matrix into a more readable format. With ortholinear boards, this isn't always necessary, but it can help to accommodate the dead spots on your matrix, where there are keys that take up more than one space (2u, staggering, 6.25u, etc). The example shows the difference between the physical keys, and the matrix design:
```
#define KEYMAP( \

@ -21,7 +21,7 @@ MCUSR MCU Status Register
SMCR Sleep Mode Control Register
SE Sleep Enable
SM2:0
SM2:0
#define set_sleep_mode(mode) \
#define SLEEP_MODE_IDLE (0)
#define SLEEP_MODE_ADC _BV(SM0)

@ -2,21 +2,21 @@
Quantum keycodes allow for easier customisation of your keymap than the basic ones provide, without having to define custom actions.
All keycodes within quantum are numbers between `0x0000` and `0xFFFF`. Within your `keymap.c` it may look like you have functions and other special cases, but ultimately the C preprocessor will translate those into a single 4 byte integer. QMK has reserved `0x0000` through `0x00FF` for standard keycodes. These are keycodes such as `KC_A`, `KC_1`, and `KC_LCTL`, which are basic keys defined in the USB HID specification.
All keycodes within quantum are numbers between `0x0000` and `0xFFFF`. Within your `keymap.c` it may look like you have functions and other special cases, but ultimately the C preprocessor will translate those into a single 4 byte integer. QMK has reserved `0x0000` through `0x00FF` for standard keycodes. These are keycodes such as `KC_A`, `KC_1`, and `KC_LCTL`, which are basic keys defined in the USB HID specification.
On this page we have documented keycodes between `0x00FF` and `0xFFFF` which are used to implement advanced quantum features. If you define your own custom keycodes they will be put into this range as well.
## QMK keycodes
## QMK Keycodes
|Name|Description|
|----|-----------|
|`RESET`|Put the keyboard into DFU mode for flashing|
|`DEBUG`|Toggles debug mode|
|`KC_GESC`/`GRAVE_ESC`|Acts as escape when pressed normally but when pressed with Shift or GUI will send a ```|
|`KC_LSPO`|Left shift when held, open paranthesis when tapped|
|`KC_RSPC`|Right shift when held, close paranthesis when tapped|
|`KC_LEAD`|The [leader key](feature_leader_key.md)|
|`KC_LOCK`|The [lock key](key_lock.md)|
|`FUNC(n)`/`F(n)`|Call `fn_action(n)` (deprecated)|
|`M(n)`|to call macro n|
|`MACROTAP(n)`|to macro-tap n idk FIXME|
|Key |Aliases |Description |
|-------------|-----------|---------------------------------------------------------------------|
|`RESET` | |Put the keyboard into DFU mode for flashing |
|`DEBUG` | |Toggle debug mode |
|`KC_GESC` |`GRAVE_ESC`|Escape when tapped, <code>&#96;</code> when pressed with Shift or GUI|
|`KC_LSPO` | |Left Shift when held, `(` when tapped |
|`KC_RSPC` | |Right Shift when held, `)` when tapped |
|`KC_LEAD` | |The [Leader key](feature_leader_key.md) |
|`KC_LOCK` | |The [Lock key](feature_key_lock.md) |
|`FUNC(n)` |`F(n)` |Call `fn_action(n)` (deprecated) |
|`M(n)` | |Call macro `n` |
|`MACROTAP(n)`| |Macro-tap `n` idk FIXME |

@ -1,12 +1,48 @@
{
"redirects": [
{
"from": "adding_a_keyboard_to_qmk.html",
"to": "hardware_keyboard_guidelines.html"
},
{
"from": "build_environment_setup.html",
"to": "getting_started_build_tools.html"
},
{
"from": "dynamic_macros.html",
"to": "feature_dynamic_macros.html"
},
{
"from": "feature_common_shortcuts.html",
"to": "feature_advanced_keycodes.html"
},
{
"from": "glossary.html",
"to": "reference_glossary.html"
},
{
"from": "key_lock.html",
"to": "feature_key_lock.html"
},
{
"from": "make_instructions.html",
"to": "getting_started_make_guide.html"
},
{
"from": "porting_your_keyboard_to_qmk.html",
"to": "hardware_avr.html"
},
{
"from": "space_cadet_shift.html",
"to": "feature_space_cadet.html"
},
{
"from": "tap_dance.html",
"to": "feature_tap_dance.html"
},
{
"from": "unicode.html",
"to": "feature_unicode.html"
}
]
}
}

@ -0,0 +1,170 @@
# Glossary of QMK Terms
## ARM
A line of 32-bit MCU's produced by a number of companies, such as Atmel, Cypress, Kinetis, NXP, ST, and TI.
## AVR
A line of 8-bit MCU's produced by [Atmel](http://www.microchip.com/). AVR was the original platform that TMK supported.
## AZERTY
The standard Français (French) keyboard layout. Named for the first 6 keys on the keyboard.
## Backlight
A generic term for lighting on a keyboard. The backlight is typically, but not always, an array of LED's that shine through keycaps and/or switches.
## Bluetooth
A short range peer to peer wireless protocol. Most common wireless protocol for a keyboard.
## Bootloader
A special program that is written to a protected area of your MCU that allows the MCU to upgrade its own firmware, typically over USB.
## Bootmagic
A feature that allows for various keyboard behavior changes to happen on the fly, such as swapping or disabling common keys.
## C
A low-level programming language suitable for system code. Most QMK code is written in C.
## Colemak
An alternative keyboard layout that is gaining in popularity.
## Compile
The process of turning human readable code into machine code your MCU can run.
## Dvorak
An alternative keyboard layout developed by Dr. August Dvorak in the 1930's. A shortened form of the Dvorak Simplified Keyboard.
## Dynamic Macro
A macro which has been recorded on the keyboard and which will be lost when the keyboard is unplugged or the computer rebooted.
* [Dynamic Macro Documentation](feature_dynamic_macros.md)
## Eclipse
An IDE that is popular with many C developers.
* [Eclipse Setup Instructions](eclipse.md)
## Firmware
The software that controls your MCU.
## FLIP
Software provided by Atmel for flashing AVR devices. We generally recommend [QMK Flasher](https://github.com/qmk/qmk_flasher) instead, but for some advanced use cases FLIP is required.
## git
Versioning software used at the command line
## GitHub
The website that hosts most of the QMK project. It provides integration with git, issue tracking, and other features that help us run QMK.
## ISP
In-system programming, a method of programming an AVR chip using external hardware and the JTAG pins.
## hid_listen
An interface for receiving debugging messages from your keyboard. You can view these messages using [QMK Flasher](https://github.com/qmk/qmk_flasher) or [PJRC's hid_listen](https://www.pjrc.com/teensy/hid_listen.html)
## Keycode
A 2-byte number that represents a particular key. `0x00`-`0xFF` are used for [Basic Keycodes](keycodes_basic.md) while `0x100`-`0xFFFF` are used for [Quantum Keycodes](quantum_keycodes.md).
## Key Down
An event that happens when a key is pressed down, but is completed before a key is released.
## Key Up
An event that happens when a key is released.
## Keymap
An array of keycodes mapped to a physical keyboard layout, which are processed on key presses and releases
## Layer
An abstraction used to allow a key to serve multiple purposes. The highest active layer takes precedence.
## Leader Key
A feature that allows you to tap the leader key followed by a sequence of 1, 2, or 3 keys to activate key presses or other quantum features.
* [Leader Key Documentation](feature_leader_key.md)
## LED
Light Emitting Diode, the most common device used for indicators on a keyboard.
## Make
Software package that is used to compile all the source files. You run `make` with various options to compile your keyboard firmware.
## Matrix
A wiring pattern of columns and rows that enables the MCU to detect keypresses with a fewer number of pins. The matrix often incorporates diodes to allow for NKRO.
## Macro
A feature that lets you send multiple keypress events (hid reports) after having pressed only a single key.
* [Macro Documentation](feature_macros.md)
## MCU
Microcontrol Unit, the processor that powers your keyboard.
## Modifier
A key that is held down while typing another key to modify the action of that key. Examples include Ctrl, Alt, and Shift.
## Mousekeys
A feature that lets you control your mouse cursor and click from your keyboard.
* [Mousekeys Documentation](feature_mouse_keys.md)
## N-Key Rollover (NKRO)
A term that applies to keyboards that are capable of reporting any number of key-presses at once.
## Oneshot Modifier
A modifier that acts as if it is held down until another key is released, so you can press the mod and then press the key, rather than holding the mod while pressing the key. Also known as a Sticky key or a Dead key.
## ProMicro
A low cost AVR development board. Clones of this device are often found on ebay very inexpensively (under $5) but people often struggle with flashing their pro micros.
## Pull Request
A request to submit code to QMK. We encourage all users to submit Pull Requests for their personal keymaps.
## QWERTY
The standard English keyboard layout, and often a shortcut for other language's standard layouts. Named for the first 6 letters on the keyboard.
## QWERTZ
The standard Deutsche (German) keyboard layout. Named for the first 6 letters on the keyboard.
## Rollover
The term for pressing a key while a key is already held down. Variants include 2KRO, 6KRO, and NKRO.
## Scancode
A 1 byte number that is sent as part of a HID report over USB that represents a single key. These numbers are documented in the [HID Usage Tables](http://www.usb.org/developers/hidpage/Hut1_12v2.pdf) published by the [USB-IF](http://www.usb.org/).
## Space Cadet Shift
A special set of shift keys which allow you to type various types of braces by tapping the left or right shift one or more times.
* [Space Cadet Shift Documentation](feature_space_cadet.md)
## Tap
Pressing and releasing a key. In some situations you will need to distinguish between a key down and a key up event, and Tap always refers to both at once.
## Tap Dance
A feature that lets you assign multiple keycodes to the same key based on how many times you press it.
* [Tap Dance Documentation](feature_tap_dance.md)
## Teensy
A low-cost AVR development board that is commonly used for hand-wired builds. A teensy is often chosen despite costing a few dollars more due to its halfkay bootloader, which makes flashing very simple.
## Underlight
A generic term for LEDs that light the underside of the board. These LED's typically shine away from the bottom of the PCB and towards the surface the keyboard rests on.
## Unicode
In the larger computer world Unicode is a set of encoding schemes for representing characters in any language. As it relates to QMK it means using various OS schemes to send unicode codepoints instead of scancodes.
* [Unicode Documentation](feature_unicode.md)
## Unit Testing
A framework for running automated tests against QMK. Unit testing helps us be confident that our changes do not break anything.
* [Unit Testing Documentation](unit_testing.md)
## USB
Universal Serial Bus, the most common wired interface for a keyboard.
## USB Host (or simply Host)
The USB Host is your computer, or whatever device your keyboard is plugged into.
# Couldn't Find the Term You're Looking For?
[Open an issue](https://github.com/qmk/qmk_firmware/issues) with your question and the term in question could be added here. Better still, open a pull request with the definition. :)

@ -1,24 +0,0 @@
## Space Cadet Shift: The future, built in
Steve Losh [described](http://stevelosh.com/blog/2012/10/a-modern-space-cadet/) the Space Cadet Shift quite well. Essentially, you hit the left Shift on its own, and you get an opening parenthesis; hit the right Shift on its own, and you get the closing one. When hit with other keys, the Shift key keeps working as it always does. Yes, it's as cool as it sounds.
To use it, use `KC_LSPO` (Left Shift, Parens Open) for your left Shift on your keymap, and `KC_RSPC` (Right Shift, Parens Close) for your right Shift.
It's defaulted to work on US keyboards, but if your layout uses different keys for parenthesis, you can define those in your `config.h` like this:
#define LSPO_KEY KC_9
#define RSPC_KEY KC_0
You can also choose between different rollover behaviors of the shift keys by defining:
#define DISABLE_SPACE_CADET_ROLLOVER
in your `config.h`. Disabling rollover allows you to use the opposite shift key to cancel the space cadet state in the event of an erroneous press instead of emitting a pair of parentheses when the keys are released.
The only other thing you're going to want to do is create a `Makefile` in your keymap directory and set the following:
```
COMMAND_ENABLE = no # Commands for debug and configuration
```
This is just to keep the keyboard from going into command mode when you hold both Shift keys at the same time.

@ -1,108 +0,0 @@
# Stenography in QMK
[Stenography](https://en.wikipedia.org/wiki/Stenotype) is a method of writing most often used by court reports, closed-captioning, and real-time transcription for the deaf. In stenography words are chorded syllable by syllable with a mixture of spelling, phonetic, and shortcut (briefs) strokes. Professional stenographers can reach 200-300 WPM without any of the strain usually found in standard typing and with far fewer errors (>99.9% accuracy).
The [Open Steno Project](http://www.openstenoproject.org/) has built an open-source program called Plover that provides real-time translation of steno strokes into words and commands. It has an established dictionary and supports
## Plover with QWERTY Keyboard
Plover can work with any standard QWERTY keyboard, although it is more efficient if the keyboard supports NKRO (n-key rollover) to allow Plover to see all the pressed keys at once. An example keymap for Plover can be found in `planck/keymaps/default`. Switching to the `PLOVER` layer adjusts the position of the keyboard to support the number bar.
To use Plover with QMK just enable NKRO and optionally adjust your layout if you have anything other than a standard layout. You may also want to purchase some steno-friendly keycaps to make it easier to hit multiple keys.
## Plover with Steno Protocol
Plover also understands the language of several steno machines. QMK can speak a couple of these languages, TX Bolt and GeminiPR. An example layout can be found in `planck/keymaps/steno`.
When QMK speaks to Plover over a steno protocol Plover will not use the keyboard as input. This means that you can switch back and forth between a standard keyboard and your steno keyboard, or even switch layers from Plover to standard and back without needing to activate/deactive Plover.
In this mode Plover expects to speak with a steno machine over a serial port so QMK will present itself to the operating system as a virtual serial port in addition to a keyboard. By default QMK will speak the TX Bolt protocol but can be switched to GeminiPR; the last protocol used is stored in non-volatile memory so QMK will use the same protocol on restart.
> Note: Due to hardware limitations you may not be able to run both a virtual serial port and mouse emulation at the same time.
### TX Bolt
TX Bolt communicates the status of 24 keys over a very simple protocol in variable-sized (1-5 byte) packets.
### GeminiPR
GeminiPR encodes 42 keys into a 6-byte packet. While TX Bolt contains everything that is necessary for standard stenography, GeminiPR opens up many more options, including supporting non-English theories.
## Configuring QMK for Steno
Firstly, enable steno in your keymap's Makefile. You may also need disable mousekeys, extra keys, or another USB endpoint to prevent conflicts. The builtin USB stack for some processors only supports a certain number of USB endpoints and the virtual serial port needed for steno fills 3 of them.
```Makefile
STENO_ENABLE = yes
MOUSEKEY_ENABLE = no
```
In your keymap create a new layer for Plover. You will need to include `keymap_steno.h`. See `planck/keymaps/steno/keymap.c` for an example. Remember to create a key to switch to the layer as well as a key for exiting the layer. If you would like to switch modes on the fly you can use the keycodes `QK_STENO_BOLT` and `QK_STENO_GEMINI`. If you only want to use one of the protocols you may set it up in your initialization function:
```C
void matrix_init_user() {
steno_set_mode(STENO_MODE_GEMINI); // or STENO_MODE_BOLT
}
```
Once you have your keyboard flashed launch Plover. Click the 'Configure...' button. In the 'Machine' tab select the Stenotype Machine that corresponds to your desired protocol. Click the 'Configure...' button on this tab and enter the serial port or click 'Scan'. Baud rate is fine at 9600 (although you should be able to set as high as 115200 with no issues). Use the default settings for everything else (Data Bits: 8, Stop Bits: 1, Parity: N, no flow control).
On the display tab click 'Open stroke display'. With Plover disabled you should be able to hit keys on your keyboard and see them show up in the stroke display window. Use this to make sure you have set up your keymap correctly. You are now ready to steno!
## Learning Stenography
* [Learn Plover!](https://sites.google.com/site/ploverdoc/)
* [QWERTY Steno](http://qwertysteno.com/Home/)
* [Steno Jig](https://joshuagrams.github.io/steno-jig/)
* More resources at the Plover [Learning Stenography](https://github.com/openstenoproject/plover/wiki/Learning-Stenography) wiki
## Keycode Reference
As defined in `keymap_steno.h`.
> Note: TX Bolt does not support the full set of keys. The TX Bolt implementation in QMK will map the GeminiPR keys to the nearest TX Bolt key so that one key map will work for both.
|GeminiPR|TX Bolt|Steno Key|
|--------|-------|-----------|
|`STN_N1`|`STN_NUM`|Number bar #1|
|`STN_N2`|`STN_NUM`|Number bar #2|
|`STN_N3`|`STN_NUM`|Number bar #3|
|`STN_N4`|`STN_NUM`|Number bar #4|
|`STN_N5`|`STN_NUM`|Number bar #5|
|`STN_N6`|`STN_NUM`|Number bar #6|
|`STN_N7`|`STN_NUM`|Number bar #7|
|`STN_N8`|`STN_NUM`|Number bar #8|
|`STN_N9`|`STN_NUM`|Number bar #9|
|`STN_NA`|`STN_NUM`|Number bar #A|
|`STN_NB`|`STN_NUM`|Number bar #B|
|`STN_NC`|`STN_NUM`|Number bar #C|
|`STN_S1`|`STN_SL`| `S-` upper|
|`STN_S2`|`STN_SL`| `S-` lower|
|`STN_TL`|`STN_TL`| `T-`|
|`STN_KL`|`STN_KL`| `K-`|
|`STN_PL`|`STN_PL`| `P-`|
|`STN_WL`|`STN_WL`| `W-`|
|`STN_HL`|`STN_HL`| `H-`|
|`STN_RL`|`STN_RL`| `R-`|
|`STN_A`|`STN_A`| `A` vowel|
|`STN_O`|`STN_O`| `O` vowel|
|`STN_ST1`|`STN_STR`| `*` upper-left |
|`STN_ST2`|`STN_STR`| `*` lower-left|
|`STN_ST3`|`STN_STR`| `*` upper-right|
|`STN_ST4`|`STN_STR`| `*` lower-right|
|`STN_E`|`STN_E`| `E` vowel|
|`STN_U`|`STN_U`| `U` vowel|
|`STN_FR`|`STN_FR`| `-F`|
|`STN_PR`|`STN_PR`| `-P`|
|`STN_RR`|`STN_RR`| `-R`|
|`STN_BR`|`STN_BR`| `-B`|
|`STN_LR`|`STN_LR`| `-L`|
|`STN_GR`|`STN_GR`| `-G`|
|`STN_TR`|`STN_TR`| `-T`|
|`STN_SR`|`STN_SR`| `-S`|
|`STN_DR`|`STN_DR`| `-D`|
|`STN_ZR`|`STN_ZR`| `-Z`|
|`STN_FN`|| (GeminiPR only)|
|`STN_RES1`||(GeminiPR only)|
|`STN_RES2`||(GeminiPR only)|
|`STN_PWR`||(GeminiPR only)|

@ -1,150 +0,0 @@
# Tap Dance: A single key can do 3, 5, or 100 different things
<!-- FIXME: Break this up into multiple sections -->
Hit the semicolon key once, send a semicolon. Hit it twice, rapidly -- send a colon. Hit it three times, and your keyboard's LEDs do a wild dance. That's just one example of what Tap Dance can do. It's one of the nicest community-contributed features in the firmware, conceived and created by [algernon](https://github.com/algernon) in [#451](https://github.com/qmk/qmk_firmware/pull/451). Here's how algernon describes the feature:
With this feature one can specify keys that behave differently, based on the amount of times they have been tapped, and when interrupted, they get handled before the interrupter.
To make it clear how this is different from `ACTION_FUNCTION_TAP`, lets explore a certain setup! We want one key to send `Space` on single tap, but `Enter` on double-tap.
With `ACTION_FUNCTION_TAP`, it is quite a rain-dance to set this up, and has the problem that when the sequence is interrupted, the interrupting key will be send first. Thus, `SPC a` will result in `a SPC` being sent, if they are typed within `TAPPING_TERM`. With the tap dance feature, that'll come out as `SPC a`, correctly.
The implementation hooks into two parts of the system, to achieve this: into `process_record_quantum()`, and the matrix scan. We need the latter to be able to time out a tap sequence even when a key is not being pressed, so `SPC` alone will time out and register after `TAPPING_TERM` time.
But lets start with how to use it, first!
First, you will need `TAP_DANCE_ENABLE=yes` in your `rules.mk`, because the feature is disabled by default. This adds a little less than 1k to the firmware size. Next, you will want to define some tap-dance keys, which is easiest to do with the `TD()` macro, that - similar to `F()`, takes a number, which will later be used as an index into the `tap_dance_actions` array.
This array specifies what actions shall be taken when a tap-dance key is in action. Currently, there are three possible options:
* `ACTION_TAP_DANCE_DOUBLE(kc1, kc2)`: Sends the `kc1` keycode when tapped once, `kc2` otherwise. When the key is held, the appropriate keycode is registered: `kc1` when pressed and held, `kc2` when tapped once, then pressed and held.
* `ACTION_TAP_DANCE_FN(fn)`: Calls the specified function - defined in the user keymap - with the final tap count of the tap dance action.
* `ACTION_TAP_DANCE_FN_ADVANCED(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn)`: Calls the first specified function - defined in the user keymap - on every tap, the second function on when the dance action finishes (like the previous option), and the last function when the tap dance action resets.
The first option is enough for a lot of cases, that just want dual roles. For example, `ACTION_TAP_DANCE(KC_SPC, KC_ENT)` will result in `Space` being sent on single-tap, `Enter` otherwise.
And that's the bulk of it!
And now, on to the explanation of how it works!
The main entry point is `process_tap_dance()`, called from `process_record_quantum()`, which is run for every keypress, and our handler gets to run early. This function checks whether the key pressed is a tap-dance key. If it is not, and a tap-dance was in action, we handle that first, and enqueue the newly pressed key. If it is a tap-dance key, then we check if it is the same as the already active one (if there's one active, that is). If it is not, we fire off the old one first, then register the new one. If it was the same, we increment the counter and the timer.
This means that you have `TAPPING_TERM` time to tap the key again, you do not have to input all the taps within that timeframe. This allows for longer tap counts, with minimal impact on responsiveness.
Our next stop is `matrix_scan_tap_dance()`. This handles the timeout of tap-dance keys.
For the sake of flexibility, tap-dance actions can be either a pair of keycodes, or a user function. The latter allows one to handle higher tap counts, or do extra things, like blink the LEDs, fiddle with the backlighting, and so on. This is accomplished by using an union, and some clever macros.
# Examples
## Simple Example
Here's a simple example for a single definition:
1. In your `rules.mk`, add `TAP_DANCE_ENABLE = yes`
2. In your `config.h` (which you can copy from `qmk_firmware/keyboards/planck/config.h` to your keymap directory), add `#define TAPPING_TERM 200`
3. In your `keymap.c` file, define the variables and definitions, then add to your keymap:
```c
//Tap Dance Declarations
enum {
TD_ESC_CAPS = 0
};
//Tap Dance Definitions
qk_tap_dance_action_t tap_dance_actions[] = {
//Tap once for Esc, twice for Caps Lock
[TD_ESC_CAPS] = ACTION_TAP_DANCE_DOUBLE(KC_ESC, KC_CAPS)
// Other declarations would go here, separated by commas, if you have them
};
//In Layer declaration, add tap dance item in place of a key code
TD(TD_ESC_CAPS)
```
## Complex Example
Here's a more complex example involving custom actions:
```c
enum {
CT_SE = 0,
CT_CLN,
CT_EGG,
CT_FLSH,
};
/* Have the above three on the keymap, TD(CT_SE), etc... */
void dance_cln_finished (qk_tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
register_code (KC_RSFT);
register_code (KC_SCLN);
} else {
register_code (KC_SCLN);
}
}
void dance_cln_reset (qk_tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
unregister_code (KC_RSFT);
unregister_code (KC_SCLN);
} else {
unregister_code (KC_SCLN);
}
}
void dance_egg (qk_tap_dance_state_t *state, void *user_data) {
if (state->count >= 100) {
SEND_STRING ("Safety dance!");
reset_tap_dance (state);
}
}
// on each tap, light up one led, from right to left
// on the forth tap, turn them off from right to left
void dance_flsh_each(qk_tap_dance_state_t *state, void *user_data) {
switch (state->count) {
case 1:
ergodox_right_led_3_on();
break;
case 2:
ergodox_right_led_2_on();
break;
case 3:
ergodox_right_led_1_on();
break;
case 4:
ergodox_right_led_3_off();
_delay_ms(50);
ergodox_right_led_2_off();
_delay_ms(50);
ergodox_right_led_1_off();
}
}
// on the fourth tap, set the keyboard on flash state
void dance_flsh_finished(qk_tap_dance_state_t *state, void *user_data) {
if (state->count >= 4) {
reset_keyboard();
reset_tap_dance(state);
}
}
// if the flash state didnt happen, then turn off leds, left to right
void dance_flsh_reset(qk_tap_dance_state_t *state, void *user_data) {
ergodox_right_led_1_off();
_delay_ms(50);
ergodox_right_led_2_off();
_delay_ms(50);
ergodox_right_led_3_off();
}
qk_tap_dance_action_t tap_dance_actions[] = {
[CT_SE] = ACTION_TAP_DANCE_DOUBLE (KC_SPC, KC_ENT)
,[CT_CLN] = ACTION_TAP_DANCE_FN_ADVANCED (NULL, dance_cln_finished, dance_cln_reset)
,[CT_EGG] = ACTION_TAP_DANCE_FN (dance_egg)
,[CT_FLSH] = ACTION_TAP_DANCE_FN_ADVANCED (dance_flsh_each, dance_flsh_finished, dance_flsh_reset)
};
```

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

Loading…
Cancel
Save