Skip to content

Key remapping ​

Remapping keys is the most basic thing you want from a keyboard. For most custom keyboard enthusiasts, being able to configure every key independently is one of the defining features of the hobby — we usually call it full-key customization.

Full-key customization means you can assign a keycode to every single key, exactly the way you prefer.

Basics ​

Remapping is straightforward. The interface is split into three areas:

  • Top — keyboard name, layer switcher and the "automatic key selection" toggle
  • Middle — the keyboard view; click a keycap to select the key you want to remap
  • Bottom — the keycode list, where you click the keycode you want to assign

Select a key and click a keycode to remap it; the change takes effect immediately. With "automatic key selection" enabled, the next key is selected automatically after each assignment, which makes remapping a run of keys much faster. The "keycode search" box above the list lets you filter by keycode name or code.

Layer switching ​

The layer buttons at the top of the interface switch the layer you are currently viewing and editing.

Every key can be assigned a different function on each layer. Think of layers as transparent sheets stacked on top of each other, each printed with its own set of keycodes. When you press a key, the keyboard reads its function from the currently active layers.

By default the keyboard sits on the base layer (usually layer 0), which holds the regular keycodes.

Switching layers changes what keys do, temporarily or permanently. That is how an Fn key works, and how you can build separate layers for gaming, programming or media control.

  • MO(0) - Activates layer 0 while held, returns to the previous layer on release

  • MO(1) - Activates layer 1 while held, returns to the previous layer on release

  • MO(2) - Activates layer 2 while held, returns to the previous layer on release

  • MO(3) - Activates layer 3 while held, returns to the previous layer on release

  • MO(4) - Activates layer 4 while held, returns to the previous layer on release

  • MO(5) - Activates layer 5 while held, returns to the previous layer on release

  • MO(6) - Activates layer 6 while held, returns to the previous layer on release

  • MO(7) - Activates layer 7 while held, returns to the previous layer on release

  • DF(0) - Sets layer 0 as the default layer

  • DF(1) - Sets layer 1 as the default layer

  • DF(2) - Sets layer 2 as the default layer

  • DF(3) - Sets layer 3 as the default layer

  • DF(4) - Sets layer 4 as the default layer

  • DF(5) - Sets layer 5 as the default layer

  • DF(6) - Sets layer 6 as the default layer

  • DF(7) - Sets layer 7 as the default layer

  • TG(0) - Activates layer 0 on press and deactivates it on the next press

  • TG(1) - Activates layer 1 on press and deactivates it on the next press

  • TG(2) - Activates layer 2 on press and deactivates it on the next press

  • TG(3) - Activates layer 3 on press and deactivates it on the next press

  • TG(4) - Activates layer 4 on press and deactivates it on the next press

  • TG(5) - Activates layer 5 on press and deactivates it on the next press

  • TG(6) - Activates layer 6 on press and deactivates it on the next press

  • TG(7) - Activates layer 7 on press and deactivates it on the next press

  • TT(0) - Toggles layer 0 on tap; tapping it repeatedly activates layer 0

  • TT(1) - Toggles layer 1 on tap; tapping it repeatedly activates layer 1

  • TT(2) - Toggles layer 2 on tap; tapping it repeatedly activates layer 2

  • TT(3) - Toggles layer 3 on tap; tapping it repeatedly activates layer 3

  • TT(4) - Toggles layer 4 on tap; tapping it repeatedly activates layer 4

  • TT(5) - Toggles layer 5 on tap; tapping it repeatedly activates layer 5

  • TT(6) - Toggles layer 6 on tap; tapping it repeatedly activates layer 6

  • TT(7) - Toggles layer 7 on tap; tapping it repeatedly activates layer 7

  • TO(0) - Deactivates every non-default layer except layer 0, so the keyboard uses only the layer 0 keymap

  • TO(1) - Deactivates every non-default layer except layer 1, so the keyboard uses only the layer 1 keymap

  • TO(2) - Deactivates every non-default layer except layer 2, so the keyboard uses only the layer 2 keymap

  • TO(3) - Deactivates every non-default layer except layer 3, so the keyboard uses only the layer 3 keymap

  • TO(4) - Deactivates every non-default layer except layer 4, so the keyboard uses only the layer 4 keymap

  • TO(5) - Deactivates every non-default layer except layer 5, so the keyboard uses only the layer 5 keymap

  • TO(6) - Deactivates every non-default layer except layer 6, so the keyboard uses only the layer 6 keymap

  • TO(7) - Deactivates every non-default layer except layer 7, so the keyboard uses only the layer 7 keymap

  • OSL(0) - After a single press, the next key pressed uses the layer 0 definition, then returns to normal

  • OSL(1) - After a single press, the next key pressed uses the layer 1 definition, then returns to normal

  • OSL(2) - After a single press, the next key pressed uses the layer 2 definition, then returns to normal

  • OSL(3) - After a single press, the next key pressed uses the layer 3 definition, then returns to normal

  • OSL(4) - After a single press, the next key pressed uses the layer 4 definition, then returns to normal

  • OSL(5) - After a single press, the next key pressed uses the layer 5 definition, then returns to normal

  • OSL(6) - After a single press, the next key pressed uses the layer 6 definition, then returns to normal

  • OSL(7) - After a single press, the next key pressed uses the layer 7 definition, then returns to normal

