Update to latest qmk sources

This commit is contained in:
kemonine 2020-10-29 17:04:34 -04:00
parent 233b163d5d
commit cd46e529bb
1681 changed files with 80139 additions and 4807 deletions

View File

@ -0,0 +1,37 @@
---
name: Bug report
about: Create a report to help us improve QMK Firmware.
title: "[Bug] "
labels: bug, help wanted
assignees: ''
---
<!-- Provide a general summary of the bug in the title above. -->
<!--- This template is entirely optional and can be removed, but is here to help both you and us. -->
<!--- Anything on lines wrapped in comments like these will not show up in the final text. -->
## Describe the Bug
<!-- A clear and concise description of what the bug is. -->
## System Information
- Keyboard:
- Revision (if applicable):
- Operating system:
- AVR GCC version:
<!-- Run `avr-gcc --version` to find this out. -->
- ARM GCC version:
<!-- Run `arm-none-eabi-gcc --version` to find this out. -->
- QMK Firmware version:
<!-- Run `git describe --abbrev=0 --tags` to find this out. -->
- Any keyboard related software installed?
- [ ] AutoHotKey
- [ ] Karabiner
- [ ] Other:
## Additional Context
<!-- Add any other relevant information about the problem here. -->

8
qmk/.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@ -0,0 +1,8 @@
blank_issues_enabled: false
contact_links:
- name: QMK Discord
url: https://discord.gg/Uq7gcHh
about: Ask questions, discuss issues and features. Chill.
- name: OLKB Subreddit
url: https://www.reddit.com/r/olkb
about: All things OLKB and QMK.

View File

@ -0,0 +1,24 @@
---
name: Feature request
about: Suggest a new feature or changes to existing features.
title: "[Feature Request] "
labels: enhancement, help wanted
assignees: ''
---
<!--- Provide a general summary of the changes you want in the title above. -->
<!--- This template is entirely optional and can be removed, but is here to help both you and us. -->
<!--- Anything on lines wrapped in comments like these will not show up in the final text. -->
## Feature Request Type
- [ ] Core functionality
- [ ] Add-on hardware support (eg. audio, RGB, OLED screen, etc.)
- [ ] Alteration (enhancement/optimization) of existing feature(s)
- [ ] New behavior
## Description
<!-- A few sentences describing what it is that you'd like to see in QMK. Additional information (such as links to spec sheets, licensing info, other related issues or PRs, etc) would be helpful. -->

View File

@ -0,0 +1,14 @@
---
name: Other issues
about: Anything else that doesn't fall into the above categories.
title: ''
labels: help wanted, question
assignees: ''
---
<!--- Provide a general summary of the changes you want in the title above. -->
<!--- Anything on lines wrapped in comments like these will not show up in the final text. -->
<!-- Please check https://docs.qmk.fm/#/support for additional resources first. If that doesn't answer your question, choose the bug report template instead, as that may be more appropriate. -->

11
qmk/.github/ISSUE_TEMPLATE/zzz_blank.md vendored Normal file
View File

@ -0,0 +1,11 @@
---
name: Blank issue
about: If you're 100% sure that you don't need one of the other issue templates, use
this one instead.
title: ''
labels: help wanted, question
assignees: ''
---

35
qmk/.github/PULL_REQUEST_TEMPLATE.md vendored Normal file
View File

@ -0,0 +1,35 @@
<!--- Provide a general summary of your changes in the title above. -->
<!--- This template is entirely optional and can be removed, but is here to help both you and us. -->
<!--- Anything on lines wrapped in comments like these will not show up in the final text. -->
## Description
<!--- Describe your changes in detail here. -->
## Types of Changes
<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply. -->
- [ ] Core
- [ ] Bugfix
- [ ] New feature
- [ ] Enhancement/optimization
- [ ] Keyboard (addition or update)
- [ ] Keymap/layout/userspace (addition or update)
- [ ] Documentation
## Issues Fixed or Closed by This PR
*
## Checklist
<!--- Go over all the following points, and put an `x` in all the boxes that apply. -->
<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->
- [ ] My code follows the code style of this project: [**C**](https://docs.qmk.fm/#/coding_conventions_c), [**Python**](https://docs.qmk.fm/#/coding_conventions_python)
- [ ] I have read the [**PR Checklist** document](https://docs.qmk.fm/#/pr_checklist) and have made the appropriate changes.
- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.
- [ ] I have read the [**CONTRIBUTING** document](https://docs.qmk.fm/#/contributing).
- [ ] I have added tests to cover my changes.
- [ ] I have tested the changes and verified that they work and don't break anything (as well as I can manage).

42
qmk/.github/labeler.yml vendored Normal file
View File

@ -0,0 +1,42 @@
core:
- quantum/**/*
- tmk_core/**/*
- drivers/**/*
- tests/**/*
- util/**/*
- platforms/**/*
- Makefile
- '*.mk'
dependencies:
- any:
- 'lib/**/*'
- '!lib/python/**/*'
keyboard:
- any:
- 'keyboards/**/*'
- '!keyboards/**/keymaps/**/*'
keymap:
- users/**/*
- layouts/**/*
- keyboards/**/keymaps/**/*
via:
- keyboards/**/keymaps/via/*
cli:
- bin/qmk
- requirements.txt
- lib/python/**/*
python:
- '**/*.py'
documentation:
- docs/**/*
translation:
- docs/fr-fr/**/*
- docs/es/**/*
- docs/ja/**/*
- docs/he-il/**/*
- docs/pt-br/**/*
- docs/zh-cn/**/*
- docs/de/**/*
- docs/ru-ru/**/*
CI:
- .github/**/*

58
qmk/.github/stale.yml vendored Normal file
View File

@ -0,0 +1,58 @@
# Configuration for probot-stale - https://github.com/probot/stale
# General configuration
# Pull request specific configuration
pulls:
staleLabel: awaiting changes
# Number of days of inactivity before an Issue or Pull Request becomes stale
daysUntilStale: 45
# Number of days of inactivity before a stale Issue or Pull Request is closed.
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
daysUntilClose: 30
# Comment to post when marking as stale. Set to `false` to disable
markComment: >
Thank you for your contribution!
This pull request has been automatically marked as stale because it has not had
activity in the last 45 days. It will be closed in 30 days if no further activity occurs.
Please feel free to give a status update now, or re-open when it's ready.
For maintainers: Please label with `awaiting review`, `breaking_change`, `in progress`, or `on hold` to prevent
the issue from being re-flagged.
# Comment to post when closing a stale Issue or Pull Request.
closeComment: >
Thank you for your contribution!
This pull request has been automatically closed because it has not had activity in the last 30 days.
Please feel free to give a status update now, ping for review, or re-open when it's ready.
# Limit the number of actions per hour, from 1-30. Default is 30
limitPerRun: 30
exemptLabels:
- awaiting review
- breaking_change
- in progress
- on hold
# Issue specific configuration
issues:
staleLabel: stale
limitPerRun: 10
daysUntilStale: 90
daysUntilClose: 30
markComment: >
This issue has been automatically marked as stale because it has not had activity in the
last 90 days. It will be closed in the next 30 days unless it is tagged properly or other activity
occurs.
For maintainers: Please label with `bug`, `in progress`, `on hold`, `discussion` or `to do` to prevent
the issue from being re-flagged.
closeComment: >
This issue has been automatically closed because it has not had activity in the last 30 days.
If this issue is still valid, re-open the issue and let us know.
exemptLabels:
- bug
- in progress
- on hold
- discussion
- to do

39
qmk/.github/workflows/api.yml vendored Normal file
View File

@ -0,0 +1,39 @@
name: Update API Data
on:
push:
branches:
- master
paths:
- 'keyboards/**'
- 'layouts/community/**'
jobs:
api_data:
runs-on: ubuntu-latest
container: qmkfm/base_container
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 1
persist-credentials: false
- name: Generate API Data
run: qmk generate-api
- name: Install rsync
run: |
apt-get update && apt-get install -y rsync
- name: Upload API Data
uses: JamesIves/github-pages-deploy-action@3.7.1
with:
ACCESS_TOKEN: ${{ secrets.API_TOKEN_GITHUB }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: main
FOLDER: api_data/v1
CLEAN: true
GIT_CONFIG_EMAIL: hello@qmk.fm
REPOSITORY_NAME: qmk/qmk_keyboards
TARGET_FOLDER: v1

28
qmk/.github/workflows/cli.yml vendored Normal file
View File

@ -0,0 +1,28 @@
name: CLI CI
on:
push:
branches:
- master
- future
pull_request:
paths:
- 'lib/python/**'
- 'bin/qmk'
- 'requirements.txt'
- '.github/workflows/cli.yml'
jobs:
test:
runs-on: ubuntu-latest
container: qmkfm/base_container
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install dependencies
run: pip3 install -r requirements.txt
- name: Run tests
run: bin/qmk pytest

54
qmk/.github/workflows/info.yml vendored Normal file
View File

@ -0,0 +1,54 @@
name: PR Lint keyboards
on:
pull_request:
paths:
- 'keyboards/**'
jobs:
info:
runs-on: ubuntu-latest
container: qmkfm/base_container
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: trilom/file-changes-action@v1.2.4
id: file_changes
with:
output: '\n'
- name: Print info
run: |
git rev-parse --short HEAD
echo ${{ github.event.pull_request.base.sha }}
echo '${{ steps.file_changes.outputs.files}}'
- name: Run qmk info
shell: 'bash {0}'
run: |
QMK_CHANGES=$(echo -e '${{ steps.file_changes.outputs.files}}')
QMK_KEYBOARDS=$(qmk list-keyboards)
exit_code=0
for KB in $QMK_KEYBOARDS; do
KEYBOARD_CHANGES=$(echo "$QMK_CHANGES" | grep -E '^(keyboards/'${KB}'/)')
if [[ -z "$KEYBOARD_CHANGES" ]]; then
# skip as no changes for this keyboard
continue
fi
KEYMAP_ONLY=$(echo "$KEYBOARD_CHANGES" | grep -cv /keymaps/)
if [[ $KEYMAP_ONLY -gt 0 ]]; then
echo "linting ${KB}"
# TODO: info info always returns 0 - right now the only way to know failure is to inspect log lines
qmk info -l -kb ${KB} 2>&1 | tee /tmp/$$
!(grep -cq ☒ /tmp/$$)
: $((exit_code = $exit_code + $?))
fi
done
exit $exit_code

14
qmk/.github/workflows/labeler.yml vendored Normal file
View File

@ -0,0 +1,14 @@
name: "Pull Request Labeler"
on:
pull_request_target:
types: [opened, synchronize, reopened, ready_for_review, locked]
jobs:
triage:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@main
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
configuration-path: '.github/labeler.yml'

1
qmk/.gitignore vendored
View File

@ -16,6 +16,7 @@
*.swp
tags
*~
api_data/v1
build/
.build/
*.bak

24
qmk/.gitmodules vendored Normal file
View File

@ -0,0 +1,24 @@
[submodule "lib/chibios"]
path = lib/chibios
url = https://github.com/qmk/ChibiOS
branch = master
[submodule "lib/chibios-contrib"]
path = lib/chibios-contrib
url = https://github.com/qmk/ChibiOS-Contrib
branch = master
[submodule "lib/ugfx"]
path = lib/ugfx
url = https://github.com/qmk/uGFX
branch = master
[submodule "lib/googletest"]
path = lib/googletest
url = https://github.com/qmk/googletest
[submodule "lib/lufa"]
path = lib/lufa
url = https://github.com/qmk/lufa
[submodule "lib/vusb"]
path = lib/vusb
url = https://github.com/qmk/v-usb
[submodule "lib/printf"]
path = lib/printf
url = https://github.com/qmk/printf

1
qmk/api_data/_config.yml Normal file
View File

@ -0,0 +1 @@
theme: jekyll-theme-cayman

5
qmk/api_data/readme.md Normal file
View File

@ -0,0 +1,5 @@
# QMK Keyboard Metadata
This directory contains machine parsable data about keyboards supported by QMK. The latest version is always available online at <https://keyboards.qmk.fm>.
Do not edit anything here by hand. It is generated with the `qmk generate-api` command.

View File

@ -28,6 +28,7 @@
# bootloadHID HIDBootFlash compatible (ATmega32A)
# USBasp USBaspLoader (ATmega328P)
# kiibohd Input:Club Kiibohd bootloader (only used on their boards)
# stm32duino STM32Duino (STM32F103x8)
#
# BOOTLOADER_SIZE can still be defined manually, but it's recommended
# you add any possible configuration to this list
@ -35,30 +36,30 @@
ifeq ($(strip $(BOOTLOADER)), atmel-dfu)
OPT_DEFS += -DBOOTLOADER_ATMEL_DFU
OPT_DEFS += -DBOOTLOADER_DFU
ifneq (,$(filter $(MCU), at90usb646 atmega16u2 atmega16u4 atmega32u2 atmega32u4))
ifneq (,$(filter $(MCU), atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647))
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(MCU)), at90usb1286)
ifneq (,$(filter $(MCU), at90usb1286 at90usb1287))
BOOTLOADER_SIZE = 8192
endif
endif
ifeq ($(strip $(BOOTLOADER)), lufa-dfu)
OPT_DEFS += -DBOOTLOADER_LUFA_DFU
OPT_DEFS += -DBOOTLOADER_DFU
ifneq (,$(filter $(MCU), at90usb646 atmega16u2 atmega16u4 atmega32u2 atmega32u4))
ifneq (,$(filter $(MCU), atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647))
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(MCU)), at90usb1286)
ifneq (,$(filter $(MCU), at90usb1286 at90usb1287))
BOOTLOADER_SIZE = 8192
endif
endif
ifeq ($(strip $(BOOTLOADER)), qmk-dfu)
OPT_DEFS += -DBOOTLOADER_QMK_DFU
OPT_DEFS += -DBOOTLOADER_DFU
ifneq (,$(filter $(MCU), at90usb646 atmega16u2 atmega16u4 atmega32u2 atmega32u4))
ifneq (,$(filter $(MCU), atmega16u2 atmega32u2 atmega16u4 atmega32u4 at90usb646 at90usb647))
BOOTLOADER_SIZE = 4096
endif
ifeq ($(strip $(MCU)), at90usb1286)
ifneq (,$(filter $(MCU), at90usb1286 at90usb1287))
BOOTLOADER_SIZE = 8192
endif
endif
@ -106,3 +107,14 @@ ifeq ($(strip $(BOOTLOADER)), kiibohd)
DFU_ARGS = -d 1C11:B007
DFU_SUFFIX_ARGS = -v 1C11 -p B007
endif
ifeq ($(strip $(BOOTLOADER)), stm32duino)
OPT_DEFS += -DBOOTLOADER_STM32DUINO
MCU_LDSCRIPT = STM32F103x8_stm32duino_bootloader
BOARD = STM32_F103_STM32DUINO
# STM32F103 does NOT have an USB bootloader in ROM (only serial), so setting anything here does not make much sense
STM32_BOOTLOADER_ADDRESS = 0x80000000
DFU_ARGS = -d 1EAF:0003 -a2 -R
DFU_SUFFIX_ARGS = -v 1EAF -p 0003
endif

View File

@ -114,6 +114,17 @@ else
SRC += $(PLATFORM_COMMON_DIR)/flash_stm32.c
OPT_DEFS += -DEEPROM_EMU_STM32F072xB
OPT_DEFS += -DSTM32_EEPROM_ENABLE
else ifeq ($(MCU_SERIES)_$(MCU_LDSCRIPT), STM32F0xx_STM32F042x6)
# Stack sizes: Since this chip has limited RAM capacity, the stack area needs to be reduced.
# This ensures that the EEPROM page buffer fits into RAM
USE_PROCESS_STACKSIZE = 0x600
USE_EXCEPTIONS_STACKSIZE = 0x300
SRC += $(PLATFORM_COMMON_DIR)/eeprom_stm32.c
SRC += $(PLATFORM_COMMON_DIR)/flash_stm32.c
OPT_DEFS += -DEEPROM_EMU_STM32F042x6
OPT_DEFS += -DSTM32_EEPROM_ENABLE
else ifneq ($(filter $(MCU_SERIES),STM32L0xx STM32L1xx),)
OPT_DEFS += -DEEPROM_DRIVER
COMMON_VPATH += $(DRIVER_PATH)/eeprom
@ -173,6 +184,10 @@ ifeq ($(filter $(RGB_MATRIX_ENABLE),$(VALID_MATRIX_TYPES)),)
$(error RGB_MATRIX_ENABLE="$(RGB_MATRIX_ENABLE)" is not a valid matrix type)
endif
OPT_DEFS += -DRGB_MATRIX_ENABLE
ifneq (,$(filter $(MCU), atmega16u2 atmega32u2))
# ATmegaxxU2 does not have hardware MUL instruction - lib8tion must be told to use software multiplication routines
OPT_DEFS += -DLIB8_ATTINY
endif
SRC += $(QUANTUM_DIR)/color.c
SRC += $(QUANTUM_DIR)/rgb_matrix.c
SRC += $(QUANTUM_DIR)/rgb_matrix_drivers.c

View File

@ -23,6 +23,7 @@
* [Overview](api_overview.md)
* [API Documentation](api_docs.md)
* [Keyboard Support](reference_configurator_support.md)
* [Adding Default Keymaps](configurator_default_keymaps.md)
* CLI
* [Overview](cli.md)
@ -117,6 +118,7 @@
* [Overview](breaking_changes.md)
* [My Pull Request Was Flagged](breaking_changes_instructions.md)
* History
* [2020 Aug 29](ChangeLog/20200829.md)
* [2020 May 30](ChangeLog/20200530.md)
* [2020 Feb 29](ChangeLog/20200229.md)
* [2019 Aug 30](ChangeLog/20190830.md)

View File

