mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-08-10 20:25:56 +00:00
Compare commits
98 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
a2b4178245 | ||
![]() |
ef5b161bb5 | ||
![]() |
23d68d0ba1 | ||
![]() |
435a1202e7 | ||
![]() |
3e8f272873 | ||
![]() |
f8a915a2db | ||
![]() |
ec26684491 | ||
![]() |
ac46378ac6 | ||
![]() |
bb4af7deee | ||
![]() |
d8db4ab202 | ||
![]() |
329b574831 | ||
![]() |
20e5798e63 | ||
![]() |
9aee5e6427 | ||
![]() |
dfef321bdf | ||
![]() |
b29799f887 | ||
![]() |
0a00583462 | ||
![]() |
a057f1ca9e | ||
![]() |
62a8603122 | ||
![]() |
6c20c6219c | ||
![]() |
f0f1a363d2 | ||
![]() |
ea7bb624de | ||
![]() |
03ad6927cb | ||
![]() |
ff14028bd8 | ||
![]() |
c11a26ba54 | ||
![]() |
9d016767e8 | ||
![]() |
bb86d8a00c | ||
![]() |
cbf200e9dd | ||
![]() |
2bc34b09cd | ||
![]() |
9b7a3a0bc8 | ||
![]() |
1c88e4663d | ||
![]() |
76f3a10eec | ||
![]() |
98fa82ceef | ||
![]() |
b90141a156 | ||
![]() |
aee0f3c3d2 | ||
![]() |
07ab5befc7 | ||
![]() |
25d757284c | ||
![]() |
841ea7ceb6 | ||
![]() |
54517f8b34 | ||
![]() |
dacc746b01 | ||
![]() |
bcc1a7ca30 | ||
![]() |
6caea0acfb | ||
![]() |
64f1ad00a7 | ||
![]() |
f2ebafcee8 | ||
![]() |
595f3cbe5b | ||
![]() |
f1513c3ad2 | ||
![]() |
bd874b9577 | ||
![]() |
9fc7bb1f6a | ||
![]() |
573e1c09e7 | ||
![]() |
4deb5de438 | ||
![]() |
b6c5c4cf52 | ||
![]() |
e0d467dbab | ||
![]() |
449736c06d | ||
![]() |
07e0558e9a | ||
![]() |
f2bf5a9a74 | ||
![]() |
7a8c139d07 | ||
![]() |
49892272a0 | ||
![]() |
723d338c62 | ||
![]() |
0fa192091c | ||
![]() |
4b5dcda126 | ||
![]() |
c531dfb6a7 | ||
![]() |
4ac48a61a6 | ||
![]() |
4df6b7ba19 | ||
![]() |
56ed2d495d | ||
![]() |
c14e297ad5 | ||
![]() |
9ce35e823b | ||
![]() |
1225120b92 | ||
![]() |
f2bc70a264 | ||
![]() |
4e41812a67 | ||
![]() |
7e8d4be8ac | ||
![]() |
b5d9bee969 | ||
![]() |
1775a3075e | ||
![]() |
095b28e006 | ||
![]() |
8a27703ef4 | ||
![]() |
006abbfd6f | ||
![]() |
95e7e10061 | ||
![]() |
87dc2efda8 | ||
![]() |
ed99581161 | ||
![]() |
83d33caf63 | ||
![]() |
6834febece | ||
![]() |
8def9bc642 | ||
![]() |
3fc5a05d66 | ||
![]() |
1147fc24ad | ||
![]() |
d4056a11d3 | ||
![]() |
1572375bfb | ||
![]() |
0284431ad9 | ||
![]() |
8e86e22187 | ||
![]() |
9c4b9bbccc | ||
![]() |
0537a59920 | ||
![]() |
d21b287e7d | ||
![]() |
c50e80e13b | ||
![]() |
738a9fc16c | ||
![]() |
b89cec9ebc | ||
![]() |
38299ff2ef | ||
![]() |
61c53ad75e | ||
![]() |
9234f9c964 | ||
![]() |
2869d51ba8 | ||
![]() |
bc7fe1223d | ||
![]() |
f804bd3d2d |
@@ -1,10 +1,10 @@
|
||||
# Code Of Conduct
|
||||
|
||||
QMK strives to be an inclusive and tolerant community. We welcome participation from anyone regardless of age, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, political belief, race, religion, or sexual identity and orientation.
|
||||
QMK strives to be an inclusive, tolerant, and welcoming community. We encourage participation from anyone regardless of age, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, political belief, race, religion, or sexual identity and orientation.
|
||||
|
||||
> “A gentle word turns away wrath, but a harsh word stirs up anger.”
|
||||
> “A gentle word turns away wrath, but a harsh word stirs up anger."
|
||||
|
||||
Our users, contributors, and collaborators are expected to treat each other with respect, to assume good intentions, and to gently correct, where possible, rather than react with escalation. Some examples of behavior we will not tolerate include, but is not limited to:
|
||||
Our users, contributors, and collaborators are expected to treat each other with kindness and respect, to assume good intentions, and to gently correct, where possible, rather than react with escalation. While our goal is to be as accurate as possible, kindness and understanding are more valuable than correctness. Some examples of behavior we will not tolerate include, but is not limited to:
|
||||
|
||||
* The use of sexualized language or imagery
|
||||
* Unwelcome advances, sexual or otherwise
|
||||
|
@@ -44,8 +44,8 @@
|
||||
* [PS/2 Mouse](feature_ps2_mouse.md)
|
||||
* [RGB Lighting](feature_rgblight.md)
|
||||
* [RGB Matrix](feature_rgb_matrix.md)
|
||||
* [Space Cadet Shift](feature_space_cadet.md)
|
||||
* [Space Cadet Shift Enter](feature_space_shift_cadet.md)
|
||||
* [Space Cadet Shift](feature_space_cadet_shift.md)
|
||||
* [Space Cadet Shift Enter](feature_space_cadet_shift_enter.md)
|
||||
* [Stenography](feature_stenography.md)
|
||||
* [Swap Hands](feature_swap_hands.md)
|
||||
* [Tap Dance](feature_tap_dance.md)
|
||||
|
@@ -44,8 +44,8 @@
|
||||
* [PS/2 Mouse](feature_ps2_mouse.md)
|
||||
* [RGB Lighting](feature_rgblight.md)
|
||||
* [RGB Matrix](feature_rgb_matrix.md)
|
||||
* [Space Cadet Shift](feature_space_cadet.md)
|
||||
* [Space Cadet Shift Enter](feature_space_shift_cadet.md)
|
||||
* [Space Cadet Shift](feature_space_cadet_shift.md)
|
||||
* [Space Cadet Shift Enter](feature_space_cadet_shift_enter.md)
|
||||
* [Stenography](feature_stenography.md)
|
||||
* [Swap Hands](feature_swap_hands.md)
|
||||
* [Tap Dance](feature_tap_dance.md)
|
||||
|
@@ -91,6 +91,8 @@ This is a C header file that is one of the first things included, and will persi
|
||||
* key combination that allows the use of magic commands (useful for debugging)
|
||||
* `#define USB_MAX_POWER_CONSUMPTION`
|
||||
* sets the maximum power (in mA) over USB for the device (default: 500)
|
||||
* `#define SCL_CLOCK 100000L`
|
||||
* sets the SCL_CLOCK speed for split keyboards. The default is `100000L` but some boards can be set to `400000L`.
|
||||
|
||||
## Features That Can Be Disabled
|
||||
|
||||
|
@@ -133,7 +133,7 @@ We've added shortcuts to make common modifier/tap (mod-tap) mappings more compac
|
||||
|
||||
?> 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.
|
||||
?> Additionally, if there is at least one right-handed modifier, any other modifiers in a chain of functions will turn into their right-handed equivalents, so it is not possible to "mix and match" the two.
|
||||
|
||||
# One Shot Keys
|
||||
|
||||
|
@@ -1,10 +1,20 @@
|
||||
# Backlighting
|
||||
|
||||
<!-- FIXME: Describe how backlighting works in QMK -->
|
||||
Many keyboards support backlit keys by way of individual LEDs placed through or underneath the keyswitches. QMK is able to control the brightness of these LEDs by switching them on and off rapidly in a certain ratio, a technique known as *Pulse Width Modulation*, or PWM. By altering the duty cycle of the PWM signal, it creates the illusion of dimming.
|
||||
|
||||
## Backlight Keycodes
|
||||
The MCU can only supply so much current to its GPIO pins. Instead of powering the backlight directly from the MCU, the backlight pin is connected to a transistor or MOSFET that switches the power to the LEDs.
|
||||
|
||||
These keycodes control the backlight. Most keyboards use this for single color in-switch lighting.
|
||||
## Usage
|
||||
|
||||
Most keyboards have backlighting enabled by default if they support it, but if it is not working for you, check that your `rules.mk` includes the following:
|
||||
|
||||
```make
|
||||
BACKLIGHT_ENABLE = yes
|
||||
```
|
||||
|
||||
You should then be able to use the keycodes below to change the backlight level.
|
||||
|
||||
## Keycodes
|
||||
|
||||
|Key |Description |
|
||||
|---------|------------------------------------------|
|
||||
@@ -16,24 +26,28 @@ These keycodes control the backlight. Most keyboards use this for single color i
|
||||
|`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.
|
||||
## Caveats
|
||||
|
||||
## Configuration Options in `config.h`
|
||||
This feature is distinct from both the [RGB underglow](feature_rgblight.md) and [RGB matrix](feature_rgb_matrix.md) features as it usually allows for only a single colour per switch, though you can obviously use multiple different coloured LEDs on a keyboard.
|
||||
|
||||
* `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.
|
||||
Hardware PWM is only supported on certain pins of the MCU, so if the backlighting is not connected to one of them, a software implementation will be used, and backlight breathing will not be available. Currently the supported pins are `B5`, `B6`, `B7`, and `C6`.
|
||||
|
||||
## Notes on Implementation
|
||||
## Configuration
|
||||
|
||||
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 change the behaviour of the backlighting, `#define` these in your `config.h`:
|
||||
|
||||
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.
|
||||
|Define |Default |Description |
|
||||
|---------------------|-------------|-------------------------------------------------------------------------------------------------------------|
|
||||
|`BACKLIGHT_PIN` |`B7` |The pin that controls the LEDs. Unless you are designing your own keyboard, you shouldn't need to change this|
|
||||
|`BACKLIGHT_LEVELS` |`3` |The number of brightness levels (maximum 15 excluding off) |
|
||||
|`BACKLIGHT_BREATHING`|*Not defined*|Enable backlight breathing, if hardware PWM is used |
|
||||
|`BREATHING_PERIOD` |`6` |The length of one backlight "breath" in seconds |
|
||||
|
||||
## Hardware PWM Implementation
|
||||
|
||||
When using the supported pins for backlighting, QMK will use a hardware timer configured to output a PWM signal. This timer will count up to `ICRx` (by default `0xFFFF`) before resetting to 0.
|
||||
The desired brightness is calculated and stored in the `OCRxx` register. When the counter reaches this value, the backlight pin will go low, and is pulled high again when the counter resets.
|
||||
In this way `OCRxx` essentially controls the duty cycle of the LEDs, and thus the brightness, where `0x0000` is completely off and `0xFFFF` is completely on.
|
||||
|
||||
The breathing effect is achieved by registering an interrupt handler for `TIMER1_OVF_vect` that is called whenever the counter resets, roughly 244 times per second.
|
||||
In this handler, the value of an incrementing counter is mapped onto a precomputed brightness curve. To turn off breathing, the interrupt handler is simply disabled, and the brightness reset to the level stored in EEPROM.
|
||||
|
@@ -1,89 +1,100 @@
|
||||
# Bootmagic and Magic Keycodes
|
||||
# Bootmagic
|
||||
|
||||
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.
|
||||
There are three separate but related features that allow you to change the behavior of your keyboard without reflashing. While each of them have similar functionality, it is accessed 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** is a system for configuring your keyboard while it initializes. To trigger a Bootmagic command, hold down the Bootmagic key 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.
|
||||
**Bootmagic Keycodes** are prefixed with `MAGIC_`, and allow you to access the Bootmagic functionality *after* your keyboard has initialized. To use the keycodes, assign them to your keymap as you would any other keycode.
|
||||
|
||||
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.
|
||||
**Command**, formerly known as **Magic**, is another feature that allows you to control different aspects of your keyboard. While it shares some functionality with Bootmagic, it also allows you to do things that Bootmagic does not, such as printing version information to the console. For more information, see [Command](feature_command.md).
|
||||
|
||||
## Enabling Bootmagic
|
||||
On some keyboards Bootmagic is disabled by default. If this is the case, it must be explicitly enabled in your `rules.mk` with:
|
||||
|
||||
Bootmagic is disabled by default. To use Bootmagic you need to enable it in your `rules.mk` file:
|
||||
```make
|
||||
BOOTMAGIC_ENABLE = yes
|
||||
```
|
||||
|
||||
BOOTMAGIC_ENABLE = yes
|
||||
## Hotkeys
|
||||
|
||||
## Bootmagic Hotkeys and Keycodes
|
||||
Hold down the Bootmagic key (Space by default) and the desired hotkey while plugging in your keyboard. For example, holding Space+`B` should cause it to enter the bootloader.
|
||||
|
||||
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.
|
||||
|Hotkey |Description |
|
||||
|------------------|---------------------------------------------|
|
||||
|Escape |Ignore Bootmagic configuration in EEPROM |
|
||||
|`B` |Enter the bootloader |
|
||||
|`D` |Toggle debugging over serial |
|
||||
|`X` |Toggle key matrix debugging |
|
||||
|`K` |Toggle keyboard debugging |
|
||||
|`M` |Toggle mouse debugging |
|
||||
|Backspace |Clear the EEPROM |
|
||||
|Caps Lock |Toggle treating Caps Lock as Left Control |
|
||||
|Left Control |Toggle swapping Caps Lock and Left Control |
|
||||
|Left Alt |Toggle swapping Left Alt and Left GUI |
|
||||
|Right Alt |Toggle swapping Right Alt and Right GUI |
|
||||
|Left GUI |Toggle the GUI keys (useful when gaming) |
|
||||
|<code>`</code>|Toggle swapping <code>`</code> and Escape|
|
||||
|`\` |Toggle swapping `\` and Backspace |
|
||||
|`N` |Toggle N-Key Rollover (NKRO) |
|
||||
|`0` |Make layer 0 the default layer |
|
||||
|`1` |Make layer 1 the default layer |
|
||||
|`2` |Make layer 2 the default layer |
|
||||
|`3` |Make layer 3 the default layer |
|
||||
|`4` |Make layer 4 the default layer |
|
||||
|`5` |Make layer 5 the default layer |
|
||||
|`6` |Make layer 6 the default layer |
|
||||
|`7` |Make layer 7 the default layer |
|
||||
|
||||
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.
|
||||
## Keycodes
|
||||
|
||||
|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 |
|
||||
|Keycode |Aliases |Description |
|
||||
|----------------------------------|---------|------------------------------------------|
|
||||
|`MAGIC_CAPSLOCK_TO_CONTROL` | |Treat Caps Lock as Left Control |
|
||||
|`MAGIC_UNCAPSLOCK_TO_CONTROL` | |Stop treating Caps Lock as Left Control |
|
||||
|`MAGIC_HOST_NKRO` | |Force N-Key Rollover (NKRO) on |
|
||||
|`MAGIC_UNHOST_NKRO` | |Force NKRO off |
|
||||
|`MAGIC_TOGGLE_NKRO` | |Turn NKRO on or off |
|
||||
|`MAGIC_NO_GUI` | |Disable the GUI keys (useful when gaming) |
|
||||
|`MAGIC_UNNO_GUI` | |Enable the GUI keys |
|
||||
|`MAGIC_SWAP_ALT_GUI` |`AG_SWAP`|Swap Alt and GUI on both sides (for macOS)|
|
||||
|`MAGIC_UNSWAP_ALT_GUI` |`AG_NORM`|Unswap Left Alt and Left GUI |
|
||||
|`MAGIC_SWAP_BACKSLASH_BACKSPACE` | |Swap `\` and Backspace |
|
||||
|`MAGIC_UNSWAP_BACKSLASH_BACKSPACE`| |Unswap `\` and Backspace |
|
||||
|`MAGIC_SWAP_CONTROL_CAPSLOCK` | |Swap Left Control and Caps Lock |
|
||||
|`MAGIC_UNSWAP_CONTROL_CAPSLOCK` | |Unswap Left Control and Caps Lock |
|
||||
|`MAGIC_SWAP_GRAVE_ESC` | |Swap <code>`</code> and Escape |
|
||||
|`MAGIC_UNSWAP_GRAVE_ESC` | |Unswap <code>`</code> and Escape |
|
||||
|`MAGIC_SWAP_LALT_LGUI` | |Swap Left Alt and Left GUI |
|
||||
|`MAGIC_UNSWAP_LALT_LGUI` | |Unswap Left Alt and Left GUI |
|
||||
|`MAGIC_SWAP_RALT_RGUI` | |Swap Right Alt and Right GUI |
|
||||
|`MAGIC_UNSWAP_RALT_RGUI` | |Unswap Right Alt and Right GUI |
|
||||
|
||||
## Bootmagic Configuration
|
||||
## 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.
|
||||
If you would like to change the hotkey assignments for Bootmagic, `#define` these in your `config.h` at either 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|
|
||||
|Define |Default |Description |
|
||||
|----------------------------------------|-------------|---------------------------------------------------|
|
||||
|`BOOTMAGIC_KEY_SALT` |`KC_SPACE` |The Bootmagic key |
|
||||
|`BOOTMAGIC_KEY_SKIP` |`KC_ESC` |Ignore Bootmagic configuration in EEPROM |
|
||||
|`BOOTMAGIC_KEY_EEPROM_CLEAR` |`KC_BSPACE` |Clear the EEPROM configuration |
|
||||
|`BOOTMAGIC_KEY_BOOTLOADER` |`KC_B` |Enter the bootloader |
|
||||
|`BOOTMAGIC_KEY_DEBUG_ENABLE` |`KC_D` |Toggle debugging over serial |
|
||||
|`BOOTMAGIC_KEY_DEBUG_MATRIX` |`KC_X` |Toggle matrix debugging |
|
||||
|`BOOTMAGIC_KEY_DEBUG_KEYBOARD` |`KC_K` |Toggle keyboard debugging |
|
||||
|`BOOTMAGIC_KEY_DEBUG_MOUSE` |`KC_M` |Toggle mouse debugging |
|
||||
|`BOOTMAGIC_KEY_SWAP_CONTROL_CAPSLOCK` |`KC_LCTRL` |Swap Left Control and Caps Lock |
|
||||
|`BOOTMAGIC_KEY_CAPSLOCK_TO_CONTROL` |`KC_CAPSLOCK`|Toggle treating Caps Lock as Left Control |
|
||||
|`BOOTMAGIC_KEY_SWAP_LALT_LGUI` |`KC_LALT` |Toggle swapping Left Alt and Left GUI (for macOS) |
|
||||
|`BOOTMAGIC_KEY_SWAP_RALT_RGUI` |`KC_RALT` |Toggle swapping Right Alt and Right GUI (for macOS)|
|
||||
|`BOOTMAGIC_KEY_NO_GUI` |`KC_LGUI` |Toggle the GUI keys (useful when gaming) |
|
||||
|`BOOTMAGIC_KEY_SWAP_GRAVE_ESC` |`KC_GRAVE` |Toggle swapping <code>`</code> and Escape |
|
||||
|`BOOTMAGIC_KEY_SWAP_BACKSLASH_BACKSPACE`|`KC_BSLASH` |Toggle swapping `\` and Backspace |
|
||||
|`BOOTMAGIC_HOST_NKRO` |`KC_N` |Toggle N-Key Rollover (NKRO) |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_0` |`KC_0` |Make layer 0 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_1` |`KC_1` |Make layer 1 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_2` |`KC_2` |Make layer 2 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_3` |`KC_3` |Make layer 3 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_4` |`KC_4` |Make layer 4 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_5` |`KC_5` |Make layer 5 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_6` |`KC_6` |Make layer 6 the default layer |
|
||||
|`BOOTMAGIC_KEY_DEFAULT_LAYER_7` |`KC_7` |Make layer 7 the default layer |
|
||||
|
@@ -1,52 +1,50 @@
|
||||
# Command (Formerly known as Magic)
|
||||
# Command
|
||||
|
||||
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.
|
||||
Command, formerly known as Magic, 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#keycodes). Wherever possible we encourage you to use that feature instead of Command.
|
||||
|
||||
## Enabling Command
|
||||
On some keyboards Command is disabled by default. If this is the case, it must be explicitly enabled in your `rules.mk`:
|
||||
|
||||
By default Command is disabled. You can enable it in your `rules.mk` file:
|
||||
|
||||
COMMAND_ENABLE = yes
|
||||
```make
|
||||
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`.
|
||||
To use Command, hold down the key combination defined by the `IS_COMMAND()` macro. By default this is Left Shift+Right Shift. Then, press the key corresponding to the command you want. For example, to output the current QMK version to the QMK Toolbox console, press Left Shift+Right Shift+`V`.
|
||||
|
||||
## Configuration
|
||||
|
||||
The following values can be defined in `config.h` to control the behavior of Command.
|
||||
If you would like to change the key assignments for Command, `#define` these in your `config.h` at either the keyboard or keymap level. All keycode assignments here must omit the `KC_` prefix.
|
||||
|
||||
|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|
|
||||
|Define |Default |Description |
|
||||
|------------------------------------|--------------------------------------------------------------------------------------|------------------------------------------------|
|
||||
|`IS_COMMAND()` |<code>(keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)))</code>|The key combination to activate Command |
|
||||
|`MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS` |`true` |Set default layer with the Function row |
|
||||
|`MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS` |`true` |Set default layer with the number keys |
|
||||
|`MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM`|`false` |Set default layer with `MAGIC_KEY_LAYER0..9` |
|
||||
|`MAGIC_KEY_DEBUG` |`D` |Toggle debugging over serial |
|
||||
|`MAGIC_KEY_DEBUG_MATRIX` |`X` |Toggle key matrix debugging |
|
||||
|`MAGIC_KEY_DEBUG_KBD` |`K` |Toggle keyboard debugging |
|
||||
|`MAGIC_KEY_DEBUG_MOUSE` |`M` |Toggle mouse debugging |
|
||||
|`MAGIC_KEY_CONSOLE` |`C` |Enable the Command console |
|
||||
|`MAGIC_KEY_VERSION` |`V` |Print the running QMK version to the console |
|
||||
|`MAGIC_KEY_STATUS` |`S` |Print the current keyboard status to the console|
|
||||
|`MAGIC_KEY_HELP1` |`H` |Print Command help to the console |
|
||||
|`MAGIC_KEY_HELP2` |`SLASH` |Print Command help to the console (alternate) |
|
||||
|`MAGIC_KEY_LAYER0` |`0` |Make layer 0 the default layer |
|
||||
|`MAGIC_KEY_LAYER1` |`1` |Make layer 1 the default layer |
|
||||
|`MAGIC_KEY_LAYER2` |`2` |Make layer 2 the default layer |
|
||||
|`MAGIC_KEY_LAYER3` |`3` |Make layer 3 the default layer |
|
||||
|`MAGIC_KEY_LAYER4` |`4` |Make layer 4 the default layer |
|
||||
|`MAGIC_KEY_LAYER5` |`5` |Make layer 5 the default layer |
|
||||
|`MAGIC_KEY_LAYER6` |`6` |Make layer 6 the default layer |
|
||||
|`MAGIC_KEY_LAYER7` |`7` |Make layer 7 the default layer |
|
||||
|`MAGIC_KEY_LAYER8` |`8` |Make layer 8 the default layer |
|
||||
|`MAGIC_KEY_LAYER9` |`9` |Make layer 9 the default layer |
|
||||
|`MAGIC_KEY_LAYER0_ALT1` |`ESC` |Make layer 0 the default layer (alternate) |
|
||||
|`MAGIC_KEY_LAYER0_ALT2` |`GRAVE` |Make layer 0 the default layer (alternate) |
|
||||
|`MAGIC_KEY_BOOTLOADER` |`PAUSE` |Enter the bootloader |
|
||||
|`MAGIC_KEY_LOCK` |`CAPS` |Lock the keyboard so nothing can be typed |
|
||||
|`MAGIC_KEY_EEPROM` |`E` |Clear the EEPROM |
|
||||
|`MAGIC_KEY_NKRO` |`N` |Toggle N-Key Rollover (NKRO) |
|
||||
|`MAGIC_KEY_SLEEP_LED` |`Z` |Toggle LED when computer is sleeping |
|
||||
|
@@ -4,10 +4,10 @@ QMK supports temporary macros created on the fly. We call these Dynamic Macros.
|
||||
|
||||
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`:
|
||||
To enable them, first add a new element to the end of your `keycodes` enum — `DYNAMIC_MACRO_RANGE`:
|
||||
|
||||
```c
|
||||
enum planck_keycodes {
|
||||
enum keycodes {
|
||||
QWERTY = SAFE_RANGE,
|
||||
COLEMAK,
|
||||
DVORAK,
|
||||
@@ -20,7 +20,7 @@ enum planck_keycodes {
|
||||
};
|
||||
```
|
||||
|
||||
It must be the last element because `dynamic_macros.h` will add some more keycodes after it.
|
||||
Your `keycodes` enum may have a slightly different name. You must add `DYNAMIC_MACRO_RANGE` as the last element because `dynamic_macros.h` will add some more keycodes after it.
|
||||
|
||||
Below it, include the `dynamic_macro.h` header:
|
||||
|
||||
|
@@ -1,17 +1,24 @@
|
||||
# Grave Escape
|
||||
|
||||
Grave Escape is a feature that allows you to share the grave key (<code>`</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`.
|
||||
If you're using a 60% keyboard, or any other layout with no F-row, you will have noticed that there is no dedicated Escape key. Grave Escape is a feature that allows you to share the grave key (<code>`</code> and `~`) with Escape.
|
||||
|
||||
## Usage
|
||||
|
||||
Replace the `KC_GRAVE` key in your keymap (usually to the left of the `1` key) with `KC_GESC`. When pressed it will behave like `KC_ESC`, but with Shift or GUI held it will send `KC_GRAVE`.
|
||||
|
||||
## Keycodes
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|---------|-----------|------------------------------------------------------------------|
|
||||
|`KC_GESC`|`GRAVE_ESC`|Escape when pressed, <code>`</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:
|
||||
## Configuration
|
||||
|
||||
| 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. |
|
||||
There are several possible key combinations this will break, among them Control+Shift+Escape on Windows and Command+Option+Escape on macOS. To work around this, you can `#define` these options in your `config.h`:
|
||||
|
||||
|Define |Description |
|
||||
|--------------------------|-----------------------------------------|
|
||||
|`GRAVE_ESC_ALT_OVERRIDE` |Always send Escape if Alt is pressed |
|
||||
|`GRAVE_ESC_CTRL_OVERRIDE` |Always send Escape if Control is pressed |
|
||||
|`GRAVE_ESC_GUI_OVERRIDE` |Always send Escape if GUI is pressed |
|
||||
|`GRAVE_ESC_SHIFT_OVERRIDE`|Always send Escape if Shift is pressed |
|
||||
|
@@ -1,11 +1,22 @@
|
||||
## Key Lock: Holding Down Keys for You
|
||||
# Key Lock
|
||||
|
||||
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.
|
||||
Sometimes you may find yourself needing to hold down a specific key for a long period of time. Key Lock holds down the next key you press for you. Press it again, and it will be released.
|
||||
|
||||
Here's how to use it:
|
||||
Let's say you need to type in ALL CAPS for a few sentences. Hit `KC_LOCK`, and then Shift. Now, Shift will be considered held until you tap it again. You can think of Key Lock as Caps Lock, but supercharged.
|
||||
|
||||
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!
|
||||
## Usage
|
||||
|
||||
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.
|
||||
First, enable Key Lock by setting `KEY_LOCK_ENABLE = yes` in your `rules.mk`. Then pick a key in your keymap and assign it the keycode `KC_LOCK`.
|
||||
|
||||
## Keycodes
|
||||
|
||||
|Keycode |Description |
|
||||
|---------|--------------------------------------------------------------|
|
||||
|`KC_LOCK`|Hold down the next key pressed, until the key is pressed again|
|
||||
|
||||
## Caveats
|
||||
|
||||
Key Lock is only able to hold standard action keys and [One Shot modifier](quantum_keycodes.md#one-shot-keys) keys (for example, if you have your Shift defined as `OSM(KC_LSFT)`).
|
||||
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.
|
||||
|
||||
Switching layers will not cancel the Key Lock.
|
||||
|
@@ -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, 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.
|
33
docs/feature_space_cadet_shift.md
Normal file
33
docs/feature_space_cadet_shift.md
Normal file
@@ -0,0 +1,33 @@
|
||||
# Space Cadet Shift: The Future, Built In
|
||||
|
||||
Steve Losh described the [Space Cadet Shift](http://stevelosh.com/blog/2012/10/a-modern-space-cadet/) quite well. Essentially, when you tap Left Shift on its own, you get an opening parenthesis; tap Right Shift on its own and you get the closing one. When held, the Shift keys function as normal. Yes, it's as cool as it sounds.
|
||||
|
||||
## Usage
|
||||
|
||||
Replace the Left Shift key in your keymap with `KC_LSPO` (Left Shift, Parenthesis Open), and Right Shift with `KC_RSPC` (Right Shift, Parenthesis Close).
|
||||
|
||||
## Keycodes
|
||||
|
||||
|Keycode |Description |
|
||||
|---------|--------------------------------------|
|
||||
|`KC_LSPO`|Left Shift when held, `(` when tapped |
|
||||
|`KC_RSPC`|Right Shift when held, `)` when tapped|
|
||||
|
||||
## Caveats
|
||||
|
||||
Space Cadet's functionality can conflict with the default Command functionality when both Shift keys are held at the same time. Make sure that Command is disabled in your `rules.mk` with:
|
||||
|
||||
```make
|
||||
COMMAND_ENABLE = no
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
By default Space Cadet assumes a US ANSI layout, but if your layout uses different keys for parentheses, you can redefine them in your `config.h`.
|
||||
You can also disable the rollover, allowing 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.
|
||||
|
||||
|Define |Default |Description |
|
||||
|------------------------------|-------------|------------------------------------------------------------|
|
||||
|`LSPO_KEY` |`KC_9` |The keycode to send when Left Shift is tapped |
|
||||
|`RSPC_KEY` |`KC_0` |The keycode to send when Right Shift is tapped |
|
||||
|`DISABLE_SPACE_CADET_ROLLOVER`|*Not defined*|If defined, use the opposite Shift key to cancel Space Cadet|
|
31
docs/feature_space_cadet_shift_enter.md
Normal file
31
docs/feature_space_cadet_shift_enter.md
Normal file
@@ -0,0 +1,31 @@
|
||||
# Space Cadet Shift Enter
|
||||
|
||||
Based on the [Space Cadet Shift](feature_space_cadet_shift.md) feature. Tap the Shift key on its own, and it behaves like Enter. When held, the Shift functions as normal.
|
||||
|
||||
## Usage
|
||||
|
||||
Replace any Shift key in your keymap with `KC_SFTENT` (Shift, Enter), and you're done.
|
||||
|
||||
## Keycodes
|
||||
|
||||
|Keycode |Description |
|
||||
|-----------|----------------------------------------|
|
||||
|`KC_SFTENT`|Right Shift when held, Enter when tapped|
|
||||
|
||||
## Caveats
|
||||
|
||||
As with Space Cadet Shift, this feature may conflict with Command, so it should be disabled in your `rules.mk` with:
|
||||
|
||||
```make
|
||||
COMMAND_ENABLE = no
|
||||
```
|
||||
|
||||
This feature also uses the same timers as Space Cadet Shift, so using them in tandem may produce strange results.
|
||||
|
||||
## Configuration
|
||||
|
||||
By default Space Cadet assumes a US ANSI layout, but if you'd like to use a different key for Enter, you can redefine it in your `config.h`:
|
||||
|
||||
|Define |Default |Description |
|
||||
|------------|--------|------------------------------------------------|
|
||||
|`SFTENT_KEY`|`KC_ENT`|The keycode to send when the Shift key is tapped|
|
@@ -1,26 +0,0 @@
|
||||
## 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.
|
||||
|
@@ -196,22 +196,20 @@ SRC += your_name.c
|
||||
Pretty simple. It is a nice way to keep some rules common on all your keymaps.
|
||||
|
||||
|
||||
### In `/qmk_firmware/users/<your_name>/<you_name>.h`
|
||||
### In `/qmk_firmware/users/<your_name>/<your_name>.h`
|
||||
|
||||
You will need a few things in this file:
|
||||
|
||||
```c
|
||||
#ifndef YOUR_NAME
|
||||
#define YOUR_NAME
|
||||
#pragma once
|
||||
|
||||
#include "quantum.h"
|
||||
#include "process_keycode/process_tap_dance.h"
|
||||
|
||||
|
||||
typedef struct {
|
||||
bool is_press_action;
|
||||
int state;
|
||||
} xtap;
|
||||
} tap;
|
||||
|
||||
enum {
|
||||
SINGLE_TAP = 1,
|
||||
@@ -225,9 +223,9 @@ enum {
|
||||
|
||||
//Tap dance enums
|
||||
enum {
|
||||
CTL_X = 0,
|
||||
SOME_OTHER_DANCE
|
||||
}
|
||||
X_CTL = 0,
|
||||
SOME_OTHER_DANCE
|
||||
};
|
||||
|
||||
int cur_dance (qk_tap_dance_state_t *state);
|
||||
|
||||
@@ -241,7 +239,7 @@ void x_reset (qk_tap_dance_state_t *state, void *user_data);
|
||||
And then in your user's `.c` file you implement the functions above:
|
||||
|
||||
```c
|
||||
#include "gordon.h"
|
||||
#include "<your_name>.h"
|
||||
#include "quantum.h"
|
||||
#include "action.h"
|
||||
#include "process_keycode/process_tap_dance.h"
|
||||
@@ -335,4 +333,4 @@ qk_tap_dance_action_t tap_dance_actions[] = {
|
||||
};
|
||||
```
|
||||
|
||||
And then simply use TD(X_CTL) anywhere in your keymap.
|
||||
And then simply use `TD(X_CTL)` anywhere in your keymap after including `<your_name>.h`.
|
||||
|
@@ -19,7 +19,7 @@ QMK has a staggering number of features for building your keyboard. It can take
|
||||
* [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.
|
||||
* [RGB Matrix](feature_rgb_matrix.md) - RGB Matrix lights for per key lighting.
|
||||
* [Space Cadet](feature_space_cadet.md) - Use your left/right shift keys to type parenthesis and brackets.
|
||||
* [Space Cadet](feature_space_cadet_shift.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.
|
||||
* [Swap Hands](feature_swap_hands.md) - Mirror your keyboard for one handed usage.
|
||||
* [Tap Dance](feature_tap_dance.md) - Make a single key do as many things as you want.
|
||||
|
@@ -19,58 +19,79 @@ If you're having trouble flashing/erasing your board, and running into cryptic e
|
||||
Memory write error, use debug for more info.
|
||||
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!
|
||||
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, Pro Micro, 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 or Pro Micro 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
|
||||
|
||||
* [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)
|
||||
* [WinAVR](http://www.ladyada.net/learn/avr/setup-win.html) (Windows)
|
||||
* [Teensy Loader](https://www.pjrc.com/teensy/loader.html) (if using a Teensy)
|
||||
* QMK Toolbox (flash as usual - be sure to select the correct MCU) or `avrdude` via [WinAVR](http://www.ladyada.net/learn/avr/setup-win.html) (for Teensy & Pro Micro)
|
||||
|
||||
## Wiring
|
||||
|
||||
This is pretty straight-forward - we'll be connecting like-things to like-things in the following manner:
|
||||
|
||||
Flasher B0 <-> Keyboard RESET
|
||||
Flasher B1 <-> Keyboard B1 (SCLK)
|
||||
Flasher B2 <-> Keyboard B2 (MOSI)
|
||||
Flasher B3 <-> Keyboard B3 (MISO)
|
||||
Flasher VCC <-> Keyboard VCC
|
||||
Flasher GND <-> Keyboard GND
|
||||
### Teensy 2.0
|
||||
|
||||
## The ISP Firmware
|
||||
Teensy B0 <-> Keyboard RESET
|
||||
Teensy B1 <-> Keyboard B1 (SCLK)
|
||||
Teensy B2 <-> Keyboard B2 (MOSI)
|
||||
Teensy B3 <-> Keyboard B3 (MISO)
|
||||
Teensy VCC <-> Keyboard VCC
|
||||
Teensy GND <-> Keyboard GND
|
||||
|
||||
### Pro Micro
|
||||
|
||||
Pro Micro 10 (B6) <-> Keyboard RESET
|
||||
Pro Micro 15 (B1) <-> Keyboard B1 (SCLK)
|
||||
Pro Micro 16 (B2) <-> Keyboard B2 (MOSI)
|
||||
Pro Micro 14 (B3) <-> Keyboard B3 (MISO)
|
||||
Pro Micro VCC <-> Keyboard VCC
|
||||
Pro Micro GND <-> Keyboard GND
|
||||
|
||||
## The ISP Firmware (now pre-compiled)
|
||||
|
||||
The only difference between the .hex files below is which pin is connected to RESET. You can use them on other boards as well, as long as you're aware of the pins being used. If for some reason neither of these pins are available, [create an issue](https://github.com/qmk/qmk_firmware/issues/new), and we can generate one for you!
|
||||
|
||||
* Teensy 2.0: [`util/teensy_2.0_ISP_B0.hex`](https://github.com/qmk/qmk_firmware/blob/master/util/teensy_2.0_ISP_B0.hex) (`B0`)
|
||||
* Pro Micro: [`util/pro_micro_ISP_B6_10.hex`](https://github.com/qmk/qmk_firmware/blob/master/util/pro_mico_ISP_B6_10.hex) (`B6/10`)
|
||||
|
||||
**Flash your Teenys/Pro Micro with one of these and continue - you won't need the file after flashing your ISP device.**
|
||||
|
||||
## Just the Bootloader File
|
||||
|
||||
If you just want to get things back to normal, you can flash only a bootloader from [`util/` folder](https://github.com/qmk/qmk_firmware/tree/master/util), and use your normal process to flash the firmware afterwards. Be sure to flash the correct bootloader for your chip:
|
||||
|
||||
* [`atmega32u4`](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32u4_1_0_0.hex) - Most keyboards, Planck Rev 1-5, Preonic Rev 1-2
|
||||
* [`at90usb1286`](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_at90usb128x_1_0_1.hex) - Planck Light Rev 1
|
||||
|
||||
If you're not sure what your board uses, look in the `rules.mk` file for the keyboard in QMK. The `MCU =` line will have the value you need. It may differ between different versions of the board.
|
||||
|
||||
### Advanced/Production Techniques
|
||||
|
||||
If you'd like to flash both the bootloader **and** the regular firmware at the same time, you need to combine the files.
|
||||
|
||||
1. Open the original firmware .hex file in a text editor
|
||||
2. Remove the last line (which should be `:00000001FF` - this is an EOF message)
|
||||
3. Copy the entire bootloader's contents onto a new line (with no empty lines between) and paste it at the end of the original file
|
||||
4. Save it as a new file by naming it `<keyboard>_<keymap>_production.hex`
|
||||
|
||||
It's possible to use other bootloaders here in the same way, but __you need a bootloader__, otherwise you'll have to use ISP again to write new firmware to your keyboard.
|
||||
|
||||
## Flashing Your Bootloader/Production File
|
||||
|
||||
Make sure your keyboard is unplugged from any device, and plug in your Teensy.
|
||||
|
||||
1. Run Arduino after you have everything installed
|
||||
2. Select `Tools > Board * > Teensy 2.0`
|
||||
3. Click `File > Examples > 11.ArduinoISP > ArduinoISP`
|
||||
### QMK Toolbox
|
||||
|
||||
Then scroll down until you see something that looks like this block of code:
|
||||
1. `AVRISP device connected` will show up in yellow
|
||||
2. Select the correct bootloader/production .hex file with the `Open` dialog (spaces can't be in the path)
|
||||
3. Be sure the correct `Microcontroller` option is selected
|
||||
4. Hit `Flash`
|
||||
5. Wait, as nothing will output for a while, especially with production files
|
||||
|
||||
// Configure which pins to use:
|
||||
If the verification and fuse checks are ok, you're done! 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.
|
||||
|
||||
// The standard pin configuration.
|
||||
#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 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
|
||||
|
||||
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
|
||||
|
||||
Make sure your keyboard is unplugged from any device, and plug in your Teensy.
|
||||
### Command Line
|
||||
|
||||
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:
|
||||
|
||||
|
277
docs/keycodes.md
277
docs/keycodes.md
@@ -8,40 +8,8 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|
||||
|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_NO` |`XXXXXXX` |Ignore this key (NOOP) |
|
||||
|`KC_TRANSPARENT` |`KC_TRNS`, `_______`|Use the next lowest non-transparent key |
|
||||
|`KC_A` | |`a` and `A` |
|
||||
|`KC_B` | |`b` and `B` |
|
||||
|`KC_C` | |`c` and `C` |
|
||||
@@ -68,6 +36,16 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|`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 `)` |
|
||||
|`KC_ENTER` |`KC_ENT` |Return (Enter) |
|
||||
|`KC_ESCAPE` |`KC_ESC` |Escape |
|
||||
|`KC_BSPACE` |`KC_BSPC` |Delete (Backspace) |
|
||||
@@ -79,33 +57,28 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|`KC_RBRACKET` |`KC_RBRC` |`]` and `}` |
|
||||
|`KC_BSLASH` |`KC_BSLS` |`\` and <code>|</code> |
|
||||
|`KC_NONUS_HASH` |`KC_NUHS` |Non-US `#` and `~` |
|
||||
|`KC_NONUS_BSLASH` |`KC_NUBS` |Non-US `\` and <code>|</code> |
|
||||
|`KC_INT1` |`KC_RO` |JIS `\` and <code>|</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>`</code> and `~` |
|
||||
|`KC_GRAVE` |`KC_GRV`, `KC_ZKHK` |<code>`</code> and `~`, JIS Zenkaku/Hankaku|
|
||||
|`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_CAPSLOCK` |`KC_CLCK`, `KC_CAPS`|Caps Lock |
|
||||
|`KC_F1` | |F1 |
|
||||
|`KC_F2` | |F2 |
|
||||
|`KC_F3` | |F3 |
|
||||
|`KC_F4` | |F4 |
|
||||
|`KC_F5` | |F5 |
|
||||
|`KC_F6` | |F6 |
|
||||
|`KC_F7` | |F7 |
|
||||
|`KC_F8` | |F8 |
|
||||
|`KC_F9` | |F9 |
|
||||
|`KC_F10` | |F10 |
|
||||
|`KC_F11` | |F11 |
|
||||
|`KC_F12` | |F12 |
|
||||
|`KC_PSCREEN` |`KC_PSCR` |Print Screen |
|
||||
|`KC_SCROLLLOCK` |`KC_SLCK` |Scroll Lock |
|
||||
|`KC_PAUSE` |`KC_PAUS` |Pause |
|
||||
|`KC_PAUSE` |`KC_PAUS`, `KC_BRK` |Pause |
|
||||
|`KC_INSERT` |`KC_INS` |Insert |
|
||||
|`KC_HOME` | |Home |
|
||||
|`KC_PGUP` | |Page Up |
|
||||
@@ -116,58 +89,6 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|`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_MEDIA_EJECT` |`KC_EJCT` |Eject (macOS) |
|
||||
|`KC_NUMLOCK` |`KC_NLCK` |Keypad Num Lock and Clear |
|
||||
|`KC_KP_SLASH` |`KC_PSLS` |Keypad `/` |
|
||||
|`KC_KP_ASTERISK` |`KC_PAST` |Keypad `*` |
|
||||
@@ -185,11 +106,103 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|`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_NONUS_BSLASH` |`KC_NUBS` |Non-US `\` and <code>|</code> |
|
||||
|`KC_APPLICATION` |`KC_APP` |Application (Windows Menu Key) |
|
||||
|`KC_POWER` | |System Power (macOS) |
|
||||
|`KC_KP_EQUAL` |`KC_PEQL` |Keypad `=` |
|
||||
|`KC_F13` | |F13 |
|
||||
|`KC_F14` | |F14 |
|
||||
|`KC_F15` | |F15 |
|
||||
|`KC_F16` | |F16 |
|
||||
|`KC_F17` | |F17 |
|
||||
|`KC_F18` | |F18 |
|
||||
|`KC_F19` | |F19 |
|
||||
|`KC_F20` | |F20 |
|
||||
|`KC_F21` | |F21 |
|
||||
|`KC_F22` | |F22 |
|
||||
|`KC_F23` | |F23 |
|
||||
|`KC_F24` | |F24 |
|
||||
|`KC_EXECUTE` |`KC_EXEC` |Execute |
|
||||
|`KC_HELP` | |Help |
|
||||
|`KC_MENU` | |Menu |
|
||||
|`KC_SELECT` |`KC_SLCT` |Select |
|
||||
|`KC_STOP` | |Stop |
|
||||
|`KC_AGAIN` |`KC_AGIN` |Again |
|
||||
|`KC_UNDO` | |Undo |
|
||||
|`KC_CUT` | |Cut |
|
||||
|`KC_COPY` | |Copy |
|
||||
|`KC_PASTE` |`KC_PSTE` |Paste |
|
||||
|`KC_FIND` | |Find |
|
||||
|`KC__MUTE` | |Mute (macOS) |
|
||||
|`KC__VOLUP` | |Volume Up (macOS) |
|
||||
|`KC__VOLDOWN` | |Volume Down (macOS) |
|
||||
|`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_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 |
|
||||
|`KC_INT1` |`KC_RO` |JIS `\` and <code>|</code> |
|
||||
|`KC_INT2` |`KC_KANA` |JIS Katakana/Hiragana |
|
||||
|`KC_INT3` |`KC_JYEN` |JIS `¥` |
|
||||
|`KC_INT4` |`KC_HENK` |JIS Henkan |
|
||||
|`KC_INT5` |`KC_MHEN` |JIS Muhenkan |
|
||||
|`KC_INT6` | |JIS Numpad `,` |
|
||||
|`KC_INT7` | |International 7 |
|
||||
|`KC_INT8` | |International 8 |
|
||||
|`KC_INT9` | |International 9 |
|
||||
|`KC_LANG1` |`KC_HAEN` |Hangul/English |
|
||||
|`KC_LANG2` |`KC_HANJ` |Hanja |
|
||||
|`KC_LANG3` | |JIS Katakana |
|
||||
|`KC_LANG4` | |JIS Hiragana |
|
||||
|`KC_LANG5` | |JIS Zenkaku/Hankaku |
|
||||
|`KC_LANG6` | |Language 6 |
|
||||
|`KC_LANG7` | |Language 7 |
|
||||
|`KC_LANG8` | |Language 8 |
|
||||
|`KC_LANG9` | |Language 9 |
|
||||
|`KC_ALT_ERASE` |`KC_ERAS` |Alternate Erase |
|
||||
|`KC_SYSREQ` | |SysReq/Attention |
|
||||
|`KC_CANCEL` | |Cancel |
|
||||
|`KC_CLEAR` |`KC_CLR` |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_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_SYSTEM_POWER` |`KC_PWR` |System Power Down |
|
||||
|`KC_SYSTEM_SLEEP` |`KC_SLEP` |System Sleep |
|
||||
|`KC_SYSTEM_WAKE` |`KC_WAKE` |System Wake |
|
||||
|`KC_AUDIO_MUTE` |`KC_MUTE` |Mute |
|
||||
|`KC_AUDIO_VOL_UP` |`KC_VOLU` |Volume Up |
|
||||
|`KC_AUDIO_VOL_DOWN` |`KC_VOLD` |Volume Down |
|
||||
|`KC_MEDIA_NEXT_TRACK` |`KC_MNXT` |Next Track (Windows) |
|
||||
|`KC_MEDIA_PREV_TRACK` |`KC_MPRV` |Previous Track (Windows) |
|
||||
|`KC_MEDIA_STOP` |`KC_MSTP` |Stop Track (Windows) |
|
||||
|`KC_MEDIA_PLAY_PAUSE` |`KC_MPLY` |Play/Pause Track |
|
||||
|`KC_MEDIA_SELECT` |`KC_MSEL` |Launch Media Player (Windows) |
|
||||
|`KC_MEDIA_EJECT` |`KC_EJCT` |Eject (macOS) |
|
||||
|`KC_MAIL` | |Launch Mail (Windows) |
|
||||
|`KC_CALCULATOR` |`KC_CALC` |Launch Calculator (Windows) |
|
||||
|`KC_MY_COMPUTER` |`KC_MYCM` |Launch My Computer (Windows) |
|
||||
|`KC_WWW_SEARCH` |`KC_WSCH` |Browser Search (Windows) |
|
||||
|`KC_WWW_HOME` |`KC_WHOM` |Browser Home (Windows) |
|
||||
|`KC_WWW_BACK` |`KC_WBAK` |Browser Back (Windows) |
|
||||
|`KC_WWW_FORWARD` |`KC_WFWD` |Browser Forward (Windows) |
|
||||
|`KC_WWW_STOP` |`KC_WSTP` |Browser Stop (Windows) |
|
||||
|`KC_WWW_REFRESH` |`KC_WREF` |Browser Refresh (Windows) |
|
||||
|`KC_WWW_FAVORITES` |`KC_WFAV` |Browser Favorites (Windows) |
|
||||
|`KC_MEDIA_FAST_FORWARD`|`KC_MFFD` |Next Track (macOS) |
|
||||
|`KC_MEDIA_REWIND` |`KC_MRWD` |Previous Track (macOS) |
|
||||
|
||||
## [Quantum Keycodes](quantum_keycodes.md#qmk-keycodes)
|
||||
|
||||
@@ -269,7 +282,7 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|`OUT_BT` |Bluetooth only |
|
||||
|
||||
|
||||
## [Layer Switching](feature_advanced_keycodes.md# Switching and Toggling Layers)
|
||||
## [Layer Switching](feature_advanced_keycodes.md#switching-and-toggling-layers)
|
||||
|
||||
|Key |Description |
|
||||
|-----------------|---------------------------------------------------------------------|
|
||||
@@ -391,29 +404,29 @@ This is a reference only. Each group of keys links to the page documenting their
|
||||
|
||||
## [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>|</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` |`?` |
|
||||
|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>|</code>|
|
||||
|`KC_COLON` |`KC_COLN` |`:` |
|
||||
|`KC_DOUBLE_QUOTE` |`KC_DQUO`, `KC_DQT`|`"` |
|
||||
|`KC_LEFT_ANGLE_BRACKET` |`KC_LABK`, `KC_LT` |`<` |
|
||||
|`KC_RIGHT_ANGLE_BRACKET`|`KC_RABK`, `KC_GT` |`>` |
|
||||
|`KC_QUESTION` |`KC_QUES` |`?` |
|
||||
|
||||
## [Switching and Toggling Layers](feature_advanced_keycodes.md#switching-and-toggling-layers)
|
||||
|
||||
|
@@ -47,117 +47,145 @@ The basic set of keycodes are based on the [HID Keyboard/Keypad Usage Page (0x07
|
||||
|
||||
|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`| |
|
||||
|`KC_F1` |F1 |
|
||||
|`KC_F2` |F2 |
|
||||
|`KC_F3` |F3 |
|
||||
|`KC_F4` |F4 |
|
||||
|`KC_F5` |F5 |
|
||||
|`KC_F6` |F6 |
|
||||
|`KC_F7` |F7 |
|
||||
|`KC_F8` |F8 |
|
||||
|`KC_F9` |F9 |
|
||||
|`KC_F10`|F10 |
|
||||
|`KC_F11`|F11 |
|
||||
|`KC_F12`|F12 |
|
||||
|`KC_F13`|F13 |
|
||||
|`KC_F14`|F14 |
|
||||
|`KC_F15`|F15 |
|
||||
|`KC_F16`|F16 |
|
||||
|`KC_F17`|F17 |
|
||||
|`KC_F18`|F18 |
|
||||
|`KC_F19`|F19 |
|
||||
|`KC_F20`|F20 |
|
||||
|`KC_F21`|F21 |
|
||||
|`KC_F22`|F22 |
|
||||
|`KC_F23`|F23 |
|
||||
|`KC_F24`|F24 |
|
||||
|
||||
## Punctuation
|
||||
|
||||
|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>|</code> |
|
||||
|`KC_NONUS_HASH` |`KC_NUHS`|Non-US `#` and `~` |
|
||||
|`KC_NONUS_BSLASH`|`KC_NUBS`|Non-US `\` and <code>|</code>|
|
||||
|`KC_INT1` |`KC_RO` |JIS `\` and <code>|</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>`</code> and `~` |
|
||||
|`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>|</code> |
|
||||
|`KC_NONUS_HASH` |`KC_NUHS` |Non-US `#` and `~` |
|
||||
|`KC_SCOLON` |`KC_SCLN` |`;` and `:` |
|
||||
|`KC_QUOTE` |`KC_QUOT` |`'` and `"` |
|
||||
|`KC_GRAVE` |`KC_GRV`, `KC_ZKHK`|<code>`</code> and `~`, JIS Zenkaku/Hankaku|
|
||||
|`KC_COMMA` |`KC_COMM` |`,` and `<` |
|
||||
|`KC_DOT` | |`.` and `>` |
|
||||
|`KC_SLASH` |`KC_SLSH` |`/` and `?` |
|
||||
|`KC_NONUS_BSLASH`|`KC_NUBS` |Non-US `\` and <code>|</code> |
|
||||
|
||||
## Lock Keys
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|-------------------|--------------------|-------------------------|
|
||||
|`KC_CAPSLOCK` |`KC_CLCK`, `KC_CAPS`|Caps Lock |
|
||||
|`KC_SCROLLLOCK` |`KC_SLCK` |Scroll Lock |
|
||||
|`KC_NUMLOCK` |`KC_NLCK` |Keypad Num Lock and Clear|
|
||||
|`KC_LOCKING_CAPS` |`KC_LCAP` |Locking Caps Lock |
|
||||
|`KC_LOCKING_NUM` |`KC_LNUM` |Locking Num Lock |
|
||||
|`KC_LOCKING_SCROLL`|`KC_LSCR` |Locking Scroll Lock |
|
||||
|
||||
## Modifiers
|
||||
|
||||
|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 |
|
||||
|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)|
|
||||
|
||||
## International
|
||||
|
||||
|Key |Aliases |Description |
|
||||
|----------|---------|-------------------------------|
|
||||
|`KC_INT1` |`KC_RO` |JIS `\` and <code>|</code>|
|
||||
|`KC_INT2` |`KC_KANA`|JIS Katakana/Hiragana |
|
||||
|`KC_INT3` |`KC_JYEN`|JIS `¥` |
|
||||
|`KC_INT4` |`KC_HENK`|JIS Henkan |
|
||||
|`KC_INT5` |`KC_MHEN`|JIS Muhenkan |
|
||||
|`KC_INT6` | |JIS Numpad `,` |
|
||||
|`KC_INT7` | |International 7 |
|
||||
|`KC_INT8` | |International 8 |
|
||||
|`KC_INT9` | |International 9 |
|
||||
|`KC_LANG1`|`KC_HAEN`|Hangul/English |
|
||||
|`KC_LANG2`|`KC_HANJ`|Hanja |
|
||||
|`KC_LANG3`| |JIS Katakana |
|
||||
|`KC_LANG4`| |JIS Hiragana |
|
||||
|`KC_LANG5`| |JIS Zenkaku/Hankaku |
|
||||
|`KC_LANG6`| |Language 6 |
|
||||
|`KC_LANG7`| |Language 7 |
|
||||
|`KC_LANG8`| |Language 8 |
|
||||
|`KC_LANG9`| |Language 9 |
|
||||
|
||||
## Commands
|
||||
|
||||
|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 |
|
||||
|Key |Aliases |Description |
|
||||
|------------------|-------------------|------------------------------|
|
||||
|`KC_PSCREEN` |`KC_PSCR` |Print Screen |
|
||||
|`KC_PAUSE` |`KC_PAUS`, `KC_BRK`|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` | |System Power (macOS/Linux) |
|
||||
|`KC_EXECUTE` |`KC_EXEC` |Execute |
|
||||
|`KC_HELP` | |Help |
|
||||
|`KC_MENU` | |Menu |
|
||||
|`KC_SELECT` |`KC_SLCT` |Select |
|
||||
|`KC_STOP` | |Stop |
|
||||
|`KC_AGAIN` |`KC_AGIN` |Again |
|
||||
|`KC_UNDO` | |Undo |
|
||||
|`KC_CUT` | |Cut |
|
||||
|`KC_COPY` | |Copy |
|
||||
|`KC_PASTE` |`KC_PSTE` |Paste |
|
||||
|`KC_FIND` | |Find |
|
||||
|`KC__MUTE` | |Mute (macOS) |
|
||||
|`KC__VOLUP` | |Volume Up (macOS) |
|
||||
|`KC__VOLDOWN` | |Volume Down (macOS) |
|
||||
|`KC_ALT_ERASE` |`KC_ERAS` |Alternate Erase |
|
||||
|`KC_SYSREQ` | |SysReq/Attention |
|
||||
|`KC_CANCEL` | |Cancel |
|
||||
|`KC_CLEAR` |`KC_CLR` |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
|
||||
|
||||
@@ -165,42 +193,37 @@ These keycodes are not part of the Keyboard/Keypad usage page. The `SYSTEM_` key
|
||||
|
||||
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`| |
|
||||
|`KC_MEDIA_EJECT` |`KC_EJCT`|Eject (macOS) |
|
||||
|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_AUDIO_MUTE` |`KC_MUTE`|Mute |
|
||||
|`KC_AUDIO_VOL_UP` |`KC_VOLU`|Volume Up |
|
||||
|`KC_AUDIO_VOL_DOWN` |`KC_VOLD`|Volume Down |
|
||||
|`KC_MEDIA_NEXT_TRACK` |`KC_MNXT`|Next Track (Windows) |
|
||||
|`KC_MEDIA_PREV_TRACK` |`KC_MPRV`|Previous Track (Windows) |
|
||||
|`KC_MEDIA_STOP` |`KC_MSTP`|Stop Track (Windows) |
|
||||
|`KC_MEDIA_PLAY_PAUSE` |`KC_MPLY`|Play/Pause Track |
|
||||
|`KC_MEDIA_SELECT` |`KC_MSEL`|Launch Media Player (Windows)|
|
||||
|`KC_MEDIA_EJECT` |`KC_EJCT`|Eject (macOS) |
|
||||
|`KC_MAIL` | |Launch Mail (Windows) |
|
||||
|`KC_CALCULATOR` |`KC_CALC`|Launch Calculator (Windows) |
|
||||
|`KC_MY_COMPUTER` |`KC_MYCM`|Launch My Computer (Windows) |
|
||||
|`KC_WWW_SEARCH` |`KC_WSCH`|Browser Search (Windows) |
|
||||
|`KC_WWW_HOME` |`KC_WHOM`|Browser Home (Windows) |
|
||||
|`KC_WWW_BACK` |`KC_WBAK`|Browser Back (Windows) |
|
||||
|`KC_WWW_FORWARD` |`KC_WFWD`|Browser Forward (Windows) |
|
||||
|`KC_WWW_STOP` |`KC_WSTP`|Browser Stop (Windows) |
|
||||
|`KC_WWW_REFRESH` |`KC_WREF`|Browser Refresh (Windows) |
|
||||
|`KC_WWW_FAVORITES` |`KC_WFAV`|Browser Favorites (Windows) |
|
||||
|`KC_MEDIA_FAST_FORWARD`|`KC_MFFD`|Next Track (macOS) |
|
||||
|`KC_MEDIA_REWIND` |`KC_MRWD`|Previous Track (macOS) |
|
||||
|
||||
## 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 `-` |
|
||||
@@ -225,7 +248,7 @@ Windows and macOS use different keycodes for "next track" and "previous track".
|
||||
|
||||
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|
|
||||
|Key |Aliases |Description |
|
||||
|----------------|--------------------|---------------------------------------|
|
||||
|`KC_NO` |`XXXXXXX` |Ignore this key (NOOP) |
|
||||
|`KC_TRANSPARENT`|`KC_TRNS`, `_______`|Use the next lowest non-transparent key|
|
||||
|
@@ -6,26 +6,26 @@ It's important to remember that all of these keycodes send a left shift - this m
|
||||
|
||||
## US ANSI Shifted Keycodes
|
||||
|
||||
|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>|</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` |`?` |
|
||||
|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>|</code>|
|
||||
|`KC_COLON` |`KC_COLN` |`:` |
|
||||
|`KC_DOUBLE_QUOTE` |`KC_DQUO`, `KC_DQT`|`"` |
|
||||
|`KC_LEFT_ANGLE_BRACKET` |`KC_LABK`, `KC_LT` |`<` |
|
||||
|`KC_RIGHT_ANGLE_BRACKET`|`KC_RABK`, `KC_GT` |`>` |
|
||||
|`KC_QUESTION` |`KC_QUES` |`?` |
|
||||
|
@@ -34,7 +34,7 @@
|
||||
},
|
||||
{
|
||||
"from": "space_cadet_shift.html",
|
||||
"to": "feature_space_cadet.html"
|
||||
"to": "feature_space_cadet_shift.html"
|
||||
},
|
||||
{
|
||||
"from": "tap_dance.html",
|
||||
|
@@ -133,7 +133,7 @@ A 1 byte number that is sent as part of a HID report over USB that represents a
|
||||
## 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)
|
||||
* [Space Cadet Shift Documentation](feature_space_cadet_shift.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.
|
||||
|
@@ -4,7 +4,7 @@ Firmware for custom keyboard PCB with 60% key layout.
|
||||
|
||||
Keyboard Maintainer: [rempired](https://github.com/rempired)
|
||||
Hardware Supported: 1upkeyboards 60% RGB
|
||||
Hardware Availability: [1upkeyboards](https://1upkeyboards.com/rgb-underglow-1up-pcb.html)
|
||||
Hardware Availability: [1upkeyboards](https://www.1upkeyboards.com/shop/controllers/1up-rgb-underglow-pcb/)
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
|
29
keyboards/4x4/4x4.c
Normal file
29
keyboards/4x4/4x4.c
Normal file
@@ -0,0 +1,29 @@
|
||||
|
||||
#include "4x4.h"
|
||||
|
||||
void matrix_init_kb(void) {
|
||||
// put your keyboard start-up code here
|
||||
// runs once when the firmware starts up
|
||||
|
||||
matrix_init_user();
|
||||
}
|
||||
|
||||
void matrix_scan_kb(void) {
|
||||
// put your looping keyboard code here
|
||||
// runs every cycle (a lot)
|
||||
|
||||
matrix_scan_user();
|
||||
}
|
||||
|
||||
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
|
||||
// put your per-action keyboard code here
|
||||
// runs for every action, just before processing by the firmware
|
||||
|
||||
return process_record_user(keycode, record);
|
||||
}
|
||||
|
||||
void led_set_kb(uint8_t usb_led) {
|
||||
// put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
|
||||
|
||||
led_set_user(usb_led);
|
||||
}
|
62
keyboards/4x4/4x4.h
Normal file
62
keyboards/4x4/4x4.h
Normal file
@@ -0,0 +1,62 @@
|
||||
|
||||
#ifndef FOURX4_H
|
||||
#define FOURX4_H
|
||||
|
||||
#include "quantum.h"
|
||||
#define ___ KC_NO
|
||||
|
||||
// This a shortcut to help you visually see your layout.
|
||||
// The first section contains all of the arguments
|
||||
// The second converts the arguments into a two-dimensional array
|
||||
|
||||
#define LAYOUT_ortho_4x4( \
|
||||
K00, K01, K02, K03, \
|
||||
K10, K11, K12, K13, \
|
||||
K20, K21, K22, K23, \
|
||||
K30, K31, K32, K33 \
|
||||
) \
|
||||
{ \
|
||||
{ K00, K01, K02, K03, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___}, \
|
||||
{ K10, K11, K12, K13, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___}, \
|
||||
{ K20, K21, K22, K23, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___}, \
|
||||
{ K30, K31, K32, K33, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___, ___} \
|
||||
}
|
||||
#define LAYOUT_ortho_4x8( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, \
|
||||
K30, K31, K32, K33, K34, K35, K36, K37\
|
||||
) \
|
||||
{ \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, ___, ___, ___, ___, ___, ___, ___, ___}, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, ___, ___, ___, ___, ___, ___, ___, ___}, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, ___, ___, ___, ___, ___, ___, ___, ___}, \
|
||||
{ K30, K31, K32, K33, K34, K35, K35, K37, ___, ___, ___, ___, ___, ___, ___, ___} \
|
||||
}
|
||||
#define LAYOUT_ortho_4x12( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0a, K0b, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1a, K1b, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2a, K2b, \
|
||||
K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3a, K3b \
|
||||
) \
|
||||
{ \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0a, K0b, ___, ___, ___, ___}, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1a, K1b, ___, ___, ___, ___}, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2a, K2b, ___, ___, ___, ___}, \
|
||||
{ K30, K31, K32, K33, K34, K35, K35, K37, K38, K39, K3a, K3b, ___, ___, ___, ___} \
|
||||
}
|
||||
|
||||
#define LAYOUT_ortho_4x16( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0a, K0b, K0c, K0d, K0e, K0f, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1a, K1b, K1c, K1d, K1e, K1f, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2a, K2b, K2c, K2d, K2e, K2f, \
|
||||
K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3a, K3b, K3c, K3d, K3e, K3f \
|
||||
) \
|
||||
{ \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0a, K0b, K0c, K0d, K0e, K0f }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1a, K1b, K1c, K1d, K1e, K1f }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2a, K2b, K2c, K2d, K2e, K2f }, \
|
||||
{ K30, K31, K32, K33, K34, K35, K35, K37, K38, K39, K3a, K3b, K3c, K3d, K3e, K3f } \
|
||||
}
|
||||
|
||||
#endif
|
202
keyboards/4x4/config.h
Normal file
202
keyboards/4x4/config.h
Normal file
@@ -0,0 +1,202 @@
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "config_common.h"
|
||||
|
||||
/* USB Device descriptor parameter */
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x0A0C
|
||||
#define DEVICE_VER 0x4444
|
||||
#define MANUFACTURER di0ib
|
||||
#define PRODUCT The 4x4 Keyboard
|
||||
#define DESCRIPTION A modular compact keyboard
|
||||
|
||||
/* key matrix size */
|
||||
#define MATRIX_ROWS 4
|
||||
#define MATRIX_COLS 16
|
||||
|
||||
/*
|
||||
* Keyboard Matrix Assignments
|
||||
*
|
||||
* Change this to how you wired your keyboard
|
||||
* COLS: AVR pins used for columns, left to right
|
||||
* ROWS: AVR pins used for rows, top to bottom
|
||||
* DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
|
||||
* ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
|
||||
*
|
||||
*/
|
||||
#define MATRIX_ROW_PINS { B2, D1, D0, D4 }
|
||||
#define MATRIX_COL_PINS { C6, D7, E6, B4, B5, B6, B7, D6, F7, F6, F5, F4, F1, F0, B3, B1 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
|
||||
/* COL2ROW, ROW2COL, or CUSTOM_MATRIX */
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
// #define BACKLIGHT_PIN C7
|
||||
// #define BACKLIGHT_BREATHING
|
||||
// #define BACKLIGHT_LEVELS 3
|
||||
|
||||
|
||||
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
|
||||
#define DEBOUNCING_DELAY 5
|
||||
|
||||
/* define if matrix has ghost (lacks anti-ghosting diodes) */
|
||||
//#define MATRIX_HAS_GHOST
|
||||
|
||||
/* number of backlight levels */
|
||||
|
||||
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
/* Locking resynchronize hack */
|
||||
#define LOCKING_RESYNC_ENABLE
|
||||
|
||||
/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
|
||||
* This is userful for the Windows task manager shortcut (ctrl+shift+esc).
|
||||
*/
|
||||
// #define GRAVE_ESC_CTRL_OVERRIDE
|
||||
|
||||
/*
|
||||
* Force NKRO
|
||||
*
|
||||
* Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
|
||||
* state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
|
||||
* makefile for this to work.)
|
||||
*
|
||||
* If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
|
||||
* until the next keyboard reset.
|
||||
*
|
||||
* NKRO may prevent your keystrokes from being detected in the BIOS, but it is
|
||||
* fully operational during normal computer usage.
|
||||
*
|
||||
* For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
|
||||
* or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
|
||||
* bootmagic, NKRO mode will always be enabled until it is toggled again during a
|
||||
* power-up.
|
||||
*
|
||||
*/
|
||||
//#define FORCE_NKRO
|
||||
|
||||
/*
|
||||
* Magic Key Options
|
||||
*
|
||||
* Magic keys are hotkey commands that allow control over firmware functions of
|
||||
* the keyboard. They are best used in combination with the HID Listen program,
|
||||
* found here: https://www.pjrc.com/teensy/hid_listen.html
|
||||
*
|
||||
* The options below allow the magic key functionality to be changed. This is
|
||||
* useful if your keyboard/keypad is missing keys and you want magic key support.
|
||||
*
|
||||
*/
|
||||
|
||||
/* key combination for magic key command */
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
|
||||
)
|
||||
|
||||
/* control how magic key switches layers */
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS true
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS true
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM false
|
||||
|
||||
/* override magic key keymap */
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS
|
||||
//#define MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM
|
||||
//#define MAGIC_KEY_HELP1 H
|
||||
//#define MAGIC_KEY_HELP2 SLASH
|
||||
//#define MAGIC_KEY_DEBUG D
|
||||
//#define MAGIC_KEY_DEBUG_MATRIX X
|
||||
//#define MAGIC_KEY_DEBUG_KBD K
|
||||
//#define MAGIC_KEY_DEBUG_MOUSE M
|
||||
//#define MAGIC_KEY_VERSION V
|
||||
//#define MAGIC_KEY_STATUS S
|
||||
//#define MAGIC_KEY_CONSOLE C
|
||||
//#define MAGIC_KEY_LAYER0_ALT1 ESC
|
||||
//#define MAGIC_KEY_LAYER0_ALT2 GRAVE
|
||||
//#define MAGIC_KEY_LAYER0 0
|
||||
//#define MAGIC_KEY_LAYER1 1
|
||||
//#define MAGIC_KEY_LAYER2 2
|
||||
//#define MAGIC_KEY_LAYER3 3
|
||||
//#define MAGIC_KEY_LAYER4 4
|
||||
//#define MAGIC_KEY_LAYER5 5
|
||||
//#define MAGIC_KEY_LAYER6 6
|
||||
//#define MAGIC_KEY_LAYER7 7
|
||||
//#define MAGIC_KEY_LAYER8 8
|
||||
//#define MAGIC_KEY_LAYER9 9
|
||||
//#define MAGIC_KEY_BOOTLOADER PAUSE
|
||||
//#define MAGIC_KEY_LOCK CAPS
|
||||
//#define MAGIC_KEY_EEPROM E
|
||||
//#define MAGIC_KEY_NKRO N
|
||||
//#define MAGIC_KEY_SLEEP_LED Z
|
||||
|
||||
/*
|
||||
* Feature disable options
|
||||
* These options are also useful to firmware size reduction.
|
||||
*/
|
||||
|
||||
/* disable debug print */
|
||||
//#define NO_DEBUG
|
||||
|
||||
/* disable print */
|
||||
//#define NO_PRINT
|
||||
|
||||
/* disable action features */
|
||||
//#define NO_ACTION_LAYER
|
||||
//#define NO_ACTION_TAPPING
|
||||
//#define NO_ACTION_ONESHOT
|
||||
//#define NO_ACTION_MACRO
|
||||
//#define NO_ACTION_FUNCTION
|
||||
|
||||
/*
|
||||
* MIDI options
|
||||
*/
|
||||
|
||||
/* Prevent use of disabled MIDI features in the keymap */
|
||||
//#define MIDI_ENABLE_STRICT 1
|
||||
|
||||
/* enable basic MIDI features:
|
||||
- MIDI notes can be sent when in Music mode is on
|
||||
*/
|
||||
//#define MIDI_BASIC
|
||||
|
||||
/* enable advanced MIDI features:
|
||||
- MIDI notes can be added to the keymap
|
||||
- Octave shift and transpose
|
||||
- Virtual sustain, portamento, and modulation wheel
|
||||
- etc.
|
||||
*/
|
||||
//#define MIDI_ADVANCED
|
||||
|
||||
/* override number of MIDI tone keycodes (each octave adds 12 keycodes and allocates 12 bytes) */
|
||||
//#define MIDI_TONE_KEYCODE_OCTAVES 1
|
||||
|
||||
/*
|
||||
* HD44780 LCD Display Configuration
|
||||
*/
|
||||
/*
|
||||
#define LCD_LINES 2 //< number of visible lines of the display
|
||||
#define LCD_DISP_LENGTH 16 //< visibles characters per line of the display
|
||||
|
||||
#define LCD_IO_MODE 1 //< 0: memory mapped mode, 1: IO port mode
|
||||
|
||||
#if LCD_IO_MODE
|
||||
#define LCD_PORT PORTB //< port for the LCD lines
|
||||
#define LCD_DATA0_PORT LCD_PORT //< port for 4bit data bit 0
|
||||
#define LCD_DATA1_PORT LCD_PORT //< port for 4bit data bit 1
|
||||
#define LCD_DATA2_PORT LCD_PORT //< port for 4bit data bit 2
|
||||
#define LCD_DATA3_PORT LCD_PORT //< port for 4bit data bit 3
|
||||
#define LCD_DATA0_PIN 4 //< pin for 4bit data bit 0
|
||||
#define LCD_DATA1_PIN 5 //< pin for 4bit data bit 1
|
||||
#define LCD_DATA2_PIN 6 //< pin for 4bit data bit 2
|
||||
#define LCD_DATA3_PIN 7 //< pin for 4bit data bit 3
|
||||
#define LCD_RS_PORT LCD_PORT //< port for RS line
|
||||
#define LCD_RS_PIN 3 //< pin for RS line
|
||||
#define LCD_RW_PORT LCD_PORT //< port for RW line
|
||||
#define LCD_RW_PIN 2 //< pin for RW line
|
||||
#define LCD_E_PORT LCD_PORT //< port for Enable line
|
||||
#define LCD_E_PIN 1 //< pin for Enable line
|
||||
#endif
|
||||
*/
|
||||
|
5
keyboards/4x4/keymaps/default/config.h
Normal file
5
keyboards/4x4/keymaps/default/config.h
Normal file
@@ -0,0 +1,5 @@
|
||||
|
||||
|
||||
#pragma once
|
||||
|
||||
// place overrides here
|
124
keyboards/4x4/keymaps/default/keymap.c
Normal file
124
keyboards/4x4/keymaps/default/keymap.c
Normal file
@@ -0,0 +1,124 @@
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
#define PAD 0
|
||||
#define _QW 1
|
||||
#define NUM 2
|
||||
#define DIR 3
|
||||
|
||||
// Readability keycodes
|
||||
#define _______ KC_TRNS
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
/* Single 4x4 board only
|
||||
* .-----------------------------------.
|
||||
* | 7 | 8 | 9 | / |
|
||||
* |--------+--------+--------+--------|
|
||||
* | 4 | 5 | 6 | * |
|
||||
* |--------+--------+--------+--------|
|
||||
* | 1 | 2 | 3 | - |
|
||||
* |--------+--------+--------+--------|
|
||||
* | 0 | QWERTY | . | + |
|
||||
* '-----------------------------------'
|
||||
*/
|
||||
|
||||
[PAD] = LAYOUT_ortho_4x4(
|
||||
KC_KP_7, KC_KP_8, KC_KP_9, KC_PSLS,
|
||||
KC_KP_4, KC_KP_5, KC_KP_6, KC_PAST,
|
||||
KC_KP_1, KC_KP_2, KC_KP_3, KC_PMNS,
|
||||
KC_KP_0, DF(_QW), KC_KP_DOT, KC_PPLS
|
||||
),
|
||||
|
||||
/* QWERTY
|
||||
* .-----------------------------------------------------------------------------------------------------------------------------------------------.
|
||||
* | ESC | Q | W | E | R | T | Y | U | I | O | P | BACKSP | 7 | 8 | 9 | / |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | TAB | A | S | D | F | G | H | J | K | L | ; | ' | 4 | 5 | 6 | * |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | SHIFT | Z | X | C | V | B | N | M | , | . | / | ENT/SFT| 1 | 2 | 3 | - |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | LCTRL | LGUI | ALT | ALT | NUM | SHIFT | SPACE | DIR | RGUI | RALT | DEL | CTRL | 0 | 0 | . | + |
|
||||
* '-----------------------------------------------------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
|
||||
[_QW] = LAYOUT_ortho_4x16(
|
||||
KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, KC_KP_7, KC_KP_8, KC_KP_9, KC_PSLS,
|
||||
KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_KP_4, KC_KP_5, KC_KP_6, KC_PAST,
|
||||
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, SFT_T(KC_ENT), KC_KP_1, KC_KP_2, KC_KP_3, KC_PMNS,
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_LALT, MO(NUM), KC_LSFT, KC_SPC, MO(DIR), KC_RGUI, KC_RALT, KC_DEL, KC_RCTL, KC_KP_0, KC_KP_0, KC_KP_DOT, KC_PPLS
|
||||
),
|
||||
|
||||
/* NUMBERS
|
||||
* .-----------------------------------------------------------------------------------------------------------------------------------------------.
|
||||
* | | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | NUMLOCK| / | * | - | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | | | | + | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | | F11 | F12 | | | | ENTER | SHIFT | RGUI | ./ALT | BKSC | | | | ENTER | |
|
||||
* | | | | | | | | | | |CTRLhold| | | | | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------| |
|
||||
* | | | | | | | ENTER | SHIFT | | | | | | | | |
|
||||
* '-----------------------------------------------------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
|
||||
[NUM] = LAYOUT_ortho_4x16(
|
||||
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, _______,
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, _______, _______, _______, KC_PPLS, _______,
|
||||
_______, KC_F11, KC_F12, KC_TRNS, KC_TRNS, KC_TRNS, KC_ENT, KC_RSFT, KC_RGUI, ALT_T(KC_DOT), CTL_T(KC_BSPC), _______, _______, _______, KC_PENT, _______,
|
||||
_______, _______, _______, _______, _______, _______, KC_ENT, KC_RSFT, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
/* DIRECTIONS
|
||||
* .-----------------------------------------------------------------------------------------------------------------------------------------------.
|
||||
* | RESET | TAB | up | | INS | CTRL | SHIFT | PgUp | Home | - | = | DEL | | | | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | CAPSLK | left | down | right | PrScr | SHIFT | CTRL | PgDn | End | [ | ] | \ | | | | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | | P-Brk | | | | | | | RGUI | ALT | | | | | | |
|
||||
* |--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------+--------|
|
||||
* | KEYPAD | | | | | | | | | | | | | | | |
|
||||
* '-----------------------------------------------------------------------------------------------------------------------------------------------'
|
||||
*/
|
||||
|
||||
[DIR] = LAYOUT_ortho_4x16(
|
||||
RESET, KC_TAB, KC_UP, _______, KC_INS, KC_LCTL, KC_LSFT, KC_PGUP, KC_HOME, KC_MINS, KC_EQL, KC_DEL, _______, _______, _______, _______,
|
||||
KC_CAPS, KC_LEFT, KC_DOWN, KC_RGHT, KC_PSCR, KC_LSFT, KC_LCTL, KC_PGDN, KC_END, KC_LBRC, KC_RBRC, KC_BSLS, _______, _______, _______, _______,
|
||||
_______, KC_PAUS, _______, _______, _______, _______, _______, _______, KC_RGUI, KC_RALT, _______, _______, _______, _______, _______, _______,
|
||||
DF(PAD), _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
|
||||
};
|
||||
|
||||
|
||||
const uint16_t PROGMEM fn_actions[] = {
|
||||
|
||||
};
|
||||
|
||||
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) {
|
||||
keyevent_t event = record->event;
|
||||
(void)event;
|
||||
|
||||
switch (id) {
|
||||
|
||||
}
|
||||
return MACRO_NONE;
|
||||
}
|
||||
|
||||
|
||||
void matrix_init_user(void) {
|
||||
|
||||
}
|
||||
|
||||
void matrix_scan_user(void) {
|
||||
|
||||
}
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
return true;
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led) {
|
||||
|
||||
}
|
23
keyboards/4x4/readme.md
Normal file
23
keyboards/4x4/readme.md
Normal file
@@ -0,0 +1,23 @@
|
||||
# 4x4
|
||||
|
||||

|
||||
===
|
||||
|
||||
**Modular keypad/keyboard**
|
||||
The basic unit is a 4x4 matrix with 16 keys. Up to 4 of these can be connected to each other side by side.
|
||||
4x4, 4x8, 4x12 and 4x16 are possible.
|
||||
There are pads for header pins on each side that complete the circuits from board to board. These can be permanently connected with solder bridges or temporarily with pin headers and shunt jumpers.
|
||||
**_All configurations are powered by a SINGLE Arduino Micro or clone (NOT a Pro Micro)._**
|
||||
|
||||
* [The original TMK firmware](https://github.com/di0ib/tmk_keyboard/tree/master/keyboard/4x4)
|
||||
|
||||
Keyboard Maintainer: QMK Community
|
||||
Hardware Supported: 4x4 PCB
|
||||
Hardware Availability: [4x4x4x4x4 project on 40% Keyboards](http://www.40percent.club/2018/01/4x4x4x4x4.html)
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make 4x4:default
|
||||
|
||||
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
|
||||
First pass at adding support for the 4x4 keyboard. Compiles but completely untested. Intended to kick-start development.
|
74
keyboards/4x4/rules.mk
Normal file
74
keyboards/4x4/rules.mk
Normal file
@@ -0,0 +1,74 @@
|
||||
# MCU name
|
||||
#MCU = at90usb1286
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Boot Section Size in *bytes*
|
||||
# Teensy halfKay 512
|
||||
# Teensy++ halfKay 1024
|
||||
# Atmel DFU loader 4096
|
||||
# LUFA bootloader 4096
|
||||
# USBaspLoader 2048
|
||||
OPT_DEFS += -DBOOTLOADER_SIZE=4096
|
||||
|
||||
# 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
|
||||
|
||||
# Build Options
|
||||
# change yes to no to disable
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = yes # Console for debug(+400)
|
||||
COMMAND_ENABLE = yes # Commands for debug and configuration
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
NKRO_ENABLE = no # USB Nkey Rollover
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
|
||||
MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
|
||||
LAYOUT = ortho_4x4 ortho_4x8 ortho_4x12 ortho_4x16
|
@@ -5,15 +5,9 @@
|
||||
#define BASE 0
|
||||
#define KEYNAV 1
|
||||
#define KEYSEL 2
|
||||
#define MOUSE 3
|
||||
#define COMBINED 4
|
||||
#define BROWSER_CONTROL 5
|
||||
#define COMBINED 3
|
||||
#define BROWSER_CONTROL 4
|
||||
|
||||
// macros
|
||||
#define MOUSE_TOGGLE 1
|
||||
#define MOUSE_LOCK 2
|
||||
|
||||
static bool mouse_lock = false;
|
||||
|
||||
enum custom_keycodes {
|
||||
PLACEHOLDER = SAFE_RANGE, // can always be here
|
||||
@@ -63,18 +57,11 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_TRNS, KC_TILD, KC_GRAVE, KC_CIRC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_0, KC_DOT, KC_PIPE, KC_BSLS
|
||||
),
|
||||
|
||||
[MOUSE] = LAYOUT(
|
||||
KC_TRNS, KC_PGUP, KC_MS_WH_UP, KC_UP, KC_TRNS, KC_UP, KC_HOME, KC_MS_U, KC_END, KC_MS_WH_UP,
|
||||
KC_MS_ACCEL0, KC_PGDN, KC_MS_WH_DOWN, KC_DOWN, KC_TRNS, KC_DOWN, KC_MS_L, KC_MS_D, KC_MS_R, KC_MS_WH_DOWN,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, MEH(KC_X), MEH(KC_Y), MEH(KC_Z), KC_F5, RCTL(KC_W),
|
||||
KC_TRNS, M(MOUSE_LOCK), KC_TRNS, KC_MS_ACCEL0, KC_TRNS, KC_BTN3, KC_BTN1, KC_BTN2, RSFT(RCTL(KC_TAB)), RCTL(KC_TAB), RCTL(KC_T), LALT(KC_LEFT)
|
||||
),
|
||||
|
||||
[BROWSER_CONTROL] = LAYOUT(
|
||||
KC_TRNS, KC_BTN3, KC_MS_U, KC_BTN1, KC_BTN2, KC_UP, KC_PGUP, KC_PGDN, KC_MS_WH_UP, KC_TRNS,
|
||||
KC_TRNS, KC_MS_L, KC_MS_D, KC_MS_R, KC_TRNS, KC_DOWN, RSFT(RCTL(KC_TAB)), RCTL(KC_TAB), KC_MS_WH_DOWN, LALT(KC_LEFT),
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RCTL(KC_1), RCTL(KC_9), KC_F6, KC_F5,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RCTL(KC_W), RCTL(KC_T), RSFT(RCTL(KC_TAB)), KC_TRNS, KC_TRNS, KC_TRNS
|
||||
MEH(KC_0), KC_BTN3, KC_MS_U, KC_BTN1, KC_BTN2, KC_UP, KC_PGUP, KC_PGDN, KC_MS_WH_UP, MEH(KC_9),
|
||||
MEH(KC_1), KC_MS_L, KC_MS_D, KC_MS_R, MEH(KC_6), KC_DOWN, RSFT(RCTL(KC_TAB)), RCTL(KC_TAB), KC_MS_WH_DOWN, LALT(KC_LEFT),
|
||||
MEH(KC_2), MEH(KC_3), MEH(KC_4), MEH(KC_5), MEH(KC_7), MEH(KC_8), RCTL(KC_1), RCTL(KC_9), KC_F6, KC_F5,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RCTL(KC_W), RCTL(KC_T), RSFT(RCTL(KC_TAB)), KC_TRNS, KC_TRNS, KC_TRNS
|
||||
),
|
||||
};
|
||||
|
||||
@@ -116,30 +103,3 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
return true;
|
||||
}
|
||||
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
// MACRODOWN only works in this function
|
||||
switch(id) {
|
||||
case MOUSE_TOGGLE:
|
||||
if (record->event.pressed) {
|
||||
layer_on(MOUSE);
|
||||
} else {
|
||||
if(!mouse_lock)
|
||||
layer_off(MOUSE);
|
||||
}
|
||||
break;
|
||||
case MOUSE_LOCK:
|
||||
if (record->event.pressed)
|
||||
{
|
||||
if(mouse_lock)
|
||||
{
|
||||
mouse_lock = false;
|
||||
layer_off(MOUSE);
|
||||
}
|
||||
else
|
||||
mouse_lock = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
return MACRO_NONE;
|
||||
};
|
||||
|
6
keyboards/chocopad/keymaps/khord/config.h
Normal file
6
keyboards/chocopad/keymaps/khord/config.h
Normal file
@@ -0,0 +1,6 @@
|
||||
#ifndef CONFIG_USER_H
|
||||
#define CONFIG_USER_H
|
||||
|
||||
#include "../../config.h"
|
||||
|
||||
#endif
|
104
keyboards/chocopad/keymaps/khord/keymap.c
Normal file
104
keyboards/chocopad/keymaps/khord/keymap.c
Normal file
@@ -0,0 +1,104 @@
|
||||
#include "chocopad.h"
|
||||
|
||||
#define _BASE 0
|
||||
#define _FN1 1
|
||||
#define _FN2 2
|
||||
|
||||
// Fillers to make layering more clear
|
||||
#define KC_ KC_TRNS
|
||||
#define KC_XX KC_NO
|
||||
|
||||
#define KC_L1 LT(1, KC_P0)
|
||||
#define KC_L2 LT(2, KC_SPC)
|
||||
#define KC_RST RESET
|
||||
#define KC_BSTP BL_STEP
|
||||
#define KC_RTOG RGB_TOG
|
||||
#define KC_RMOD RGB_MOD
|
||||
#define KC_RHUI RGB_HUI
|
||||
#define KC_RHUD RGB_HUD
|
||||
#define KC_RSAI RGB_SAI
|
||||
#define KC_RSAD RGB_SAD
|
||||
#define KC_RVAI RGB_VAI
|
||||
#define KC_RVAD RGB_VAD
|
||||
#define KC_MAC1 ADMIN
|
||||
#define KC_MAC2 SMSPC
|
||||
#define KC_M192 M192
|
||||
#define KC_M255 M255
|
||||
|
||||
enum custom_keycodes {
|
||||
NUMPAD = SAFE_RANGE,
|
||||
ADMIN,
|
||||
SMSPC,
|
||||
M192,
|
||||
M255
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
[_BASE] = KC_KEYMAP(
|
||||
//,----+----+----+----.
|
||||
P7 , P8 , P9 ,BSPC,
|
||||
//|----+----+----+----|
|
||||
P4 , P5 , P6 ,TAB ,
|
||||
//|----+----+----+----|
|
||||
P1 , P2 , P3 ,PENT,
|
||||
//|----+----+----+----|
|
||||
L1 , L2 ,PDOT,PSLS
|
||||
//`----+----+----+----'
|
||||
),
|
||||
|
||||
[_FN1] = KC_KEYMAP(
|
||||
//,----+----+----+----.
|
||||
ESC ,MAC1,MAC2,DEL ,
|
||||
//|----+----+----+----|
|
||||
LEFT,DOWN, UP ,RGHT,
|
||||
//|----+----+----+----|
|
||||
M192,M255, XX , XX ,
|
||||
//|----+----+----+----|
|
||||
, XX , , XX
|
||||
//`----+----+----+----'
|
||||
),
|
||||
|
||||
[_FN2] = KC_KEYMAP(
|
||||
//,----+----+----+----.
|
||||
RST , XX , XX , XX ,
|
||||
//|----+----+----+----|
|
||||
RTOG,RHUI,RSAI,RVAI,
|
||||
//|----+----+----+----|
|
||||
RMOD,RHUD,RSAD,RVAD,
|
||||
//|----+----+----+----|
|
||||
BSTP, , XX , XX
|
||||
//`----+----+----+----'
|
||||
)
|
||||
|
||||
};
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case ADMIN:
|
||||
if (record->event.pressed) {
|
||||
SEND_STRING("Administrator");
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case SMSPC:
|
||||
if (record->event.pressed) {
|
||||
SEND_STRING("Simspace1!");
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case M192:
|
||||
if (record->event.pressed) {
|
||||
SEND_STRING("192.168.");
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case M255:
|
||||
if (record->event.pressed) {
|
||||
SEND_STRING("255");
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
};
|
5
keyboards/chocopad/keymaps/khord/rules.mk
Normal file
5
keyboards/chocopad/keymaps/khord/rules.mk
Normal file
@@ -0,0 +1,5 @@
|
||||
RGBLIGHT_ENABLE = yes
|
||||
|
||||
ifndef QUANTUM_DIR
|
||||
include ../../../../Makefile
|
||||
endif
|
@@ -18,7 +18,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | | | | |
|
||||
* `---------------------- '
|
||||
*/
|
||||
[0] = KEYMAP( /* LAYER SELECT */
|
||||
[0] = LAYOUT( /* LAYER SELECT */
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, RESET, \
|
||||
TO(4), KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
TO(1), TO(2), TO(3), KC_TRNS, \
|
||||
@@ -35,7 +35,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | 0 | . | / | = |
|
||||
* `---------------------- '
|
||||
*/
|
||||
[1] = KEYMAP( /* NUMPAD */
|
||||
[1] = LAYOUT( /* NUMPAD */
|
||||
KC_P7, KC_P8, KC_P9, KC_PAST, \
|
||||
KC_P4, KC_P5, KC_P6, KC_PMNS, \
|
||||
KC_P1, KC_P2, KC_P3, KC_PPLS, \
|
||||
@@ -52,7 +52,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | | | | |
|
||||
* `---------------------- '
|
||||
*/
|
||||
[5] = KEYMAP( /* NUMPAD SUPPLEMENT */
|
||||
[5] = LAYOUT( /* NUMPAD SUPPLEMENT */
|
||||
KC_NLCK, KC_TRNS, KC_TRNS, TO(0), \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
@@ -69,7 +69,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* |LEFT |DOWN |RIGHT|ENTER|
|
||||
* `---------------------- '
|
||||
*/
|
||||
[2] = KEYMAP( /* NAV CLUSTER */
|
||||
[2] = LAYOUT( /* NAV CLUSTER */
|
||||
KC_INS, KC_PGUP, KC_TAB, KC_PSCR, \
|
||||
KC_DEL, KC_PGDN, KC_VOLD, KC_VOLU, \
|
||||
KC_HOME, KC_UP, KC_END, TO(0), \
|
||||
@@ -86,7 +86,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* |CTRL | C | R |SPACE|
|
||||
* `---------------------- '
|
||||
*/
|
||||
[3] = KEYMAP( /* GAMING */
|
||||
[3] = LAYOUT( /* GAMING */
|
||||
LT(4, KC_ESC), KC_1, KC_2, KC_3, \
|
||||
KC_TAB, KC_Q, KC_W, KC_E, \
|
||||
KC_LSFT, KC_A, KC_S, KC_D, \
|
||||
@@ -103,7 +103,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* |TOGGL|MODE | | |
|
||||
* `---------------------- '
|
||||
*/
|
||||
[4] = KEYMAP( /* NUMPAD SUPPLEMENT */
|
||||
[4] = LAYOUT( /* NUMPAD SUPPLEMENT */
|
||||
KC_NO, KC_NO, KC_NO, KC_NO, \
|
||||
KC_NO, KC_NO, KC_NO, KC_NO, \
|
||||
KC_NO, KC_NO, KC_NO, KC_NO, \
|
||||
|
@@ -7,7 +7,7 @@
|
||||
// The following is an example using the Planck MIT layout
|
||||
// The first section contains all of the arguements
|
||||
// The second converts the arguments into a two-dimensional array
|
||||
#define KEYMAP( \
|
||||
#define LAYOUT( \
|
||||
k00, k01, k02, k03, \
|
||||
k10, k11, k12, k13, \
|
||||
k20, k21, k22, k23, \
|
||||
|
@@ -48,7 +48,7 @@
|
||||
* @details Frequency of the system timer that drives the system ticks. This
|
||||
* setting also defines the system tick time unit.
|
||||
*/
|
||||
#define CH_CFG_ST_FREQUENCY 10000
|
||||
#define CH_CFG_ST_FREQUENCY 100000
|
||||
|
||||
/**
|
||||
* @brief Time delta constant for the tick-less mode.
|
||||
|
@@ -1,3 +0,0 @@
|
||||
#include "../config.h"
|
||||
|
||||
#define TAPPING_TERM 600 // ms
|
@@ -20,19 +20,13 @@
|
||||
enum contra_layers {
|
||||
_QWERTZ,
|
||||
_FUNC,
|
||||
_NUMPAD,
|
||||
_NUMROW
|
||||
};
|
||||
|
||||
#define KC_I3 LM(_NUMROW, MOD_LALT)
|
||||
#define KC_NR MO(_NUMROW)
|
||||
#define NR_L3 SAFE_RANGE
|
||||
#define FUN MO(_FUNC)
|
||||
#define NPK TT(_NUMPAD)
|
||||
//#define SPEC_S LM(_NUMROW, (KC_LSFT))
|
||||
//#define SPEC_L3 LM(_NUMROW, (DE_ALGR))
|
||||
|
||||
enum custom_keycodes {
|
||||
SPEC_S = SAFE_RANGE,
|
||||
SPEC_L3
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
@@ -44,21 +38,21 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | Shift| Y | X | C | V | B | N | M | , | . | Up | Shift|
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | Ctrl | Sup | Alt | NumP | Spec | Space | Sp_A | Fun | Left | Down | Right|
|
||||
* | Ctrl | Sup | Alt | i3 | NumR | Space | Spec | Fun | Left | Down | Right|
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_QWERTZ] = {
|
||||
{KC_GESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC},
|
||||
{KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, DE_PLUS, KC_ENT },
|
||||
{KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_UP, KC_RSFT},
|
||||
{KC_LCTL, KC_LGUI, KC_LALT, NPK, SPEC_S, KC_SPC, KC_SPC, SPEC_L3, FUN, KC_LEFT, KC_DOWN, KC_RGHT}
|
||||
{KC_LCTL, KC_LGUI, KC_LALT, KC_I3, KC_NR, KC_SPC, KC_SPC, NR_L3, FUN, KC_LEFT, KC_DOWN, KC_RGHT}
|
||||
},
|
||||
|
||||
/* Function layer
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | | | | | | | | Ü | | Ö | | Del |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | Lock | Ä | | | | | | RGBS | RGBB | RGBS | | |
|
||||
* | Lock | Ä | ß | | | | | RGBS | RGBB | RGBS | | |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | | | | | | | | RGBH-| RGBT | RGBH+| PgUp | |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
@@ -67,7 +61,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
*/
|
||||
[_FUNC] = {
|
||||
{_______, _______, _______, _______, _______, _______, _______, DE_UE, _______, DE_OE, _______, KC_DEL },
|
||||
{KC_LOCK, DE_AE, _______, _______, _______, _______, _______, RGB_M_P, RGB_M_B, RGB_M_SW,_______, _______},
|
||||
{KC_LOCK, DE_AE, DE_SS, _______, _______, _______, _______, RGB_M_P, RGB_M_B, RGB_M_SW,_______, _______},
|
||||
{_______, _______, _______, _______, _______, _______, _______, RGB_HUD, RGB_TOG, RGB_HUI, KC_PGUP, _______},
|
||||
{_______, _______, _______, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, KC_HOME, KC_PGDN, KC_END }
|
||||
},
|
||||
@@ -76,51 +70,23 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | ß |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | | | | | | | | | | | | |
|
||||
* | | | | | | | | | | | #' | |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | | ><| | | | | | | | | | _ - | |
|
||||
* | | <> | | | | | | | | | | -_ | |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | | | | ---- | ---- | | | ---- | ---- | | | |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_NUMROW] = {
|
||||
{_______, DE_1, DE_2, DE_3, DE_4, DE_5, DE_6, DE_7, DE_8, DE_9, DE_0, DE_SS },
|
||||
{_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______},
|
||||
{_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, DE_HASH, _______},
|
||||
{_______, DE_LESS, _______, _______, _______, _______, _______, _______, _______, _______, DE_MINS, _______},
|
||||
{_______, _______, _______, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, _______, _______, _______}
|
||||
},
|
||||
|
||||
/* Numpad layer
|
||||
* ,-----------------------------------------------------------------------------------.
|
||||
* | | + | 7 | 8 | 9 | | | | | | | |
|
||||
* |------+------+------+------+------+-------------+------+------+------+------+------|
|
||||
* | | - | 4 | 5 | 6 | | | | | | | |
|
||||
* |------+------+------+------+------+------|------+------+------+------+------+------|
|
||||
* | | * | 1 | 2 | 3 | | | | | | | |
|
||||
* |------+------+------+------+------+------+------+------+------+------+------+------|
|
||||
* | | / | 0 | ---- | ---- | | | ---- | ---- | | | |
|
||||
* `-----------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_NUMPAD] = {
|
||||
{DEBUG, KC_PPLS, KC_P7, KC_P8, KC_P9, _______, _______, _______, _______, _______, _______, _______},
|
||||
{_______, KC_PMNS, KC_P4, KC_P5, KC_P6, _______, _______, _______, _______, _______, _______, _______},
|
||||
{_______, KC_PAST, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______},
|
||||
{_______, KC_PSLS, KC_P0, _______, XXXXXXX, _______, _______, XXXXXXX, XXXXXXX, _______, _______, _______}
|
||||
}
|
||||
};
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case SPEC_S:
|
||||
if (record->event.pressed) {
|
||||
register_code(KC_LSFT);
|
||||
layer_on(_NUMROW);
|
||||
} else {
|
||||
layer_off(_NUMROW);
|
||||
unregister_code(KC_LSFT);
|
||||
}
|
||||
return false;
|
||||
case SPEC_L3:
|
||||
if (keycode == NR_L3) {
|
||||
if (record->event.pressed) {
|
||||
register_code(DE_ALGR);
|
||||
layer_on(_NUMROW);
|
||||
@@ -129,9 +95,8 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
unregister_code(DE_ALGR);
|
||||
}
|
||||
return false;
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led) {
|
||||
|
@@ -1 +1,2 @@
|
||||
# Contra Layout by Maxr1998
|
||||
# Contra Layout by Maxr1998
|
||||

|
@@ -1,8 +1,13 @@
|
||||
RGBLIGHT_ENABLE = yes
|
||||
KEY_LOCK_ENABLE = yes
|
||||
|
||||
EXTRAFLAGS += -flto
|
||||
UNICODE_ENABLE = no
|
||||
MOUSEKEY_ENABLE = no
|
||||
|
||||
### Debugging ###
|
||||
#CONSOLE_ENABLE = yes
|
||||
CONSOLE_ENABLE = no # yes
|
||||
COMMAND_ENABLE = no
|
||||
|
||||
ifndef QUANTUM_DIR
|
||||
include ../../../../Makefile
|
||||
|
51
keyboards/converter/m0110_usb/README.md
Normal file
51
keyboards/converter/m0110_usb/README.md
Normal file
@@ -0,0 +1,51 @@
|
||||
M0110(A) keyboard converter
|
||||
======================================
|
||||
This is a port of the original M0110 converter from TMK to QMK. The original converter was designed to work with **ATmega32U2** and **ATmega32U4** based microcontrollers to convert Apple M0110/M0110A keyboards and M0120 numpads to USB. This port has been tested to be compatible with the [**Adafruit Feather 32U4 BLE**](https://learn.adafruit.com/adafruit-feather-32u4-bluefruit-le).
|
||||
|
||||
|
||||
### Enabling Bluetooth for the Adafruit Feather 32U4 BLE
|
||||
----------------------------------------------------
|
||||
Simply add `BLUETOOTH = AdafruitBLE` to your `rules.mk` file. This enables code specifically for the Adafruit Feather 32U4 BLE. If enabled, the device will use the `PRODUCT` and `DESCRIPTION` values from `config.h` for the device name displayed by the Feather on host devices. You can simply change these values to change the device name.
|
||||
|
||||
|
||||
### Pins
|
||||
----
|
||||
This port utilizes the same pins that the TMK converter used. `PD1` is used for `CLOCK` and `PD0` is used for the `DATA` from the keyboard. These pins can be changed in `config.h`.
|
||||
|
||||
|
||||
### Other important hardware notes from the original TMK converter Readme:
|
||||
>### Hardware
|
||||
>--------
|
||||
>You can buy preassembled [TMK converter] or make yourown with AVR dev board like PJRC [Teensy].
|
||||
>
|
||||
>Port of the MCU `PD1` is assigned to `CLOCK` line and `PD0` to `DATA` by default, you can change pin configuration with editing `config.h`.
|
||||
>
|
||||
>[](http://i.imgur.com/yEp2eRi.jpg)
|
||||
>
|
||||
>#### 4P4C phone handset cable
|
||||
>Note that original cable used with Mac is **straight** while phone handset cable is **crossover**.
|
||||
>
|
||||
><http://en.wikipedia.org/wiki/Modular_connector#4P4C>
|
||||
>
|
||||
>[Teensy]: http://www.pjrc.com/teensy/
|
||||
>[TMK converter]: https://geekhack.org/index.php?topic=72052.0
|
||||
>
|
||||
>
|
||||
>#### Socket Pinout
|
||||
>- <http://pinouts.ru/Inputs/MacKeyboard_pinout.shtml>
|
||||
>
|
||||
>
|
||||
>
|
||||
>
|
||||
>#### Pull-up Resistor
|
||||
>You may need pull-up resistors on signal lines(`CLOCK`, `DATA`) in particular when you have long or coiled cable. **1k-10k Ohm** will be OK >for this purpose. In that case the converter may not read signal from keyboard correctly without pull-up resistors.
|
||||
>
|
||||
|
||||
[**View the original TMK converter Readme**](https://github.com/tmk/tmk_keyboard/tree/master/converter/m0110_usb)\
|
||||
[**View the original TMK converter Repository**](https://github.com/tmk/tmk_keyboard/tree/master/converter/m0110_usb)
|
||||
|
||||
|
||||
### QMK Port Changelog
|
||||
---------
|
||||
- 2018/08/01 - Original Release
|
||||
|
59
keyboards/converter/m0110_usb/config.h
Normal file
59
keyboards/converter/m0110_usb/config.h
Normal file
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
Copyright 2011,2012 Jun Wako <wakojun@gmail.com>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
--------------
|
||||
|
||||
Ported to QMK by Techsock <info@techsock.com>
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x0110
|
||||
#define DEVICE_VER 0x0101
|
||||
#define MANUFACTURER Apple
|
||||
#define PRODUCT M0110(A)
|
||||
#define DESCRIPTION Converts M0110(A) to USB and/or BT
|
||||
|
||||
/* matrix size */
|
||||
#define MATRIX_ROWS 14
|
||||
#define MATRIX_COLS 8
|
||||
|
||||
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
/* Locking resynchronize hack */
|
||||
#define LOCKING_RESYNC_ENABLE
|
||||
|
||||
/* magic key */
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_LALT) | MOD_BIT(KC_LGUI)) || \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_LALT) | MOD_BIT(KC_LCTL)) \
|
||||
)
|
||||
|
||||
/* boot magic key */
|
||||
#define BOOTMAGIC_KEY_SALT KC_M
|
||||
|
||||
/* ports */
|
||||
#define M0110_CLOCK_PORT PORTD
|
||||
#define M0110_CLOCK_PIN PIND
|
||||
#define M0110_CLOCK_DDR DDRD
|
||||
#define M0110_CLOCK_BIT 1
|
||||
#define M0110_DATA_PORT PORTD
|
||||
#define M0110_DATA_PIN PIND
|
||||
#define M0110_DATA_DDR DDRD
|
||||
#define M0110_DATA_BIT 0
|
||||
|
||||
|
92
keyboards/converter/m0110_usb/keymaps/default/keymap.c
Normal file
92
keyboards/converter/m0110_usb/keymaps/default/keymap.c
Normal file
@@ -0,0 +1,92 @@
|
||||
/*
|
||||
Copyright 2011,2012,2015 Jun Wako <wakojun@gmail.com>
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
--------------
|
||||
|
||||
Ported to QMK by Techsock <info@techsock.com>
|
||||
*/
|
||||
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
/* Default:
|
||||
* M0110 M0120
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* | `| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backs| |Nlk| =| /| *|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \| | 7| 8| 9| -|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Caps | A| S| D| F| G| H| J| K| L| ;| '|Return| | 4| 5| 6| +|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift | | 1| 2| 3| |
|
||||
* `---------------------------------------------------------' |-----------|Ent|
|
||||
* |Opt|Mac | Space |Fn |Opt| | 0| .| |
|
||||
* `-----------------------------------------------' `---------------'
|
||||
* M0110A
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* | `| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backs| |Nlk| =| /| *|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| | | 7| 8| 9| -|
|
||||
* |-----------------------------------------------------' | |---------------|
|
||||
* |Caps | A| S| D| F| G| H| J| K| L| ;| '|Return| | 4| 5| 6| +|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Shift | Z| X| C| V| B| N| M| ,| .| /|Shft|Up | | 1| 2| 3| |
|
||||
* |---------------------------------------------------------| |-----------|Ent|
|
||||
* |Opt |Mac | Space | \|Lft|Rgt|Dn | | 0| .| |
|
||||
* `---------------------------------------------------------' `---------------'
|
||||
*/
|
||||
|
||||
[0] = LAYOUT_ansi(
|
||||
KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_NLCK, KC_EQL, KC_PSLS, KC_PAST, \
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_P7, KC_P8, KC_P9, KC_PMNS, \
|
||||
KC_LCAP, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_P4, KC_P5, KC_P6, KC_PPLS, \
|
||||
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_UP, KC_P1, KC_P2, KC_P3, KC_PENT, \
|
||||
KC_LALT, KC_LGUI, KC_SPC, MO(1), LT(1, KC_BSLASH), KC_LEFT, KC_RGHT, KC_DOWN, KC_P0, KC_PDOT),
|
||||
|
||||
|
||||
/* Cursor Layer:
|
||||
* M0110 M0120
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet| |Nlk| =| /| *|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Tab |Hom| Up|PgU|Rst| | | |Psc|Slk|Pau|Up |INS| | | 7| 8| 9| -|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Ctrl |Lef|Dow|Rig| | | | |Hom|PgU|Lef|Rig|Return| | 4| 5| 6| +|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Shift |End| |PgD| | | | |End|PgD|Dow|Shift | | 1| 2| 3| |
|
||||
* `---------------------------------------------------------' |-----------|Ent|
|
||||
* |Opt|Mac | Space |Fn |Opt| | 0| .| |
|
||||
* `-----------------------------------------------' `---------------'
|
||||
* M0110A
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* |Esc| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delet| |Nlk| =| /| *|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Tab |Hom| Up|PgU| | | | |Psc|Slk|Pau|Up |INS| | | 7| 8| 9| -|
|
||||
* |-----------------------------------------------------' | |---------------|
|
||||
* |Caps |Lef|Dow|Rig| | | | |Hom|PgU|Lef|Rig|Return| | 4| 5| 6| +|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Ctrl |End| |PgD| | | | |End|PgD|Dow|Shft|PgU| | 1| 2| 3| |
|
||||
* |---------------------------------------------------------| |-----------|Ent|
|
||||
* |Opt |Mac | Space | \|Hom|End|PgD| | 0| .| |
|
||||
* `---------------------------------------------------------' `---------------'
|
||||
*/
|
||||
|
||||
[1] = LAYOUT_ansi(
|
||||
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, KC_NLCK, KC_EQL, KC_PSLS, KC_PAST, \
|
||||
KC_TAB, KC_HOME, KC_UP, KC_PGUP, RESET, KC_NO, KC_NO, KC_NO, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_INS, KC_P7, KC_P8, KC_P9, KC_PMNS, \
|
||||
KC_LCAP, KC_LEFT, KC_DOWN, KC_RGHT, KC_NO, KC_NO, KC_NO, KC_NO, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_ENT, KC_P4, KC_P5, KC_P6, KC_PPLS, \
|
||||
KC_LCTL, KC_END, KC_NO, KC_PGDN, KC_NO, KC_NO, KC_NO, KC_NO, KC_END, KC_PGDN, KC_DOWN, KC_PGUP, KC_P1, KC_P2, KC_P3, KC_PENT, \
|
||||
KC_LALT, KC_LGUI, KC_SPC, KC_TRNS, KC_TRNS, KC_HOME, KC_END, KC_PGDN, KC_P0, KC_PDOT),
|
||||
|
||||
};
|
3
keyboards/converter/m0110_usb/m0110_usb.c
Normal file
3
keyboards/converter/m0110_usb/m0110_usb.c
Normal file
@@ -0,0 +1,3 @@
|
||||
#include "m0110_usb.h"
|
||||
#include <avr/io.h>
|
||||
#include "quantum.h"
|
131
keyboards/converter/m0110_usb/m0110_usb.h
Normal file
131
keyboards/converter/m0110_usb/m0110_usb.h
Normal file
@@ -0,0 +1,131 @@
|
||||
/*
|
||||
Copyright 2011,2012,2014,2015 Jun Wako <wakojun@gmail.com>
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
--------------
|
||||
|
||||
Ported to QMK by Techsock <info@techsock.com>
|
||||
*/
|
||||
|
||||
#ifndef M0110_USB_H
|
||||
#define M0110_USB_H
|
||||
#endif
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
/* Common layout for M0110 and M0110A
|
||||
* This keymap works with both keyboards. As you can see, the M0110A is
|
||||
* a superset of M0110 keyboard, only one exception is 'Enter'(34) of M0110
|
||||
* does not exist on the M0110A.
|
||||
*
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* | `| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backs| |Clr| =| /| *|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| | | 7| 8| 9| -|
|
||||
* |-----------------------------------------------------' | |---------------|
|
||||
* |Caps | A| S| D| F| G| H| J| K| L| ;| '|Return| | 4| 5| 6| +|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* |Shift | Z| X| C| V| B| N| M| ,| ,| /|Shft|Up | | 1| 2| 3| |
|
||||
* |---------------------------------------------------------| |-----------|Ent|
|
||||
* |Opt |Mac | Space |Ent| \|Lft|Rgt|Dn | | 0| .| |
|
||||
* `---------------------------------------------------------' `---------------'
|
||||
*
|
||||
* M0110A scan codes
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* | 32| 12| 13| 14| 15| 17| 16| 1A| 1C| 19| 1D| 1B| 18| 33| | 47| 68| 6D| 62|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 30| 0C| 0D| 0E| 0F| 11| 10| 20| 22| 1F| 23| 21| 1E| | | 59| 5B| 5C| 4E|
|
||||
* |-----------------------------------------------------' | |---------------|
|
||||
* | 39| 00| 01| 02| 03| 05| 04| 26| 28| 25| 29| 27| 24| | 56| 57| 58| 66|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 38| 06| 07| 08| 09| 0B| 2D| 2E| 2B| 2F| 2C| 38| 4D| | 53| 54| 55| |
|
||||
* `---------------------------------------------------------' |-----------| 4C|
|
||||
* | 3A| 37| 31 | 2A| 46| 42| 48| | 52| 41| |
|
||||
* `---------------------------------------------------------' `---------------'
|
||||
*
|
||||
* M0110 + M0120 scan codes
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* | 32| 12| 13| 14| 15| 17| 16| 1A| 1C| 19| 1D| 1B| 18| 33| | 47| 68| 6D| 62|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 30| 0C| 0D| 0E| 0F| 11| 10| 20| 22| 1F| 23| 21| 1E| 2A| | 59| 5B| 5C| 4E|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 39| 00| 01| 02| 03| 05| 04| 26| 28| 25| 29| 27| 24| | 56| 57| 58| 66|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 38| 06| 07| 08| 09| 0B| 2D| 2E| 2B| 2F| 2C| 38| | 53| 54| 55| |
|
||||
* `---------------------------------------------------------' |-----------| 4C|
|
||||
* | 3A| 37| 31 | 34| 3A| | 52| 41| |
|
||||
* `------------------------------------------------' `---------------'
|
||||
* Two right and left keys of 38 and 3A are identical, you cannot discriminate those two.
|
||||
*/
|
||||
#define LAYOUT_ansi( \
|
||||
K32,K12,K13,K14,K15,K17,K16,K1A,K1C,K19,K1D,K1B,K18,K33, K47,K68,K6D,K62, \
|
||||
K30,K0C,K0D,K0E,K0F,K11,K10,K20,K22,K1F,K23,K21,K1E, K59,K5B,K5C,K4E, \
|
||||
K39,K00,K01,K02,K03,K05,K04,K26,K28,K25,K29,K27, K24, K56,K57,K58,K66, \
|
||||
K38,K06,K07,K08,K09,K0B,K2D,K2E,K2B,K2F,K2C, K4D, K53,K54,K55,K4C, \
|
||||
K3A,K37, K31, K34,K2A,K46,K42,K48, K52, K41 \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07 }, \
|
||||
{ K08, K09, KC_NO, K0B, K0C, K0D, K0E, K0F }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17 }, \
|
||||
{ K18, K19, K1A, K1B, K1C, K1D, K1E, K1F }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27 }, \
|
||||
{ K28, K29, K2A, K2B, K2C, K2D, K2E, K2F }, \
|
||||
{ K30, K31, K32, K33, K34, KC_NO, KC_NO, K37 }, \
|
||||
{ K38, K39, K3A, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO }, \
|
||||
{ KC_NO, K41, K42, KC_NO, KC_NO, KC_NO, K46, K47 }, \
|
||||
{ K48, KC_NO, KC_NO, KC_NO, K4C, K4D, K4E, KC_NO }, \
|
||||
{ KC_NO, KC_NO, K52, K53, K54, K55, K56, K57 }, \
|
||||
{ K58, K59, KC_NO, K5B, K5C, KC_NO, KC_NO, KC_NO }, \
|
||||
{ KC_NO, KC_NO, K62, KC_NO, KC_NO, KC_NO, K66, KC_NO }, \
|
||||
{ K68, KC_NO, KC_NO, KC_NO, KC_NO, K6D, KC_NO, KC_NO }, \
|
||||
}
|
||||
|
||||
/* International keyboard layout for M0110 + M0120
|
||||
* https://en.wikipedia.org/wiki/File:Apple_Macintosh_Plus_Keyboard.jpg
|
||||
* Probably International keyboard layout of M0110A doesn't exist.
|
||||
*
|
||||
* M0110 + M0120 scan codes
|
||||
* ,---------------------------------------------------------. ,---------------.
|
||||
* | 32| 12| 13| 14| 15| 17| 16| 1A| 1C| 19| 1D| 1B| 18| 33| | 47| 68| 6D| 62|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 30| 0C| 0D| 0E| 0F| 11| 10| 20| 22| 1F| 23| 21| 1E| 2A| | 59| 5B| 5C| 4E|
|
||||
* |------------------------------------------------------, | |---------------|
|
||||
* | 39| 00| 01| 02| 03| 05| 04| 26| 28| 25| 29| 27| 24| | | 56| 57| 58| 66|
|
||||
* |---------------------------------------------------------| |---------------|
|
||||
* | 38| 06| 07| 08| 09| 0B| 2D| 2E| 2B| 2F| 2C| 0A| 38| | 53| 54| 55| |
|
||||
* `---------------------------------------------------------' |-----------| 4C|
|
||||
* | 3A| 37| 34 | 31| 3A| | 52| 41| |
|
||||
* `------------------------------------------------' `---------------'
|
||||
* Two right and left keys of 38 and 3A are identical, you cannot discriminate those two.
|
||||
*/
|
||||
#define LAYOUT_iso( \
|
||||
K32,K12,K13,K14,K15,K17,K16,K1A,K1C,K19,K1D,K1B,K18,K33, K47,K68,K6D,K62, \
|
||||
K30,K0C,K0D,K0E,K0F,K11,K10,K20,K22,K1F,K23,K21,K1E,K2A, K59,K5B,K5C,K4E, \
|
||||
K39,K00,K01,K02,K03,K05,K04,K26,K28,K25,K29,K27,K24, K56,K57,K58,K66, \
|
||||
K38,K06,K07,K08,K09,K0B,K2D,K2E,K2B,K2F,K2C,K0A, K53,K54,K55,K4C, \
|
||||
K3A,K37, K34, K31, K52, K41 \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07 }, \
|
||||
{ K08, K09, K0A, K0B, K0C, K0D, K0E, K0F }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17 }, \
|
||||
{ K18, K19, K1A, K1B, K1C, K1D, K1E, K1F }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27 }, \
|
||||
{ K28, K29, K2A, K2B, K2C, K2D, K2E, K2F }, \
|
||||
{ K30, K31, K32, K33, K34, KC_NO, KC_NO, K37 }, \
|
||||
{ K38, K39, K3A, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO }, \
|
||||
{ KC_NO, K41, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, K47 }, \
|
||||
{ KC_NO, KC_NO, KC_NO, KC_NO, K4C, KC_NO, K4E, KC_NO }, \
|
||||
{ KC_NO, KC_NO, K52, K53, K54, K55, K56, K57 }, \
|
||||
{ K58, K59, KC_NO, K5B, K5C, KC_NO, KC_NO, KC_NO }, \
|
||||
{ KC_NO, KC_NO, K62, KC_NO, KC_NO, KC_NO, K66, KC_NO }, \
|
||||
{ K68, KC_NO, KC_NO, KC_NO, KC_NO, K6D, KC_NO, KC_NO }, \
|
||||
}
|
121
keyboards/converter/m0110_usb/matrix.c
Normal file
121
keyboards/converter/m0110_usb/matrix.c
Normal file
@@ -0,0 +1,121 @@
|
||||
/*
|
||||
Copyright 2011,2012 Jun Wako <wakojun@gmail.com>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
--------------
|
||||
|
||||
Ported to QMK by Techsock <info@techsock.com>
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <avr/io.h>
|
||||
#include <util/delay.h>
|
||||
#include "print.h"
|
||||
#include "util.h"
|
||||
#include "debug.h"
|
||||
#include "host.h"
|
||||
#include "m0110.h"
|
||||
#include "matrix.h"
|
||||
#include "report.h"
|
||||
#include "timer.h"
|
||||
|
||||
|
||||
#define CAPS 0x39
|
||||
#define CAPS_BREAK (CAPS | 0x80)
|
||||
#define ROW(key) ((key)>>3&0x0F)
|
||||
#define COL(key) ((key)&0x07)
|
||||
|
||||
|
||||
static bool is_modified = false;
|
||||
|
||||
// matrix state buffer(1:on, 0:off)
|
||||
static uint8_t *matrix;
|
||||
static uint8_t _matrix0[MATRIX_ROWS];
|
||||
|
||||
static void register_key(uint8_t key);
|
||||
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_init_kb(void) {
|
||||
matrix_init_user();
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_scan_kb(void) {
|
||||
matrix_scan_user();
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_init_user(void) {
|
||||
}
|
||||
|
||||
__attribute__ ((weak))
|
||||
void matrix_scan_user(void) {
|
||||
}
|
||||
|
||||
void matrix_init(void)
|
||||
{
|
||||
m0110_init();
|
||||
// initialize matrix state: all keys off
|
||||
for (uint8_t i=0; i < MATRIX_ROWS; i++) _matrix0[i] = 0x00;
|
||||
matrix = _matrix0;
|
||||
|
||||
matrix_init_quantum();
|
||||
return;
|
||||
}
|
||||
|
||||
uint8_t matrix_scan(void)
|
||||
{
|
||||
uint8_t key;
|
||||
|
||||
is_modified = false;
|
||||
key = m0110_recv_key();
|
||||
|
||||
if (key == M0110_NULL) {
|
||||
return 0;
|
||||
} else if (key == M0110_ERROR) {
|
||||
return 0;
|
||||
} else {
|
||||
is_modified = true;
|
||||
register_key(key);
|
||||
}
|
||||
|
||||
if (debug_enable) {
|
||||
print("["); phex(key); print("]\n");
|
||||
}
|
||||
|
||||
matrix_scan_quantum();
|
||||
return 1;
|
||||
}
|
||||
|
||||
void matrix_print(void){
|
||||
|
||||
}
|
||||
|
||||
inline
|
||||
uint8_t matrix_get_row(uint8_t row)
|
||||
{
|
||||
return matrix[row];
|
||||
}
|
||||
|
||||
inline
|
||||
static void register_key(uint8_t key)
|
||||
{
|
||||
if (key&0x80) {
|
||||
matrix[ROW(key)] &= ~(1<<COL(key));
|
||||
} else {
|
||||
matrix[ROW(key)] |= (1<<COL(key));
|
||||
}
|
||||
}
|
73
keyboards/converter/m0110_usb/rules.mk
Normal file
73
keyboards/converter/m0110_usb/rules.mk
Normal file
@@ -0,0 +1,73 @@
|
||||
# MCU name
|
||||
# atmega32u4 Teensy2.0
|
||||
# atemga32u4 TMK Converter rev.1
|
||||
# atemga32u2 TMK Converter rev.2
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
#
|
||||
#F_CPU = 16000000
|
||||
F_CPU = 8000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Bootloader
|
||||
# This definition is optional, and if your keyboard supports multiple bootloaders of
|
||||
# different sizes, comment this out, and the correct address will be loaded
|
||||
# automatically (+60). See bootloader.mk for all options.
|
||||
BOOTLOADER = caterina
|
||||
|
||||
# Boot Section Size in *bytes*
|
||||
# Teensy halfKay 512
|
||||
# Teensy++ halfKay 1024
|
||||
# Atmel DFU loader 4096 for TMK Converter rev.1/rev.2
|
||||
# LUFA bootloader 4096
|
||||
# USBaspLoader 2048
|
||||
|
||||
# Build Options
|
||||
# comment out to disable the options.
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
CONSOLE_ENABLE = yes # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
NKRO_ENABLE = no # USB Nkey Rollover - not yet supported in LUFA
|
||||
EXTRAKEY_ENABLE = yes
|
||||
USB_HID_ENABLE = yes
|
||||
BACKLIGHT_ENABLE = no
|
||||
#BLUETOOTH = AdafruitBLE # For Adafruit Feather 32U4 BLE support, uncomment this line
|
||||
|
||||
CUSTOM_MATRIX = yes
|
||||
SRC = matrix.c \
|
||||
m0110.c
|
@@ -23,7 +23,7 @@
|
||||
// This a shortcut to help you visually see your layout.
|
||||
// The first section contains all of the arguments
|
||||
// The second converts the arguments into a two-dimensional array
|
||||
#define LAYOUT_ALL( \
|
||||
#define LAYOUT_all( \
|
||||
K00, K01, K02, \
|
||||
K10, K11, K12, \
|
||||
\
|
||||
|
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"keyboard_name": "DC01 Arrow Cluster",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"width": 3,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_all": {
|
||||
"layout": [{"label":"Insert", "x":0, "y":0}, {"label":"Home", "x":1, "y":0}, {"label":"PgUp", "x":2, "y":0}, {"label":"Delete", "x":0, "y":1}, {"label":"End", "x":1, "y":1}, {"label":"PgDn", "x":2, "y":1}, {"label":"\u2191", "x":1, "y":3}, {"label":"\u2190", "x":0, "y":4}, {"label":"\u2193", "x":1, "y":4}, {"label":"\u2192", "x":2, "y":4}]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_ALL( /* Base */
|
||||
[0] = LAYOUT_all( /* Base */
|
||||
KC_INS, KC_HOME, KC_PGUP, \
|
||||
KC_DEL, KC_END, KC_PGDN, \
|
||||
\
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||

|
||||
|
||||
A hotpluggable four part keyboard which comes together with magnets and pogo pins! This is the arrow cluster
|
||||
A hotpluggable four part keyboard which comes together with magnets and pogo pins! This is the arrow cluster.
|
||||
|
||||
Keyboard Maintainer: [Yiancar](https://github.com/yiancar)
|
||||
Hardware Supported: Runs on an atmega32u4
|
||||
|
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"keyboard_name": "DC01 Left Half",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"width": 22.5,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_ansi": {
|
||||
"layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Insert", "x":15.25, "y":0}, {"label":"Home", "x":16.25, "y":0}, {"label":"PgUp", "x":17.25, "y":0}, {"label":"Num Lock", "x":18.5, "y":0}, {"label":"/", "x":19.5, "y":0}, {"label":"*", "x":20.5, "y":0}, {"label":"-", "x":21.5, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Delete", "x":15.25, "y":1}, {"label":"End", "x":16.25, "y":1}, {"label":"PgDn", "x":17.25, "y":1}, {"label":"7", "x":18.5, "y":1}, {"label":"8", "x":19.5, "y":1}, {"label":"9", "x":20.5, "y":1}, {"label":"+", "x":21.5, "y":1}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"4", "x":18.5, "y":2}, {"label":"5", "x":19.5, "y":2}, {"label":"6", "x":20.5, "y":2}, {"label":"KC_NO", "x":21.5, "y":2}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":2.75}, {"label":"\u2191", "x":16.25, "y":3}, {"label":"1", "x":18.5, "y":3}, {"label":"2", "x":19.5, "y":3}, {"label":"3", "x":20.5, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"GUI", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":2.75}, {"x":6.5, "y":4, "w":1.25}, {"x":7.75, "y":4, "w":2.25}, {"label":"Alt", "x":10, "y":4, "w":1.25}, {"label":"GUI", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}, {"label":"\u2190", "x":15.25, "y":4}, {"label":"\u2193", "x":16.25, "y":4}, {"label":"\u2192", "x":17.25, "y":4}, {"label":"0", "x":18.5, "y":4}, {"label":"KC_NO", "x":19.5, "y":4}, {"label":".", "x":20.5, "y":4}, {"label":"Enter", "x":21.5, "y":3, "h":2}]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_ANSI( /* Base */
|
||||
[0] = LAYOUT_ansi( /* Base */
|
||||
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS, KC_HOME, KC_PGUP, KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS, \
|
||||
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_P4, KC_P5, KC_P6, KC_NO, \
|
||||
|
@@ -23,7 +23,7 @@
|
||||
// This a shortcut to help you visually see your layout.
|
||||
// The first section contains all of the arguments
|
||||
// The second converts the arguments into a two-dimensional array
|
||||
#define LAYOUT_ANSI( \
|
||||
#define LAYOUT_ansi( \
|
||||
K00, K01, K02, K03, K04, K05, K45, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, K0F, K0G, K0H, K0J, K0K, K0L, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, K1F, K1G, K1H, K1J, K1K, K1L, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, K2H, K2J, K2K, K2L, \
|
||||
|
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"keyboard_name": "DC01 Numpad",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"width": 4,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_numpad_5x4": {
|
||||
"layout": [{"label":"Num Lock", "x":0, "y":0}, {"label":"/", "x":1, "y":0}, {"label":"*", "x":2, "y":0}, {"label":"-", "x":3, "y":0}, {"label":"7", "x":0, "y":1}, {"label":"8", "x":1, "y":1}, {"label":"9", "x":2, "y":1}, {"label":"4", "x":0, "y":2}, {"label":"5", "x":1, "y":2}, {"label":"6", "x":2, "y":2}, {"label":"+", "x":3, "y":1, "h":2}, {"label":"1", "x":0, "y":3}, {"label":"2", "x":1, "y":3}, {"label":"3", "x":2, "y":3}, {"label":"0", "x":0, "y":4, "w":2}, {"label":".", "x":2, "y":4}, {"label":"Enter", "x":3, "y":3, "h":2}]
|
||||
},
|
||||
"LAYOUT_ortho_5x4": {
|
||||
"layout": [{"label":"Num Lock", "x":0, "y":0}, {"label":"/", "x":1, "y":0}, {"label":"*", "x":2, "y":0}, {"label":"-", "x":3, "y":0}, {"label":"7", "x":0, "y":1}, {"label":"8", "x":1, "y":1}, {"label":"9", "x":2, "y":1}, {"label":"+", "x":3, "y":1}, {"label":"4", "x":0, "y":2}, {"label":"5", "x":1, "y":2}, {"label":"6", "x":2, "y":2}, {"label":"+", "x":3, "y":2}, {"label":"1", "x":0, "y":3}, {"label":"2", "x":1, "y":3}, {"label":"3", "x":2, "y":3}, {"label":"Enter", "x":3, "y":3}, {"label":"0", "x":0, "y":4}, {"label":"00", "x":1, "y":4}, {"label":".", "x":2, "y":4}, {"label":"Enter", "x":3, "y":4}]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -25,8 +25,8 @@
|
||||
// The second converts the arguments into a two-dimensional array
|
||||
#define LAYOUT_numpad_5x4( \
|
||||
K00, K01, K02, K03, \
|
||||
K10, K11, K12, K13, \
|
||||
K20, K21, K22, \
|
||||
K10, K11, K12, \
|
||||
K20, K21, K22, K13, \
|
||||
K30, K31, K32, \
|
||||
K40, K42, K43 \
|
||||
) \
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||

|
||||
|
||||
A hotpluggable four part keyboard which comes together with magnets and pogo pins! This is the numpad
|
||||
A hotpluggable four part keyboard which comes together with magnets and pogo pins! This is the numpad.
|
||||
|
||||
Keyboard Maintainer: [Yiancar](https://github.com/yiancar)
|
||||
Hardware Supported: Runs on an atmega32u4
|
||||
|
@@ -71,4 +71,7 @@ AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
NO_USB_STARTUP_CHECK = yes # Disable initialization only when usb is plugged in
|
||||
CUSTOM_MATRIX = yes # Use custom matrix
|
||||
CUSTOM_MATRIX = yes # Use custom matrix
|
||||
|
||||
# Community layouts supported
|
||||
LAYOUTS = numpad_5x4 ortho_5x4
|
||||
|
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"keyboard_name": "DC01 Right Half",
|
||||
"url": "",
|
||||
"maintainer": "qmk",
|
||||
"width": 8.5,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_ansi": {
|
||||
"layout": [{"label":"&", "x":0.5, "y":0}, {"label":"*", "x":1.5, "y":0}, {"label":"(", "x":2.5, "y":0}, {"label":")", "x":3.5, "y":0}, {"label":"_", "x":4.5, "y":0}, {"label":"+", "x":5.5, "y":0}, {"label":"Backspace", "x":6.5, "y":0, "w":2}, {"label":"Y", "x":0, "y":1}, {"label":"U", "x":1, "y":1}, {"label":"I", "x":2, "y":1}, {"label":"O", "x":3, "y":1}, {"label":"P", "x":4, "y":1}, {"label":"{", "x":5, "y":1}, {"label":"}", "x":6, "y":1}, {"label":"|", "x":7, "y":1, "w":1.5}, {"label":"H", "x":0.25, "y":2}, {"label":"J", "x":1.25, "y":2}, {"label":"K", "x":2.25, "y":2}, {"label":"L", "x":3.25, "y":2}, {"label":":", "x":4.25, "y":2}, {"label":"\"", "x":5.25, "y":2}, {"label":"Enter", "x":6.25, "y":2, "w":2.25}, {"label":"N", "x":0.75, "y":3}, {"label":"M", "x":1.75, "y":3}, {"label":"<", "x":2.75, "y":3}, {"label":">", "x":3.75, "y":3}, {"label":"?", "x":4.75, "y":3}, {"label":"Shift", "x":5.75, "y":3, "w":2.75}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":2.25}, {"label":"Alt", "x":3.5, "y":4, "w":1.25}, {"label":"GUI", "x":4.75, "y":4, "w":1.25}, {"label":"Menu", "x":6, "y":4, "w":1.25}, {"label":"Ctrl", "x":7.25, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_iso": {
|
||||
"layout": [{"label":"&", "x":0.5, "y":0}, {"label":"*", "x":1.5, "y":0}, {"label":"(", "x":2.5, "y":0}, {"label":")", "x":3.5, "y":0}, {"label":"_", "x":4.5, "y":0}, {"label":"+", "x":5.5, "y":0}, {"label":"Backspace", "x":6.5, "y":0, "w":2}, {"label":"Y", "x":0, "y":1}, {"label":"U", "x":1, "y":1}, {"label":"I", "x":2, "y":1}, {"label":"O", "x":3, "y":1}, {"label":"P", "x":4, "y":1}, {"label":"{", "x":5, "y":1}, {"label":"}", "x":6, "y":1}, {"label":"H", "x":0.25, "y":2}, {"label":"J", "x":1.25, "y":2}, {"label":"K", "x":2.25, "y":2}, {"label":"L", "x":3.25, "y":2}, {"label":":", "x":4.25, "y":2}, {"label":"@", "x":5.25, "y":2}, {"label":"~", "x":6.25, "y":2}, {"label":"Enter", "x":7.25, "y":1, "w":1.25, "h":2}, {"label":"N", "x":0.75, "y":3}, {"label":"M", "x":1.75, "y":3}, {"label":"<", "x":2.75, "y":3}, {"label":">", "x":3.75, "y":3}, {"label":"?", "x":4.75, "y":3}, {"label":"Shift", "x":5.75, "y":3, "w":2.75}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":2.25}, {"label":"AltGr", "x":3.5, "y":4, "w":1.25}, {"label":"GUI", "x":4.75, "y":4, "w":1.25}, {"label":"Menu", "x":6, "y":4, "w":1.25}, {"label":"Ctrl", "x":7.25, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_hhkb_ansi": {
|
||||
"layout": [{"label":"&", "x":0.5, "y":0}, {"label":"*", "x":1.5, "y":0}, {"label":"(", "x":2.5, "y":0}, {"label":")", "x":3.5, "y":0}, {"label":"_", "x":4.5, "y":0}, {"label":"+", "x":5.5, "y":0}, {"label":"Backspace", "x":6.5, "y":0}, {"label":"~", "x":7.5, "y":0}, {"label":"Y", "x":0, "y":1}, {"label":"U", "x":1, "y":1}, {"label":"I", "x":2, "y":1}, {"label":"O", "x":3, "y":1}, {"label":"P", "x":4, "y":1}, {"label":"{", "x":5, "y":1}, {"label":"}", "x":6, "y":1}, {"label":"|", "x":7, "y":1, "w":1.5}, {"label":"H", "x":0.25, "y":2}, {"label":"J", "x":1.25, "y":2}, {"label":"K", "x":2.25, "y":2}, {"label":"L", "x":3.25, "y":2}, {"label":":", "x":4.25, "y":2}, {"label":"\"", "x":5.25, "y":2}, {"label":"Enter", "x":6.25, "y":2, "w":2.25}, {"label":"N", "x":0.75, "y":3}, {"label":"M", "x":1.75, "y":3}, {"label":"<", "x":2.75, "y":3}, {"label":">", "x":3.75, "y":3}, {"label":"?", "x":4.75, "y":3}, {"label":"Shift", "x":5.75, "y":3, "w":1.75}, {"label":"Fn", "x":7.5, "y":3}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":2.25}, {"label":"Alt", "x":3.5, "y":4, "w":1.25}, {"label":"GUI", "x":4.75, "y":4, "w":1.25}, {"label":"Menu", "x":6, "y":4, "w":1.25}, {"label":"Ctrl", "x":7.25, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_hhkb_iso": {
|
||||
"layout": [{"label":"&", "x":0.5, "y":0}, {"label":"*", "x":1.5, "y":0}, {"label":"(", "x":2.5, "y":0}, {"label":")", "x":3.5, "y":0}, {"label":"_", "x":4.5, "y":0}, {"label":"+", "x":5.5, "y":0}, {"label":"|", "x":6.5, "y":0}, {"label":"Backspace", "x":7.5, "y":0}, {"label":"Y", "x":0, "y":1}, {"label":"U", "x":1, "y":1}, {"label":"I", "x":2, "y":1}, {"label":"O", "x":3, "y":1}, {"label":"P", "x":4, "y":1}, {"label":"{", "x":5, "y":1}, {"label":"}", "x":6, "y":1}, {"label":"H", "x":0.25, "y":2}, {"label":"J", "x":1.25, "y":2}, {"label":"K", "x":2.25, "y":2}, {"label":"L", "x":3.25, "y":2}, {"label":":", "x":4.25, "y":2}, {"label":"@", "x":5.25, "y":2}, {"label":"~", "x":6.25, "y":2}, {"label":"Enter", "x":7.25, "y":1, "w":1.25, "h":2}, {"label":"N", "x":0.75, "y":3}, {"label":"M", "x":1.75, "y":3}, {"label":"<", "x":2.75, "y":3}, {"label":">", "x":3.75, "y":3}, {"label":"?", "x":4.75, "y":3}, {"label":"Shift", "x":5.75, "y":3, "w":1.75}, {"label":"Fn", "x":7.5, "y":3}, {"x":0, "y":4, "w":1.25}, {"x":1.25, "y":4, "w":2.25}, {"label":"AltGr", "x":3.5, "y":4, "w":1.25}, {"label":"GUI", "x":4.75, "y":4, "w":1.25}, {"label":"Menu", "x":6, "y":4, "w":1.25}, {"label":"Ctrl", "x":7.25, "y":4, "w":1.25}]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_ANSI( /* Base */
|
||||
[0] = LAYOUT_ansi( /* Base */
|
||||
KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, \
|
||||
KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC,KC_BSLS, \
|
||||
KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT, KC_ENT, \
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_HHKB_ANSI( /* Base */
|
||||
[0] = LAYOUT_hhkb_ansi( /* Base */
|
||||
KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, KC_GRV, \
|
||||
KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC,KC_BSPC, \
|
||||
KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT, KC_ENT, \
|
||||
@@ -24,12 +24,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_SPC, KC_SPC, KC_RALT, KC_RGUI, KC_RGUI, KC_RCTL \
|
||||
),
|
||||
|
||||
[1] = LAYOUT_HHKB_ANSI(
|
||||
[1] = LAYOUT_hhkb_ansi(
|
||||
KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL, \
|
||||
KC_TRNS,KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, KC_BSPC, \
|
||||
KC_PAST,KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_PENT, \
|
||||
KC_PPLS,KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS \
|
||||
),
|
||||
};
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_HHKB_ISO( /* Base */
|
||||
[0] = LAYOUT_hhkb_iso( /* Base */
|
||||
KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, KC_BSPC, \
|
||||
KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, \
|
||||
KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT, KC_NUHS,KC_ENT, \
|
||||
@@ -24,12 +24,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_SPC, KC_SPC, KC_RALT, KC_RGUI, KC_RGUI, KC_RCTL \
|
||||
),
|
||||
|
||||
[1] = LAYOUT_HHKB_ISO(
|
||||
[1] = LAYOUT_hhkb_iso(
|
||||
KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL, \
|
||||
KC_TRNS,KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, \
|
||||
KC_PAST,KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_TRNS, KC_PENT, \
|
||||
KC_PPLS,KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, \
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS \
|
||||
),
|
||||
};
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[0] = LAYOUT_ISO( /* Base */
|
||||
[0] = LAYOUT_iso( /* Base */
|
||||
KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, \
|
||||
KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, \
|
||||
KC_H, KC_J, KC_K, KC_L, KC_SCLN,KC_QUOT, KC_NUHS,KC_ENT, \
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||

|
||||
|
||||
A hotpluggable four part keyboard which comes together with magnets and pogo pins! This is the right part
|
||||
A hotpluggable four part keyboard which comes together with magnets and pogo pins! This is the right part.
|
||||
|
||||
Keyboard Maintainer: [Yiancar](https://github.com/yiancar)
|
||||
Hardware Supported: Runs on an atmega32u4
|
||||
|
@@ -23,7 +23,7 @@
|
||||
// This a shortcut to help you visually see your layout.
|
||||
// The first section contains all of the arguments
|
||||
// The second converts the arguments into a two-dimensional array
|
||||
#define LAYOUT_ANSI( \
|
||||
#define LAYOUT_ansi( \
|
||||
K01, K02, K03, K04, K05, K06, K07, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, \
|
||||
K20, K21, K22, K23, K24, K25, K27, \
|
||||
@@ -38,7 +38,7 @@
|
||||
{ K40, K41, K42, K43, K44, K45, XXX, XXX } \
|
||||
}
|
||||
|
||||
#define LAYOUT_ISO( \
|
||||
#define LAYOUT_iso( \
|
||||
K01, K02, K03, K04, K05, K06, K07, \
|
||||
K10, K11, K12, K13, K14, K15, K16, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, \
|
||||
@@ -53,7 +53,7 @@
|
||||
{ K40, K41, K42, K43, K44, K45, XXX, XXX } \
|
||||
}
|
||||
|
||||
#define LAYOUT_HHKB_ANSI( \
|
||||
#define LAYOUT_hhkb_ansi( \
|
||||
K01, K02, K03, K04, K05, K06, K07, K00, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, \
|
||||
K20, K21, K22, K23, K24, K25, K27, \
|
||||
@@ -68,7 +68,7 @@
|
||||
{ K40, K41, K42, K43, K44, K45, XXX, XXX } \
|
||||
}
|
||||
|
||||
#define LAYOUT_HHKB_ISO( \
|
||||
#define LAYOUT_hhkb_iso( \
|
||||
K01, K02, K03, K04, K05, K06, K07, K00, \
|
||||
K10, K11, K12, K13, K14, K15, K16, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, \
|
||||
|
@@ -22,7 +22,13 @@ void led_init_ports(void) {
|
||||
}
|
||||
|
||||
void led_set_kb(uint8_t usb_led) {
|
||||
// Code for caps lock LED as reported by the OS
|
||||
// Set this per keymap, instead of globally
|
||||
led_set_user(usb_led);
|
||||
if (usb_led & (1 << USB_LED_CAPS_LOCK)) {
|
||||
DDRB |= (1 << 2);
|
||||
PORTB &= ~(1 << 2);
|
||||
} else {
|
||||
DDRB &= ~(1 << 2);
|
||||
PORTB &= ~(1 << 2);
|
||||
}
|
||||
|
||||
led_set_user(usb_led);
|
||||
}
|
||||
|
@@ -49,6 +49,20 @@
|
||||
{ KC_NO, K401, KC_NO, K403, KC_NO, KC_NO, K406, KC_NO, KC_NO, KC_NO, K410, K411, KC_NO, KC_NO, KC_NO } \
|
||||
}
|
||||
|
||||
#define LAYOUT_60_hhkb( \
|
||||
K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, \
|
||||
K100, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114, \
|
||||
K200, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K213, \
|
||||
K300, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, K313, K314, \
|
||||
K401, K403, K406, K411, K413 \
|
||||
) { \
|
||||
{ K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014 }, \
|
||||
{ K100, KC_NO, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114 }, \
|
||||
{ K200, KC_NO, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, K213, KC_NO }, \
|
||||
{ K300, KC_NO, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311, KC_NO, K313, K314 }, \
|
||||
{ KC_NO, K401, KC_NO, K403, KC_NO, KC_NO, K406, KC_NO, KC_NO, KC_NO, KC_NO, K411, KC_NO, K413, KC_NO } \
|
||||
}
|
||||
|
||||
#define LAYOUT_2_shifts( \
|
||||
K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, K013, K014, \
|
||||
K100, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, K112, K113, K114, \
|
||||
|
@@ -37,6 +37,10 @@
|
||||
"key_count": 62,
|
||||
"layout": [{"label":"¬", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"\"", "x":2, "y":0}, {"label":"£", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"CapsLock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"@", "x":11.75, "y":2}, {"label":"~", "x":12.75, "y":2}, {"label":"Enter", "x":13.75, "y":1, "w":1.25, "h":2}, {"label":"Shift", "x":0, "y":3, "w":1.25}, {"label":"|", "x":1.25, "y":3}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":2.75}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"AltGr", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_60_hhkb": {
|
||||
"key_count": 60,
|
||||
"layout": [{"label":"Esc", "x":0, "y":0}, {"label":"1", "x":1, "y":0}, {"label":"2", "x":2, "y":0}, {"label":"3", "x":3, "y":0}, {"label":"4", "x":4, "y":0}, {"label":"5", "x":5, "y":0}, {"label":"6", "x":6, "y":0}, {"label":"7", "x":7, "y":0}, {"label":"8", "x":8, "y":0}, {"label":"9", "x":9, "y":0}, {"label":"0", "x":10, "y":0}, {"label":"-", "x":11, "y":0}, {"label":"=", "x":12, "y":0}, {"label":"\\", "x":13, "y":0}, {"label":"`", "x":14, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"[", "x":11.5, "y":1}, {"label":"]", "x":12.5, "y":1}, {"label":"Backspace", "x":13.5, "y":1, "w":1.5}, {"label":"Control", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":";", "x":10.75, "y":2}, {"label":"'", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":",", "x":9.25, "y":3}, {"label":".", "x":10.25, "y":3}, {"label":"/", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"label":"Fn", "x":14, "y":3}, {"label":"Os", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Os", "x":12.5, "y":4}]
|
||||
},
|
||||
"LAYOUT_directional_625_space": {
|
||||
"key_count": 65,
|
||||
"layout": [{"label":"K000", "x":0, "y":0}, {"label":"K001", "x":1, "y":0}, {"label":"K002", "x":2, "y":0}, {"label":"K003", "x":3, "y":0}, {"label":"K004", "x":4, "y":0}, {"label":"K005", "x":5, "y":0}, {"label":"K006", "x":6, "y":0}, {"label":"K007", "x":7, "y":0}, {"label":"K008", "x":8, "y":0}, {"label":"K009", "x":9, "y":0}, {"label":"K010", "x":10, "y":0}, {"label":"K011", "x":11, "y":0}, {"label":"K012", "x":12, "y":0}, {"label":"K013", "x":13, "y":0}, {"label":"K014", "x":14, "y":0}, {"label":"K100", "x":0, "y":1, "w":1.5}, {"label":"K102", "x":1.5, "y":1}, {"label":"K103", "x":2.5, "y":1}, {"label":"K104", "x":3.5, "y":1}, {"label":"K105", "x":4.5, "y":1}, {"label":"K106", "x":5.5, "y":1}, {"label":"K107", "x":6.5, "y":1}, {"label":"K108", "x":7.5, "y":1}, {"label":"K109", "x":8.5, "y":1}, {"label":"K110", "x":9.5, "y":1}, {"label":"K111", "x":10.5, "y":1}, {"label":"K112", "x":11.5, "y":1}, {"label":"K113", "x":12.5, "y":1}, {"label":"K114", "x":13.5, "y":1, "w":1.5}, {"label":"K200", "x":0, "y":2, "w":1.75}, {"label":"K202", "x":1.75, "y":2}, {"label":"K203", "x":2.75, "y":2}, {"label":"K204", "x":3.75, "y":2}, {"label":"K205", "x":4.75, "y":2}, {"label":"K206", "x":5.75, "y":2}, {"label":"K207", "x":6.75, "y":2}, {"label":"K208", "x":7.75, "y":2}, {"label":"K209", "x":8.75, "y":2}, {"label":"K210", "x":9.75, "y":2}, {"label":"K211", "x":10.75, "y":2}, {"label":"K212", "x":11.75, "y":2}, {"label":"K213", "x":12.75, "y":2, "w":2.25}, {"label":"K300", "x":0, "y":3, "w":2}, {"label":"K301", "x":2, "y":3}, {"label":"K302", "x":3, "y":3}, {"label":"K303", "x":4, "y":3}, {"label":"K304", "x":5, "y":3}, {"label":"K305", "x":6, "y":3}, {"label":"K306", "x":7, "y":3}, {"label":"K307", "x":8, "y":3}, {"label":"K308", "x":9, "y":3}, {"label":"K309", "x":10, "y":3}, {"label":"K310", "x":11, "y":3}, {"label":"K312", "x":12, "y":3}, {"label":"K313", "x":13, "y":3}, {"label":"K314", "x":14, "y":3}, {"label":"K400", "x":0, "y":4, "w":1.25}, {"label":"K401", "x":1.25, "y":4, "w":1.25}, {"label":"K403", "x":2.5, "y":4, "w":1.25}, {"label":"K406", "x":3.75, "y":4, "w":6.25}, {"label":"K410", "x":10, "y":4}, {"label":"K411", "x":11, "y":4}, {"label":"K412", "x":12, "y":4}, {"label":"K413", "x":13, "y":4}, {"label":"K414", "x":14, "y":4}]
|
||||
|
@@ -59,11 +59,3 @@ void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led) {
|
||||
if (usb_led & (1 << USB_LED_CAPS_LOCK)) {
|
||||
DDRB |= (1 << 2); PORTB &= ~(1 << 2);
|
||||
} else {
|
||||
DDRB &= ~(1 << 2); PORTB &= ~(1 << 2);
|
||||
}
|
||||
}
|
||||
|
@@ -84,11 +84,3 @@ void action_function(keyrecord_t *record, uint8_t id, uint8_t opt) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void led_set_user(uint8_t usb_led) {
|
||||
if (usb_led & (1 << USB_LED_CAPS_LOCK)) {
|
||||
DDRB |= (1 << 2); PORTB &= ~(1 << 2);
|
||||
} else {
|
||||
DDRB &= ~(1 << 2); PORTB &= ~(1 << 2);
|
||||
}
|
||||
}
|
||||
|
2
keyboards/dz60/keymaps/krusli/config.h
Normal file
2
keyboards/dz60/keymaps/krusli/config.h
Normal file
@@ -0,0 +1,2 @@
|
||||
#pragma once
|
||||
#define USB_MAX_POWER_CONSUMPTION 100
|
21
keyboards/dz60/keymaps/krusli/keymap.c
Normal file
21
keyboards/dz60/keymaps/krusli/keymap.c
Normal file
@@ -0,0 +1,21 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
#define MODS_CTRL_MASK (MOD_BIT(KC_LSHIFT)|MOD_BIT(KC_RSHIFT))
|
||||
#define _______ KC_TRNS
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
LAYOUT(
|
||||
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, KC_GRV,
|
||||
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSPC,
|
||||
KC_LCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
|
||||
KC_LSFT, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1),
|
||||
KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_SPC, KC_SPC, KC_RGUI, KC_RALT, KC_APP, KC_APP, KC_RCTL),
|
||||
|
||||
LAYOUT(
|
||||
KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_INS, KC_DEL,
|
||||
KC_CAPS, RGB_TOG, RGB_MOD, RGB_HUI, RGB_VAD, RGB_VAI, RGB_SAD, RGB_SAI, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, _______, RESET,
|
||||
_______, KC_VOLD, KC_VOLU, KC_MUTE, _______, _______, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, _______,
|
||||
_______, KC_NO, _______, _______, _______, _______, _______, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, _______, _______,
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______)
|
||||
};
|
15
keyboards/dz60/keymaps/krusli/rules.mk
Normal file
15
keyboards/dz60/keymaps/krusli/rules.mk
Normal file
@@ -0,0 +1,15 @@
|
||||
# Build Options
|
||||
# comment out to disable the options.
|
||||
#
|
||||
BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
NKRO_ENABLE = yes # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
|
||||
AUDIO_ENABLE = no
|
||||
RGBLIGHT_ENABLE = yes
|
||||
|
||||
LAYOUTS = 60_ansi
|
@@ -33,7 +33,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
/* ,-----------------------------------------------------------------------------------------.
|
||||
* | ` | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Del |
|
||||
* |-----------------------------------------------------------------------------------------+
|
||||
* | | | | | | | | | UP | | | | | Reset |
|
||||
* | | | | | | | | | UP | | | | | |
|
||||
* |-----------------------------------------------------------------------------------------+
|
||||
* | | | | | | | | Left| Down|Right| | | |
|
||||
* |-----------------------------------------------------------------------------------------+
|
||||
@@ -44,15 +44,15 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
*/
|
||||
[_FL] = LAYOUT(
|
||||
KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, ______, KC_DEL,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, KC_UP, ______, ______, ______, ______, RESET,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, KC_UP, ______, ______, ______, ______, ______,
|
||||
______, ______, ______, ______, ______, ______, ______, KC_LEFT, KC_DOWN, KC_RIGHT, ______, ______, ______,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______),
|
||||
|
||||
/* ,-----------------------------------------------------------------------------------------.
|
||||
* | | BR- | BR+ | F3 | F4 | | |PREV |PLAY |NEXT |MUTE | V- | V+ | Eject |
|
||||
* |Eject| BR- | BR+ | F3 | F4 | | |PREV |PLAY |NEXT |MUTE | V- | V+ | |
|
||||
* |-----------------------------------------------------------------------------------------+
|
||||
* | | | | | | | | | | | | | | |
|
||||
* | | | | | | | | | | | | | | Reset |
|
||||
* |-----------------------------------------------------------------------------------------+
|
||||
* | | | | | | | | | | | | | |
|
||||
* |-----------------------------------------------------------------------------------------+
|
||||
@@ -62,8 +62,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* `-----------------------------------------------------------------------------------------'
|
||||
*/
|
||||
[_ML] = LAYOUT(
|
||||
______, BR_DOWN, BR_UP, ______, ______, KC_F5, KC_F6, KC_MEDIA_PREV_TRACK, KC_MEDIA_PLAY_PAUSE, KC_MEDIA_NEXT_TRACK, KC_AUDIO_MUTE, KC_AUDIO_VOL_DOWN, KC_AUDIO_VOL_UP, ______, KC_MEDIA_EJECT,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______,
|
||||
KC_MEDIA_EJECT, BR_DOWN, BR_UP, ______, ______, KC_F5, KC_F6, KC_MEDIA_PREV_TRACK, KC_MEDIA_PLAY_PAUSE, KC_MEDIA_NEXT_TRACK, KC_AUDIO_MUTE, KC_AUDIO_VOL_DOWN, KC_AUDIO_VOL_UP, ______, ______,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, RESET,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______,
|
||||
______, ______, ______, ______, ______, ______, ______, ______, ______, ______, ______),
|
||||
|
@@ -37,7 +37,7 @@ My build used the following components:
|
||||
,-----------------------------------------------------------------------------------------.
|
||||
| ` | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | Del |
|
||||
|-----------------------------------------------------------------------------------------+
|
||||
| | | | | | | | | UP | | | | | Reset |
|
||||
| | | | | | | | | UP | | | | | |
|
||||
|-----------------------------------------------------------------------------------------+
|
||||
| | | | | | | | Left| Down|Right| | | |
|
||||
|-----------------------------------------------------------------------------------------+
|
||||
@@ -55,7 +55,7 @@ The function layer is activated by the `Caps-Lock` (`Hyper`) key to access `F` k
|
||||
,-----------------------------------------------------------------------------------------.
|
||||
| | BR- | BR+ | F3 | F4 | | |PREV |PLAY |NEXT |MUTE | V- | V+ | Eject |
|
||||
|-----------------------------------------------------------------------------------------+
|
||||
| | | | | | | | | | | | | | |
|
||||
| | | | | | | | | | | | | | Reset |
|
||||
|-----------------------------------------------------------------------------------------+
|
||||
| | | | | | | | | | | | | |
|
||||
|-----------------------------------------------------------------------------------------+
|
||||
|
2
keyboards/dz60/keymaps/macos_arrow/rules.mk
Normal file
2
keyboards/dz60/keymaps/macos_arrow/rules.mk
Normal file
@@ -0,0 +1,2 @@
|
||||
BACKLIGHT_ENABLE = no
|
||||
RGBLIGHT_ENABLE = no
|
@@ -55,4 +55,4 @@ BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
|
||||
AUDIO_ENABLE = no
|
||||
RGBLIGHT_ENABLE = yes
|
||||
|
||||
LAYOUTS = 60_ansi 60_iso
|
||||
LAYOUTS = 60_ansi 60_iso 60_hhkb
|
||||
|
@@ -1 +0,0 @@
|
||||
#include "e6v2.h"
|
@@ -1,14 +0,0 @@
|
||||
#ifndef E6V2_H
|
||||
#define E6V2_H
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
#ifdef KEYBOARD_e6v2_oe
|
||||
#include "oe.h"
|
||||
#endif
|
||||
|
||||
#ifdef KEYBOARD_e6v2_le
|
||||
#include "le.h"
|
||||
#endif
|
||||
|
||||
#endif
|
@@ -7,6 +7,10 @@
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"x":0, "y":3}, {"x":1, "y":3}, {"label":"Z", "x":2, "y":3}, {"label":"X", "x":3, "y":3}, {"label":"C", "x":4, "y":3}, {"label":"V", "x":5, "y":3}, {"label":"B", "x":6, "y":3}, {"label":"N", "x":7, "y":3}, {"label":"M", "x":8, "y":3}, {"label":"<", "x":9, "y":3}, {"label":">", "x":10, "y":3}, {"label":"?", "x":11, "y":3}, {"x":12, "y":3}, {"x":13, "y":3}, {"x":14, "y":3}, {"x":0, "y":4, "w":1.75}, {"label":"Ctrl", "x":1.75, "y":4, "w":1.25}, {"label":"Win", "x":3, "y":4, "w":1.25}, {"label":"Alt", "x":4.25, "y":4, "w":1.25}, {"x":5.5, "y":4, "w":2.75}, {"x":8.25, "y":4, "w":1.75}, {"x":10, "y":4}, {"label":"Alt", "x":11, "y":4}, {"label":"Win", "x":12, "y":4}, {"label":"Menu", "x":13, "y":4}, {"label":"Ctrl", "x":14, "y":4}]
|
||||
},
|
||||
|
||||
"LAYOUT_60_ansi": {
|
||||
"layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":2.75}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"Alt", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}]
|
||||
}
|
||||
}
|
||||
}
|
@@ -21,24 +21,13 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
|
||||
return process_record_user(keycode, record);
|
||||
}
|
||||
|
||||
void led_set_kb(uint8_t usb_led) {
|
||||
// put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
|
||||
DDRB |= (1<<7);
|
||||
if (usb_led & (1<<USB_LED_CAPS_LOCK)) {
|
||||
// output low
|
||||
DDRB |= (1<<2);
|
||||
PORTB &= ~(1<<2);
|
||||
} else {
|
||||
// Hi-Z
|
||||
DDRB &= ~(1<<2);
|
||||
PORTB &= ~(1<<2);
|
||||
}
|
||||
if (usb_led == 0){
|
||||
PORTB |= (1<<7);
|
||||
void led_set_user(uint8_t usb_led) {
|
||||
if (usb_led & (1 << USB_LED_CAPS_LOCK)) {
|
||||
DDRB |= (1 << 7);
|
||||
PORTB &= ~(1 << 7);
|
||||
} else {
|
||||
DDRB &= ~(1 << 7);
|
||||
PORTB &= ~(1 << 7);
|
||||
}
|
||||
else{
|
||||
PORTB &= ~(1<<7);
|
||||
}
|
||||
|
||||
led_set_user(usb_led);
|
||||
}
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#ifndef LE_H
|
||||
#define LE_H
|
||||
|
||||
#include "../e6v2.h"
|
||||
#include "quantum.h"
|
||||
|
||||
#define LAYOUT( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0E, K0D, \
|
||||
@@ -18,4 +18,19 @@
|
||||
{ K40, KC_NO, K42, K43, K44, KC_NO, KC_NO, K47, KC_NO, K49, K4A, K4B, K4C, K4D, K4E }, \
|
||||
}
|
||||
|
||||
#endif
|
||||
#define LAYOUT_60_ansi( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
|
||||
K10, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \
|
||||
K20, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, \
|
||||
K40, K42, K43, K47, K4A, K4B, K4D, K4E \
|
||||
)\
|
||||
{\
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, KC_NO }, \
|
||||
{ K10, KC_NO, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \
|
||||
{ K20, KC_NO, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, KC_NO }, \
|
||||
{ K30, KC_NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, KC_NO, K3D, KC_NO }, \
|
||||
{ K40, KC_NO, K42, K43, KC_NO, KC_NO, KC_NO, K47, KC_NO, KC_NO, K4A, K4B, KC_NO, K4D, K4E }, \
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@@ -1,10 +1,12 @@
|
||||
# E6-V2 Last Edition (LE)
|
||||
|
||||
These docs are for the QMK version of the PCB. [More info on qmk.fm](http://qmk.fm/)
|
||||
These docs are for the QMK version of the E6-V2 PCB. [More info on qmk.fm](http://qmk.fm/)
|
||||
|
||||
Keyboard Maintainer: [MechMerlin](https://github.com/mechmerlin)
|
||||
Hardware Supported: E6-V2 LE Mid Port rev.qmk
|
||||
Hardware Availability: [geekhack.org/index.php?topic=90787.0](https://geekhack.org/index.php?topic=90787.0)
|
||||
Keyboard Maintainer: [MechMerlin](https://github.com/mechmerlin)
|
||||
Hardware Supported: E6-V2 LE Mid Port rev.qmk
|
||||
Hardware Availability: [geekhack.org/index.php?topic=90787.0](https://geekhack.org/index.php?topic=90787.0)
|
||||
|
||||
**Please do not flash LE firmware on OE hardware.**
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
|
@@ -66,3 +66,5 @@ MIDI_ENABLE = no # MIDI controls
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
|
||||
LAYOUTS = 60_ansi
|
@@ -1,7 +1,7 @@
|
||||
#ifndef OE_H
|
||||
#define OE_H
|
||||
|
||||
#include "../e6v2.h"
|
||||
#include "quantum.h"
|
||||
|
||||
#define LAYOUT( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \
|
||||
|
@@ -1,10 +1,12 @@
|
||||
# E6-V2 Original Edition (OE)
|
||||
|
||||
These docs are for the QMK version of the PCB. [More info on qmk.fm](http://qmk.fm/)
|
||||
These docs are for the QMK version of the E6-V2 PCB. [More info on qmk.fm](http://qmk.fm/)
|
||||
|
||||
Keyboard Maintainer: [amnesia0287](https://github.com/amnesia0287)
|
||||
Hardware Supported: E6-V2 OE Mid Port rev.qmk
|
||||
Hardware Availability: [geekhack.org/index.php?topic=90787.0](https://geekhack.org/index.php?topic=90787.0)
|
||||
Keyboard Maintainer: [amnesia0287](https://github.com/amnesia0287)
|
||||
Hardware Supported: E6-V2 OE Mid Port rev.qmk
|
||||
Hardware Availability: [geekhack.org/index.php?topic=90787.0](https://geekhack.org/index.php?topic=90787.0)
|
||||
|
||||
**Please do not flash OE firmware on LE hardware.**
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
|
@@ -1,9 +1,20 @@
|
||||
# E6-V2
|
||||
|
||||
These docs are for the QMK version of the PCB. [More info on qmk.fm](http://qmk.fm/)
|
||||
The E6-V2 is a 60% keyboard manufactured by Exclusive.
|
||||
|
||||
### Round 1:
|
||||
- ps2avrGB PCB and QMK powered PCB option (OE PCB)
|
||||
- Center mount and side mount USB
|
||||
|
||||
### Round 2
|
||||
- ps2avrGB PCB and QMK powered PCB option (LE PCB)
|
||||
- Only center mount USB offered
|
||||
- All brass option
|
||||
|
||||
These docs are for the QMK version of the E6-V2 PCB. [More info on qmk.fm](http://qmk.fm/)
|
||||
|
||||
The E6V2 has been available with either a bootmapper client or QMK powered PCB. During the second round, the QMK powered PCB was redesigned and used different ports and a different switch matrix.
|
||||
|
||||
Please use the appropriate version when making your firmware.
|
||||
Please use the appropriate version when making your firmware. Flashing one in place of the other, can brick your PCB. Please be certain whether you have a OE or LE PCB.
|
||||
|
||||
See [build environment setup](https://docs.qmk.fm/build_environment_setup.html) then the [make instructions](https://docs.qmk.fm/make_instructions.html) for more information.
|
||||
|
@@ -1 +0,0 @@
|
||||
DEFAULT_FOLDER = e6v2/oe
|
43
keyboards/ergo42/keymaps/default-underglow/config.h
Normal file
43
keyboards/ergo42/keymaps/default-underglow/config.h
Normal file
@@ -0,0 +1,43 @@
|
||||
/*
|
||||
This is the c configuration file for the keymap
|
||||
|
||||
Copyright 2012 Jun Wako <wakojun@gmail.com>
|
||||
Copyright 2015 Jack Humbert
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef CONFIG_USER_H
|
||||
#define CONFIG_USER_H
|
||||
|
||||
#include "../../config.h"
|
||||
|
||||
/* Use I2C or Serial, not both */
|
||||
|
||||
#define USE_SERIAL
|
||||
// #define USE_I2C
|
||||
|
||||
/* Select hand configuration */
|
||||
|
||||
#define MASTER_LEFT
|
||||
// #define MASTER_RIGHT
|
||||
// #define EE_HANDS
|
||||
|
||||
// Underglow
|
||||
#undef RGBLED_NUM
|
||||
#define RGBLED_NUM 14 // Number of LEDs
|
||||
#define RGBLIGHT_ANIMATIONS
|
||||
#define RGBLIGHT_SLEEP
|
||||
|
||||
#endif
|
133
keyboards/ergo42/keymaps/default-underglow/keymap.c
Normal file
133
keyboards/ergo42/keymaps/default-underglow/keymap.c
Normal file
@@ -0,0 +1,133 @@
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
extern keymap_config_t keymap_config;
|
||||
|
||||
#define BASE 0
|
||||
#define META 1
|
||||
#define SYMB 2
|
||||
#define GAME 3
|
||||
#define RGB 4
|
||||
|
||||
// Fillers to make layering more clear
|
||||
#define _______ KC_TRNS
|
||||
#define XXXXXXX KC_NO
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
//Following line allows macro to read current RGB settings
|
||||
extern rgblight_config_t rgblight_config;
|
||||
#endif
|
||||
|
||||
enum custom_keycodes {
|
||||
RGB_RST = SAFE_RANGE,
|
||||
TAP_ANIM
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
/* BASE
|
||||
* ,------------------------------------------------. ,------------------------------------------------.
|
||||
* | ESC | Tab | Q | W | E | R | T | | Y | U | I | O | P | [ | Bksp |
|
||||
* |------+------+------+------+------+------+------| |-------------+------+------+------+------+------|
|
||||
* | Del | RCtrl| A | S | D | F | G | | H | J | K | L | ; | ] | Enter|
|
||||
* |------+------+------+------+------+------+------| |------|------+------+------+------+------+------|
|
||||
* | RGB | LSft | Z | X | C | V | B | | N | M | , | . | / | UP | RSft |
|
||||
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
|
||||
* | META | LCtrl| ` | \ | LAlt | LGUI |Space | |Space | ' | - | = | LEFT | DOWN | RIGHT|
|
||||
* `------------------------------------------------' `------------------------------------------------'
|
||||
*/
|
||||
[BASE] = LAYOUT( \
|
||||
KC_ESC, KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_BSPC, \
|
||||
KC_DELT, KC_RCTL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_RBRC, KC_ENT, \
|
||||
MO(RGB), KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_UP, KC_RSFT, \
|
||||
MO(META), KC_LCTL, KC_GRV, KC_BSLS, KC_LALT, KC_LGUI, KC_SPC, KC_SPC, KC_QUOT, KC_MINS, KC_EQL, KC_LEFT, KC_DOWN, KC_RGHT \
|
||||
),
|
||||
|
||||
/* META
|
||||
* ,------------------------------------------------. ,------------------------------------------------.
|
||||
* | Reset| 1 | 2 | 3 | 4 | 5 | [ | | ] | 6 | 7 | 8 | 9 | 0 | Bksp |
|
||||
* |------+------+------+------+------+------+------| |-------------+------+------+------+------+------|
|
||||
* | Del | F1 | |Muhen | Henk | | | | Left | Down | Up |Right | | | Enter|
|
||||
* |------+------+------+------+------+------+------| |------|------+------+------+------+------+------|
|
||||
* | RGB | F2 | F3 | F4 | F5 | F6 | { | | } | F7 | F8 | F9 | F10 | F11 | F12 |
|
||||
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
|
||||
* | META | LCtrl| ` | \ | LAlt | LGUI |Space | |Space | ' | - | = | | | |
|
||||
* `------------------------------------------------' `------------------------------------------------'
|
||||
*/
|
||||
[META] = LAYOUT( \
|
||||
RESET, KC_1, KC_2, KC_3, KC_4, KC_5, KC_LBRC, KC_RBRC, KC_6, KC_7, KC_8, KC_9, KC_0, _______, \
|
||||
_______, KC_F1, XXXXXXX, KC_MHEN, KC_HENK, XXXXXXX, XXXXXXX, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, XXXXXXX, XXXXXXX, _______, \
|
||||
_______, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, S(KC_LBRC), S(KC_RBRC), KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, \
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX \
|
||||
),
|
||||
|
||||
/* SYMB
|
||||
* ,------------------------------------------------. ,------------------------------------------------.
|
||||
* | ESC | ! | @ | # | $ | % | [ | | ] | ^ | & | * | ( | ) | Bksp |
|
||||
* |------+------+------+------+------+------+------| |-------------+------+------+------+------+------|
|
||||
* | Del | | | | | | ( | | ) | | | | | | Enter|
|
||||
* |------+------+------+------+------+------+------| |------|------+------+------+------+------+------|
|
||||
* | RGB | | | | | | { | | } | | | | | UP | Sft |
|
||||
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
|
||||
* | META | LCtrl| ` | \ | LAlt | LGUI |Space | |Space | ' | - | = | LEFT | DOWN | RIGHT|
|
||||
* `------------------------------------------------' `------------------------------------------------'
|
||||
*/
|
||||
[SYMB] = LAYOUT( \
|
||||
_______, S(KC_1), S(KC_2), S(KC_3), S(KC_4), S(KC_5), KC_LBRC, KC_RBRC, S(KC_6), S(KC_7), S(KC_8), S(KC_9), S(KC_0), _______, \
|
||||
_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, S(KC_9), S(KC_0), XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, \
|
||||
_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, S(KC_LBRC), S(KC_RBRC), XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, \
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ \
|
||||
),
|
||||
|
||||
/* RGB
|
||||
* ,------------------------------------------------. ,------------------------------------------------.
|
||||
* | | | | | | | | | | | | | | | |
|
||||
* |------+------+------+------+------+------+------| |-------------+------+------+------+------+------|
|
||||
* | | | | | | | | | | TOG | HUI | SAI | VAI |HUANIM| |
|
||||
* |------+------+------+------+------+------+------| |------|------+------+------+------+------+------|
|
||||
* | | | | | | | | | | MOD | HUD | SAD | VAD |RESET | |
|
||||
* |------+------+------+------+------+------+------| |------+------+------+------+------+------+------|
|
||||
* | | | | | | | | | | | | | |=>RGB | |
|
||||
* `------------------------------------------------' `------------------------------------------------'
|
||||
*/
|
||||
[RGB] = LAYOUT( \
|
||||
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, \
|
||||
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_TOG, RGB_HUI, RGB_SAI, RGB_VAI, TAP_ANIM,XXXXXXX, \
|
||||
_______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_MOD, RGB_HUI, RGB_SAD, RGB_VAD, RGB_RST, XXXXXXX, \
|
||||
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX \
|
||||
)
|
||||
|
||||
};
|
||||
|
||||
bool isTapAnim = false;
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case RGB_MOD:
|
||||
if (record->event.pressed) {
|
||||
isTapAnim = false;
|
||||
}
|
||||
break;
|
||||
case RGB_RST:
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
if (record->event.pressed) {
|
||||
eeconfig_update_rgblight_default();
|
||||
rgblight_enable();
|
||||
}
|
||||
#endif
|
||||
break;
|
||||
case TAP_ANIM:
|
||||
if (record->event.pressed) {
|
||||
isTapAnim = !isTapAnim;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
if (isTapAnim) {
|
||||
rgblight_mode_noeeprom(1);
|
||||
uint16_t hue = (rgblight_config.hue + 5) % 360;
|
||||
rgblight_sethsv_noeeprom(hue, rgblight_config.sat, rgblight_config.val);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
1
keyboards/ergo42/keymaps/default-underglow/rules.mk
Normal file
1
keyboards/ergo42/keymaps/default-underglow/rules.mk
Normal file
@@ -0,0 +1 @@
|
||||
RGBLIGHT_ENABLE = yes
|
146
keyboards/ergodox_ez/keymaps/bocaj/bocaj.h
Normal file
146
keyboards/ergodox_ez/keymaps/bocaj/bocaj.h
Normal file
@@ -0,0 +1,146 @@
|
||||
/*
|
||||
Copyright 2018 Jacob Jerrell <jacob.jerrell@gmail.com>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
// Layers
|
||||
enum layers {
|
||||
_SWRKMN = 0,
|
||||
_HWRKMN,
|
||||
_LOWER,
|
||||
_RAISE,
|
||||
_ADJUST,
|
||||
_DIABLO
|
||||
};
|
||||
|
||||
|
||||
|
||||
enum custom_keycodes {
|
||||
KC_EPRM = SAFE_RANGE,
|
||||
KC_SWRK,
|
||||
KC_HWRK,
|
||||
KC_VRSN,
|
||||
JJ_COPY,
|
||||
JJ_PASTE,
|
||||
JJ_ARRW,
|
||||
MC_LOCK,
|
||||
KC_DIABLO_CLEAR,
|
||||
KC_NMPD
|
||||
// UC_FLIP
|
||||
};
|
||||
|
||||
// Space Cadet Hyper/Meh and [/]
|
||||
#define HYP_LBK ALL_T(KC_LBRACKET)
|
||||
#define MEH_RBK MEH_T(KC_RBRACKET)
|
||||
|
||||
#define KC_LWSP LT(_LOWER, KC_SPACE)
|
||||
#define KC_RSEN LT(_RAISE, KC_ENTER)
|
||||
#define KC_ADJS TT(_ADJUST)
|
||||
|
||||
#define XXXXXXX KC_NO
|
||||
#define _______ KC_TRNS
|
||||
|
||||
#ifdef TAP_DANCE_ENABLE
|
||||
enum {
|
||||
TD_D3_1 = 0,
|
||||
TD_D3_2,
|
||||
TD_D3_3,
|
||||
TD_D3_4
|
||||
};
|
||||
#endif // TAP_DANCE_ENABLE
|
||||
|
||||
// Custom Keycodes for Diablo 3 layer
|
||||
// But since TD() doesn't work when tap dance is disabled
|
||||
// We use custom codes here, so we can substitute the right stuff
|
||||
#ifdef TAP_DANCE_ENABLE
|
||||
#define KC_D3_1 TD(TD_D3_1)
|
||||
#define KC_D3_2 TD(TD_D3_2)
|
||||
#define KC_D3_3 TD(TD_D3_3)
|
||||
#define KC_D3_4 TD(TD_D3_4)
|
||||
#else // TAP_DANCE_ENABLE
|
||||
#define KC_D3_1 KC_1
|
||||
#define KC_D3_2 KC_2
|
||||
#define KC_D3_3 KC_3
|
||||
#define KC_D3_4 KC_4
|
||||
#endif // TAP_DANCE_ENABLE
|
||||
|
||||
//define diablo macro timer variables
|
||||
extern uint16_t diablo_timer[4];
|
||||
extern uint8_t diablo_times[];
|
||||
extern uint8_t diablo_key_time[4];
|
||||
|
||||
|
||||
void run_diablo_macro_check(void);
|
||||
|
||||
|
||||
#define LAYOUT_ergodox_pretty_wrapper(...) LAYOUT_ergodox_pretty(__VA_ARGS__)
|
||||
|
||||
/* Pretty Layout
|
||||
.---------------------------------------------. .---------------------------------------------.
|
||||
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | ! 8 | 9 | 10 | 11 | 12 | 13 | 14 |
|
||||
!-------+-----+-----+-----+-----+-------------! !-------+-----+-----+-----+-----+-----+-------!
|
||||
| 15 | 16 | 17 | 18 | 19 | 20 | 21 | ! 22 | 23 | 24 | 25 | 26 | 27 | 28 |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| 29 | 30 | 31 | 32 | 33 | 34 |-------! !-------! 35 | 36 | 37 | 38 | 39 | 40 |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| 41 | 42 | 43 | 44 | 45 | 46 | 47 | ! 48 | 49 | 50 | 51 | 52 | 53 | 54 |
|
||||
'-------+-----+-----+-----+-----+-------------' '-------------+-----+-----+-----+-----+-------'
|
||||
| 55 | 56 | 57 | 58 | 59 | .---------------. .---------------. ! 60 | 61 | 62 | 63 | 64 |
|
||||
'------------------------------' | 65 | 66 | ! 67 | 68 | '------------------------------'
|
||||
.-------+-------+-------! !-------+-------+-------.
|
||||
! ! | 69 | ! 70 | ! !
|
||||
! ! !-------! !-------! ! !
|
||||
| 71 | 72 | 73 | ! 74 | 75 | 76 |
|
||||
'-----------------------' '-----------------------'
|
||||
*/
|
||||
|
||||
#define ______________________NUMBER_LEFT________________________ KC_1, KC_2, KC_3, KC_4, KC_5
|
||||
#define ______________________NUMBER_RIGHT_______________________ KC_6, KC_7, KC_8, KC_9, KC_0
|
||||
|
||||
#define ______________________SPECIAL_LEFT_______________________ KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC
|
||||
#define ______________________SPECIAL_RIGHT______________________ KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN
|
||||
|
||||
#define _______________________FUNC_LEFT_________________________ KC_F1, KC_F2, KC_F3, KC_F4, KC_F5
|
||||
#define _______________________FUNC_RIGHT________________________ KC_F6, KC_F7, KC_F8, KC_F9, KC_F10
|
||||
|
||||
#define _________________________________________________________ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
|
||||
#define XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX KC_NO, KC_NO, KC_NO, KC_NO, KC_NO
|
||||
|
||||
#define _______________________SWORKMAN_L1_______________________ KC_Q, KC_W, KC_E, KC_R, KC_T
|
||||
#define _______________________SWORKMAN_L2_______________________ KC_A, SFT_T(KC_S), GUI_T(KC_D), ALT_T(KC_F), KC_G
|
||||
#define _______________________SWORKMAN_L3_______________________ CTL_T(KC_Z), KC_X, KC_C, KC_V, KC_B
|
||||
|
||||
#define _______________________SWORKMAN_R1_______________________ KC_Y, KC_U, KC_I, KC_O, KC_P
|
||||
#define _______________________SWORKMAN_R2_______________________ KC_H, ALT_T(KC_J), GUI_T(KC_K), SFT_T(KC_L), KC_SCLN
|
||||
#define _______________________SWORKMAN_R3_______________________ KC_N, KC_M, KC_COMM, KC_DOT, CTL_T(KC_SLASH)
|
||||
|
||||
// Hardware Driven Workman
|
||||
#define _______________________HWORKMAN_L1_______________________ KC_Q, KC_D, KC_R, KC_W, KC_B
|
||||
#define _______________________HWORKMAN_L2_______________________ KC_A, SFT_T(KC_S), GUI_T(KC_H), ALT_T(KC_T), KC_G
|
||||
#define _______________________HWORKMAN_L3_______________________ CTL_T(KC_Z), KC_X, KC_M, KC_C, KC_V
|
||||
|
||||
#define _______________________HWORKMAN_R1_______________________ KC_J, KC_F, KC_U, KC_P, KC_SCLN
|
||||
#define _______________________HWORKMAN_R2_______________________ KC_Y, ALT_T(KC_N), GUI_T(KC_E), SFT_T(KC_O), KC_I
|
||||
#define _______________________HWORKMAN_R3_______________________ KC_K, KC_L, KC_COMM, KC_DOT, CTL_T(KC_SLASH)
|
||||
|
||||
#define ___________________ERGODOX_BOTTOM_LEFT___________________ TT(_DIABLO), TT(_ADJUST), XXXXXXX, KC_UP, KC_LEFT
|
||||
#define ___________________ERGODOX_BOTTOM_RIGHT__________________ KC_RIGHT, KC_DOWN, TT(_RAISE), TT(_LOWER), TT(_ADJUST)
|
||||
|
||||
// LEFT | RIGHT
|
||||
#define ______________________ERGODOX_THUMBS_____________________ KC_APP,KC_HOME, KC_PGUP,KC_ESC, \
|
||||
KC_END, KC_PGDOWN, \
|
||||
KC_LWSP,KC_BSPACE,JJ_COPY, JJ_PASTE,KC_TAB,KC_RSEN
|
21
keyboards/ergodox_ez/keymaps/bocaj/config.h
Normal file
21
keyboards/ergodox_ez/keymaps/bocaj/config.h
Normal file
@@ -0,0 +1,21 @@
|
||||
#ifndef USERSPACE_CONFIG_H
|
||||
#define USERSPACE_CONFIG_H
|
||||
|
||||
#ifndef QMK_KEYS_PER_SCAN
|
||||
#define QMK_KEYS_PER_SCAN 4
|
||||
#endif // QMK KEYS PER SCAN
|
||||
|
||||
// this makes it possible to do rolling combos (zx) with keys that
|
||||
// convert to other keys on hold (z becomes ctrl when you hold it,
|
||||
// and when this option isn't enabled, z rapidly followed by x
|
||||
// actually sends Ctrl-x. That's bad.)
|
||||
#define IGNORE_MOD_TAP_INTERRUPT
|
||||
#define PERMISSIVE_HOLD
|
||||
#undef PREVENT_STUCK_MODIFIERS
|
||||
|
||||
// Disable action_get_macro and fn_actions, since we don't use these
|
||||
// and it saves on space in the firmware.
|
||||
#define NO_ACTION_MACRO
|
||||
#define NO_ACTION_FUNCTION
|
||||
|
||||
#endif // !USERSPACE_CONFIG_H
|
340
keyboards/ergodox_ez/keymaps/bocaj/keymap.c
Normal file
340
keyboards/ergodox_ez/keymaps/bocaj/keymap.c
Normal file
@@ -0,0 +1,340 @@
|
||||
/*
|
||||
Copyright 2018 Jacob Jerrell <jacob.jerrell@gmail.com>
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
#include QMK_KEYBOARD_H
|
||||
#include "bocaj.h"
|
||||
|
||||
#ifdef UNICODEMAP_ENABLE
|
||||
#include "bocaj_unicode.h"
|
||||
#endif // UNICODEMAP_ENABLE
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
/* Software Workman / QWERTY - http://www.keyboard-layout-editor.com/#/gists/b6c016a22a9d31381a276a603a42fe5f
|
||||
.---------------------------------------------. .---------------------------------------------.
|
||||
| ESC | 1 | 2 | 3 | 4 | 5 | -> | ! - | 6 | 7 | 8 | 9 | 0 | = |
|
||||
!-------+-----+-----+-----+-----+-------------! !-------+-----+-----+-----+-----+-----+-------!
|
||||
| DEL | Q | W | E | R | T | ( | ! ) | Y | U | I | O | P | \ |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| ADJST | A | S | D | F | G |-------! !-------! H | J | K | L | ; | ' |
|
||||
!-------+-----+-----+-----x-----x-----! HYP ! ! MEH !-----x-----x-----+-----+-----+-------!
|
||||
| SHIFT | Z | X | C | V | B | { | ! } | N | M | , | . | / | SHIFT |
|
||||
'-------+-----+-----+-----+-----+-------------' '-------------+-----+-----+-----+-----+-------'
|
||||
| GAME | NUM | VRS | UP | LFT | .---------------. .---------------. ! RGT | DWN | RSE | LWR | ADJ |
|
||||
'------------------------------' | APP | HOME | ! PGUP | ESC | '------------------------------'
|
||||
.-------+-------+-------! !-------+-------+-------.
|
||||
! SPACE ! | END | ! PGDN | ! ENTER !
|
||||
! / ! BSPCE !-------! !-------! TAB ! / !
|
||||
| LOWER | | COPY | ! PASTE | | RAISE |
|
||||
'-----------------------' '-----------------------'
|
||||
*/
|
||||
[_SWRKMN] = LAYOUT_ergodox_pretty_wrapper(
|
||||
KC_ESC, ______________________NUMBER_LEFT________________________, JJ_ARRW, KC_MINUS, ______________________NUMBER_RIGHT_______________________, KC_EQUAL,
|
||||
KC_DEL, _______________________SWORKMAN_L1_______________________, KC_LPRN, KC_RPRN, _______________________SWORKMAN_R1_______________________, KC_BSLS,
|
||||
KC_ADJS,_______________________SWORKMAN_L2_______________________, _______________________SWORKMAN_R2_______________________, KC_QUOTE,
|
||||
KC_LSFT,_______________________SWORKMAN_L3_______________________, HYP_LBK, MEH_RBK, _______________________SWORKMAN_R3_______________________, KC_RSFT,
|
||||
___________________ERGODOX_BOTTOM_LEFT___________________, ___________________ERGODOX_BOTTOM_RIGHT__________________,
|
||||
______________________ERGODOX_THUMBS_____________________
|
||||
),
|
||||
/* Hardware Workman - http://www.keyboard-layout-editor.com/#/gists/7a07cb982ec3597ba3e3d947554225f1
|
||||
.---------------------------------------------. .---------------------------------------------.
|
||||
| ESC | 1 | 2 | 3 | 4 | 5 | -> | ! - | 6 | 7 | 8 | 9 | 0 | = |
|
||||
!-------+-----+-----+-----+-----+-------------! !-------+-----+-----+-----+-----+-----+-------!
|
||||
| DEL | Q | D | R | W | B | ( | ! ) | J | F | U | P | ; | \ |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| ADJST | A | S | H | T | G |-------! !-------! Y | N | E | O | I | ' |
|
||||
!-------+-----+-----+-----x-----x-----! HYP ! ! MEH !-----x-----x-----+-----+-----+-------!
|
||||
| SHIFT | Z | X | M | C | V | { | ! } | K | L | , | . | / | SHIFT |
|
||||
'-------+-----+-----+-----+-----+-------------' '-------------+-----+-----+-----+-----+-------'
|
||||
| GAME | NUM | VRS | UP | LFT | .---------------. .---------------. ! RGT | DWN | RSE | LWR | ADJ |
|
||||
'------------------------------' | APP | HOME | ! PGUP | ESC | '------------------------------'
|
||||
.-------+-------+-------! !-------+-------+-------.
|
||||
! SPACE ! | END | ! PGDN | ! ENTER !
|
||||
! / ! BSPCE !-------! !-------! TAB ! / !
|
||||
| LOWER | | COPY | ! PASTE | | RAISE |
|
||||
'-----------------------' '-----------------------'
|
||||
*/
|
||||
[_HWRKMN] = LAYOUT_ergodox_pretty_wrapper(
|
||||
KC_ESC, ______________________NUMBER_LEFT________________________, JJ_ARRW, KC_MINUS, ______________________NUMBER_RIGHT_______________________, KC_EQUAL,
|
||||
KC_DEL, _______________________HWORKMAN_L1_______________________, KC_LPRN, KC_RPRN, _______________________HWORKMAN_R1_______________________, KC_BSLS,
|
||||
KC_ADJS,_______________________HWORKMAN_L2_______________________, _______________________HWORKMAN_R2_______________________, KC_QUOTE,
|
||||
KC_LSFT,_______________________HWORKMAN_L3_______________________, HYP_LBK, MEH_RBK, _______________________HWORKMAN_R3_______________________, KC_RSFT,
|
||||
___________________ERGODOX_BOTTOM_LEFT___________________, ___________________ERGODOX_BOTTOM_RIGHT__________________,
|
||||
______________________ERGODOX_THUMBS_____________________
|
||||
),
|
||||
/* Lower - http://www.keyboard-layout-editor.com/#/gists/f1d745a88d1c48ab55e095efd9e7a43a
|
||||
.---------------------------------------------. .---------------------------------------------.
|
||||
| | F1 | F2 | F3 | F4 | F5 | | ! | F6 | F7 | F8 | F9 | F10 | |
|
||||
!-------+-----+-----+-----+-----+-------------! !-------+-----+-----+-----+-----+-----+-------!
|
||||
| ` | 1 | 2 | 3 | 4 | 5 | | ! | 6 | 7 | 8 | 9 | 0 | |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| | | | | | |-------! !-------! | | | | | |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| | | | | | | | ! | | | | | | |
|
||||
'-------+-----+-----+-----+-----+-------------' '-------------+-----+-----+-----+-----+-------'
|
||||
| | | | | | .---------------. .---------------. ! | | | | |
|
||||
'------------------------------' | | | ! | | '------------------------------'
|
||||
.-------+-------+-------! !-------+-------+-------.
|
||||
! ! | | ! | ! !
|
||||
! ! !-------! !-------! ! !
|
||||
| | | | ! | | |
|
||||
'-----------------------' '-----------------------'
|
||||
*/
|
||||
[_LOWER] = LAYOUT_ergodox_pretty_wrapper(
|
||||
_______,_______________________FUNC_LEFT_________________________, _______, _______, _______________________FUNC_RIGHT________________________, _______,
|
||||
KC_GRV ,______________________NUMBER_LEFT________________________, _______, _______, ______________________NUMBER_RIGHT_______________________, _______,
|
||||
_______,_________________________________________________________, _________________________________________________________, _______,
|
||||
_______,_________________________________________________________, _______, _______, _________________________________________________________, _______,
|
||||
_________________________________________________________, _________________________________________________________,
|
||||
______________________ERGODOX_THUMBS_____________________
|
||||
),
|
||||
/* Raise - http://www.keyboard-layout-editor.com/#/gists/e0f591ec2ce9f24675a02d15c7048b25
|
||||
.---------------------------------------------. .---------------------------------------------.
|
||||
| | F1 | F2 | F3 | F4 | F5 | | ! _ | F6 | F7 | F8 | F9 | F10 | |
|
||||
!-------+-----+-----+-----+-----+-------------! !-------+-----+-----+-----+-----+-----+-------!
|
||||
| ~ | ! | @ | # | $ | % | | ! | ^ | & | * | ( | ) | |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| | | | | | |-------! !-------! | | | | | |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| | | | | | | | ! | | | | | | |
|
||||
'-------+-----+-----+-----+-----+-------------' '-------------+-----+-----+-----+-----+-------'
|
||||
| | | | | | .---------------. .---------------. ! | | | | |
|
||||
'------------------------------' | | | ! | | '------------------------------'
|
||||
.-------+-------+-------! !-------+-------+-------.
|
||||
! ! | | ! | ! !
|
||||
! ! !-------! !-------! ! !
|
||||
| | | | ! | | |
|
||||
'-----------------------' '-----------------------'
|
||||
*/
|
||||
[_RAISE] = LAYOUT_ergodox_pretty_wrapper(
|
||||
_______,_______________________FUNC_LEFT_________________________, _______, KC_UNDS, _______________________FUNC_RIGHT________________________, _______,
|
||||
KC_TILD,______________________SPECIAL_LEFT_______________________, _______, _______, ______________________SPECIAL_RIGHT______________________, _______,
|
||||
_______,_________________________________________________________, _________________________________________________________, _______,
|
||||
_______,_________________________________________________________, _______, _______, _________________________________________________________, _______,
|
||||
_________________________________________________________, _________________________________________________________,
|
||||
______________________ERGODOX_THUMBS_____________________
|
||||
),
|
||||
/* Adjust - http://www.keyboard-layout-editor.com/#/gists/dedeae17b35a5d5f745a42aaea78f007
|
||||
.---------------------------------------------. .---------------------------------------------.
|
||||
| | | | | | | EPRM | ! EPRM | | | | | | |
|
||||
!-------+-----+-----+-----+-----+-------------! !-------+-----+-----+-----+-----+-----+-------!
|
||||
| | | | | | | | ! | | 7 | 8 | 9 | * | |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| | 🔇 | 🔉 | 🔊 | LCK | |-------! !-------! | 4 | 5 | 6 | + | SWRKM |
|
||||
!-------+-----+-----+-----x-----x-----! ! ! !-----x-----x-----+-----+-----+-------!
|
||||
| | | | | | | | ! | | 1 | 2 | 3 | - | HWRKM |
|
||||
'-------+-----+-----+-----+-----+-------------' '-------------+-----+-----+-----+-----+-------'
|
||||
| | | | | | .---------------. .---------------. ! 0 | . | , | = | |
|
||||
'------------------------------' | | | ! | | '------------------------------'
|
||||
.-------+-------+-------! !-------+-------+-------.
|
||||
! ! | | ! | ! !
|
||||
! ! !-------! !-------! ! !
|
||||
| | | | ! | | |
|
||||
'-----------------------' '-----------------------'
|
||||
*/
|
||||
[_ADJUST] = LAYOUT_ergodox_pretty_wrapper(
|
||||
XXXXXXX,XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX, KC_EPRM, KC_EPRM, XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX, XXXXXXX,
|
||||
XXXXXXX,XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_KP_7, KC_KP_8, KC_KP_9, KC_PAST, XXXXXXX,
|
||||
_______,KC__MUTE, KC__VOLDOWN, KC__VOLUP, MC_LOCK, XXXXXXX, XXXXXXX, KC_KP_4, KC_KP_5, KC_KP_6, KC_PPLS, KC_SWRK,
|
||||
XXXXXXX,XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_KP_1, KC_KP_2, KC_KP_3, KC_PMNS, KC_HWRK,
|
||||
XXXXXXX,_______,XXXXXXX,XXXXXXX,XXXXXXX, KC_KP_0, KC_PDOT, KC_COMM, KC_PEQL, _______,
|
||||
______________________ERGODOX_THUMBS_____________________
|
||||
),
|
||||
// Diablo - http://www.keyboard-layout-editor.com/#/gists/28476e4237e77d4835ac8a9d7e5f9b2c
|
||||
[_DIABLO] = LAYOUT_ergodox_pretty_wrapper(
|
||||
KC_ESC , KC_V , KC_D ,XXXXXXX ,XXXXXXX ,XXXXXXX ,XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
|
||||
KC_TAB , KC_S , KC_I , KC_F , KC_T , KC_J ,XXXXXXX, XXXXXXX, XXXXXXX, KC_KP_7, KC_KP_8, KC_KP_9, XXXXXXX, XXXXXXX,
|
||||
KC_Q , KC_1 , KC_2 , KC_3 , KC_4 , KC_M , XXXXXXX, KC_KP_4, KC_KP_5, KC_KP_6, XXXXXXX, XXXXXXX,
|
||||
KC_LSFT,KC_D3_1 ,KC_D3_2 ,KC_D3_3 ,KC_D3_4 ,XXXXXXX ,XXXXXXX, XXXXXXX, XXXXXXX, KC_KP_1, KC_KP_2, KC_KP_3, XXXXXXX, XXXXXXX,
|
||||
_______,ALT_T(KC_Z) ,KC_G ,KC_Y ,XXXXXXX , KC_KP_0, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
|
||||
XXXXXXX, XXXXXXX, XXXXXXX,XXXXXXX,
|
||||
XXXXXXX, XXXXXXX,
|
||||
KC_BTN1,KC_BTN2,KC_DIABLO_CLEAR, XXXXXXX,XXXXXXX,XXXXXXX
|
||||
)
|
||||
};
|
||||
|
||||
// Defines actions for my custom keycodes
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
// KC_COPY and KC_PASTE have problems with different hardware/software mappings
|
||||
// e.g. If the mappings conflict, KC_COPY will send Cmd+M which minimizes the
|
||||
// window and is very annoying. JJ_COPY and JJ_PASTE fix this by sending the
|
||||
// raw character rather than the KC_* code
|
||||
case JJ_COPY:
|
||||
if (!record->event.pressed) {
|
||||
SEND_STRING(SS_LGUI("c"));
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case JJ_PASTE:
|
||||
if (!record->event.pressed) {
|
||||
SEND_STRING(SS_LGUI("v"));
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case JJ_ARRW:
|
||||
if (!record->event.pressed) {
|
||||
SEND_STRING("->");
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case KC_SWRK:
|
||||
if (!record->event.pressed) {
|
||||
set_single_persistent_default_layer(_SWRKMN);
|
||||
layer_move(_SWRKMN);
|
||||
ergodox_blink_all_leds();
|
||||
ergodox_blink_all_leds();
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case KC_HWRK:
|
||||
if (!record->event.pressed) {
|
||||
set_single_persistent_default_layer(_HWRKMN);
|
||||
layer_move(_HWRKMN);
|
||||
ergodox_blink_all_leds();
|
||||
ergodox_blink_all_leds();
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case KC_EPRM:
|
||||
if (!record->event.pressed) {
|
||||
ergodox_blink_all_leds();
|
||||
eeconfig_init();
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case MC_LOCK:
|
||||
if (!record->event.pressed) {
|
||||
layer_move(_HWRKMN);
|
||||
SEND_STRING(SS_LCTRL(SS_LGUI("q")));
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case KC_DIABLO_CLEAR:
|
||||
#ifdef TAP_DANCE_ENABLE
|
||||
if (record->event.pressed) {
|
||||
uint8_t dtime;
|
||||
for (dtime = 0; dtime < 4; dtime++) {
|
||||
diablo_key_time[dtime] = diablo_times[0];
|
||||
}
|
||||
}
|
||||
#endif // TAP_DANCE_ENABLE
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void tap(uint16_t keycode){ register_code(keycode); unregister_code(keycode); };
|
||||
|
||||
// Diablo III Fun stuff
|
||||
//define diablo macro timer variables
|
||||
uint16_t diablo_timer[4];
|
||||
uint8_t diablo_times[] = { 0, 1, 3, 5, 10, 30 };
|
||||
uint8_t diablo_key_time[4];
|
||||
|
||||
// has the correct number of seconds elapsed (as defined by diablo_times)
|
||||
bool check_dtimer(uint8_t dtimer) { return (timer_elapsed(diablo_timer[dtimer]) < (diablo_key_time[dtimer] * 1000)) ? false : true; };
|
||||
|
||||
// Cycle through the times for the macro, starting at 0, for disabled.
|
||||
// Max of six values, so don't exceed
|
||||
void diablo_tapdance_master(qk_tap_dance_state_t *state, void *user_data, uint8_t diablo_key) {
|
||||
if (state->count >= 7) {
|
||||
diablo_key_time[diablo_key] = diablo_times[0];
|
||||
reset_tap_dance(state);
|
||||
} else {
|
||||
diablo_key_time[diablo_key] = diablo_times[state->count - 1];
|
||||
}
|
||||
}
|
||||
|
||||
// Would rather have one function for all of this, but no idea how to do that...
|
||||
void diablo_tapdance1(qk_tap_dance_state_t *state, void *user_data) { diablo_tapdance_master(state, user_data, 0); }
|
||||
void diablo_tapdance2(qk_tap_dance_state_t *state, void *user_data) { diablo_tapdance_master(state, user_data, 1); }
|
||||
void diablo_tapdance3(qk_tap_dance_state_t *state, void *user_data) { diablo_tapdance_master(state, user_data, 2); }
|
||||
void diablo_tapdance4(qk_tap_dance_state_t *state, void *user_data) { diablo_tapdance_master(state, user_data, 3); }
|
||||
|
||||
//Tap Dance Definitions
|
||||
qk_tap_dance_action_t tap_dance_actions[] = {
|
||||
// tap once to disable, and more to enable timed micros
|
||||
[TD_D3_1] = ACTION_TAP_DANCE_FN(diablo_tapdance1),
|
||||
[TD_D3_2] = ACTION_TAP_DANCE_FN(diablo_tapdance2),
|
||||
[TD_D3_3] = ACTION_TAP_DANCE_FN(diablo_tapdance3),
|
||||
[TD_D3_4] = ACTION_TAP_DANCE_FN(diablo_tapdance4),
|
||||
};
|
||||
|
||||
// Sends the key press to system, but only if on the Diablo layer
|
||||
void send_diablo_keystroke(uint8_t diablo_key) {
|
||||
if (biton32(layer_state) == _DIABLO) {
|
||||
switch (diablo_key) {
|
||||
case 0:
|
||||
tap(KC_1); break;
|
||||
case 1:
|
||||
tap(KC_2); break;
|
||||
case 2:
|
||||
tap(KC_3); break;
|
||||
case 3:
|
||||
tap(KC_4); break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Checks each of the 4 timers/keys to see if enough time has elapsed
|
||||
// Runs the "send string" command if enough time has passed, and resets the timer.
|
||||
void run_diablo_macro_check(void) {
|
||||
uint8_t dtime;
|
||||
for (dtime = 0; dtime < 4; dtime++) {
|
||||
if (check_dtimer(dtime) && diablo_key_time[dtime]) {
|
||||
diablo_timer[dtime] = timer_read();
|
||||
send_diablo_keystroke(dtime);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void matrix_scan_user(void) {
|
||||
uint8_t layer = biton32(layer_state);
|
||||
ergodox_board_led_off();
|
||||
ergodox_right_led_1_off();
|
||||
ergodox_right_led_2_off();
|
||||
ergodox_right_led_3_off();
|
||||
switch (layer) {
|
||||
/*
|
||||
Lights are treated as binary here for easy identification.
|
||||
LED1 = 4; LED2 = 2; LED1 = 1
|
||||
This allows for up to 8 identified layers (default layers being no lights on)
|
||||
Which is way more than I should ever need
|
||||
*/
|
||||
case _LOWER:
|
||||
ergodox_right_led_3_on();
|
||||
ergodox_right_led_3_set(10); // Default brightness is deadly in a dark room
|
||||
break;
|
||||
case _RAISE:
|
||||
ergodox_right_led_2_on();
|
||||
ergodox_right_led_2_set(10);
|
||||
break;
|
||||
case _ADJUST:
|
||||
ergodox_right_led_2_on();
|
||||
ergodox_right_led_2_set(10);
|
||||
ergodox_right_led_3_on();
|
||||
ergodox_right_led_3_set(10);
|
||||
break;
|
||||
case _DIABLO:
|
||||
ergodox_right_led_1_on();
|
||||
ergodox_right_led_1_set(10);
|
||||
break;
|
||||
default:
|
||||
// none
|
||||
break;
|
||||
}
|
||||
#ifdef TAP_DANCE_ENABLE
|
||||
run_diablo_macro_check();
|
||||
#endif
|
||||
};
|
48
keyboards/ergodox_ez/keymaps/bocaj/readme.md
Normal file
48
keyboards/ergodox_ez/keymaps/bocaj/readme.md
Normal file
@@ -0,0 +1,48 @@
|
||||
# Ergodox EZ Layout by JacobJerrell
|
||||
|
||||
My personal Ergodox EZ layout.
|
||||
|
||||
## Summary
|
||||
|
||||
Contains two base layers because I carry my keyboard between different machines and occassionally use the machines without this keyboard. A side-effect to using it in this manner (with a non-QWERTY layout) is that software/hardware mappings conflict so this allows a quick (2-buttons) to get the keyboard to a compatible layer
|
||||
|
||||
## Layers
|
||||
|
||||
| Layer | Purpose |
|
||||
| ----- | ------- |
|
||||
| 0 | [Hardware Workman](#hardware-workman) - For OS mapped to QWERTY |
|
||||
| 1 | [Software Workman](#software-workman) - For OS mapped to Workman |
|
||||
| 2 | [Lower](#lower) |
|
||||
| 3 | [Raise](#raise) |
|
||||
| 4 | [Adjust](#adjust) |
|
||||
| 5 | [Diablo III](#diablo-iii) |
|
||||
|
||||
### Hardware Workman
|
||||
|
||||
For easy plug and play into QWERTY machines
|
||||

|
||||
|
||||
### Software Workman
|
||||
|
||||
To switch to when I was previously using the laptop keyboard with software mapped to Workman. Or so other people can take the Ergodox for a spin.
|
||||

|
||||
|
||||
### Lower
|
||||
|
||||
Reveals F1-12 keys and brings numkeys down.
|
||||

|
||||
|
||||
### Raise
|
||||
|
||||
Reveals F1-F12 keys and gives shifted numkeys.
|
||||

|
||||
|
||||
### Adjust
|
||||
|
||||
Numpad, Wipe EEPROM, OSX Volume Control, OSX Lockscreen, and Default Layer Switching.
|
||||

|
||||
|
||||
### Diablo III
|
||||
|
||||
Arranged to make playing on a laptop much more enjoyable. Credit for the D1-4 macros (as well as much of the ideas in this layout goes to Drashna)
|
||||

|
5
keyboards/ergodox_ez/keymaps/bocaj/rules.mk
Normal file
5
keyboards/ergodox_ez/keymaps/bocaj/rules.mk
Normal file
@@ -0,0 +1,5 @@
|
||||
AUTO_SHIFT_ENABLE = no
|
||||
COMMAND_ENABLE = no
|
||||
SWAP_HANDS_ENABLE = no
|
||||
TAP_DANCE_ENABLE = yes
|
||||
EXTRAKEY_ENABLE = no
|
@@ -12,7 +12,8 @@ Layers
|
||||
* BASE: basic dvorak layout
|
||||
* KEYNAV: arrow-key navigation. Momentary toggle held by thumb allows the right hand to navigate through text as well as copy/paste/cut, page up/page down
|
||||
* KEYSEL: similar to KEYNAV, except for shift-selection
|
||||
* COMBINED: this is a layer that combines numbers, brackets and special characters. !@#$%^&*( can be type by shift+COMBINED+1/2/3/etc..
|
||||
* MOUSE: mouse navigation, as well as browser tab-left/tab-right shortcuts
|
||||
* COMBINED: this is a layer that combines numbers, brackets and special characters. !@#$%^&*( can be typed by shift+COMBINED+1/2/3/etc..
|
||||
* BROWSER_CONTROL: primarily browser left/right tab, open new tab/delete tab, but also mouse keys.
|
||||
* SHELL_NAV: Linux Bash shortcuts (move forward/backward in command line, Ctrl+C, recall last argument, etc
|
||||
* SHELL_SCREEN: Linux screen (run multiple terminals in one window) shortcuts such as open new tabs, switch between tabs
|
||||
* SHELL_SCREEN: Linux screen (run multiple terminals in one window) shortcuts such as open new tabs, switch between tabs
|
||||
* SCREEN_NAV: special layer for copy/pasting within Linux screen, allows using various copy/paste buffers
|
@@ -15,8 +15,6 @@
|
||||
// pushing dev branch
|
||||
// git push origin dev:dev
|
||||
|
||||
static bool mouse_lock = false;
|
||||
|
||||
enum custom_keycodes {
|
||||
PLACEHOLDER = SAFE_RANGE, // can always be here
|
||||
EPRM,
|
||||
@@ -40,7 +38,12 @@ enum custom_keycodes {
|
||||
SHELL_SCREEN_LIST,
|
||||
SHELL_MKE,
|
||||
SHELL_HTCSTATUS,
|
||||
SHELL_HTCBOUNCE,
|
||||
SHELL_DUMPTLOG,
|
||||
|
||||
SHELL_EXPAND_OE_LOGPATTERN,
|
||||
SHELL_EXPAND_OE_TRANPATTERN,
|
||||
|
||||
// Cloud9 macros
|
||||
CLOUD9_TAB_LEFT,
|
||||
CLOUD9_TAB_RIGHT,
|
||||
@@ -57,19 +60,15 @@ enum custom_keycodes {
|
||||
#define KEYSEL 2 // arrow navigation + shift (allow text selection)
|
||||
#define SHELL_NAV 3 // bash shortcuts
|
||||
#define SHELL_SCREEN 4 // linux screen shortcuts
|
||||
#define SCREEN_NAV 5 // navigate between linux screen tabs
|
||||
#define MOUSE 6 // mouse layer (can be locked with lock key), unmapped for now
|
||||
#define BROWSER_CONTROL 7 // control browser and mouse
|
||||
#define COMBINED 8 // combined numbers and symbols layer
|
||||
#define SCREEN_NAV 5 // navigate between linux screen tabs
|
||||
#define BROWSER_CONTROL 6 // control browser and mouse
|
||||
#define COMBINED 7 // combined numbers and symbols layer
|
||||
|
||||
|
||||
// macros
|
||||
#define MOUSE_TOGGLE 1
|
||||
#define MOUSE_LOCK 2
|
||||
#define SCREEN_TAB_LEFT 4
|
||||
#define SCREEN_TAB_RIGHT 5
|
||||
#define SCREEN_NEW_TAB 6
|
||||
#define SWITCH_NDS 7
|
||||
#define SCREEN_COPY_MODE 8
|
||||
#define SCREEN_PASTE 9
|
||||
#define SCREEN_RENAME 10
|
||||
@@ -93,9 +92,8 @@ enum custom_keycodes {
|
||||
#define SCREEN_PASTEREG_1 28
|
||||
#define SCREEN_PASTEREG_2 29
|
||||
#define SCREEN_PASTEREG_3 30
|
||||
#define SHELL_WRITE_LOGPATTERN 31
|
||||
#define SHELL_WRITE_TRANPATTERN 32
|
||||
#define SHELL_EXPAND_PATTERN 33
|
||||
#define DEL_TO_HOME 36
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -175,13 +173,14 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_TRNS,MEH(KC_B), CLOUD9_NAVIGATE, CLOUD9_TAB_LEFT, CLOUD9_TAB_RIGHT, CLOUD9_TAB_CLOSE, KC_TRNS,
|
||||
KC_TRNS,KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
// left thumb cluster
|
||||
KC_TRNS,KC_TRNS,KC_TRNS,TO(MOUSE),KC_TRNS,KC_TRNS,
|
||||
KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,KC_TRNS,
|
||||
|
||||
|
||||
// right hand
|
||||
KC_TRNS,KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, MEH(KC_G),
|
||||
KC_TRNS,KC_NO, KC_HOME, KC_UP, KC_END, KC_PGUP, MEH(KC_H),
|
||||
LCTL(KC_LEFT), KC_LEFT, KC_DOWN, KC_RIGHT, LCTL(KC_RIGHT), MEH(KC_I),
|
||||
KC_TRNS,KC_NO, RCTL(KC_C), RCTL(KC_X), RCTL(KC_V), KC_PGDOWN, MEH(KC_J),
|
||||
KC_TRNS,M(DEL_TO_HOME),RCTL(KC_C), RCTL(KC_X), RCTL(KC_V), KC_PGDOWN, MEH(KC_J),
|
||||
KC_BSPC, RCTL(KC_BSPC), KC_DELETE, LCTL(KC_DELETE), MEH(KC_K),
|
||||
|
||||
// right thumb cluster
|
||||
@@ -218,7 +217,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[SHELL_NAV] = LAYOUT_ergodox(
|
||||
// left hand
|
||||
KC_NO, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS,KC_TRNS, SHELL_PGREP, SHELL_PLESS, SHELL_LESS, KC_TRNS, SHELL_H3,
|
||||
KC_TRNS,KC_TRNS, SHELL_PGREP, SHELL_PLESS, SHELL_LESS, SHELL_HTCBOUNCE, SHELL_H3,
|
||||
KC_TRNS,SHELL_MKE, SHELL_CDPRE, SHELL_LSLTR, SHELL_LS, SHELL_LSLA,
|
||||
KC_TRNS,SHELL_SCREEN_LIST, SHELL_SCREENRD, SHELL_SCREEN_NEW, SHELL_TAILF, SHELL_HTCSTATUS, SHELL_AMMCOLO,
|
||||
// bottom row
|
||||
@@ -228,10 +227,10 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_TRNS,
|
||||
KC_TRNS,KC_TRNS,KC_TRNS,
|
||||
// right hand
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, M(SHELL_WRITE_TRANPATTERN),
|
||||
RCTL(KC_L), RCTL(KC_W), KC_HOME, KC_UP, KC_END, KC_TRNS, M(SHELL_WRITE_LOGPATTERN),
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, SHELL_EXPAND_OE_TRANPATTERN,
|
||||
RCTL(KC_L), RCTL(KC_W), KC_HOME, KC_UP, KC_END, KC_TRNS, SHELL_EXPAND_OE_LOGPATTERN,
|
||||
LALT(KC_B), KC_LEFT, KC_DOWN, KC_RIGHT, LALT(KC_F), RCTL(KC_W),
|
||||
RCTL(KC_C), RCTL(KC_U), LALT(KC_DOT), RCTL(KC_R), MEH(KC_V), RCTL(KC_K), M(SHELL_EXPAND_PATTERN),
|
||||
RCTL(KC_C), RCTL(KC_U), LALT(KC_DOT), RCTL(KC_R), MEH(KC_V), RCTL(KC_K), SHELL_DUMPTLOG,
|
||||
// bottom row (match functionality of base layer)
|
||||
KC_BSPC, RCTL(KC_W), KC_DELETE, LALT(KC_D), RCTL(KC_U),
|
||||
// thumb cluster
|
||||
@@ -320,30 +319,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
KC_TRNS,KC_TRNS,
|
||||
KC_TRNS,
|
||||
KC_TRNS,KC_TRNS,KC_TRNS),
|
||||
|
||||
|
||||
[MOUSE] = LAYOUT_ergodox(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_PGUP, KC_MS_WH_UP, KC_UP, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_MS_ACCEL0, KC_PGDN, KC_MS_WH_DOWN, KC_DOWN, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, M(MOUSE_LOCK), KC_TRNS, KC_MS_ACCEL0,
|
||||
|
||||
KC_TRNS, KC_TRNS,
|
||||
KC_TRNS,
|
||||
KC_TRNS, KC_BTN3, KC_TRNS,
|
||||
// right hand
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_UP, KC_HOME, KC_MS_U, KC_END, KC_MS_WH_UP, KC_TRNS,
|
||||
KC_DOWN, KC_MS_L, KC_MS_D, KC_MS_R, KC_MS_WH_DOWN, KC_TRNS,
|
||||
KC_TRNS, MEH(KC_X), MEH(KC_Y), MEH(KC_Z), KC_F5, RCTL(KC_W), KC_TRNS,
|
||||
// browser tab control
|
||||
RSFT(RCTL(KC_TAB)), RCTL(KC_TAB), RCTL(KC_T), LALT(KC_LEFT), KC_TRNS,
|
||||
KC_TRNS, KC_TRNS,
|
||||
KC_TRNS,
|
||||
KC_TRNS, KC_BTN1, KC_BTN2
|
||||
),
|
||||
|
||||
|
||||
|
||||
[BROWSER_CONTROL] = LAYOUT_ergodox(
|
||||
// left hand
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
@@ -379,26 +356,6 @@ const uint16_t PROGMEM fn_actions[] = {
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
switch(id) {
|
||||
case MOUSE_TOGGLE:
|
||||
if (record->event.pressed) {
|
||||
layer_on(MOUSE);
|
||||
} else {
|
||||
if(!mouse_lock)
|
||||
layer_off(MOUSE);
|
||||
}
|
||||
break;
|
||||
case MOUSE_LOCK:
|
||||
if (record->event.pressed)
|
||||
{
|
||||
if(mouse_lock)
|
||||
{
|
||||
mouse_lock = false;
|
||||
layer_off(MOUSE);
|
||||
}
|
||||
else
|
||||
mouse_lock = true;
|
||||
}
|
||||
break;
|
||||
case SCREEN_TAB_LEFT:
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LCTL), T(A), U(LCTL), T(P), END);
|
||||
@@ -478,40 +435,19 @@ const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LCTL), T(A), U(LCTL), T(RBRC), END);
|
||||
}
|
||||
break;
|
||||
break;
|
||||
|
||||
case SHELL_WRITE_LOGPATTERN:
|
||||
case DEL_TO_HOME:
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LSFT),
|
||||
T(8),
|
||||
T(8),
|
||||
U(LSFT),
|
||||
T(L),
|
||||
T(O),
|
||||
T(G),
|
||||
T(LEFT),
|
||||
T(LEFT),
|
||||
T(LEFT),
|
||||
T(LEFT),
|
||||
END);
|
||||
}
|
||||
break;
|
||||
|
||||
case SHELL_WRITE_TRANPATTERN:
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LSFT),
|
||||
T(8),
|
||||
T(8),
|
||||
U(LSFT), T(T), T(R), T(A), T(N), T(LEFT), T(LEFT), T(LEFT), T(LEFT), T(LEFT), END);
|
||||
}
|
||||
break;
|
||||
|
||||
case SHELL_EXPAND_PATTERN:
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LALT), T(F), U(LALT), D(LCTL), T(X), U(LCTL), D(LSFT), T(8), D(LSFT), END);
|
||||
}
|
||||
break;
|
||||
return MACRO(
|
||||
// delete to the beginning of the line
|
||||
D(LSFT), T(HOME), U(LSFT),
|
||||
T(DELETE),
|
||||
END);
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
}
|
||||
return MACRO_NONE;
|
||||
};
|
||||
@@ -599,15 +535,29 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
return true;
|
||||
break;
|
||||
case SHELL_MKE:
|
||||
SEND_STRING("mke\n");
|
||||
SEND_STRING("mki -j8\n");
|
||||
return true;
|
||||
break;
|
||||
case SHELL_HTCSTATUS:
|
||||
SEND_STRING("htcStatus -j ");
|
||||
return true;
|
||||
break;
|
||||
// Cloud9 macros
|
||||
case CLOUD9_TAB_LEFT:
|
||||
break;
|
||||
case SHELL_HTCBOUNCE:
|
||||
SEND_STRING("htcBounce -j ");
|
||||
return true;
|
||||
break;
|
||||
case SHELL_EXPAND_OE_LOGPATTERN:
|
||||
SEND_STRING(SS_TAP(X_LEFT)"*CQW_HKEX"SS_TAP(X_END)"*.log"SS_LCTRL("x")SS_LSFT("8"));
|
||||
break;
|
||||
case SHELL_EXPAND_OE_TRANPATTERN:
|
||||
SEND_STRING(SS_TAP(X_LEFT)"*CQW_HKEX"SS_TAP(X_END)"*.tran"SS_LCTRL("x")SS_LSFT("8"));
|
||||
break;
|
||||
case SHELL_DUMPTLOG:
|
||||
SEND_STRING(" | dumptlog - ");
|
||||
return true;
|
||||
break;
|
||||
// Cloud9 macros
|
||||
case CLOUD9_TAB_LEFT:
|
||||
SEND_STRING(SS_LCTRL("["));
|
||||
return true;
|
||||
break;
|
||||
@@ -664,8 +614,7 @@ void matrix_scan_user(void) {
|
||||
case SCREEN_NAV:
|
||||
ergodox_right_led_3_on();
|
||||
break;
|
||||
case MOUSE:
|
||||
case BROWSER_CONTROL:
|
||||
case BROWSER_CONTROL:
|
||||
ergodox_right_led_2_on();
|
||||
ergodox_right_led_3_on();
|
||||
break;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user