Mouse emulation ​

Mouse emulation lets a key perform mouse actions.

  • Mouse ↑ - Moves the cursor up

  • Mouse ↓ - Moves the cursor down

  • Mouse ← - Moves the cursor left

  • Mouse → - Moves the cursor right

  • Mouse Btn1 - Presses mouse button 1

  • Mouse Btn2 - Presses mouse button 2

  • Mouse Btn3 - Presses mouse button 3

  • Mouse Btn4 - Presses mouse button 4

  • Mouse Btn5 - Presses mouse button 5

  • Mouse Btn6 - Presses mouse button 6

  • Mouse Btn7 - Presses mouse button 7

  • Mouse Btn8 - Presses mouse button 8

  • Mouse Wh↑ - Scrolls the wheel up

  • Mouse Wh↓ - Scrolls the wheel down

  • Mouse Wh← - Scrolls the wheel left

  • Mouse Wh→ - Scrolls the wheel right

  • Mouse Acc0 - Sets the pointer speed to 0

  • Mouse Acc1 - Sets the pointer speed to 1

  • Mouse Acc2 - Sets the pointer speed to 2

Advanced keys ​

The advanced keys have their own tab in the keycode menu. Unlike regular keycodes they are usually configured through a small dialog.

Mod-Tap ​

Holding a Mod-Tap key MT(mod, kc) makes it act as a modifier, while tapping it makes it act as a regular keycode.

MT(MOD_LCTL | MOD_LSFT, KC_ESC)

This key activates left Control and left Shift while held, and sends Escape when tapped.

Modifier Keys ​

MK(mod, kc) combines a modifier with a base key. On press it sends the modifier keydown event first and then the keycode. On release it sends the keycode keyup event first and then the modifier.

Using MK(mod, kc) feels like pressing the modifier and the base key at the same time. If you would rather not emulate a key combination with a macro, this key can often replace it.

MK(MOD_LCTL | MOD_LALT, KC_DEL)

This key sends Delete while left Control and left Alt are active.

Endpoint ​

TIP

These keys apply to keyboards running Marin Firmware

The output option can be found in the keyboard's options panel, where the preferred output of the keyboard can be selected as USB or Bluetooth from a dropdown.

When the keyboard is connected over USB and Bluetooth at the same time, it sends its report to the preferred endpoint. For example, with USB connected, it can send reports to the Bluetooth endpoint first.

Three endpoint control keys are available in the advanced keys, so the preferred output can be switched directly from the keyboard:

  • Endpoint Toggle: Switches the preferred output back and forth between USB and Bluetooth
  • Endpoint USB: Switches the preferred output to the USB endpoint
  • Endpoint BLE: Switches the preferred output to the Bluetooth endpoint

Assigning these keys to convenient positions makes switching the preferred output much quicker.

Any ​

Any is a custom key: you can enter a keycode, a key combination with parameters, or a hexadecimal value in the dialog, and LINK works out the corresponding key from your input.