@ -167,6 +167,17 @@ Creates a keymap.c from a QMK Configurator export.
qmk json2c [-o OUTPUT] filename
```
## `qmk c2json`
Creates a keymap.json from a keymap.c.
**Note:** Parsing C source files is not easy, therefore this subcommand may not work your keymap. In some cases not using the C pre-processor helps.
**Usage**:
```
qmk c2json [--no-cpp] [-o OUTPUT] filename
```
## `qmk list-keyboards`
This command lists all the keyboards currently defined in `qmk_firmware`

View File

@ -0,0 +1,193 @@
# Adding Default Keymaps to QMK Configurator :id=adding-default-keymaps
This page covers how to add a default keymap for a keyboard to QMK Configurator.
## Technical Information :id=technical-information
QMK Configurator uses JSON as its native file format for keymaps. As much as possible, these should be kept such that they behave the same as running `make <keyboard>:default` from `qmk_firmware`.
Keymaps in this directory require four key-value pairs:
* `keyboard` (string)
* This is the name of the keyboard, the same as would be used when running a compile job through `make` (e.g. `make 1upkeyboards/1up60rgb:default`).
* `keymap` (string)
* Should be set to `default`.
* `layout` (string)
* This is the layout macro used by the default keymap.
* `layers` (array)
* The keymap itself. This key should contain one array per layer, which themselves should contain the keycodes that make up that layer.
Additionally, most keymaps contain a `commit` key. This key is not consumed by the API that back-stops QMK Configurator, but is used by Configurator's maintainers to tell which version of a keymap was used to create the JSON keymap in this repository. The value is the SHA of the last commit to modify a board's default `keymap.c` in the `qmk_firmware` repository. The SHA is found by checking out [the `master` branch of the `qmk/qmk_firmware` repository](https://github.com/qmk/qmk_firmware/tree/master/) and running `git log -1 --pretty=oneline -- keyboards/<keyboard>/keymaps/default/keymap.c` (use `keymap.json` if the keyboard in question has this file instead), which should return something similar to:
```shell
f14629ed1cd7c7ec9089604d64f29a99981558e8 Remove/migrate action_get_macro()s from default keymaps (#5625)
```
In this example, `f14629ed1cd7c7ec9089604d64f29a99981558e8` is the value that should be used for `commit`.
## Example :id=example
If one wished to add a default keymap for the H87a by Hineybush, one would run the `git log` command above against the H87a's default keymap in `qmk_firmware`:
```shell
user ~/qmk_firmware (master)
$ git log -1 --pretty=oneline master -- keyboards/hineybush/h87a/keymaps/default/keymap.c
ef8878fba5d3786e3f9c66436da63a560cd36ac9 Hineybush h87a lock indicators (#8237)
```
Now that we have the commit hash, we need the keymap (edited for readability):
```c
...
#include QMK_KEYBOARD_H
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT_all(
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_SLCK, KC_PAUS,
KC_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_BSPC, KC_INS, KC_HOME, KC_PGUP,
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL, KC_END, KC_PGDN,
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_NUHS, KC_ENT,
KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_TRNS, KC_UP,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_RGUI, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT),
[1] = LAYOUT_all(
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_TOG, RGB_MOD, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, RGB_VAD, RGB_VAI, BL_TOGG, BL_DEC, BL_INC,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLU,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RESET, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_MPLY, KC_MNXT, KC_VOLD,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
};
```
The default keymap uses the `LAYOUT_all` macro, so that will be the value of the `layout` key. Compiled to a QMK Configurator JSON keymap, our resulting file should be:
```json
{
"keyboard": "hineybush/h87a",
"keymap": "default",
"commit": "ef8878fba5d3786e3f9c66436da63a560cd36ac9",
"layout": "LAYOUT_all",
"layers": [
[
"KC_ESC", "KC_F1", "KC_F2", "KC_F3", "KC_F4", "KC_F5", "KC_F6", "KC_F7", "KC_F8", "KC_F9", "KC_F10", "KC_F11", "KC_F12", "KC_PSCR", "KC_SLCK", "KC_PAUS",
"KC_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_BSPC", "KC_INS", "KC_HOME", "KC_PGUP",
"KC_TAB", "KC_Q", "KC_W", "KC_E", "KC_R", "KC_T", "KC_Y", "KC_U", "KC_I", "KC_O", "KC_P", "KC_LBRC", "KC_RBRC", "KC_BSLS", "KC_DEL", "KC_END", "KC_PGDN",
"KC_CAPS", "KC_A", "KC_S", "KC_D", "KC_F", "KC_G", "KC_H", "KC_J", "KC_K", "KC_L", "KC_SCLN", "KC_QUOT", "KC_NUHS", "KC_ENT",
"KC_LSFT", "KC_NUBS", "KC_Z", "KC_X", "KC_C", "KC_V", "KC_B", "KC_N", "KC_M", "KC_COMM", "KC_DOT", "KC_SLSH", "KC_RSFT", "KC_TRNS", "KC_UP",
"KC_LCTL", "KC_LGUI", "KC_LALT", "KC_SPC", "KC_RALT", "MO(1)", "KC_RGUI", "KC_RCTL", "KC_LEFT", "KC_DOWN", "KC_RGHT"
],
[
"KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "RGB_TOG", "RGB_MOD", "RGB_HUD", "RGB_HUI", "RGB_SAD", "RGB_SAI", "RGB_VAD", "RGB_VAI", "BL_TOGG", "BL_DEC", "BL_INC",
"KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_VOLU",
"KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "RESET", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_MPLY", "KC_MNXT", "KC_VOLD",
"KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS",
"KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS",
"KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS", "KC_TRNS"
]
]
}
```
The white space in the `layers` arrays have no effect on the functionality of the keymap, but are used to make these files easier for humans to read.
## Caveats :id=caveats
### Layers can only be referenced by number :id=layer-references
A common QMK convention is to name layers using a series of `#define`s, or an `enum` statement:
```c
enum layer_names {
_BASE,
_MEDIA,
_FN
};
```
This works in C, but for Configurator, you *must* use the layer's numeric index `MO(_FN)` would need to be `MO(2)` in the above example.
### No support for custom code of any kind :id=custom-code
Features that require adding functions to the keymap.c file, such as Tap Dance or Unicode, can not be compiled in Configurator **at all**. Even setting `TAP_DANCE_ENABLE = yes` in the `qmk_firmware` repository at the keyboard level will prevent Configurator from compiling **any** firmware for that keyboard. This is limited both by the API and the current spec of our JSON keymap format.
### Limited Support for Custom keycodes :id=custom-keycodes
There is a way to support custom keycodes: if the logic for a custom keycode is implemented at the keyboard level instead of the keymap level in qmk_firmware, that keycode *can* be used in Configurator and it *will* compile and work. Instead of using the following in your `keymap.c`:
```c
enum custom_keycodes {
MACRO_1 = SAFE_RANGE,
MACRO_2,
MACRO_3
};
...
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch(keycode) {
case MACRO_1:
if (record->event.pressed) {
SEND_STRING("This is macro #1.");
}
return false;
case MACRO_2:
if (record->event.pressed) {
SEND_STRING("This is macro #2.");
}
return false;
case MACRO_3:
if (record->event.pressed) {
SEND_STRING("This is macro #3.");
}
return false;
}
return true;
};
```
... add the keycode `enum` block to your keyboard's header file (`<keyboard>.h`) as follows (note that the `enum` is named `keyboard_keycodes` here):
```c
enum keyboard_keycodes {
MACRO_1 = SAFE_RANGE,
MACRO_2,
MACRO_3,
NEW_SAFE_RANGE // Important!
};
```
... then the logic to your `<keyboard>.c` through `process_record_kb()`:
```c
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
switch(keycode) {
case MACRO_1:
if (record->event.pressed) {
SEND_STRING("This is macro #1.");
}
return false;
case MACRO_2:
if (record->event.pressed) {
SEND_STRING("This is macro #2.");
}
return false;
case MACRO_3:
if (record->event.pressed) {
SEND_STRING("This is macro #3.");
}
return false;
}
return process_record_user(keycode, record);
};
```
Note the call to `process_record_user()` at the end. Additionally, users of the keyboard will need to use `NEW_SAFE_RANGE` instead of `SAFE_RANGE` if they wish to add their own custom keycodes at keymap level, beyond what is provided by the keyboard.
## Additional Reading :id=additional-reading
For QMK Configurator to support your keyboard, your keyboard must be present in the `master` branch of the `qmk_firmware` repository. For instructions on this, please see [Supporting Your Keyboard in QMK Configurator](reference_configurator_support.md).

View File

@ -4,7 +4,7 @@ QMK presents itself to the host as a regular HID keyboard device, and as such re
There are two notable exceptions: the Caterina bootloader, usually seen on Pro Micros, and the HalfKay bootloader shipped with PJRC Teensys, appear as a serial port and a generic HID device respectively, and so do not require a driver.
We recommend the use of the [Zadig](https://zadig.akeo.ie/) utility. If you have set up the development environment with MSYS2 or WSL, the `qmk_install.sh` script will have asked if you want it to install the drivers for you.
We recommend the use of the [Zadig](https://zadig.akeo.ie/) utility. If you have set up the development environment with MSYS2, the `qmk_install.sh` script will have already installed the drivers for you.
## Installation

View File

@ -13,65 +13,29 @@ An example of using `sudo`, when your controller is ATMega32u4:
or just:
$ sudo make <keyboard>:<keymap>:dfu
$ sudo make <keyboard>:<keymap>:flash
Note that running `make` with `sudo` is generally ***not*** a good idea, and you should use one of the former methods, if possible.
### Linux `udev` Rules
On Linux, you'll need proper privileges to access the MCU. You can either use
`sudo` when flashing firmware, or place these files in `/etc/udev/rules.d/`. Once added run the following:
```console
On Linux, you'll need proper privileges to communicate with the bootloader device. You can either use `sudo` when flashing firmware (not recommended), or place [this file](https://github.com/qmk/qmk_firmware/tree/master/util/udev/50-qmk.rules) into `/etc/udev/rules.d/`.
Once added, run the following:
```
sudo udevadm control --reload-rules
sudo udevadm trigger
```
**/etc/udev/rules.d/50-atmel-dfu.rules:**
```
# Atmel ATMega32U4
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff4", TAG+="uaccess", RUN{builtin}+="uaccess"
# Atmel USBKEY AT90USB1287
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ffb", TAG+="uaccess", RUN{builtin}+="uaccess"
# Atmel ATMega32U2
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff0", TAG+="uaccess", RUN{builtin}+="uaccess"
```
**/etc/udev/rules.d/54-input-club-keyboard.rules:**
**Note:** With older versions of ModemManager (< 1.12), filtering only works when not in strict mode. The following commands can update that setting:
```
# Input Club keyboard bootloader
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1c11", ATTRS{idProduct}=="b007", TAG+="uaccess", RUN{builtin}+="uaccess"
```
**/etc/udev/rules.d/55-caterina.rules:**
```
# ModemManager should ignore the following devices
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="0036", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0036", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9205", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9203", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
```
**Note:** With older (before 1.12) ModemManager, filtering only works when not in strict mode, the following commands can update that settings:
```console
printf '[Service]\nExecStart=\nExecStart=/usr/sbin/ModemManager --filter-policy=default' | sudo tee /etc/systemd/system/ModemManager.service.d/policy.conf
sudo systemctl daemon-reload
sudo systemctl restart ModemManager
```
**/etc/udev/rules.d/56-dfu-util.rules:**
```
# stm32duino
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1eaf", ATTRS{idProduct}=="0003", TAG+="uaccess", RUN{builtin}+="uaccess"
# Generic stm32
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="df11", TAG+="uaccess", RUN{builtin}+="uaccess"
```
**/etc/udev/rules.d/57-bootloadhid.rules:**
```
# bootloadHID
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05df", TAG+="uaccess", RUN{builtin}+="uaccess"
```
### Serial device is not detected in bootloader mode on Linux
Make sure your kernel has appropriate support for your device. If your device uses USB ACM, such as
Pro Micro (Atmega32u4), make sure to include `CONFIG_USB_ACM=y`. Other devices may require `USB_SERIAL` and any of its sub options.
@ -96,46 +60,6 @@ You can buy a really unique VID:PID here. I don't think you need this for person
- http://www.obdev.at/products/vusb/license.html
- http://www.mcselec.com/index.php?page=shop.product_details&flypage=shop.flypage&product_id=92&option=com_phpshop&Itemid=1
## BOOTLOADER_SIZE for AVR
Note that Teensy2.0++ bootloader size is 2048byte. Some Makefiles may have wrong comment.
```
# Boot Section Size in *bytes*
# Teensy halfKay 512
# Teensy++ halfKay 2048
# Atmel DFU loader 4096 (TMK Alt Controller)
# LUFA bootloader 4096
# USBaspLoader 2048
OPT_DEFS += -DBOOTLOADER_SIZE=2048
```
## `avr-gcc: internal compiler error: Abort trap: 6 (program cc1)` on MacOS
This is an issue with updating on brew, causing symlinks that avr-gcc depend on getting mangled.
The solution is to remove and reinstall all affected modules.
```
brew rm avr-gcc avr-gcc@8 dfu-programmer dfu-util gcc-arm-none-eabi arm-gcc-bin@8 avrdude qmk
brew install qmk/qmk/qmk
brew link --force avr-gcc@8
brew link --force arm-gcc-bin@8
```
### `avr-gcc` and LUFA
If you updated your `avr-gcc` and you see errors involving LUFA, for example:
`lib/lufa/LUFA/Drivers/USB/Class/Device/AudioClassDevice.h:380:5: error: 'const' attribute on function returning 'void'`
For now, you need to rollback `avr-gcc` to 8 in Homebrew.
```
brew uninstall --force avr-gcc
brew install avr-gcc@8
brew link --force avr-gcc@8
```
### I just flashed my keyboard and it does nothing/keypresses don't register - it's also ARM (rev6 planck, clueboard 60, hs60v2, etc...) (Feb 2019)
Due to how EEPROM works on ARM based chips, saved settings may no longer be valid. This affects the default layers, and *may*, under certain circumstances we are still figuring out, make the keyboard unusable. Resetting the EEPROM will correct this.

View File

@ -31,20 +31,6 @@ Check:
- try using 'print' function instead of debug print. See **common/print.h**.
- disconnect other devices with console function. See [Issue #97](https://github.com/tmk/tmk_keyboard/issues/97).
## Linux or UNIX Like System Requires Super User Privilege
Just use 'sudo' to execute *hid_listen* with privilege.
```
$ sudo hid_listen
```
Or add an *udev rule* for TMK devices with placing a file in rules directory. The directory may vary on each system.
File: /etc/udev/rules.d/52-tmk-keyboard.rules(in case of Ubuntu)
```
# tmk keyboard products https://github.com/tmk/tmk_keyboard
SUBSYSTEMS=="usb", ATTRS{idVendor}=="feed", MODE:="0666"
```
***
# Miscellaneous

View File

@ -2,21 +2,24 @@
These allow you to combine a modifier with a keycode. When pressed, the keydown event for the modifier, then `kc` will be sent. On release, the keyup event for `kc`, then the modifier will be sent.
|Key |Aliases |Description |
|----------|-------------------------------|----------------------------------------------------|
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|`LALT(kc)`|`A(kc)`, `LOPT(kc)` |Hold Left Alt and press `kc` |
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)`|Hold Left GUI and press `kc` |
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|`RALT(kc)`|`ROPT(kc)`, `ALGR(kc)` |Hold Right Alt and press `kc` |
|`RGUI(kc)`|`RCMD(kc)`, `LWIN(kc)` |Hold Right GUI and press `kc` |
|`SGUI(kc)`|`SCMD(kc)`, `SWIN(kc)` |Hold Left Shift and GUI and press `kc` |
|`LCA(kc)` | |Hold Left Control and Alt and press `kc` |
|`LCAG(kc)`| |Hold Left Control, Alt and GUI and press `kc` |
|`MEH(kc)` | |Hold Left Control, Shift and Alt and press `kc` |
|`HYPR(kc)`| |Hold Left Control, Shift, Alt and GUI and press `kc`|
|Key |Aliases |Description |
|----------|-------------------------------|------------------------------------------------------|
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|`LALT(kc)`|`A(kc)`, `LOPT(kc)` |Hold Left Alt and press `kc` |
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)`|Hold Left GUI and press `kc` |
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|`RALT(kc)`|`ROPT(kc)`, `ALGR(kc)` |Hold Right Alt and press `kc` |
|`RGUI(kc)`|`RCMD(kc)`, `LWIN(kc)` |Hold Right GUI and press `kc` |
|`SGUI(kc)`|`SCMD(kc)`, `SWIN(kc)` |Hold Left Shift and GUI and press `kc` |
|`LCA(kc)` | |Hold Left Control and Alt and press `kc` |
|`LSA(kc)` | |Hold Left Shift and Left Alt and press `kc` |
|`RSA(kc)` |`SAGR(kc)` |Hold Right Shift and Right Alt (AltGr) and press `kc` |
|`RCS(kc)` | |Hold Right Control and Right Shift and press `kc` |
|`LCAG(kc)`| |Hold Left Control, Alt and GUI and press `kc` |
|`MEH(kc)` | |Hold Left Control, Shift and Alt and press `kc` |
|`HYPR(kc)`| |Hold Left Control, Shift, Alt and GUI and press `kc` |
You can also chain them, for example `LCTL(LALT(KC_DEL))` or `C(A(KC_DEL))` makes a key that sends Control+Alt+Delete with a single keypress.

View File

@ -26,7 +26,10 @@ A Bluefruit UART friend can be converted to an SPI friend, however this [require
<!-- FIXME: Document bluetooth support more completely. -->
## Bluetooth Rules.mk Options
Use only one of these
The currently supported Bluetooth chipsets do not support [N-Key Rollover (NKRO)](reference_glossary.md#n-key-rollover-nkro), so `rules.mk` must contain `NKRO_ENABLE = no`.
Use only one of these to enable Bluetooth:
* BLUETOOTH_ENABLE = yes (Legacy Option)
* BLUETOOTH = RN42
* BLUETOOTH = AdafruitBLE

View File

@ -55,7 +55,7 @@ combo_t key_combos[COMBO_COUNT] = {
[XV_PASTE] = COMBO_ACTION(paste_combo),
};
void process_combo_event(uint8_t combo_index, bool pressed) {
void process_combo_event(uint16_t combo_index, bool pressed) {
switch(combo_index) {
case ZC_COPY:
if (pressed) {

View File

@ -76,8 +76,8 @@ susceptible to noise, you must choose a debounce method that will also mitigate
* Defer algorithms are noise-resistant
* Recommended naming conventions:
* ```sym_defer_*```
* ```asym_defer_*_*```: key-down is using eager algorithm
* ```asym_*_defer_*```: key-up is using eager algorithm
* ```asym_defer_*_*```: key-down is using defer algorithm
* ```asym_*_defer_*```: key-up is using defer algorithm
4) Global vs Per-Key vs Per-Row
* Global - one timer for all keys. Any key change state affects global timer

View File

@ -140,8 +140,8 @@ void oled_task_user(void) {
|---------------------------|-----------------|--------------------------------------------------------------------------------------------------------------------------|
|`OLED_DISPLAY_ADDRESS` |`0x3C` |The i2c address of the OLED Display |
|`OLED_FONT_H` |`"glcdfont.c"` |The font code file to use for custom fonts |
|`OLED_FONT_START` |`0` |The starting characer index for custom fonts |
|`OLED_FONT_END` |`223` |The ending characer index for custom fonts |
|`OLED_FONT_START` |`0` |The starting character index for custom fonts |
|`OLED_FONT_END` |`223` |The ending character index for custom fonts |
|`OLED_FONT_WIDTH` |`6` |The font width |
|`OLED_FONT_HEIGHT` |`8` |The font height (untested) |
|`OLED_TIMEOUT` |`60000` |Turns off the OLED screen after 60000ms of keyboard inactivity. Helps reduce OLED Burn-in. Set to 0 to disable. |
@ -149,6 +149,7 @@ void oled_task_user(void) {
|`OLED_SCROLL_TIMEOUT_RIGHT`|*Not defined* |Scroll timeout direction is right when defined, left when undefined. |
|`OLED_IC` |`OLED_IC_SSD1306`|Set to `OLED_IC_SH1106` if you're using the SH1106 OLED controller. |
|`OLED_COLUMN_OFFSET` |`0` |(SH1106 only.) Shift output to the right this many pixels.<br />Useful for 128x64 displays centered on a 132x64 SH1106 IC.|
|`OLED_BRIGHTNESS` |`255` |The default brightness level of the OLED, from 0 to 255. |
## 128x64 & Custom sized OLED Displays
@ -300,6 +301,16 @@ bool oled_on(void);
// Returns true if the screen was off or turns off
bool oled_off(void);
// Returns true if the oled is currently on, false if it is
// not
bool is_oled_on(void);
// Sets the brightness level of the display
uint8_t oled_set_brightness(uint8_t level);
// Gets the current brightness level of the display
uint8_t oled_get_brightness(void);
// Basically it's oled_render, but with timeout management and oled_task_user calling!
void oled_task(void);

View File

@ -192,7 +192,7 @@ When developing your keyboard, keep in mind that all warnings will be treated as
## Copyright Blurb
If you're adapting your keyboard's setup from another project, but not using the same code, but sure to update the copyright header at the top of the files to show your name, in this format:
If you're adapting your keyboard's setup from another project, but not using the same code, be sure to update the copyright header at the top of the files to show your name, in this format:
Copyright 2017 Your Name <your@email.com>

View File

@ -116,6 +116,7 @@
* [概要](ja/breaking_changes.md)
* [プルリクエストにフラグが付けられた](ja/breaking_changes_instructions.md)
* 履歴
* [2020年8月29日](ja/ChangeLog/20200829.md)
* [2020年5月30日](ja/ChangeLog/20200530.md)
* [2020年2月29日](ja/ChangeLog/20200229.md)
* [2019年8月30日](ja/ChangeLog/20190830.md)

View File

@ -2,8 +2,8 @@
<!---
grep --no-filename "^[ ]*git diff" docs/ja/*.md | sh
original document: 0.9.0:docs/breaking_changes.md
git diff 0.9.0 HEAD -- docs/breaking_changes.md | cat
original document: 0.10.33:docs/breaking_changes.md
git diff 0.10.33 HEAD -- docs/breaking_changes.md | cat
-->
このドキュメントは QMK の互換性を破る変更(Breaking change) のプロセスについて説明します。
@ -15,22 +15,23 @@ Breaking change ピリオドとは、危険な変更、または予想外の変
## 過去の Breaking change には何が含まれますか?
* [2020年8月29日](ja/ChangeLog/20200829.md)
* [2020年5月30日](ja/ChangeLog/20200530.md)
* [2020年2月29日](ja/ChangeLog/20200229.md)
* [2019年8月30日](ja/ChangeLog/20190830.md)
## 次の Breaking change はいつですか?
次の Breaking change は2020年8月29日に予定されています。
次の Breaking change は2020年11月28日に予定されています。
### 重要な日付
* [x] 2020年 5月30日 - `develop` が作成されました。毎週リベースされます。
* [ ] 2020年 8月 1日 - `develop` は新しいPRを取り込みません。
* [ ] 2020年 8月 1日 - テスターの募集。
* [ ] 2020年 8月27日 - `master`がロックされ、PR はマージされません。
* [ ] 2020年 8月29日 - `develop``master` にマージします。
* [ ] 2020年 8月29日 - `master` のロックが解除されます。PR を再びマージすることができます。
* [x] 2020年 8月29日 - `develop` が作成されました。毎週リベースされます。
* [ ] 2020年10月31日 - `develop` は新しいPRを取り込みません。
* [ ] 2020年10月31日 - テスターの募集。
* [ ] 2020年11月26日 - `master`がロックされ、PR はマージされません。
* [ ] 2020年11月28日 - `develop``master` にマージします。
* [ ] 2020年11月28日 - `master` のロックが解除されます。PR を再びマージすることができます。
## どのような変更が含まれますか?

View File

@ -1,8 +1,8 @@
# QMK の設定
<!---
original document: 0.9.43:docs/config_options.md
git diff 0.9.43 HEAD -- docs/config_options.md | cat
original document: 0.10.33:docs/config_options.md
git diff 0.10.33 HEAD -- docs/config_options.md | cat
-->
QMK はほぼ無制限に設定可能です。可能なところはいかなるところでも、やりすぎな程、ユーザーがコードサイズを犠牲にしてでも彼らのキーボードをカスタマイズをすることを許しています。ただし、このレベルの柔軟性により設定が困難になります。

View File

@ -31,7 +31,7 @@ keyboards/<keyboard>/matrix.c
SRC += matrix.c
```
## マトリックスコードの部分置き換え
## マトリックスコードの部分置き換え :id=lite
カスタムマトリックスを実装する際、定型コードを書かなくてすむように、さまざまなスキャン関数のデフォルト実装を提供しています。

View File

@ -1,8 +1,8 @@
# キーボードの挙動をカスタマイズする方法
<!---
original document: 0.9.43:docs/custom_quantum_functions.md
git diff 0.9.43 HEAD -- docs/custom_quantum_functions.md | cat
original document: 0.10.33:docs/custom_quantum_functions.md
git diff 0.10.33 HEAD -- docs/custom_quantum_functions.md | cat
-->
多くの人にとって、カスタムキーボードはボタンの押下をコンピュータに送信するだけではありません。単純なボタンの押下やマクロよりも複雑なことを実行できるようにしたいでしょう。QMK にはコードを挿入したり、機能を上書きしたり、様々な状況でキーボードの挙動をカスタマイズできるフックがあります。
@ -232,7 +232,7 @@ void keyboard_pre_init_user(void) {
}
```
### `keyboard_pre_init_*` 関数のドキュメント
### `keyboard_pre_init_*` 関数のドキュメント :id=keyboard_pre_init_-function-documentation
* キーボード/リビジョン: `void keyboard_pre_init_kb(void)`
* キーマップ: `void keyboard_pre_init_user(void)`

View File

@ -1,8 +1,8 @@
# ドキュメントベストプラクティス
<!---
original document: 0.9.19:docs/documentation_best_practices.md
git diff 0.9.19 HEAD -- docs/documentation_best_practices.md | cat
original document: 0.10.33:docs/documentation_best_practices.md
git diff 0.10.33 HEAD -- docs/documentation_best_practices.md | cat
-->
このページは QMK のためのドキュメントを作成する時のベストプラクティスを文章化するためのものです。これらのガイドラインに従うことで、一貫したトーンとスタイルを維持することでき、他の人が QMK をより理解しやすくすることができます。

View File

@ -1,8 +1,8 @@
# よくあるビルドの質問
<!---
original document: 0.9.43:docs/faq_build.md
git diff 0.9.43 HEAD -- docs/faq_build.md | cat
original document: 0.10.33:docs/faq_build.md
git diff 0.10.33 HEAD -- docs/faq_build.md | cat
-->
このページは QMK のビルドに関する質問を説明します。まだビルドをしていない場合は、[ビルド環境のセットアップ](ja/getting_started_build_tools.md) および [Make 手順](ja/getting_started_make_guide.md)ガイドを読むべきです。
@ -18,64 +18,93 @@
あるいは、単純に:
$ sudo make <keyboard>:<keymap>:dfu
$ sudo make <keyboard>:<keymap>:flash
`make``sudo` で実行することは一般的には良い考えでは***なく***、可能であれば前者の方法のいずれかを使うべきです。
### Linux の `udev` ルール
Linux では、MCU にアクセスするには適切な権限が必要です。ファームウェアを書き込む時に `sudo` を使うか、`/etc/udev/rules.d/` にこれらのファイルを配置することで、アクセスすることができます。権限の追加が完了したら、以下を実行します:
```console
Linux では、ブートローダデバイスと通信するには適切な権限が必要です。ファームウェアを書き込む時に `sudo` を使うか、`/etc/udev/rules.d/` にこのファイルを配置することで、通信することができます。
**/etc/udev/rules.d/50-qmk.rules:**
```
# Atmel DFU
### ATmega16U2
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="2FEF", TAG+="uaccess", RUN{builtin}+="uaccess"
### ATmega32U2
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="2FF0", TAG+="uaccess", RUN{builtin}+="uaccess"
### ATmega16U4
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="2FF3", TAG+="uaccess", RUN{builtin}+="uaccess"
### ATmega32U4
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="2FF4", TAG+="uaccess", RUN{builtin}+="uaccess"
### AT90USB64
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="2FF9", TAG+="uaccess", RUN{builtin}+="uaccess"
### AT90USB128
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="2FFB", TAG+="uaccess", RUN{builtin}+="uaccess"
# Input Club
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1C11", ATTRS{idProduct}=="B007", TAG+="uaccess", RUN{builtin}+="uaccess"
# STM32duino
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1EAF", ATTRS{idProduct}=="0003", TAG+="uaccess", RUN{builtin}+="uaccess"
# STM32 DFU
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="DF11", TAG+="uaccess", RUN{builtin}+="uaccess"
# BootloadHID
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16C0", ATTRS{idProduct}=="05DF", TAG+="uaccess", RUN{builtin}+="uaccess"
# USBAspLoader
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16C0", ATTRS{idProduct}=="05DC", TAG+="uaccess", RUN{builtin}+="uaccess"
# ModemManager should ignore the following devices
# Atmel SAM-BA (Massdrop)
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03EB", ATTRS{idProduct}=="6124", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
# Caterina (Pro Micro)
## Spark Fun Electronics
### Pro Micro 3V3/8MHz
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1B4F", ATTRS{idProduct}=="9203", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Pro Micro 5V/16MHz
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1B4F", ATTRS{idProduct}=="9205", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### LilyPad 3V3/8MHz (and some Pro Micro clones)
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1B4F", ATTRS{idProduct}=="9207", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
## Pololu Electronics
### A-Star 32U4
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1FFB", ATTRS{idProduct}=="0101", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
## Arduino SA
### Leonardo
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0036", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Micro
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0037", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
## Adafruit Industries LLC
### Feather 32U4
SUBSYSTEMS=="usb", ATTRS{idVendor}=="239A", ATTRS{idProduct}=="000C", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### ItsyBitsy 32U4 3V3/8MHz
SUBSYSTEMS=="usb", ATTRS{idVendor}=="239A", ATTRS{idProduct}=="000D", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### ItsyBitsy 32U4 5V/16MHz
SUBSYSTEMS=="usb", ATTRS{idVendor}=="239A", ATTRS{idProduct}=="000E", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
## dog hunter AG
### Leonardo
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2A03", ATTRS{idProduct}=="0036", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
### Micro
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2A03", ATTRS{idProduct}=="0037", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
```
追加が完了したら、以下を実行します:
```
sudo udevadm control --reload-rules
sudo udevadm trigger
```
**/etc/udev/rules.d/50-atmel-dfu.rules:**
```
# Atmel ATMega32U4
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff4", TAG+="uaccess", RUN{builtin}+="uaccess"
# Atmel USBKEY AT90USB1287
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ffb", TAG+="uaccess", RUN{builtin}+="uaccess"
# Atmel ATMega32U2
SUBSYSTEMS=="usb", ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2ff0", TAG+="uaccess", RUN{builtin}+="uaccess"
```
**/etc/udev/rules.d/54-input-club-keyboard.rules:**
```
# Input Club keyboard bootloader
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1c11", ATTRS{idProduct}=="b007", TAG+="uaccess", RUN{builtin}+="uaccess"
```
**/etc/udev/rules.d/55-caterina.rules:**
```
# ModemManager should ignore the following devices
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="0036", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", ATTRS{idProduct}=="0036", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9205", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1b4f", ATTRS{idProduct}=="9203", TAG+="uaccess", RUN{builtin}+="uaccess", ENV{ID_MM_DEVICE_IGNORE}="1"
```
**注意:** 古い(1.12以前の) ModemManager では、フィルタリングは厳密なモードではない場合にのみ動作し、以下のコマンドはその設定を更新することができます。
```console
```
printf '[Service]\nExecStart=\nExecStart=/usr/sbin/ModemManager --filter-policy=default' | sudo tee /etc/systemd/system/ModemManager.service.d/policy.conf
sudo systemctl daemon-reload
sudo systemctl restart ModemManager
```
**/etc/udev/rules.d/56-dfu-util.rules:**
```
# stm32duino
SUBSYSTEMS=="usb", ATTRS{idVendor}=="1eaf", ATTRS{idProduct}=="0003", TAG+="uaccess", RUN{builtin}+="uaccess"
# Generic stm32
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="df11", TAG+="uaccess", RUN{builtin}+="uaccess"
```
**/etc/udev/rules.d/57-bootloadhid.rules:**
```
# bootloadHID
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05df", TAG+="uaccess", RUN{builtin}+="uaccess"
```
### Linux のブートローダモードで Serial デバイスが検知されない
カーネルがデバイスを適切にサポートしていることを確認してください。デバイスが、Pro Micro (Atmega32u4) のように USB ACM を使う場合、`CONFIG_USB_ACM=y` を含めるようにしてください。他のデバイスは `USB_SERIAL` およびそのサブオプションを必要とするかもしれません。
@ -99,46 +128,6 @@ https://github.com/tmk/tmk_keyboard/issues/150
- http://www.obdev.at/products/vusb/license.html
- http://www.mcselec.com/index.php?page=shop.product_details&flypage=shop.flypage&product_id=92&option=com_phpshop&Itemid=1
## AVR のための BOOTLOADER_SIZE
Teensy2.0++ ブートローダのサイズは 2048 バイトであることに注意してください。一部の Makefile には間違ったコメントがあります。
```
# Boot Section Size in *bytes*
# Teensy halfKay 512
# Teensy++ halfKay 2048
# Atmel DFU loader 4096 (TMK Alt Controller)
# LUFA bootloader 4096
# USBaspLoader 2048
OPT_DEFS += -DBOOTLOADER_SIZE=2048
```
## MacOS での `avr-gcc: internal compiler error: Abort trap: 6 (program cc1)`
これは brew での更新に関する問題で、avr-gcc が依存するシンボリックリンクを壊します。
解決法は全ての影響を受けたモジュールを削除し再インストールすることです。
```
brew rm avr-gcc avr-gcc@8 dfu-programmer dfu-util gcc-arm-none-eabi arm-gcc-bin@8 avrdude qmk
brew install qmk/qmk/qmk
brew link --force avr-gcc@8
brew link --force arm-gcc-bin@8
```
### `avr-gcc` と LUFA
`avr-gcc` を更新し、LUFA に関連するエラーが表示された場合、例えば:
`lib/lufa/LUFA/Drivers/USB/Class/Device/AudioClassDevice.h:380:5: error: 'const' attribute on function returning 'void'`
今のところ、Homebrew で `avr-gcc` を 8 にロールバックする必要があります。
```
brew uninstall --force avr-gcc
brew install avr-gcc@8
brew link --force avr-gcc@8
```
### キーボードに書き込んだが何も起こらない、あるいはキーの押下が登録されない - ARM (rev6 planck、clueboard 60、hs60v2 など) でも同じ (Feb 2019)
ARM ベースのチップ上での EEPROM の動作によって、保存された設定が無効になる場合があります。これはデフォルトレイヤに影響し、まだ調査中の特定の環境下でキーボードが使えなくなる*しれません*。EEPROM のリセットでこれが修正されます。

View File

@ -1,8 +1,8 @@
# デバッグの FAQ
<!---
original document: 0.9.10:docs/faq_debug.md
git diff 0.9.10 HEAD -- docs/faq_debug.md | cat
original document: 0.10.33:docs/faq_debug.md
git diff 0.10.33 HEAD -- docs/faq_debug.md | cat
-->
このページは、キーボードのトラブルシューティングについての様々な一般的な質問を説明します。
@ -36,20 +36,6 @@ Linux のような OS でデバイスにアクセスするには、権限が必
- デバッグ print の代わりに 'print' 関数を使ってみてください。**common/print.h** を見てください。
- コンソール機能を持つ他のデバイスを切断します。[Issue #97](https://github.com/tmk/tmk_keyboard/issues/97) を見てください。
## Linux あるいは UNIX のようなシステムはスーパーユーザ権限を必要とします
権限付きで *hid_listen* を実行するために 'sudo' を使ってください。
```
$ sudo hid_listen
```
または rules ディレクトリにファイルを置いて、TMK デバイスのための *udev rule* を追加します。ディレクトリは各システムで異なるかもしれません。
File: /etc/udev/rules.d/52-tmk-keyboard.rules (Ubuntu の場合)
```
# tmk keyboard products https://github.com/tmk/tmk_keyboard
SUBSYSTEMS=="usb", ATTRS{idVendor}=="feed", MODE:="0666"
```
***
# 雑多なこと

View File

@ -1,8 +1,8 @@
# 自動シフト: なぜシフトキーが必要ですか?
<!---
original document: 0.9.0:docs/feature_auto_shift.md
git diff 0.9.0 HEAD -- docs/feature_auto_shift.md | cat
original document: 0.10.33:docs/feature_auto_shift.md
git diff 0.10.33 HEAD -- docs/feature_auto_shift.md | cat
-->
キーをタップすると、その文字を取得します。キーをタップするが、*わずかに*長く押し続けると、シフト状態になります。ほら!シフトキーは必要ありません!
@ -109,7 +109,7 @@ AからZを含むアルファベット文字を自動シフトしません。
5. タイムアウトを増やすことに決めた場合は、`KC_ASUP` にマップしたキーを押し、ステップ1に戻ります。
6. 結果に満足したら、`KC_ASRP` にマップしたキーを押します。キーボードは `AUTO_SHIFT_TIMEOUT` の値を自動的に入力します。
7. 報告された値で `config.h``AUTO_SHIFT_TIMEOUT` を更新します。
8. `config.h` から `AUTO_SHIFT_SETUP` を削除します。
8. `config.h` `AUTO_SHIFT_NO_SETUP` を追加します。
9. `KC_ASDN`、`KC_ASUP` および `KC_ASRP` のキーバインディングを削除します。
10. 新しいファームウェアをコンパイルしてアップロードします。

View File

@ -1,8 +1,8 @@
# バックライト :id=backlighting
<!---
original document: 0.9.44:docs/feature_backlight.md
git diff 0.9.44 HEAD -- docs/feature_backlight.md | cat
original document: 0.10.33:docs/feature_backlight.md
git diff 0.10.33 HEAD -- docs/feature_backlight.md | cat
-->
多くのキーボードは、キースイッチを貫通して配置されたり、キースイッチの下に配置された個々の LED によって、バックライトキーをサポートします。この機能は通常スイッチごとに単一の色しか使用できないため、[RGB アンダーグロー](ja/feature_rgblight.md)および [RGB マトリックス](ja/feature_rgb_matrix.md)機能のどちらとも異なりますが、キーボードに複数の異なる単一色の LED を取り付けることは当然可能です。
@ -165,8 +165,6 @@ BACKLIGHT_DRIVER = pwm
現在のところ、ハードウェア PWM のみがサポートされ、タイマー支援はなく、自動設定は提供されません。
?> STM32F072 のバックライトサポートのテストは制限されています。人によって違うかもしれません。不明な場合は、`rules.mk` で `BACKLIGHT_ENABLE = no` を設定します。
### ソフトウェア PWM ドライバ :id=software-pwm-driver
このモードでは、他のキーボードのタスクを実行中に PWM は「エミュレート」されます。追加のプラットフォーム設定なしで最大のハードウェア互換性を提供します。トレードオフは、キーボードが忙しい時にバックライトが揺れる可能性があることです。有効にするには、`rules.mk` に以下を追加します:

View File

@ -1,18 +1,18 @@
# Bluetooth
<!---
original document: 0.9.0:docs/feature_bluetooth.md
git diff 0.9.0 HEAD -- docs/feature_bluetooth.md | cat
original document: 0.10.33:docs/feature_bluetooth.md
git diff 0.10.33 HEAD -- docs/feature_bluetooth.md | cat
-->
## Bluetooth の既知のサポートハードウェア
現在のところ Bluetooth のサポートは AVR ベースのチップに限られます。Bluetooth 2.1 については、QMK は RN-42 モジュールをサポートします。より最近の BLE プロトコルについては、現在のところ Adafruit Bluefruit SPI Friend のみが直接サポートされています。iOS デバイスに接続するには、BLE が必要です。iOS はマウス入力をサポートしないことに注意してください。
| ボード | Bluetooth プロトコル | 接続タイプ | rules.mk | Bluetooth チップ |
|----------------------------------------------------------------|----------------------------|----------------|---------------------------|--------------|
| Roving Networks RN-42 (Sparkfun Bluesmirf) | Bluetooth Classic | UART | `BLUETOOTH = RN42` | RN-42 |
| [Bluefruit LE SPI Friend](https://www.adafruit.com/product/2633) | Bluetooth Low Energy | SPI | `BLUETOOTH = AdafruitBLE` | nRF51822 |
| ボード | Bluetooth プロトコル | 接続タイプ | rules.mk | Bluetooth チップ |
| ---------------------------------------------------------------- | -------------------- | ---------- | ------------------------- | ---------------- |
| Roving Networks RN-42 (Sparkfun Bluesmirf) | Bluetooth Classic | UART | `BLUETOOTH = RN42` | RN-42 |
| [Bluefruit LE SPI Friend](https://www.adafruit.com/product/2633) | Bluetooth Low Energy | SPI | `BLUETOOTH = AdafruitBLE` | nRF51822 |
まだサポートされていませんが、可能性のあるもの:
* [Bluefruit LE UART Friend](https://www.adafruit.com/product/2479)。[tmk 実装がおそらく見つかります](https://github.com/tmk/tmk_keyboard/issues/514)
@ -30,7 +30,10 @@ Bluefruit UART friend は SPI friend に変換することができますが、
<!-- FIXME: Document bluetooth support more completely. -->
## Bluetooth の Rules.mk オプション
これらのうちの1つだけを使ってください
現在サポートされている Bluetooth チップセットは [N-キーロールオーバー (NKRO)](ja/reference_glossary.md#n-key-rollover-nkro) をサポートしていません。そのため、`rules.mk` に `NKRO_ENABLE = no` を含めなければなりません。
Bluetooth を有効にするには、以下のうちの1つだけを使ってください:
* BLUETOOTH_ENABLE = yes (レガシーオプション)
* BLUETOOTH = RN42
* BLUETOOTH = AdafruitBLE
@ -39,8 +42,8 @@ Bluefruit UART friend は SPI friend に変換することができますが、
これは複数のキーボードの出力が選択できる場合に使われます。現在のところ、これは USB と Bluetooth の両方をサポートするキーボードで、それらの間の切り替えのみが可能です。
| 名前 | 説明 |
|----------|----------------------------------------------|
| 名前 | 説明 |
| ---------- | ------------------------------------- |
| `OUT_AUTO` | USB と Bluetooth を自動的に切り替える |
| `OUT_USB` | USB のみ |
| `OUT_BT` | Bluetooth のみ |
| `OUT_USB` | USB のみ |
| `OUT_BT` | Bluetooth のみ |

View File

@ -1,8 +1,8 @@
# コンボ
<!---
original document: 0.8.94:docs/feature_combo.md
git diff 0.8.94 HEAD -- docs/feature_combo.md | cat
original document: 0.10.36:docs/feature_combo.md
git diff 0.10.36 HEAD -- docs/feature_combo.md | cat
-->
コンボ機能は、同時押し方式でのカスタムアクション追加機能です。同時に複数のキーを押して、異なる効果を生み出すことができます。例えば、タッピング時間内で `A``S` を押すと、代わりに `ESC` が押されます。もっと複雑なタスクを実行させることもできます。
@ -60,7 +60,7 @@ combo_t key_combos[COMBO_COUNT] = {
[XV_PASTE] = COMBO_ACTION(paste_combo),
};
void process_combo_event(uint8_t combo_index, bool pressed) {
void process_combo_event(uint16_t combo_index, bool pressed) {
switch(combo_index) {
case ZC_COPY:
if (pressed) {

View File

@ -1,8 +1,8 @@
# 動的マクロ: ランタイムでのマクロの記録および再生
<!---
original document: 0.9.43:docs/feature_dynamic_macros.md
git diff 0.9.43 HEAD -- docs/feature_dynamic_macros.md | cat
original document: 0.10.33:docs/feature_dynamic_macros.md
git diff 0.10.33 HEAD -- docs/feature_dynamic_macros.md | cat
-->
QMK はその場で作られた一時的なマクロをサポートします。これらを動的マクロと呼びます。それらはユーザがキーボードから定義し、キーボードのプラグを抜くか再起動すると失われます。

View File

@ -1,8 +1,8 @@
# リーダーキー: 新しい種類のモディファイア
<!---
original document: 0.8.134:docs/feature_leader_key.md
git diff 0.8.134 HEAD -- docs/feature_leader_key.md | cat
original document: 0.10.33:docs/feature_leader_key.md
git diff 0.10.33 HEAD -- docs/feature_leader_key.md | cat
-->
もしあなたが Vim を使ったことがある場合、リーダーキーは何であるかを知っています。そうでなければ、素晴らしい概念を発見しようとしています。:) 例えば、Alt+Shift+W を押す(3つのキーを同時に押す)代わりに、キーの_シーケンス_を押すことができたらどうでしょうつまり、特別なモディファイア (リーダーキー)を押して、続けて W と C を押すと (単純にキーを高速に繋げます)、何かが起こります。

View File

@ -1,8 +1,8 @@
# QMK での速記 :id=stenography-in-qmk
<!---
original document: 0.9.19:docs/feature_stenography.md
git diff 0.9.19 HEAD -- docs/feature_stenography.md | cat
original document: 0.10.33:docs/feature_stenography.md
git diff 0.10.33 HEAD -- docs/feature_stenography.md | cat
-->
[速記](https://en.wikipedia.org/wiki/Stenotype)は裁判所のレポート、字幕および耳が不自由な人のためのリアルタイムの文字起こしで最もよく使われる記述方法です。速記では単語はスペル、音声およびショートカット(短い)ストロークが混在する音節ごとに音節化されます。プロの速記者は、標準的なタイピングで通常見られる負担を掛けずに、はるかに少ないエラー(99.9%より高い精度)で、200-300 WPM に到達できます。

View File

@ -1,9 +1,9 @@
# タップダンス: 1つのキーが3つ、5つまたは100の異なる動作をします
<!---
original document: 0.9.44:docs/feature_tap_dance.md
git diff 0.9.44 HEAD -- docs/feature_tap_dance.md | cat
-->
original document: 0.10.33:docs/feature_tap_dance.md
git diff 0.10.33 HEAD -- docs/feature_tap_dance.md | cat
-->
## イントロダクション :id=introduction
@ -32,7 +32,9 @@
* `ACTION_TAP_DANCE_LAYER_TOGGLE(kc, layer)`: 1回タップすると `kc` キーコードが送信され、2回タップすると `layer` の状態をトグルします(これは `TG` レイヤーキーコードのように機能します)。
* `ACTION_TAP_DANCE_FN(fn)`: ユーザーキーマップに定義した指定の関数が呼び出されます。タップダンス実行の回数分タップすると、最後の時点で呼び出されます。
* `ACTION_TAP_DANCE_FN_ADVANCED(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn)`: タップする度にユーザーキーマップに定義した最初の関数が呼び出されます。タップダンスの実行が終わった時点で2番目の関数が呼び出され、タップダンスの実行をリセットするときに最後の関数が呼び出されます。
* `ACTION_TAP_DANCE_FN_ADVANCED_TIME(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn, tap_specific_tapping_term)`: これは `ACTION_TAP_DANCE_FN_ADVANCED` と同じように機能します。しかし、`TAPPING_TERM` で事前に定義した時間に代えて、カスタマイズしたタップ時間を使えます。
* ~~`ACTION_TAP_DANCE_FN_ADVANCED_TIME(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn, tap_specific_tapping_term)`~~: これは `ACTION_TAP_DANCE_FN_ADVANCED` 関数と同じように機能します。しかし、`TAPPING_TERM` で事前に定義した時間の代わりに、カスタマイズしたタップ時間を使います。
* [ここ](ja/custom_quantum_functions.md#Custom_Tapping_Term)で概説するように、これはキーごとのタッピング時間機能を優先して非推奨になりました。この特定のタップダンス機能を使う代わりに、使いたい特定の `TD()` マクロ(`TD(TD_ESC_CAPS)` のような)を確認する必要があります。
最初のオプションで、1つのキーに2つの役割を持たせる大抵のケースには十分です。例えば、`ACTION_TAP_DANCE_DOUBLE(KC_SPC, KC_ENT)` は、1回タップすると `Space` を送信し、2回タップすると `Enter` を送信します。
@ -55,7 +57,7 @@
異なる場合、まず、古いタップダンスを処理し、続いて新しいタップダンスを登録します。
同じ場合、カウンタの値を増やし、タイマーをリセットします。
このことは、あなたは再びキーをタップするまでの時間として `TAPPING_TERM` の時間を持っていることを意味します。そのため、あなたは1つの `TAPPING_TERM` の時間内に全てのタップを行う必要はありません。これにより、キーの反応への影響を最小限に抑えながら、より長いタップ回数を可能にします。
このことは、あなたは再びキーをタップするまでの時間として `TAPPING_TERM` の時間を持っていることを意味します。そのため、あなたは1つの `TAPPING_TERM` の時間内に全てのタップを行う必要はありません。これにより、キーの反応への影響を最小限に抑えながら、より長いタップ回数を可能にします。
次は `matrix_scan_tap_dance()` です。この関数はタップダンスキーのタイムアウトを制御します。

View File

@ -1,8 +1,8 @@
# 書き込みの手順とブートローダ情報
<!---
original document: 0.9.10:docs/flashing.md
git diff 0.9.10 HEAD -- docs/flashing.md | cat
original document: 0.10.33:docs/flashing.md
git diff 0.10.33 HEAD -- docs/flashing.md | cat
-->
キーボードが使用するブートローダにはかなり多くの種類があり、ほぼ全てが異なる書き込みの方法を使います。幸いなことに、[QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) のようなプロジェクトは、あまり深く考える必要無しに様々なタイプと互換性を持つことを目指していますが、この文章では様々なタイプのブートローダとそれらを書き込むために利用可能な方法について説明します。
@ -244,3 +244,4 @@ BOOTLOADER = bootloadHID
* `:dfu-util-split-left` - デフォルトのオプション (`:dfu-util`) と同様に、通常のファームウェアが書き込まれます。ただし、分割キーボードの「左側の」 EEPROM の設定も行われます。
* `:dfu-util-split-right` - デフォルトのオプション (`:dfu-util`) と同様に、通常のファームウェアが書き込まれます。ただし、分割キーボードの「右側の」 EEPROM の設定も行われます。
* `:st-link-cli` - dfu-util ではなく、ST-LINK の CLI ユーティリティを介してファームウェアを書き込めます。
* `:st-flash` - dfu-util ではなく、[STLink Tools](https://github.com/stlink-org/stlink) の `st-flash` ユーティリティを介してファームウェアを書き込めます。

View File

@ -1,8 +1,8 @@
# より詳細な `make` 手順
<!---
original document: 0.9.0:docs/getting_started_make_guide.md
git diff 0.9.0 HEAD -- docs/getting_started_make_guide.md | cat
original document: 0.10.33:docs/getting_started_make_guide.md
git diff 0.10.33 HEAD -- docs/getting_started_make_guide.md | cat
-->
`make` コマンドの完全な構文は `<keyboard_folder>:<keymap>:<target>` です:

View File

@ -2,8 +2,8 @@
<!---
grep --no-filename "^[ ]*git diff" docs/ja/*.md | sh
original document: 0.9.0:docs/hardware_avr.md
git diff 0.9.0 HEAD -- docs/hardware_avr.md | cat
original document: 0.10.33:docs/hardware_avr.md
git diff 0.10.33 HEAD -- docs/hardware_avr.md | cat
-->
このページでは QMK における AVR マイコンのサポートについて説明します。AVR マイコンには、Atmel 社製の atmega32u4、atmega32u2、at90usb1286 やその他のマイコンを含みます。AVR マイコンは、簡単に動かせるよう設計された8ビットの MCU です。キーボードでよく使用される AVR マイコンには USB 機能や大きなキーボードマトリックスのためのたくさんの GPIO を搭載しています。これらは、現在、キーボードで使われる最も一般的な MCU です。

View File

@ -2,8 +2,8 @@
<!---
grep --no-filename "^[ ]*git diff" docs/ja/*.md | sh
original document: 0.9.0:docs/hardware_keyboard_guidelines.md
git diff 0.9.0 HEAD -- docs/hardware_keyboard_guidelines.md | cat
original document: 0.10.33:docs/hardware_keyboard_guidelines.md
git diff 0.10.33 HEAD -- docs/hardware_keyboard_guidelines.md | cat
-->
QMK は開始以来、コミュニティにおけるキーボードの作成や保守に貢献しているあなたのような人たちのおかげで飛躍的に成長しました。私たちが成長するにつれて、うまくやるためのいくつかのパターンを発見しました。他の人たちがあなたの苦労の恩恵を受けやすくするため、それにあわせてもらえるようお願いします。

View File

@ -2,8 +2,8 @@
<!---
grep --no-filename "^[ ]*git diff" docs/ja/*.md | sh
original document: 0.8.62:docs/i2c_driver.md
git diff 0.8.62 HEAD -- docs/i2c_driver.md | cat
original document: 0.10.33:docs/i2c_driver.md
git diff 0.10.33 HEAD -- docs/i2c_driver.md | cat
-->
QMK で使われる I2C マスタドライバには、MCU 間のポータビリティを提供するための一連の関数が用意されています。
@ -83,8 +83,8 @@ STM32 MCU では、使用するハードウェアドライバにより、さま
|-----------------------|--------------------------------------------------------------------------------------------------|---------|
| `I2C1_SCL_BANK` | SCL に使うピンのバンク (`GPIOA`, `GPIOB`, `GPIOC`) | `GPIOB` |
| `I2C1_SDA_BANK` | SDA に使うピンのバンク (`GPIOA`, `GPIOB`, `GPIOC`) | `GPIOB` |
| `I2C1_SCL` | SCL のピン番号 (0-9) | `6` |
| `I2C1_SDA` | SDA のピン番号 (0-9) | `7` |
| `I2C1_SCL` | SCL のピン番号 (0-15) | `6` |
| `I2C1_SDA` | SDA のピン番号 (0-15) | `7` |
| `I2C1_BANK`(非推奨) | 使用するピンのバンク (`GPIOA`, `GPIOB`, `GPIOC`)。後継は `I2C1_SCL_BANK`, `I2C1_SDA_BANK` です。 | `GPIOB` |
ChibiOS I2C ドライバの設定項目は STM32 MCU の種類に依存します。

View File

@ -0,0 +1,284 @@
# ISP 書き込みガイド
<!---
grep --no-filename "^[ ]*git diff" docs/ja/*.md | sh
original document: 0.9.46:docs/isp_flashing_guide.md
git diff 0.9.46 HEAD -- docs/isp_flashing_guide.md | cat
-->
ISP 書き込み(ICSP 書き込みと呼ぶ場合もあります)とは、マイクロコントローラーを直接プログラミングするプロセスです。
これにより、ブートローダを交換したり、コントローラの「ヒューズ」を変更することができ、コントローラの速度や起動方法、その他のオプションなど、多くのハードウェアおよびソフトウェア関連の機能を制御します。
QMK の ISP 書き込みの主な用途は、AVRベースのコントローラPro Micro、または V-USB チップ)のブートローダの書き込みまたは交換です。
?> これは Pro Micro や他の ATmega コントローラなどの AVR ベースのボードをプログラミングするためだけのものです。 Proton C などの Arm コントローラには使用できません。
## 破損したブートローダーの取り扱い
ボードの書き込み/消去で問題が発生し、DFU ベースのコントローラで次のような不可解なエラーメッセージが表示される場合:
libusb: warning [darwin_transfer_status] transfer error: timed out
dfu.c:844: -ETIMEDOUT: Transfer timed out, NAK 0xffffffc4 (-60)
atmel.c:1627: atmel_flash: flash data dfu_download failed.
atmel.c:1629: Expected message length of 1072, got -60.
atmel.c:1434: Error flashing the block: err -2.
ERROR
Memory write error, use debug for more info.
commands.c:360: Error writing memory data. (err -4)
dfu.c:844: -EPIPE: a) Babble detect or b) Endpoint stalled 0xffffffe0 (-32)
Device is write protected.
dfu.c:252: dfu_clear_status( 0x7fff4fc2ea80 )
atmel.c:1434: Error flashing the block: err -2.
ERROR
Memory write error, use debug for more info.
commands.c:360: Error writing memory data. (err -4)
または、Pro Micro ベースのコントローラに対して次のようなメッセージが表示された場合:
avrdude: butterfly_recv(): programmer is not responding
avrdude: butterfly_recv(): programmer is not responding
avrdude: verification error, first mismatch at byte 0x002a
0x2b != 0x75
avrdude: verification error; content mismatch
avrdude: verification error; content mismatch
あなたのボード/デバイスを再び動作させるには、ISP 書き込みが必要になるかもしれません。
## 必要なハードウェア
実際に ISP の書き込みを行うには、以下のいずれか(その後に使用するプロトコルが続きます)が必要になります。
* [SparkFun PocketAVR](https://www.sparkfun.com/products/9825) - (USB Tiny)
* [USBtinyISP AVR Programmer Kit](https://www.adafruit.com/product/46) - (USB Tiny)
* [Teensy 2.0](https://www.pjrc.com/store/teensy.html) - (avrisp)
* [Pro Micro](https://www.sparkfun.com/products/12640) - (avrisp)
* [Bus Pirate](https://www.adafruit.com/product/237) - (buspirate)
ISP 書き込みに使用できるデバイスは他にもありますが、これらが主なものです。
また、すべての製品リンクは公式バージョンへのものです。他の場所で入手することもできます。
また、「ISP プログラマ」をプログラミングするデバイスに配線するためのものも必要になります。
PCB の中には直接使用できる ISP ヘッダがあるものもありますが、そうではない場合が多いので、コントローラ自体にハンダ付けするか、別のスイッチや他のコンポーネントにハンダ付けする必要があるでしょう。
### ISP ファームウェア
Teensy と Pro Micro のコントローラを ISP プログラマとして使用するには、コントローラに ISP ファームウェアを書き込む必要があります。
それ以外のハードウェアは、あらかじめプログラムされているはずです。
そのため、これらのコントローラの場合は、正しい hex ファイルをダウンロードしてから書き込んでください。
* 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_micro_ISP_B6_10.hex) (`10/B6`)
コントローラに書き込んだら、この hex ファイルはもう必要ありません。
## 必要なソフトウェア
QMK ツールボックスは、このほとんど(すべて)に使用することができます。
ただし、Teensy 2.0 ボードを使っている場合は、[Teensy Loader](https:/www.pjrc.comteensyloader.html) を使えば、Teensy 2.0 ボードに書き込むことができます。
あるいは、`avrdude` (`qmk_install.sh` の一部としてインストールされています) や、[AVRDUDESS](https:/blog.zakkemble.netavrdudess-a-gui-for-avrdude)(Windows 用) を使って、Pro Micro に書き込んだり、ISP を書き込んだりすることができます。
## 配線
これは非常に簡単です。次のようにして、相互に対応するものを接続します。
### SparkFun Pocket AVR
PocketAVR RST <-> Keyboard RESET
PocketAVR SCLK <-> Keyboard B1 (SCLK)
PocketAVR MOSI <-> Keyboard B2 (MOSI)
PocketAVR MISO <-> Keyboard B3 (MISO)
PocketAVR VCC <-> Keyboard VCC
PocketAVR GND <-> Keyboard GND
### Teensy 2.0
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
!> Teensy の B0 ピンはキーボードのコントローラの RESET/RST ピンと配線されています。 Teensy の RESET ピンをキーボードの RESET に配線しないでください。
### 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
!> Pro Micro の 10/B6 ピンはキーボードのコントローラの RESET/RST ピンに配線されています。 Pro Micro の RESET ピンをキーボードの RESET に配線 ***しないでください***。
## キーボードへの書き込み
ISP プログラマをセットアップして、キーボードに接続したら、キーボードに書き込みをします。
### ブートローダファイル
普通の状態に戻す一番簡単で手っ取り早い方法は、キーボードにブートローダだけ書き込むことです。
これが終れば、普通にキーボードを接続して、普通にキーボードに書き込みできるようになります。
標準のブートローダは[`util/` フォルダー](https://github.com/qmk/qmk_firmware/tree/master/util) にあります。
チップの正しいブートローダを書き込んでください:
* **Atmel DFU**
* [ATmega16U4](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega16u4_1.0.1.hex)
* [ATmega32U4](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32u4_1.0.0.hex)
* [AT90USB64](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_at90usb64_1.0.0.hex)
* [AT90USB128](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_at90usb128_1.0.1.hex)
* **Caterina**
* [Pro Micro (5V/16MHz)](https://github.com/sparkfun/Arduino_Boards/blob/master/sparkfun/avr/bootloaders/caterina/Caterina-promicro16.hex)
* [Pro Micro (3.3V/8MHz)](https://github.com/sparkfun/Arduino_Boards/blob/master/sparkfun/avr/bootloaders/caterina/Caterina-promicro8.hex)
* **BootloadHID (PS2AVRGB)**
* [ATmega32A](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_ps2avrgb_bootloadhid_1.0.1.hex)
お使いのボードが何を使っているかわからない場合は、QMK のキーボード用の `rules.mk` ファイルを見てください。
`MCU``BOOTLOADER` の行には必要な値が書かれています。これはボードのバージョンによって異なるかもしれません。
### 製造手法
ブートローダと通常のファームウェアを同時に書き込みたい場合、2つの方法があります。
手動で行うか、コンパイル時に `:production` ターゲットを使って行うかです。
手動で行うには:
1. オリジナルのファームウェアの .hex ファイルをテキストエディタで開きます
2. 最後の行を削除してください。(`:00000001FF`になっているはずです - これは EOF メッセージです)
3. ブートローダの内容全体を新しい行にコピーして(行間に空行を入れないように)、元のファイルの最後に貼り付けてください。
4. これを新しいファイルとして `<keyboard>_<keymap>_production.hex` という名前で保存します。
?> ここでは他のブートローダも同じように使うことができますが、__ブートローダが必要で__、そうしないとまた ISP を使ってキーボードに新しいファームウェアを書き込まなければならなくなります。
#### QMK DFU ブートローダとプロダクションイメージの作成
コンパイル時に `:production` ターゲットを使用して、ボード用のファームウェア、QMK DFU ブートローダ、プロダクションファームウェアイメージを作成することができます。
これが完了すると、3つのファイルが表示されます:
* `<keyboard>_<keymap>.hex`
* `<keyboard>_<keymap>_bootloader.hex`
* `<keyboard>_<keymap>_production.hex`
QMK DFU ブートローダは `atmega32u4` コントローラ (AVR ベースの Planck ボードや Pro Micro など) でしかテストされておらず、他のコントローラではテストされていません。
しかし、`atmega32a` や `atmega328p` のような V-USB コントローラでは間違いなく動作しません。
ブートローダかプロダクションファームウェアファイルのどちらかを書き込むことができます。
プロダクションファームウェアファイルの方が、より多くのデータを書き込むので、書き込みに時間がかかります。
?> 注意:同じブートローダを使用しつづけるべきです。すでに DFU を使用している場合は、QMK DFU に切り替えても問題ありません。しかし、例えば Pro Micro に QMK DFU を書き込むには、追加の手順が必要になります。
## ブートローダ/プロダクションファイルの書き込み
キーボードがどのデバイスにも接続されていないことを確認し、ISP プログラマを接続してください。
ブートローダの種類を変更したい場合は、コマンドラインを使用する必要があります。
### QMK Toolbox
1. 'AVRISP device connected' または `USB Tiny device connected` が黄色で表示されます。
2. `Open` ダイアログで正しいブートローダー/プロダクションの .hex ファイルを選択します(パスにスペースを含めることはできません)
3. 書きこもうとしているキーボードISP プログラマではなく)のための正しい `Microcontroller` オプションが選択されていることを確認してください。
4. `Flash` を押します
5. 特にプロダクションファイルの場合、しばらくは何も出力されませんが、待ちましょう。
検証とヒューズのチェックに問題がなければ、完了です。
ボードが自動的に再起動する場合があります。
それ以外の場合は、Teensy のプラグを抜いて、キーボードを接続します。
テスト中は、Teensy をキーボードに接続したままにすることができますが、すべてが正常に機能することを確認したら、はんだを外すか、配線を外すことをお勧めします。
### コマンドライン
ターミナルWindows の場合は `cmd`)を開いて、修正した .hex ファイルがある場所に移動します。
ここでは、このファイルを `main.hex` と呼び、Teensy 2.0 が `COM3` ポートに接続されていると仮定します。
よくわからない場合は、デバイスマネージャを開いて、`Ports > USB Serial Device` を探してください。ここにある COM ポートを使ってください。
あなたはそれが正しいポートであることを確認することができます:
avrdude -c avrisp -P COM3 -p atmega32u4
次のような出力が得られるはずです:
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.02s
avrdude: Device signature = 0x1e9587
avrdude: safemode: Fuses OK
avrdude done. Thank you.
私たちのキーボードは `atmega32u4`(共通)を使用しているので、これが指定するチップです。
以下が完全なコマンドです:
avrdude -c avrisp -P COM3 -p atmega32u4 -U flash:w:main.hex:i
ボードが `atmega32a`jj40 など)を使用している場合、コマンドは次のとおりです(最後の追加コードによりヒューズが正しく設定されます)。
avrdude -c avrisp -P COM3 -p atmega32 -U flash:w:main.hex:i -U hfuse:w:0xD0:m -U lfuse:w:0x0F:m
プログレスバーが表示されてから、以下が表示されるはずです。
avrdude: verifying ...
avrdude: 32768 bytes of flash verified
avrdude: safemode: Fuses OK
avrdude done. Thank you.
これは全てうまく動作したことを示しています。
ボードが自動的に再起動する場合もありますが、そうでない場合は、Teensy のプラグを抜いてキーボードを接続してください。
テスト中は、Teensy をキーボードに接続したままにすることができますが、すべてが正常に機能することを確認したら、はんだを外すか、配線を外すことをお勧めします。
SparkFun PocketAVR Programmer や、他の USB Tiny ベースの ISP プログラマを使用している場合は、次のようなものを使用すると良いでしょう。
avrdude -c usbtiny -P usb -p atmega32u4
#### 上級者向け: ヒューズの変更
Pro Micro に QMK DFU を書き込むなど、ブートローダを切り替える場合は、ブートローダの hex ファイルの書き込みに加えて、ヒューズを変更する必要があります。
これは、`caterina` (Pro Micro ブートローダ) と `dfu` では起動ルーチンの扱いが異なり、その動作はヒューズによって制御されるからです。
!> これは、ヒューズを変更することは、永久にあなたのコントローラをレンガ化(訳注:日本では文鎮化と呼ぶことが多い、コントローラがまったく無反応になる状態)することができる方法の1つであるため、それは非常に注意が必要な1つの領域です。
以下は、`atmega32u4`の 5V 16MHz 版5V Pro Micro など)を想定しています。
`atmega32u4`の DFU の場合、必要なヒューズ設定は次のとおりです:
| ヒューズ | 設定 |
|----------|------------------|
| Low | `0x5E` |
| High | `0xD9` or `0x99` |
| Extended | `0xC3` |
High ヒューズは 0xD9 か 0x99 のどちらかになります。
違いは、0xD9 は QMK Firmware がソフトウェアでも無効化している JTAG を無効化しているのに対し、0x99 は JTAG を無効化していないことです。
これを設定するには、`-U lfuse:w:0x5E:m -U hfuse:w:0xD9:m -U efuse:w:0xC3:m` をコマンドに追加します。
そうすると、最終的なコマンドは次のようになります。
avrdude -c avrisp -P COM3 -p atmega32u4 -U flash:w:main.hex:i -U lfuse:w:0x5E:m -U hfuse:w:0xD9:m -U efuse:w:0xC3:m
`atmega32u4`の Caterina では、以下があなたに必要なヒューズの設定です。
| ヒューズ | 設定 |
|----------|--------|
| Low | `0xFF` |
| High | `0xD8` |
| Extended | `0xCB` |
これを設定するには、コマンドに `-U lfuse:w:0xFF:m -U hfuse:w:0xD8:m -U efuse:w:0xCB:m` を追加します。
これで、最終的なコマンドは次のようになるはずです。
avrdude -c avrisp -P COM3 -p atmega32u4 -U flash:w:main.hex:i -U lfuse:w:0xFF:m -U hfuse:w:0xD8:m -U efuse:w:0xCB:m
別のコントローラーを使用している場合や、別の設定を希望する場合は、この[AVR ヒューズ計算機](http:/www.engbedded.comfusecalc)を使用して、より適切な値を見つけることができます。
## ヘルプ
ご質問・ご不明な点がありましたら、お気軽に[issue を開いてください](https://github.com/qmk/qmk_firmware/issues/new)

View File

@ -1,8 +1,8 @@
# QMK 開発用の Visual Studio Code のセットアップ
<!---
original document: 0.9.34:docs/other_vscode.md
git diff 0.9.34 HEAD -- docs/other_vscode.md | cat
original document: 0.10.33:docs/other_vscode.md
git diff 0.10.33 HEAD -- docs/other_vscode.md | cat
-->
[Visual Studio Code](https://code.visualstudio.com/) (VS Code) は多くの異なるプログラミング言語をサポートするオープンソースのコードエディタです。
@ -53,7 +53,7 @@ VS Code のようなフル機能のエディタの使用は、プレーンテキ
### VS Code の設定
最初に、IntelliSense をセットアップする必要があります。これは厳密には必要ではありませんが、あなたの人生をずっと楽にします。これを行うには、QMK ファームウェアフォルダに `.vscode/c_cpp_properies.json` ファイルを作成する必要があります。これは全て手動で行うことができますが、ほとんどの作業は既に完了しています。
最初に、IntelliSense をセットアップする必要があります。これは厳密には必要ではありませんが、あなたの人生をずっと楽にします。これを行うには、QMK ファームウェアフォルダに `.vscode/c_cpp_properties.json` ファイルを作成する必要があります。これは全て手動で行うことができますが、ほとんどの作業は既に完了しています。
[このファイル](https://gist.github.com/drashna/48e2c49ce877be592a1650f91f8473e8) を取得して保存します。MSYS2 をデフォルトの場所にインストールしなかった、または WSL か LxSS を使っている場合、このファイルを編集する必要があります。
@ -64,7 +64,7 @@ VS Code のようなフル機能のエディタの使用は、プレーンテキ
次に、VSCode に統合ターミナルとして表示されるように、MSYS2 ウィンドウを設定します。これには多くの利点があります。ほとんどの場合で、エラー上で Ctrl + クリックするとこれらのファイルにジャンプできます。これによりデバッグがはるかに簡単になります。また、他のウィンドウへジャンプする必要が無いという点でも優れています。
1. <kbd><kbd>File</kbd> > <kbd>Preferences ></kbd> > <kbd>Settings</kbd> </kbd> をクリックします。
1. <kbd><kbd>ファイル</kbd> > <kbd>ユーザー設定 ></kbd> > <kbd>設定</kbd> </kbd> をクリックします。
2. 右上の <kbd>{}</kbd> ボタンをクリックし、`settings.json` ファイルを開きます。
3. ファイルの内容を以下のように設定します:
@ -82,11 +82,11 @@ VS Code のようなフル機能のエディタの使用は、プレーンテキ
}
```
ここに既に設定がある場合は、最初と最後の波括弧の間に全てを追加します。
ここに既に設定がある場合は、最初と最後の波括弧の間に全てを追加し、既存の設定を新しく追加された設定とカンマで区切ります。
?> MSYS2 を別のフォルダにインストールした場合は、`terminal.integrated.shell.windows` のパスをシステムの正しいパスに変更する必要があります。
4. Ctrl-` (grave) を押して、ターミナルを起動します。
4. Ctrl-<code>&#96;</code> (Grave) を押して、ターミナルを起動するか、<kbd><kbd>表示</kbd> > <kbd>ターミナル</kbd></kbd> (コマンド `workbench.action.terminal.toggleTerminal`)に進みます。まだターミナルが開いていない場合は、新しいターミナルが開きます。
これにより、ワークスペースフォルダ(つまり `qmk_firmware` フォルダ)でターミナルが起動し、キーボードをコンパイルすることができます。
@ -115,8 +115,8 @@ VS Code のようなフル機能のエディタの使用は、プレーンテキ
いずれかの拡張機能をインストールしたら、再起動します。
# QMK 用の VS Code の設定
1. <kbd><kbd>File</kbd> > <kbd>Open Folder</kbd></kbd> をクリックします
1. <kbd><kbd>ファイル</kbd> > <kbd>フォルダーを開く</kbd></kbd> をクリックします
2. GitHub からクローンした QMK ファームウェアフォルダを開きます。
3. <kbd><kbd>File</kbd> > <kbd>Save Workspace As...</kbd></kbd> をクリックします
3. <kbd><kbd>ファイル</kbd> > <kbd>名前を付けてワークスペースを保存...</kbd></kbd> をクリックします
これで、VS Code で QMK ファームウェアをコーディングする準備ができました。

134
qmk/docs/ja/pr_checklist.md Normal file
View File

@ -0,0 +1,134 @@
# PR チェックリスト
<!---
original document: 0.10.7:docs/pr_checklist.md
git diff 0.10.7 HEAD -- docs/pr_checklist.md | cat
-->
これは、提出された PR を QMK の協力者がレビューする際に何をチェックするのかの非網羅的なチェックリストです。
これらの推奨事項に矛盾がある場合は、このドキュメントに対して [issue を開く](https://github.com/qmk/qmk_firmware/issues/new)か、[Discord](https://discord.gg/Uq7gcHh) の QMK コラボレータに連絡することをお勧めします。
## 一般的な PR
- PRは、ソースリポジトリ上の `master` ではないブランチを使って提出する必要があります
- これは、あなたの PR にとって別のブランチをターゲットにするという意味ではなく、むしろ自分の master ブランチで作業をしていないという意味です
- もし PR の提出者が自分の `master` ブランチを使っている場合は、マージ後に ["git の使い方"](https://docs.qmk.fm/#/ja/newbs_git_using_your_master_branch) ページへのリンクが表示されます - (このドキュメントの最後にはメッセージの内容が含まれます)
- 新しく追加されたディレクトリとファイル名は小文字でなければなりません
- 上流のソースが元々大文字を使っていた場合 (ChibiOS や他のリポジトリからインポートしたファイルなど)、このルールは緩和されるかもしれません
- 十分な正当性がある場合 (既存のコアファイルとの整合性など) は、このルールを緩和することができます。
- ボードデザイナーがキーボードの名前を大文字にした場合は、十分な正当性とはみとめられません
- すべての `*.c` および `*.h` ソースファイルの有効なライセンスヘッダ
- 一貫性のために GPL2/GPL3 が推奨されています
- 他のライセンスも許可されていますが、GPL と互換性があり、再配布が許可されていなければなりません。異なるライセンスを使うと、PR がマージされるのをほぼ確実に遅らせることになります
- QMK コードベースの「ベストプラクティス」に従う
- これは網羅的なリストではありませんし、時間が経つにつれて修正される可能性が高いです
- ヘッダファイルでは、`#ifndef` インクルードガードの代わりに `#pragma once` を使います
- 「旧式の」 GPIO/I2C/SPI 関数を使用しない - 正当な理由がない限り、QMK の抽象化を使用しなければなりません (怠惰は正当な理由にはなりません)
- タイミングの抽象化にも従う必要があります:
- `_delay_ms()` のかわりに `wait_ms()` を。(`#include <util/delay.h>` も消します)
- `timer_read()``timer_read32()` など。 -- タイミング API は [timer.h](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/timer.h) を参照してください
- 新しい抽象化が有用だと思う場合は、次のことをお勧めします:
- 機能が完成するまで自分のキーボードでプロトタイプを作成する
- Discord の QMK コラボレータと話し合う
- 個別のコア変更としてそれをリファクタリングする
- あなたのキーボードからそのコピーを削除する
- PR を開く前にリベースしてマージの競合をすべて修正します (ヘルプやアドバイスが必要な場合は、Discord で QMK コラボレータに連絡してください)。
## キーマップの PR
- 特定のボードファイルをインクルードするよりも `#include QMK_KEYBOARD_H` を推奨します
- レイヤーは `#define` よりも `enum` が好まれます
- カスタムキーコードは `#define` ではなく `enum` が必要です。最初のエントリには `= SAFE_RANGE` が必要です
- LAYOUT マクロ呼び出しのパラメータの途中の改行ではバックスラッシュ(`\`)は不要です
- スペーシング(コンマまたはキーコードの最初の文字の配置など)に注意を払うと、見栄えの良いキーマップになります
## キーボードの PR
終了した PRインスピレーションを得るために、以前のレビューコメントセットは、自分のレビューのピンポンをなくすのに役立ちます:
https://github.com/qmk/qmk_firmware/pulls?q=is%3Apr+is%3Aclosed+label%3Akeyboard
- `info.json`
- 有効な URL
- 有効なメンテナ
- Configurator で正しく表示されることCtrl + Shift + I を押してローカルファイルをプレビューし、高速入力をオンにして順序を確認する)
- `readme.md`
- 標準テンプレートがあること
- 書き込みコマンドが `:flash` で終わっていること
- 有効なハードウェアの入手方法へのリンク (手配線の場合を除く) -- プライベートな共同購入は問題ありませんが、一回限りのプロトタイプは疑問視されます。オープンソースの場合は、ファイルへのリンクを提供してください
- ボードをブートローダーモードにリセットする方法を明確に説明してください
- キーボードの写真、できれば PCB の写真も添付してください
- `rules.mk`
- `MIDI_ENABLE`、`FAUXCLICKY_ENABLE`、`HD44780_ENABLE` は削除されました
- `# Enable Bluetooth with the Adafruit EZ-Key HID``# Enable Bluetooth` に変更されました
- 機能の有効化に関する `(-/+サイズ)` コメントはなくなりました
- ブートローダが指定されている場合は、代替ブートローダのリストを削除します
- [mcu_selection.mk](https://github.com/qmk/qmk_firmware/blob/master/quantum/mcu_selection.mk)の同等の MCU と比較した場合、同じ値の場合、デフォルトの MCU パラメータの再定義がないこと
- キーボードの `config.h`
- `PRODUCT` 値に `MANUFACTURER` を繰り返さないでください
- `#define DESCRIPTION` は要りません
- マジックキーオプション、 MIDI オプション、HD44780 コンフィギュレーションは要りません
- ユーザー設定の設定可能な `define` はキーマップ `config.h` に移動する必要があります
- "`DEBOUNCING_DELAY`" の代りに "`DEBOUNCE`" を使います
- キーボードが QMK で起動するために最低限必要なコードが存在する必要があります
- マトリックスと重要なデバイスの初期化コード
- (カスタムキーコードや特別なアニメーションなど)商用キーボードの既存の機能をミラーリングする場合は、`default` ではないキーマップを使って処理する必要があります
- `keyboard.c`
- 空の `xxxx_xxxx_kb()` または他の weak-define のデフォルト実装関数が削除されていること
- コメントアウトされた関数も削除されていること
- `matrix_init_board()` などが `keyboard_pre_init_kb()` に移行されました。[keyboard_pre_init*](https://docs.qmk.fm/#/ja/custom_quantum_functions?id=keyboard_pre_init_-function-documentation) を参照してください
- カスタムマトリックスを使用する場合は、`CUSTOM_MATRIX = lite` を選択し、標準のデバウンスを許可します。[マトリックスコードの部分置き換え](https://docs.qmk.fm/#/ja/custom_matrix?id=lite) を参照してください
- `keyboard.h`
- 先頭に `#include "quantum.h"` を置きます
- `LAYOUT` マクロは、該当する場合は標準の定義を使用してください
- 該当する場合はコミュニティレイアウトマクロ名を使用します (`LAYOUT`/`LAYOUT_all`よりも優先されます)
- キーマップの `config.h`
- キーボードから `rules.mk``config.h` が重複していないこと
- `keymaps/default/keymap.c`
- `QMKBEST`/`QMKURL` が削除されていること
- `MO(_LOWER)`および `MO(_RAISE)`キーコードまたは同等のものを使用していて、キーマップに両方のキーを押したときに adjust レイヤーがある場合 - キーマップに直接 adjust レイヤーに入るキーコードがない場合(`MO(_ADJUST)`のように)次のように記述します...
```
layer_state_t layer_state_set_user(layer_state_t state) {
return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST);
}
```
...キーマップの `process_record_user()` 内で `layer_on()``update_tri_layer()` を手動で処理する代わりに。
- default (および via) のキーマップは「素朴」でなければなりません。
- 他のユーザーが独自のユーザー固有のキーマップを開発するための「クリーンな状態」として使用するための最低限のもの。
- これらのキーマップで推奨される標準レイアウト(可能な場合)
- PR の提出者は、同じ PR に機能を紹介する個人的な(または豪華な)キーマップを持たせることができますが、「デフォルト」のキーマップに埋め込むべきではありません
- PR の提出者はまた、既存の商用キーボードへ QMK を移植する場合、その商用製品の既存の機能を反映する「製造業者に一致する」キーマップを持つことができます
さらに、ChibiOS に固有で:
- 既存の ChibiOS ボード定義を使用することを**強く**推奨します。
- 多くの場合、同等の Nucleo ボードは、同じファミリの異なるフラッシュサイズまたはわずかに異なるモデルで使用できます。
- 例STM32L082KZ の場合、STM32L073RZ に類似しているため、rules.mkで `BOARD = ST_NUCLEO64_L073RZ` を使用できます。
- QMK は ChibiOS のアップグレード時のメンテナンス負担が継続的に発生するため、可能な限りカスタムボード定義を持たないように移行しています。
- ボードの定義が避けられない場合、`board.c` には標準の `__early_init()` (通常の ChibiOS ボードの定義と同じ) と空の `boardInit()` を実装しなければなりません。
- Arm/ChibiOS [早期初期化](https:/docs.qmk.fm/#/ja/platformdev_chibios_earlyinit?id=board-init)を参照してください
- `__early_init()`は、`early_hardware_init_pre()` または `early_hardware_init_post()` で適切に置き換える必要があります
- `boardInit()``board_init()` に移行する必要があります
## コアの PR
- `develop` ブランチをターゲットにする必要があります。これは、その後、breaking change のタイムラインで `master` にマージされます。
- その他の注意事項 TBD
- 投稿された変更の幅を考えると、コアはもっと主観的です
---
## 注意事項
人々が自分の `master` ブランチを使用する場合、マージ後に以下を投稿します:
```
For future reference, we recommend against committing to your `master` branch as you've done here, because pull requests from modified `master` branches can make it more difficult to keep your QMK fork updated. It is highly recommended for QMK development regardless of what is being done or where to keep your master updated, but **NEVER** commit to it. Instead, do all your changes in a branch (branches are basically free in Git) and issue PRs from your branches when you're developing.
There are instructions on how to keep your fork updated here:
[**Best Practices: Your Fork's Master: Update Often, Commit Never**](https://docs.qmk.fm/#/newbs_git_using_your_master_branch)
[Fixing Your Branch](https://docs.qmk.fm/#/newbs_git_resynchronize_a_branch) will walk you through fixing up your `master` branch moving forward. If you need any help with this just ask.
Thanks for contributing!
```

View File

@ -1,8 +1,8 @@
# キーボードをより良くするための便利なコア関数のリスト
<!---
original document: 0.9.47:docs/ref_functions.md
git diff 0.9.47 HEAD -- docs/ref_functions.md | cat
original document: 0.10.33:docs/ref_functions.md
git diff 0.10.33 HEAD -- docs/ref_functions.md | cat
-->
QMK には、信じられないほど便利な、またはあなたが望んでいた機能を少し追加する、隠された関数がたくさんあります。特定の機能に固有の関数はそれぞれの機能のページにあるため、ここには含まれていません。
@ -48,7 +48,9 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
### `update_tri_layer_state(state, x, y, z)`
もう1つの関数は `update_tri_layer_state(state, x, y, z)` です。この関数は [`layer_state_set_*` 関数](ja/custom_quantum_functions.md#layer-change-code)から呼び出されることを意図しています。これは、キーコードを使ってレイヤーを変更するたびに、これがチェックされることを意味します。したがって、`LT(layer, kc)` を使ってレイヤーを変更すると、同じレイヤーチェックが引き起こされます。
このメソッドの注意点は、`x` および `y` レイヤーをオンにしないと、`z` レイヤーにアクセスできないことです。レイヤー `z` のみをアクティブにしようとすると、このコードが実行され、使用前にレイヤー `z` がオフになるからです。
このメソッドの注意点は2つあります:
1. `x` および `y` レイヤーをオンにしないと、`z` レイヤーにアクセスできません。これは、レイヤー `z` のみをアクティブにしようとすると、このコードが実行され、使用前にレイヤー `z` がオフになるからです。
2. レイヤーは最上位の番号から処理されるので、`z` は `x``y` よりも上位のレイヤーでなければなりません。そうでなければアクセスできない場合があります。
#### 例

View File

@ -1,8 +1,8 @@
# `info.json`
<!---
original document: 0.9.46:docs/reference_info_json.md
git diff 0.9.46 HEAD -- docs/reference_info_json.md | cat
original document: 0.10.33:docs/reference_info_json.md
git diff 0.10.33 HEAD -- docs/reference_info_json.md | cat
-->
このファイルは [QMK API](https://github.com/qmk/qmk_api) によって使われます。このファイルは [QMK Configurator](https://config.qmk.fm/) がキーボードの画像を表示するために必要な情報を含んでいます。ここにメタデータを設定することもできます。
@ -36,7 +36,7 @@
* `height`
* オプション: キー単位でのレイアウトの高さ
* `key_count`
* **必須**: このレイアウトのキーの数
* オプション: このレイアウトのキーの数
* `layout`
* 物理レイアウトを説明するキー辞書のリスト。詳細は次のセクションを見てください。

196
qmk/docs/ja/tap_hold.md Normal file
View File

@ -0,0 +1,196 @@
# タップホールド設定オプション
<!---
original document: 0.10.33:docs/tap_hold.md
git diff 0.10.33 HEAD -- docs/tap_hold.md | cat
-->
タップホールドオプションは素晴らしいものですが、問題が無いわけではありません。デフォルト設定を適切なものにしようとしましたが、一部の人にとってまだ問題を引き起こすかもしれません。
次のオプションによりタップホールドキーの挙動を変更することができます。
## タッピング時間
以下の機能の全ての核心は、タッピング時間の設定です。これにより、何をタップとし、何をホールドとするかが決まります。これが自然に感じられるぴったりのタイミングは、キーボードごと、スイッチごと、あるいはキーごとに異ることもありえます。
`config.h` に以下の設定を追加することで、この時間を全体的に設定することができます:
```c
#define TAPPING_TERM 200
```
この設定はミリ秒で定義され、デフォルトは 200ms です。これは大多数の人にとっての適切な平均値です。
この機能をより細かく制御するために、以下を `config.h` に追加することができます:
```c
#define TAPPING_TERM_PER_KEY
```
そして、以下の関数をキーマップに追加します:
```c
uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case SFT_T(KC_SPC):
return TAPPING_TERM + 1250;
case LT(1, KC_GRV):
return 130;
default:
return TAPPING_TERM;
}
}
```
## 許容ホールド
[PR#1359](https://github.com/qmk/qmk_firmware/pull/1359/) 以降、新しい `config.h` オプションがあります:
```c
#define PERMISSIVE_HOLD
```
これは高速なタイピストや高い `TAPPING_TERM` 設定に対して、タップとホールドキー(モッドタップのような)の動作を向上させます。
モッドタップキーを押し、他のキーをタップ(押して放す)して、モッドタップキーを放すという動作の全てをタッピング時間内に行うと、両方のキーのタッピング機能が出力されます。
例えば:
- `SFT_T(KC_A)` を押す
- `KC_X` を押す
- `KC_X` を放す
- `SFT_T(KC_A)` を放す
通常、これら全てを `TAPPING_TERM` (デフォルト: 200ms) 内で行うと、ファームウェアとホストシステムによって `ax` として登録されます。許容ホールドを有効にすると、別のキーがタップされた場合にモッドタップキーを修飾キーと見なすように処理を変更し、 `X` (`SHIFT`+`x`) と登録されます。
?> `モッドタップ割り込みの無視`を有効にしている場合、これにより両方の動きが変更されます。通常のキーには、最初のキーが最初に放された場合、あるいは両方のキーが `TAPPING_TERM` より長くホールドされた場合に、修飾キーが追加されます。
この機能をより細かく制御するために、以下を `config.h` に追加することができます:
```c
#define PERMISSIVE_HOLD_PER_KEY
```
そして、以下の関数をキーマップに追加します:
```c
bool get_permissive_hold(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case LT(1, KC_BSPC):
return true;
default:
return false;
}
}
```
## モッドタップ割り込みの無視
この設定を有効にするには、これを `config.h` に追加してください:
```c
#define IGNORE_MOD_TAP_INTERRUPT
```
許容ホールドと同様に、これは高速なタイピストのためのファームウェアの処理方法を変更します。モッドタップキーを押し、他のキーを押し、モッドタップキーを放し、通常のキーを放すと、通常は両方のキーのタッピング機能が出力されます。これはローリングコンボキーには望ましくないかもしれません。
`モッドタップ割り込みの無視`を設定するには、両方のキーを `TAPPING_TERM` の間ホールドすると、(その修飾キーの)ホールド機能を実行する必要があります。
例えば:
- `SFT_T(KC_A)` を押す
- `KC_X` を押す
- `SFT_T(KC_A)` を放す
- `KC_X` を放す
通常、これは `X` (`SHIFT`+`x`) を送信します。`モッドタップ割り込みの無視` を有効にすると、ホールドアクションを登録するには、両方のキーを `TAPPING_TERM` の間ホールドする必要があります。この場合、素早いタップは `ax` を送信しますが、両方をホールドすると、`X` (`SHIFT`+`x`) を出力します。
?> __注意__: これはモディファイアにのみ関係し、レイヤー切り替えキーには関係しません。
?> `許容ホールド`を有効にすると、これは両方がどのように動作するかを変更します。通常のキーには、最初のキーが最初に放された場合、あるいは両方のキーが `TAPPING_TERM` より長くホールドされた場合に、修飾キーが追加されます。
この機能をより細かく制御するために、以下を `config.h` に追加することができます:
```c
#define IGNORE_MOD_TAP_INTERRUPT_PER_KEY
```
そして、以下の関数をキーマップに追加します:
```c
bool get_ignore_mod_tap_interrupt(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case SFT_T(KC_SPC):
return true;
default:
return false;
}
}
```
## タッピング強制ホールド
`タッピング強制ホールド` を有効にするには、以下を `config.h` に追加します:
```c
#define TAPPING_FORCE_HOLD
```
タップの後でユーザがキーをホールドすると、ホールド機能がアクティブになるのではなく、デフォルトでタッピング機能が繰り返されます。これにより、デュアルロールキーのタッピング機能を自動繰り返しする機能を維持することができます。
`TAPPING_FORCE_HOLD` は、デュアルロールキーをタップした後ホールドした場合、ユーザがホールド機能をアクティブにする機能を削除します。
例:
- `SFT_T(KC_A)` を押す
- `SFT_T(KC_A)` を放す
- `SFT_T(KC_A)` を押す
- タッピング時間が終了するまで待ちます...
- `SFT_T(KC_A)` を放す
デフォルトの設定では、最初に放したときに `a` が送信され、2回目の押下で `a` が送信され、コンピュータに自動リピート機能を作動させることができます。
`TAPPING_FORCE_HOLD` を使うと、2回目の押下は Shift として解釈され、それをタップして使った後ですぐに修飾キーとして使うことができます。
!> `TAPPING_FORCE_HOLD` はタッピングトグル(`TT` レイヤーキーコード、ワンショットタップトグルなど)を使うものをすべて破壊します。
この機能をより細かく制御するために、以下を `config.h` に追加することができます:
```c
#define TAPPING_FORCE_HOLD_PER_KEY
```
そして、以下の関数をキーマップに追加します:
```c
bool get_tapping_force_hold(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case LT(1, KC_BSPC):
return true;
default:
return false;
}
}
```
## レトロタッピング
`レトロタッピング`を有効にするには、以下を `config.h` に追加してください:
```c
#define RETRO_TAPPING
```
他のキーを押さずにデュアルファンクションキーを押して放しても何も起こりません。レトロタッピングを有効にすると、他のキーを押さずにキーを放すと、元のキーコードがタッピング時間外であっても送信されます。
例えば、他のキーを押すことなく `LT(2, KC_SPACE)` を押したり放したりしても何も起こりません。これを有効にすると、代わりに `KC_SPACE` を送信します。
## キー別の関数にキーレコードを含めるのはなぜですか?
「キー別」の関数全てにキーレコードを含んでいることに気付いたかもしれません。そしてなぜそうしたのか不思議に思っているかもしれません。
まぁ、それは単純に本当にカスタマイズのためです。ただし、具体的には、それはキーボードの配線方法によって異なります。例えば、各行が実際にキーボードのマトリックスの1行を使っている場合、キーコード全体をチェックする代わりに、`if (record->event.row == 3)` を使うほうが簡単かもしれません。これは、ホームキー行でタップホールドタイプのキーを使っている人にとって特に便利です。そのため、通常のタイピングを妨げないように微調整することができるのではないでしょうか。
## `*_kb``*_user` 関数が無いのはなぜですか?
QMK にある他の多くの関数とは異なり、quantum あるいはキーボードレベルの関数を持つ必要はありません (または理由さえありません)。ここではユーザレベルの関数だけが有用なため、そのようにマークする必要はありません。

View File

@ -0,0 +1,195 @@
# QMK のコードの理解
<!---
original document: 0.9.55:docs/understanding_qmk.md
git diff 0.9.55 HEAD -- docs/understanding_qmk.md | cat
-->
このドキュメントでは、QMK ファームウェアがどのように機能するかを非常に高いレベルから説明しようとしています。基本的なプログラミングの概念を理解していることを前提としていますが、(実例を示す必要がある場合を除き) C に精通していることを前提にはしていません。以下のドキュメントの基本的な知識があることを前提としています。
* [入門](ja/getting_started_introduction.md)
* [キーボードがどのように動作するか](ja/how_keyboards_work.md)
* [FAQ](ja/faq.md)
## スタートアップ
QMK は他のコンピュータプログラムと何ら変わりないと考えることができます。開始され、タスクを実行し、そして終了します。プログラムのエントリーポイントは、他の C プログラムと同様に、`main()` 関数です。ただし、QMK を初めて触る人は、`main()` 関数が複数の場所に現れるため、混乱するかもしれません。また、どれを見ればよいか分かりにくいかもしれません。
複数ある理由は、QMK は様々なプラットフォームをサポートするからです。最も一般的なプラットフォームは `lufa` です。これは atmega32u4 のような AVR プロセッサ上で実行されます。また、`chibios` および `vusb` もサポートします。
ここでは AVR プロセッサに焦点を当てます。これは `lufa` プラットフォームを使います。`main()` 関数は [tmk_core/protocol/lufa/lufa.c](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/tmk_core/protocol/lufa/lufa.c#L1028) にあります。関数にざっと目を通すと、(ホストへの USB も含めて)設定された全てのハードウェアが初期化され、プログラムのコア部分が [`while(1)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/tmk_core/protocol/lufa/lufa.c#L1069) で開始されることが分かります。これが[メインループ](#the-main-loop)です。
## メインループ
コードのこの部分は、同じ命令セットを永久にループ処理するため、「メインループ」と呼ばれます。ここはキーボードに必要なことを実行させる関数を QMK が呼び出す場所です。一見、多くの機能を持つように見えるかもしれませんが、大抵の場合、コードは `#define` によって無効にされます。
```
keyboard_task();
```
ここで、全てのキーボードの固有の機能が実行されます。`keyboard_task()` のソースコードは [tmk_core/common/keyboard.c](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/tmk_core/common/keyboard.c#L216) にあり、マトリックスの変化を検知し、LED の状態をオンオフする責任があります。
`keyboard_task()` に以下を処理するコードがあります:
* [マトリックスのスキャン](#matrix-scanning)
* マウスの処理
* シリアルリンク
* ビジュアライザ
* キーボードの状態の LED (Caps Lock, Num Lock, Scroll Lock)
#### マトリックスのスキャン
マトリックスのスキャンはキーボードファームウェアのコアの機能です。これは今どのキーが押されているかを検知するプロセスであり、キーボードはこの機能を1秒間に何度も何度も実行します。ファームウェアの CPU 時間の 99% はマトリックスのスキャンに費やされていると言っても過言ではありません。
実際のマトリックスの検知には様々な方法がありますが、それはこのドキュメントの対象外です。マトリックスのスキャンをブラックボックスとして扱っても問題ありません。マトリックスの現在の状態を求めると、以下のようなデータ構造を取得します:
```
{
{0,0,0,0},
{0,0,0,0},
{0,0,0,0},
{0,0,0,0},
{0,0,0,0}
}
```
これは 4行x5列のテンキー(訳注: 5行x4列の間違いと思われます)のマトリックスを表す直接的な表現のデータ構造です。キーが押されると、マトリックス内のそのキーの位置が、 `0` ではなく `1` として返されます。
マトリックスのスキャンは1秒間に何度も実行されます。正確なレートは様々ですが、知覚できるような遅延を避けるために、秒間に少なくとも10回実行します。
##### マトリックスから物理的なレイアウトへのマップ
キーボード上の各スイッチの状態が分かると、それをキーコードへマップする必要があります。QMK ではキーコードへのマップは C マクロを使うことで行われ、C マクロにより物理的なレイアウトの定義はキーコードの定義から分離されています。(訳注:「キーコードの定義」は「キーコードのマトリクス配列による定義」と思われる)
キーボードレベルで、キーボードのマトリックスを物理キーにマップする C マクロ (一般的には、`LAYOUT()` という名前)を定義します。マトリックスにスイッチがない場所がある場合、このマクロを使って KC_NO を事前に埋め込むことができ、キーマップの定義を扱いやすくすることができます。以下は、テンキー用の `LAYOUT()` マクロです:
```c
#define LAYOUT( \
k00, k01, k02, k03, \
k10, k11, k12, k13, \
k20, k21, k22, \
k30, k31, k32, k33, \
k40, k42 \
) { \
{ k00, k01, k02, k03, }, \
{ k10, k11, k12, k13, }, \
{ k20, k21, k22, KC_NO, }, \
{ k30, k31, k32, k33, }, \
{ k40, KC_NO, k42, KC_NO } \
}
```
`LAYOUT()` マクロの2つ目のブロックが、上記のマトリックススキャン配列とどのように一致しているかに注目してください。このマクロはマトリックスのスキャン配列をキーコードにマップするものです。ただし、17キーのテンキーを見ると、マトリックスにはスイッチが置けるが、キーが大きいために実際にはスイッチが無い箇所が3つあることが分かります。これらのスペースに `KC_NO` を設定したので、キーマップ定義には必要ありません。
このマクロを使って、少し変わったマトリックスのレイアウト、例えば [Clueboard rev 2](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/keyboards/clueboard/66/rev2/rev2.h) を扱うこともできます。その説明はこのドキュメントの範囲外です。
##### キーコードの割り当て
キーマップレべルでは、上記の `LAYOUT()` マクロを使って、物理的な場所からマトリックスの場所にマッピングします。以下のようになります:
```
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT(
KC_NLCK, KC_PSLS, KC_PAST, KC_PMNS, \
KC_P7, KC_P8, KC_P9, KC_PPLS, \
KC_P4, KC_P5, KC_P6, \
KC_P1, KC_P2, KC_P3, KC_PENT, \
KC_P0, KC_PDOT)
}
```
これら全ての引数が、前のセクションの `LAYOUT()` マクロの前半とどのように一致しているかについて注目してください。このようにして、キーコードを取得して、それを前述のマトリックススキャンにマップします。
##### 状態変更の検知
上記のマトリックススキャンはある時点のマトリックスの状態を伝えますが、コンピュータは変更のみを知りたいだけで、現在の状態を気にしません。QMK は最後のマトリックススキャンの結果を格納し、このマトリックスから結果を比較して、いつキーが押されたか放されたかを決定します。
例を見てみましょう。キーボードスキャンループの途中に移動して、前のスキャンが以下のようになっていることがわかったとします:
```
{
{0,0,0,0},
{0,0,0,0},
{0,0,0,0},
{0,0,0,0},
{0,0,0,0}
}
```
現在のスキャンが完了すると、以下のように見えるとします:
```
{
{1,0,0,0},
{0,0,0,0},
{0,0,0,0},
{0,0,0,0},
{0,0,0,0}
}
```
キーマップと比較すると、押されたキーが KC_NLCK であることが分かります。ここから、`process_record` 関数群を呼び出します。
<!-- FIXME: Magic happens between here and process_record -->
##### Process Record
`process_record()` 関数自体は一見簡単に見えますが、その内部は QMK の様々なレベルで機能を上書きするためのゲートウェイが隠されています。キーボード/キーマップレベルの機能について調べる必要があるときは、以下に列挙した一連のイベントを手引帳として使います。`rules.mk` またはほかの場所で設定されたオプションに応じて、最終的なファームウェアに以下の関数のサブセットのみが含まれます。
* [`void process_record(keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/tmk_core/common/action.c#L172)
* [`bool process_record_quantum(keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/quantum.c#L206)
* [このレコードをキーコードにマップする](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/quantum.c#L226)
* [`void velocikey_accelerate(void)`](https://github.com/qmk/qmk_firmware/blob/c1c5922aae7b60b7c7d13d3769350eed9dda17ab/quantum/velocikey.c#L27)
* [`void preprocess_tap_dance(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_tap_dance.c#L119)
* [`bool process_key_lock(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_key_lock.c#L62)
* [`bool process_clicky(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_clicky.c#L79)
* [`bool process_haptic(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/2cee371bf125a6ec541dd7c5a809573facc7c456/drivers/haptic/haptic.c#L216)
* [`bool process_record_kb(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/keyboards/clueboard/card/card.c#L20)
* [`bool process_record_user(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/keyboards/clueboard/card/keymaps/default/keymap.c#L58)
* [`bool process_rgb_matrix(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/rgb_matrix.c#L139)
* [`bool process_midi(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_midi.c#L81)
* [`bool process_audio(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_audio.c#L19)
* [`bool process_steno(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_steno.c#L160)
* [`bool process_music(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_music.c#L114)
* [`bool process_tap_dance(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_tap_dance.c#L141)
* [`bool process_unicode_common(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_unicode_common.c#L169) は、以下のいずれかを呼び出します:
* [`bool process_unicode(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_unicode.c#L20)
* [`bool process_unicodemap(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_unicodemap.c#L46)
* [`bool process_ucis(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_ucis.c#L95)
* [`bool process_leader(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_leader.c#L51)
* [`bool process_combo(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_combo.c#L115)
* [`bool process_printer(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_printer.c#L77)
* [`bool process_auto_shift(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_auto_shift.c#L94)
* [`bool process_terminal(uint16_t keycode, keyrecord_t *record)`](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/process_keycode/process_terminal.c#L264)
* [Quantum 固有のキーコードを識別して処理する](https://github.com/qmk/qmk_firmware/blob/e1203a222bb12ab9733916164a000ef3ac48da93/quantum/quantum.c#L291)
この一連のイベントの中の任意のステップで (`process_record_kb()` のような)関数は `false` を返して、以降の処理を停止することができます。
この呼び出しの後で、`post_process_record()` が呼ばれます。これはキーコードが通常処理された後に実行する必要がある追加のクリーンアップを処理するために使うことができます。
* [`void post_process_record(keyrecord_t *record)`]()
* [`void post_process_record_quantum(keyrecord_t *record)`]()
* [このレコードをキーコードにマップする]()
* [`void post_process_clicky(uint16_t keycode, keyrecord_t *record)`]()
* [`void post_process_record_kb(uint16_t keycode, keyrecord_t *record)`]()
* [`void post_process_record_user(uint16_t keycode, keyrecord_t *record)`]()
<!--
#### Mouse Handling
FIXME: This needs to be written
#### Serial Link(s)
FIXME: This needs to be written
#### Visualizer
FIXME: This needs to be written
#### Keyboard state LEDs (Caps Lock, Num Lock, Scroll Lock)
FIXME: This needs to be written
-->

View File

@ -27,22 +27,25 @@ This key would activate Left Control and Left Shift when held, and send Escape w
For convenience, QMK includes some Mod-Tap shortcuts to make common combinations more compact in your keymap:
|Key |Aliases |Description |
|------------|-----------------------------------------------------------------|-------------------------------------------------------|
|`LCTL_T(kc)`|`CTL_T(kc)` |Left Control when held, `kc` when tapped |
|`LSFT_T(kc)`|`SFT_T(kc)` |Left Shift when held, `kc` when tapped |
|`LALT_T(kc)`|`LOPT_T(kc)`, `ALT_T(kc)`, `OPT_T(kc)` |Left Alt when held, `kc` when tapped |
|`LGUI_T(kc)`|`LCMD_T(kc)`, `LWIN_T(kc)`, `GUI_T(kc)`, `CMD_T(kc)`, `WIN_T(kc)`|Left GUI when held, `kc` when tapped |
|`RCTL_T(kc)`| |Right Control when held, `kc` when tapped |
|`RSFT_T(kc)`| |Right Shift when held, `kc` when tapped |
|`RALT_T(kc)`|`ROPT_T(kc)`, `ALGR_T(kc)` |Right Alt when held, `kc` when tapped |
|`RGUI_T(kc)`|`RCMD_T(kc)`, `RWIN_T(kc)` |Right GUI when held, `kc` when tapped |
|`SGUI_T(kc)`|`SCMD_T(kc)`, `SWIN_T(kc)` |Left Shift and GUI when held, `kc` when tapped |
|`LCA_T(kc)` | |Left Control and Alt when held, `kc` when tapped |
|`LCAG_T(kc)`| |Left Control, Alt and GUI when held, `kc` when tapped |
|`RCAG_T(kc)`| |Right Control, Alt and GUI when held, `kc` when tapped |
|`C_S_T(kc)` | |Left Control and Shift when held, `kc` when tapped |
|`MEH_T(kc)` | |Left Control, Shift and Alt when held, `kc` when tapped|
|Key |Aliases |Description |
|------------|-----------------------------------------------------------------|--------------------------------------------------------------|
|`LCTL_T(kc)`|`CTL_T(kc)` |Left Control when held, `kc` when tapped |
|`LSFT_T(kc)`|`SFT_T(kc)` |Left Shift when held, `kc` when tapped |
|`LALT_T(kc)`|`LOPT_T(kc)`, `ALT_T(kc)`, `OPT_T(kc)` |Left Alt when held, `kc` when tapped |
|`LGUI_T(kc)`|`LCMD_T(kc)`, `LWIN_T(kc)`, `GUI_T(kc)`, `CMD_T(kc)`, `WIN_T(kc)`|Left GUI when held, `kc` when tapped |
|`RCTL_T(kc)`| |Right Control when held, `kc` when tapped |
|`RSFT_T(kc)`| |Right Shift when held, `kc` when tapped |
|`RALT_T(kc)`|`ROPT_T(kc)`, `ALGR_T(kc)` |Right Alt when held, `kc` when tapped |
|`RGUI_T(kc)`|`RCMD_T(kc)`, `RWIN_T(kc)` |Right GUI when held, `kc` when tapped |
|`SGUI_T(kc)`|`SCMD_T(kc)`, `SWIN_T(kc)` |Left Shift and GUI when held, `kc` when tapped |
|`LCA_T(kc)` | |Left Control and Alt when held, `kc` when tapped |
|`LSA_T(kc)` | |Left Shift and Alt when held, `kc` when tapped |
|`RSA_T(kc)` |`SAGR_T(kc)` |Right Shift and Right Alt (AltGr) when held, `kc` when tapped |
|`RCS_T(kc)` | |Right Control and Right Shift when held, `kc` when tapped |
|`LCAG_T(kc)`| |Left Control, Alt and GUI when held, `kc` when tapped |
|`RCAG_T(kc)`| |Right Control, Alt and GUI when held, `kc` when tapped |
|`C_S_T(kc)` | |Left Control and Shift when held, `kc` when tapped |
|`MEH_T(kc)` | |Left Control, Shift and Alt when held, `kc` when tapped |
|`HYPR_T(kc)`|`ALL_T(kc)` |Left Control, Shift, Alt and GUI when held, `kc` when tapped - more info [here](http://brettterpstra.com/2012/12/08/a-useful-caps-lock-key/)|
## Caveats
@ -52,3 +55,7 @@ Unfortunately, these keycodes cannot be used in Mod-Taps or Layer-Taps, since an
Additionally, you may run into issues when using Remote Desktop Connection on Windows. Because these codes send shift very fast, Remote Desktop may miss the codes.
To fix this, open Remote Desktop Connection, click on "Show Options", open the the "Local Resources" tab. In the keyboard section, change the drop down to "On this Computer". This will fix the issue, and allow the characters to work correctly.
## Other Resources
See the [Tap-Hold Configuration Options](tap_hold.md) for additional flags that tweak Mod-Tap behavior.

View File

@ -81,7 +81,7 @@ Now, we will set up the MSYS2 window to show up in VSCode as the integrated term
?> If you installed MSYS2 to a different folder, then you'll need to change the path for `terminal.integrated.shell.windows` to the correct path for your system.
4. Hit Ctrl-`\`` (Grave) to bring up the terminal or go to <kbd><kbd>View</kbd> > <kbd>Terminal</kbd></kbd> (command `workbench.action.terminal.toggleTerminal`). A new terminal will be opened if there isnt one already.
4. Hit Ctrl-<code>&#96;</code> (Grave) to bring up the terminal or go to <kbd><kbd>View</kbd> > <kbd>Terminal</kbd></kbd> (command `workbench.action.terminal.toggleTerminal`). A new terminal will be opened if there isnt one already.
This should start the terminal in the workspace's folder (so the `qmk_firmware` folder), and then you can compile your keyboard.

View File

@ -43,7 +43,9 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
### `update_tri_layer_state(state, x, y, z)`
The other function is `update_tri_layer_state(state, x, y, z)`. This function is meant to be called from the [`layer_state_set_*` functions](custom_quantum_functions.md#layer-change-code). This means that any time that you use a keycode to change the layer, this will be checked. So you could use `LT(layer, kc)` to change the layer and it will trigger the same layer check.
The caveat to this method is that you cannot access the `z` layer without having `x` and `y` layers on, since if you try to activate just layer `z`, it will run this code and turn off layer `z` before you could use it.
There are a couple of caveats to this method:
1. You cannot access the `z` layer without having `x` and `y` layers on, since if you try to activate just layer `z`, it will run this code and turn off layer `z` before you could use it.
2. Because layers are processed from the highest number `z` should be a higher layer than `x` and `y` or you may not be able to access it.
#### Example
@ -97,7 +99,7 @@ To wipe the EEPROM, run `eeconfig_init()` from your function or macro to reset m
## Tap random key
If you want to send a random character to the host computer, you can use the `tap_random_base64()` function. This [pseudorandomly](https://en.wikipedia.org/wiki/Pseudorandom_number_generator) selects a number between 0 and 63, and then sends a key press based on that selection. (025 is `A``Z`, 2651 is `a``z`, 5261 is `0``9`, 62 is `+` and 63 is `/`).
If you want to send a random character to the host computer, you can use the `tap_random_base64()` function. This [pseudorandomly](https://en.wikipedia.org/wiki/Pseudorandom_number_generator) selects a number between 0 and 63, and then sends a key press based on that selection. (025 is `A``Z`, 2651 is `a``z`, 5261 is `0``9`, 62 is `+` and 63 is `/`).
?> Needless to say, but this is _not_ a cryptographically secure method of generating random Base64 keys or passwords.

View File

@ -31,7 +31,7 @@ Within our `info.json` file the `layouts` portion of the dictionary contains sev
* `height`
* Optional: The height of the layout in Key Units
* `key_count`
* **Required**: The number of keys in this layout
* Optional: The number of keys in this layout
* `layout`
* A list of Key Dictionaries describing the physical layout. See the next section for more details.

View File

@ -1,22 +1,22 @@
# Tap-Hold Configuration Options
While Tap-Hold options are fantastic, they are not without their issues. We have tried to configure them with reasonable defaults, but that may still cause issues for some people.
While Tap-Hold options are fantastic, they are not without their issues. We have tried to configure them with reasonable defaults, but that may still cause issues for some people.
These options let you modify the behavior of the Tap-Hold keys.
## Tapping Term
The crux of all of the following features is the tapping term setting. This determines what is a tap and what is a hold. And the exact timing for this to feel natural can vary from keyboard to keyboard, from switch to switch, and from key to key.
The crux of all of the following features is the tapping term setting. This determines what is a tap and what is a hold. And the exact timing for this to feel natural can vary from keyboard to keyboard, from switch to switch, and from key to key.
You can set the global time for this by adding the following setting to your `config.h`:
You can set the global time for this by adding the following setting to your `config.h`:
```c
#define TAPPING_TERM 200
```
This setting is defined in milliseconds, and does default to 200ms. This is a good average for a majority of people.
This setting is defined in milliseconds, and does default to 200ms. This is a good average for a majority of people.
For more granular control of this feature, you can add the following to your `config.h`:
For more granular control of this feature, you can add the following to your `config.h`:
```c
#define TAPPING_TERM_PER_KEY
```
@ -45,9 +45,9 @@ As of [PR#1359](https://github.com/qmk/qmk_firmware/pull/1359/), there is a new
#define PERMISSIVE_HOLD
```
This makes tap and hold keys (like Mod Tap) work better for fast typists, or for high `TAPPING_TERM` settings.
This makes tap and hold keys (like Mod Tap) work better for fast typists, or for high `TAPPING_TERM` settings.
If you press a Mod Tap key, tap another key (press and release) and then release the Mod Tap key, all within the tapping term, it will output the "tapping" function for both keys.
If you press a Mod Tap key, tap another key (press and release) and then release the Mod Tap key, all within the tapping term, it will output the tapping function for both keys.
For Instance:
@ -56,7 +56,7 @@ For Instance:
- `KC_X` Up
- `SFT_T(KC_A)` Up
Normally, if you do all this within the `TAPPING_TERM` (default: 200ms) this will be registered as `ax` by the firmware and host system. With permissive hold enabled, this modifies how this is handled by considering the Mod Tap keys as a Mod if another key is tapped, and would registered as `X` (`SHIFT`+`x`).
Normally, if you do all this within the `TAPPING_TERM` (default: 200ms) this will be registered as `ax` by the firmware and host system. With permissive hold enabled, this modifies how this is handled by considering the Mod Tap keys as a Mod if another key is tapped, and would registered as `X` (`SHIFT`+`x`).
?> If you have `Ignore Mod Tap Interrupt` enabled, as well, this will modify how both work. The regular key has the modifier added if the first key is released first or if both keys are held longer than the `TAPPING_TERM`.
@ -87,7 +87,7 @@ To enable this setting, add this to your `config.h`:
#define IGNORE_MOD_TAP_INTERRUPT
```
Similar to Permissive Hold, this alters how the firmware processes inputs for fast typists. If you press a Mod Tap key, press another key, release the Mod Tap key, and then release the normal key, it would normally output the "tapping" function for both keys. This may not be desirable for rolling combo keys.
Similar to Permissive Hold, this alters how the firmware processes inputs for fast typists. If you press a Mod Tap key, press another key, release the Mod Tap key, and then release the normal key, it would normally output the tapping function for both keys. This may not be desirable for rolling combo keys.
Setting `Ignore Mod Tap Interrupt` requires holding both keys for the `TAPPING_TERM` to trigger the hold function (the mod).
@ -126,27 +126,27 @@ bool get_ignore_mod_tap_interrupt(uint16_t keycode, keyrecord_t *record) {
## Tapping Force Hold
To enable `tapping force hold`, add the following to your `config.h`:
To enable `tapping force hold`, add the following to your `config.h`:
```c
#define TAPPING_FORCE_HOLD
```
When the user holds a key after tap, this repeats the tapped key rather to hold a modifier key. This allows to use auto repeat for the tapped key.
When the user holds a key after tapping it, the tapping function is repeated by default, rather than activating the hold function. This allows keeping the ability to auto-repeat the tapping function of a dual-role key. `TAPPING_FORCE_HOLD` removes that ability to let the user activate the hold function instead, in the case of holding the dual-role key after having tapped it.
Example:
- SFT_T(KC_A) Down
- SFT_T(KC_A) Up
- SFT_T(KC_A) Down
- wait more than tapping term...
- SFT_T(KC_A) Up
- `SFT_T(KC_A)` Down
- `SFT_T(KC_A)` Up
- `SFT_T(KC_A)` Down
- wait until the tapping term expires...
- `SFT_T(KC_A)` Up
With default settings, `a` will be sent on the first release, then `a` will be sent on the second press allowing the computer to trigger its auto repeat function.
With `TAPPING_FORCE_HOLD`, the second press will be interpreted as a Shift, allowing to use it as a modifier shortly after having used it as a tap.
!> `TAPPING_FORCE_HOLD` will break anything that uses tapping toggles (Such as the `TT` layer keycode, and the One Shot Tapping Toggle).
!> `TAPPING_FORCE_HOLD` will break anything that uses tapping toggles (Such as the `TT` layer keycode, and the One Shot Tap Toggle).
For more granular control of this feature, you can add the following to your `config.h`:
@ -169,7 +169,7 @@ bool get_tapping_force_hold(uint16_t keycode, keyrecord_t *record) {
## Retro Tapping
To enable `retro tapping`, add the following to your `config.h`:
To enable `retro tapping`, add the following to your `config.h`:
```c
#define RETRO_TAPPING
@ -179,11 +179,11 @@ Holding and releasing a dual function key without pressing another key will resu
For instance, holding and releasing `LT(2, KC_SPACE)` without hitting another key will result in nothing happening. With this enabled, it will send `KC_SPACE` instead.
## Why do we include the key record for the per key functions?
## Why do we include the key record for the per key functions?
One thing that you may notice is that we include the key record for all of the "per key" functions, and may be wondering why we do that.
One thing that you may notice is that we include the key record for all of the "per key" functions, and may be wondering why we do that.
Well, it's simply really: customization. But specifically, it depends on how your keyboard is wired up. For instance, if each row is actually using a row in the keyboard's matrix, then it may be simpler to use `if (record->event.row == 3)` instead of checking a whole bunch of keycodes. Which is especially good for those people using the Tap Hold type keys on the home row. So you could fine tune those to not interfere with your normal typing.
Well, it's simple really: customization. But specifically, it depends on how your keyboard is wired up. For instance, if each row is actually using a row in the keyboard's matrix, then it may be simpler to use `if (record->event.row == 3)` instead of checking a whole bunch of keycodes. Which is especially good for those people using the Tap Hold type keys on the home row. So you could fine tune those to not interfere with your normal typing.
## Why is there no `*_kb` or `*_user` functions?!

View File

@ -233,4 +233,5 @@ void IS31FL3731_update_led_control_registers(uint8_t addr, uint8_t index) {
IS31FL3731_write_register(addr, i, g_led_control_registers[index][i]);
}
}
g_led_control_registers_update_required[index] = false;
}

View File

@ -264,5 +264,6 @@ void IS31FL3736_update_led_control_registers(uint8_t addr1, uint8_t addr2) {
IS31FL3736_write_register(addr1, i, g_led_control_registers[0][i]);
// IS31FL3736_write_register(addr2, i, g_led_control_registers[1][i]);
}
g_led_control_registers_update_required = false;
}
}

View File

@ -218,5 +218,6 @@ void IS31FL3737_update_led_control_registers(uint8_t addr1, uint8_t addr2) {
IS31FL3737_write_register(addr1, i, g_led_control_registers[0][i]);
// IS31FL3737_write_register(addr2, i, g_led_control_registers[1][i]);
}
g_led_control_registers_update_required = false;
}
}

View File

@ -97,14 +97,13 @@ bool IS31FL3741_write_pwm_buffer(uint8_t addr, uint8_t *pwm_buffer) {
IS31FL3741_write_register(addr, ISSI_COMMANDREGISTER, ISSI_PAGE_PWM0);
for (int i = 0; i < 342; i += 18) {
g_twi_transfer_buffer[0] = i % 180;
if (i == 180) {
// unlock the command register and select PG2
IS31FL3741_write_register(addr, ISSI_COMMANDREGISTER_WRITELOCK, 0xC5);
IS31FL3741_write_register(addr, ISSI_COMMANDREGISTER, ISSI_PAGE_PWM1);
}
g_twi_transfer_buffer[0] = i % 180;
memcpy(g_twi_transfer_buffer + 1, pwm_buffer + i, 18);
#if ISSI_PERSISTENCE > 0
@ -251,4 +250,6 @@ void IS31FL3741_set_scaling_registers(const is31_led *pled, uint8_t red, uint8_t
g_scaling_registers[pled->driver][pled->r] = red;
g_scaling_registers[pled->driver][pled->g] = green;
g_scaling_registers[pled->driver][pled->b] = blue;
g_scaling_registers_update_required[pled->driver] = true;
}

View File

@ -23,14 +23,13 @@
#include <stdbool.h>
typedef struct is31_led {
uint8_t driver : 2;
uint16_t r;
uint16_t g;
uint16_t b;
uint32_t driver : 2;
uint32_t r : 10;
uint32_t g : 10;
uint32_t b : 10;
} __attribute__((packed)) is31_led;
extern const is31_led g_is31_leds[DRIVER_LED_TOTAL];
extern const is31_led g_is31_indicator_leds[DRIVER_INDICATOR_LED_TOTAL];
void IS31FL3741_init(uint8_t addr);
void IS31FL3741_write_register(uint8_t addr, uint8_t reg, uint8_t data);

View File

@ -75,8 +75,14 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define CHARGE_PUMP 0x8D
// Misc defines
#define OLED_BLOCK_COUNT (sizeof(OLED_BLOCK_TYPE) * 8)
#define OLED_BLOCK_SIZE (OLED_MATRIX_SIZE / OLED_BLOCK_COUNT)
#ifndef OLED_BLOCK_COUNT
# define OLED_BLOCK_COUNT (sizeof(OLED_BLOCK_TYPE) * 8)
#endif
#ifndef OLED_BLOCK_SIZE
# define OLED_BLOCK_SIZE (OLED_MATRIX_SIZE / OLED_BLOCK_COUNT)
#endif
#define OLED_ALL_BLOCKS_MASK (((((OLED_BLOCK_TYPE)1 << (OLED_BLOCK_COUNT - 1)) - 1) << 1) | 1)
// i2c defines
#define I2C_CMD 0x00
@ -101,6 +107,7 @@ OLED_BLOCK_TYPE oled_dirty = 0;
bool oled_initialized = false;
bool oled_active = false;
bool oled_scrolling = false;
uint8_t oled_brightness = OLED_BRIGHTNESS;
uint8_t oled_rotation = 0;
uint8_t oled_rotation_width = 0;
uint8_t oled_scroll_speed = 0; // this holds the speed after being remapped to ssd1306 internal values
@ -187,7 +194,7 @@ bool oled_init(uint8_t rotation) {
}
}
static const uint8_t PROGMEM display_setup2[] = {I2C_CMD, COM_PINS, OLED_COM_PINS, CONTRAST, 0x8F, PRE_CHARGE_PERIOD, 0xF1, VCOM_DETECT, 0x40, DISPLAY_ALL_ON_RESUME, NORMAL_DISPLAY, DEACTIVATE_SCROLL, DISPLAY_ON};
static const uint8_t PROGMEM display_setup2[] = {I2C_CMD, COM_PINS, OLED_COM_PINS, CONTRAST, OLED_BRIGHTNESS, PRE_CHARGE_PERIOD, 0xF1, VCOM_DETECT, 0x20, DISPLAY_ALL_ON_RESUME, NORMAL_DISPLAY, DEACTIVATE_SCROLL, DISPLAY_ON};
if (I2C_TRANSMIT_P(display_setup2) != I2C_STATUS_SUCCESS) {
print("display_setup2 failed\n");
return false;
@ -212,7 +219,7 @@ __attribute__((weak)) oled_rotation_t oled_init_user(oled_rotation_t rotation) {
void oled_clear(void) {
memset(oled_buffer, 0, sizeof(oled_buffer));
oled_cursor = &oled_buffer[0];
oled_dirty = -1; // -1 will be max value as long as display_dirty is unsigned type
oled_dirty = OLED_ALL_BLOCKS_MASK;
}
static void calc_bounds(uint8_t update_start, uint8_t *cmd_array) {
@ -262,13 +269,14 @@ static void rotate_90(const uint8_t *src, uint8_t *dest) {
void oled_render(void) {
// Do we have work to do?
oled_dirty &= OLED_ALL_BLOCKS_MASK;
if (!oled_dirty || oled_scrolling) {
return;
}
// Find first dirty block
uint8_t update_start = 0;
while (!(oled_dirty & (1 << update_start))) {
while (!(oled_dirty & ((OLED_BLOCK_TYPE)1 << update_start))) {
++update_start;
}
@ -314,7 +322,7 @@ void oled_render(void) {
oled_on();
// Clear dirty flag
oled_dirty &= ~(1 << update_start);
oled_dirty &= ~((OLED_BLOCK_TYPE)1 << update_start);
}
void oled_set_cursor(uint8_t col, uint8_t line) {
@ -404,9 +412,9 @@ void oled_write_char(const char data, bool invert) {
// Dirty check
if (memcmp(&oled_temp_buffer, oled_cursor, OLED_FONT_WIDTH)) {
uint16_t index = oled_cursor - &oled_buffer[0];
oled_dirty |= (1 << (index / OLED_BLOCK_SIZE));
oled_dirty |= ((OLED_BLOCK_TYPE)1 << (index / OLED_BLOCK_SIZE));
// Edgecase check if the written data spans the 2 chunks
oled_dirty |= (1 << ((index + OLED_FONT_WIDTH) / OLED_BLOCK_SIZE));
oled_dirty |= ((OLED_BLOCK_TYPE)1 << ((index + OLED_FONT_WIDTH - 1) / OLED_BLOCK_SIZE));
}
// Finally move to the next char
@ -441,7 +449,7 @@ void oled_pan(bool left) {
}
}
}
oled_dirty = ~((OLED_BLOCK_TYPE)0);
oled_dirty = OLED_ALL_BLOCKS_MASK;
}
oled_buffer_reader_t oled_read_raw(uint16_t start_index) {
@ -456,7 +464,7 @@ void oled_write_raw_byte(const char data, uint16_t index) {
if (index > OLED_MATRIX_SIZE) index = OLED_MATRIX_SIZE;
if (oled_buffer[index] == data) return;
oled_buffer[index] = data;
oled_dirty |= (1 << (index / OLED_BLOCK_SIZE));
oled_dirty |= ((OLED_BLOCK_TYPE)1 << (index / OLED_BLOCK_SIZE));
}
void oled_write_raw(const char *data, uint16_t size) {
@ -464,21 +472,28 @@ void oled_write_raw(const char *data, uint16_t size) {
for (uint16_t i = 0; i < size; i++) {
if (oled_buffer[i] == data[i]) continue;
oled_buffer[i] = data[i];
oled_dirty |= (1 << (i / OLED_BLOCK_SIZE));
oled_dirty |= ((OLED_BLOCK_TYPE)1 << (i / OLED_BLOCK_SIZE));
}
}
void oled_write_pixel(uint8_t x, uint8_t y, bool on) {
if (x >= OLED_DISPLAY_WIDTH || y >= OLED_DISPLAY_HEIGHT) {
if (x >= oled_rotation_width) {
return;
}
uint16_t index = x + (y / 8) * OLED_DISPLAY_WIDTH;
if (on) {
oled_buffer[index] |= (1 << (y % 8));
} else {
oled_buffer[index] &= ~(1 << (y % 8));
uint16_t index = x + (y / 8) * oled_rotation_width;
if (index >= OLED_MATRIX_SIZE) {
return;
}
uint8_t data = oled_buffer[index];
if (on) {
data |= (1 << (y % 8));
} else {
data &= ~(1 << (y % 8));
}
if (oled_buffer[index] != data) {
oled_buffer[index] = data;
oled_dirty |= ((OLED_BLOCK_TYPE)1 << (index / OLED_BLOCK_SIZE));
}
oled_dirty |= (1 << (index / OLED_BLOCK_SIZE));
}
#if defined(__AVR__)
@ -501,7 +516,7 @@ void oled_write_raw_P(const char *data, uint16_t size) {
uint8_t c = pgm_read_byte(data++);
if (oled_buffer[i] == c) continue;
oled_buffer[i] = c;
oled_dirty |= (1 << (i / OLED_BLOCK_SIZE));
oled_dirty |= ((OLED_BLOCK_TYPE)1 << (i / OLED_BLOCK_SIZE));
}
}
#endif // defined(__AVR__)
@ -534,6 +549,22 @@ bool oled_off(void) {
return !oled_active;
}
bool is_oled_on(void) { return oled_active; }
uint8_t oled_set_brightness(uint8_t level) {
uint8_t set_contrast[] = {I2C_CMD, CONTRAST, level};
if (oled_brightness != level) {
if (I2C_TRANSMIT(set_contrast) != I2C_STATUS_SUCCESS) {
print("set_brightness cmd failed\n");
return oled_brightness;
}
oled_brightness = level;
}
return oled_brightness;
}
uint8_t oled_get_brightness(void) { return oled_brightness; }
// Set the specific 8 lines rows of the screen to scroll.
// 0 is the default for start, and 7 for end, which is the entire
// height of the screen. For 128x32 screens, rows 4-7 are not used.
@ -595,7 +626,7 @@ bool oled_scroll_off(void) {
return oled_scrolling;
}
oled_scrolling = false;
oled_dirty = -1;
oled_dirty = OLED_ALL_BLOCKS_MASK;
}
return !oled_scrolling;
}

View File

@ -141,6 +141,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#if !defined(OLED_FONT_HEIGHT)
# define OLED_FONT_HEIGHT 8
#endif
// Default brightness level
#if !defined(OLED_BRIGHTNESS)
# define OLED_BRIGHTNESS 255
#endif
#if !defined(OLED_TIMEOUT)
# if defined(OLED_DISABLE_TIMEOUT)
@ -257,6 +261,16 @@ bool oled_on(void);
// Returns true if the screen was off or turns off
bool oled_off(void);
// Returns true if the oled is currently on, false if it is
// not
bool is_oled_on(void);
// Sets the brightness of the display
uint8_t oled_set_brightness(uint8_t level);
// Gets the current brightness of the display
uint8_t oled_get_brightness(void);
// Basically it's oled_render, but with timeout management and oled_task_user calling!
void oled_task(void);

View File

@ -0,0 +1,42 @@
/*
* Dan's Magicforce 68 (MF68) QMK Keyboard
* Copyright (C) Dan <https://github.com/delivrance>
*
* This file is part of Dan's MF68 QMK Keyboard.
*
* Dan's MF68 QMK Keyboard 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 3 of the License, or
* (at your option) any later version.
*
* Dan's MF68 QMK Keyboard 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 Dan's MF68 QMK Keyboard. If not, see <https://www.gnu.org/licenses/>.
*/
#pragma once
#undef MANUFACTURER
#define MANUFACTURER Dan
#undef PRODUCT
#define PRODUCT Magicforce 68 QMK
#undef BACKLIGHT_LEVELS
#define BACKLIGHT_LEVELS 20
// Disable backlight breathing
#undef BACKLIGHT_BREATHING
// Set USB polling rate to 1000 Hz
#define USB_POLLING_INTERVAL_MS 1
// Enable NKRO on boot
#define FORCE_NKRO
// Backlight idle timeout in seconds
#define BACKLIGHT_IDLE_TIMEOUT 1200

View File

@ -0,0 +1,232 @@
/*
* Dan's Magicforce 68 (MF68) QMK Keyboard
* Copyright (C) Dan <https://github.com/delivrance>
*
* This file is part of Dan's MF68 QMK Keyboard.
*
* Dan's MF68 QMK Keyboard 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 3 of the License, or
* (at your option) any later version.
*
* Dan's MF68 QMK Keyboard 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 Dan's MF68 QMK Keyboard. If not, see <https://www.gnu.org/licenses/>.
*/
#include QMK_KEYBOARD_H
#define KC_ KC_TRNS
#define KC_FN1 MO(_FN)
#define KC_FN2 LT(_FN, KC_CAPS)
#define KC_BLUP BL_INC // Backlight increase
#define KC_BLDN BL_DEC // Backlight decrease
#define KC_BLTOG BL_TOGG // Backlight toggle
#define KC_TERM TERM_ON // Terminal mode on
#define KC_REC1 DM_REC1 // Record macro 1
#define KC_PLY1 DM_PLY1 // Play macro 1
#define KC_REC2 DM_REC2 // Record macro 2
#define KC_PLY2 DM_PLY2 // Play macro 1
#define KC_RSTP DM_RSTP // Stop macro recording
enum {
_QWERTY,
_FN
};
/* ┏━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━━━━━┓ ┏━━━━┳━━━━┓
Esc 1! 2@ 3# 4$ 5% 6^ 7& 8* 9( 0) -_ =+ Ins PgUp
Tab Q W E R T Y U I O P [{ ]} \| Del PgDn
Caps A S D F G H J K L ;: '" ┃ Enter ┃ Magicforce
Shift Z X C V B N M ,< .> /? Shift Dan
Ctrl GUI Alt Alt Fn Ctrl
*/
// clang-format off
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = LAYOUT_kc( /* Default layer
*/
GESC, 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 0 ,MINS,EQL , BSPC , INS ,PGUP, /*
*/
TAB , Q , W , E , R , T , Y , U , I , O , P ,LBRC,RBRC, BSLS , DEL ,PGDN, /*
*/
FN2 , A , S , D , F , G , H , J , K , L ,SCLN,QUOT, ENTER , /*
*/
LSFT , Z , X , C , V , B , N , M ,COMM,DOT ,SLSH, RSFT , UP , /*
*/
LCTL ,LGUI ,LALT , SPACE ,RALT , FN1 ,RCTL , LEFT,DOWN,RGHT /*
*/),
[_FN] = LAYOUT_kc( /* FN & CAPS layer
*/
GRV , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , F9 , F10, F11, F12, RSTP , PSCR,HOME, /*
Esc 1! 2@ 3# 4$ 5% 6^ 7& 8* 9( 0) -_ =+ Ins PgUp */
,PLY1,PLY2, , , , , , 7 , 8 , 9 ,BLDN,BLUP,BLTOG , ,END , /*
Tab Q W E R T Y U I O P [{ ]} \| Del PgDn */
, , , , , , , , 4 , 5 , 6 , , TERM , /*
Caps A S D F G H J K L ;: '" ┻━ Enter ━┫ ┏━━━━┓ */
,REC1,REC2, , ,MSTP, ,MUTE, 1 , 2 , 3 , , VOLU, /*
Shift Z X C V B N M ,< .> /? Shift */
, , , MPLY , 0 , , , MPRV,VOLD,MNXT /*
Ctrl GUI Alt Space Alt Fn Ctrl */)
};
// clang-format on
// Initialization code
// -------------------
void keyboard_post_init_user(void) {
backlight_level(2);
}
// Custom backlight driver
// -----------------------
// http://jared.geek.nz/2013/feb/linear-led-pwm
float cie1931(float x) {
x *= 100.0 / BACKLIGHT_LEVELS;
float y;
if (x < 8) {
y = x / 902.3;
} else {
y = (x + 16.0) / 116.0;
y = y * y * y;
}
return round(y * 255);
}
void backlight_init_ports(void) {
setPinOutput(BACKLIGHT_PIN);
writePinLow(BACKLIGHT_PIN);
TCCR1A = _BV(COM1A1) | _BV(WGM11);
TCCR1B = _BV(WGM13) | _BV(WGM12) | _BV(CS10);
ICR1 = 0xFFU; // Set PWM levels to 255 (enables high-frequency PWM)
}
void backlight_set(uint8_t level) {
if (level > BACKLIGHT_LEVELS) {
level = BACKLIGHT_LEVELS;
}
if (level == 0) {
TCCR1A &= ~(_BV(COM1A1)); // Disable PWM
} else {
TCCR1A |= _BV(COM1A1); // Enable PWM
}
OCR1A = cie1931(level);
}
// Custom macro hooks
// ------------------
// Redefine with lower delay
void led_blink(void) {
backlight_toggle();
wait_ms(25);
backlight_toggle();
}
void dynamic_macro_record_start_user(void) {
led_blink();
}
void dynamic_macro_play_user(int8_t direction) {
led_blink();
}
void dynamic_macro_record_key_user(int8_t direction, keyrecord_t *record) {
led_blink();
}
void dynamic_macro_record_end_user(int8_t direction) {
led_blink();
}
// Custom Caps Lock backlight behaviour
// ------------------------------------
void led_set_user(uint8_t usb_led) {
// This exists because I don't like the backlight to turn OFF when the Caps Lock is ON.
// That is, this will turn the backlight ON (at half the brightness) when the Caps Lock is ON as well.
static bool prev_is_caps_on;
bool is_caps_on = IS_LED_ON(usb_led, USB_LED_CAPS_LOCK);
if (prev_is_caps_on != is_caps_on) {
prev_is_caps_on = is_caps_on;
if (is_caps_on) {
backlight_set(BACKLIGHT_LEVELS / 2);
} else {
if (is_backlight_enabled()) {
backlight_set(get_backlight_level());
} else {
backlight_set(0);
}
}
}
// Turn on the Pro Micro's on-board LEDs for Caps Lock
if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) {
// Set to low
setPinOutput(B0);
writePinLow(B0);
setPinOutput(D5);
writePinLow(D5);
} else {
// Set to Hi-Z
setPinInput(B0);
setPinInput(D5);
}
}
// Backlight idle timeout feature
// ------------------------------
static uint32_t timer;
static bool is_idle;
void matrix_scan_user() {
// Check the timer only if the keyboard is not idle
if (!is_idle) {
if (timer_elapsed32(timer) >= (uint32_t) BACKLIGHT_IDLE_TIMEOUT * 1000) {
is_idle = true;
// Both backlight_level and backlight_level_noeeprom modify the global backlight config (not useful)
// Instead, use backlight_set in order to restore the current backlight level later on
backlight_set(0);
}
}
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
// Reset timer on each keypress
timer = timer_read32();
// Enable backlight back only when keyboard is idling (which implies the backlight was turned off previously)
if (is_idle) {
is_idle = false;
// Set back the original backlight level only if it is actually enabled globally
if (is_backlight_enabled()) {
// The current backlight level can be obtained with get_backlight_level
backlight_set(get_backlight_level());
}
}
return true;
}

View File

@ -0,0 +1,38 @@
# Dan's Magicforce 68 (MF68) QMK Keyboard
> https://github.com/delivrance
```
┏━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━┳━━━━━━━━┓ ┏━━━━┳━━━━┓
┃Esc ┃ 1! ┃ 2@ ┃ 3# ┃ 4$ ┃ 5% ┃ 6^ ┃ 7& ┃ 8* ┃ 9( ┃ 0) ┃ -_ ┃ =+ ┃ ←─ ┃ ┃Ins ┃PgUp┃
┣━━━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━━━━━┫ ┣━━━━╋━━━━┫
┃ Tab ┃ Q ┃ W ┃ E ┃ R ┃ T ┃ Y ┃ U ┃ I ┃ O ┃ P ┃ [{ ┃ ]} ┃ \| ┃ ┃Del ┃PgDn┃
┣━━━━━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━━━━━━┫ ┗━━━━┻━━━━┛
┃ Caps ┃ A ┃ S ┃ D ┃ F ┃ G ┃ H ┃ J ┃ K ┃ L ┃ ;: ┃ '" ┃ Enter ┃ Magicforce
┣━━━━━━━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━┳━━┻━━━━━━━━━┫ ┏━━━━┓
┃ Shift ┃ Z ┃ X ┃ C ┃ V ┃ B ┃ N ┃ M ┃ ,< ┃ .> ┃ /? ┃ Shift ┃ ┃ ↑ ┃ Dan
┣━━━━━┳━━━━┻┳━━━┻━┳━━┻━━━━┻━━━━┻━━━━┻━━━━┻━━━━┻━━━┳┻━━━━╋━━━━┻┳━━━━━┳━━┳━━┻━╋━━━━╋━━━━┓
┃Ctrl ┃ GUI ┃ Alt ┃ ━━━━━ ┃ Alt ┃ Fn ┃Ctrl ┃ ┃ ← ┃ ↓ ┃ → ┃
┗━━━━━┻━━━━━┻━━━━━┻━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┻━━━━━┻━━━━━┻━━━━━┛ ┗━━━━┻━━━━┻━━━━┛
```
## Features
- Right ALT and FN keys swapped.
- USB Polling rate set to 1000 Hz (1 ms).
- Dynamic macros enabled (2 macros).
- Transient EEPROM to avoid wearing (r/w from/to RAM).
- NKRO enabled on boot (up to 248 keys at once).
- CAPS LOCK key used as alias to the FN key.
- Pro Micro's on-board LEDs used for CAPS LOCK status.
- Backlight also used as CAPS LOCK status indicator.
- Both Grave and Tilde characters embedded in ESC.
- Media control keys and extra number keys (numpad).
- Flicker-free backlight thanks to high-frequency PWM mode.
- Linear backlight brightness intensity (better for human eyes).
- Backlight turns off automatically after 20 minutes idle.
- Backlight brightness levels set to 20 (5% steps) + 1 (off).
- Backlight breathing completely disabled.
- Link Time Optimizations to reduce compiled size.
- QMK Terminal enabled for fun (pretty useless in practice).
- Performing ~1550 matrix scans per second.

View File

@ -0,0 +1,10 @@
BACKLIGHT_DRIVER = custom
NKRO_ENABLE = yes
TERMINAL_ENABLE = yes
DYNAMIC_MACRO_ENABLE = yes
# Use RAM (fake EEPROM, transient) instead of real EEPROM
EEPROM_DRIVER = transient
# LTO: Link Time Optimizations. Reduce compiled size
LTO_ENABLE = yes

View File

@ -1,3 +1,19 @@
/* Copyright 2020 Christopher Courtney, aka Drashna Jael're (@drashna) <drashna@live.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 "drashna.h"
#include "analog.h"
#include "pointing_device.h"

View File

@ -19,8 +19,8 @@
#include "config_common.h"
/* USB Device descriptor parameter */
#define VENDOR_ID 0xFEED
#define PRODUCT_ID 0x0A0C
#define VENDOR_ID 0x3430 // "40"
#define PRODUCT_ID 0x9999
#define DEVICE_VER 0x9999
#define MANUFACTURER di0ib
#define PRODUCT The nein Keyboard

View File

@ -1,6 +1,6 @@
{
"keyboard_name": "nein",
"url": "",
"url": "http://www.40percent.club/2019/04/nein.html",
"maintainer": "qmk",
"width": 3,
"height": 3,

View File

@ -0,0 +1,39 @@
/* Copyright 2019
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include QMK_KEYBOARD_H
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT_ortho_3x3(
KC_MUTE, KC_HOME, KC_MPLY,
MO(1), KC_UP, KC_END,
KC_LEFT, KC_DOWN, KC_RGHT
),
[1] = LAYOUT_ortho_3x3(
RESET, _______, KC_STOP,
_______, _______, RGB_MOD,
KC_MPRV, _______, KC_MNXT
),
[2] = LAYOUT_ortho_3x3(
_______, _______, _______,
_______, _______, _______,
_______, _______, _______
),
[3] = LAYOUT_ortho_3x3(
_______, _______, _______,
_______, _______, _______,
_______, _______, _______
),
};

View File

@ -0,0 +1,2 @@
VIA_ENABLE = yes
LTO_ENABLE = yes

View File

@ -0,0 +1,19 @@
/*
Copyright 2020 Alec Penland
Copyright 2020 Garret Gartner
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 "45_ats.h"

View File

@ -0,0 +1,59 @@
/*
Copyright 2020 Alec Penland
Copyright 2020 Garret Gartner
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "quantum.h"
#define xxx KC_NO
#define LAYOUT_split_space( \
k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D, \
k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1D, \
k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2D, \
k30, k31, k32, k33, k36, k38, k39, k3A, k3B, k3D \
) { \
{ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D }, \
{ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, xxx, k1D }, \
{ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, xxx, k2D }, \
{ k30, k31, k32, k33, xxx, xxx, k36, xxx, k38, k39, k3A, k3B, xxx, k3D } \
}
#define LAYOUT_625_space( \
k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D, \
k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1D, \
k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2D, \
k30, k31, k32, k36, k39, k3A, k3B, k3D \
) { \
{ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D }, \
{ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, xxx, k1D }, \
{ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, xxx, k2D }, \
{ k30, k31, k32, xxx, xxx, xxx, k36, xxx, xxx, k39, k3A, k3B, xxx, k3D } \
}
#define LAYOUT_600_space( \
k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D, \
k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, k1D, \
k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, k2D, \
k30, k31, k32, k36, k38, k39, k3A, k3B, k3D \
) { \
{ k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0A, k0B, k0C, k0D }, \
{ k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1A, k1B, xxx, k1D }, \
{ k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2A, k2B, xxx, k2D }, \
{ k30, k31, k32, xxx, xxx, xxx, k36, xxx, k38, k39, k3A, k3B, xxx, k3D } \
}

View File

@ -0,0 +1,52 @@
/*
Copyright 2020 Alec Penland
Copyright 2020 Garret Gartner
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "config_common.h"
/* USB Device descriptor parameter */
#define VENDOR_ID 0xAB13
#define PRODUCT_ID 0x4511
#define DEVICE_VER 0x0001
#define MANUFACTURER Abec13
#define PRODUCT 45ATS
/* key matrix size */
#define MATRIX_ROWS 4
#define MATRIX_COLS 14
#define ENCODERS_PAD_A { B4 }
#define ENCODERS_PAD_B { B5 }
/* key matrix pins */
#define MATRIX_ROW_PINS { D3, D5, D7, D6 }
#define MATRIX_COL_PINS { E6, B0, B1, B2, B3, B7, F6, F5, F4, C7, F7, C6, B6, D4 }
#define UNUSED_PINS
/* COL2ROW or ROW2COL */
#define DIODE_DIRECTION COL2ROW
/* Set 0 if debouncing isn't needed */
#define DEBOUNCE 5
/* 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

View File

@ -0,0 +1,169 @@
{
"keyboard_name": "45-ATS",
"url": "",
"maintainer": "The-Royal",
"width": 14.25,
"height": 4.25,
"layouts": {
"LAYOUT_split_space": {
"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":"", "x":13.5, "y":0},
{"label":"", "x":0, "y":1, "w":1.25},
{"label":"", "x":1.25, "y":1},
{"label":"", "x":2.25, "y":1},
{"label":"", "x":3.25, "y":1},
{"label":"", "x":4.25, "y":1},
{"label":"", "x":5.25, "y":1},
{"label":"", "x":6.25, "y":1},
{"label":"", "x":7.25, "y":1},
{"label":"", "x":8.25, "y":1},
{"label":"", "x":9.25, "y":1},
{"label":"", "x":10.25, "y":1},
{"label":"", "x":11.25, "y":1, "w":1.75},
{"label":"", "x":13.5, "y":1},
{"label":"", "x":0, "y":2, "w":1.75},
{"label":"", "x":1.75, "y":2},
{"label":"", "x":2.75, "y":2},
{"label":"", "x":3.75, "y":2},
{"label":"", "x":4.75, "y":2},
{"label":"", "x":5.75, "y":2},
{"label":"", "x":6.75, "y":2},
{"label":"", "x":7.75, "y":2},
{"label":"", "x":8.75, "y":2},
{"label":"", "x":9.75, "y":2},
{"label":"", "x":10.75, "y":2, "w":1.25},
{"label":"", "x":12.25, "y":2.25},
{"label":"", "x":13.5, "y":2},
{"label":"", "x":0, "y":3, "w":1.25},
{"label":"", "x":1.25, "y":3},
{"label":"", "x":2.25, "y":3, "w":1.25},
{"label":"", "x":3.5, "y":3, "w":2.75},
{"label":"", "x":6.25, "y":3, "w":2.25},
{"label":"", "x":8.5, "y":3, "w":1.25},
{"label":"", "x":9.75, "y":3, "w":1.25},
{"label":"", "x":11.25, "y":3.25},
{"label":"", "x":12.25, "y":3.25},
{"label":"", "x":13.25, "y":3.25}
]
},
"LAYOUT_625_space": {
"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":"", "x":13.5, "y":0},
{"label":"", "x":0, "y":1, "w":1.25},
{"label":"", "x":1.25, "y":1},
{"label":"", "x":2.25, "y":1},
{"label":"", "x":3.25, "y":1},
{"label":"", "x":4.25, "y":1},
{"label":"", "x":5.25, "y":1},
{"label":"", "x":6.25, "y":1},
{"label":"", "x":7.25, "y":1},
{"label":"", "x":8.25, "y":1},
{"label":"", "x":9.25, "y":1},
{"label":"", "x":10.25, "y":1},
{"label":"", "x":11.25, "y":1, "w":1.75},
{"label":"", "x":13.5, "y":1},
{"label":"", "x":0, "y":2, "w":1.75},
{"label":"", "x":1.75, "y":2},
{"label":"", "x":2.75, "y":2},
{"label":"", "x":3.75, "y":2},
{"label":"", "x":4.75, "y":2},
{"label":"", "x":5.75, "y":2},
{"label":"", "x":6.75, "y":2},
{"label":"", "x":7.75, "y":2},
{"label":"", "x":8.75, "y":2},
{"label":"", "x":9.75, "y":2},
{"label":"", "x":10.75, "y":2, "w":1.25},
{"label":"", "x":12.25, "y":2.25},
{"label":"K", "x":13.5, "y":2},
{"label":"", "x":0, "y":3, "w":1.25},
{"label":"", "x":1.25, "y":3},
{"label":"", "x":2.25, "y":3, "w":1.25},
{"label":"", "x":3.5, "y":3, "w":6.25},
{"label":"", "x":9.75, "y":3, "w":1.25},
{"label":"", "x":11.25, "y":3.25},
{"label":"", "x":12.25, "y":3.25},
{"label":"", "x":13.25, "y":3.25}
]
},
"LAYOUT_600_space": {
"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":"", "x":13.5, "y":0},
{"label":"", "x":0, "y":1, "w":1.25},
{"label":"", "x":1.25, "y":1},
{"label":"", "x":2.25, "y":1},
{"label":"", "x":3.25, "y":1},
{"label":"", "x":4.25, "y":1},
{"label":"", "x":5.25, "y":1},
{"label":"", "x":6.25, "y":1},
{"label":"", "x":7.25, "y":1},
{"label":"", "x":8.25, "y":1},
{"label":"", "x":9.25, "y":1},
{"label":"", "x":10.25, "y":1},
{"label":"", "x":11.25, "y":1, "w":1.75},
{"label":"", "x":13.5, "y":1},
{"label":"", "x":0, "y":2, "w":1.75},
{"label":"", "x":1.75, "y":2},
{"label":"", "x":2.75, "y":2},
{"label":"", "x":3.75, "y":2},
{"label":"", "x":4.75, "y":2},
{"label":"", "x":5.75, "y":2},
{"label":"", "x":6.75, "y":2},
{"label":"", "x":7.75, "y":2},
{"label":"", "x":8.75, "y":2},
{"label":"", "x":9.75, "y":2},
{"label":"", "x":10.75, "y":2, "w":1.25},
{"label":"", "x":12.25, "y":2.25},
{"label":"", "x":13.5, "y":2},
{"label":"", "x":0, "y":3},
{"label":"", "x":1, "y":3},
{"label":"", "x":2, "y":3},
{"label":"", "x":3, "y":3, "w":6.00},
{"label":"", "x":9, "y":3},
{"label":"", "x":10, "y":3},
{"label":"", "x":11.25, "y":3.25},
{"label":"", "x":12.25, "y":3.25},
{"label":"", "x":13.25, "y":3.25}
]
}
}
}

View File

@ -0,0 +1,25 @@
/*
Copyright 2020 Alec Penland
Copyright 2020 Garret Gartner
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define TAPPING_TERM 175
#define PERMISSIVE_HOLD
#define MOD_TAP_INTERUPT

View File

@ -0,0 +1,107 @@
/*
Copyright 2020 Alec Penland
Copyright 2020 Garret Gartner
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
// Layer names
enum ats_layers{
// - Base layer:
_BASE,
// - Symbols, numbers, and functions:
_FN,
// - Alternate Function layer:
_LN
};
#define RS_SLS RSFT_T(KC_SLSH)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Default QWERTY layer
*
* Esc Q W E R T Y U I O P DelBkS PgU
*
* Tab A S D F G H J K L ' Enter PgD
*
* LShift Z X C V B N M , . Sft/ CAP
*
* LCtlOS LAlt Fn Space RAlt Ln
*
*
*/
[_BASE] = LAYOUT_split_space(
KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_BSPC, KC_PGUP,
KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOTE, KC_ENT, KC_PGDN,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, RS_SLS, KC_UP, KC_CAPS,
KC_LCTL, KC_LGUI, KC_LALT, MO(_FN), KC_SPACE, KC_RALT, MO(_LN), KC_LEFT, KC_DOWN, KC_RIGHT
),
/* Main Numbers, Symbols & Function Layer (MOMENTARY)
*
* ! @ # $ % ^ & * [ ] \ Hme
*
* 1 2 3 4 5 6 7 8 9 0 End
*
* ( ) ; . - + * / =
*
*
*
*
*/
[_FN] = LAYOUT_split_space(
_______, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LBRC, KC_RBRC, KC_BSLS, _______, KC_HOME,
_______, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_ENTER, KC_END,
_______, KC_LPRN, KC_RPRN, KC_SCLN, KC_DOT, _______, KC_MINS, KC_PLUS, KC_ASTR, KC_SLSH, KC_EQL, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* ALTERNATE Function layer (MOMENTARY)
*
* PWRF1 F2 F3 F4 F5 F6 PRVNXT VL+
*
* SLP F7 F8 F9 F10F11F12 PLAY VL-
*
* WAKE
*
* RSET
*
*
*/
[_LN] = LAYOUT_split_space(
KC_PWR, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, _______, _______, _______, _______, KC_MPRV, KC_MNXT, KC_VOLU,
KC_SLEP, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______, _______, _______, KC_MPLY, KC_VOLD,
KC_WAKE, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______
)
};
//function for layer indicator LED
layer_state_t layer_state_set_user(layer_state_t state) {
writePin(D0, layer_state_cmp(state, 0));
writePin(D1, layer_state_cmp(state, 1));
writePin(D2, layer_state_cmp(state, 2));
return state;
}
void encoder_update_user(uint8_t index, bool clockwise) {
if (index == 0) {
if (clockwise) {
tap_code(KC_VOLU);
} else {
tap_code(KC_VOLD);
}
}
}

View File

@ -0,0 +1,107 @@
/*
Copyright 2020 Alec Penland
Copyright 2020 Garret Gartner
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
// Layer names
enum ats_layers{
// - Base layer:
_BASE,
// - Symbols, numbers, and functions:
_FN,
// - Alternate Function layer:
_LN
};
#define RS_SLS RSFT_T(KC_SLSH)
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/* Default QWERTY layer
*
* Esc Q W E R T Y U I O P DelBkS PgU
*
* Tab A S D F G H J K L ' Enter PgD
*
* LShift Z X C V B N M , . Sft/ CAP
*
* LCtlOS LAlt Fn Space RAlt Ln
*
*
*/
[_BASE] = LAYOUT_split_space(
KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_BSPC, KC_PGUP,
KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOTE, KC_ENT, KC_PGDN,
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, RS_SLS, KC_UP, KC_CAPS,
KC_LCTL, KC_LGUI, KC_LALT, MO(_FN), KC_SPACE, KC_RALT, MO(_LN), KC_LEFT, KC_DOWN, KC_RIGHT
),
/* Main Numbers, Symbols & Function Layer (MOMENTARY)
*
* ! @ # $ % ^ & * [ ] \ Hme
*
* 1 2 3 4 5 6 7 8 9 0 End
*
* ( ) ; . - + * / =
*
*
*
*
*/
[_FN] = LAYOUT_split_space(
_______, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LBRC, KC_RBRC, KC_BSLS, _______, KC_HOME,
_______, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_ENTER, KC_END,
_______, KC_LPRN, KC_RPRN, KC_SCLN, KC_DOT, _______, KC_MINS, KC_PLUS, KC_ASTR, KC_SLSH, KC_EQL, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
/* ALTERNATE Function layer (MOMENTARY)
*
* PWRF1 F2 F3 F4 F5 F6 PRVNXT VL+
*
* SLP F7 F8 F9 F10F11F12 PLAY VL-
*
* WAKE
*
* RSET
*
*
*/
[_LN] = LAYOUT_split_space(
KC_PWR, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, _______, _______, _______, _______, KC_MPRV, KC_MNXT, KC_VOLU,
KC_SLEP, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, _______, _______, _______, KC_MPLY, KC_VOLD,
KC_WAKE, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______
)
};
//function for layer indicator LED
layer_state_t layer_state_set_user(layer_state_t state) {
writePin(D0, layer_state_cmp(state, 0));
writePin(D1, layer_state_cmp(state, 1));
writePin(D2, layer_state_cmp(state, 2));
return state;
}
void encoder_update_user(uint8_t index, bool clockwise) {
if (index == 0) {
if (clockwise) {
tap_code(KC_VOLU);
} else {
tap_code(KC_VOLD);
}
}
}

View File

@ -0,0 +1,3 @@
# 45-ATS VIA Firmware
This keymap is to enable the use of VIA on the 45-ATS Keyboard.

View File

@ -0,0 +1 @@
VIA_ENABLE = yes

View File

@ -0,0 +1,16 @@
# 45-ATS
![45ats](https://i.imgur.com/Paqx5zGl.png)
A Premium and Beautiful 45% (And-Then-Some) Keyboard. Concept and Design by [Abec13](https://www.reddit.com/user/abec13).
- Keyboard Designer: [Abec13](https://reddit.com/u/abec13/)
- Keyboard Maintainer: [The-Royal](https://github.com/the-royal)
- Hardware Supported: 45-ATS v1.0 PCB
- Hardware Availability: Through Group Buy - Dec. 2019
Make example for this keyboard (after setting up your build environment):
make 45_ats:default
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).

View File

@ -0,0 +1,22 @@
# MCU name
MCU = atmega32u4
# Bootloader selection
BOOTLOADER = atmel-dfu
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration
MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # Console for debug
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
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output

View File

@ -0,0 +1,17 @@
/*
Copyright 2020 Salicylic_Acid
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 "7splus.h"

View File

@ -0,0 +1,61 @@
/*
Copyright 2020 Salicylic_Acid
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "quantum.h"
/*
* ,-------------------------------------- ----------------------------------------------------------.
* | L00 | L01 | L02 | L03 | L04 | L05 | | R00 | R01 | R02 | R03 | R04 | R05 | R06 | R07 | R60 |
* |-------------------------------------- ------------------------------------------------------------+
* | L10 | L11 | L12 | L13 | L14 | L15 | | R10 | R11 | R12 | R13 | R14 | R15 | R16 | R17 | R62 |
* |---------------------------------------------------------------------------------------------------+
* | L20 | L21 | L22 | L23 | L24 | L25 | | R20 | R21 | R22 | R23 | R24 | R25 | R26 | R27 | R63 |
* |---------------------------------------- ---------------------------------------------------------+
* | L30 | L31 | L32 | L33 | L34 | L35 | | R30 | R31 | R32 | R33 | R34 | R35 | R36 | R37 |
* |---------------------------------------------------------------------------------------------------+
* | L40 | L41 | L42 | L43 | L44 | L45 | | R40 | R41 | R42 | R43 | R44 | R45 | R47 | R57 |
* |---------------------------------------------------------------------------------------------------+
* | L50 | L51 | L52 | L53 | L54 | L55 | | R50 | R51 | R53 | R54 | R55 | R56 | R64 |
* |---------------------------------------- ------------------------------------------------------'
*/
#define LAYOUT( \
L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, R06, R07, R60, \
L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, R16, R17, R62, \
L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, R26, R27, R63, \
L30, L31, L32, L33, L34, L35, R30, R31, R32, R33, R34, R35, R36, R37, \
L40, L41, L42, L43, L44, L45, R40, R41, R42, R43, R44, R45, R47, R57, \
L50, L51, L52, L54, L55, R50, R51, R53, R54, R55, R56, R64 \
) \
{ \
{ L00, L01, L02, L03, L04, L05, KC_NO, KC_NO }, \
{ L10, L11, L12, L13, L14, L15, KC_NO, KC_NO }, \
{ L20, L21, L22, L23, L24, L25, KC_NO, KC_NO }, \
{ L30, L31, L32, L33, L34, L35, KC_NO, KC_NO }, \
{ L40, L41, L42, L43, L44, L45, KC_NO, KC_NO }, \
{ L50, L51, L52, KC_NO, L54, L55, KC_NO, KC_NO }, \
{KC_NO,KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO }, \
{ R00, R01, R02, R03, R04, R05, R06, R07 }, \
{ R10, R11, R12, R13, R14, R15, R16, R17 }, \
{ R20, R21, R22, R23, R24, R25, R26, R27 }, \
{ R30, R31, R32, R33, R34, R35, R36, R37 }, \
{ R40, R41, R42, R43, R44, R45, KC_NO, R47 }, \
{ R50, R51, KC_NO, R53, R54, R55, R56, R57 }, \
{ R60, KC_NO, R62, R63, R64, KC_NO, KC_NO, KC_NO } \
}

View File

@ -0,0 +1,84 @@
/*
Copyright 2020 Salicylic_acid3
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include "config_common.h"
/* USB Device descriptor parameter */
#define VENDOR_ID 0x04D8
#define PRODUCT_ID 0xEAE7
#define DEVICE_VER 0x0001
#define MANUFACTURER Salicylic_Acid
#define PRODUCT 7splus
/* key matrix size */
#define MATRIX_ROWS 14
#define MATRIX_COLS 8
// wiring of each half
#define MATRIX_ROW_PINS { D1, D0, D4, C6, D7, E6, B4 }
#define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2, B5 }
#define DIODE_DIRECTION COL2ROW
/* Set 0 if debouncing isn't needed */
#define DEBOUNCE 5
/* serial.c configuration for split keyboard */
#define SOFT_SERIAL_PIN D2
#define SPLIT_HAND_PIN B6
/* 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
/* ws2812 RGB LED */
#define RGB_DI_PIN D3
#ifndef RGBLED_NUM
#define RGBLED_NUM 31
#define RGBLIGHT_SPLIT
#define RGBLED_SPLIT { 11, 20 }
#endif
#define RGBLIGHT_ANIMATIONS
#ifndef IOS_DEVICE_ENABLE
#define RGBLIGHT_LIMIT_VAL 180
#define RGBLIGHT_VAL_STEP 17
#else
#define RGBLIGHT_LIMIT_VAL 50
#define RGBLIGHT_VAL_STEP 4
#endif
#define RGBLIGHT_HUE_STEP 10
#define RGBLIGHT_SAT_STEP 17
#if defined(RGBLIGHT_ENABLE) && !defined(IOS_DEVICE_ENABLE)
// USB_MAX_POWER_CONSUMPTION value for naked48 keyboard
// 120 RGBoff, OLEDoff
// 120 OLED
// 330 RGB 6
// 300 RGB 32
// 310 OLED & RGB 32
#define USB_MAX_POWER_CONSUMPTION 400
#else
// fix iPhone and iPad power adapter issue
// iOS device need lessthan 100
#define USB_MAX_POWER_CONSUMPTION 100
#endif

View File

@ -0,0 +1,98 @@
{
"keyboard_name": "7splus",
"url": "https://salicylic-acid3.hatenablog.com/",
"maintainer": "Salicylic_acid3",
"width": 17,
"height": 6.25,
"layouts": {
"LAYOUT": {
"layout": [
{"label":"Esc", "x":0, "y":0},
{"label":"F1", "x":1.25, "y":0},
{"label":"F2", "x":2.25, "y":0},
{"label":"F3", "x":3.25, "y":0},
{"label":"F4", "x":4.25, "y":0},
{"label":"F5", "x":5.5, "y":0},
{"label":"F6", "x":7.5, "y":0},
{"label":"F7", "x":8.5, "y":0},
{"label":"F8", "x":9.5, "y":0},
{"label":"F9", "x":10.75, "y":0},
{"label":"F10", "x":11.75, "y":0},
{"label":"F11", "x":12.75, "y":0},
{"label":"F12", "x":13.75, "y":0},
{"label":"PrtScr", "x":15, "y":0},
{"label":"Delete", "x":16, "y":0},
{"label":"~", "x":0, "y":1.25},
{"label":"1", "x":1, "y":1.25},
{"label":"2", "x":2, "y":1.25},
{"label":"3", "x":3, "y":1.25},
{"label":"4", "x":4, "y":1.25},
{"label":"5", "x":5, "y":1.25},
{"label":"6", "x":7, "y":1.25},
{"label":"7", "x":8, "y":1.25},
{"label":"8", "x":9, "y":1.25},
{"label":"9", "x":10, "y":1.25},
{"label":"0", "x":11, "y":1.25},
{"label":"-", "x":12, "y":1.25},
{"label":"=", "x":13, "y":1.25},
{"label":"Back Space", "x":14, "y":1.25, "w":2},
{"label":"Home", "x":16, "y":1.25},
{"label":"Tab", "x":0, "y":2.25, "w":1.5},
{"label":"Q", "x":1.5, "y":2.25},
{"label":"W", "x":2.5, "y":2.25},
{"label":"E", "x":3.5, "y":2.25},
{"label":"R", "x":4.5, "y":2.25},
{"label":"T", "x":5.5, "y":2.25},
{"label":"Y", "x":7.5, "y":2.25},
{"label":"U", "x":8.5, "y":2.25},
{"label":"I", "x":9.5, "y":2.25},
{"label":"O", "x":10.5, "y":2.25},
{"label":"P", "x":11.5, "y":2.25},
{"label":"[", "x":12.5, "y":2.25},
{"label":"]", "x":13.5, "y":2.25},
{"label":"\"", "x":14.5, "y":2.25, "w":1.5},
{"label":"Page Up", "x":16, "y":2.25},
{"label":"Caps Lock", "x":0, "y":3.25, "w":1.75},
{"label":"A", "x":1.75, "y":3.25},
{"label":"S", "x":2.75, "y":3.25},
{"label":"D", "x":3.75, "y":3.25},
{"label":"F", "x":4.75, "y":3.25},
{"label":"G", "x":5.75, "y":3.25},
{"label":"H", "x":7.75, "y":3.25},
{"label":"J", "x":8.75, "y":3.25},
{"label":"K", "x":9.75, "y":3.25},
{"label":"L", "x":10.75, "y":3.25},
{"label":":", "x":11.75, "y":3.25},
{"label":"'", "x":12.75, "y":3.25},
{"label":"Enter", "x":13.75, "y":3.25, "w":2.25},
{"label":"Page Down", "x":16, "y":3.25},
{"label":"Shift", "x":0, "y":4.25, "w":2.25},
{"label":"Z", "x":2.25, "y":4.25},
{"label":"X", "x":3.25, "y":4.25},
{"label":"C", "x":4.25, "y":4.25},
{"label":"V", "x":5.25, "y":4.25},
{"label":"B", "x":6.25, "y":4.25},
{"label":"N", "x":8.25, "y":4.25},
{"label":"M", "x":9.25, "y":4.25},
{"label":"<", "x":10.25, "y":4.25},
{"label":">", "x":11.25, "y":4.25},
{"label":"?", "x":12.25, "y":4.25},
{"label":"Shift","x":13.25, "y":4.25, "w":1.75},
{"label":"Up", "x":15, "y":4.25},
{"label":"End", "x":16, "y":4.25},
{"label":"Ctrl", "x":0, "y":5.25, "w":1.25},
{"label":"Win", "x":1.25, "y":5.25, "w":1.25},
{"label":"Alt", "x":2.5, "y":5.25, "w":1.25},
{"x":3.75, "y":5.25, "w":2},
{"x":5.75, "y":5.25},
{"x":7.75, "y":5.25},
{"x":8.75, "y":5.25, "w":2.75},
{"label":"Alt", "x":11.5, "y":5.25, "w":1.25},
{"label":"App", "x":12.75, "y":5.25, "w":1.25},
{"label":"Left", "x":14, "y":5.25},
{"label":"Down", "x":15, "y":5.25},
{"label":"Right", "x":16, "y":5.25}
]
}
}
}

View File

@ -0,0 +1,81 @@
/*
Copyright 2020 Salicylic_Acid
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
// Each layer gets a name for readability, which is then used in the keymap matrix below.
// The underscores don't mean anything - you can have a layer called STUFF or any other name.
// Layer names don't all need to be of the same length, obviously, and you can also skip them
// entirely and just use numbers.
enum layer_number {
_QWERTY = 0,
_ADJUST,
};
enum custom_keycodes {
RGB_RST = SAFE_RANGE
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_DEL,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
LT(_ADJUST,KC_GRV),KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_HOME,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_PGUP,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_PGDN,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_LCTRL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_APP, KC_LEFT, KC_DOWN,KC_RIGHT
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[_ADJUST] = LAYOUT( /* Base */
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
MO(_ADJUST), XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_RST, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_TOG, RGB_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_VAD, RGB_VAI, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
)
};
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
#ifdef RGBLIGHT_ENABLE
case RGB_RST:
if (record->event.pressed) {
uint8_t mode = rgblight_get_mode();
eeconfig_update_rgblight_default();
rgblight_enable();
rgblight_mode(mode);
}
break;
#endif
}
return true;
}

View File

@ -0,0 +1,22 @@
/* Copyright 2020 Salicylic_acid3
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
/* Select hand configuration */
#define TAPPING_FORCE_HOLD
#define TAPPING_TERM 180

View File

@ -0,0 +1,147 @@
/*
Copyright 2020 Salicylic_Acid
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 "keymap_jp.h"
// Each layer gets a name for readability, which is then used in the keymap matrix below.
// The underscores don't mean anything - you can have a layer called STUFF or any other name.
// Layer names don't all need to be of the same length, obviously, and you can also skip them
// entirely and just use numbers.
enum layer_number {
_QWERTY = 0,
_MOUSE,
_LOWER,
_RAISE,
_ADJUST,
};
enum custom_keycodes {
RGB_RST = SAFE_RANGE
};
enum tapdances{
TD_ESMS = 0,
TD_ESAR,
};
qk_tap_dance_action_t tap_dance_actions[] = {
[TD_ESMS] = ACTION_TAP_DANCE_DUAL_ROLE(KC_ESC, _MOUSE),
[TD_ESAR] = ACTION_TAP_DANCE_DUAL_ROLE(KC_ESC, _QWERTY),
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
TD(TD_ESMS), KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_DEL,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_ZKHK, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, JP_MINS, JP_EQL, KC_BSPC, KC_HOME,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, JP_LBRC, JP_RBRC, JP_BSLS, KC_PGUP,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_LCTRL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, JP_MINS, JP_QUOT, KC_ENT, KC_PGDN,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_ZKHK, KC_LGUI,ALT_T(KC_MHEN),LT(_LOWER,KC_ENT),KC_BSPC, KC_DEL,LT(_RAISE,KC_SPC), ALT_T(KC_HENK), KC_APP, KC_LEFT, KC_DOWN,KC_RIGHT
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[_MOUSE] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
TD(TD_ESAR), _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, LCTL(KC_W),
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, LCTL(LSFT(KC_T)),
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_BTN1, KC_MS_U, KC_BTN2,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MS_L, KC_MS_D, KC_MS_R
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[_LOWER] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
KC_ESC, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
JP_QUOT, JP_EXLM, JP_QUES, JP_LBRC, JP_RBRC, JP_TILD, KC_P6, KC_P7, KC_P8, KC_P9, JP_ASTR, JP_SLSH, _______, _______, KC_HOME,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
LCTL_T(JP_QUOT),JP_HASH, JP_DQT, JP_LPRN, JP_RPRN, JP_AT, XXXXXXX, KC_P4, KC_P5, KC_P6, JP_MINS, JP_EQL, _______, KC_END,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
SFT_T(JP_CIRC),JP_PERC, JP_AMPR, JP_SCLN, JP_COLN, JP_PIPE, KC_P0, KC_P1, KC_P2, KC_P3, JP_PLUS, _______, KC_UP, KC_PGUP,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, MO(_LOWER), _______, _______,MO(_RAISE), _______, _______, KC_LEFT, KC_DOWN,KC_RIGHT
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[_RAISE] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_TAB, KC_1, KC_2, KC_3, KC_4, KC_5, XXXXXXX, XXXXXXX, KC_UP, XXXXXXX, KC_PGUP, XXXXXXX, _______, _______, KC_HOME,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
LCTL_T(KC_F11),XXXXXXX, KC_F2, KC_F3, KC_F4, KC_F5, XXXXXXX, KC_LEFT, KC_DOWN,KC_RIGHT, XXXXXXX, XXXXXXX, _______, KC_END,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
SFT_T(KC_F12), KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, KC_PGDN, _______, KC_UP, KC_PGUP,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, KC_LEFT, KC_DOWN,KC_RIGHT
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[_ADJUST] = LAYOUT( /* Base */
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_RST, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_TOG, RGB_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_VAD, RGB_VAI, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
_______, _______, _______, _______, _______, _______, _______, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
)
};
//A description for expressing the layer position in LED mode.
layer_state_t layer_state_set_user(layer_state_t state) {
return update_tri_layer_state(state, _RAISE, _LOWER, _ADJUST);
}
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
#ifdef RGBLIGHT_ENABLE
case RGB_RST:
if (record->event.pressed) {
uint8_t mode = rgblight_get_mode();
eeconfig_update_rgblight_default();
rgblight_enable();
rgblight_mode(mode);
}
break;
#endif
}
return true;
}

View File

@ -0,0 +1,2 @@
TAP_DANCE_ENABLE = yes
MOUSEKEY_ENABLE = yes

View File

@ -0,0 +1,23 @@
/* Copyright 2020 Salicylic_acid3
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
/* Select hand configuration */
#define TAPPING_FORCE_HOLD
#define TAPPING_TERM 180
#define DYNAMIC_KEYMAP_LAYER_COUNT 3

View File

@ -0,0 +1,71 @@
/*
Copyright 2020 Salicylic_Acid
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
// Each layer gets a name for readability, which is then used in the keymap matrix below.
// The underscores don't mean anything - you can have a layer called STUFF or any other name.
// Layer names don't all need to be of the same length, obviously, and you can also skip them
// entirely and just use numbers.
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_PSCR, KC_DEL,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
LT(1,KC_GRV), KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_HOME,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_PGUP,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_PGDN,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
KC_LCTRL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_APP, KC_LEFT, KC_DOWN,KC_RIGHT
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[1] = LAYOUT( /* Base */
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
MO(1), XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_TOG, RGB_MOD, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, RGB_VAD, RGB_VAI, RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
),
[2] = LAYOUT(
//,-----------------------------------------------------| |--------------------------------------------------------------------------------.
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
//|--------+--------+--------+--------+--------+--------| |--------+--------+--------+--------+--------+--------+--------+--------+--------|
XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
//`-----------------------------------------------------| |--------------------------------------------------------------------------------'
)
};

Some files were not shown because too many files have changed in this diff Show More