summaryrefslogtreecommitdiffstats
path: root/docs/faq_keymap.md
diff options
context:
space:
mode:
authorskullY <skullydazed@gmail.com>2017-07-03 10:30:36 +0200
committerskullY <skullydazed@gmail.com>2017-07-03 10:30:36 +0200
commitd8e29b53fe5d57f2102b77f0ce9932cdb8b021b2 (patch)
tree14dd7d4c51a3d0bb046acb29ad96ca2b5f76f55b /docs/faq_keymap.md
parentea8df568f23b79eba13ef9e914d8b1ce94688858 (diff)
downloadqmk_firmware-d8e29b53fe5d57f2102b77f0ce9932cdb8b021b2.tar.gz
qmk_firmware-d8e29b53fe5d57f2102b77f0ce9932cdb8b021b2.tar.xz
Update a bunch of docs
Diffstat (limited to 'docs/faq_keymap.md')
-rw-r--r--docs/faq_keymap.md94
1 files changed, 20 insertions, 74 deletions
diff --git a/docs/faq_keymap.md b/docs/faq_keymap.md
index 623726ab2..d6442ac53 100644
--- a/docs/faq_keymap.md
+++ b/docs/faq_keymap.md
@@ -1,10 +1,13 @@
-## READ FIRST
-https://github.com/tmk/tmk_core/blob/master/doc/keymap.md
+# Frequently Asked Keymap Questions
-## How to get keycode
-See [Keycodes](Keycodes). Keycodes are actually defined in [common/keycode.h](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/keycode.h).
+This page covers questions people often have about keymaps. If you haven't you should read [Keymap Overview](keymap.html) first.
-## Sysrq key
+## What Keycodes Can I Use?
+See [Basic Keycodes](keycodes.html) and [Quantum Keycodes](quantum_keycodes.html) for most of the keys you can define.
+
+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
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
@@ -16,7 +19,7 @@ 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.
-http://geekhack.org/index.php?topic=14290.msg1327264#msg1327264
+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.
@@ -32,15 +35,17 @@ For Modifier keys and layer actions you have to place `KC_TRANS` on same positio
## Mechanical Lock Switch Support
-https://github.com/tmk/tmk_keyboard#mechanical-locking-support
-
-This feature is for *mechanical lock switch* like this Alps one.
-http://deskthority.net/wiki/Alps_SKCL_Lock
-Using enabling this feature and using keycodes `LCAP`, `LNUM` or `LSCR` in keymap you can use physical locking CapsLock, NumLock or ScrollLock keys as you expected.
+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
+```
-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 `CAPS`, `NLCK` and `SLCK`.***
+After enabling this feature use keycodes `KC_LCAP`, `KC_LNUM` and `KC_LSCR` in your keymap instead.
+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 'Ç'
NO UNIVERSAL METHOD TO INPUT THOSE WORKS OVER ALL SYSTEMS. You have to define **MACRO** in way specific to your OS or layout.
@@ -111,68 +116,12 @@ https://github.com/tekezo/Karabiner/issues/403
## Esc and `~ on a key
-You can define FC660 and Poker style ESC with `ACTION_LAYER_MODS`.
-https://github.com/tmk/tmk_core/blob/master/doc/keymap.md#35-momentary-switching-with-modifiers
-
-```
-#include "keymap_common.h"
-
-
-/* Leopold FC660
- * https://elitekeyboards.com/products.php?sub=leopold,compact&pid=fc660c
- * Shift + Esc = ~
- * Fn + Esc = `
- *
- * Votex Poker II
- * https://adprice.fedorapeople.org/poker2_manual.pdf
- * Fn + Esc = `
- * Fn + Shift + Esc = ~
- */
-const uint8_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
- /* 0: qwerty */
- [0] = KEYMAP( \
- ESC, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, MINS,EQL, NUHS,BSPC, \
- TAB, Q, W, E, R, T, Y, U, I, O, P, LBRC,RBRC,BSLS, \
- LCTL,A, S, D, F, G, H, J, K, L, SCLN,QUOT,ENT, \
- FN0, NUBS,Z, X, C, V, B, N, M, COMM,DOT, SLSH,RSFT,ESC, \
- LCTL,LGUI,LALT, SPC, RALT,FN1, RGUI,RCTL),
- [1] = KEYMAP( \
- GRV, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
- TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,\
- TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
- TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
- TRNS,TRNS,TRNS, TRNS, TRNS,TRNS,TRNS,TRNS),
- [2] = KEYMAP( \
- GRV, F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, TRNS,TRNS, \
- TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,\
- TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
- TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
- TRNS,TRNS,TRNS, TRNS, TRNS,TRNS,TRNS,TRNS),
-};
-
-const uint16_t PROGMEM fn_actions[] = {
- // https://github.com/tmk/tmk_core/blob/master/doc/keymap.md#35-momentary-switching-with-modifiers
- [0] = ACTION_LAYER_MODS(1, MOD_LSFT),
- [1] = ACTION_LAYER_MOMENTARY(2),
-};
-```
-
-Otherwise, you can write code, see this.
-https://github.com/p3lim/keyboard_firmware/commit/fd799c12b69a5ab5addd1d4c03380a1b8ef8e9dc
-
-
-## 32 Fn keys are not enough?
-### actionmap
-It uses 16 bit codes and has no limitation of 32 Fn at the expense of memory space. TMK keymap is actually is 8 bit codes as subset of the actionmap.
-https://github.com/tmk/tmk_keyboard/issues?utf8=%E2%9C%93&q=is%3Aissue+actionmap
-
-### extension for modified keys
-https://geekhack.org/index.php?topic=41989.msg1885526#msg1885526
-
+Use `GRAVE_ESC` or `KC_GESC` in your keymap.
## 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**.
```
+
#include "keymap_common.h"
@@ -211,18 +160,16 @@ const uint16_t PROGMEM fn_actions[] = {
```
-
Dual-role key: https://en.wikipedia.org/wiki/Modifier_key#Dual-role_keys
## Eject on Mac OSX
-`EJCT` keycode works on OSX. https://github.com/tmk/tmk_keyboard/issues/250
+`KC_EJCT` keycode works on OSX. https://github.com/tmk/tmk_keyboard/issues/250
It seems Windows 10 ignores the code and Linux/Xorg recognizes but has no mapping by default.
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
___TO BE IMPROVED___
@@ -262,4 +209,3 @@ if (timer_elapsed(key_timer) < 100) {
```
It's best to declare the `static uint16_t key_timer;` at the top of the file, outside of any code blocks you're using it in.
-