forked from mirrors/qmk_firmware
Compare commits
517 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dfcd4f0d25 | ||
|
|
b2271d984d | ||
|
|
8d3fca57a3 | ||
|
|
fced377ac0 | ||
|
|
7b8a013826 | ||
|
|
5263dfd465 | ||
|
|
13206b2f87 | ||
|
|
cb9be8a9dc | ||
|
|
a1af8542c7 | ||
|
|
1a5dc278bc | ||
|
|
10c1e1b3ab | ||
|
|
00c1401d3c | ||
|
|
a9b3c0a807 | ||
|
|
ac447d8acb | ||
|
|
a5e749d8cd | ||
|
|
4ee623fdd5 | ||
|
|
751316c344 | ||
|
|
5d3bf8a050 | ||
|
|
6501377070 | ||
|
|
af2ca13604 | ||
|
|
451c472d1d | ||
|
|
bfe76053ba | ||
|
|
9d41281a1d | ||
|
|
ba5e1f1bae | ||
|
|
e4823aadec | ||
|
|
5c9906eb4f | ||
|
|
f56d333db1 | ||
|
|
d8f76f9e6d | ||
|
|
6ca00c2152 | ||
|
|
dc6fe85b87 | ||
|
|
883dd2df80 | ||
|
|
2ac3a51d71 | ||
|
|
f66680d233 | ||
|
|
503cf18aed | ||
|
|
38d2c8cedf | ||
|
|
53224e03d6 | ||
|
|
7ef2ea3d49 | ||
|
|
9e4037465a | ||
|
|
fd4f102977 | ||
|
|
6d84795bc1 | ||
|
|
179e5c018f | ||
|
|
5246acb2e4 | ||
|
|
02a8c874f8 | ||
|
|
dae6f6b39b | ||
|
|
526c185e7e | ||
|
|
c63fd051da | ||
|
|
b95979560c | ||
|
|
65150984bd | ||
|
|
205321c377 | ||
|
|
1816ad01d0 | ||
|
|
9c8f61dfa0 | ||
|
|
d1df576ece | ||
|
|
83ebbf57b3 | ||
|
|
8e1f706ac6 | ||
|
|
b0c780ed32 | ||
|
|
3ad2be52a7 | ||
|
|
0fbcb41c85 | ||
|
|
ddca422776 | ||
|
|
82bb7d2852 | ||
|
|
1044519f36 | ||
|
|
209942366b | ||
|
|
494b34b63f | ||
|
|
58e3b01f37 | ||
|
|
6c2008c688 | ||
|
|
bcedc80ec7 | ||
|
|
ef5fad137b | ||
|
|
15dd05c402 | ||
|
|
32d03db371 | ||
|
|
c9d396dd47 | ||
|
|
2afb29e095 | ||
|
|
fcf150bd82 | ||
|
|
ee2eb01653 | ||
|
|
0bece1d442 | ||
|
|
be69dd22e8 | ||
|
|
b9675d2106 | ||
|
|
f689f043b1 | ||
|
|
54b04d9665 | ||
|
|
4604c70c4c | ||
|
|
010c5b12bd | ||
|
|
4adf4d5a89 | ||
|
|
d0e0202b27 | ||
|
|
fb9425df82 | ||
|
|
22ad35b225 | ||
|
|
f6cec668c7 | ||
|
|
2651edc243 | ||
|
|
2a43989d30 | ||
|
|
2f5521cd48 | ||
|
|
ac3d2a3810 | ||
|
|
1786490993 | ||
|
|
e55d55edc0 | ||
|
|
ad014c2539 | ||
|
|
81698df056 | ||
|
|
fca35a3540 | ||
|
|
5d01cc45be | ||
|
|
eaab0844e8 | ||
|
|
ce842f912e | ||
|
|
cceab93baa | ||
|
|
4161573b28 | ||
|
|
d0e684ef55 | ||
|
|
f125406700 | ||
|
|
afebb6576c | ||
|
|
7f6ba2bf8a | ||
|
|
142ebaea46 | ||
|
|
bbd17def21 | ||
|
|
d89e552419 | ||
|
|
9cf69a1997 | ||
|
|
c6cf1ae4e7 | ||
|
|
2c9ab8a606 | ||
|
|
0bf60acc4b | ||
|
|
6b54f3ce1c | ||
|
|
c3aaed8dfb | ||
|
|
ebc274209e | ||
|
|
1bdfac8afc | ||
|
|
9b716b7ada | ||
|
|
b591c0c24a | ||
|
|
6ba014a572 | ||
|
|
2dd47a3bf4 | ||
|
|
887c1c4e0e | ||
|
|
f66850bfd0 | ||
|
|
632285c982 | ||
|
|
805f5cb72b | ||
|
|
a8a8bf0ff3 | ||
|
|
fadd3cb461 | ||
|
|
a41f973f75 | ||
|
|
7abbc95cd6 | ||
|
|
30a6f231bf | ||
|
|
44ff14f290 | ||
|
|
741c7d5eec | ||
|
|
f3c30e80cc | ||
|
|
d846660e00 | ||
|
|
774384ce31 | ||
|
|
361ac2f32a | ||
|
|
d15a60d2d3 | ||
|
|
73992c68d5 | ||
|
|
8ca4ed9a98 | ||
|
|
640d12d070 | ||
|
|
3beda5c16e | ||
|
|
fb7fc54923 | ||
|
|
179c868059 | ||
|
|
7b11dcce10 | ||
|
|
e2fa05c6d2 | ||
|
|
4c4009c0fd | ||
|
|
e7860d673b | ||
|
|
2fe7e221ec | ||
|
|
e0f548085c | ||
|
|
94fc32f431 | ||
|
|
1f7bbf279c | ||
|
|
803610a284 | ||
|
|
cd0edbb1fb | ||
|
|
6919772fb9 | ||
|
|
fedd8e81d1 | ||
|
|
adda5d7770 | ||
|
|
d2581884d9 | ||
|
|
58fd782ce0 | ||
|
|
8e56d10e4e | ||
|
|
43868a5e20 | ||
|
|
db167ecf79 | ||
|
|
2b8b1045a1 | ||
|
|
7a6e52b5d8 | ||
|
|
ae5f7365ea | ||
|
|
606438692d | ||
|
|
5d29a13e22 | ||
|
|
81c648e947 | ||
|
|
923bad46f9 | ||
|
|
19513fac5f | ||
|
|
7bb9c76c80 | ||
|
|
57e67a4cc8 | ||
|
|
cf3913cd79 | ||
|
|
a30cc37c09 | ||
|
|
b18c261040 | ||
|
|
bac5d6bc6a | ||
|
|
ab1650606c | ||
|
|
dc00942be1 | ||
|
|
e8f842e798 | ||
|
|
3745ebc22b | ||
|
|
d646cba72a | ||
|
|
15e84f79f1 | ||
|
|
6f30b402a2 | ||
|
|
1ff526dac0 | ||
|
|
e17b55e33a | ||
|
|
f31bf1b202 | ||
|
|
5f82b0782f | ||
|
|
2e6959ed87 | ||
|
|
c482a2944b | ||
|
|
65c8ac9ac9 | ||
|
|
e182a38e7c | ||
|
|
fe4581c1a1 | ||
|
|
ddd055b1e2 | ||
|
|
f7324ec684 | ||
|
|
3d760caa85 | ||
|
|
750c7c2bdb | ||
|
|
4846c8eba0 | ||
|
|
3de4c3ea6a | ||
|
|
830bd5460c | ||
|
|
9f54a26dc0 | ||
|
|
16a15c1cfc | ||
|
|
37a4b53c4f | ||
|
|
a84d239661 | ||
|
|
41fd60d624 | ||
|
|
231464c49c | ||
|
|
d26a14c169 | ||
|
|
195be50745 | ||
|
|
8fdb229b66 | ||
|
|
fd3456f362 | ||
|
|
812d80efbd | ||
|
|
86c4c4e91d | ||
|
|
168ba88ada | ||
|
|
5f5c2a219c | ||
|
|
e415198235 | ||
|
|
b17482c3fd | ||
|
|
5b4870c046 | ||
|
|
374525c995 | ||
|
|
e02a3c559d | ||
|
|
e1217dae5a | ||
|
|
485a0b0bc3 | ||
|
|
23cfc4b145 | ||
|
|
bd639752db | ||
|
|
aaeef7a833 | ||
|
|
0d6614f71f | ||
|
|
d322ec5452 | ||
|
|
c7449b3840 | ||
|
|
4c51049b2b | ||
|
|
dd60fcda28 | ||
|
|
fd6b674b49 | ||
|
|
2c0deb8a13 | ||
|
|
a904371b29 | ||
|
|
cfdd105d9d | ||
|
|
82ae6ee007 | ||
|
|
f220e7d713 | ||
|
|
3cb6fb2935 | ||
|
|
5c666398d5 | ||
|
|
a47915d2d2 | ||
|
|
6ec3cc029e | ||
|
|
4597f2bcc8 | ||
|
|
52af38da37 | ||
|
|
b2dbc3f515 | ||
|
|
86b62eadc2 | ||
|
|
3337eb10b2 | ||
|
|
32bab55def | ||
|
|
47fc2f8855 | ||
|
|
ee29b515ec | ||
|
|
c031e13982 | ||
|
|
84bf82f2c9 | ||
|
|
af26238385 | ||
|
|
28e5969f78 | ||
|
|
59246756e5 | ||
|
|
423ce39f18 | ||
|
|
217debff07 | ||
|
|
52e9719d09 | ||
|
|
9df367e227 | ||
|
|
8650b9f10c | ||
|
|
5c9c45619e | ||
|
|
09caf19389 | ||
|
|
4baf49191f | ||
|
|
427da3c19c | ||
|
|
1df8bb3cdb | ||
|
|
99eacdc47a | ||
|
|
5e235d30c7 | ||
|
|
6586280bf3 | ||
|
|
0722986d7a | ||
|
|
22a10cc8a3 | ||
|
|
b349fa0a57 | ||
|
|
e98a9578a1 | ||
|
|
d2b03bf150 | ||
|
|
35ca1c2212 | ||
|
|
ccc8338b0e | ||
|
|
bafa35ff46 | ||
|
|
182286680a | ||
|
|
c1c579c554 | ||
|
|
19bd8aa942 | ||
|
|
d0d105b083 | ||
|
|
c0a57c2a50 | ||
|
|
738c6612ca | ||
|
|
643fc1d806 | ||
|
|
f78896589e | ||
|
|
837ffd0006 | ||
|
|
92a50a386a | ||
|
|
357c6009be | ||
|
|
e916ce5f3e | ||
|
|
086a7cf800 | ||
|
|
99f7fe6bd4 | ||
|
|
d0c3a4c8d5 | ||
|
|
2dca087b04 | ||
|
|
b80340c207 | ||
|
|
cb4a86475e | ||
|
|
7e4cf9ace2 | ||
|
|
0d658e0c95 | ||
|
|
1522d97c2b | ||
|
|
2d39a9dcdb | ||
|
|
33bf4863f5 | ||
|
|
ad547c1fdd | ||
|
|
9b70e53508 | ||
|
|
33a5dc4fcf | ||
|
|
e0fffcde99 | ||
|
|
06bffbd45b | ||
|
|
c261076f8e | ||
|
|
51ecd37d7b | ||
|
|
ed5e69093c | ||
|
|
43785126a7 | ||
|
|
8c97b4a3a4 | ||
|
|
0698b15aa5 | ||
|
|
d600631ad1 | ||
|
|
f3595f65b7 | ||
|
|
23df763a31 | ||
|
|
ed910c8e97 | ||
|
|
7e1c0bd4c0 | ||
|
|
d2b8398f75 | ||
|
|
195324cc4c | ||
|
|
cd5399942b | ||
|
|
fd4bbd8d11 | ||
|
|
f43cb31476 | ||
|
|
89eb3a9e42 | ||
|
|
66d94dc22a | ||
|
|
5a8f59503e | ||
|
|
7918f7d61d | ||
|
|
a6bd8fe67b | ||
|
|
55b43f02f0 | ||
|
|
db4b11f866 | ||
|
|
46a84ec84a | ||
|
|
3b5998085c | ||
|
|
7a9980fd85 | ||
|
|
bc13dcd349 | ||
|
|
55002338b1 | ||
|
|
99d9250045 | ||
|
|
4a92dd327c | ||
|
|
7873b49d40 | ||
|
|
fcf2b45263 | ||
|
|
5607af8524 | ||
|
|
5a45627e17 | ||
|
|
17d0f6338e | ||
|
|
484c059d86 | ||
|
|
3cc68543ca | ||
|
|
daf6dedb02 | ||
|
|
7a0d145e27 | ||
|
|
e990863296 | ||
|
|
d06340f665 | ||
|
|
4c0065dda7 | ||
|
|
2ae39ccf38 | ||
|
|
5185c52b4a | ||
|
|
c0b99badcb | ||
|
|
f9bb9ef0b8 | ||
|
|
3d9ffd3efb | ||
|
|
3cea9fedff | ||
|
|
575d99816e | ||
|
|
4bccde37d4 | ||
|
|
f6b40da7f8 | ||
|
|
6fb048fdaf | ||
|
|
06b571aa53 | ||
|
|
355b693e4e | ||
|
|
f514ad5503 | ||
|
|
09a1917103 | ||
|
|
46e4493761 | ||
|
|
157d121c71 | ||
|
|
7e6b550ebf | ||
|
|
7f4ce4a8b7 | ||
|
|
6452973761 | ||
|
|
a2309b306a | ||
|
|
52ac6c4303 | ||
|
|
05e9ff6554 | ||
|
|
17bda000f3 | ||
|
|
46a69d1f3b | ||
|
|
b56a41800a | ||
|
|
d3c29c9b3c | ||
|
|
370577e4ed | ||
|
|
6e84247ec2 | ||
|
|
5380c29dd7 | ||
|
|
23f19852b9 | ||
|
|
8a5c1e1859 | ||
|
|
6265b78307 | ||
|
|
23124b9fd1 | ||
|
|
eb7fc7f9d9 | ||
|
|
c2df714c3b | ||
|
|
799b21f8cd | ||
|
|
750179e111 | ||
|
|
f538b2273a | ||
|
|
50e85f91e8 | ||
|
|
27e7f322a5 | ||
|
|
dfdc89296b | ||
|
|
671020af08 | ||
|
|
b8c3f4c60b | ||
|
|
511fe643c2 | ||
|
|
f7601dba13 | ||
|
|
89cab95b63 | ||
|
|
cc38627816 | ||
|
|
6c2c3c13e9 | ||
|
|
e4cc642a79 | ||
|
|
c3c3943432 | ||
|
|
061ed87b89 | ||
|
|
5c1aca0b88 | ||
|
|
6384a2abd8 | ||
|
|
439afc883a | ||
|
|
07c75feba3 | ||
|
|
b5aa5e4338 | ||
|
|
be8443b35b | ||
|
|
4b10235f67 | ||
|
|
6ef13f83e2 | ||
|
|
be2f5816b6 | ||
|
|
ff213d5fe1 | ||
|
|
3234118e52 | ||
|
|
a1ffc40b36 | ||
|
|
8fe5c718b4 | ||
|
|
38f14c4174 | ||
|
|
eb683c8c52 | ||
|
|
21799be1ca | ||
|
|
5cfc3ce02e | ||
|
|
724f20ed32 | ||
|
|
c61f016fa4 | ||
|
|
ea7e40bae1 | ||
|
|
974f83ec4b | ||
|
|
400ca2d035 | ||
|
|
e409fb47f2 | ||
|
|
0499f30f59 | ||
|
|
ae74922d14 | ||
|
|
3349a8b49b | ||
|
|
b4ef72423e | ||
|
|
f4b67cde8a | ||
|
|
0a643be39e | ||
|
|
6c8e205fc0 | ||
|
|
7901006753 | ||
|
|
9bfa713421 | ||
|
|
b6fc3ad8e7 | ||
|
|
e0909a31c7 | ||
|
|
d6bffdf577 | ||
|
|
d1190df10b | ||
|
|
bf38f39c3f | ||
|
|
6add103827 | ||
|
|
62d1d69ba9 | ||
|
|
7642075fc3 | ||
|
|
ca91dc594b | ||
|
|
26cb83b8c0 | ||
|
|
2392ddb76b | ||
|
|
6de77141a4 | ||
|
|
6f6c2e1c5c | ||
|
|
48cad94d7e | ||
|
|
90665aeec9 | ||
|
|
845953cc67 | ||
|
|
c3c2eb71e1 | ||
|
|
28a6a4a15b | ||
|
|
ccb37f673a | ||
|
|
c5efbc45a1 | ||
|
|
6a0d3c3517 | ||
|
|
2fbbac04bb | ||
|
|
04c81a04c7 | ||
|
|
120fcc58b6 | ||
|
|
2f15cb2126 | ||
|
|
8af156d976 | ||
|
|
70b5015162 | ||
|
|
3fad3854d6 | ||
|
|
38d7145da2 | ||
|
|
6e8876be39 | ||
|
|
0bb2924670 | ||
|
|
2f623daa45 | ||
|
|
ebbaba9001 | ||
|
|
5f35b07102 | ||
|
|
59188bf29d | ||
|
|
9c4bf0ac4a | ||
|
|
f2901375ce | ||
|
|
f65e79477f | ||
|
|
3094422b33 | ||
|
|
31fd0cbc1c | ||
|
|
2b427f774a | ||
|
|
85444176b2 | ||
|
|
52b48997eb | ||
|
|
808aab8496 | ||
|
|
0742f9fc96 | ||
|
|
58a9c84d6b | ||
|
|
c217186bea | ||
|
|
781308507d | ||
|
|
2eb6cb0dfd | ||
|
|
95c5c11d0b | ||
|
|
b6a09502c6 | ||
|
|
1962135418 | ||
|
|
d79be051dd | ||
|
|
3fe8d604a4 | ||
|
|
194bc7a7e1 | ||
|
|
fec4283022 | ||
|
|
17af712b7c | ||
|
|
712ded1f2f | ||
|
|
c67e304593 | ||
|
|
8c80475fcc | ||
|
|
3e18bb914c | ||
|
|
4434649c2f | ||
|
|
c6c94eeabc | ||
|
|
2c201ab9ad | ||
|
|
e5b10079cf | ||
|
|
854d46f833 | ||
|
|
bdfdc506da | ||
|
|
51a81813b0 | ||
|
|
8566a684bc | ||
|
|
28d3c29704 | ||
|
|
dd5cb64851 | ||
|
|
b9a64ec93b | ||
|
|
c9067dfe4f | ||
|
|
1592d7df24 | ||
|
|
9acd5e04d5 | ||
|
|
0afcb8a36c | ||
|
|
89a675d57c | ||
|
|
b892a1429d | ||
|
|
e90d66f93e | ||
|
|
bfef2c7b05 | ||
|
|
74c01654c7 | ||
|
|
dc98d44582 | ||
|
|
defa1a1dc7 | ||
|
|
c89c084146 | ||
|
|
13fff52f6b | ||
|
|
7bf9d9dc0a | ||
|
|
14079ce698 | ||
|
|
05d9a0ff03 | ||
|
|
b9d0b1f064 | ||
|
|
ed80874f72 | ||
|
|
23e942ae4e | ||
|
|
c077300e19 | ||
|
|
11f12d386b | ||
|
|
4d76d85d7b | ||
|
|
981ea87b05 | ||
|
|
65252ebf67 | ||
|
|
5bd0a5a585 |
@@ -1,24 +0,0 @@
|
|||||||
|
|
||||||
-I.
|
|
||||||
-I./drivers
|
|
||||||
-I./drivers/avr
|
|
||||||
-I./keyboards/ergodox_ez
|
|
||||||
-I./keyboards/ergodox_ez/keymaps/vim
|
|
||||||
-I./lib
|
|
||||||
-I./lib/lufa
|
|
||||||
-I./quantum
|
|
||||||
-I./quantum/api
|
|
||||||
-I./quantum/audio
|
|
||||||
-I./quantum/keymap_extras
|
|
||||||
-I./quantum/process_keycode
|
|
||||||
-I./quantum/serial_link
|
|
||||||
-I./quantum/template
|
|
||||||
-I./quantum/tools
|
|
||||||
-I./quantum/visualizer
|
|
||||||
-I./tmk_core
|
|
||||||
-I./tmk_core/common
|
|
||||||
-I./tmk_core/common/debug.h
|
|
||||||
-I./tmk_core/protocol
|
|
||||||
-I./tmk_core/protocol/lufa
|
|
||||||
-I./util
|
|
||||||
-DQMK_KEYBOARD=\"$(KEYBOARD)\" -DQMK_KEYMAP=\"$(KEYMAP)\"
|
|
||||||
2
.github/workflows/cli.yml
vendored
2
.github/workflows/cli.yml
vendored
@@ -19,7 +19,7 @@ jobs:
|
|||||||
container: qmkfm/base_container
|
container: qmkfm/base_container
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
|
|||||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -24,6 +24,7 @@ quantum/version.h
|
|||||||
.idea/
|
.idea/
|
||||||
CMakeLists.txt
|
CMakeLists.txt
|
||||||
cmake-build-debug
|
cmake-build-debug
|
||||||
|
.clang_complete
|
||||||
doxygen/
|
doxygen/
|
||||||
.DS_Store
|
.DS_Store
|
||||||
/util/wsl_downloaded
|
/util/wsl_downloaded
|
||||||
@@ -47,7 +48,6 @@ doxygen/
|
|||||||
*.iml
|
*.iml
|
||||||
.browse.VC.db*
|
.browse.VC.db*
|
||||||
*.stackdump
|
*.stackdump
|
||||||
util/Win_Check_Output.txt
|
|
||||||
# Let these ones be user specific, since we have so many different configurations
|
# Let these ones be user specific, since we have so many different configurations
|
||||||
.vscode/c_cpp_properties.json
|
.vscode/c_cpp_properties.json
|
||||||
.vscode/launch.json
|
.vscode/launch.json
|
||||||
|
|||||||
8
.gitmodules
vendored
8
.gitmodules
vendored
@@ -12,7 +12,13 @@
|
|||||||
branch = master
|
branch = master
|
||||||
[submodule "lib/googletest"]
|
[submodule "lib/googletest"]
|
||||||
path = lib/googletest
|
path = lib/googletest
|
||||||
url = https://github.com/google/googletest
|
url = https://github.com/qmk/googletest
|
||||||
[submodule "lib/lufa"]
|
[submodule "lib/lufa"]
|
||||||
path = lib/lufa
|
path = lib/lufa
|
||||||
url = https://github.com/qmk/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
|
||||||
|
|||||||
20
.vscode/settings.json
vendored
20
.vscode/settings.json
vendored
@@ -9,13 +9,17 @@
|
|||||||
"**/*.bin": true
|
"**/*.bin": true
|
||||||
},
|
},
|
||||||
"files.associations": {
|
"files.associations": {
|
||||||
"*.h": "c",
|
"*.h": "c",
|
||||||
"*.c": "c",
|
"*.c": "c",
|
||||||
"*.inc": "c",
|
"*.inc": "c",
|
||||||
"*.cpp": "cpp",
|
"*.cpp": "cpp",
|
||||||
"*.hpp": "cpp",
|
"*.hpp": "cpp",
|
||||||
"xstddef": "c",
|
"xstddef": "c",
|
||||||
"type_traits": "c",
|
"type_traits": "c",
|
||||||
"utility": "c"
|
"utility": "c"
|
||||||
|
},
|
||||||
|
"[markdown]": {
|
||||||
|
"editor.trimAutoWhitespace": false,
|
||||||
|
"files.trimTrailingWhitespace": false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
13
Makefile
13
Makefile
@@ -29,6 +29,9 @@ $(info QMK Firmware $(QMK_VERSION))
|
|||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# avoid 'Entering|Leaving directory' messages
|
||||||
|
MAKEFLAGS += --no-print-directory
|
||||||
|
|
||||||
ON_ERROR := error_occurred=1
|
ON_ERROR := error_occurred=1
|
||||||
|
|
||||||
BREAK_ON_ERRORS = no
|
BREAK_ON_ERRORS = no
|
||||||
@@ -291,8 +294,8 @@ define PARSE_RULE
|
|||||||
$$(info | QMK's make format recently changed to use folder locations and colons:)
|
$$(info | QMK's make format recently changed to use folder locations and colons:)
|
||||||
$$(info | make project_folder:keymap[:target])
|
$$(info | make project_folder:keymap[:target])
|
||||||
$$(info | Examples:)
|
$$(info | Examples:)
|
||||||
$$(info | make planck/rev4:default:dfu)
|
$$(info | make dz60:default)
|
||||||
$$(info | make planck:default)
|
$$(info | make planck/rev6:default:flash)
|
||||||
$$(info |)
|
$$(info |)
|
||||||
endif
|
endif
|
||||||
endef
|
endef
|
||||||
@@ -559,14 +562,16 @@ endef
|
|||||||
%:
|
%:
|
||||||
# Check if we have the CMP tool installed
|
# Check if we have the CMP tool installed
|
||||||
cmp $(ROOT_DIR)/Makefile $(ROOT_DIR)/Makefile >/dev/null 2>&1; if [ $$? -gt 0 ]; then printf "$(MSG_NO_CMP)"; exit 1; fi;
|
cmp $(ROOT_DIR)/Makefile $(ROOT_DIR)/Makefile >/dev/null 2>&1; if [ $$? -gt 0 ]; then printf "$(MSG_NO_CMP)"; exit 1; fi;
|
||||||
# Ensure that python3 is installed. This check can be removed after python is used in more places.
|
# Ensure that bin/qmk works. This will be a failing check after the next develop merge on 2020 Aug 29.
|
||||||
if ! python3 --version 1> /dev/null 2>&1; then printf "$(MSG_PYTHON_MISSING)"; fi
|
if ! bin/qmk hello 1> /dev/null 2>&1; then printf "$(MSG_PYTHON_MISSING)"; fi
|
||||||
# Check if the submodules are dirty, and display a warning if they are
|
# Check if the submodules are dirty, and display a warning if they are
|
||||||
ifndef SKIP_GIT
|
ifndef SKIP_GIT
|
||||||
if [ ! -e lib/chibios ]; then git submodule sync lib/chibios && git submodule update --depth 50 --init lib/chibios; fi
|
if [ ! -e lib/chibios ]; then git submodule sync lib/chibios && git submodule update --depth 50 --init lib/chibios; fi
|
||||||
if [ ! -e lib/chibios-contrib ]; then git submodule sync lib/chibios-contrib && git submodule update --depth 50 --init lib/chibios-contrib; fi
|
if [ ! -e lib/chibios-contrib ]; then git submodule sync lib/chibios-contrib && git submodule update --depth 50 --init lib/chibios-contrib; fi
|
||||||
if [ ! -e lib/ugfx ]; then git submodule sync lib/ugfx && git submodule update --depth 50 --init lib/ugfx; fi
|
if [ ! -e lib/ugfx ]; then git submodule sync lib/ugfx && git submodule update --depth 50 --init lib/ugfx; fi
|
||||||
if [ ! -e lib/lufa ]; then git submodule sync lib/lufa && git submodule update --depth 50 --init lib/lufa; fi
|
if [ ! -e lib/lufa ]; then git submodule sync lib/lufa && git submodule update --depth 50 --init lib/lufa; fi
|
||||||
|
if [ ! -e lib/vusb ]; then git submodule sync lib/vusb && git submodule update --depth 50 --init lib/vusb; fi
|
||||||
|
if [ ! -e lib/printf ]; then git submodule sync lib/printf && git submodule update --depth 50 --init lib/printf; fi
|
||||||
git submodule status --recursive 2>/dev/null | \
|
git submodule status --recursive 2>/dev/null | \
|
||||||
while IFS= read -r x; do \
|
while IFS= read -r x; do \
|
||||||
case "$$x" in \
|
case "$$x" in \
|
||||||
|
|||||||
2
Vagrantfile
vendored
2
Vagrantfile
vendored
@@ -89,7 +89,7 @@ Vagrant.configure(2) do |config|
|
|||||||
|
|
||||||
Examples:
|
Examples:
|
||||||
make planck/rev4:default:dfu
|
make planck/rev4:default:dfu
|
||||||
make planck:default
|
make planck/rev4:default
|
||||||
|
|
||||||
EOT
|
EOT
|
||||||
end
|
end
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
67
bin/qmk
67
bin/qmk
@@ -2,52 +2,61 @@
|
|||||||
"""CLI wrapper for running QMK commands.
|
"""CLI wrapper for running QMK commands.
|
||||||
"""
|
"""
|
||||||
import os
|
import os
|
||||||
import subprocess
|
|
||||||
import sys
|
import sys
|
||||||
from importlib.util import find_spec
|
from importlib.util import find_spec
|
||||||
from time import strftime
|
from pathlib import Path
|
||||||
|
|
||||||
# Add the QMK python libs to our path
|
# Add the QMK python libs to our path
|
||||||
script_dir = os.path.dirname(os.path.realpath(__file__))
|
script_dir = Path(os.path.realpath(__file__)).parent
|
||||||
qmk_dir = os.path.abspath(os.path.join(script_dir, '..'))
|
qmk_dir = script_dir.parent
|
||||||
python_lib_dir = os.path.abspath(os.path.join(qmk_dir, 'lib', 'python'))
|
python_lib_dir = Path(qmk_dir / 'lib' / 'python').resolve()
|
||||||
sys.path.append(python_lib_dir)
|
sys.path.append(str(python_lib_dir))
|
||||||
|
|
||||||
# Make sure our modules have been setup
|
|
||||||
with open(os.path.join(qmk_dir, 'requirements.txt'), 'r') as fd:
|
|
||||||
for line in fd.readlines():
|
|
||||||
line = line.strip().replace('<', '=').replace('>', '=')
|
|
||||||
|
|
||||||
if line[0] == '#':
|
def _check_modules(requirements):
|
||||||
continue
|
""" Check if the modules in the given requirements.txt are available.
|
||||||
|
"""
|
||||||
|
with Path(qmk_dir / requirements).open() as fd:
|
||||||
|
for line in fd.readlines():
|
||||||
|
line = line.strip().replace('<', '=').replace('>', '=')
|
||||||
|
|
||||||
if '#' in line:
|
if len(line) == 0 or line[0] == '#' or line.startswith('-r'):
|
||||||
line = line.split('#')[0]
|
continue
|
||||||
|
|
||||||
module = line.split('=')[0] if '=' in line else line
|
if '#' in line:
|
||||||
|
line = line.split('#')[0]
|
||||||
|
|
||||||
|
module = dict()
|
||||||
|
module['name'] = module['import'] = line.split('=')[0] if '=' in line else line
|
||||||
|
|
||||||
if module in ['pep8-naming']:
|
|
||||||
# Not every module is importable by its own name.
|
# Not every module is importable by its own name.
|
||||||
continue
|
if module['name'] == "pep8-naming":
|
||||||
|
module['import'] = "pep8ext_naming"
|
||||||
|
|
||||||
if not find_spec(module):
|
if not find_spec(module['import']):
|
||||||
print('Could not find module %s!' % module)
|
print('Could not find module %s!' % module['name'])
|
||||||
print('Please run `pip3 install -r requirements.txt` to install the python dependencies.')
|
print('Please run `python3 -m pip install -r %s` to install required python dependencies.' % (qmk_dir / requirements,))
|
||||||
exit(255)
|
if developer:
|
||||||
|
print('You can also turn off developer mode: qmk config user.developer=None')
|
||||||
|
print()
|
||||||
|
exit(255)
|
||||||
|
|
||||||
# Figure out our version
|
|
||||||
# TODO(skullydazed/anyone): Find a method that doesn't involve git. This is slow in docker and on windows.
|
|
||||||
command = ['git', 'describe', '--abbrev=6', '--dirty', '--always', '--tags']
|
|
||||||
result = subprocess.run(command, universal_newlines=True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
|
|
||||||
|
|
||||||
if result.returncode == 0:
|
developer = False
|
||||||
os.environ['QMK_VERSION'] = result.stdout.strip()
|
# Make sure our modules have been setup
|
||||||
else:
|
_check_modules('requirements.txt')
|
||||||
os.environ['QMK_VERSION'] = 'nogit-' + strftime('%Y-%m-%d-%H:%M:%S') + '-dirty'
|
|
||||||
|
|
||||||
# Setup the CLI
|
# Setup the CLI
|
||||||
import milc # noqa
|
import milc # noqa
|
||||||
|
|
||||||
|
# For developers additional modules are needed
|
||||||
|
if milc.cli.config.user.developer:
|
||||||
|
# Do not run the check for 'config',
|
||||||
|
# so users can turn off developer mode
|
||||||
|
if len(sys.argv) == 1 or (len(sys.argv) > 1 and 'config' != sys.argv[1]):
|
||||||
|
developer = True
|
||||||
|
_check_modules('requirements-dev.txt')
|
||||||
|
|
||||||
milc.EMOJI_LOGLEVELS['INFO'] = '{fg_blue}Ψ{style_reset_all}'
|
milc.EMOJI_LOGLEVELS['INFO'] = '{fg_blue}Ψ{style_reset_all}'
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -21,6 +21,11 @@ else ifneq ("$(wildcard $(MAIN_KEYMAP_PATH_1)/keymap.json)","")
|
|||||||
KEYMAP_PATH := $(MAIN_KEYMAP_PATH_1)
|
KEYMAP_PATH := $(MAIN_KEYMAP_PATH_1)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# Load the keymap-level rules.mk if exists
|
||||||
|
ifneq ("$(wildcard $(KEYMAP_PATH))", "")
|
||||||
|
-include $(KEYMAP_PATH)/rules.mk
|
||||||
|
endif
|
||||||
|
|
||||||
# Generate the keymap.c
|
# Generate the keymap.c
|
||||||
$(KEYBOARD_OUTPUT)/src/keymap.c: $(KEYMAP_JSON)
|
$(KEYBOARD_OUTPUT)/src/keymap.c: $(KEYMAP_JSON)
|
||||||
bin/qmk json2c --quiet --output $(KEYMAP_C) $(KEYMAP_JSON)
|
bin/qmk json2c --quiet --output $(KEYMAP_C) $(KEYMAP_JSON)
|
||||||
|
|||||||
@@ -70,7 +70,7 @@ ifeq ($(strip $(POINTING_DEVICE_ENABLE)), yes)
|
|||||||
SRC += $(QUANTUM_DIR)/pointing_device.c
|
SRC += $(QUANTUM_DIR)/pointing_device.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
VALID_EEPROM_DRIVER_TYPES := vendor custom transient i2c
|
VALID_EEPROM_DRIVER_TYPES := vendor custom transient i2c spi
|
||||||
EEPROM_DRIVER ?= vendor
|
EEPROM_DRIVER ?= vendor
|
||||||
ifeq ($(filter $(EEPROM_DRIVER),$(VALID_EEPROM_DRIVER_TYPES)),)
|
ifeq ($(filter $(EEPROM_DRIVER),$(VALID_EEPROM_DRIVER_TYPES)),)
|
||||||
$(error EEPROM_DRIVER="$(EEPROM_DRIVER)" is not a valid EEPROM driver)
|
$(error EEPROM_DRIVER="$(EEPROM_DRIVER)" is not a valid EEPROM driver)
|
||||||
@@ -85,6 +85,11 @@ else
|
|||||||
COMMON_VPATH += $(DRIVER_PATH)/eeprom
|
COMMON_VPATH += $(DRIVER_PATH)/eeprom
|
||||||
QUANTUM_LIB_SRC += i2c_master.c
|
QUANTUM_LIB_SRC += i2c_master.c
|
||||||
SRC += eeprom_driver.c eeprom_i2c.c
|
SRC += eeprom_driver.c eeprom_i2c.c
|
||||||
|
else ifeq ($(strip $(EEPROM_DRIVER)), spi)
|
||||||
|
OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_SPI
|
||||||
|
COMMON_VPATH += $(DRIVER_PATH)/eeprom
|
||||||
|
QUANTUM_LIB_SRC += spi_master.c
|
||||||
|
SRC += eeprom_driver.c eeprom_spi.c
|
||||||
else ifeq ($(strip $(EEPROM_DRIVER)), transient)
|
else ifeq ($(strip $(EEPROM_DRIVER)), transient)
|
||||||
OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_TRANSIENT
|
OPT_DEFS += -DEEPROM_DRIVER -DEEPROM_TRANSIENT
|
||||||
COMMON_VPATH += $(DRIVER_PATH)/eeprom
|
COMMON_VPATH += $(DRIVER_PATH)/eeprom
|
||||||
|
|||||||
239
docs/ChangeLog/20200530.md
Normal file
239
docs/ChangeLog/20200530.md
Normal file
@@ -0,0 +1,239 @@
|
|||||||
|
# QMK Breaking Change - 2020 May 30 Changelog
|
||||||
|
|
||||||
|
Four times a year QMK runs a process for merging Breaking Changes. A Breaking Change is any change which modifies how QMK behaves in a way that is incompatible or potentially dangerous. We limit these changes to 4 times per year so that users can have confidence that updating their QMK tree will not break their keymaps.
|
||||||
|
|
||||||
|
The list of changes follows.
|
||||||
|
|
||||||
|
|
||||||
|
## Core Changes
|
||||||
|
|
||||||
|
### Converting V-USB usbdrv to a submodule
|
||||||
|
|
||||||
|
[#8321](https://github.com/qmk/qmk_firmware/pull/8321) and [qmk_compiler#62](https://github.com/qmk/qmk_compiler/pull/62).
|
||||||
|
|
||||||
|
These PRs move the V-USB driver code out of the qmk_firmware repository and into a submodule pointed at https://github.com/obdev/v-usb. This will make it easier to update the codebase if needed, while applying any potential QMK-specific modifications by forking it to the QMK GitHub organization.
|
||||||
|
|
||||||
|
### Unify Tap Hold functions and documentation
|
||||||
|
|
||||||
|
[#8348](https://github.com/qmk/qmk_firmware/pull/8348)
|
||||||
|
|
||||||
|
Updates all of the per key tap-hold functions to pass the `keyrecord_t` structure, and include documentation changes.
|
||||||
|
|
||||||
|
Any remaining versions or code outside of the main repo will need to be converted:
|
||||||
|
| Old function | New Function |
|
||||||
|
|------------------------------------------------------|---------------------------------------------------------------------------|
|
||||||
|
|`uint16_t get_tapping_term(uint16_t keycode)` |`uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record)` |
|
||||||
|
|`bool get_ignore_mod_tap_interrupt(uint16_t keycode)` |`bool get_ignore_mod_tap_interrupt(uint16_t keycode, keyrecord_t *record)` |
|
||||||
|
|
||||||
|
### Python Required In The Build Process
|
||||||
|
|
||||||
|
[#9000](https://github.com/qmk/qmk_firmware/pull/9000)
|
||||||
|
|
||||||
|
This is the last release of QMK that will work without having Python 3.6 (or later) installed. If your environment is not fully setup you will get a warning instructing you to set it up.
|
||||||
|
|
||||||
|
After the next breaking change you will not be able to build if `bin/qmk hello` does not work.
|
||||||
|
|
||||||
|
### Upgrade from tinyprintf to mpaland/printf
|
||||||
|
|
||||||
|
[#8269](https://github.com/qmk/qmk_firmware/pull/8269)
|
||||||
|
|
||||||
|
- Provides debug functionality on ChibiOS/ARM that is more compliant than previous integrations.
|
||||||
|
- Less maintenence, fewer QMK customisations, and allows QMK to sidestep previous compile and runtime issues.
|
||||||
|
- A `make git-submodule` may be required after pulling the latest QMK Firmware code to update to the new dependency.
|
||||||
|
|
||||||
|
### Fixed RGB_DISABLE_AFTER_TIMEOUT to be seconds based & small internals cleanup
|
||||||
|
|
||||||
|
[#6480](https://github.com/qmk/qmk_firmware/pull/6480)
|
||||||
|
|
||||||
|
- Changes `RGB_DISABLE_AFTER_TIMEOUT` to be based on milliseconds instead of ticks.
|
||||||
|
- Includes a code cleanup, resulting in a savings of 100 bytes, depending on features used.
|
||||||
|
- Fixed issues with timeouts / suspending at the wrong time not turning off all LEDs in some cases.
|
||||||
|
|
||||||
|
The `RGB_DISABLE_AFTER_TIMEOUT` definition is now deprecated, and has been superseded by `RGB_DISABLE_TIMEOUT`. To use the new definition, rename `RGB_DISABLE_AFTER_TIMEOUT` to `RGB_DISABLE_TIMEOUT` in your `config.h` file, and multiply the value set by 1200.
|
||||||
|
|
||||||
|
Before: `#define RGB_DISABLE_AFTER_TIMEOUT 100`
|
||||||
|
After: `#define RGB_DISABLE_TIMEOUT 120000`
|
||||||
|
|
||||||
|
### Switch to qmk forks for everything
|
||||||
|
|
||||||
|
[#9019](https://github.com/qmk/qmk_firmware/pull/9019)
|
||||||
|
|
||||||
|
Fork all QMK submodules to protect against upstream repositories disappearing.
|
||||||
|
|
||||||
|
### code cleanup regarding deprecated macro PLAY_NOTE_ARRAY by replacing it with PLAY_SONG
|
||||||
|
|
||||||
|
[#8484](https://github.com/qmk/qmk_firmware/pull/8484)
|
||||||
|
|
||||||
|
Removes the deprecated `PLAY_NOTE_ARRAY` macro. References to it are replaced with `PLAY_SONG`, which references the same function.
|
||||||
|
|
||||||
|
### fixing wrong configuration of AUDIO feature
|
||||||
|
|
||||||
|
[#8903](https://github.com/qmk/qmk_firmware/pull/8903) and [#8974](https://github.com/qmk/qmk_firmware/pull/8974)
|
||||||
|
|
||||||
|
`audio_avr.c` does not default to any pin; there has to be a #define XX_AUDIO in config.h at some level for Audio to actually work. Otherwise, the Audio code ends up cluttering the firmware, possibly breaking builds because the maximum allowed firmware size is exceeded.
|
||||||
|
|
||||||
|
These changes fix this by disabling Audio on keyboards that have the feature misconfigured, and therefore non-functional.
|
||||||
|
|
||||||
|
Also, add a compile-time error to alert the user to a missing pin-configuration (on AVR boards) when `AUDIO_ENABLE = yes` is set.
|
||||||
|
|
||||||
|
|
||||||
|
## Keyboard Refactors
|
||||||
|
|
||||||
|
### Migrating Lily58 to use split_common
|
||||||
|
|
||||||
|
[#6260](https://github.com/qmk/qmk_firmware/pull/6260)
|
||||||
|
|
||||||
|
Modifies the default firmware for Lily58 to use the `split_common` library, instead of including and depending on its own set of libraries for the following functionality:
|
||||||
|
|
||||||
|
- SSD1306 display
|
||||||
|
- i2c for OLED
|
||||||
|
- Serial Communication
|
||||||
|
|
||||||
|
This allows current lily58 firmware to advance with updates to the `split_common` library, which is shared with many other split keyboards.
|
||||||
|
|
||||||
|
#### To migrate existing Lily58 firmware:
|
||||||
|
|
||||||
|
[Changes to `config.h`](https://github.com/qmk/qmk_firmware/pull/6260/files#diff-445ac369c8717dcd6fc6fc3630836fc1):
|
||||||
|
- Remove `#define SSD1306OLED` from config.h
|
||||||
|
|
||||||
|
|
||||||
|
[Changes to `keymap.c`](https://github.com/qmk/qmk_firmware/pull/6260/files#diff-20943ea59856e9bdf3d99ecb2eee40b7):
|
||||||
|
- Find/Replace each instance of `#ifdef SSD1306OLED` with `#ifdef OLED_DRIVER_ENABLE`
|
||||||
|
- The following changes are for compatibility with the OLED driver. If you don't use the OLED driver you may safely delete [this section](https://github.com/qmk/qmk_firmware/blob/e6b9980bd45c186f7360df68c24b6e05a80c10dc/keyboards/lily58/keymaps/default/keymap.c#L144-L190)
|
||||||
|
- Alternatively, if you did not change the OLED code from that in `default`, you may find it easier to simply copy the [relevant section](https://github.com/qmk/qmk_firmware/blob/4ac310668501ae6786c711ecc8f01f62ddaa1c0b/keyboards/lily58/keymaps/default/keymap.c#L138-L172). Otherwise, the changes you need to make are as follows (sample change [here](https://github.com/qmk/qmk_firmware/pull/6260/files#diff-20943ea59856e9bdf3d99ecb2eee40b7R138-R173))
|
||||||
|
- [Remove](https://github.com/qmk/qmk_firmware/pull/6260/files#diff-20943ea59856e9bdf3d99ecb2eee40b7L138-L141) the block
|
||||||
|
```c
|
||||||
|
#ifdef SSD1306OLED
|
||||||
|
iota_gfx_init(!has_usb()); // turns on the display
|
||||||
|
#endif
|
||||||
|
```
|
||||||
|
- Within the block bounded by `#ifdef OLED_DRIVER_ENABLE` and `#endif // OLED_DRIVER_ENABLE`, add the following block to ensure that your two OLEDs are rotated correctly across the left and right sides:
|
||||||
|
```c
|
||||||
|
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
|
||||||
|
if (!is_keyboard_master())
|
||||||
|
return OLED_ROTATION_180; // flips the display 180 degrees if offhand
|
||||||
|
return rotation;
|
||||||
|
}
|
||||||
|
```
|
||||||
|
- Remove the functions `matrix_scan_user`, `matrix_update` and `iota_gfx_task_user`
|
||||||
|
- Find/Replace `matrix_render_user(struct CharacterMatrix *matrix)` with `iota_gfx_task_user(void)`
|
||||||
|
- Find/Replace `is_master` with `is_keyboard_master()`
|
||||||
|
- For each instance of `matrix_write_ln(matrix, display_fn())`, rewrite it as `oled_write_ln(read_layer_state(), false);`
|
||||||
|
- For each instance of `matrix_write(matrix, read_logo());`, replace with `oled_write(read_logo(), false);`
|
||||||
|
|
||||||
|
### Refactor zinc to use split_common
|
||||||
|
|
||||||
|
[#7114](https://github.com/qmk/qmk_firmware/pull/7114) and [#9171](https://github.com/qmk/qmk_firmware/pull/9171)
|
||||||
|
|
||||||
|
* Refactor to use split_common and remove split codes under the zinc/revx/
|
||||||
|
* Add - backlight RGB LED and/or underglow RGB LED option
|
||||||
|
* Add - continuous RGB animations feature (between L and R halves)
|
||||||
|
* Fix - keymap files to adapt to changes
|
||||||
|
* all authors of keymaps confirmed this PR
|
||||||
|
* Update - documents and rules.mk
|
||||||
|
|
||||||
|
### Refactor of TKC1800 to use common OLED code
|
||||||
|
|
||||||
|
[#8472](https://github.com/qmk/qmk_firmware/pull/8472)
|
||||||
|
|
||||||
|
Modifies the default firmware for TKC1800 to use the in-built I2C and OLED drivers, instead of including and depending on its own set of libraries for the following functionality:
|
||||||
|
|
||||||
|
- SSD1306 display
|
||||||
|
- i2c for OLED
|
||||||
|
|
||||||
|
This allows current TKC1800 firmware to advance with updates to those drivers, which are shared with other keyboards.
|
||||||
|
|
||||||
|
#### To migrate existing TKC1800 firmware:
|
||||||
|
|
||||||
|
[Changes to `config.h`](https://github.com/qmk/qmk_firmware/pull/8472/files#diff-d10b26e676b4a55cbb00d71955116526):
|
||||||
|
- Remove `#define SSD1306OLED` from config.h
|
||||||
|
|
||||||
|
[Changes to `tkc1800.c`](https://github.com/qmk/qmk_firmware/pull/8472/files#diff-3b35bd30abe89c8110717c6972cd2cc5):
|
||||||
|
- Add the following to avoid debug errors on HID_listen if the screen is not present
|
||||||
|
```c
|
||||||
|
void keyboard_pre_init_kb(void) {
|
||||||
|
setPinInputHigh(D0);
|
||||||
|
setPinInputHigh(D1);
|
||||||
|
|
||||||
|
keyboard_pre_init_user();
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
[Changes to `keymap.c`](https://github.com/qmk/qmk_firmware/pull/8472/files#diff-05a2a344ce27e4d045fe68520ccd4771):
|
||||||
|
- Find/Replace each instance of `#ifdef SSD1306OLED` with `#ifdef OLED_DRIVER_ENABLE`
|
||||||
|
- The following changes are for compatibility with the OLED driver. If you don't use the OLED driver you may safely delete [this section](https://github.com/qmk/qmk_firmware/blob/e6b9980bd45c186f7360df68c24b6e05a80c10dc/keyboards/lily58/keymaps/default/keymap.c#L144-L190)
|
||||||
|
- [Remove](https://github.com/qmk/qmk_firmware/pull/6260/files#diff-20943ea59856e9bdf3d99ecb2eee40b7L91-L158) the block
|
||||||
|
```c
|
||||||
|
#ifdef SSD1306OLED
|
||||||
|
iota_gfx_init(!has_usb()); // turns on the display
|
||||||
|
#endif
|
||||||
|
```
|
||||||
|
- Within the block bounded by `#ifdef OLED_DRIVER_ENABLE` and `#endif // OLED_DRIVER_ENABLE`, add the following block to ensure that your two OLEDs are rotated correctly across the left and right sides:
|
||||||
|
```c
|
||||||
|
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
|
||||||
|
if (!is_keyboard_master())
|
||||||
|
return OLED_ROTATION_180; // flips the display 180 degrees if offhand
|
||||||
|
return rotation;
|
||||||
|
}
|
||||||
|
```
|
||||||
|
- Remove the function `iota_gfx_task_user`
|
||||||
|
|
||||||
|
### Split HHKB to ANSI and JP layouts and Add VIA support for each
|
||||||
|
|
||||||
|
[#8582](https://github.com/qmk/qmk_firmware/pull/8582)
|
||||||
|
|
||||||
|
- Splits the HHKB codebase into two separate folders `keyboards/hhkb/ansi` and `keyboards/hhkb/jp`.
|
||||||
|
- Adds VIA Configurator support for both versions.
|
||||||
|
|
||||||
|
#### Migrating existing HHKB keymaps
|
||||||
|
|
||||||
|
- Remove any checks for the `HHKB_JP` definition
|
||||||
|
- All checks for this definition have been removed, and each version uses the source that is appropriate to that version.
|
||||||
|
- Move the directory for your keymap into the appropriate `keymaps` directory
|
||||||
|
- `keyboards/hhkb/ansi/keymaps/` for ANSI HHKBs
|
||||||
|
- `keyboards/hhkb/jp/keymaps/` for HHKB JPs
|
||||||
|
- Compile with the new keyboard names
|
||||||
|
- This PR changes the compilation instructions for the HHKB Alternate Controller. To compile firmware for this controller moving forward, use:
|
||||||
|
- `make hhkb/ansi` for ANSI-layout HHKBs
|
||||||
|
- `make hhkb/jp` for HHKB JP keyboards
|
||||||
|
|
||||||
|
|
||||||
|
## Keyboard Moves
|
||||||
|
|
||||||
|
- [#8412](https://github.com/qmk/qmk_firmware/pull/8412 "Changing board names to prevent confusion") by blindassassin111
|
||||||
|
- [#8499](https://github.com/qmk/qmk_firmware/pull/8499 "Move the Keyboardio Model01 to a keyboardio/ subdir") by algernon
|
||||||
|
- [#8830](https://github.com/qmk/qmk_firmware/pull/8830 "Move spaceman keyboards") by Spaceman (formerly known as Rionlion100)
|
||||||
|
- [#8537](https://github.com/qmk/qmk_firmware/pull/8537 "Organizing my keyboards (plaid, tartan, ergoinu)") by hsgw
|
||||||
|
|
||||||
|
Keyboards by Keyboardio, Spaceman, and hsgw move to vendor folders, while PCBs designed by blindassassin111 are renamed.
|
||||||
|
|
||||||
|
Old Name | New Name
|
||||||
|
:----------------- | :-----------------
|
||||||
|
2_milk | spaceman/2_milk
|
||||||
|
at101_blackheart | at101_bh
|
||||||
|
ergoinu | dm9records/ergoinu
|
||||||
|
model01 | keyboardio/model01
|
||||||
|
omnikey_blackheart | omnikey_bh
|
||||||
|
pancake | spaceman/pancake
|
||||||
|
plaid | dm9records/plaid
|
||||||
|
tartan | dm9records/tartan
|
||||||
|
z150_blackheart | z150_bh
|
||||||
|
|
||||||
|
If you own one of these PCBs, please use the new names to compile your firmware moving forward.
|
||||||
|
|
||||||
|
|
||||||
|
## Keycode Migration PRs
|
||||||
|
|
||||||
|
[#8954](https://github.com/qmk/qmk_firmware/pull/8954 "Migrate `ACTION_LAYER_TOGGLE` to `TG()`"), [#8957](https://github.com/qmk/qmk_firmware/pull/8957 "Migrate `ACTION_MODS_ONESHOT` to `OSM()`"), [#8958](https://github.com/qmk/qmk_firmware/pull/8958 "Migrate `ACTION_DEFAULT_LAYER_SET` to `DF()`"), [#8959](https://github.com/qmk/qmk_firmware/pull/8959 "Migrate `ACTION_LAYER_MODS` to `LM()`"), [#8968](https://github.com/qmk/qmk_firmware/pull/8968 "Migrate `ACTION_MODS_TAP_KEY` to `MT()`"), [#8977](https://github.com/qmk/qmk_firmware/pull/8977 "Migrate miscellaneous `fn_actions` entries"), and [#8979](https://github.com/qmk/qmk_firmware/pull/8979 "Migrate `ACTION_MODS_KEY` to chained mod keycodes")
|
||||||
|
|
||||||
|
Authored by fauxpark, these pull requests remove references to deprecated TMK macros that have been superseded by native QMK keycodes.
|
||||||
|
|
||||||
|
Old `fn_actions` action | New QMK keycode
|
||||||
|
:---------------------- | :--------------
|
||||||
|
`ACTION_DEFAULT_LAYER_SET(layer)` | `DF(layer)`
|
||||||
|
`ACTION_LAYER_MODS(layer, mod)` | `LM(layer, mod)`
|
||||||
|
`ACTION_LAYER_ONESHOT(mod)` | `OSL(mod)`
|
||||||
|
`ACTION_LAYER_TOGGLE(layer)` | `TG(layer)`
|
||||||
|
`ACTION_MODS_ONESHOT(mod)` | `OSM(mod)`
|
||||||
|
`ACTION_MODS_TAP_KEY(mod, kc)` | `MT(mod, kc)`
|
||||||
|
`ACTION_MODS_KEY(mod, kc)`<br>e.g. `ACTION_MODS_KEY(MOD_LCTL, KC_0)` | `MOD(kc)`<br>e.g. `LCTL(KC_0)`
|
||||||
@@ -6,6 +6,7 @@
|
|||||||
* [Testing and Debugging](newbs_testing_debugging.md)
|
* [Testing and Debugging](newbs_testing_debugging.md)
|
||||||
* [Getting Help/Support](support.md)
|
* [Getting Help/Support](support.md)
|
||||||
* [Other Resources](newbs_learn_more_resources.md)
|
* [Other Resources](newbs_learn_more_resources.md)
|
||||||
|
* [Syllabus](syllabus.md)
|
||||||
|
|
||||||
* FAQs
|
* FAQs
|
||||||
* [General FAQ](faq_general.md)
|
* [General FAQ](faq_general.md)
|
||||||
@@ -33,7 +34,9 @@
|
|||||||
* [Customizing Functionality](custom_quantum_functions.md)
|
* [Customizing Functionality](custom_quantum_functions.md)
|
||||||
* [Driver Installation with Zadig](driver_installation_zadig.md)
|
* [Driver Installation with Zadig](driver_installation_zadig.md)
|
||||||
* [Keymap Overview](keymap.md)
|
* [Keymap Overview](keymap.md)
|
||||||
* [Vagrant Guide](getting_started_vagrant.md)
|
* Development Environments
|
||||||
|
* [Docker Guide](getting_started_docker.md)
|
||||||
|
* [Vagrant Guide](getting_started_vagrant.md)
|
||||||
* Flashing
|
* Flashing
|
||||||
* [Flashing](flashing.md)
|
* [Flashing](flashing.md)
|
||||||
* [Flashing ATmega32A (ps2avrgb)](flashing_bootloadhid.md)
|
* [Flashing ATmega32A (ps2avrgb)](flashing_bootloadhid.md)
|
||||||
@@ -52,6 +55,7 @@
|
|||||||
* Simple Keycodes
|
* Simple Keycodes
|
||||||
* [Full List](keycodes.md)
|
* [Full List](keycodes.md)
|
||||||
* [Basic Keycodes](keycodes_basic.md)
|
* [Basic Keycodes](keycodes_basic.md)
|
||||||
|
* [Language-Specific Keycodes](reference_keymap_extras.md)
|
||||||
* [Modifier Keys](feature_advanced_keycodes.md)
|
* [Modifier Keys](feature_advanced_keycodes.md)
|
||||||
* [Quantum Keycodes](quantum_keycodes.md)
|
* [Quantum Keycodes](quantum_keycodes.md)
|
||||||
|
|
||||||
@@ -74,6 +78,7 @@
|
|||||||
* [Layers](feature_layers.md)
|
* [Layers](feature_layers.md)
|
||||||
* [One Shot Keys](one_shot_keys.md)
|
* [One Shot Keys](one_shot_keys.md)
|
||||||
* [Pointing Device](feature_pointing_device.md)
|
* [Pointing Device](feature_pointing_device.md)
|
||||||
|
* [Raw HID](feature_rawhid.md)
|
||||||
* [Swap Hands](feature_swap_hands.md)
|
* [Swap Hands](feature_swap_hands.md)
|
||||||
* [Tap Dance](feature_tap_dance.md)
|
* [Tap Dance](feature_tap_dance.md)
|
||||||
* [Tap-Hold Configuration](tap_hold.md)
|
* [Tap-Hold Configuration](tap_hold.md)
|
||||||
@@ -110,6 +115,7 @@
|
|||||||
* [Overview](breaking_changes.md)
|
* [Overview](breaking_changes.md)
|
||||||
* [My Pull Request Was Flagged](breaking_changes_instructions.md)
|
* [My Pull Request Was Flagged](breaking_changes_instructions.md)
|
||||||
* History
|
* History
|
||||||
|
* [2020 May 30](ChangeLog/20200530.md)
|
||||||
* [2020 Feb 29](ChangeLog/20200229.md)
|
* [2020 Feb 29](ChangeLog/20200229.md)
|
||||||
* [2019 Aug 30](ChangeLog/20190830.md)
|
* [2019 Aug 30](ChangeLog/20190830.md)
|
||||||
|
|
||||||
@@ -121,8 +127,10 @@
|
|||||||
* [Drivers](hardware_drivers.md)
|
* [Drivers](hardware_drivers.md)
|
||||||
* [ADC Driver](adc_driver.md)
|
* [ADC Driver](adc_driver.md)
|
||||||
* [I2C Driver](i2c_driver.md)
|
* [I2C Driver](i2c_driver.md)
|
||||||
|
* [SPI Driver](spi_driver.md)
|
||||||
* [WS2812 Driver](ws2812_driver.md)
|
* [WS2812 Driver](ws2812_driver.md)
|
||||||
* [EEPROM Driver](eeprom_driver.md)
|
* [EEPROM Driver](eeprom_driver.md)
|
||||||
|
* ['serial' Driver](serial_driver.md)
|
||||||
* [GPIO Controls](internals_gpio_control.md)
|
* [GPIO Controls](internals_gpio_control.md)
|
||||||
* [Keyboard Guidelines](hardware_keyboard_guidelines.md)
|
* [Keyboard Guidelines](hardware_keyboard_guidelines.md)
|
||||||
|
|
||||||
@@ -135,6 +143,10 @@
|
|||||||
* [Development Environment](api_development_environment.md)
|
* [Development Environment](api_development_environment.md)
|
||||||
* [Architecture Overview](api_development_overview.md)
|
* [Architecture Overview](api_development_overview.md)
|
||||||
|
|
||||||
|
* Hardware Platform Development
|
||||||
|
* Arm/ChibiOS
|
||||||
|
* [Early initialization](platformdev_chibios_earlyinit.md)
|
||||||
|
|
||||||
* QMK Reference
|
* QMK Reference
|
||||||
* [Contributing to QMK](contributing.md)
|
* [Contributing to QMK](contributing.md)
|
||||||
* [Translating the QMK Docs](translating.md)
|
* [Translating the QMK Docs](translating.md)
|
||||||
|
|||||||
@@ -6,27 +6,28 @@ The breaking change period is when we will merge PR's that change QMK in dangero
|
|||||||
|
|
||||||
## What has been included in past Breaking Changes?
|
## What has been included in past Breaking Changes?
|
||||||
|
|
||||||
|
* [2020 May 30](ChangeLog/20200530.md)
|
||||||
* [2020 Feb 29](ChangeLog/20200229.md)
|
* [2020 Feb 29](ChangeLog/20200229.md)
|
||||||
* [2019 Aug 30](ChangeLog/20190830.md)
|
* [2019 Aug 30](ChangeLog/20190830.md)
|
||||||
|
|
||||||
## When is the next Breaking Change?
|
## When is the next Breaking Change?
|
||||||
|
|
||||||
The next Breaking Change is scheduled for May 30, 2020.
|
The next Breaking Change is scheduled for Aug 29, 2020.
|
||||||
|
|
||||||
### Important Dates
|
### Important Dates
|
||||||
|
|
||||||
* [x] 2020 Feb 29 - `future` is created. It will be rebased weekly.
|
* [x] 2020 May 30 - `develop` is created. It will be rebased weekly.
|
||||||
* [ ] 2020 May 2 - `future` closed to new PR's.
|
* [ ] 2020 Aug 1 - `develop` closed to new PR's.
|
||||||
* [ ] 2020 May 2 - Call for testers.
|
* [ ] 2020 Aug 1 - Call for testers.
|
||||||
* [ ] 2020 May 28 - `master` is locked, no PR's merged.
|
* [ ] 2020 Aug 27 - `master` is locked, no PR's merged.
|
||||||
* [ ] 2020 May 30 - Merge `future` to `master`.
|
* [ ] 2020 Aug 29 - Merge `develop` to `master`.
|
||||||
* [ ] 2020 May 30 - `master` is unlocked. PR's can be merged again.
|
* [ ] 2020 Aug 29 - `master` is unlocked. PR's can be merged again.
|
||||||
|
|
||||||
## What changes will be included?
|
## What changes will be included?
|
||||||
|
|
||||||
To see a list of breaking change candidates you can look at the [`breaking_change` label](https://github.com/qmk/qmk_firmware/pulls?q=is%3Aopen+label%3Abreaking_change+is%3Apr). New changes might be added between now and when `future` is closed, and a PR with that label applied is not guaranteed to be merged.
|
To see a list of breaking change candidates you can look at the [`breaking_change` label](https://github.com/qmk/qmk_firmware/pulls?q=is%3Aopen+label%3Abreaking_change+is%3Apr). New changes might be added between now and when `develop` is closed, and a PR with that label applied is not guaranteed to be merged.
|
||||||
|
|
||||||
If you want your breaking change to be included in this round you need to create a PR with the `breaking_change` label and have it accepted before `future` closes. After `future` closes no new breaking changes will be accepted.
|
If you want your breaking change to be included in this round you need to create a PR with the `breaking_change` label and have it accepted before `develop` closes. After `develop` closes no new breaking changes will be accepted.
|
||||||
|
|
||||||
Criteria for acceptance:
|
Criteria for acceptance:
|
||||||
|
|
||||||
@@ -37,9 +38,9 @@ Criteria for acceptance:
|
|||||||
|
|
||||||
This section documents various processes we use when running the Breaking Changes process.
|
This section documents various processes we use when running the Breaking Changes process.
|
||||||
|
|
||||||
## Rebase `future` from `master`
|
## Rebase `develop` from `master`
|
||||||
|
|
||||||
This is run every Friday while `future` is open.
|
This is run every Friday while `develop` is open.
|
||||||
|
|
||||||
Process:
|
Process:
|
||||||
|
|
||||||
@@ -47,31 +48,31 @@ Process:
|
|||||||
cd qmk_firmware
|
cd qmk_firmware
|
||||||
git checkout master
|
git checkout master
|
||||||
git pull --ff-only
|
git pull --ff-only
|
||||||
git checkout future
|
git checkout develop
|
||||||
git rebase master
|
git rebase master
|
||||||
git push --force
|
git push --force
|
||||||
```
|
```
|
||||||
|
|
||||||
## Creating the `future` branch
|
## Creating the `develop` branch
|
||||||
|
|
||||||
This happens immediately after the previous `future` branch is merged.
|
This happens immediately after the previous `develop` branch is merged.
|
||||||
|
|
||||||
* `qmk_firmware` git commands
|
* `qmk_firmware` git commands
|
||||||
* [ ] `git checkout master`
|
* [ ] `git checkout master`
|
||||||
* [ ] `git pull --ff-only`
|
* [ ] `git pull --ff-only`
|
||||||
* [ ] `git checkout -b future`
|
* [ ] `git checkout -b develop`
|
||||||
* [ ] Edit `readme.md`
|
* [ ] Edit `readme.md`
|
||||||
* [ ] Add a big notice at the top that this is a testing branch.
|
* [ ] Add a big notice at the top that this is a testing branch.
|
||||||
* [ ] Include a link to this document
|
* [ ] Include a link to this document
|
||||||
* [ ] `git commit -m 'Branch point for <DATE> Breaking Change'`
|
* [ ] `git commit -m 'Branch point for <DATE> Breaking Change'`
|
||||||
* [ ] `git tag breakpoint_<YYYY>_<MM>_<DD>`
|
* [ ] `git tag breakpoint_<YYYY>_<MM>_<DD>`
|
||||||
* [ ] `git tag <next_version>` # Prevent the breakpoint tag from confusing version incrementing
|
* [ ] `git tag <next_version>` # Prevent the breakpoint tag from confusing version incrementing
|
||||||
* [ ] `git push origin future`
|
* [ ] `git push origin develop`
|
||||||
* [ ] `git push --tags`
|
* [ ] `git push --tags`
|
||||||
|
|
||||||
## 4 Weeks Before Merge
|
## 4 Weeks Before Merge
|
||||||
|
|
||||||
* `future` is now closed to new PR's, only fixes for current PR's may be merged
|
* `develop` is now closed to new PR's, only fixes for current PR's may be merged
|
||||||
* Post call for testers
|
* Post call for testers
|
||||||
* [ ] Discord
|
* [ ] Discord
|
||||||
* [ ] GitHub PR
|
* [ ] GitHub PR
|
||||||
@@ -94,15 +95,15 @@ This happens immediately after the previous `future` branch is merged.
|
|||||||
## Day Of Merge
|
## Day Of Merge
|
||||||
|
|
||||||
* `qmk_firmware` git commands
|
* `qmk_firmware` git commands
|
||||||
* [ ] `git checkout future`
|
* [ ] `git checkout develop`
|
||||||
* [ ] `git pull --ff-only`
|
* [ ] `git pull --ff-only`
|
||||||
* [ ] `git rebase origin/master`
|
* [ ] `git rebase origin/master`
|
||||||
* [ ] Edit `readme.md`
|
* [ ] Edit `readme.md`
|
||||||
* [ ] Remove the notes about `future`
|
* [ ] Remove the notes about `develop`
|
||||||
* [ ] Roll up the ChangeLog into one file.
|
* [ ] Roll up the ChangeLog into one file.
|
||||||
* [ ] `git commit -m 'Merge point for <DATE> Breaking Change'`
|
* [ ] `git commit -m 'Merge point for <DATE> Breaking Change'`
|
||||||
* [ ] `git push origin future`
|
* [ ] `git push origin develop`
|
||||||
* Github Actions
|
* GitHub Actions
|
||||||
* [ ] Create a PR for `future`
|
* [ ] Create a PR for `develop`
|
||||||
* [ ] Make sure travis comes back clean
|
* [ ] Make sure travis comes back clean
|
||||||
* [ ] Merge `future` PR
|
* [ ] Merge `develop` PR
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ If you are contributing core code, and the only reason it needs to go through br
|
|||||||
|
|
||||||
We require submissions that go through the Breaking Change process to include a changelog entry. The entry should be a short summary of the changes your pull request makes – [each section here started as a changelog](ChangeLog/20190830.md "n.b. This should link to the 2019 Aug 30 Breaking Changes doc - @noroadsleft").
|
We require submissions that go through the Breaking Change process to include a changelog entry. The entry should be a short summary of the changes your pull request makes – [each section here started as a changelog](ChangeLog/20190830.md "n.b. This should link to the 2019 Aug 30 Breaking Changes doc - @noroadsleft").
|
||||||
|
|
||||||
Your changelog should be located at `docs/ChangeLog/YYYYMMDD/PR####.md`, where `YYYYMMDD` is the date on which QMK's breaking change branch – usually named `future` – will be merged into the `master` branch, and `####` is the number of your pull request.
|
Your changelog should be located at `docs/ChangeLog/YYYYMMDD/PR####.md`, where `YYYYMMDD` is the date on which QMK's breaking change branch – usually named `develop` – will be merged into the `master` branch, and `####` is the number of your pull request.
|
||||||
|
|
||||||
If your submission requires action on the part of users, your changelog should instruct users what action(s) must be taken, or link to a location that does so.
|
If your submission requires action on the part of users, your changelog should instruct users what action(s) must be taken, or link to a location that does so.
|
||||||
|
|
||||||
|
|||||||
11
docs/cli.md
11
docs/cli.md
@@ -6,25 +6,24 @@ The QMK CLI makes building and working with QMK keyboards easier. We have provid
|
|||||||
|
|
||||||
### Requirements :id=requirements
|
### Requirements :id=requirements
|
||||||
|
|
||||||
The CLI requires Python 3.5 or greater. We try to keep the number of requirements small but you will also need to install the packages listed in [`requirements.txt`](https://github.com/qmk/qmk_firmware/blob/master/requirements.txt). These are installed automatically when you install the QMK CLI.
|
QMK requires Python 3.6 or greater. We try to keep the number of requirements small but you will also need to install the packages listed in [`requirements.txt`](https://github.com/qmk/qmk_firmware/blob/master/requirements.txt). These are installed automatically when you install the QMK CLI.
|
||||||
|
|
||||||
### Install Using Homebrew (macOS, some Linux) :id=install-using-homebrew
|
### Install Using Homebrew (macOS, some Linux) :id=install-using-homebrew
|
||||||
|
|
||||||
If you have installed [Homebrew](https://brew.sh) you can tap and install QMK:
|
If you have installed [Homebrew](https://brew.sh) you can tap and install QMK:
|
||||||
|
|
||||||
```
|
```
|
||||||
brew tap qmk/qmk
|
brew install qmk/qmk/qmk
|
||||||
brew install qmk
|
|
||||||
export QMK_HOME='~/qmk_firmware' # Optional, set the location for `qmk_firmware`
|
export QMK_HOME='~/qmk_firmware' # Optional, set the location for `qmk_firmware`
|
||||||
qmk setup # This will clone `qmk/qmk_firmware` and optionally set up your build environment
|
qmk setup # This will clone `qmk/qmk_firmware` and optionally set up your build environment
|
||||||
```
|
```
|
||||||
|
|
||||||
### Install Using easy_install or pip :id=install-using-easy_install-or-pip
|
### Install Using pip :id=install-using-easy_install-or-pip
|
||||||
|
|
||||||
If your system is not listed above you can install QMK manually. First ensure that you have python 3.5 (or later) installed and have installed pip. Then install QMK with this command:
|
If your system is not listed above you can install QMK manually. First ensure that you have Python 3.6 (or later) installed and have installed pip. Then install QMK with this command:
|
||||||
|
|
||||||
```
|
```
|
||||||
pip3 install qmk
|
python3 -m pip install qmk
|
||||||
export QMK_HOME='~/qmk_firmware' # Optional, set the location for `qmk_firmware`
|
export QMK_HOME='~/qmk_firmware' # Optional, set the location for `qmk_firmware`
|
||||||
qmk setup # This will clone `qmk/qmk_firmware` and optionally set up your build environment
|
qmk setup # This will clone `qmk/qmk_firmware` and optionally set up your build environment
|
||||||
```
|
```
|
||||||
|
|||||||
@@ -1,43 +1,13 @@
|
|||||||
# QMK CLI Commands
|
# QMK CLI Commands
|
||||||
|
|
||||||
# CLI Commands
|
# User Commands
|
||||||
|
|
||||||
## `qmk cformat`
|
|
||||||
|
|
||||||
This command formats C code using clang-format.
|
|
||||||
|
|
||||||
Run it with no arguments to format all core code that has been changed. Default checks `origin/master` with `git diff`, branch can be changed using `-b <branch_name>`
|
|
||||||
|
|
||||||
Run it with `-a` to format all core code, or pass filenames on the command line to run it on specific files.
|
|
||||||
|
|
||||||
**Usage for specified files**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk cformat [file1] [file2] [...] [fileN]
|
|
||||||
```
|
|
||||||
|
|
||||||
**Usage for all core files**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk cformat -a
|
|
||||||
```
|
|
||||||
|
|
||||||
**Usage for only changed files against origin/master**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk cformat
|
|
||||||
```
|
|
||||||
|
|
||||||
**Usage for only changed files against branch_name**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk cformat -b branch_name
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk compile`
|
## `qmk compile`
|
||||||
|
|
||||||
This command allows you to compile firmware from any directory. You can compile JSON exports from <https://config.qmk.fm>, compile keymaps in the repo, or compile the keyboard in the current working directory.
|
This command allows you to compile firmware from any directory. You can compile JSON exports from <https://config.qmk.fm>, compile keymaps in the repo, or compile the keyboard in the current working directory.
|
||||||
|
|
||||||
|
This command is directory aware. It will automatically fill in KEYBOARD and/or KEYMAP if you are in a keyboard or keymap directory.
|
||||||
|
|
||||||
**Usage for Configurator Exports**:
|
**Usage for Configurator Exports**:
|
||||||
|
|
||||||
```
|
```
|
||||||
@@ -105,8 +75,9 @@ $ qmk compile -kb dz60
|
|||||||
|
|
||||||
## `qmk flash`
|
## `qmk flash`
|
||||||
|
|
||||||
This command is similar to `qmk compile`, but can also target a bootloader. The bootloader is optional, and is set to `:flash` by default.
|
This command is similar to `qmk compile`, but can also target a bootloader. The bootloader is optional, and is set to `:flash` by default. To specify a different bootloader, use `-bl <bootloader>`. Visit the [Flashing Firmware](flashing.md) guide for more details of the available bootloaders.
|
||||||
To specify a different bootloader, use `-bl <bootloader>`. Visit the [Flashing Firmware](flashing.md) guide for more details of the available bootloaders.
|
|
||||||
|
This command is directory aware. It will automatically fill in KEYBOARD and/or KEYMAP if you are in a keyboard or keymap directory.
|
||||||
|
|
||||||
**Usage for Configurator Exports**:
|
**Usage for Configurator Exports**:
|
||||||
|
|
||||||
@@ -136,16 +107,6 @@ This command lets you configure the behavior of QMK. For the full `qmk config` d
|
|||||||
qmk config [-ro] [config_token1] [config_token2] [...] [config_tokenN]
|
qmk config [-ro] [config_token1] [config_token2] [...] [config_tokenN]
|
||||||
```
|
```
|
||||||
|
|
||||||
## `qmk docs`
|
|
||||||
|
|
||||||
This command starts a local HTTP server which you can use for browsing or improving the docs. Default port is 8936.
|
|
||||||
|
|
||||||
**Usage**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk docs [-p PORT]
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk doctor`
|
## `qmk doctor`
|
||||||
|
|
||||||
This command examines your environment and alerts you to potential build or flash problems. It can fix many of them if you want it to.
|
This command examines your environment and alerts you to potential build or flash problems. It can fix many of them if you want it to.
|
||||||
@@ -170,6 +131,32 @@ Check your environment and report problems only:
|
|||||||
|
|
||||||
qmk doctor -n
|
qmk doctor -n
|
||||||
|
|
||||||
|
## `qmk info`
|
||||||
|
|
||||||
|
Displays information about keyboards and keymaps in QMK. You can use this to get information about a keyboard, show the layouts, display the underlying key matrix, or to pretty-print JSON keymaps.
|
||||||
|
|
||||||
|
**Usage**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk info [-f FORMAT] [-m] [-l] [-km KEYMAP] [-kb KEYBOARD]
|
||||||
|
```
|
||||||
|
|
||||||
|
This command is directory aware. It will automatically fill in KEYBOARD and/or KEYMAP if you are in a keyboard or keymap directory.
|
||||||
|
|
||||||
|
**Examples**:
|
||||||
|
|
||||||
|
Show basic information for a keyboard:
|
||||||
|
|
||||||
|
qmk info -kb planck/rev5
|
||||||
|
|
||||||
|
Show the matrix for a keyboard:
|
||||||
|
|
||||||
|
qmk info -kb ergodox_ez -m
|
||||||
|
|
||||||
|
Show a JSON keymap for a keyboard:
|
||||||
|
|
||||||
|
qmk info -kb clueboard/california -km default
|
||||||
|
|
||||||
## `qmk json2c`
|
## `qmk json2c`
|
||||||
|
|
||||||
Creates a keymap.c from a QMK Configurator export.
|
Creates a keymap.c from a QMK Configurator export.
|
||||||
@@ -180,6 +167,86 @@ Creates a keymap.c from a QMK Configurator export.
|
|||||||
qmk json2c [-o OUTPUT] filename
|
qmk json2c [-o OUTPUT] filename
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## `qmk list-keyboards`
|
||||||
|
|
||||||
|
This command lists all the keyboards currently defined in `qmk_firmware`
|
||||||
|
|
||||||
|
**Usage**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk list-keyboards
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk list-keymaps`
|
||||||
|
|
||||||
|
This command lists all the keymaps for a specified keyboard (and revision).
|
||||||
|
|
||||||
|
This command is directory aware. It will automatically fill in KEYBOARD if you are in a keyboard directory.
|
||||||
|
|
||||||
|
**Usage**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk list-keymaps -kb planck/ez
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk new-keymap`
|
||||||
|
|
||||||
|
This command creates a new keymap based on a keyboard's existing default keymap.
|
||||||
|
|
||||||
|
This command is directory aware. It will automatically fill in KEYBOARD and/or KEYMAP if you are in a keyboard or keymap directory.
|
||||||
|
|
||||||
|
**Usage**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk new-keymap [-kb KEYBOARD] [-km KEYMAP]
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# Developer Commands
|
||||||
|
|
||||||
|
## `qmk cformat`
|
||||||
|
|
||||||
|
This command formats C code using clang-format.
|
||||||
|
|
||||||
|
Run it with no arguments to format all core code that has been changed. Default checks `origin/master` with `git diff`, branch can be changed using `-b <branch_name>`
|
||||||
|
|
||||||
|
Run it with `-a` to format all core code, or pass filenames on the command line to run it on specific files.
|
||||||
|
|
||||||
|
**Usage for specified files**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat [file1] [file2] [...] [fileN]
|
||||||
|
```
|
||||||
|
|
||||||
|
**Usage for all core files**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat -a
|
||||||
|
```
|
||||||
|
|
||||||
|
**Usage for only changed files against origin/master**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat
|
||||||
|
```
|
||||||
|
|
||||||
|
**Usage for only changed files against branch_name**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat -b branch_name
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk docs`
|
||||||
|
|
||||||
|
This command starts a local HTTP server which you can use for browsing or improving the docs. Default port is 8936.
|
||||||
|
|
||||||
|
**Usage**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk docs [-p PORT]
|
||||||
|
```
|
||||||
|
|
||||||
## `qmk kle2json`
|
## `qmk kle2json`
|
||||||
|
|
||||||
This command allows you to convert from raw KLE data to QMK Configurator JSON. It accepts either an absolute file path, or a file name in the current directory. By default it will not overwrite `info.json` if it is already present. Use the `-f` or `--force` flag to overwrite.
|
This command allows you to convert from raw KLE data to QMK Configurator JSON. It accepts either an absolute file path, or a file name in the current directory. By default it will not overwrite `info.json` if it is already present. Use the `-f` or `--force` flag to overwrite.
|
||||||
@@ -202,36 +269,6 @@ $ qmk kle2json -f kle.txt -f
|
|||||||
Ψ Wrote out to info.json
|
Ψ Wrote out to info.json
|
||||||
```
|
```
|
||||||
|
|
||||||
## `qmk list-keyboards`
|
|
||||||
|
|
||||||
This command lists all the keyboards currently defined in `qmk_firmware`
|
|
||||||
|
|
||||||
**Usage**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk list-keyboards
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk list-keymaps`
|
|
||||||
|
|
||||||
This command lists all the keymaps for a specified keyboard (and revision).
|
|
||||||
|
|
||||||
**Usage**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk list-keymaps -kb planck/ez
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk new-keymap`
|
|
||||||
|
|
||||||
This command creates a new keymap based on a keyboard's existing default keymap.
|
|
||||||
|
|
||||||
**Usage**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk new-keymap [-kb KEYBOARD] [-km KEYMAP]
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk pyformat`
|
## `qmk pyformat`
|
||||||
|
|
||||||
This command formats python code in `qmk_firmware`.
|
This command formats python code in `qmk_firmware`.
|
||||||
@@ -251,3 +288,4 @@ This command runs the python test suite. If you make changes to python code you
|
|||||||
```
|
```
|
||||||
qmk pytest
|
qmk pytest
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -108,7 +108,7 @@ compile.keymap: skully -> None
|
|||||||
|-----|---------------|-------------|
|
|-----|---------------|-------------|
|
||||||
| user.keyboard | None | The keyboard path (Example: `clueboard/66/rev4`) |
|
| user.keyboard | None | The keyboard path (Example: `clueboard/66/rev4`) |
|
||||||
| user.keymap | None | The keymap name (Example: `default`) |
|
| user.keymap | None | The keymap name (Example: `default`) |
|
||||||
| user.name | None | The user's github username. |
|
| user.name | None | The user's GitHub username. |
|
||||||
|
|
||||||
# All Configuration Options
|
# All Configuration Options
|
||||||
|
|
||||||
|
|||||||
@@ -6,6 +6,18 @@ This document has useful information for developers wishing to write new `qmk` s
|
|||||||
|
|
||||||
The QMK CLI operates using the subcommand pattern made famous by git. The main `qmk` script is simply there to setup the environment and pick the correct entrypoint to run. Each subcommand is a self-contained module with an entrypoint (decorated by `@cli.subcommand()`) that performs some action and returns a shell returncode, or None.
|
The QMK CLI operates using the subcommand pattern made famous by git. The main `qmk` script is simply there to setup the environment and pick the correct entrypoint to run. Each subcommand is a self-contained module with an entrypoint (decorated by `@cli.subcommand()`) that performs some action and returns a shell returncode, or None.
|
||||||
|
|
||||||
|
## Developer mode:
|
||||||
|
|
||||||
|
If you intend to maintain keyboards and/or contribute to QMK, you can enable the CLI's "Developer" mode:
|
||||||
|
|
||||||
|
`qmk config user.developer=True`
|
||||||
|
|
||||||
|
This will allow you to see all available subcommands.
|
||||||
|
**Note:** You will have to install additional requirements:
|
||||||
|
```bash
|
||||||
|
python3 -m pip install -r requirements-dev.txt
|
||||||
|
```
|
||||||
|
|
||||||
# Subcommands
|
# Subcommands
|
||||||
|
|
||||||
[MILC](https://github.com/clueboard/milc) is the CLI framework `qmk` uses to handle argument parsing, configuration, logging, and many other features. It lets you focus on writing your tool without wasting your time writing glue code.
|
[MILC](https://github.com/clueboard/milc) is the CLI framework `qmk` uses to handle argument parsing, configuration, logging, and many other features. It lets you focus on writing your tool without wasting your time writing glue code.
|
||||||
@@ -32,7 +44,7 @@ def hello(cli):
|
|||||||
|
|
||||||
First we import the `cli` object from `milc`. This is how we interact with the user and control the script's behavior. We use `@cli.argument()` to define a command line flag, `--name`. This also creates a configuration variable named `hello.name` (and the corresponding `user.name`) which the user can set so they don't have to specify the argument. The `cli.subcommand()` decorator designates this function as a subcommand. The name of the subcommand will be taken from the name of the function.
|
First we import the `cli` object from `milc`. This is how we interact with the user and control the script's behavior. We use `@cli.argument()` to define a command line flag, `--name`. This also creates a configuration variable named `hello.name` (and the corresponding `user.name`) which the user can set so they don't have to specify the argument. The `cli.subcommand()` decorator designates this function as a subcommand. The name of the subcommand will be taken from the name of the function.
|
||||||
|
|
||||||
Once inside our function we find a typical "Hello, World!" program. We use `cli.log` to access the underlying [Logger Object](https://docs.python.org/3.5/library/logging.html#logger-objects), whose behavior is user controllable. We also access the value for name supplied by the user as `cli.config.hello.name`. The value for `cli.config.hello.name` will be determined by looking at the `--name` argument supplied by the user, if not provided it will use the value in the `qmk.ini` config file, and if neither of those is provided it will fall back to the default supplied in the `cli.argument()` decorator.
|
Once inside our function we find a typical "Hello, World!" program. We use `cli.log` to access the underlying [Logger Object](https://docs.python.org/3.6/library/logging.html#logger-objects), whose behavior is user controllable. We also access the value for name supplied by the user as `cli.config.hello.name`. The value for `cli.config.hello.name` will be determined by looking at the `--name` argument supplied by the user, if not provided it will use the value in the `qmk.ini` config file, and if neither of those is provided it will fall back to the default supplied in the `cli.argument()` decorator.
|
||||||
|
|
||||||
# User Interaction
|
# User Interaction
|
||||||
|
|
||||||
@@ -44,13 +56,13 @@ There are two main methods for outputting text in a subcommand- `cli.log` and `c
|
|||||||
|
|
||||||
You can use special tokens to colorize your text, to make it easier to understand the output of your program. See [Colorizing Text](#colorizing-text) below.
|
You can use special tokens to colorize your text, to make it easier to understand the output of your program. See [Colorizing Text](#colorizing-text) below.
|
||||||
|
|
||||||
Both of these methods support built-in string formatting using python's [printf style string format operations](https://docs.python.org/3.5/library/stdtypes.html#old-string-formatting). You can use tokens such as `%s` and `%d` within your text strings then pass the values as arguments. See our Hello, World program above for an example.
|
Both of these methods support built-in string formatting using python's [printf style string format operations](https://docs.python.org/3.6/library/stdtypes.html#old-string-formatting). You can use tokens such as `%s` and `%d` within your text strings then pass the values as arguments. See our Hello, World program above for an example.
|
||||||
|
|
||||||
You should never use the format operator (`%`) directly, always pass values as arguments.
|
You should never use the format operator (`%`) directly, always pass values as arguments.
|
||||||
|
|
||||||
### Logging (`cli.log`)
|
### Logging (`cli.log`)
|
||||||
|
|
||||||
The `cli.log` object gives you access to a [Logger Object](https://docs.python.org/3.5/library/logging.html#logger-objects). We have configured our log output to show the user a nice emoji for each log level (or the log level name if their terminal does not support unicode.) This way the user can tell at a glance which messages are most important when something goes wrong.
|
The `cli.log` object gives you access to a [Logger Object](https://docs.python.org/3.6/library/logging.html#logger-objects). We have configured our log output to show the user a nice emoji for each log level (or the log level name if their terminal does not support unicode.) This way the user can tell at a glance which messages are most important when something goes wrong.
|
||||||
|
|
||||||
The default log level is `INFO`. If the user runs `qmk -v <subcommand>` the default log level will be set to `DEBUG`.
|
The default log level is `INFO`. If the user runs `qmk -v <subcommand>` the default log level will be set to `DEBUG`.
|
||||||
|
|
||||||
@@ -198,7 +210,7 @@ Our tests can be found in `lib/python/qmk/tests/`. You will find both unit and i
|
|||||||
|
|
||||||
If your PR does not include a comprehensive set of tests please add comments like this to your code so that other people know where they can help:
|
If your PR does not include a comprehensive set of tests please add comments like this to your code so that other people know where they can help:
|
||||||
|
|
||||||
# TODO(unassigned/<yourGithubUsername>): Write <unit|integration> tests
|
# TODO(unassigned/<your_github_username>): Write <unit|integration> tests
|
||||||
|
|
||||||
We use [nose2](https://nose2.readthedocs.io/en/latest/getting_started.html) to run our tests. You can refer to the nose2 documentation for more details on what you can do in your test functions.
|
We use [nose2](https://nose2.readthedocs.io/en/latest/getting_started.html) to run our tests. You can refer to the nose2 documentation for more details on what you can do in your test functions.
|
||||||
|
|
||||||
|
|||||||
@@ -20,11 +20,11 @@ Most of our style is pretty easy to pick up on, but right now it's not entirely
|
|||||||
* We accept both forms of preprocessor if's: `#ifdef DEFINED` and `#if defined(DEFINED)`
|
* We accept both forms of preprocessor if's: `#ifdef DEFINED` and `#if defined(DEFINED)`
|
||||||
* If you are not sure which to prefer use the `#if defined(DEFINED)` form.
|
* If you are not sure which to prefer use the `#if defined(DEFINED)` form.
|
||||||
* Do not change existing code from one style to the other, except when moving to a multiple condition `#if`.
|
* Do not change existing code from one style to the other, except when moving to a multiple condition `#if`.
|
||||||
* Do not put whitespace between `#` and `if`.
|
* When deciding how (or if) to indent preprocessor directives, keep these points in mind:
|
||||||
* When deciding how (or if) to indent directives keep these points in mind:
|
* Readability is more important than consistency.
|
||||||
* Readability is more important than consistency.
|
* Follow the file's existing style. If the file is mixed, follow the style that makes sense for the section you are modifying.
|
||||||
* Follow the file's existing style. If the file is mixed follow the style that makes sense for the section you are modifying.
|
* When indenting, keep the hash at the start of the line and add whitespace between `#` and `if`, starting with 4 spaces after the `#`.
|
||||||
* When choosing to indent you can follow the indention level of the surrounding C code, or preprocessor directives can have their own indent level. Choose the style that best communicates the intent of your code.
|
* You can follow the indention level of the surrounding C code, or preprocessor directives can have their own indentation levels. Choose the style that best communicates the intent of your code.
|
||||||
|
|
||||||
Here is an example for easy reference:
|
Here is an example for easy reference:
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Most of our style follows PEP8 with some local modifications to make things less nit-picky.
|
Most of our style follows PEP8 with some local modifications to make things less nit-picky.
|
||||||
|
|
||||||
* We target Python 3.5 for compatability with all supported platforms.
|
* We target Python 3.6 for compatability with all supported platforms.
|
||||||
* We indent using four (4) spaces (soft tabs)
|
* We indent using four (4) spaces (soft tabs)
|
||||||
* We encourage liberal use of comments
|
* We encourage liberal use of comments
|
||||||
* Think of them as a story describing the feature
|
* Think of them as a story describing the feature
|
||||||
@@ -317,7 +317,7 @@ At the time of this writing our tests are not very comprehensive. Looking at the
|
|||||||
|
|
||||||
## Integration Tests
|
## Integration Tests
|
||||||
|
|
||||||
Integration tests can be found in `lib/python/qmk/tests/test_cli_commands.py`. This is where CLI commands are actually run and their overall behavior is verified. We use [`subprocess`](https://docs.python.org/3.5/library/subprocess.html#module-subprocess) to launch each CLI command and a combination of checking output and returncode to determine if the right thing happened.
|
Integration tests can be found in `lib/python/qmk/tests/test_cli_commands.py`. This is where CLI commands are actually run and their overall behavior is verified. We use [`subprocess`](https://docs.python.org/3.6/library/subprocess.html#module-subprocess) to launch each CLI command and a combination of checking output and returncode to determine if the right thing happened.
|
||||||
|
|
||||||
## Unit Tests
|
## Unit Tests
|
||||||
|
|
||||||
|
|||||||
@@ -115,9 +115,9 @@ If you define these options you will disable the associated feature, which can s
|
|||||||
* `#define NO_ACTION_ONESHOT`
|
* `#define NO_ACTION_ONESHOT`
|
||||||
* disable one-shot modifiers
|
* disable one-shot modifiers
|
||||||
* `#define NO_ACTION_MACRO`
|
* `#define NO_ACTION_MACRO`
|
||||||
* disable old style macro handling: MACRO() & action_get_macro
|
* disable old-style macro handling using `MACRO()`, `action_get_macro()` _(deprecated)_
|
||||||
* `#define NO_ACTION_FUNCTION`
|
* `#define NO_ACTION_FUNCTION`
|
||||||
* disable calling of action_function() from the fn_actions array (deprecated)
|
* disable old-style function handling using `fn_actions`, `action_function()` _(deprecated)_
|
||||||
|
|
||||||
## Features That Can Be Enabled
|
## Features That Can Be Enabled
|
||||||
|
|
||||||
@@ -191,7 +191,12 @@ If you define these options you will enable the associated feature, which may in
|
|||||||
* `#define RGBLIGHT_ANIMATIONS`
|
* `#define RGBLIGHT_ANIMATIONS`
|
||||||
* run RGB animations
|
* run RGB animations
|
||||||
* `#define RGBLIGHT_LAYERS`
|
* `#define RGBLIGHT_LAYERS`
|
||||||
* Lets you define [lighting layers](feature_rgblight.md) that can be toggled on or off. Great for showing the current keyboard layer or caps lock state.
|
* Lets you define [lighting layers](feature_rgblight.md?id=lighting-layers) that can be toggled on or off. Great for showing the current keyboard layer or caps lock state.
|
||||||
|
* `#define RGBLIGHT_MAX_LAYERS`
|
||||||
|
* Defaults to 8. Can be expanded up to 32 if more [lighting layers](feature_rgblight.md?id=lighting-layers) are needed.
|
||||||
|
* Note: Increasing the maximum will increase the firmware size and slow sync on split keyboards.
|
||||||
|
* `#define RGBLIGHT_LAYER_BLINK`
|
||||||
|
* Adds ability to [blink](feature_rgblight.md?id=lighting-layer-blink) a lighting layer for a specified number of milliseconds (e.g. to acknowledge an action).
|
||||||
* `#define RGBLED_NUM 12`
|
* `#define RGBLED_NUM 12`
|
||||||
* number of LEDs
|
* number of LEDs
|
||||||
* `#define RGBLIGHT_SPLIT`
|
* `#define RGBLIGHT_SPLIT`
|
||||||
@@ -317,10 +322,10 @@ This is a [make](https://www.gnu.org/software/make/manual/make.html) file that i
|
|||||||
* `LAYOUTS`
|
* `LAYOUTS`
|
||||||
* A list of [layouts](feature_layouts.md) this keyboard supports.
|
* A list of [layouts](feature_layouts.md) this keyboard supports.
|
||||||
* `LINK_TIME_OPTIMIZATION_ENABLE`
|
* `LINK_TIME_OPTIMIZATION_ENABLE`
|
||||||
* Enables Link Time Optimization (`LTO`) when compiling the keyboard. This makes the process take longer, but can significantly reduce the compiled size (and since the firmware is small, the added time is not noticeable). However, this will automatically disable the old Macros and Functions features automatically, as these break when `LTO` is enabled.
|
* Enables Link Time Optimization (LTO) when compiling the keyboard. This makes the process take longer, but it can significantly reduce the compiled size (and since the firmware is small, the added time is not noticeable).
|
||||||
It does this by automatically defining `NO_ACTION_MACRO` and `NO_ACTION_FUNCTION`
|
However, this will automatically disable the legacy TMK Macros and Functions features, as these break when LTO is enabled. It does this by automatically defining `NO_ACTION_MACRO` and `NO_ACTION_FUNCTION`. (Note: This does not affect QMK [Macros](feature_macros.md) and [Layers](feature_layers.md).)
|
||||||
* `LTO_ENABLE`
|
* `LTO_ENABLE`
|
||||||
* It has the same meaning as LINK_TIME_OPTIMIZATION_ENABLE. You can use `LTO_ENABLE` instead of `LINK_TIME_OPTIMIZATION_ENABLE`.
|
* Has the same meaning as `LINK_TIME_OPTIMIZATION_ENABLE`. You can use `LTO_ENABLE` instead of `LINK_TIME_OPTIMIZATION_ENABLE`.
|
||||||
|
|
||||||
## AVR MCU Options
|
## AVR MCU Options
|
||||||
* `MCU = atmega32u4`
|
* `MCU = atmega32u4`
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ I'll say that again because it's important:
|
|||||||
|
|
||||||
!> **MAKE SURE YOU SELECT THE RIGHT VERSION!**
|
!> **MAKE SURE YOU SELECT THE RIGHT VERSION!**
|
||||||
|
|
||||||
If your keyboard has been advertised to be powered by QMK but is not in the list, chances are a developer hasn't gotten to it yet or we haven't had a chance to merge it in yet. File an issue at [qmk_firmware](https://github.com/qmk/qmk_firmware/issues) requesting to support that particular keyboard, if there is no active [Pull Request](https://github.com/qmk/qmk_firmware/pulls?q=is%3Aopen+is%3Apr+label%3Akeyboard) for it. There are also QMK powered keyboards that are in their manufacturer's own github accounts. Double check for that as well. <!-- FIXME(skullydazed): This feels too wordy and I'm not sure we want to encourage these kinds of issues. Also, should we prompt them to bug the manufacutrer? -->
|
If your keyboard has been advertised to be powered by QMK but is not in the list, chances are a developer hasn't gotten to it yet or we haven't had a chance to merge it in yet. File an issue at [qmk_firmware](https://github.com/qmk/qmk_firmware/issues) requesting to support that particular keyboard, if there is no active [Pull Request](https://github.com/qmk/qmk_firmware/pulls?q=is%3Aopen+is%3Apr+label%3Akeyboard) for it. There are also QMK powered keyboards that are in their manufacturer's own GitHub accounts. Double check for that as well. <!-- FIXME(skullydazed): This feels too wordy and I'm not sure we want to encourage these kinds of issues. Also, should we prompt them to bug the manufacutrer? -->
|
||||||
|
|
||||||
## Step 2: Select Your Keyboard Layout
|
## Step 2: Select Your Keyboard Layout
|
||||||
|
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||||||
case KC_ENTER:
|
case KC_ENTER:
|
||||||
// Play a tone when enter is pressed
|
// Play a tone when enter is pressed
|
||||||
if (record->event.pressed) {
|
if (record->event.pressed) {
|
||||||
PLAY_NOTE_ARRAY(tone_qwerty);
|
PLAY_SONG(tone_qwerty);
|
||||||
}
|
}
|
||||||
return true; // Let QMK send the enter press/release events
|
return true; // Let QMK send the enter press/release events
|
||||||
default:
|
default:
|
||||||
@@ -438,7 +438,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||||||
case KC_ENTER:
|
case KC_ENTER:
|
||||||
// Play a tone when enter is pressed
|
// Play a tone when enter is pressed
|
||||||
if (record->event.pressed) {
|
if (record->event.pressed) {
|
||||||
PLAY_NOTE_ARRAY(tone_qwerty);
|
PLAY_SONG(tone_qwerty);
|
||||||
}
|
}
|
||||||
return true; // Let QMK send the enter press/release events
|
return true; // Let QMK send the enter press/release events
|
||||||
case RGB_LYR: // This allows me to use underglow as layer indication, or as normal
|
case RGB_LYR: // This allows me to use underglow as layer indication, or as normal
|
||||||
@@ -486,56 +486,3 @@ And you're done. The RGB layer indication will only work if you want it to. And
|
|||||||
* Keymap: `void eeconfig_init_user(void)`, `uint32_t eeconfig_read_user(void)` and `void eeconfig_update_user(uint32_t val)`
|
* Keymap: `void eeconfig_init_user(void)`, `uint32_t eeconfig_read_user(void)` and `void eeconfig_update_user(uint32_t val)`
|
||||||
|
|
||||||
The `val` is the value of the data that you want to write to EEPROM. And the `eeconfig_read_*` function return a 32 bit (DWORD) value from the EEPROM.
|
The `val` is the value of the data that you want to write to EEPROM. And the `eeconfig_read_*` function return a 32 bit (DWORD) value from the EEPROM.
|
||||||
|
|
||||||
# Custom Tapping Term
|
|
||||||
|
|
||||||
By default, the tapping term and related options (such as `IGNORE_MOD_TAP_INTERRUPT`) are defined globally, and are not configurable by key. For most users, this is perfectly fine. But in some cases, dual function keys would be greatly improved by different timeout behaviors than `LT` keys, or because some keys may be easier to hold than others. Instead of using custom key codes for each, this allows for per key configurable timeout behaviors.
|
|
||||||
|
|
||||||
There are two configurable options to control per-key timeout behaviors:
|
|
||||||
|
|
||||||
- `TAPPING_TERM_PER_KEY`
|
|
||||||
- `IGNORE_MOD_TAP_INTERRUPT_PER_KEY`
|
|
||||||
|
|
||||||
You need to add `#define` lines to your `config.h` for each feature you want.
|
|
||||||
|
|
||||||
```
|
|
||||||
#define TAPPING_TERM_PER_KEY
|
|
||||||
#define IGNORE_MOD_TAP_INTERRUPT_PER_KEY
|
|
||||||
```
|
|
||||||
|
|
||||||
|
|
||||||
## Example `get_tapping_term` Implementation
|
|
||||||
|
|
||||||
To change the `TAPPING_TERM` based on the keycode, you'd want to add something like the following to your `keymap.c` file:
|
|
||||||
|
|
||||||
```c
|
|
||||||
uint16_t get_tapping_term(uint16_t keycode) {
|
|
||||||
switch (keycode) {
|
|
||||||
case SFT_T(KC_SPC):
|
|
||||||
return TAPPING_TERM + 1250;
|
|
||||||
case LT(1, KC_GRV):
|
|
||||||
return 130;
|
|
||||||
default:
|
|
||||||
return TAPPING_TERM;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
## Example `get_ignore_mod_tap_interrupt` Implementation
|
|
||||||
|
|
||||||
To change the `IGNORE_MOD_TAP_INTERRUPT` value based on the keycode, you'd want to add something like the following to your `keymap.c` file:
|
|
||||||
|
|
||||||
```c
|
|
||||||
bool get_ignore_mod_tap_interrupt(uint16_t keycode) {
|
|
||||||
switch (keycode) {
|
|
||||||
case SFT_T(KC_SPC):
|
|
||||||
return true;
|
|
||||||
default:
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
## `get_tapping_term` / `get_ignore_mod_tap_interrupt` Function Documentation
|
|
||||||
|
|
||||||
Unlike many of the other functions here, there isn't a need (or even reason) to have a quantum or keyboard level function. Only user level functions are useful here, so no need to mark them as such.
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ QMK (*Quantum Mechanical Keyboard*) ist eine Open-Source-Community, welche die Q
|
|||||||
|
|
||||||
## Bezugsquelle für QMK
|
## Bezugsquelle für QMK
|
||||||
|
|
||||||
Wenn Du vorhast, deine Tastatur, Tastaturbelegung oder Features zu QMK beizusteuern, geht das am einfachsten, indem Du das [Repository auf Github](https://github.com/qmk/qmk_firmware#fork-destination-box) forkst, die Änderungen in deinem lokalen Repo vornimmst und anschließend einen [Pull Request](https://github.com/qmk/qmk_firmware/pulls) einreichst.
|
Wenn Du vorhast, deine Tastatur, Tastaturbelegung oder Features zu QMK beizusteuern, geht das am einfachsten, indem Du das [Repository auf GitHub](https://github.com/qmk/qmk_firmware#fork-destination-box) forkst, die Änderungen in deinem lokalen Repo vornimmst und anschließend einen [Pull Request](https://github.com/qmk/qmk_firmware/pulls) einreichst.
|
||||||
|
|
||||||
Ansonsten kannst Du es als [zip](https://github.com/qmk/qmk_firmware/zipball/master) oder [tar](https://github.com/qmk/qmk_firmware/tarball/master) herunterladen, oder es direkt via git klonen (`git clone git@github.com:qmk/qmk_firmware.git` bzw. `git clone https://github.com/qmk/qmk_firmware.git`).
|
Ansonsten kannst Du es als [zip](https://github.com/qmk/qmk_firmware/zipball/master) oder [tar](https://github.com/qmk/qmk_firmware/tarball/master) herunterladen, oder es direkt via git klonen (`git clone git@github.com:qmk/qmk_firmware.git` bzw. `git clone https://github.com/qmk/qmk_firmware.git`).
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
* [QMK CLI](de/cli.md)
|
* [QMK CLI](de/cli.md)
|
||||||
* [QMK CLI Konfiguration](de/cli_configuration.md)
|
* [QMK CLI Konfiguration](de/cli_configuration.md)
|
||||||
* [Zu QMK beitragen](de/contributing.md)
|
* [Zu QMK beitragen](de/contributing.md)
|
||||||
* [Anleitung für Github](de/getting_started_github.md)
|
* [Anleitung für GitHub](de/getting_started_github.md)
|
||||||
* [Nach Hilfe fragen](de/getting_started_getting_help.md)
|
* [Nach Hilfe fragen](de/getting_started_getting_help.md)
|
||||||
|
|
||||||
* [Breaking Changes](de/breaking_changes.md)
|
* [Breaking Changes](de/breaking_changes.md)
|
||||||
@@ -98,6 +98,7 @@
|
|||||||
* [ISP Flashing Guide](de/isp_flashing_guide.md)
|
* [ISP Flashing Guide](de/isp_flashing_guide.md)
|
||||||
* [ARM Debugging Guide](de/arm_debugging.md)
|
* [ARM Debugging Guide](de/arm_debugging.md)
|
||||||
* [I2C Driver](de/i2c_driver.md)
|
* [I2C Driver](de/i2c_driver.md)
|
||||||
|
* [SPI Driver](de/spi_driver.md)
|
||||||
* [GPIO Controls](de/internals_gpio_control.md)
|
* [GPIO Controls](de/internals_gpio_control.md)
|
||||||
* [Proton C Conversion](de/proton_c_conversion.md)
|
* [Proton C Conversion](de/proton_c_conversion.md)
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ Git Ressourcen:
|
|||||||
|
|
||||||
* [Gutes allgemeines Tutorial](https://www.codecademy.com/learn/learn-git) (auf Englisch)
|
* [Gutes allgemeines Tutorial](https://www.codecademy.com/learn/learn-git) (auf Englisch)
|
||||||
* [Git spielerisch anhand von Beispielen lernen](https://learngitbranching.js.org/) (auf Englisch)
|
* [Git spielerisch anhand von Beispielen lernen](https://learngitbranching.js.org/) (auf Englisch)
|
||||||
* [Mehr über den allgemeinen Umgang mit Github](getting_started_github.md)
|
* [Mehr über den allgemeinen Umgang mit GitHub](getting_started_github.md)
|
||||||
* [Mehr über Git im Bezug zu QMK](contributing.md)
|
* [Mehr über Git im Bezug zu QMK](contributing.md)
|
||||||
|
|
||||||
Mehr über die Arbeit mit der Befehlszeile:
|
Mehr über die Arbeit mit der Befehlszeile:
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
# EEPROM Driver Configuration
|
# EEPROM Driver Configuration :id=eeprom-driver-configuration
|
||||||
|
|
||||||
The EEPROM driver can be swapped out depending on the needs of the keyboard, or whether extra hardware is present.
|
The EEPROM driver can be swapped out depending on the needs of the keyboard, or whether extra hardware is present.
|
||||||
|
|
||||||
@@ -6,15 +6,20 @@ Driver | Description
|
|||||||
-----------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
-----------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||||
`EEPROM_DRIVER = vendor` (default) | Uses the on-chip driver provided by the chip manufacturer. For AVR, this is provided by avr-libc. This is supported on ARM for a subset of chips -- STM32F3xx, STM32F1xx, and STM32F072xB will be emulated by writing to flash. STM32L0xx and STM32L1xx will use the onboard dedicated true EEPROM. Other chips will generally act as "transient" below.
|
`EEPROM_DRIVER = vendor` (default) | Uses the on-chip driver provided by the chip manufacturer. For AVR, this is provided by avr-libc. This is supported on ARM for a subset of chips -- STM32F3xx, STM32F1xx, and STM32F072xB will be emulated by writing to flash. STM32L0xx and STM32L1xx will use the onboard dedicated true EEPROM. Other chips will generally act as "transient" below.
|
||||||
`EEPROM_DRIVER = i2c` | Supports writing to I2C-based 24xx EEPROM chips. See the driver section below.
|
`EEPROM_DRIVER = i2c` | Supports writing to I2C-based 24xx EEPROM chips. See the driver section below.
|
||||||
|
`EEPROM_DRIVER = spi` | Supports writing to SPI-based 25xx EEPROM chips. See the driver section below.
|
||||||
`EEPROM_DRIVER = transient` | Fake EEPROM driver -- supports reading/writing to RAM, and will be discarded when power is lost.
|
`EEPROM_DRIVER = transient` | Fake EEPROM driver -- supports reading/writing to RAM, and will be discarded when power is lost.
|
||||||
|
|
||||||
## Vendor Driver Configuration
|
## Vendor Driver Configuration :id=vendor-eeprom-driver-configuration
|
||||||
|
|
||||||
|
#### STM32 L0/L1 Configuration :id=stm32l0l1-eeprom-driver-configuration
|
||||||
|
|
||||||
!> Resetting EEPROM using an STM32L0/L1 device takes up to 1 second for every 1kB of internal EEPROM used.
|
!> Resetting EEPROM using an STM32L0/L1 device takes up to 1 second for every 1kB of internal EEPROM used.
|
||||||
|
|
||||||
No configurable options are available.
|
`config.h` override | Description | Default Value
|
||||||
|
------------------------------------|--------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------
|
||||||
|
`#define STM32_ONBOARD_EEPROM_SIZE` | The size of the EEPROM to use, in bytes. Erase times can be high, so it's configurable here, if not using the default value. | Minimum required to cover base _eeconfig_ data, or `1024` if VIA is enabled.
|
||||||
|
|
||||||
## I2C Driver Configuration
|
## I2C Driver Configuration :id=i2c-eeprom-driver-configuration
|
||||||
|
|
||||||
Currently QMK supports 24xx-series chips over I2C. As such, requires a working i2c_master driver configuration. You can override the driver configuration via your config.h:
|
Currently QMK supports 24xx-series chips over I2C. As such, requires a working i2c_master driver configuration. You can override the driver configuration via your config.h:
|
||||||
|
|
||||||
@@ -41,7 +46,21 @@ MB85RC256V FRAM | `#define EEPROM_I2C_MB85RC256V` | <https://www.adafruit.com/p
|
|||||||
|
|
||||||
?> If you find that the EEPROM is not cooperating, ensure you've correctly shifted up your EEPROM address by 1. For example, the datasheet might state the address as `0b01010000` -- the correct value of `EXTERNAL_EEPROM_I2C_BASE_ADDRESS` needs to be `0b10100000`.
|
?> If you find that the EEPROM is not cooperating, ensure you've correctly shifted up your EEPROM address by 1. For example, the datasheet might state the address as `0b01010000` -- the correct value of `EXTERNAL_EEPROM_I2C_BASE_ADDRESS` needs to be `0b10100000`.
|
||||||
|
|
||||||
## Transient Driver configuration
|
## SPI Driver Configuration :id=spi-eeprom-driver-configuration
|
||||||
|
|
||||||
|
Currently QMK supports 25xx-series chips over SPI. As such, requires a working spi_master driver configuration. You can override the driver configuration via your config.h:
|
||||||
|
|
||||||
|
`config.h` override | Description | Default Value
|
||||||
|
-----------------------------------------------|--------------------------------------------------------------------------------------|--------------
|
||||||
|
`#define EXTERNAL_EEPROM_SPI_SLAVE_SELECT_PIN` | SPI Slave select pin in order to inform that the EEPROM is currently being addressed | _none_
|
||||||
|
`#define EXTERNAL_EEPROM_SPI_CLOCK_DIVISOR` | Clock divisor used to divide the peripheral clock to derive the SPI frequency | `64`
|
||||||
|
`#define EXTERNAL_EEPROM_BYTE_COUNT` | Total size of the EEPROM in bytes | 8192
|
||||||
|
`#define EXTERNAL_EEPROM_PAGE_SIZE` | Page size of the EEPROM in bytes, as specified in the datasheet | 32
|
||||||
|
`#define EXTERNAL_EEPROM_ADDRESS_SIZE` | The number of bytes to transmit for the memory location within the EEPROM | 2
|
||||||
|
|
||||||
|
!> There's no way to determine if there is an SPI EEPROM actually responding. Generally, this will result in reads of nothing but zero.
|
||||||
|
|
||||||
|
## Transient Driver configuration :id=transient-eeprom-driver-configuration
|
||||||
|
|
||||||
The only configurable item for the transient EEPROM driver is its size:
|
The only configurable item for the transient EEPROM driver is its size:
|
||||||
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ QMK (*Quantum Mechanical Keyboard*) es una comunidad open source que mantiene el
|
|||||||
|
|
||||||
## Cómo conseguirlo
|
## Cómo conseguirlo
|
||||||
|
|
||||||
Si estás pensando en contribuir con un keymap, teclado, or característica a QMK, la manera más sencilla es hacer un [fork del repositorio en Github](https://github.com/qmk/qmk_firmware#fork-destination-box), y clonar tu repositorio localmente para hacer los cambios, subirlos, y abir un [Pull Request](https://github.com/qmk/qmk_firmware/pulls) desde tu fork.
|
Si estás pensando en contribuir con un keymap, teclado, or característica a QMK, la manera más sencilla es hacer un [fork del repositorio en GitHub](https://github.com/qmk/qmk_firmware#fork-destination-box), y clonar tu repositorio localmente para hacer los cambios, subirlos, y abir un [Pull Request](https://github.com/qmk/qmk_firmware/pulls) desde tu fork.
|
||||||
|
|
||||||
De cualquier manera, también puedes descargarlo directamente en formatos ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), o clonarlo via git (`git@github.com:qmk/qmk_firmware.git`), o https (`https://github.com/qmk/qmk_firmware.git`).
|
De cualquier manera, también puedes descargarlo directamente en formatos ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), o clonarlo via git (`git@github.com:qmk/qmk_firmware.git`), o https (`https://github.com/qmk/qmk_firmware.git`).
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
* [QMK CLI](es/cli.md)
|
* [QMK CLI](es/cli.md)
|
||||||
* [Configuración de QMK CLI](es/cli_configuration.md)
|
* [Configuración de QMK CLI](es/cli_configuration.md)
|
||||||
* [Contribuyendo a QMK](es/contributing.md)
|
* [Contribuyendo a QMK](es/contributing.md)
|
||||||
* [Cómo usar Github](es/getting_started_github.md)
|
* [Cómo usar GitHub](es/getting_started_github.md)
|
||||||
* [Obtener ayuda](es/getting_started_getting_help.md)
|
* [Obtener ayuda](es/getting_started_getting_help.md)
|
||||||
|
|
||||||
* [Cambios incompatibles](es/breaking_changes.md)
|
* [Cambios incompatibles](es/breaking_changes.md)
|
||||||
@@ -98,6 +98,7 @@
|
|||||||
* [Guía de flasheado de ISP](es/isp_flashing_guide.md)
|
* [Guía de flasheado de ISP](es/isp_flashing_guide.md)
|
||||||
* [Guía de depuración de ARM](es/arm_debugging.md)
|
* [Guía de depuración de ARM](es/arm_debugging.md)
|
||||||
* [Driver I2C](es/i2c_driver.md)
|
* [Driver I2C](es/i2c_driver.md)
|
||||||
|
* [Driver SPI](es/spi_driver.md)
|
||||||
* [Controles GPIO](es/internals_gpio_control.md)
|
* [Controles GPIO](es/internals_gpio_control.md)
|
||||||
* [Conversión Proton C](es/proton_c_conversion.md)
|
* [Conversión Proton C](es/proton_c_conversion.md)
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ Este documento procura instruir a los novatos en las mejores prácticas para ten
|
|||||||
|
|
||||||
En este documento suponemos un par de cosas:
|
En este documento suponemos un par de cosas:
|
||||||
|
|
||||||
1. Tienes una cuenta de Github, y has hecho un [fork del repo qmk_firmware](getting_started_github.md) en tu cuenta.
|
1. Tienes una cuenta de GitHub, y has hecho un [fork del repo qmk_firmware](getting_started_github.md) en tu cuenta.
|
||||||
2. Has [configurado tu entorno de desarrollo](newbs_getting_started.md?id=environment-setup).
|
2. Has [configurado tu entorno de desarrollo](newbs_getting_started.md?id=environment-setup).
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ Lo diré otra vez porque es importante
|
|||||||
|
|
||||||
!> **ASEGÚRATE DE QUE SELECCIONAS LA VERSIÓN CORRECTA!**
|
!> **ASEGÚRATE DE QUE SELECCIONAS LA VERSIÓN CORRECTA!**
|
||||||
|
|
||||||
Si se ha anunciado que tu teclado funciona con QMK pero no está en la lista, es probable que un desarrollador no se haya encargado de él aún o que todavía no hemos tenido la oportunidad de incluirlo. Abre un issue en [qmk_firmware](https://github.com/qmk/qmk_firmware/issues) solicitando soportar ese teclado un particular, si no hay un [Pull Request](https://github.com/qmk/qmk_firmware/pulls?q=is%3Aopen+is%3Apr+label%3Akeyboard) activo para ello. Hay también teclados que funcionan con QMK que están en las cuentas de github de sus manufacturantes. Acuérdate de comprobar esto también.
|
Si se ha anunciado que tu teclado funciona con QMK pero no está en la lista, es probable que un desarrollador no se haya encargado de él aún o que todavía no hemos tenido la oportunidad de incluirlo. Abre un issue en [qmk_firmware](https://github.com/qmk/qmk_firmware/issues) solicitando soportar ese teclado un particular, si no hay un [Pull Request](https://github.com/qmk/qmk_firmware/pulls?q=is%3Aopen+is%3Apr+label%3Akeyboard) activo para ello. Hay también teclados que funcionan con QMK que están en las cuentas de GitHub de sus manufacturantes. Acuérdate de comprobar esto también.
|
||||||
|
|
||||||
## Eligiendo el layout de tu teclado
|
## Eligiendo el layout de tu teclado
|
||||||
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ Recursos de Git:
|
|||||||
|
|
||||||
* [Excelente tutorial general](https://www.codecademy.com/learn/learn-git)
|
* [Excelente tutorial general](https://www.codecademy.com/learn/learn-git)
|
||||||
* [Juego de Git para aprender usando ejemplos](https://learngitbranching.js.org/)
|
* [Juego de Git para aprender usando ejemplos](https://learngitbranching.js.org/)
|
||||||
* [Recursos de Git para aprender más sobre Github](getting_started_github.md)
|
* [Recursos de Git para aprender más sobre GitHub](getting_started_github.md)
|
||||||
* [Recursos de Git dirigidos específicamente a QMK](contributing.md)
|
* [Recursos de Git dirigidos específicamente a QMK](contributing.md)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -113,26 +113,16 @@ OPT_DEFS += -DBOOTLOADER_SIZE=2048
|
|||||||
```
|
```
|
||||||
|
|
||||||
## `avr-gcc: internal compiler error: Abort trap: 6 (program cc1)` on MacOS
|
## `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.
|
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.
|
The solution is to remove and reinstall all affected modules.
|
||||||
|
|
||||||
```
|
```
|
||||||
brew rm avr-gcc
|
brew rm avr-gcc avr-gcc@8 dfu-programmer dfu-util gcc-arm-none-eabi arm-gcc-bin@8 avrdude qmk
|
||||||
brew rm avr-gcc@8
|
brew install qmk/qmk/qmk
|
||||||
brew rm dfu-programmer
|
|
||||||
brew rm dfu-util
|
|
||||||
brew rm gcc-arm-none-eabi
|
|
||||||
brew rm arm-gcc-bin@8
|
|
||||||
brew rm avrdude
|
|
||||||
brew install avr-gcc@8
|
|
||||||
brew install dfu-programmer
|
|
||||||
brew install dfu-util
|
|
||||||
brew install arm-gcc-bin@8
|
|
||||||
brew install avrdude
|
|
||||||
brew link --force avr-gcc@8
|
brew link --force avr-gcc@8
|
||||||
brew link --force arm-gcc-bin@8
|
brew link --force arm-gcc-bin@8
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
### `avr-gcc` and LUFA
|
### `avr-gcc` and LUFA
|
||||||
|
|||||||
@@ -160,10 +160,3 @@ As of now root of its cause is not clear but some build options seem to be relat
|
|||||||
|
|
||||||
https://github.com/tmk/tmk_keyboard/issues/266
|
https://github.com/tmk/tmk_keyboard/issues/266
|
||||||
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
|
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## FLIP Doesn't Work
|
|
||||||
### `AtLibUsbDfu.dll` Not Found
|
|
||||||
Remove current driver and reinstall one FLIP provides from DeviceManager.
|
|
||||||
http://imgur.com/a/bnwzy
|
|
||||||
|
|||||||
@@ -6,11 +6,11 @@ These allow you to combine a modifier with a keycode. When pressed, the keydown
|
|||||||
|----------|-------------------------------|----------------------------------------------------|
|
|----------|-------------------------------|----------------------------------------------------|
|
||||||
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|
|`LCTL(kc)`|`C(kc)` |Hold Left Control and press `kc` |
|
||||||
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|
|`LSFT(kc)`|`S(kc)` |Hold Left Shift and press `kc` |
|
||||||
|`LALT(kc)`|`A(kc)` |Hold Left Alt 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` |
|
|`LGUI(kc)`|`G(kc)`, `LCMD(kc)`, `LWIN(kc)`|Hold Left GUI and press `kc` |
|
||||||
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|
|`RCTL(kc)`| |Hold Right Control and press `kc` |
|
||||||
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|
|`RSFT(kc)`| |Hold Right Shift and press `kc` |
|
||||||
|`RALT(kc)`|`ALGR(kc)` |Hold Right Alt 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` |
|
|`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` |
|
|`SGUI(kc)`|`SCMD(kc)`, `SWIN(kc)` |Hold Left Shift and GUI and press `kc` |
|
||||||
|`LCA(kc)` | |Hold Left Control and Alt and press `kc` |
|
|`LCA(kc)` | |Hold Left Control and Alt and press `kc` |
|
||||||
@@ -18,7 +18,7 @@ These allow you to combine a modifier with a keycode. When pressed, the keydown
|
|||||||
|`MEH(kc)` | |Hold Left Control, Shift and Alt 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`|
|
|`HYPR(kc)`| |Hold Left Control, Shift, Alt and GUI and press `kc`|
|
||||||
|
|
||||||
You can also chain them, for example `LCTL(LALT(KC_DEL))` makes a key that sends Control+Alt+Delete with a single keypress.
|
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.
|
||||||
|
|
||||||
# Legacy Content :id=legacy-content
|
# Legacy Content :id=legacy-content
|
||||||
|
|
||||||
|
|||||||
@@ -38,5 +38,6 @@ For use in keyboards where refreshing ```NUM_KEYS``` 8-bit counters is computati
|
|||||||
appropriate for the ErgoDox models; the matrix is rotated 90°, and hence its "rows" are really columns, and each finger only hits a single "row" at a time in normal use.
|
appropriate for the ErgoDox models; the matrix is rotated 90°, and hence its "rows" are really columns, and each finger only hits a single "row" at a time in normal use.
|
||||||
* eager_pk - debouncing per key. On any state change, response is immediate, followed by ```DEBOUNCE``` milliseconds of no further input for that key
|
* eager_pk - debouncing per key. On any state change, response is immediate, followed by ```DEBOUNCE``` milliseconds of no further input for that key
|
||||||
* sym_g - debouncing per keyboard. On any state change, a global timer is set. When ```DEBOUNCE``` milliseconds of no changes has occured, all input changes are pushed.
|
* sym_g - debouncing per keyboard. On any state change, a global timer is set. When ```DEBOUNCE``` milliseconds of no changes has occured, all input changes are pushed.
|
||||||
|
* sym_pk - debouncing per key. On any state change, a per-key timer is set. When ```DEBOUNCE``` milliseconds of no changes have occured on that key, the key status change is pushed.
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ void encoder_update_user(uint8_t index, bool clockwise) {
|
|||||||
} else {
|
} else {
|
||||||
tap_code(KC_PGUP);
|
tap_code(KC_PGUP);
|
||||||
}
|
}
|
||||||
} else if (index == 1) { /* Second encoder */
|
} else if (index == 1) { /* Second encoder */
|
||||||
if (clockwise) {
|
if (clockwise) {
|
||||||
tap_code(KC_DOWN);
|
tap_code(KC_DOWN);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# HD44780 LCD Displays
|
# HD44780 LCD Displays
|
||||||
|
|
||||||
This is an integration of Peter Fleury's LCD library. This page will explain the basics. [For in depth documentation visit his page.](http://homepage.hispeed.ch/peterfleury/doxygen/avr-gcc-libraries/group__pfleury__lcd.html)
|
This is an integration of Peter Fleury's LCD library. This page will explain the basics. [For in depth documentation visit his page.](http://www.peterfleury.epizy.com/doxygen/avr-gcc-libraries/group__pfleury__lcd.html)
|
||||||
|
|
||||||
You can enable support for HD44780 Displays by setting the `HD44780_ENABLE` flag in your keyboards `rules.mk` to yes.
|
You can enable support for HD44780 Displays by setting the `HD44780_ENABLE` flag in your keyboards `rules.mk` to yes.
|
||||||
|
|
||||||
@@ -50,8 +50,8 @@ LCD_DISP_ON_CURSOR_BLINK : display on, cursor on flashing
|
|||||||
````
|
````
|
||||||
This is best done in your keyboards `matrix_init_kb` or your keymaps `matrix_init_user`.
|
This is best done in your keyboards `matrix_init_kb` or your keymaps `matrix_init_user`.
|
||||||
It is advised to clear the display before use.
|
It is advised to clear the display before use.
|
||||||
To do so call `lcd_clrsrc()`.
|
To do so call `lcd_clrscr()`.
|
||||||
|
|
||||||
To now print something to your Display you first call `lcd_gotoxy(column, line)`. To go to the start of the first line you would call `lcd_gotoxy(0, 0)` and then print a string with `lcd_puts("example string")`.
|
To now print something to your Display you first call `lcd_gotoxy(column, line)`. To go to the start of the first line you would call `lcd_gotoxy(0, 0)` and then print a string with `lcd_puts("example string")`.
|
||||||
|
|
||||||
There are more methods available to control the display. [For in depth documentation please visit the linked page.](http://homepage.hispeed.ch/peterfleury/doxygen/avr-gcc-libraries/group__pfleury__lcd.html)
|
There are more methods available to control the display. [For in depth documentation please visit the linked page.](http://www.peterfleury.epizy.com/doxygen/avr-gcc-libraries/group__pfleury__lcd.html)
|
||||||
|
|||||||
@@ -161,11 +161,11 @@ There's also a couple of mod shortcuts you can use:
|
|||||||
|
|
||||||
* `SS_LCTL(string)`
|
* `SS_LCTL(string)`
|
||||||
* `SS_LSFT(string)`
|
* `SS_LSFT(string)`
|
||||||
* `SS_LALT(string)`
|
* `SS_LALT(string)` or `SS_LOPT(string)`
|
||||||
* `SS_LGUI(string)`, `SS_LCMD(string)` or `SS_LWIN(string)`
|
* `SS_LGUI(string)`, `SS_LCMD(string)` or `SS_LWIN(string)`
|
||||||
* `SS_RCTL(string)`
|
* `SS_RCTL(string)`
|
||||||
* `SS_RSFT(string)`
|
* `SS_RSFT(string)`
|
||||||
* `SS_RALT(string)` or `SS_ALGR(string)`
|
* `SS_RALT(string)`, `SS_ROPT(string)` or `SS_ALGR(string)`
|
||||||
* `SS_RGUI(string)`, `SS_RCMD(string)` or `SS_RWIN(string)`
|
* `SS_RGUI(string)`, `SS_RCMD(string)` or `SS_RWIN(string)`
|
||||||
|
|
||||||
These press the respective modifier, send the supplied string and then release the modifier.
|
These press the respective modifier, send the supplied string and then release the modifier.
|
||||||
|
|||||||
@@ -27,20 +27,17 @@ In the following example, a custom key is used to click the mouse and scroll 127
|
|||||||
|
|
||||||
```c
|
```c
|
||||||
case MS_SPECIAL:
|
case MS_SPECIAL:
|
||||||
report_mouse_t currentReport = pointing_device_get_report();
|
report_mouse_t currentReport = pointing_device_get_report();
|
||||||
if (record->event.pressed)
|
if (record->event.pressed) {
|
||||||
{
|
|
||||||
currentReport.v = 127;
|
currentReport.v = 127;
|
||||||
currentReport.h = 127;
|
currentReport.h = 127;
|
||||||
currentReport.buttons |= MOUSE_BTN1; //this is defined in report.h
|
currentReport.buttons |= MOUSE_BTN1; // this is defined in report.h
|
||||||
}
|
} else {
|
||||||
else
|
|
||||||
{
|
|
||||||
currentReport.v = -127;
|
currentReport.v = -127;
|
||||||
currentReport.h = -127;
|
currentReport.h = -127;
|
||||||
currentReport.buttons &= ~MOUSE_BTN1;
|
currentReport.buttons &= ~MOUSE_BTN1;
|
||||||
}
|
}
|
||||||
pointing_device_set_report(currentReport);
|
pointing_device_set_report(currentReport);
|
||||||
break;
|
break;
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
@@ -266,6 +266,25 @@ To reverse the scroll axes you can put:
|
|||||||
|
|
||||||
into config.h.
|
into config.h.
|
||||||
|
|
||||||
|
### Rotate Mouse Axes :id=rotate-mouse-axes
|
||||||
|
|
||||||
|
Transform the output of the device with a clockwise rotation of 90, 180, or 270
|
||||||
|
degrees.
|
||||||
|
|
||||||
|
When compensating for device orientation, rotate the output the same amount in
|
||||||
|
the opposite direction. E.g. if the normal device orientation is considered to
|
||||||
|
be North-facing, compensate as follows:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define PS2_MOUSE_ROTATE 270 /* Compensate for East-facing device orientation. */
|
||||||
|
```
|
||||||
|
```c
|
||||||
|
#define PS2_MOUSE_ROTATE 180 /* Compensate for South-facing device orientation. */
|
||||||
|
```
|
||||||
|
```c
|
||||||
|
#define PS2_MOUSE_ROTATE 90 /* Compensate for West-facing device orientation. */
|
||||||
|
```
|
||||||
|
|
||||||
### Debug Settings :id=debug-settings
|
### Debug Settings :id=debug-settings
|
||||||
|
|
||||||
To debug the mouse, add `debug_mouse = true` or enable via bootmagic.
|
To debug the mouse, add `debug_mouse = true` or enable via bootmagic.
|
||||||
|
|||||||
69
docs/feature_rawhid.md
Normal file
69
docs/feature_rawhid.md
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
# Raw HID
|
||||||
|
|
||||||
|
Raw HID allows for bidirectional communication between QMK and the host computer over an HID interface. This has many potential use cases, such as switching keymaps on the fly or changing RGB LED colors and modes.
|
||||||
|
|
||||||
|
There are two main components to getting raw HID working with your keyboard.
|
||||||
|
|
||||||
|
## Keyboard firmware
|
||||||
|
|
||||||
|
The implementation is fairly straightforward for the firmware.
|
||||||
|
In your `rules.mk` add:
|
||||||
|
|
||||||
|
```make
|
||||||
|
RAW_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
In your `keymap.c` include `"raw_hid.h"` and implement the following:
|
||||||
|
|
||||||
|
```C
|
||||||
|
void raw_hid_receive(uint8_t *data, uint8_t length) {
|
||||||
|
// Your code goes here. data is the packet received from host.
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The `"raw_hid.h"` header also declares `void raw_hid_send(uint8_t *data, uint8_t length);` which allows sending packets from keyboard to host. As an example, it can also be used for debugging when building your host application by returning all data back to the host.
|
||||||
|
|
||||||
|
```C
|
||||||
|
void raw_hid_receive(uint8_t *data, uint8_t length) {
|
||||||
|
raw_hid_send(data, length);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
`raw_hid_receive` can receive variable size packets from host with maximum length `RAW_EPSIZE`. `raw_hid_send` on the other hand can send packets to host of exactly `RAW_EPSIZE` length, therefore it should be used with data of length `RAW_EPSIZE`.
|
||||||
|
|
||||||
|
Make sure to flash raw enabled firmware before proceeding with working on the host side.
|
||||||
|
|
||||||
|
## Host (Windows/macOS/Linux)
|
||||||
|
|
||||||
|
This is the more complicated part as it will require some digging.
|
||||||
|
|
||||||
|
To connect your host computer to your keyboard with raw HID you need four pieces of information about your keyboard:
|
||||||
|
|
||||||
|
1. Vendor ID
|
||||||
|
2. Product ID
|
||||||
|
3. Usage Page
|
||||||
|
4. Usage
|
||||||
|
|
||||||
|
The first two can easily be found in your keyboard's `config.h` in the keyboard's main directory under `VENDOR_ID` and `PRODUCT_ID`.
|
||||||
|
|
||||||
|
The final two can be overridden in your keyboard's `config.h` in the keyboard's main directory by redefining the values: `#define RAW_USAGE_PAGE 0xFF60` and `#define RAW_USAGE_ID 0x61`.
|
||||||
|
|
||||||
|
By default, **Usage Page** is `0xFF60` and **Usage** is `0x61`.
|
||||||
|
|
||||||
|
### Building your host
|
||||||
|
|
||||||
|
You can build your host using any language that has an available HID implementation library if you don't wish to make your own. The ones we know of for popular languages are:
|
||||||
|
|
||||||
|
* Node: [node-hid](https://github.com/node-hid/node-hid).
|
||||||
|
* C: [hidapi](https://github.com/libusb/hidapi).
|
||||||
|
* Java: [purejavahidapi](https://github.com/nyholku/purejavahidapi) and [hid4java](https://github.com/gary-rowe/hid4java).
|
||||||
|
* Python: [pyhidapi](https://pypi.org/project/hid/).
|
||||||
|
|
||||||
|
This is not an exhaustive cross-platform list but should get you started. There are no special requirements for using raw HID so any HID library should work.
|
||||||
|
|
||||||
|
Now that you have all four pieces of information required to open HID interface to your keyboard. All you need to do is use your library's available functions to open the device with its ID parameters.
|
||||||
|
|
||||||
|
Note that Vendor ID and Product ID are not actually required to open the device. They are used only to filter to a specific device out of the many HID devices you have plugged in. Many libraries will give you the option to open the device using Product Name or Manufacturer Name instead, `node-hid` being a prime example. This will create issues for devices with builtin USB Hub or any extra HID interfaces where you will have multiple interfaces with the same name or from the same manufacturer. The Vendor ID together with Product ID create a unique designation to a single interface and will not exhibit this problem. Therefore, even if your library doesn't require you to, it is best to use them to avoid issues.
|
||||||
|
Unlike Vendor ID and Product ID though, Usage Page and Usage are necessary for successful communication.
|
||||||
|
|
||||||
|
It should go without saying that regardless of the library you're using, you should always make sure to close the interface when finished. Depending on the operating system and your particular environment there may be issues connecting to it again afterwards with another client or another instance of the same client if it's not explicitly closed.
|
||||||
@@ -374,7 +374,8 @@ These are defined in [`rgblight_list.h`](https://github.com/qmk/qmk_firmware/blo
|
|||||||
```c
|
```c
|
||||||
#define RGB_MATRIX_KEYPRESSES // reacts to keypresses
|
#define RGB_MATRIX_KEYPRESSES // reacts to keypresses
|
||||||
#define RGB_MATRIX_KEYRELEASES // reacts to keyreleases (instead of keypresses)
|
#define RGB_MATRIX_KEYRELEASES // reacts to keyreleases (instead of keypresses)
|
||||||
#define RGB_DISABLE_AFTER_TIMEOUT 0 // number of ticks to wait until disabling effects
|
#define RGB_DISABLE_TIMEOUT 0 // number of milliseconds to wait until rgb automatically turns off
|
||||||
|
#define RGB_DISABLE_AFTER_TIMEOUT 0 // OBSOLETE: number of ticks to wait until disabling effects
|
||||||
#define RGB_DISABLE_WHEN_USB_SUSPENDED false // turn off effects when suspended
|
#define RGB_DISABLE_WHEN_USB_SUSPENDED false // turn off effects when suspended
|
||||||
#define RGB_MATRIX_LED_PROCESS_LIMIT (DRIVER_LED_TOTAL + 4) / 5 // limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)
|
#define RGB_MATRIX_LED_PROCESS_LIMIT (DRIVER_LED_TOTAL + 4) / 5 // limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)
|
||||||
#define RGB_MATRIX_LED_FLUSH_LIMIT 16 // limits in milliseconds how frequently an animation will update the LEDs. 16 (16ms) is equivalent to limiting to 60fps (increases keyboard responsiveness)
|
#define RGB_MATRIX_LED_FLUSH_LIMIT 16 // limits in milliseconds how frequently an animation will update the LEDs. 16 (16ms) is equivalent to limiting to 60fps (increases keyboard responsiveness)
|
||||||
@@ -437,12 +438,16 @@ Where `28` is an unused index from `eeconfig.h`.
|
|||||||
|`rgb_matrix_sethsv_noeeprom(h, s, v)` |Set LEDs to the given HSV value where `h`/`s`/`v` are between 0 and 255 (not written to EEPROM) |
|
|`rgb_matrix_sethsv_noeeprom(h, s, v)` |Set LEDs to the given HSV value where `h`/`s`/`v` are between 0 and 255 (not written to EEPROM) |
|
||||||
|
|
||||||
### Query Current Status :id=query-current-status
|
### Query Current Status :id=query-current-status
|
||||||
|Function |Description |
|
|Function |Description |
|
||||||
|-----------------------|-----------------|
|
|---------------------------------|---------------------------|
|
||||||
|`rgb_matrix_get_mode()` |Get current mode |
|
|`rgb_matrix_is_enabled()` |Gets current on/off status |
|
||||||
|`rgb_matrix_get_hue()` |Get current hue |
|
|`rgb_matrix_get_mode()` |Gets current mode |
|
||||||
|`rgb_matrix_get_sat()` |Get current sat |
|
|`rgb_matrix_get_hue()` |Gets current hue |
|
||||||
|`rgb_matrix_get_val()` |Get current val |
|
|`rgb_matrix_get_sat()` |Gets current sat |
|
||||||
|
|`rgb_matrix_get_val()` |Gets current val |
|
||||||
|
|`rgb_matrix_get_hsv()` |Gets hue, sat, and val and returns a [`HSV` structure](https://github.com/qmk/qmk_firmware/blob/7ba6456c0b2e041bb9f97dbed265c5b8b4b12192/quantum/color.h#L56-L61)|
|
||||||
|
|`rgb_matrix_get_speed()` |Gets current speed |
|
||||||
|
|`rgb_matrix_get_suspend_state()` |Gets current suspend state |
|
||||||
|
|
||||||
## Callbacks :id=callbacks
|
## Callbacks :id=callbacks
|
||||||
|
|
||||||
|
|||||||
@@ -94,6 +94,7 @@ if `RGBLIGHT_EFFECT_xxxx` or `RGBLIGHT_ANIMATIONS` is defined, you also have a n
|
|||||||
|`RGBLIGHT_MODE_STATIC_GRADIENT`| 0,1,..,9 |Static gradient |
|
|`RGBLIGHT_MODE_STATIC_GRADIENT`| 0,1,..,9 |Static gradient |
|
||||||
|`RGBLIGHT_MODE_RGB_TEST` | *None* |RGB Test |
|
|`RGBLIGHT_MODE_RGB_TEST` | *None* |RGB Test |
|
||||||
|`RGBLIGHT_MODE_ALTERNATING` | *None* |Alternating |
|
|`RGBLIGHT_MODE_ALTERNATING` | *None* |Alternating |
|
||||||
|
|`RGBLIGHT_MODE_TWINKLE` | 0,1,2,3,4,5 |Twinkle |
|
||||||
|
|
||||||
Check out [this video](https://youtube.com/watch?v=VKrpPAHlisY) for a demonstration.
|
Check out [this video](https://youtube.com/watch?v=VKrpPAHlisY) for a demonstration.
|
||||||
|
|
||||||
@@ -103,8 +104,8 @@ Note: For versions older than 0.6.117, The mode numbers were written directly. I
|
|||||||
|
|
||||||
Use these defines to add or remove animations from the firmware. When you are running low on flash space, it can be helpful to disable animations you are not using.
|
Use these defines to add or remove animations from the firmware. When you are running low on flash space, it can be helpful to disable animations you are not using.
|
||||||
|
|
||||||
|Define |Default |Description |
|
|Define |Default |Description |
|
||||||
|------------------------------------|-------------|-------------------------------------------------------------------------------------|
|
|------------------------------------|-------------|-------------------------------------------------------------------------|
|
||||||
|`RGBLIGHT_ANIMATIONS` |*Not defined*|Enable all additional animation modes. |
|
|`RGBLIGHT_ANIMATIONS` |*Not defined*|Enable all additional animation modes. |
|
||||||
|`RGBLIGHT_EFFECT_ALTERNATING` |*Not defined*|Enable alternating animation mode. |
|
|`RGBLIGHT_EFFECT_ALTERNATING` |*Not defined*|Enable alternating animation mode. |
|
||||||
|`RGBLIGHT_EFFECT_BREATHING` |*Not defined*|Enable breathing animation mode. |
|
|`RGBLIGHT_EFFECT_BREATHING` |*Not defined*|Enable breathing animation mode. |
|
||||||
@@ -115,6 +116,7 @@ Use these defines to add or remove animations from the firmware. When you are ru
|
|||||||
|`RGBLIGHT_EFFECT_RGB_TEST` |*Not defined*|Enable RGB test animation mode. |
|
|`RGBLIGHT_EFFECT_RGB_TEST` |*Not defined*|Enable RGB test animation mode. |
|
||||||
|`RGBLIGHT_EFFECT_SNAKE` |*Not defined*|Enable snake animation mode. |
|
|`RGBLIGHT_EFFECT_SNAKE` |*Not defined*|Enable snake animation mode. |
|
||||||
|`RGBLIGHT_EFFECT_STATIC_GRADIENT` |*Not defined*|Enable static gradient mode. |
|
|`RGBLIGHT_EFFECT_STATIC_GRADIENT` |*Not defined*|Enable static gradient mode. |
|
||||||
|
|`RGBLIGHT_EFFECT_TWINKLE` |*Not defined*|Enable twinkle animation mode. |
|
||||||
|
|
||||||
### Effect and Animation Settings
|
### Effect and Animation Settings
|
||||||
|
|
||||||
@@ -131,6 +133,8 @@ The following options are used to tweak the various animations:
|
|||||||
|`RGBLIGHT_EFFECT_KNIGHT_OFFSET` |`0` |The number of LEDs to start the "Knight" animation from the start of the strip by |
|
|`RGBLIGHT_EFFECT_KNIGHT_OFFSET` |`0` |The number of LEDs to start the "Knight" animation from the start of the strip by |
|
||||||
|`RGBLIGHT_RAINBOW_SWIRL_RANGE` |`255` |Range adjustment for the rainbow swirl effect to get different swirls |
|
|`RGBLIGHT_RAINBOW_SWIRL_RANGE` |`255` |Range adjustment for the rainbow swirl effect to get different swirls |
|
||||||
|`RGBLIGHT_EFFECT_SNAKE_LENGTH` |`4` |The number of LEDs to light up for the "Snake" animation |
|
|`RGBLIGHT_EFFECT_SNAKE_LENGTH` |`4` |The number of LEDs to light up for the "Snake" animation |
|
||||||
|
|`RGBLIGHT_EFFECT_TWINKLE_LIFE` |`75` |Adjusts how quickly each LED brightens and dims when twinkling (in animation steps) |
|
||||||
|
|`RGBLIGHT_EFFECT_TWINKLE_PROBABILITY`|`1/127` |Adjusts how likely each LED is to twinkle (on each animation step) |
|
||||||
|
|
||||||
### Example Usage to Reduce Memory Footprint
|
### Example Usage to Reduce Memory Footprint
|
||||||
1. Remove `RGBLIGHT_ANIMATIONS` from `config.h`.
|
1. Remove `RGBLIGHT_ANIMATIONS` from `config.h`.
|
||||||
@@ -168,6 +172,9 @@ const uint8_t RGBLED_SNAKE_INTERVALS[] PROGMEM = {100, 50, 20};
|
|||||||
// How long (in milliseconds) to wait between animation steps for each of the "Knight" animations
|
// How long (in milliseconds) to wait between animation steps for each of the "Knight" animations
|
||||||
const uint8_t RGBLED_KNIGHT_INTERVALS[] PROGMEM = {127, 63, 31};
|
const uint8_t RGBLED_KNIGHT_INTERVALS[] PROGMEM = {127, 63, 31};
|
||||||
|
|
||||||
|
// How long (in milliseconds) to wait between animation steps for each of the "Twinkle" animations
|
||||||
|
const uint8_t RGBLED_TWINKLE_INTERVALS[] PROGMEM = {50, 25, 10};
|
||||||
|
|
||||||
// These control which hues are selected for each of the "Static gradient" modes
|
// These control which hues are selected for each of the "Static gradient" modes
|
||||||
const uint8_t RGBLED_GRADIENT_RANGES[] PROGMEM = {255, 170, 127, 85, 64};
|
const uint8_t RGBLED_GRADIENT_RANGES[] PROGMEM = {255, 170, 127, 85, 64};
|
||||||
```
|
```
|
||||||
@@ -177,6 +184,10 @@ const uint8_t RGBLED_GRADIENT_RANGES[] PROGMEM = {255, 170, 127, 85, 64};
|
|||||||
By including `#define RGBLIGHT_LAYERS` in your `config.h` file you can enable lighting layers. These make
|
By including `#define RGBLIGHT_LAYERS` in your `config.h` file you can enable lighting layers. These make
|
||||||
it easy to use your underglow LEDs as status indicators to show which keyboard layer is currently active, or the state of caps lock, all without disrupting any animations. [Here's a video](https://youtu.be/uLGE1epbmdY) showing an example of what you can do.
|
it easy to use your underglow LEDs as status indicators to show which keyboard layer is currently active, or the state of caps lock, all without disrupting any animations. [Here's a video](https://youtu.be/uLGE1epbmdY) showing an example of what you can do.
|
||||||
|
|
||||||
|
### Defining Lighting Layers :id=defining-lighting-layers
|
||||||
|
|
||||||
|
By default, 8 layers are possible. This can be expanded to as many as 32 by overriding the definition of `RGBLIGHT_MAX_LAYERS` in `config.h` (e.g. `#define RGBLIGHT_MAX_LAYERS 32`). Please note, if you use a split keyboard, you will need to flash both sides of the split after changing this. Also, increasing the maximum will increase the firmware size, and will slow sync on split keyboards.
|
||||||
|
|
||||||
To define a layer, we modify `keymap.c` to list out LED ranges and the colors we want to overlay on them using an array of `rgblight_segment_t` using the `RGBLIGHT_LAYER_SEGMENTS` macro. We can define multiple layers and enable/disable them independently:
|
To define a layer, we modify `keymap.c` to list out LED ranges and the colors we want to overlay on them using an array of `rgblight_segment_t` using the `RGBLIGHT_LAYER_SEGMENTS` macro. We can define multiple layers and enable/disable them independently:
|
||||||
|
|
||||||
```c
|
```c
|
||||||
@@ -211,8 +222,12 @@ void keyboard_post_init_user(void) {
|
|||||||
rgblight_layers = my_rgb_layers;
|
rgblight_layers = my_rgb_layers;
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
Note: For split keyboards with two controllers, both sides need to be flashed when updating the contents of rgblight_layers.
|
||||||
|
|
||||||
Finally, we enable and disable the lighting layers whenever the state of the keyboard changes:
|
### Enabling and disabling lighting layers :id=enabling-lighting-layers
|
||||||
|
|
||||||
|
Everything above just configured the definition of each lighting layer.
|
||||||
|
We can now enable and disable the lighting layers whenever the state of the keyboard changes:
|
||||||
|
|
||||||
```c
|
```c
|
||||||
layer_state_t layer_state_set_user(layer_state_t state) {
|
layer_state_t layer_state_set_user(layer_state_t state) {
|
||||||
@@ -228,7 +243,40 @@ bool led_update_user(led_t led_state) {
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
Note: For split keyboards with two controllers, both sides need to be flashed when updating the contents of rgblight_layers.
|
### Lighting layer blink :id=lighting-layer-blink
|
||||||
|
|
||||||
|
By including `#define RGBLIGHT_LAYER_BLINK` in your `config.h` file you can turn a lighting
|
||||||
|
layer on for a specified duration. Once the specified number of milliseconds has elapsed
|
||||||
|
the layer will be turned off. This is useful, e.g., if you want to acknowledge some
|
||||||
|
action (e.g. toggling some setting):
|
||||||
|
|
||||||
|
```c
|
||||||
|
const rgblight_segment_t PROGMEM _yes_layer[] = RGBLIGHT_LAYER_SEGMENTS( {9, 6, HSV_GREEN} );
|
||||||
|
const rgblight_segment_t PROGMEM _no_layer[] = RGBLIGHT_LAYER_SEGMENTS( {9, 6, HSV_RED} );
|
||||||
|
|
||||||
|
const rgblight_segment_t* const PROGMEM _rgb_layers[] =
|
||||||
|
RGBLIGHT_LAYERS_LIST( _yes_layer, _no_layer );
|
||||||
|
|
||||||
|
void keyboard_post_init_user(void) {
|
||||||
|
rgblight_layers = _rgb_layers;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Note we user post_process_record_user because we want the state
|
||||||
|
// after the flag has been flipped...
|
||||||
|
void post_process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
|
switch (keycode) {
|
||||||
|
case DEBUG:
|
||||||
|
rgblight_blink_layer(debug_enable ? 0 : 1, 500);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case NK_TOGG:
|
||||||
|
case NK_ON:
|
||||||
|
case NK_OFF:
|
||||||
|
rgblight_blink_layer(keymap_config.nkro ? 0 : 1, 500);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
## Functions
|
## Functions
|
||||||
|
|
||||||
@@ -328,12 +376,14 @@ rgblight_sethsv(HSV_GREEN, 2); // led 2
|
|||||||
|`rgblight_set_layer_state(i, is_on)` |Enable or disable lighting layer `i` based on value of `bool is_on` |
|
|`rgblight_set_layer_state(i, is_on)` |Enable or disable lighting layer `i` based on value of `bool is_on` |
|
||||||
|
|
||||||
#### query
|
#### query
|
||||||
|Function |Description |
|
|Function |Description |
|
||||||
|-----------------------|-----------------|
|
|-----------------------|---------------------------|
|
||||||
|`rgblight_get_mode()` |Get current mode |
|
|`rgblight_is_enabled()`|Gets current on/off status |
|
||||||
|`rgblight_get_hue()` |Get current hue |
|
|`rgblight_get_mode()` |Gets current mode |
|
||||||
|`rgblight_get_sat()` |Get current sat |
|
|`rgblight_get_hue()` |Gets current hue |
|
||||||
|`rgblight_get_val()` |Get current val |
|
|`rgblight_get_sat()` |Gets current sat |
|
||||||
|
|`rgblight_get_val()` |Gets current val |
|
||||||
|
|`rgblight_get_speed()` |Gets current speed |
|
||||||
|
|
||||||
## Colors
|
## Colors
|
||||||
|
|
||||||
|
|||||||
@@ -8,9 +8,20 @@ QMK Firmware has a generic implementation that is usable by any board, as well a
|
|||||||
|
|
||||||
For this, we will mostly be talking about the generic implementation used by the Let's Split and other keyboards.
|
For this, we will mostly be talking about the generic implementation used by the Let's Split and other keyboards.
|
||||||
|
|
||||||
!> ARM is not yet supported for Split Keyboards. Progress is being made, but we are not quite there, yet.
|
!> ARM is not yet fully supported for Split Keyboards and has many limitations. Progress is being made, but we have not yet reached 100% feature parity.
|
||||||
|
|
||||||
|
|
||||||
|
## Compatibility Overview
|
||||||
|
|
||||||
|
| Transport | AVR | ARM |
|
||||||
|
|------------------------------|--------------------|--------------------|
|
||||||
|
| ['serial'](serial_driver.md) | :heavy_check_mark: | :white_check_mark: <sup>1</sup> |
|
||||||
|
| I2C | :heavy_check_mark: | |
|
||||||
|
|
||||||
|
Notes:
|
||||||
|
|
||||||
|
1. Both hardware and software limitations are detailed within the [driver documentation](serial_driver.md).
|
||||||
|
|
||||||
## Hardware Configuration
|
## Hardware Configuration
|
||||||
|
|
||||||
This assumes that you're using two Pro Micro-compatible controllers, and are using TRRS jacks to connect to two halves.
|
This assumes that you're using two Pro Micro-compatible controllers, and are using TRRS jacks to connect to two halves.
|
||||||
|
|||||||
@@ -28,3 +28,4 @@ Note that the array indices are reversed same as the matrix and the values are o
|
|||||||
|`SH_MOFF` |Momentarily turns off swap. |
|
|`SH_MOFF` |Momentarily turns off swap. |
|
||||||
|`SH_TG` |Toggles swap on and off with every key press. |
|
|`SH_TG` |Toggles swap on and off with every key press. |
|
||||||
|`SH_TT` |Toggles with a tap; momentary when held. |
|
|`SH_TT` |Toggles with a tap; momentary when held. |
|
||||||
|
|`SH_OS` |One shot swap hands: toggles while pressed or until next key press. |
|
||||||
|
|||||||
@@ -90,13 +90,15 @@ Unicode input in QMK works by inputting a sequence of characters to the OS, sort
|
|||||||
|
|
||||||
The following input modes are available:
|
The following input modes are available:
|
||||||
|
|
||||||
* **`UC_OSX`**: macOS built-in Unicode hex input. Supports code points up to `0xFFFF` (`0x10FFFF` with Unicode Map).
|
* **`UC_MAC`**: macOS built-in Unicode hex input. Supports code points up to `0xFFFF` (`0x10FFFF` with Unicode Map).
|
||||||
|
|
||||||
To enable, go to _System Preferences > Keyboard > Input Sources_, add _Unicode Hex Input_ to the list (it's under _Other_), then activate it from the input dropdown in the Menu Bar.
|
To enable, go to _System Preferences > Keyboard > Input Sources_, add _Unicode Hex Input_ to the list (it's under _Other_), then activate it from the input dropdown in the Menu Bar.
|
||||||
By default, this mode uses the left Option key (`KC_LALT`) for Unicode input, but this can be changed by defining [`UNICODE_KEY_OSX`](#input-key-configuration) with another keycode.
|
By default, this mode uses the left Option key (`KC_LALT`) for Unicode input, but this can be changed by defining [`UNICODE_KEY_MAC`](#input-key-configuration) with another keycode.
|
||||||
|
|
||||||
!> Using the _Unicode Hex Input_ input source may disable some Option based shortcuts, such as Option + Left Arrow and Option + Right Arrow.
|
!> Using the _Unicode Hex Input_ input source may disable some Option based shortcuts, such as Option + Left Arrow and Option + Right Arrow.
|
||||||
|
|
||||||
|
!> `UC_OSX` is a deprecated alias of `UC_MAC` that will be removed in a future version of QMK.
|
||||||
|
|
||||||
* **`UC_LNX`**: Linux built-in IBus Unicode input. Supports code points up to `0x10FFFF` (all possible code points).
|
* **`UC_LNX`**: Linux built-in IBus Unicode input. Supports code points up to `0x10FFFF` (all possible code points).
|
||||||
|
|
||||||
Enabled by default and works almost anywhere on IBus-enabled distros. Without IBus, this mode works under GTK apps, but rarely anywhere else.
|
Enabled by default and works almost anywhere on IBus-enabled distros. Without IBus, this mode works under GTK apps, but rarely anywhere else.
|
||||||
@@ -124,7 +126,7 @@ You can switch the input mode at any time by using one of the following keycodes
|
|||||||
|----------------------|---------|------------|--------------------------------------------------------------|
|
|----------------------|---------|------------|--------------------------------------------------------------|
|
||||||
|`UNICODE_MODE_FORWARD`|`UC_MOD` |Next in list|[Cycle](#input-mode-cycling) through selected modes |
|
|`UNICODE_MODE_FORWARD`|`UC_MOD` |Next in list|[Cycle](#input-mode-cycling) through selected modes |
|
||||||
|`UNICODE_MODE_REVERSE`|`UC_RMOD`|Prev in list|[Cycle](#input-mode-cycling) through selected modes in reverse|
|
|`UNICODE_MODE_REVERSE`|`UC_RMOD`|Prev in list|[Cycle](#input-mode-cycling) through selected modes in reverse|
|
||||||
|`UNICODE_MODE_OSX` |`UC_M_OS`|`UC_OSX` |Switch to macOS input |
|
|`UNICODE_MODE_MAC` |`UC_M_MA`|`UC_MAC` |Switch to macOS input |
|
||||||
|`UNICODE_MODE_LNX` |`UC_M_LN`|`UC_LNX` |Switch to Linux input |
|
|`UNICODE_MODE_LNX` |`UC_M_LN`|`UC_LNX` |Switch to Linux input |
|
||||||
|`UNICODE_MODE_WIN` |`UC_M_WI`|`UC_WIN` |Switch to Windows input |
|
|`UNICODE_MODE_WIN` |`UC_M_WI`|`UC_WIN` |Switch to Windows input |
|
||||||
|`UNICODE_MODE_BSD` |`UC_M_BS`|`UC_BSD` |Switch to BSD input (not implemented) |
|
|`UNICODE_MODE_BSD` |`UC_M_BS`|`UC_BSD` |Switch to BSD input (not implemented) |
|
||||||
@@ -145,9 +147,9 @@ If you have the [Audio feature](feature_audio.md) enabled on the board, you can
|
|||||||
For instance, you can add these definitions to your `config.h` file:
|
For instance, you can add these definitions to your `config.h` file:
|
||||||
|
|
||||||
```c
|
```c
|
||||||
#define UNICODE_SONG_OSX COIN_SOUND
|
#define UNICODE_SONG_MAC AUDIO_ON_SOUND
|
||||||
#define UNICODE_SONG_LNX UNICODE_LINUX
|
#define UNICODE_SONG_LNX UNICODE_LINUX
|
||||||
#define UNICODE_SONG_BSD MARIO_GAMEOVER
|
#define UNICODE_SONG_BSD TERMINAL_SOUND
|
||||||
#define UNICODE_SONG_WIN UNICODE_WINDOWS
|
#define UNICODE_SONG_WIN UNICODE_WINDOWS
|
||||||
#define UNICODE_SONG_WINC UNICODE_WINDOWS
|
#define UNICODE_SONG_WINC UNICODE_WINDOWS
|
||||||
```
|
```
|
||||||
@@ -171,7 +173,7 @@ You can customize the keys used to trigger Unicode input for macOS, Linux and Wi
|
|||||||
|
|
||||||
|Define |Type |Default |Example |
|
|Define |Type |Default |Example |
|
||||||
|------------------|----------|------------------|-------------------------------------------|
|
|------------------|----------|------------------|-------------------------------------------|
|
||||||
|`UNICODE_KEY_OSX` |`uint8_t` |`KC_LALT` |`#define UNICODE_KEY_OSX KC_RALT` |
|
|`UNICODE_KEY_MAC` |`uint8_t` |`KC_LALT` |`#define UNICODE_KEY_MAC KC_RALT` |
|
||||||
|`UNICODE_KEY_LNX` |`uint16_t`|`LCTL(LSFT(KC_U))`|`#define UNICODE_KEY_LNX LCTL(LSFT(KC_E))`|
|
|`UNICODE_KEY_LNX` |`uint16_t`|`LCTL(LSFT(KC_U))`|`#define UNICODE_KEY_LNX LCTL(LSFT(KC_E))`|
|
||||||
|`UNICODE_KEY_WINC`|`uint8_t` |`KC_RALT` |`#define UNICODE_KEY_WINC KC_RGUI` |
|
|`UNICODE_KEY_WINC`|`uint8_t` |`KC_RALT` |`#define UNICODE_KEY_WINC KC_RGUI` |
|
||||||
|
|
||||||
@@ -180,7 +182,7 @@ You can customize the keys used to trigger Unicode input for macOS, Linux and Wi
|
|||||||
You can choose which input modes are available for cycling through. By default, this is disabled. If you want to enable it, limiting it to just the modes you use makes sense. Note that the values in the list are comma-delimited.
|
You can choose which input modes are available for cycling through. By default, this is disabled. If you want to enable it, limiting it to just the modes you use makes sense. Note that the values in the list are comma-delimited.
|
||||||
|
|
||||||
```c
|
```c
|
||||||
#define UNICODE_SELECTED_MODES UC_OSX, UC_LNX, UC_WIN, UC_WINC
|
#define UNICODE_SELECTED_MODES UC_MAC, UC_LNX, UC_WIN, UC_WINC
|
||||||
```
|
```
|
||||||
|
|
||||||
You can cycle through the selected modes by using the `UC_MOD`/`UC_RMOD` keycodes, or by calling `cycle_unicode_input_mode(offset)` in your code (`offset` is how many modes to move forward by, so +1 corresponds to `UC_MOD`).
|
You can cycle through the selected modes by using the `UC_MOD`/`UC_RMOD` keycodes, or by calling `cycle_unicode_input_mode(offset)` in your code (`offset` is how many modes to move forward by, so +1 corresponds to `UC_MOD`).
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# Userspace: Sharing Code Between Keymaps
|
# Userspace: Sharing Code Between Keymaps
|
||||||
|
|
||||||
If you use more than one keyboard with a similar keymap, you might see the benefit in being able to share code between them. Create your own folder in `users/` named the same as your keymap (ideally your github username, `<name>`) with the following structure:
|
If you use more than one keyboard with a similar keymap, you might see the benefit in being able to share code between them. Create your own folder in `users/` named the same as your keymap (ideally your GitHub username, `<name>`) with the following structure:
|
||||||
|
|
||||||
* `/users/<name>/` (added to the path automatically)
|
* `/users/<name>/` (added to the path automatically)
|
||||||
* `readme.md` (optional, recommended)
|
* `readme.md` (optional, recommended)
|
||||||
@@ -73,7 +73,7 @@ The reason for this, is that `<name>.h` won't be added in time to add settings (
|
|||||||
|
|
||||||
## Readme (`readme.md`)
|
## Readme (`readme.md`)
|
||||||
|
|
||||||
Please include authorship (your name, github username, email), and optionally [a license that's GPL compatible](https://www.gnu.org/licenses/license-list.html#GPLCompatibleLicenses).
|
Please include authorship (your name, GitHub username, email), and optionally [a license that's GPL compatible](https://www.gnu.org/licenses/license-list.html#GPLCompatibleLicenses).
|
||||||
|
|
||||||
You can use this as a template:
|
You can use this as a template:
|
||||||
```
|
```
|
||||||
@@ -93,7 +93,7 @@ You should have received a copy of the GNU General Public License
|
|||||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
```
|
```
|
||||||
|
|
||||||
You'd want to replace the year, name, email and github username with your info.
|
You'd want to replace the year, name, email and GitHub username with your info.
|
||||||
|
|
||||||
Additionally, this is a good place to document your code, if you wish to share it with others.
|
Additionally, this is a good place to document your code, if you wish to share it with others.
|
||||||
|
|
||||||
|
|||||||
@@ -26,7 +26,6 @@ Compatible flashers:
|
|||||||
|
|
||||||
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (recommended GUI)
|
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (recommended GUI)
|
||||||
* [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` in QMK (recommended command line)
|
* [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` in QMK (recommended command line)
|
||||||
* [Atmel's Flip](http://www.microchip.com/developmenttools/productdetails.aspx?partno=flip) (not recommended)
|
|
||||||
|
|
||||||
Flashing sequence:
|
Flashing sequence:
|
||||||
|
|
||||||
|
|||||||
@@ -4,8 +4,8 @@
|
|||||||
[](https://travis-ci.org/qmk/qmk_firmware)
|
[](https://travis-ci.org/qmk/qmk_firmware)
|
||||||
[](https://discord.gg/Uq7gcHh)
|
[](https://discord.gg/Uq7gcHh)
|
||||||
[](https://docs.qmk.fm)
|
[](https://docs.qmk.fm)
|
||||||
[](https://github.com/qmk/qmk_firmware/pulse/monthly)
|
[](https://github.com/qmk/qmk_firmware/pulse/monthly)
|
||||||
[](https://github.com/qmk/qmk_firmware/)
|
[](https://github.com/qmk/qmk_firmware/)
|
||||||
|
|
||||||
## Qu'est-ce que QMK Firmware ?
|
## Qu'est-ce que QMK Firmware ?
|
||||||
|
|
||||||
@@ -13,7 +13,7 @@ QMK (*Quantum Mechanical Keyboard*) est une communauté open source qui maintien
|
|||||||
|
|
||||||
## Comment l'obtenir
|
## Comment l'obtenir
|
||||||
|
|
||||||
Si vous souhaitez contribuer à une disposition de clavier (keymap), ou à des fonctionnalités de QMK alors le plus simple est de [forker le dépôt avec Github](https://github.com/qmk/qmk_firmware#fork-destination-box) puis cloner le dépôt localement pour y faire des changements. Vous pourrez pousser vos changements sur github puis ouvrir un [Pull Request](https://github.com/qmk/qmk_firmware/pulls) depuis votre fork Github.
|
Si vous souhaitez contribuer à une disposition de clavier (keymap), ou à des fonctionnalités de QMK alors le plus simple est de [forker le dépôt avec GitHub](https://github.com/qmk/qmk_firmware#fork-destination-box) puis cloner le dépôt localement pour y faire des changements. Vous pourrez pousser vos changements sur GitHub puis ouvrir un [Pull Request](https://github.com/qmk/qmk_firmware/pulls) depuis votre fork GitHub.
|
||||||
|
|
||||||
Sinon, vous pouvez aussi le télécharger directement en ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), ou le cloner avec git en ssh (`git@github.com:qmk/qmk_firmware.git`), ou https (`https://github.com/qmk/qmk_firmware.git`).
|
Sinon, vous pouvez aussi le télécharger directement en ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), ou le cloner avec git en ssh (`git@github.com:qmk/qmk_firmware.git`), ou https (`https://github.com/qmk/qmk_firmware.git`).
|
||||||
|
|
||||||
|
|||||||
@@ -101,7 +101,8 @@
|
|||||||
* [Guide des claviers soudés à la main](fr-fr/hand_wire.md)
|
* [Guide des claviers soudés à la main](fr-fr/hand_wire.md)
|
||||||
* [Guide de flash de l’ISP](fr-fr/isp_flashing_guide.md)
|
* [Guide de flash de l’ISP](fr-fr/isp_flashing_guide.md)
|
||||||
* [Guide du débogage ARM](fr-fr/arm_debugging.md)
|
* [Guide du débogage ARM](fr-fr/arm_debugging.md)
|
||||||
* [Drivers i2c](fr-fr/i2c_driver.md)
|
* [Drivers I2C](fr-fr/i2c_driver.md)
|
||||||
|
* [Drivers SPI](fr-fr/spi_driver.md)
|
||||||
* [Contrôles des GPIO](fr-fr/internals_gpio_control.md)
|
* [Contrôles des GPIO](fr-fr/internals_gpio_control.md)
|
||||||
* [Conversion en Proton C](fr-fr/proton_c_conversion.md)
|
* [Conversion en Proton C](fr-fr/proton_c_conversion.md)
|
||||||
|
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ Ceci est fait immédiatement après la fusion de la branche `future` précédent
|
|||||||
* [ ] Regroupe ChangeLog dans un fichier.
|
* [ ] Regroupe ChangeLog dans un fichier.
|
||||||
* [ ] `git commit -m 'Merge point for <DATE> Breaking Change'`
|
* [ ] `git commit -m 'Merge point for <DATE> Breaking Change'`
|
||||||
* [ ] `git push origin future`
|
* [ ] `git push origin future`
|
||||||
* Actions sur Github
|
* Actions sur GitHub
|
||||||
* [ ] Crée un PR pour `future`
|
* [ ] Crée un PR pour `future`
|
||||||
* [ ] S'assurer que Travis ne relève aucun problème
|
* [ ] S'assurer que Travis ne relève aucun problème
|
||||||
* [ ] Fusion le PR `future`
|
* [ ] Fusion le PR `future`
|
||||||
|
|||||||
@@ -155,11 +155,3 @@ Pour le moment, l'origine du problème n'est pas comprise, mais certaines option
|
|||||||
|
|
||||||
https://github.com/tmk/tmk_keyboard/issues/266
|
https://github.com/tmk/tmk_keyboard/issues/266
|
||||||
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
|
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
|
||||||
|
|
||||||
## FLIP ne marche pas
|
|
||||||
|
|
||||||
### `AtLibUsbDfu.dll` Not Found
|
|
||||||
|
|
||||||
Supprimez le pilote actuel et réinstallez celui donné par FLIP dans le gestionnaire de périphériques.
|
|
||||||
|
|
||||||
http://imgur.com/a/bnwzy
|
|
||||||
|
|||||||
@@ -26,7 +26,6 @@ Méthodes de flash compatibles :
|
|||||||
|
|
||||||
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (interface graphique recommandé)
|
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (interface graphique recommandé)
|
||||||
* [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` avec QMK (outil en ligne de commande recommandé)
|
* [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` avec QMK (outil en ligne de commande recommandé)
|
||||||
* [Atmel's Flip](http://www.microchip.com/developmenttools/productdetails.aspx?partno=flip) (non recommandé)
|
|
||||||
|
|
||||||
Ordre des actions :
|
Ordre des actions :
|
||||||
|
|
||||||
|
|||||||
@@ -6,11 +6,11 @@ GitHub peut être un peu compliqué pour ceux qui n'y sont pas familier. Ce guid
|
|||||||
|
|
||||||
Commencez par la [page GitHub de QMK](https://github.com/qmk/qmk_firmware), et vous verrez un bouton dans le coin en haut à droite qui indique "Fork":
|
Commencez par la [page GitHub de QMK](https://github.com/qmk/qmk_firmware), et vous verrez un bouton dans le coin en haut à droite qui indique "Fork":
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
Si vous faites partie d'une organisation, vous aurez besoin de savoir quel compte utiliser pour le fork. Dans la plupart des cas, vous voudrez créer le fork dans votre compte personnel. Une fois le fork complet (cela peut quelques fois prendre un peu de temps), appuyez sur le bouton "Clone or download":
|
Si vous faites partie d'une organisation, vous aurez besoin de savoir quel compte utiliser pour le fork. Dans la plupart des cas, vous voudrez créer le fork dans votre compte personnel. Une fois le fork complet (cela peut quelques fois prendre un peu de temps), appuyez sur le bouton "Clone or download":
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
Faites attention à sélectionner "HTTPS", et sélectionnez le lien et copiez-le:
|
Faites attention à sélectionner "HTTPS", et sélectionnez le lien et copiez-le:
|
||||||
|
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ git pull upstream master
|
|||||||
git push origin master
|
git push origin master
|
||||||
```
|
```
|
||||||
|
|
||||||
Cela vous change la branche courante en master, synchronise les données de références du dépôt QMK vers votre ordinateur. La commande pull tire les données de références vers votre branche courante puis les y téleverse. La commande push permet de pousser la branche courante (master) vers votre fork github.
|
Cela vous change la branche courante en master, synchronise les données de références du dépôt QMK vers votre ordinateur. La commande pull tire les données de références vers votre branche courante puis les y téleverse. La commande push permet de pousser la branche courante (master) vers votre fork GitHub.
|
||||||
|
|
||||||
### Faire des changements
|
### Faire des changements
|
||||||
|
|
||||||
|
|||||||
47
docs/getting_started_docker.md
Normal file
47
docs/getting_started_docker.md
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
# Docker Quick Start
|
||||||
|
|
||||||
|
This project includes a Docker workflow that will allow you to build a new firmware for your keyboard very easily without major changes to your primary operating system. This also ensures that when you clone the project and perform a build, you have the exact same environment as anyone else and the QMK build infrastructure. This makes it much easier for people to help you troubleshoot any issues you encounter.
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
The main prerequisite is a working `docker` install.
|
||||||
|
* [Docker CE](https://docs.docker.com/install/#supported-platforms)
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
Acquire a local copy of the QMK's repository (including submodules):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone --recurse-submodules https://github.com/qmk/qmk_firmware.git
|
||||||
|
cd qmk_firmware
|
||||||
|
```
|
||||||
|
|
||||||
|
Run the following command to build a keymap:
|
||||||
|
```bash
|
||||||
|
util/docker_build.sh <keyboard>:<keymap>
|
||||||
|
# For example: util/docker_build.sh planck/rev6:default
|
||||||
|
```
|
||||||
|
|
||||||
|
This will compile the desired keyboard/keymap and leave the resulting `.hex` or `.bin` file in the QMK directory for you to flash. If `:keymap` is omitted, all keymaps are used. Note that the parameter format is the same as when building with `make`.
|
||||||
|
|
||||||
|
There is also support for building _and_ flashing the keyboard straight from Docker by specifying the `target` as well:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
util/docker_build.sh keyboard:keymap:target
|
||||||
|
# For example: util/docker_build.sh planck/rev6:default:flash
|
||||||
|
```
|
||||||
|
|
||||||
|
You can also start the script without any parameters, in which case it will ask you to input the build parameters one by one, which you may find easier to use:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
util/docker_build.sh
|
||||||
|
# Reads parameters as input (leave blank for all keyboards/keymaps)
|
||||||
|
```
|
||||||
|
|
||||||
|
## FAQ
|
||||||
|
|
||||||
|
### Why can't I flash on Windows/macOS
|
||||||
|
|
||||||
|
On Windows and macOS, it requires [Docker Machine](http://gw.tnode.com/docker/docker-machine-with-usb-support-on-windows-macos/) to be running. This is tedious to set up, so it's not recommended; use [QMK Toolbox](https://github.com/qmk/qmk_toolbox) instead.
|
||||||
|
|
||||||
|
!> Docker for Windows requires [Hyper-V](https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/quick-start/enable-hyper-v) to be enabled. This means that it cannot work on versions of Windows which don't have Hyper-V, such as Windows 7, Windows 8 and **Windows 10 Home**.
|
||||||
@@ -1,16 +1,16 @@
|
|||||||
# How to Use Github with QMK
|
# How to Use GitHub with QMK
|
||||||
|
|
||||||
Github can be a little tricky to those that aren't familiar with it - this guide will walk through each step of forking, cloning, and submitting a pull request with QMK.
|
GitHub can be a little tricky to those that aren't familiar with it - this guide will walk through each step of forking, cloning, and submitting a pull request with QMK.
|
||||||
|
|
||||||
?> This guide assumes you're somewhat comfortable with running things at the command line, and have git installed on your system.
|
?> This guide assumes you're somewhat comfortable with running things at the command line, and have git installed on your system.
|
||||||
|
|
||||||
Start on the [QMK Github page](https://github.com/qmk/qmk_firmware), and you'll see a button in the upper right that says "Fork":
|
Start on the [QMK GitHub page](https://github.com/qmk/qmk_firmware), and you'll see a button in the upper right that says "Fork":
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
If you're a part of an organization, you'll need to choose which account to fork it to. In most circumstances, you'll want to fork it to your personal account. Once your fork is completed (sometimes this takes a little while), click the "Clone or Download" button:
|
If you're a part of an organization, you'll need to choose which account to fork it to. In most circumstances, you'll want to fork it to your personal account. Once your fork is completed (sometimes this takes a little while), click the "Clone or Download" button:
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
And be sure to select "HTTPS", and select the link and copy it:
|
And be sure to select "HTTPS", and select the link and copy it:
|
||||||
|
|
||||||
@@ -54,7 +54,7 @@ To https://github.com/whoeveryouare/qmk_firmware.git
|
|||||||
+ 20043e64...7da94ac5 master -> master
|
+ 20043e64...7da94ac5 master -> master
|
||||||
```
|
```
|
||||||
|
|
||||||
Your changes now exist on your fork on Github - if you go back there (`https://github.com/<whoeveryouare>/qmk_firmware`), you can create a "New Pull Request" by clicking this button:
|
Your changes now exist on your fork on GitHub - if you go back there (`https://github.com/<whoeveryouare>/qmk_firmware`), you can create a "New Pull Request" by clicking this button:
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
|||||||
@@ -20,7 +20,6 @@ The "easy" way to flash the firmware is using a tool from your host OS:
|
|||||||
|
|
||||||
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox) (recommended)
|
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox) (recommended)
|
||||||
* [Teensy Loader](https://www.pjrc.com/teensy/loader.html)
|
* [Teensy Loader](https://www.pjrc.com/teensy/loader.html)
|
||||||
* [Atmel FLIP](http://www.atmel.com/tools/flip.aspx)
|
|
||||||
|
|
||||||
If you want to program via the command line you can uncomment the ['modifyvm'] lines in the Vagrantfile to enable the USB passthrough into Linux and then program using the command line tools like dfu-util/dfu-programmer or you can install the Teensy CLI version.
|
If you want to program via the command line you can uncomment the ['modifyvm'] lines in the Vagrantfile to enable the USB passthrough into Linux and then program using the command line tools like dfu-util/dfu-programmer or you can install the Teensy CLI version.
|
||||||
|
|
||||||
|
|||||||
@@ -61,10 +61,76 @@ This file is used by the [QMK API](https://github.com/qmk/qmk_api). It contains
|
|||||||
|
|
||||||
All projects need to have a `config.h` file that sets things like the matrix size, product name, USB VID/PID, description and other settings. In general, use this file to set essential information and defaults for your keyboard that will always work.
|
All projects need to have a `config.h` file that sets things like the matrix size, product name, USB VID/PID, description and other settings. In general, use this file to set essential information and defaults for your keyboard that will always work.
|
||||||
|
|
||||||
|
The `config.h` files can also be placed in sub-folders, and the order in which they are read is as follows:
|
||||||
|
|
||||||
|
* `keyboards/top_folder/config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/sub_3/config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/sub_3/sub_4/config.h`
|
||||||
|
* `users/a_user_folder/config.h`
|
||||||
|
* `keyboards/top_folder/keymaps/a_keymap/config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/sub_3/sub_4/post_config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/sub_3/post_config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/post_config.h`
|
||||||
|
* `keyboards/top_folder/sub_1/post_config.h`
|
||||||
|
* `keyboards/top_folder/post_config.h`
|
||||||
|
|
||||||
|
The `post_config.h` file can be used for additional post-processing, depending on what is specified in the `config.h` file. For example, if you define the `IOS_DEVICE_ENABLE` macro in your keymap-level `config.h` file as follows, you can configure more detailed settings accordingly in the `post_config.h` file:
|
||||||
|
|
||||||
|
* `keyboards/top_folder/keymaps/a_keymap/config.h`
|
||||||
|
```c
|
||||||
|
#define IOS_DEVICE_ENABLE
|
||||||
|
```
|
||||||
|
* `keyboards/top_folder/post_config.h`
|
||||||
|
```c
|
||||||
|
#ifndef IOS_DEVICE_ENABLE
|
||||||
|
// USB_MAX_POWER_CONSUMPTION value for this keyboard
|
||||||
|
#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
|
||||||
|
|
||||||
|
#ifdef RGBLIGHT_ENABLE
|
||||||
|
#ifndef IOS_DEVICE_ENABLE
|
||||||
|
#define RGBLIGHT_LIMIT_VAL 200
|
||||||
|
#define RGBLIGHT_VAL_STEP 17
|
||||||
|
#else
|
||||||
|
#define RGBLIGHT_LIMIT_VAL 35
|
||||||
|
#define RGBLIGHT_VAL_STEP 4
|
||||||
|
#endif
|
||||||
|
#ifndef RGBLIGHT_HUE_STEP
|
||||||
|
#define RGBLIGHT_HUE_STEP 10
|
||||||
|
#endif
|
||||||
|
#ifndef RGBLIGHT_SAT_STEP
|
||||||
|
#define RGBLIGHT_SAT_STEP 17
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
```
|
||||||
|
|
||||||
|
?> If you define options using `post_config.h` as in the above example, you should not define the same options in the keyboard- or user-level `config.h`.
|
||||||
|
|
||||||
### `rules.mk`
|
### `rules.mk`
|
||||||
|
|
||||||
The presence of this file means that the folder is a keyboard target and can be used in `make` commands. This is where you setup the build environment for your keyboard and configure the default set of features.
|
The presence of this file means that the folder is a keyboard target and can be used in `make` commands. This is where you setup the build environment for your keyboard and configure the default set of features.
|
||||||
|
|
||||||
|
The `rules.mk` file can also be placed in a sub-folder, and its reading order is as follows:
|
||||||
|
|
||||||
|
* `keyboards/top_folder/rules.mk`
|
||||||
|
* `keyboards/top_folder/sub_1/rules.mk`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/rules.mk`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/sub_3/rules.mk`
|
||||||
|
* `keyboards/top_folder/sub_1/sub_2/sub_3/sub_4/rules.mk`
|
||||||
|
* `keyboards/top_folder/keymaps/a_keymap/rules.mk`
|
||||||
|
* `users/a_user_folder/rules.mk`
|
||||||
|
* `common_features.mk`
|
||||||
|
|
||||||
|
Many of the settings written in the `rules.mk` file are interpreted by `common_features.mk`, which sets the necessary source files and compiler options.
|
||||||
|
|
||||||
|
?> See `build_keyboard.mk` and `common_features.mk` for more details.
|
||||||
|
|
||||||
### `<keyboard_name.c>`
|
### `<keyboard_name.c>`
|
||||||
|
|
||||||
This is where you will write custom code for your keyboard. Typically you will write code to initialize and interface with the hardware in your keyboard. If your keyboard consists of only a key matrix with no LEDs, speakers, or other auxiliary hardware this file can be blank.
|
This is where you will write custom code for your keyboard. Typically you will write code to initialize and interface with the hardware in your keyboard. If your keyboard consists of only a key matrix with no LEDs, speakers, or other auxiliary hardware this file can be blank.
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ QMK (*Quantum Mechanical Keyboard*) היא קהילת קוד פתוח (open sour
|
|||||||
|
|
||||||
## איך להשיג אותה
|
## איך להשיג אותה
|
||||||
|
|
||||||
אם אתם מתכננים לתרום מיפוי מקשים, מקלדת או יכולת ל QMK, הדבר הקל ביותר הוא [לעשות פורק לריפו בGithub](https://github.com/qmk/qmk_firmware#fork-destination-box), ולעשות קלון לריפו בסביבה המקומית ושם לבצע את השינויים שלכם, לדחוף אותם ולפתוח [Pull Request](https://github.com/qmk/qmk_firmware/pulls) מהפורק שלך.
|
אם אתם מתכננים לתרום מיפוי מקשים, מקלדת או יכולת ל QMK, הדבר הקל ביותר הוא [לעשות פורק לריפו בGitHub](https://github.com/qmk/qmk_firmware#fork-destination-box), ולעשות קלון לריפו בסביבה המקומית ושם לבצע את השינויים שלכם, לדחוף אותם ולפתוח [Pull Request](https://github.com/qmk/qmk_firmware/pulls) מהפורק שלך.
|
||||||
|
|
||||||
אחרת, אפשר להוריד את הקושחה באופן ישיר ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), או לשכפל אותה באמצעות git (`git@github.com:qmk/qmk_firmware.git`), או https (`https://github.com/qmk/qmk_firmware.git`).
|
אחרת, אפשר להוריד את הקושחה באופן ישיר ([zip](https://github.com/qmk/qmk_firmware/zipball/master), [tar](https://github.com/qmk/qmk_firmware/tarball/master)), או לשכפל אותה באמצעות git (`git@github.com:qmk/qmk_firmware.git`), או https (`https://github.com/qmk/qmk_firmware.git`).
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* [מקורות ללמידה](he-il/newbs_learn_more_resources.md)
|
* [מקורות ללמידה](he-il/newbs_learn_more_resources.md)
|
||||||
* [בסיס QMK](he-il/README.md)
|
* [בסיס QMK](he-il/README.md)
|
||||||
* [מבוא לQMK](he-il/getting_started_introduction.md)
|
* [מבוא לQMK](he-il/getting_started_introduction.md)
|
||||||
* [איך להשתמש בGithub](he-il/getting_started_github.md)
|
* [איך להשתמש בGitHub](he-il/getting_started_github.md)
|
||||||
* [קבלת עזרה](he-il/getting_started_getting_help.md)
|
* [קבלת עזרה](he-il/getting_started_getting_help.md)
|
||||||
* [שאלות נפוצות](he-il/faq.md)
|
* [שאלות נפוצות](he-il/faq.md)
|
||||||
* [שאלות נפוצות כלליות](he-il/faq_general.md)
|
* [שאלות נפוצות כלליות](he-il/faq_general.md)
|
||||||
@@ -27,7 +27,7 @@
|
|||||||
* [QMK CLI](he-il/cli.md)
|
* [QMK CLI](he-il/cli.md)
|
||||||
* [QMK CLI Config](he-il/cli_configuration.md)
|
* [QMK CLI Config](he-il/cli_configuration.md)
|
||||||
* [תרומה ל QMK](he-il/contributing.md)
|
* [תרומה ל QMK](he-il/contributing.md)
|
||||||
* [איך להשתמש בGithub](he-il/getting_started_github.md)
|
* [איך להשתמש בGitHub](he-il/getting_started_github.md)
|
||||||
* [קבלת עזרה](he-il/getting_started_getting_help.md)
|
* [קבלת עזרה](he-il/getting_started_getting_help.md)
|
||||||
|
|
||||||
* [שינויים משמעותיים](he-il/breaking_changes.md)
|
* [שינויים משמעותיים](he-il/breaking_changes.md)
|
||||||
@@ -114,6 +114,7 @@
|
|||||||
* [מדריך לצריבת ISP](he-il/isp_flashing_guide.md)
|
* [מדריך לצריבת ISP](he-il/isp_flashing_guide.md)
|
||||||
* [מדריך לדיבאגינג ARM](he-il/arm_debugging.md)
|
* [מדריך לדיבאגינג ARM](he-il/arm_debugging.md)
|
||||||
* [מנהל התקן I2C](he-il/i2c_driver.md)
|
* [מנהל התקן I2C](he-il/i2c_driver.md)
|
||||||
|
* [מנהל התקן SPI](he-il/spi_driver.md)
|
||||||
* [בקרת GPIO](he-il/internals_gpio_control.md)
|
* [בקרת GPIO](he-il/internals_gpio_control.md)
|
||||||
* [המרת Proton C](he-il/proton_c_conversion.md)
|
* [המרת Proton C](he-il/proton_c_conversion.md)
|
||||||
|
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
הפורום הרשמי של QMK נמצא ב - [/r/olkb](https://reddit.com/r/olkb) באתר [reddit.com](https://reddit.com).
|
הפורום הרשמי של QMK נמצא ב - [/r/olkb](https://reddit.com/r/olkb) באתר [reddit.com](https://reddit.com).
|
||||||
|
|
||||||
## סוגיות Github
|
## סוגיות GitHub
|
||||||
|
|
||||||
ניתן לפתוח [סוגייה ב-GitHub](https://github.com/qmk/qmk_firmware/issues). הדבר שימושי במיוחד כאשר הסוגיה דורשת דיון עמוק וארוך או דיבאגינג.
|
ניתן לפתוח [סוגייה ב-GitHub](https://github.com/qmk/qmk_firmware/issues). הדבר שימושי במיוחד כאשר הסוגיה דורשת דיון עמוק וארוך או דיבאגינג.
|
||||||
</div>
|
</div>
|
||||||
@@ -1,17 +1,17 @@
|
|||||||
<div dir="rtl" markdown="1">
|
<div dir="rtl" markdown="1">
|
||||||
# איך להשתמש ב-Github עם QMK
|
# איך להשתמש ב-GitHub עם QMK
|
||||||
|
|
||||||
Github עלול להיות קצת טריקי למי שלא מכיר את העבודה איתו - מדריך זה ילווה אתכם שלב אחר שלב דרך ביצוע פעולות fork, clone ו-pull request עם QMK.
|
GitHub עלול להיות קצת טריקי למי שלא מכיר את העבודה איתו - מדריך זה ילווה אתכם שלב אחר שלב דרך ביצוע פעולות fork, clone ו-pull request עם QMK.
|
||||||
|
|
||||||
?> מדריך זה מניח שאתם מרגישים בנוח עם הרצה של פקודות בסביבת command line (שורת הפקודה) ו-git מותקן במערכת שלכם.
|
?> מדריך זה מניח שאתם מרגישים בנוח עם הרצה של פקודות בסביבת command line (שורת הפקודה) ו-git מותקן במערכת שלכם.
|
||||||
|
|
||||||
התחילו ב- [עמוד של QMK ב-Github](https://github.com/qmk/qmk_firmware), ותצמאו כפתור בחלק העליון מימין עם התיכוב "Fork":
|
התחילו ב- [עמוד של QMK ב-GitHub](https://github.com/qmk/qmk_firmware), ותצמאו כפתור בחלק העליון מימין עם התיכוב "Fork":
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
אם אתם חלק מארגון, תצטרכו לבחור לאיזה חשבון לבצע פעולת fork. ברוב המבקרים, תרצו לבצע fork לתוך החשבון הפרטי שלכם. ברגע שה-fork הסתיים (לפעמים זה יכול לקחת קצת זמן) הקליקו על כפתור ה-"Clone or Download":
|
אם אתם חלק מארגון, תצטרכו לבחור לאיזה חשבון לבצע פעולת fork. ברוב המבקרים, תרצו לבצע fork לתוך החשבון הפרטי שלכם. ברגע שה-fork הסתיים (לפעמים זה יכול לקחת קצת זמן) הקליקו על כפתור ה-"Clone or Download":
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
תוודאו שאתם בוחרים באופצייה של "HTTPS", בחרו את הקישור והעתיקו אותו:
|
תוודאו שאתם בוחרים באופצייה של "HTTPS", בחרו את הקישור והעתיקו אותו:
|
||||||
|
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
|
|
||||||
// Moved pages
|
// Moved pages
|
||||||
'/adding_a_keyboard_to_qmk': '/hardware_keyboard_guidelines',
|
'/adding_a_keyboard_to_qmk': '/hardware_keyboard_guidelines',
|
||||||
'/build_environment_setup': '/getting_started_build_tools',
|
'/build_environment_setup': '/newbs_getting_started',
|
||||||
'/cli_dev_configuration': '/cli_configuration',
|
'/cli_dev_configuration': '/cli_configuration',
|
||||||
'/dynamic_macros': '/feature_dynamic_macros',
|
'/dynamic_macros': '/feature_dynamic_macros',
|
||||||
'/feature_common_shortcuts': '/feature_advanced_keycodes',
|
'/feature_common_shortcuts': '/feature_advanced_keycodes',
|
||||||
@@ -45,6 +45,7 @@
|
|||||||
'/tap_dance': '/feature_tap_dance',
|
'/tap_dance': '/feature_tap_dance',
|
||||||
'/unicode': '/feature_unicode',
|
'/unicode': '/feature_unicode',
|
||||||
'/python_development': '/cli_development',
|
'/python_development': '/cli_development',
|
||||||
|
'/getting_started_build_tools':'/newbs_getting_started',
|
||||||
},
|
},
|
||||||
basePath: '/',
|
basePath: '/',
|
||||||
name: 'QMK Firmware',
|
name: 'QMK Firmware',
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ The following functions can provide basic control of GPIOs and are found in `qua
|
|||||||
| `writePinLow(pin)` | Set pin level as low, assuming it is an output | `PORTB &= ~(1<<2)` | `palClearLine(pin)` |
|
| `writePinLow(pin)` | Set pin level as low, assuming it is an output | `PORTB &= ~(1<<2)` | `palClearLine(pin)` |
|
||||||
| `writePin(pin, level)` | Set pin level, assuming it is an output | `(level) ? PORTB \|= (1<<2) : PORTB &= ~(1<<2)` | `(level) ? palSetLine(pin) : palClearLine(pin)` |
|
| `writePin(pin, level)` | Set pin level, assuming it is an output | `(level) ? PORTB \|= (1<<2) : PORTB &= ~(1<<2)` | `(level) ? palSetLine(pin) : palClearLine(pin)` |
|
||||||
| `readPin(pin)` | Returns the level of the pin | `_SFR_IO8(pin >> 4) & _BV(pin & 0xF)` | `palReadLine(pin)` |
|
| `readPin(pin)` | Returns the level of the pin | `_SFR_IO8(pin >> 4) & _BV(pin & 0xF)` | `palReadLine(pin)` |
|
||||||
|
| `togglePin(pin)` | Invert pin level, assuming it is an output | `PORTB ^= (1<<2)` | `palToggleLine(pin)` |
|
||||||
|
|
||||||
## Advanced Settings :id=advanced-settings
|
## Advanced Settings :id=advanced-settings
|
||||||
|
|
||||||
|
|||||||
@@ -115,12 +115,18 @@ The simplest and quickest way to get things back to normal is to flash only a bo
|
|||||||
|
|
||||||
You can find the stock bootloaders in the [`util/` folder](https://github.com/qmk/qmk_firmware/tree/master/util). Be sure to flash the correct bootloader for your chip:
|
You can find the stock bootloaders in the [`util/` folder](https://github.com/qmk/qmk_firmware/tree/master/util). Be sure to flash the correct bootloader for your chip:
|
||||||
|
|
||||||
* [`atmega32u4`](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32u4_1_0_0.hex) - Most keyboards, Planck Rev 1-5, Preonic Rev 1-2
|
* **Atmel DFU**
|
||||||
* [`Pro Micro`](https://github.com/sparkfun/Arduino_Boards/blob/master/sparkfun/avr/bootloaders/caterina/Caterina-promicro16.hex) - The default bootloader for Pro Micro controllers
|
* [ATmega16U4](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega16u4_1.0.1.hex)
|
||||||
* [`at90usb1286`](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_at90usb128x_1_0_1.hex) - Planck Light Rev 1
|
* [ATmega32U4](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32u4_1.0.0.hex)
|
||||||
* [`atmega32a`](https://github.com/qmk/qmk_firmware/blob/master/util/bootloader_atmega32a_1_0_0.hex) - jj40, and other V-USB/ps2avrGB keyboards
|
* [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)
|
||||||
|
|
||||||
If you're not sure what your board uses, look in the `rules.mk` file for the keyboard in QMK. The `MCU =` line will have the value you need. It may differ between different versions of the board.
|
If you're not sure what your board uses, look in the `rules.mk` file for the keyboard in QMK. The `MCU` and `BOOTLOADER` lines will have the value you need. It may differ between different versions of the board.
|
||||||
|
|
||||||
### Production Techniques
|
### Production Techniques
|
||||||
|
|
||||||
|
|||||||
@@ -121,6 +121,7 @@
|
|||||||
* [ドライバ](ja/hardware_drivers.md)
|
* [ドライバ](ja/hardware_drivers.md)
|
||||||
* [ADC ドライバ](ja/adc_driver.md)
|
* [ADC ドライバ](ja/adc_driver.md)
|
||||||
* [I2C ドライバ](ja/i2c_driver.md)
|
* [I2C ドライバ](ja/i2c_driver.md)
|
||||||
|
* [SPI ドライバ](ja/spi_driver.md)
|
||||||
* [WS2812 ドライバ](ja/ws2812_driver.md)
|
* [WS2812 ドライバ](ja/ws2812_driver.md)
|
||||||
* [EEPROM ドライバ](ja/eeprom_driver.md)
|
* [EEPROM ドライバ](ja/eeprom_driver.md)
|
||||||
* [GPIO コントロール](ja/internals_gpio_control.md)
|
* [GPIO コントロール](ja/internals_gpio_control.md)
|
||||||
|
|||||||
272
docs/ja/cli.md
272
docs/ja/cli.md
@@ -1,29 +1,19 @@
|
|||||||
# QMK CLI
|
# QMK CLI :id=qmk-cli
|
||||||
|
|
||||||
<!---
|
<!---
|
||||||
original document: 79e6b7866:docs/cli.md
|
original document: 0.8.58:docs/cli.md
|
||||||
git diff 79e6b7866 HEAD -- docs/cli.md | cat
|
git diff 0.8.58 HEAD -- docs/cli.md | cat
|
||||||
-->
|
-->
|
||||||
|
|
||||||
このページは QMK CLI のセットアップと使用方法について説明します。
|
## 概要 :id=overview
|
||||||
|
|
||||||
# 概要
|
|
||||||
|
|
||||||
QMK CLI を使用すると QMK キーボードの構築と作業が簡単になります。QMK ファームウェアの取得とコンパイル、キーマップの作成などのようなタスクを簡素化し合理化するためのコマンドを多く提供します。
|
QMK CLI を使用すると QMK キーボードの構築と作業が簡単になります。QMK ファームウェアの取得とコンパイル、キーマップの作成などのようなタスクを簡素化し合理化するためのコマンドを多く提供します。
|
||||||
|
|
||||||
* [グローバル CLI](#global-cli)
|
### 必要事項 :id=requirements
|
||||||
* [ローカル CLI](#local-cli)
|
|
||||||
* [CLI コマンド](#cli-commands)
|
|
||||||
|
|
||||||
# 必要事項
|
CLI は Python 3.5 以上を必要とします。我々は必要事項の数を少なくしようとしていますが、[`requirements.txt`](https://github.com/qmk/qmk_firmware/blob/master/requirements.txt) に列挙されているパッケージもインストールする必要があります。これらは QMK CLI をインストールするときに自動的にインストールされます。
|
||||||
|
|
||||||
CLI は Python 3.5 以上を必要とします。我々は必要事項の数を少なくしようとしていますが、[`requirements.txt`](https://github.com/qmk/qmk_firmware/blob/master/requirements.txt) にリストされているパッケージもインストールする必要があります。
|
### Homebrew を使ったインストール (macOS、いくつかの Linux) :id=install-using-homebrew
|
||||||
|
|
||||||
# グローバル CLI :id=global-cli
|
|
||||||
|
|
||||||
QMK は、QMK ビルド環境のセットアップ、QMK の操作、および `qmk_firmware` の複数のコピーの操作を容易にできるインストール可能な CLI を提供します。これを定期的にインストールおよび更新することをお勧めします。
|
|
||||||
|
|
||||||
## Homebrew を使ったインストール (macOS、いくつかの Linux)
|
|
||||||
|
|
||||||
[Homebrew](https://brew.sh) をインストールしている場合は、タップして QMK をインストールすることができます:
|
[Homebrew](https://brew.sh) をインストールしている場合は、タップして QMK をインストールすることができます:
|
||||||
|
|
||||||
@@ -34,7 +24,7 @@ export QMK_HOME='~/qmk_firmware' # オプション、`qmk_firmware` の場所を
|
|||||||
qmk setup # これは `qmk/qmk_firmware` をクローンし、オプションでビルド環境をセットアップします
|
qmk setup # これは `qmk/qmk_firmware` をクローンし、オプションでビルド環境をセットアップします
|
||||||
```
|
```
|
||||||
|
|
||||||
## easy_install あるいは pip を使ってインストール
|
### easy_install あるいは pip を使ってインストール :id=install-using-easy_install-or-pip
|
||||||
|
|
||||||
上のリストにあなたのシステムがない場合は、QMK を手動でインストールすることができます。最初に、python 3.5 (以降)をインストールしていて、pip をインストールしていることを確認してください。次に以下のコマンドを使って QMK をインストールします:
|
上のリストにあなたのシステムがない場合は、QMK を手動でインストールすることができます。最初に、python 3.5 (以降)をインストールしていて、pip をインストールしていることを確認してください。次に以下のコマンドを使って QMK をインストールします:
|
||||||
|
|
||||||
@@ -44,7 +34,7 @@ export QMK_HOME='~/qmk_firmware' # オプション、`qmk_firmware` の場所を
|
|||||||
qmk setup # これは `qmk/qmk_firmware` をクローンし、オプションでビルド環境をセットアップします
|
qmk setup # これは `qmk/qmk_firmware` をクローンし、オプションでビルド環境をセットアップします
|
||||||
```
|
```
|
||||||
|
|
||||||
## 他のオペレーティングシステムのためのパッケージ
|
### 他のオペレーティングシステムのためのパッケージ :id=packaging-for-other-operating-systems
|
||||||
|
|
||||||
より多くのオペレーティングシステム用に `qmk` パッケージを作成および保守する人を探しています。OS 用のパッケージを作成する場合は、以下のガイドラインに従ってください:
|
より多くのオペレーティングシステム用に `qmk` パッケージを作成および保守する人を探しています。OS 用のパッケージを作成する場合は、以下のガイドラインに従ってください:
|
||||||
|
|
||||||
@@ -52,247 +42,3 @@ qmk setup # これは `qmk/qmk_firmware` をクローンし、オプション
|
|||||||
* 逸脱する場合は、理由をコメントに文章化してください。
|
* 逸脱する場合は、理由をコメントに文章化してください。
|
||||||
* virtualenv を使ってインストールしてください
|
* virtualenv を使ってインストールしてください
|
||||||
* 環境変数 `QMK_HOME` を設定して、ファームウェアソースを `~/qmk_firmware` 以外のどこかにチェックアウトするようにユーザに指示してください。
|
* 環境変数 `QMK_HOME` を設定して、ファームウェアソースを `~/qmk_firmware` 以外のどこかにチェックアウトするようにユーザに指示してください。
|
||||||
|
|
||||||
# ローカル CLI :id=local-cli
|
|
||||||
|
|
||||||
グローバル CLI を使いたくない場合は、`qmk_firmware` に付属のローカル CLI があります。`qmk_firmware/bin/qmk` で見つけることができます。任意のディレクトリから `qmk` コマンドを実行でき、常に `qmk_firmware` のコピー上で動作します。
|
|
||||||
|
|
||||||
**例**:
|
|
||||||
|
|
||||||
```
|
|
||||||
$ ~/qmk_firmware/bin/qmk hello
|
|
||||||
Ψ Hello, World!
|
|
||||||
```
|
|
||||||
|
|
||||||
## ローカル CLI の制限
|
|
||||||
|
|
||||||
グローバル CLI と比較して、ローカル CLI には幾つかの制限があります:
|
|
||||||
|
|
||||||
* ローカル CLI は `qmk setup` あるいは `qmk clone` をサポートしません。
|
|
||||||
* 複数のリポジトリがクローンされている場合でも、ローカル CLI は常に `qmk_firmware` ツリー上で動作します。
|
|
||||||
* ローカル CLI は virtualenv で動作しません。そのため依存関係が競合する可能性があります
|
|
||||||
|
|
||||||
# CLI コマンド :id=cli-commands
|
|
||||||
|
|
||||||
## `qmk cformat`
|
|
||||||
|
|
||||||
このコマンドは clang-format を使って C コードを整形します。引数無しで実行して全てのコアコードを整形するか、コマンドラインでファイル名を渡して特定のファイルに対して実行します。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk cformat [file1] [file2] [...] [fileN]
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk compile`
|
|
||||||
|
|
||||||
このコマンドにより、任意のディレクトリからファームウェアをコンパイルすることができます。<https://config.qmk.fm> からエクスポートした JSON をコンパイルするか、リポジトリ内でキーマップをコンパイルするか、現在の作業ディレクトリでキーボードをコンパイルすることができます。
|
|
||||||
|
|
||||||
**Configurator Exports での使い方**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk compile <configuratorExport.json>
|
|
||||||
```
|
|
||||||
|
|
||||||
**キーマップでの使い方**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk compile -kb <keyboard_name> -km <keymap_name>
|
|
||||||
```
|
|
||||||
|
|
||||||
**キーボードディレクトリでの使い方**:
|
|
||||||
|
|
||||||
default キーマップのあるキーボードディレクトリ、キーボードのキーマップディレクトリ、`--keymap <keymap_name>` で与えられるキーマップディレクトリにいなければなりません。
|
|
||||||
```
|
|
||||||
qmk compile
|
|
||||||
```
|
|
||||||
|
|
||||||
**例**:
|
|
||||||
```
|
|
||||||
$ qmk config compile.keymap=default
|
|
||||||
$ cd ~/qmk_firmware/keyboards/planck/rev6
|
|
||||||
$ qmk compile
|
|
||||||
Ψ Compiling keymap with make planck/rev6:default
|
|
||||||
...
|
|
||||||
```
|
|
||||||
あるいはオプションのキーマップ引数を指定して
|
|
||||||
|
|
||||||
```
|
|
||||||
$ cd ~/qmk_firmware/keyboards/clueboard/66/rev4
|
|
||||||
$ qmk compile -km 66_iso
|
|
||||||
Ψ Compiling keymap with make clueboard/66/rev4:66_iso
|
|
||||||
...
|
|
||||||
```
|
|
||||||
あるいはキーマップディレクトリで
|
|
||||||
|
|
||||||
```
|
|
||||||
$ cd ~/qmk_firmware/keyboards/gh60/satan/keymaps/colemak
|
|
||||||
$ qmk compile
|
|
||||||
Ψ Compiling keymap with make make gh60/satan:colemak
|
|
||||||
...
|
|
||||||
```
|
|
||||||
|
|
||||||
**レイアウトディレクトリでの使い方**:
|
|
||||||
|
|
||||||
`qmk_firmware/layouts/` 以下のキーマップディレクトリにいなければなりません。
|
|
||||||
```
|
|
||||||
qmk compile -kb <keyboard_name>
|
|
||||||
```
|
|
||||||
|
|
||||||
**例**:
|
|
||||||
```
|
|
||||||
$ cd ~/qmk_firmware/layouts/community/60_ansi/mechmerlin-ansi
|
|
||||||
$ qmk compile -kb dz60
|
|
||||||
Ψ Compiling keymap with make dz60:mechmerlin-ansi
|
|
||||||
...
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk flash`
|
|
||||||
|
|
||||||
このコマンドは `qmk compile` に似ていますが、ブートローダを対象にすることもできます。ブートローダはオプションで、デフォルトでは `:flash` に設定されています。
|
|
||||||
違うブートローダを指定するには、`-bl <bootloader>` を使ってください。利用可能なブートローダの詳細については、<https://docs.qmk.fm/#/ja/flashing>
|
|
||||||
を見てください。
|
|
||||||
|
|
||||||
**Configurator Exports での使い方**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk flash <configuratorExport.json> -bl <bootloader>
|
|
||||||
```
|
|
||||||
|
|
||||||
**キーマップでの使い方**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk flash -kb <keyboard_name> -km <keymap_name> -bl <bootloader>
|
|
||||||
```
|
|
||||||
|
|
||||||
**ブートローダのリスト**
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk flash -b
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk config`
|
|
||||||
|
|
||||||
このコマンドにより QMK の挙動を設定することができます。完全な `qmk config` のドキュメントについては、[CLI 設定](ja/cli_configuration.md)を見てください。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk config [-ro] [config_token1] [config_token2] [...] [config_tokenN]
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk docs`
|
|
||||||
|
|
||||||
このコマンドは、ドキュメントを参照または改善するために使うことができるローカル HTTP サーバを起動します。デフォルトのポートは 8936 です。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk docs [-p PORT]
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk doctor`
|
|
||||||
|
|
||||||
このコマンドは環境を調査し、潜在的なビルドあるいは書き込みの問題について警告します。必要に応じてそれらの多くを修正できます。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk doctor [-y] [-n]
|
|
||||||
```
|
|
||||||
|
|
||||||
**例**:
|
|
||||||
|
|
||||||
環境に問題がないか確認し、それらを修正するよう促します:
|
|
||||||
|
|
||||||
qmk doctor
|
|
||||||
|
|
||||||
環境を確認し、見つかった問題を自動的に修正します:
|
|
||||||
|
|
||||||
qmk doctor -y
|
|
||||||
|
|
||||||
環境を確認し、問題のみをレポートします:
|
|
||||||
|
|
||||||
qmk doctor -n
|
|
||||||
|
|
||||||
## `qmk json2c`
|
|
||||||
|
|
||||||
QMK Configurator からエクスポートしたものから keymap.c を生成します。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk json2c [-o OUTPUT] filename
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk kle2json`
|
|
||||||
|
|
||||||
このコマンドにより、生の KLE データから QMK Configurator の JSON へ変換することができます。絶対パスあるいは現在のディレクトリ内のファイル名のいずれかを受け取ります。デフォルトでは、`info.json` が既に存在している場合は上書きしません。上書きするには、`-f` あるいは `--force` フラグを使ってください。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk kle2json [-f] <filename>
|
|
||||||
```
|
|
||||||
|
|
||||||
**例**:
|
|
||||||
|
|
||||||
```
|
|
||||||
$ qmk kle2json kle.txt
|
|
||||||
☒ File info.json already exists, use -f or --force to overwrite.
|
|
||||||
```
|
|
||||||
|
|
||||||
```
|
|
||||||
$ qmk kle2json -f kle.txt -f
|
|
||||||
Ψ Wrote out to info.json
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk list-keyboards`
|
|
||||||
|
|
||||||
このコマンドは現在 `qmk_firmware` で定義されている全てのキーボードをリスト化します。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk list-keyboards
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk list-keymaps`
|
|
||||||
|
|
||||||
このコマンドは指定されたキーボード(とリビジョン)の全てのキーマップをリスト化します。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk list-keymaps -kb planck/ez
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk new-keymap`
|
|
||||||
|
|
||||||
このコマンドは、キーボードの既存のデフォルトのキーマップに基づいて新しいキーマップを作成します。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk new-keymap [-kb KEYBOARD] [-km KEYMAP]
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk pyformat`
|
|
||||||
|
|
||||||
このコマンドは `qmk_firmware` 内の python コードを整形します。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk pyformat
|
|
||||||
```
|
|
||||||
|
|
||||||
## `qmk pytest`
|
|
||||||
|
|
||||||
このコマンドは python のテストスィートを実行します。python コードに変更を加えた場合、これの実行が成功することを確認する必要があります。
|
|
||||||
|
|
||||||
**使用法**:
|
|
||||||
|
|
||||||
```
|
|
||||||
qmk pytest
|
|
||||||
```
|
|
||||||
|
|||||||
258
docs/ja/cli_commands.md
Normal file
258
docs/ja/cli_commands.md
Normal file
@@ -0,0 +1,258 @@
|
|||||||
|
# QMK CLI コマンド
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.58:docs/cli.md
|
||||||
|
git diff 0.8.58 HEAD -- docs/cli.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
# CLI コマンド
|
||||||
|
|
||||||
|
## `qmk cformat`
|
||||||
|
|
||||||
|
このコマンドは clang-format を使って C コードを整形します。
|
||||||
|
|
||||||
|
引数無しで実行すると、変更された全てのコアコードを整形します。デフォルトでは `git diff` で `origin/master` をチェックし、ブランチは `-b <branch_name>` を使って変更できます。
|
||||||
|
|
||||||
|
`-a` で全てのコアコードを整形するか、コマンドラインでファイル名を渡して特定のファイルに対して実行します。
|
||||||
|
|
||||||
|
**指定したファイルに対する使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat [file1] [file2] [...] [fileN]
|
||||||
|
```
|
||||||
|
|
||||||
|
**全てのコアファイルに対する使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat -a
|
||||||
|
```
|
||||||
|
|
||||||
|
**origin/master で変更されたファイルのみに対する使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat
|
||||||
|
```
|
||||||
|
|
||||||
|
**branch_name で変更されたファイルのみに対する使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk cformat -b branch_name
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk compile`
|
||||||
|
|
||||||
|
このコマンドにより、任意のディレクトリからファームウェアをコンパイルすることができます。<https://config.qmk.fm> からエクスポートした JSON をコンパイルするか、リポジトリ内でキーマップをコンパイルするか、現在の作業ディレクトリでキーボードをコンパイルすることができます。
|
||||||
|
|
||||||
|
**Configurator Exports での使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk compile <configuratorExport.json>
|
||||||
|
```
|
||||||
|
|
||||||
|
**キーマップでの使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk compile -kb <keyboard_name> -km <keymap_name>
|
||||||
|
```
|
||||||
|
|
||||||
|
**キーボードディレクトリでの使い方**:
|
||||||
|
|
||||||
|
default キーマップのあるキーボードディレクトリ、キーボードのキーマップディレクトリ、`--keymap <keymap_name>` で与えられるキーマップディレクトリにいなければなりません。
|
||||||
|
```
|
||||||
|
qmk compile
|
||||||
|
```
|
||||||
|
|
||||||
|
**指定したキーマップをサポートする全てのキーボードをビルドする場合の使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk compile -kb all -km <keymap_name>
|
||||||
|
```
|
||||||
|
|
||||||
|
**例**:
|
||||||
|
```
|
||||||
|
$ qmk config compile.keymap=default
|
||||||
|
$ cd ~/qmk_firmware/keyboards/planck/rev6
|
||||||
|
$ qmk compile
|
||||||
|
Ψ Compiling keymap with make planck/rev6:default
|
||||||
|
...
|
||||||
|
```
|
||||||
|
あるいはオプションのキーマップ引数を指定して
|
||||||
|
|
||||||
|
```
|
||||||
|
$ cd ~/qmk_firmware/keyboards/clueboard/66/rev4
|
||||||
|
$ qmk compile -km 66_iso
|
||||||
|
Ψ Compiling keymap with make clueboard/66/rev4:66_iso
|
||||||
|
...
|
||||||
|
```
|
||||||
|
あるいはキーマップディレクトリで
|
||||||
|
|
||||||
|
```
|
||||||
|
$ cd ~/qmk_firmware/keyboards/gh60/satan/keymaps/colemak
|
||||||
|
$ qmk compile
|
||||||
|
Ψ Compiling keymap with make make gh60/satan:colemak
|
||||||
|
...
|
||||||
|
```
|
||||||
|
|
||||||
|
**レイアウトディレクトリでの使い方**:
|
||||||
|
|
||||||
|
`qmk_firmware/layouts/` 以下のキーマップディレクトリにいなければなりません。
|
||||||
|
```
|
||||||
|
qmk compile -kb <keyboard_name>
|
||||||
|
```
|
||||||
|
|
||||||
|
**例**:
|
||||||
|
```
|
||||||
|
$ cd ~/qmk_firmware/layouts/community/60_ansi/mechmerlin-ansi
|
||||||
|
$ qmk compile -kb dz60
|
||||||
|
Ψ Compiling keymap with make dz60:mechmerlin-ansi
|
||||||
|
...
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk flash`
|
||||||
|
|
||||||
|
このコマンドは `qmk compile` に似ていますが、ブートローダを対象にすることもできます。ブートローダはオプションで、デフォルトでは `:flash` に設定されています。
|
||||||
|
違うブートローダを指定するには、`-bl <bootloader>` を使ってください。利用可能なブートローダの詳細については、[ファームウェアを書き込む](ja/flashing.md)を見てください。
|
||||||
|
|
||||||
|
**Configurator Exports での使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk flash <configuratorExport.json> -bl <bootloader>
|
||||||
|
```
|
||||||
|
|
||||||
|
**キーマップでの使い方**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk flash -kb <keyboard_name> -km <keymap_name> -bl <bootloader>
|
||||||
|
```
|
||||||
|
|
||||||
|
**ブートローダの列挙**
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk flash -b
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk config`
|
||||||
|
|
||||||
|
このコマンドにより QMK の挙動を設定することができます。完全な `qmk config` のドキュメントについては、[CLI 設定](ja/cli_configuration.md)を見てください。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk config [-ro] [config_token1] [config_token2] [...] [config_tokenN]
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk docs`
|
||||||
|
|
||||||
|
このコマンドは、ドキュメントを参照または改善するために使うことができるローカル HTTP サーバを起動します。デフォルトのポートは 8936 です。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk docs [-p PORT]
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk doctor`
|
||||||
|
|
||||||
|
このコマンドは環境を調査し、潜在的なビルドあるいは書き込みの問題について警告します。必要に応じてそれらの多くを修正できます。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk doctor [-y] [-n]
|
||||||
|
```
|
||||||
|
|
||||||
|
**例**:
|
||||||
|
|
||||||
|
環境に問題がないか確認し、それらを修正するよう促します:
|
||||||
|
|
||||||
|
qmk doctor
|
||||||
|
|
||||||
|
環境を確認し、見つかった問題を自動的に修正します:
|
||||||
|
|
||||||
|
qmk doctor -y
|
||||||
|
|
||||||
|
環境を確認し、問題のみをレポートします:
|
||||||
|
|
||||||
|
qmk doctor -n
|
||||||
|
|
||||||
|
## `qmk json2c`
|
||||||
|
|
||||||
|
QMK Configurator からエクスポートしたものから keymap.c を生成します。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk json2c [-o OUTPUT] filename
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk kle2json`
|
||||||
|
|
||||||
|
このコマンドにより、生の KLE データから QMK Configurator の JSON へ変換することができます。絶対パスあるいは現在のディレクトリ内のファイル名のいずれかを受け取ります。デフォルトでは、`info.json` が既に存在している場合は上書きしません。上書きするには、`-f` あるいは `--force` フラグを使ってください。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk kle2json [-f] <filename>
|
||||||
|
```
|
||||||
|
|
||||||
|
**例**:
|
||||||
|
|
||||||
|
```
|
||||||
|
$ qmk kle2json kle.txt
|
||||||
|
☒ File info.json already exists, use -f or --force to overwrite.
|
||||||
|
```
|
||||||
|
|
||||||
|
```
|
||||||
|
$ qmk kle2json -f kle.txt -f
|
||||||
|
Ψ Wrote out to info.json
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk list-keyboards`
|
||||||
|
|
||||||
|
このコマンドは現在 `qmk_firmware` で定義されている全てのキーボードを列挙します。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk list-keyboards
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk list-keymaps`
|
||||||
|
|
||||||
|
このコマンドは指定されたキーボード(とリビジョン)の全てのキーマップを列挙します。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk list-keymaps -kb planck/ez
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk new-keymap`
|
||||||
|
|
||||||
|
このコマンドは、キーボードの既存のデフォルトのキーマップに基づいて新しいキーマップを作成します。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk new-keymap [-kb KEYBOARD] [-km KEYMAP]
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk pyformat`
|
||||||
|
|
||||||
|
このコマンドは `qmk_firmware` 内の python コードを整形します。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk pyformat
|
||||||
|
```
|
||||||
|
|
||||||
|
## `qmk pytest`
|
||||||
|
|
||||||
|
このコマンドは python のテストスィートを実行します。python コードに変更を加えた場合、これの実行が成功することを確認する必要があります。
|
||||||
|
|
||||||
|
**使用法**:
|
||||||
|
|
||||||
|
```
|
||||||
|
qmk pytest
|
||||||
|
```
|
||||||
@@ -113,7 +113,7 @@ compile.keymap: skully -> None
|
|||||||
|-----|---------------|-------------|
|
|-----|---------------|-------------|
|
||||||
| user.keyboard | None | キーボードのパス (例: `clueboard/66/rev4`) |
|
| user.keyboard | None | キーボードのパス (例: `clueboard/66/rev4`) |
|
||||||
| user.keymap | None | キーマップ名 (例: `default`) |
|
| user.keymap | None | キーマップ名 (例: `default`) |
|
||||||
| user.name | None | ユーザの github のユーザ名。 |
|
| user.name | None | ユーザの GitHub のユーザ名。 |
|
||||||
|
|
||||||
# 全ての設定オプション
|
# 全ての設定オプション
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
# QMK の設定
|
# QMK の設定
|
||||||
|
|
||||||
<!---
|
<!---
|
||||||
original document: 2fe288d01:docs/config_options.md
|
original document: 0.8.62:docs/config_options.md
|
||||||
git diff 2fe288d01 HEAD -- docs/config_options.md | cat
|
git diff 0.8.62 HEAD -- docs/config_options.md | cat
|
||||||
-->
|
-->
|
||||||
|
|
||||||
QMK はほぼ無制限に設定可能です。可能なところはいかなるところでも、やりすぎな程、ユーザーがコードサイズを犠牲にしてでも彼らのキーボードをカスタマイズをすることを許しています。ただし、このレベルの柔軟性により設定が困難になります。
|
QMK はほぼ無制限に設定可能です。可能なところはいかなるところでも、やりすぎな程、ユーザーがコードサイズを犠牲にしてでも彼らのキーボードをカスタマイズをすることを許しています。ただし、このレベルの柔軟性により設定が困難になります。
|
||||||
@@ -39,167 +39,173 @@ QMK での全ての利用可能な設定にはデフォルトがあります。
|
|||||||
|
|
||||||
## ハードウェアオプション
|
## ハードウェアオプション
|
||||||
* `#define VENDOR_ID 0x1234`
|
* `#define VENDOR_ID 0x1234`
|
||||||
* VID を定義します。ほとんどの DIY プロジェクトにおいて、任意のものを定義できます
|
* VID を定義します。ほとんどの DIY プロジェクトにおいて、任意のものを定義できます
|
||||||
* `#define PRODUCT_ID 0x5678`
|
* `#define PRODUCT_ID 0x5678`
|
||||||
* PID を定義します。ほとんどの DIY プロジェクトでは、任意のものを定義できます
|
* PID を定義します。ほとんどの DIY プロジェクトでは、任意のものを定義できます
|
||||||
* `#define DEVICE_VER 0`
|
* `#define DEVICE_VER 0`
|
||||||
* デバイスのバージョンを定義します (多くの場合リビジョンに使われます)
|
* デバイスのバージョンを定義します (多くの場合リビジョンに使われます)
|
||||||
* `#define MANUFACTURER Me`
|
* `#define MANUFACTURER Me`
|
||||||
* 一般的に、誰もしくはどのブランドがボードを作成したか
|
* 一般的に、誰もしくはどのブランドがボードを作成したか
|
||||||
* `#define PRODUCT Board`
|
* `#define PRODUCT Board`
|
||||||
* キーボードの名前
|
* キーボードの名前
|
||||||
* `#define DESCRIPTION a keyboard`
|
* `#define DESCRIPTION a keyboard`
|
||||||
* キーボードの簡単な説明
|
* キーボードの簡単な説明
|
||||||
* `#define MATRIX_ROWS 5`
|
* `#define MATRIX_ROWS 5`
|
||||||
* キーボードのマトリックスの行の数
|
* キーボードのマトリックスの行の数
|
||||||
* `#define MATRIX_COLS 15`
|
* `#define MATRIX_COLS 15`
|
||||||
* キーボードのマトリックスの列の数
|
* キーボードのマトリックスの列の数
|
||||||
* `#define MATRIX_ROW_PINS { D0, D5, B5, B6 }`
|
* `#define MATRIX_ROW_PINS { D0, D5, B5, B6 }`
|
||||||
* 行のピン、上から下へ
|
* 行のピン、上から下へ
|
||||||
* `#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7 }`
|
* `#define MATRIX_COL_PINS { F1, F0, B0, C7, F4, F5, F6, F7, D4, D6, B4, D7 }`
|
||||||
* 列のピン、左から右へ
|
* 列のピン、左から右へ
|
||||||
|
* `#define MATRIX_IO_DELAY 30`
|
||||||
|
* マトリックスピン状態の変更と値の読み取り間のマイクロ秒単位の遅延
|
||||||
* `#define UNUSED_PINS { D1, D2, D3, B1, B2, B3 }`
|
* `#define UNUSED_PINS { D1, D2, D3, B1, B2, B3 }`
|
||||||
* 参考として、キーボードで使われていないピン
|
* 参考として、キーボードで使われていないピン
|
||||||
* `#define MATRIX_HAS_GHOST`
|
* `#define MATRIX_HAS_GHOST`
|
||||||
* マトリックスにゴーストがあるか(ありそうにないか)定義します
|
* マトリックスにゴーストがあるか(ありそうにないか)定義します
|
||||||
* `#define DIODE_DIRECTION COL2ROW`
|
* `#define DIODE_DIRECTION COL2ROW`
|
||||||
* COL2ROW あるいは ROW2COL - マトリックスがどのように設定されているか。COL2ROW は、スイッチとロウ(行)ラインの間にダイオードが黒い印をロウ(行)ラインに向けて置いてあることを意味します。
|
* COL2ROW あるいは ROW2COL - マトリックスがどのように設定されているか。COL2ROW は、スイッチとロウ(行)ラインの間にダイオードが黒い印をロウ(行)ラインに向けて置いてあることを意味します。
|
||||||
* `#define DIRECT_PINS { { F1, F0, B0, C7 }, { F4, F5, F6, F7 } }`
|
* `#define DIRECT_PINS { { F1, F0, B0, C7 }, { F4, F5, F6, F7 } }`
|
||||||
* ロウ(行)ラインとカラム(列)ラインにマップされているピンを左から右に。各スイッチが個別のピンとグラウンドに接続されているマトリックスを定義します。
|
* ロウ(行)ラインとカラム(列)ラインにマップされているピンを左から右に。各スイッチが個別のピンとグラウンドに接続されているマトリックスを定義します。
|
||||||
* `#define AUDIO_VOICES`
|
* `#define AUDIO_VOICES`
|
||||||
* (循環させるために)代替音声を有効にします
|
* (循環させるために)代替音声を有効にします
|
||||||
* `#define C4_AUDIO`
|
* `#define C4_AUDIO`
|
||||||
* ピン C4 のオーディオを有効にします
|
* ピン C4 のオーディオを有効にします
|
||||||
* `#define C5_AUDIO`
|
* `#define C5_AUDIO`
|
||||||
* ピン C5 のオーディオを有効にします
|
* ピン C5 のオーディオを有効にします
|
||||||
* `#define C6_AUDIO`
|
* `#define C6_AUDIO`
|
||||||
* ピン C6 のオーディオを有効にします
|
* ピン C6 のオーディオを有効にします
|
||||||
* `#define B5_AUDIO`
|
* `#define B5_AUDIO`
|
||||||
* ピン B5 のオーディオを有効にします (C[4-6]\_AUDIO の1つとともに B[5-7]\_AUDIO の1つが有効にされている場合、疑似ステレオが有効にされます)
|
* ピン B5 のオーディオを有効にします (C[4-6]\_AUDIO の1つとともに B[5-7]\_AUDIO の1つが有効にされている場合、疑似ステレオが有効にされます)
|
||||||
* `#define B6_AUDIO`
|
* `#define B6_AUDIO`
|
||||||
* ピン B6 のオーディオを有効にします (C[4-6]\_AUDIO の1つとともに B[5-7]\_AUDIO の1つが有効にされている場合、疑似ステレオが有効にされます)
|
* ピン B6 のオーディオを有効にします (C[4-6]\_AUDIO の1つとともに B[5-7]\_AUDIO の1つが有効にされている場合、疑似ステレオが有効にされます)
|
||||||
* `#define B7_AUDIO`
|
* `#define B7_AUDIO`
|
||||||
* ピン B7 のオーディオを有効にします (C[4-6]\_AUDIO の1つとともに B[5-7]\_AUDIO の1つが有効にされている場合、疑似ステレオが有効にされます)
|
* ピン B7 のオーディオを有効にします (C[4-6]\_AUDIO の1つとともに B[5-7]\_AUDIO の1つが有効にされている場合、疑似ステレオが有効にされます)
|
||||||
* `#define BACKLIGHT_PIN B7`
|
* `#define BACKLIGHT_PIN B7`
|
||||||
* バックライトのピン
|
* バックライトのピン
|
||||||
* `#define BACKLIGHT_LEVELS 3`
|
* `#define BACKLIGHT_LEVELS 3`
|
||||||
* バックライトのレベル数 (off を除いて最大31)
|
* バックライトのレベル数 (off を除いて最大31)
|
||||||
* `#define BACKLIGHT_BREATHING`
|
* `#define BACKLIGHT_BREATHING`
|
||||||
* バックライトのブレスを有効にします
|
* バックライトのブレスを有効にします
|
||||||
* `#define BREATHING_PERIOD 6`
|
* `#define BREATHING_PERIOD 6`
|
||||||
* 1つのバックライトの "ブレス" の長さの秒数
|
* 1つのバックライトの "ブレス" の長さの秒数
|
||||||
* `#define DEBOUNCE 5`
|
* `#define DEBOUNCE 5`
|
||||||
* ピンの値を読み取る時の遅延 (5がデフォルト)
|
* ピンの値を読み取る時の遅延 (5がデフォルト)
|
||||||
* `#define LOCKING_SUPPORT_ENABLE`
|
* `#define LOCKING_SUPPORT_ENABLE`
|
||||||
* メカニカルロックのサポート。キーマップで KC_LCAP、 KC_LNUM そして KC_LSCR を使えるようにします
|
* メカニカルロックのサポート。キーマップで KC_LCAP、 KC_LNUM そして KC_LSCR を使えるようにします
|
||||||
* `#define LOCKING_RESYNC_ENABLE`
|
* `#define LOCKING_RESYNC_ENABLE`
|
||||||
* キーボードの LED の状態をスイッチの状態と一致させ続けようとします
|
* キーボードの LED の状態をスイッチの状態と一致させ続けようとします
|
||||||
* `#define IS_COMMAND() (get_mods() == MOD_MASK_SHIFT)`
|
* `#define IS_COMMAND() (get_mods() == MOD_MASK_SHIFT)`
|
||||||
* マジックコマンドの使用を可能にするキーの組み合わせ (デバッグに便利です)
|
* マジックコマンドの使用を可能にするキーの組み合わせ (デバッグに便利です)
|
||||||
* `#define USB_MAX_POWER_CONSUMPTION 500`
|
* `#define USB_MAX_POWER_CONSUMPTION 500`
|
||||||
* デバイスの USB 経由の最大電力(mA) を設定します (デフォルト: 500)
|
* デバイスの USB 経由の最大電力(mA) を設定します (デフォルト: 500)
|
||||||
* `#define USB_POLLING_INTERVAL_MS 10`
|
* `#define USB_POLLING_INTERVAL_MS 10`
|
||||||
* キーボード、マウス および 共有 (NKRO/メディアキー) インタフェースのための USB ポーリングレートをミリ秒で設定します
|
* キーボード、マウス および 共有 (NKRO/メディアキー) インタフェースのための USB ポーリングレートをミリ秒で設定します
|
||||||
* `#define F_SCL 100000L`
|
* `#define F_SCL 100000L`
|
||||||
* I2C を使用するキーボードのための I2C クロックレート速度を設定します。デフォルトは `400000L` ですが、`split_common` を使っているキーボードは別でデフォルトは `100000L` です。
|
* I2C を使用するキーボードのための I2C クロックレート速度を設定します。デフォルトは `400000L` ですが、`split_common` を使っているキーボードは別でデフォルトは `100000L` です。
|
||||||
|
|
||||||
## 無効にできる機能
|
## 無効にできる機能
|
||||||
|
|
||||||
これらのオプションを定義すると、関連する機能が無効になり、コードサイズを節約できます。
|
これらのオプションを定義すると、関連する機能が無効になり、コードサイズを節約できます。
|
||||||
|
|
||||||
* `#define NO_DEBUG`
|
* `#define NO_DEBUG`
|
||||||
* デバッグを無効にします
|
* デバッグを無効にします
|
||||||
* `#define NO_PRINT`
|
* `#define NO_PRINT`
|
||||||
* hid_listen を使った出力やデバッグを無効にします
|
* hid_listen を使った出力やデバッグを無効にします
|
||||||
* `#define NO_ACTION_LAYER`
|
* `#define NO_ACTION_LAYER`
|
||||||
* レイヤーを無効にします
|
* レイヤーを無効にします
|
||||||
* `#define NO_ACTION_TAPPING`
|
* `#define NO_ACTION_TAPPING`
|
||||||
* タップダンスと他のタップ機能を無効にします
|
* タップダンスと他のタップ機能を無効にします
|
||||||
* `#define NO_ACTION_ONESHOT`
|
* `#define NO_ACTION_ONESHOT`
|
||||||
* ワンショットモディファイアを無効にします
|
* ワンショットモディファイアを無効にします
|
||||||
* `#define NO_ACTION_MACRO`
|
* `#define NO_ACTION_MACRO`
|
||||||
* 古い形式のマクロ処理を無効にします: MACRO() & action_get_macro
|
* 古い形式のマクロ処理を無効にします: MACRO() & action_get_macro
|
||||||
* `#define NO_ACTION_FUNCTION`
|
* `#define NO_ACTION_FUNCTION`
|
||||||
* fn_actions 配列(非推奨)からの action_function() の呼び出しを無効にします
|
* fn_actions 配列(非推奨)からの action_function() の呼び出しを無効にします
|
||||||
|
|
||||||
## 有効にできる機能
|
## 有効にできる機能
|
||||||
|
|
||||||
これらのオプションを定義すると、関連する機能が有効になり、コードサイズが大きくなるかもしれません。
|
これらのオプションを定義すると、関連する機能が有効になり、コードサイズが大きくなるかもしれません。
|
||||||
|
|
||||||
* `#define FORCE_NKRO`
|
* `#define FORCE_NKRO`
|
||||||
* NKRO をデフォルトでオンにする必要があります。これにより EEPROM の設定に関係なく、キーボードの起動時に NKRO が強制的にオンになります。NKRO は引き続きオフにできますが、キーボードを再起動すると再びオンになります。
|
* NKRO をデフォルトでオンにする必要があります。これにより EEPROM の設定に関係なく、キーボードの起動時に NKRO が強制的にオンになります。NKRO は引き続きオフにできますが、キーボードを再起動すると再びオンになります。
|
||||||
* `#define STRICT_LAYER_RELEASE`
|
* `#define STRICT_LAYER_RELEASE`
|
||||||
* キーリリースがどのレイヤーから来たのかを覚えるのではなく、現在のレイヤースタックを使って強制的に評価されるようにします (高度なケースに使われます)
|
* キーリリースがどのレイヤーから来たのかを覚えるのではなく、現在のレイヤースタックを使って強制的に評価されるようにします (高度なケースに使われます)
|
||||||
|
|
||||||
## 設定可能な挙動
|
## 設定可能な挙動
|
||||||
|
|
||||||
* `#define TAPPING_TERM 200`
|
* `#define TAPPING_TERM 200`
|
||||||
* タップがホールドになるまでの時間。500以上に設定された場合、タップ期間中にタップされたキーもホールドになります。(訳注: PERMISSIVE_HOLDも参照)
|
* タップがホールドになるまでの時間。500以上に設定された場合、タップ期間中にタップされたキーもホールドになります。(訳注: PERMISSIVE_HOLDも参照)
|
||||||
* `#define TAPPING_TERM_PER_KEY`
|
* `#define TAPPING_TERM_PER_KEY`
|
||||||
* キーごとの `TAPPING_TERM` 設定の処理を有効にします
|
* キーごとの `TAPPING_TERM` 設定の処理を有効にします
|
||||||
* `#define RETRO_TAPPING`
|
* `#define RETRO_TAPPING`
|
||||||
* 押下とリリースの間に他のキーによる中断がなければ、TAPPING_TERM の後であってもとにかくタップします
|
* 押下とリリースの間に他のキーによる中断がなければ、TAPPING_TERM の後であってもとにかくタップします
|
||||||
* 詳細は [Retro Tapping](ja/feature_advanced_keycodes.md#retro-tapping) を見てください
|
* 詳細は [Retro Tapping](ja/tap_hold.md#retro-tapping) を見てください
|
||||||
* `#define TAPPING_TOGGLE 2`
|
* `#define TAPPING_TOGGLE 2`
|
||||||
* トグルを引き起こす前のタップ数
|
* トグルを引き起こす前のタップ数
|
||||||
* `#define PERMISSIVE_HOLD`
|
* `#define PERMISSIVE_HOLD`
|
||||||
* `TAPPING_TERM` にヒットしていなくても、リリースする前に別のキーが押されると、タップとフォールドキーがホールドを引き起こします
|
* `TAPPING_TERM` にヒットしていなくても、リリースする前に別のキーが押されると、タップとホールドキーがホールドを引き起こします
|
||||||
* 詳細は [Permissive Hold](ja/feature_advanced_keycodes.md#permissive-hold) を見てください
|
* 詳細は [Permissive Hold](ja/tap_hold.md#permissive-hold) を見てください
|
||||||
|
* `#define PERMISSIVE_HOLD_PER_KEY`
|
||||||
|
* キーごとの `PERMISSIVE_HOLD` 設定の処理を有効にします
|
||||||
* `#define IGNORE_MOD_TAP_INTERRUPT`
|
* `#define IGNORE_MOD_TAP_INTERRUPT`
|
||||||
* 両方のキーに `TAPPING_TERM` を適用することで、ホールド時に他のキーに変換するキーを使ってローリングコンボ (zx) をすることができるようにします
|
* 両方のキーに `TAPPING_TERM` を適用することで、ホールド時に他のキーに変換するキーを使ってローリングコンボ (zx) をすることができるようにします
|
||||||
* 詳細は [Mod tap interrupt](ja/feature_advanced_keycodes.md#ignore-mod-tap-interrupt) を見てください
|
* 詳細は [Ignore Mod Tap Interrupt](ja/tap_hold.md#ignore-mod-tap-interrupt) を見てください
|
||||||
* `#define IGNORE_MOD_TAP_INTERRUPT_PER_KEY`
|
* `#define IGNORE_MOD_TAP_INTERRUPT_PER_KEY`
|
||||||
* キーごとの `IGNORE_MOD_TAP_INTERRUPT` 設定の処理を有効にします
|
* キーごとの `IGNORE_MOD_TAP_INTERRUPT` 設定の処理を有効にします
|
||||||
* `#define TAPPING_FORCE_HOLD`
|
* `#define TAPPING_FORCE_HOLD`
|
||||||
* タップされた直後に、デュアルロールキーを修飾子として使用できるようにします
|
* タップされた直後に、デュアルロールキーを修飾子として使用できるようにします
|
||||||
* [Hold after tap](ja/feature_advanced_keycodes.md#tapping-force-hold)を見てください
|
* [Tapping Force Hold](ja/tap_hold.md#tapping-force-hold)を見てください
|
||||||
* タップトグル機能を無効にします (`TT` あるいは One Shot Tap Toggle)
|
* タップトグル機能を無効にします (`TT` あるいは One Shot Tap Toggle)
|
||||||
* `#define TAPPING_FORCE_HOLD_PER_KEY`
|
* `#define TAPPING_FORCE_HOLD_PER_KEY`
|
||||||
* キーごとの `TAPPING_FORCE_HOLD` 設定処理を有効にします。
|
* キーごとの `TAPPING_FORCE_HOLD` 設定処理を有効にします。
|
||||||
* `#define LEADER_TIMEOUT 300`
|
* `#define LEADER_TIMEOUT 300`
|
||||||
* リーダーキーがタイムアウトするまでの時間
|
* リーダーキーがタイムアウトするまでの時間
|
||||||
* タイムアウトする前にシーケンスを終了できない場合は、タイムアウトの設定を増やす必要があるかもしれません。あるいは、`LEADER_PER_KEY_TIMING` オプションを有効にすると良いでしょう。これは各キーがタップされた後でタイムアウトを再設定します。
|
* タイムアウトする前にシーケンスを終了できない場合は、タイムアウトの設定を増やす必要があるかもしれません。あるいは、`LEADER_PER_KEY_TIMING` オプションを有効にすると良いでしょう。これは各キーがタップされた後でタイムアウトを再設定します。
|
||||||
* `#define LEADER_PER_KEY_TIMING`
|
* `#define LEADER_PER_KEY_TIMING`
|
||||||
* 全体では無く各キーを押すたびに実行されるリーダーキーコードのタイマーを設定します
|
* 全体では無く各キーを押すたびに実行されるリーダーキーコードのタイマーを設定します
|
||||||
* `#define LEADER_KEY_STRICT_KEY_PROCESSING`
|
* `#define LEADER_KEY_STRICT_KEY_PROCESSING`
|
||||||
* Mod-Tap および Layer-Tap キーコードのためのキーコードフィルタリングを無効にします。例えば、これを有効にすると、`KC_A` を使いたい場合は `MT(MOD_CTL, KC_A)` を指定する必要があります。
|
* Mod-Tap および Layer-Tap キーコードのためのキーコードフィルタリングを無効にします。例えば、これを有効にすると、`KC_A` を使いたい場合は `MT(MOD_CTL, KC_A)` を指定する必要があります。
|
||||||
* `#define ONESHOT_TIMEOUT 300`
|
* `#define ONESHOT_TIMEOUT 300`
|
||||||
* ワンショットがタイムアウトするまでの時間
|
* ワンショットがタイムアウトするまでの時間
|
||||||
* `#define ONESHOT_TAP_TOGGLE 2`
|
* `#define ONESHOT_TAP_TOGGLE 2`
|
||||||
* ワンショットトグルが引き起こされるまでのタップ数
|
* ワンショットトグルが引き起こされるまでのタップ数
|
||||||
* `#define QMK_KEYS_PER_SCAN 4`
|
* `#define QMK_KEYS_PER_SCAN 4`
|
||||||
* 走査ごとに1つ以上のキーを送信できるようにします。デフォルトでは、走査ごとに `process_record()` 経由で1つのキーイベントのみが送信されます。これはほとんどのタイピングにほとんど影響しませんが、多くのコードを入力しているか、走査レートが最初から遅い場合、キーイベントの処理に多少の遅延が生じる可能性があります。それぞれのプレスとリリースは別のイベントです。スキャン時間が 1ms 程度のキーボードの場合、とても高速なタイピストでさえ、実際にキーボードから数 ms 以上の遅延を発生させるのに必要な 500 キーストロークを1秒間に生成することはないでしょう。しかし、3~4ms の走査時間でコードを入力している場合はどうでしょうか?おそらくこれが必要です。
|
* 走査ごとに1つ以上のキーを送信できるようにします。デフォルトでは、走査ごとに `process_record()` 経由で1つのキーイベントのみが送信されます。これはほとんどのタイピングにほとんど影響しませんが、多くのコードを入力しているか、走査レートが最初から遅い場合、キーイベントの処理に多少の遅延が生じる可能性があります。それぞれのプレスとリリースは別のイベントです。スキャン時間が 1ms 程度のキーボードの場合、とても高速なタイピストでさえ、実際にキーボードから数 ms 以上の遅延を発生させるのに必要な 500 キーストロークを1秒間に生成することはないでしょう。しかし、3~4ms の走査時間でコードを入力している場合はどうでしょうか?おそらくこれが必要です。
|
||||||
* `#define COMBO_COUNT 2`
|
* `#define COMBO_COUNT 2`
|
||||||
* [コンボ](ja/feature_combo.md)機能で使っているコンボの数にこれを設定します。
|
* [コンボ](ja/feature_combo.md)機能で使っているコンボの数にこれを設定します。
|
||||||
* `#define COMBO_TERM 200`
|
* `#define COMBO_TERM 200`
|
||||||
* コンボキーが検出されるまでの時間。定義されていない場合は、デフォルトは `TAPPING_TERM` です。
|
* コンボキーが検出されるまでの時間。定義されていない場合は、デフォルトは `TAPPING_TERM` です。
|
||||||
* `#define TAP_CODE_DELAY 100`
|
* `#define TAP_CODE_DELAY 100`
|
||||||
* 適切な登録に問題がある場合(VUSB ボードで珍しくない)、`register_code` と `unregister_code` の間の遅延を設定します。値はミリ秒です。
|
* 適切な登録に問題がある場合(VUSB ボードで珍しくない)、`register_code` と `unregister_code` の間の遅延を設定します。値はミリ秒です。
|
||||||
* `#define TAP_HOLD_CAPS_DELAY 80`
|
* `#define TAP_HOLD_CAPS_DELAY 80`
|
||||||
* MacOS で特別な処理が行われるため、`KC_CAPSLOCK` を使う時にタップホールドキー (`LT`, `MT`) に遅延を設定します。この値はミリ秒で、定義されていない場合はデフォルトは80msです。macOS については、これを200以上に設定すると良いでしょう。
|
* MacOS で特別な処理が行われるため、`KC_CAPSLOCK` を使う時にタップホールドキー (`LT`, `MT`) に遅延を設定します。この値はミリ秒で、定義されていない場合はデフォルトは80msです。macOS については、これを200以上に設定すると良いでしょう。
|
||||||
|
|
||||||
## RGB ライト設定 :id=rgb-light-configuration
|
## RGB ライト設定 :id=rgb-light-configuration
|
||||||
|
|
||||||
* `#define RGB_DI_PIN D7`
|
* `#define RGB_DI_PIN D7`
|
||||||
* WS2812 の DI 端子につなぐピン
|
* WS2812 の DI 端子につなぐピン
|
||||||
* `#define RGBLIGHT_ANIMATIONS`
|
* `#define RGBLIGHT_ANIMATIONS`
|
||||||
* RGB アニメーションを実行します
|
* RGB アニメーションを実行します
|
||||||
|
* `#define RGBLIGHT_LAYERS`
|
||||||
|
* オンとオフを切り替えることができる [ライトレイヤー](ja/feature_rgblight.md) を定義できます。現在のキーボードレイヤーまたは Caps Lock 状態を表示するのに最適です。
|
||||||
* `#define RGBLED_NUM 12`
|
* `#define RGBLED_NUM 12`
|
||||||
* LED の数
|
* LED の数
|
||||||
* `#define RGBLIGHT_SPLIT`
|
* `#define RGBLIGHT_SPLIT`
|
||||||
* 分割キーボードの左半分の RGB LED の出力を右半分の RGB LED の入力につなげるかわりに、それぞれの側で個別にコントローラの出力ピンが直接 RGB LED の入力に繋がっているときは、この定義が必要です。
|
* 分割キーボードの左半分の RGB LED の出力を右半分の RGB LED の入力につなげるかわりに、それぞれの側で個別にコントローラの出力ピンが直接 RGB LED の入力に繋がっているときは、この定義が必要です。
|
||||||
* `#define RGBLED_SPLIT { 6, 6 }`
|
* `#define RGBLED_SPLIT { 6, 6 }`
|
||||||
* 分割キーボードの各半分の `RGB_DI_PIN` に直接配線されている接続されている LED の数
|
* 分割キーボードの各半分の `RGB_DI_PIN` に直接配線されている接続されている LED の数
|
||||||
* 最初の値は左半分の LED の数を示し、2番目の値は右半分です。
|
* 最初の値は左半分の LED の数を示し、2番目の値は右半分です。
|
||||||
* RGBLED_SPLIT が定義されている場合、RGBLIGHT_SPLIT は暗黙的に定義されます。
|
* RGBLED_SPLIT が定義されている場合、RGBLIGHT_SPLIT は暗黙的に定義されます。
|
||||||
* `#define RGBLIGHT_HUE_STEP 12`
|
* `#define RGBLIGHT_HUE_STEP 12`
|
||||||
* 色相の増減時のステップ単位
|
* 色相の増減時のステップ単位
|
||||||
* `#define RGBLIGHT_SAT_STEP 25`
|
* `#define RGBLIGHT_SAT_STEP 25`
|
||||||
* 彩度の増減時のステップ単位
|
* 彩度の増減時のステップ単位
|
||||||
* `#define RGBLIGHT_VAL_STEP 12`
|
* `#define RGBLIGHT_VAL_STEP 12`
|
||||||
* 値(明度)の増減時のステップ単位
|
* 値(明度)の増減時のステップ単位
|
||||||
* `#define RGBW`
|
* `#define RGBW`
|
||||||
* RGBW LED のサポートを有効にします
|
* RGBW LED のサポートを有効にします
|
||||||
|
|
||||||
## マウスキーオプション
|
## マウスキーオプション
|
||||||
|
|
||||||
@@ -214,7 +220,7 @@ QMK での全ての利用可能な設定にはデフォルトがあります。
|
|||||||
分割キーボード固有のオプション。あなたの rules.mk に 'SPLIT_KEYBOARD = yes' が有ることを確認してください。
|
分割キーボード固有のオプション。あなたの rules.mk に 'SPLIT_KEYBOARD = yes' が有ることを確認してください。
|
||||||
|
|
||||||
* `SPLIT_TRANSPORT = custom`
|
* `SPLIT_TRANSPORT = custom`
|
||||||
* 標準の分割通信ルーチンをカスタムのものに置き換えることができます。現在、ARM ベースの分割キーボードはこれを使わなければなりません。
|
* 標準の分割通信ルーチンをカスタムのものに置き換えることができます。現在、ARM ベースの分割キーボードはこれを使わなければなりません。
|
||||||
|
|
||||||
### 左右の設定
|
### 左右の設定
|
||||||
|
|
||||||
@@ -233,52 +239,52 @@ QMK での全ての利用可能な設定にはデフォルトがあります。
|
|||||||
#### 左右を定義します
|
#### 左右を定義します
|
||||||
|
|
||||||
* `#define SPLIT_HAND_PIN B7`
|
* `#define SPLIT_HAND_PIN B7`
|
||||||
* high/low ピンを使って左右を決定します。low = 右手、high = 左手。`B7` を使っているピンに置き換えます。これはオプションで、`SPLIT_HAND_PIN` が未定義のままである場合、EE_HANDS メソッドまたは標準の Let's Splitが使っている MASTER_LEFT / MASTER_RIGHT 定義をまだ使うことができます。
|
* high/low ピンを使って左右を決定します。low = 右手、high = 左手。`B7` を使っているピンに置き換えます。これはオプションで、`SPLIT_HAND_PIN` が未定義のままである場合、EE_HANDS メソッドまたは標準の Let's Splitが使っている MASTER_LEFT / MASTER_RIGHT 定義をまだ使うことができます。
|
||||||
|
|
||||||
* `#define EE_HANDS` (`SPLIT_HAND_PIN` が定義されていない場合のみ動作します)
|
* `#define EE_HANDS` (`SPLIT_HAND_PIN` が定義されていない場合のみ動作します)
|
||||||
* `eeprom-lefthand.eep`/`eeprom-righthand.eep` がそれぞれの半分に書き込まれた後で、EEPROM 内に格納されている左右の設定の値を読み込みます。
|
* `eeprom-lefthand.eep`/`eeprom-righthand.eep` がそれぞれの半分に書き込まれた後で、EEPROM 内に格納されている左右の設定の値を読み込みます。
|
||||||
|
|
||||||
* `#define MASTER_RIGHT`
|
* `#define MASTER_RIGHT`
|
||||||
* マスター側が右側と定義されます。
|
* マスター側が右側と定義されます。
|
||||||
|
|
||||||
### 他のオプション
|
### 他のオプション
|
||||||
|
|
||||||
* `#define USE_I2C`
|
* `#define USE_I2C`
|
||||||
* Serial の代わりに I2C を使う場合 (デフォルトは serial)
|
* Serial の代わりに I2C を使う場合 (デフォルトは serial)
|
||||||
|
|
||||||
* `#define SOFT_SERIAL_PIN D0`
|
* `#define SOFT_SERIAL_PIN D0`
|
||||||
* serial を使う場合、これを定義します。`D0` あるいは `D1`,`D2`,`D3`,`E6`。
|
* serial を使う場合、これを定義します。`D0` あるいは `D1`,`D2`,`D3`,`E6`。
|
||||||
|
|
||||||
* `#define MATRIX_ROW_PINS_RIGHT { <row pins> }`
|
* `#define MATRIX_ROW_PINS_RIGHT { <row pins> }`
|
||||||
* `#define MATRIX_COL_PINS_RIGHT { <col pins> }`
|
* `#define MATRIX_COL_PINS_RIGHT { <col pins> }`
|
||||||
* 右半分に左半分と異なるピン配置を指定したい場合は、`MATRIX_ROW_PINS_RIGHT`/`MATRIX_COL_PINS_RIGHT` を定義することができます。現在のところ、`MATRIX_ROW_PINS` のサイズは `MATRIX_ROW_PINS_RIGHT` と同じでなければならず、列の定義も同様です。
|
* 右半分に左半分と異なるピン配置を指定したい場合は、`MATRIX_ROW_PINS_RIGHT`/`MATRIX_COL_PINS_RIGHT` を定義することができます。現在のところ、`MATRIX_ROW_PINS` のサイズは `MATRIX_ROW_PINS_RIGHT` と同じでなければならず、列の定義も同様です。
|
||||||
|
|
||||||
* `#define DIRECT_PINS_RIGHT { { F1, F0, B0, C7 }, { F4, F5, F6, F7 } }`
|
* `#define DIRECT_PINS_RIGHT { { F1, F0, B0, C7 }, { F4, F5, F6, F7 } }`
|
||||||
* 右半分に左半分と異なる直接ピン配置を指定したい場合は、`DIRECT_PINS_RIGHT` を定義することができます。現在のところ、`DIRECT_PINS` のサイズは `DIRECT_PINS_RIGHT` と同じでなければなりません。
|
* 右半分に左半分と異なる直接ピン配置を指定したい場合は、`DIRECT_PINS_RIGHT` を定義することができます。現在のところ、`DIRECT_PINS` のサイズは `DIRECT_PINS_RIGHT` と同じでなければなりません。
|
||||||
|
|
||||||
* `#define RGBLED_SPLIT { 6, 6 }`
|
* `#define RGBLED_SPLIT { 6, 6 }`
|
||||||
* [RGB ライト設定](#rgb-light-configuration)を見てください。
|
* [RGB ライト設定](#rgb-light-configuration)を見てください。
|
||||||
|
|
||||||
* `#define SELECT_SOFT_SERIAL_SPEED <speed>` (デフォルトの速度は1です)
|
* `#define SELECT_SOFT_SERIAL_SPEED <speed>` (デフォルトの速度は1です)
|
||||||
* serial 通信を使う時のプロトコルの速度を設定します。
|
* serial 通信を使う時のプロトコルの速度を設定します。
|
||||||
* 速度:
|
* 速度:
|
||||||
* 0: 約 189kbps (実験目的のみ)
|
* 0: 約 189kbps (実験目的のみ)
|
||||||
* 1: 約 137kbps (デフォルト)
|
* 1: 約 137kbps (デフォルト)
|
||||||
* 2: 約 75kbps
|
* 2: 約 75kbps
|
||||||
* 3: 約 39kbps
|
* 3: 約 39kbps
|
||||||
* 4: 約 26kbps
|
* 4: 約 26kbps
|
||||||
* 5: 約 20kbps
|
* 5: 約 20kbps
|
||||||
|
|
||||||
* `#define SPLIT_USB_DETECT`
|
* `#define SPLIT_USB_DETECT`
|
||||||
* マスタ/スレーブを委任する時に(タイムアウト付きで) USB 接続を検出します
|
* マスタ/スレーブを委任する時に(タイムアウト付きで) USB 接続を検出します
|
||||||
* ARM についてはデフォルトの挙動
|
* ARM についてはデフォルトの挙動
|
||||||
* AVR Teensy については必須
|
* AVR Teensy については必須
|
||||||
|
|
||||||
* `#define SPLIT_USB_TIMEOUT 2000`
|
* `#define SPLIT_USB_TIMEOUT 2000`
|
||||||
* `SPLIT_USB_DETECT` を使う時のマスタ/スレーブを検出する場合の最大タイムアウト
|
* `SPLIT_USB_DETECT` を使う時のマスタ/スレーブを検出する場合の最大タイムアウト
|
||||||
|
|
||||||
* `#define SPLIT_USB_TIMEOUT_POLL 10`
|
* `#define SPLIT_USB_TIMEOUT_POLL 10`
|
||||||
* `SPLIT_USB_DETECT` を使う時のマスタ/スレーブを検出する場合のポーリング頻度
|
* `SPLIT_USB_DETECT` を使う時のマスタ/スレーブを検出する場合のポーリング頻度
|
||||||
|
|
||||||
# `rules.mk` ファイル
|
# `rules.mk` ファイル
|
||||||
|
|
||||||
@@ -287,11 +293,11 @@ QMK での全ての利用可能な設定にはデフォルトがあります。
|
|||||||
## ビルドオプション
|
## ビルドオプション
|
||||||
|
|
||||||
* `DEFAULT_FOLDER`
|
* `DEFAULT_FOLDER`
|
||||||
* キーボードに1つ以上のサブフォルダがある場合にデフォルトのフォルダを指定するために使われます。
|
* キーボードに1つ以上のサブフォルダがある場合にデフォルトのフォルダを指定するために使われます。
|
||||||
* `FIRMWARE_FORMAT`
|
* `FIRMWARE_FORMAT`
|
||||||
* ビルドの後でルート `qmk_firmware` フォルダにコピーされる形式 (bin, hex) を定義します。
|
* ビルドの後でルート `qmk_firmware` フォルダにコピーされる形式 (bin, hex) を定義します。
|
||||||
* `SRC`
|
* `SRC`
|
||||||
* コンパイル・リンクリストにファイルを追加するために使われます。
|
* コンパイル・リンクリストにファイルを追加するために使われます。
|
||||||
* `LIB_SRC`
|
* `LIB_SRC`
|
||||||
* コンパイル・リンクリストにライブラリとしてファイルを追加するために使われます。
|
* コンパイル・リンクリストにライブラリとしてファイルを追加するために使われます。
|
||||||
`LIB_SRC` で指定されたファイルは、`SRC` で指定されたファイルの後にリンクされます。
|
`LIB_SRC` で指定されたファイルは、`SRC` で指定されたファイルの後にリンクされます。
|
||||||
@@ -307,11 +313,11 @@ QMK での全ての利用可能な設定にはデフォルトがあります。
|
|||||||
... a.o c.o ... lib_b.a lib_d.a ...
|
... a.o c.o ... lib_b.a lib_d.a ...
|
||||||
```
|
```
|
||||||
* `LAYOUTS`
|
* `LAYOUTS`
|
||||||
* このキーボードがサポートする[レイアウト](ja/feature_layouts.md)のリスト
|
* このキーボードがサポートする[レイアウト](ja/feature_layouts.md)のリスト
|
||||||
* `LINK_TIME_OPTIMIZATION_ENABLE`
|
* `LINK_TIME_OPTIMIZATION_ENABLE`
|
||||||
* キーボードをコンパイルする時に、Link Time Optimization (`LTO`) を有効にします。これは処理に時間が掛かりますが、コンパイルされたサイズを大幅に減らします (そして、ファームウェアが小さいため、追加の時間は分からないくらいです)。ただし、`LTO` が有効な場合、古いマクロと関数の機能が壊れるため、自動的にこれらの機能を無効にします。これは `NO_ACTION_MACRO` と `NO_ACTION_FUNCTION` を自動的に定義することで行われます。
|
* キーボードをコンパイルする時に、Link Time Optimization (`LTO`) を有効にします。これは処理に時間が掛かりますが、コンパイルされたサイズを大幅に減らします (そして、ファームウェアが小さいため、追加の時間は分からないくらいです)。ただし、`LTO` が有効な場合、古いマクロと関数の機能が壊れるため、自動的にこれらの機能を無効にします。これは `NO_ACTION_MACRO` と `NO_ACTION_FUNCTION` を自動的に定義することで行われます。
|
||||||
* `LTO_ENABLE`
|
* `LTO_ENABLE`
|
||||||
* LINK_TIME_OPTIMIZATION_ENABLE と同じ意味です。`LINK_TIME_OPTIMIZATION_ENABLE` の代わりに `LTO_ENABLE` を使うことができます。
|
* LINK_TIME_OPTIMIZATION_ENABLE と同じ意味です。`LINK_TIME_OPTIMIZATION_ENABLE` の代わりに `LTO_ENABLE` を使うことができます。
|
||||||
|
|
||||||
## AVR MCU オプション
|
## AVR MCU オプション
|
||||||
* `MCU = atmega32u4`
|
* `MCU = atmega32u4`
|
||||||
@@ -320,56 +326,56 @@ QMK での全ての利用可能な設定にはデフォルトがあります。
|
|||||||
* `F_USB = $(F_CPU)`
|
* `F_USB = $(F_CPU)`
|
||||||
* `OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT`
|
* `OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT`
|
||||||
* `BOOTLOADER = atmel-dfu` と以下のオプション:
|
* `BOOTLOADER = atmel-dfu` と以下のオプション:
|
||||||
* `atmel-dfu`
|
* `atmel-dfu`
|
||||||
* `lufa-dfu`
|
* `lufa-dfu`
|
||||||
* `qmk-dfu`
|
* `qmk-dfu`
|
||||||
* `halfkay`
|
* `halfkay`
|
||||||
* `caterina`
|
* `caterina`
|
||||||
* `bootloadHID`
|
* `bootloadHID`
|
||||||
* `USBasp`
|
* `USBasp`
|
||||||
|
|
||||||
## 機能オプション
|
## 機能オプション :id=feature-options
|
||||||
|
|
||||||
これらを使って特定の機能のビルドを有効または無効にします。有効にすればするほどファームウェアが大きくなり、MCU には大きすぎるファームウェアを構築するリスクがあります。
|
これらを使って特定の機能のビルドを有効または無効にします。有効にすればするほどファームウェアが大きくなり、MCU には大きすぎるファームウェアを構築するリスクがあります。
|
||||||
|
|
||||||
* `BOOTMAGIC_ENABLE`
|
* `BOOTMAGIC_ENABLE`
|
||||||
* 仮想 DIP スイッチ設定
|
* 仮想 DIP スイッチ設定
|
||||||
* `MOUSEKEY_ENABLE`
|
* `MOUSEKEY_ENABLE`
|
||||||
* マウスキー
|
* マウスキー
|
||||||
* `EXTRAKEY_ENABLE`
|
* `EXTRAKEY_ENABLE`
|
||||||
* オーディオ制御とシステム制御
|
* オーディオ制御とシステム制御
|
||||||
* `CONSOLE_ENABLE`
|
* `CONSOLE_ENABLE`
|
||||||
* デバッグ用コンソール
|
* デバッグ用コンソール
|
||||||
* `COMMAND_ENABLE`
|
* `COMMAND_ENABLE`
|
||||||
* デバッグ及び設定用のコマンド
|
* デバッグ及び設定用のコマンド
|
||||||
* `COMBO_ENABLE`
|
* `COMBO_ENABLE`
|
||||||
* キーコンボ機能
|
* キーコンボ機能
|
||||||
* `NKRO_ENABLE`
|
* `NKRO_ENABLE`
|
||||||
* USB N-キーロールオーバー - これが動作しない場合は、ここを見てください: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
* USB N-キーロールオーバー - これが動作しない場合は、ここを見てください: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||||
* `AUDIO_ENABLE`
|
* `AUDIO_ENABLE`
|
||||||
* オーディオサブシステムを有効にします。
|
* オーディオサブシステムを有効にします。
|
||||||
* `RGBLIGHT_ENABLE`
|
* `RGBLIGHT_ENABLE`
|
||||||
* キーボードアンダーライト機能を有効にします
|
* キーボードアンダーライト機能を有効にします
|
||||||
* `LEADER_ENABLE`
|
* `LEADER_ENABLE`
|
||||||
* リーダーキーコードを有効にします
|
* リーダーキーコードを有効にします
|
||||||
* `MIDI_ENABLE`
|
* `MIDI_ENABLE`
|
||||||
* MIDI 制御
|
* MIDI 制御
|
||||||
* `UNICODE_ENABLE`
|
* `UNICODE_ENABLE`
|
||||||
* Unicode
|
* Unicode
|
||||||
* `BLUETOOTH_ENABLE`
|
* `BLUETOOTH_ENABLE`
|
||||||
* Adafruit EZ-Key HID で Bluetooth を有効にするレガシーオプション。BLUETOOTH を見てください
|
* Adafruit EZ-Key HID で Bluetooth を有効にするレガシーオプション。BLUETOOTH を見てください
|
||||||
* `BLUETOOTH`
|
* `BLUETOOTH`
|
||||||
* 現在のオプションは、AdafruitEzKey、AdafruitBLE、RN42
|
* 現在のオプションは、AdafruitEzKey、AdafruitBLE、RN42
|
||||||
* `SPLIT_KEYBOARD`
|
* `SPLIT_KEYBOARD`
|
||||||
* 分割キーボード (let's split や bakingpy のキーボードのようなデュアル MCU) のサポートを有効にし、quantum/split_common にある全ての必要なファイルをインクルードします
|
* 分割キーボード (let's split や bakingpy のキーボードのようなデュアル MCU) のサポートを有効にし、quantum/split_common にある全ての必要なファイルをインクルードします
|
||||||
* `CUSTOM_MATRIX`
|
* `CUSTOM_MATRIX`
|
||||||
* 標準マトリックス走査ルーチンを独自のものに置き換えることができます。
|
* 標準マトリックス走査ルーチンを独自のものに置き換えることができます。
|
||||||
* `DEBOUNCE_TYPE`
|
* `DEBOUNCE_TYPE`
|
||||||
* 標準キーデバウンスルーチンを代替または独自のものに置き換えることができます。
|
* 標準キーデバウンスルーチンを代替または独自のものに置き換えることができます。
|
||||||
* `WAIT_FOR_USB`
|
* `WAIT_FOR_USB`
|
||||||
* キーボードが起動する前に、USB 接続が確立されるのをキーボードに待機させます
|
* キーボードが起動する前に、USB 接続が確立されるのをキーボードに待機させます
|
||||||
* `NO_USB_STARTUP_CHECK`
|
* `NO_USB_STARTUP_CHECK`
|
||||||
* キーボードの起動後の usb サスペンドチェックを無効にします。通常、キーボードはタスクが実行される前にホストがウェイク アップするのを待ちます。分割キーボードは半分はウェイクアップコールを取得できませんが、マスタにコマンドを送信する必要があるため、役に立ちます。
|
* キーボードの起動後の usb サスペンドチェックを無効にします。通常、キーボードはタスクが実行される前にホストがウェイク アップするのを待ちます。分割キーボードは半分はウェイクアップコールを取得できませんが、マスタにコマンドを送信する必要があるため、役に立ちます。
|
||||||
|
|
||||||
## USB エンドポイントの制限
|
## USB エンドポイントの制限
|
||||||
|
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||||||
case KC_ENTER:
|
case KC_ENTER:
|
||||||
// enter が押された時に音を再生します
|
// enter が押された時に音を再生します
|
||||||
if (record->event.pressed) {
|
if (record->event.pressed) {
|
||||||
PLAY_NOTE_ARRAY(tone_qwerty);
|
PLAY_SONG(tone_qwerty);
|
||||||
}
|
}
|
||||||
return true; // QMK に enter のプレスまたはリリースイベントを送信させます
|
return true; // QMK に enter のプレスまたはリリースイベントを送信させます
|
||||||
default:
|
default:
|
||||||
@@ -440,7 +440,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|||||||
case KC_ENTER:
|
case KC_ENTER:
|
||||||
// enter が押された時に音を再生します
|
// enter が押された時に音を再生します
|
||||||
if (record->event.pressed) {
|
if (record->event.pressed) {
|
||||||
PLAY_NOTE_ARRAY(tone_qwerty);
|
PLAY_SONG(tone_qwerty);
|
||||||
}
|
}
|
||||||
return true; // QMK に enter のプレスまたはリリースイベントを送信させます
|
return true; // QMK に enter のプレスまたはリリースイベントを送信させます
|
||||||
case RGB_LYR: // これにより、アンダーグローをレイヤー表示として、あるいは通常通りに使うことができます。
|
case RGB_LYR: // これにより、アンダーグローをレイヤー表示として、あるいは通常通りに使うことができます。
|
||||||
@@ -511,7 +511,7 @@ void eeconfig_init_user(void) { // EEPROM がリセットされます!
|
|||||||
キーコードに基づいて `TAPPING_TERM` を変更するには、次のようなものを `keymap.c` ファイルに追加します:
|
キーコードに基づいて `TAPPING_TERM` を変更するには、次のようなものを `keymap.c` ファイルに追加します:
|
||||||
|
|
||||||
```c
|
```c
|
||||||
uint16_t get_tapping_term(uint16_t keycode) {
|
uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record) {
|
||||||
switch (keycode) {
|
switch (keycode) {
|
||||||
case SFT_T(KC_SPC):
|
case SFT_T(KC_SPC):
|
||||||
return TAPPING_TERM + 1250;
|
return TAPPING_TERM + 1250;
|
||||||
@@ -528,7 +528,7 @@ uint16_t get_tapping_term(uint16_t keycode) {
|
|||||||
キーコードに基づいて `IGNORE_MOD_TAP_INTERRUPT` の値を変更するには、次のようなものを `keymap.c` ファイルに追加します:
|
キーコードに基づいて `IGNORE_MOD_TAP_INTERRUPT` の値を変更するには、次のようなものを `keymap.c` ファイルに追加します:
|
||||||
|
|
||||||
```c
|
```c
|
||||||
bool get_ignore_mod_tap_interrupt(uint16_t keycode) {
|
bool get_ignore_mod_tap_interrupt(uint16_t keycode, keyrecord_t *record) {
|
||||||
switch (keycode) {
|
switch (keycode) {
|
||||||
case SFT_T(KC_SPC):
|
case SFT_T(KC_SPC):
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
@@ -1,11 +0,0 @@
|
|||||||
# よくある質問
|
|
||||||
|
|
||||||
<!---
|
|
||||||
original document: d598f01cb:docs/faq.md
|
|
||||||
git diff d598f01cb HEAD -- docs/faq.md | cat
|
|
||||||
-->
|
|
||||||
|
|
||||||
* [一般](ja/faq_general.md)
|
|
||||||
* [QMK のビルドあるいはコンパイル](ja/faq_build.md)
|
|
||||||
* [QMK のデバッグとトラブルシューティング](ja/faq_debug.md)
|
|
||||||
* [キーマップ](ja/faq_keymap.md)
|
|
||||||
@@ -152,10 +152,3 @@ https://geekhack.org/index.php?topic=14290.msg1884034#msg1884034
|
|||||||
|
|
||||||
https://github.com/tmk/tmk_keyboard/issues/266
|
https://github.com/tmk/tmk_keyboard/issues/266
|
||||||
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
|
https://geekhack.org/index.php?topic=41989.msg1967778#msg1967778
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## FLIP が動作しない
|
|
||||||
### `AtLibUsbDfu.dll` が見つかりません
|
|
||||||
デバイスマネージャから現在のドライバを削除し、FLIP が提供するものを再インストールします。
|
|
||||||
http://imgur.com/a/bnwzy
|
|
||||||
|
|||||||
@@ -1,14 +1,52 @@
|
|||||||
# よくある質問
|
# よくある質問
|
||||||
|
|
||||||
<!---
|
<!---
|
||||||
original document: d598f01cb:docs/faq_general.md
|
original document: 0.8.62:docs/faq_general.md
|
||||||
git diff d598f01cb HEAD -- docs/faq_general.md | cat
|
git diff 0.8.62 HEAD -- docs/faq_general.md | cat
|
||||||
-->
|
-->
|
||||||
|
|
||||||
## QMK とは何か?
|
## QMK とは何か?
|
||||||
|
|
||||||
Quantum Mechanical Keyboard の略である [QMK](https://github.com/qmk) は、カスタムキーボードのためのツールをビルドしている人々のグループです。[TMK](https://github.com/tmk/tmk_keyboard) の大幅に修正されたフォークである [QMK ファームウェア](https://github.com/qmk/qmk_firmware)から始まりました。
|
Quantum Mechanical Keyboard の略である [QMK](https://github.com/qmk) は、カスタムキーボードのためのツールをビルドしている人々のグループです。[TMK](https://github.com/tmk/tmk_keyboard) の大幅に修正されたフォークである [QMK ファームウェア](https://github.com/qmk/qmk_firmware)から始まりました。
|
||||||
|
|
||||||
|
## どこから始めればいいかわかりません!
|
||||||
|
|
||||||
|
この場合は、[初心者ガイド](ja/newbs.md) から始めるべきです。ここには多くの素晴らしい情報があり、それらはあなたが始めるのに必要な全てをカバーするはずです。
|
||||||
|
|
||||||
|
問題がある場合は、[QMK Configurator](https://config.qmk.fm)にアクセスしてください。あなたが必要なものの大部分が処理されます。
|
||||||
|
|
||||||
|
## ビルドしたファームウェアを書き込むにはどうすればいいですか?
|
||||||
|
|
||||||
|
まず、[コンパイル/書き込み FAQ ページ](ja/faq-build.md) に進みます。そこにはたくさんの情報があり、そこには一般的な問題に対する多くの解決策があります。
|
||||||
|
|
||||||
|
## ここで取り上げていない問題がある場合はどうしますか?
|
||||||
|
|
||||||
|
OK、問題ありません。[GitHub で issue を開く](https://github.com/qmk/qmk_firmware/issues) をチェックして、誰かが同じこと(似ているかだけでなく実際に同じであることを確認してください)を経験しているかどうかを確認してください。
|
||||||
|
|
||||||
|
もし何も見つからない場合は、[新しい issue](https://github.com/qmk/qmk_firmware/issues/new) を開いてください!
|
||||||
|
|
||||||
|
## バグを見つけたらどうしますか?
|
||||||
|
|
||||||
|
[issue](https://github.com/qmk/qmk_firmware/issues/new) を開いてください。そしてもし修正方法を知っている場合は、GitHub で修正のプルリクエストを開いてください。
|
||||||
|
|
||||||
|
## しかし、`git` と `GitHub` は怖いです!
|
||||||
|
|
||||||
|
心配しないでください。開発を容易にするために `git` と GitHub を使い始めるための、かなり良い [ガイドライン](ja/newbs_git_best_practices.md) があります。
|
||||||
|
|
||||||
|
さらに、追加の `git` と GitHub の関連リンクを [ここ](ja/newbs_learn_more_resources.md) に見つけることができます。
|
||||||
|
|
||||||
|
## サポートを追加したいキーボードがあります
|
||||||
|
|
||||||
|
素晴らしい!プルリクエストを開いてください。私たちはコードをレビューし、マージします!
|
||||||
|
|
||||||
|
### `QMK` でブランドしたい場合はどうればいいですか?
|
||||||
|
|
||||||
|
素晴らしい!私たちはあなたを支援したいと思います!
|
||||||
|
|
||||||
|
実際、私たちにはあなたのページとキーボードに QMK ブランドを追加するための [完全なページ](https://qmk.fm/powered/) があります。これは QMK を公式にサポートするために必要なほぼ全て(知識と画像)をカバーしています。
|
||||||
|
|
||||||
|
これについて質問がある場合は、issue を開くか、[Discord](https://discord.gg/Uq7gcHh) に進んでください。
|
||||||
|
|
||||||
## QMK と TMK の違いは何か?
|
## QMK と TMK の違いは何か?
|
||||||
|
|
||||||
TMK は [Jun Wako](https://github.com/tmk) によって設計され実装されました。QMK は [Jack Humbert](https://github.com/jackhumbert) の Planck 用 TMK のフォークとして始まりました。しばらくして、Jack のフォークは TMK からかなり分岐し、2015年に Jack はフォークを QMK に名前を変えることにしました。
|
TMK は [Jun Wako](https://github.com/tmk) によって設計され実装されました。QMK は [Jack Humbert](https://github.com/jackhumbert) の Planck 用 TMK のフォークとして始まりました。しばらくして、Jack のフォークは TMK からかなり分岐し、2015年に Jack はフォークを QMK に名前を変えることにしました。
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
# キーマップの FAQ
|
# キーマップの FAQ
|
||||||
|
|
||||||
<!---
|
<!---
|
||||||
original document: 376419a4f:docs/faq_keymap.md
|
original document: 0.8.62:docs/faq_keymap.md
|
||||||
git diff 376419a4f HEAD -- docs/faq_keymap.md | cat
|
git diff 0.8.62 HEAD -- docs/faq_keymap.md | cat
|
||||||
-->
|
-->
|
||||||
|
|
||||||
このページは人々がキーマップについてしばしば持つ疑問について説明します。まだ読んだことが無い場合には、[キーマップの概要](ja/keymap.md)を最初に読むべきです。
|
このページは人々がキーマップについてしばしば持つ疑問について説明します。まだ読んだことが無い場合には、[キーマップの概要](ja/keymap.md)を最初に読むべきです。
|
||||||
@@ -19,9 +19,20 @@
|
|||||||
<!-- Source for this image: http://www.keyboard-layout-editor.com/#/gists/bf431647d1001cff5eff20ae55621e9a -->
|
<!-- Source for this image: http://www.keyboard-layout-editor.com/#/gists/bf431647d1001cff5eff20ae55621e9a -->
|
||||||

|

|
||||||
|
|
||||||
|
## 複雑なキーコードのカスタム名を作成する方法はありますか?
|
||||||
|
|
||||||
|
時には、読みやすくするために、一部のキーコードにカスタム名を定義すると役に立ちます。人々は、しばしば `#define` を使ってカスタム名を定義します。例えば:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define FN_CAPS LT(_FL, KC_CAPSLOCK)
|
||||||
|
#define ALT_TAB LALT(KC_TAB)
|
||||||
|
```
|
||||||
|
|
||||||
|
これにより、キーマップで `FN_CAPS` と `ALT_TAB` を使えるようになり、読みやすくなります。
|
||||||
|
|
||||||
## 一部のキーが入れ替わっているか、または動作しない
|
## 一部のキーが入れ替わっているか、または動作しない
|
||||||
|
|
||||||
QMK には2つの機能、ブートマジックとコマンドがあり、これによりその場でキーボードの動作を変更することができます。これには Ctrl/Caps の交換、Gui の無効化、Alt/GUI の交換、Backspace/Backslash の交換、全てのキーの無効化およびその他の動作の変更が含まれますが、これらに限定されません。
|
QMK には2つの機能、ブートマジックとコマンドがあり、これによりその場でキーボードの動作を変更することができます。これには Ctrl/Caps の交換、Gui の無効化、Alt/Gui の交換、Backspace/Backslash の交換、全てのキーの無効化およびその他の動作の変更が含まれますが、これらに限定されません。
|
||||||
|
|
||||||
迅速な解決策として、キーボードを接続している時に `Space`+`Backspace` を押してみてください。これはキーボードに保存されている設定をリセットし、これらのキーを通常の操作に戻します。うまく行かない場合は、以下を見てください:
|
迅速な解決策として、キーボードを接続している時に `Space`+`Backspace` を押してみてください。これはキーボードに保存されている設定をリセットし、これらのキーを通常の操作に戻します。うまく行かない場合は、以下を見てください:
|
||||||
|
|
||||||
|
|||||||
85
docs/ja/feature_advanced_keycodes.md
Normal file
85
docs/ja/feature_advanced_keycodes.md
Normal file
@@ -0,0 +1,85 @@
|
|||||||
|
# レイヤーの切り替えとトグル :id=switching-and-toggling-layers
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 5d5ff80:docs/feature_advanced_keycodes.md
|
||||||
|
git diff 5d5ff80 HEAD -- docs/feature_advanced_keycodes.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
これらの機能により、様々な方法でレイヤーをアクティブ化することができます。レイヤーは一般的に独立したレイアウトでは無いことに注意してください -- 複数のレイヤーを一度にアクティブ化することができ、レイヤーが `KC_TRNS` を使ってキーの押下を下のレイヤーに渡すことが一般的です。レイヤーの詳細については、[キーマップの概要](ja/keymap.md#keymap-and-layers)を見てください。MO()、LM()、TT() あるいは LT() を使って一時的なレイヤーの切り替えを使う場合、上のレイヤーのキーを透過にするようにしてください。さもないと意図したように動作しないかもしれません。
|
||||||
|
|
||||||
|
* `DF(layer)` - デフォルトレイヤーを切り替えます。デフォルトレイヤーは、他のレイヤーがその上に積み重なっている、常にアクティブな基本レイヤーです。デフォルトレイヤーの詳細については以下を見てください。これは QWERTY から Dvorak レイアウトに切り替えるために使うことができます。(これは一時的な切り替えであり、キーボードの電源が切れるまでしか持続しないことに注意してください。デフォルトレイヤーを永続的に変更するには、[process_record_user](ja/custom_quantum_functions.md#programming-the-behavior-of-any-keycode) 内で `set_single_persistent_default_layer` 関数を呼び出すなど、より深いカスタマイズが必要です。)
|
||||||
|
* `MO(layer)` - 一時的に*レイヤー*をアクティブにします。キーを放すとすぐに、レイヤーは非アクティブになります。
|
||||||
|
* `LM(layer, mod)` - (`MO` のように)一時的に*レイヤー*をアクティブにしますが、モディファイア *mod* がアクティブな状態です。layer 0-15 と、左モディファイアのみをサポートします: `MOD_LCTL`、`MOD_LSFT`、`MOD_LALT`、`MOD_LGUI` (`KC_` の代わりに `MOD_` 定数を使うことに注意してください)。これらのモディファイアは、例えば `LM(_RAISE, MOD_LCTL | MOD_LALT)` のように、ビット単位の OR を使って組み合わせることができます。
|
||||||
|
* `LT(layer, kc)` - ホールドされた時に*レイヤー*を一時的にアクティブにし、タップされた時に *kc* を送信します。layer 0-15 のみをサポートします。
|
||||||
|
* `OSL(layer)` - 次のキーが押されるまで、一時的に*レイヤー*をアクティブにします。詳細と追加機能については、[ワンショットキー](ja/one_shot_keys.md)を見てください。
|
||||||
|
* `TG(layer)` - *レイヤー*を切り替えます。非アクティブな場合はアクティブにし、逆も同様です。
|
||||||
|
* `TO(layer)` - *レイヤー*をアクティブにし、他の全てのレイヤー(デフォルトレイヤーを除く)を非アクティブにします。この関数は特別です。1つのレイヤーをアクティブなレイヤースタックに追加/削除する代わりに、現在のアクティブなレイヤーを完全に置き換え、唯一上位のレイヤーを下位のレイヤーで置き換えることができるからです。これはキーダウンで(キーが押されるとすぐに)アクティブになります。
|
||||||
|
* `TT(layer)` - レイヤーのタップ切り替え。キーを押したままにすると*レイヤー*がアクティブにされ、放すと非アクティブになります (`MO` 風)。繰り返しタップすると、レイヤーはオンあるいはオフを切り替えます (`TG` 風)。デフォルトでは5回のタップが必要ですが、`TAPPING_TOGGLE` を定義することで変更することができます -- 例えば、2回のタップだけで切り替えるには、`#define TAPPING_TOGGLE 2` を定義します。
|
||||||
|
|
||||||
|
## 注意事項
|
||||||
|
|
||||||
|
現在のところ、`LT()` と `MT()` は[基本的なキーコードセット](ja/keycodes_basic.md)に制限されています。つまり、`LCTL()`、`KC_TILD` あるいは `0xFF` より大きなキーコードを使うことができません。レイヤータップあるいはモッドタップのキーコードの一部として指定されたモディファイアは無視されます。タップしたキーコードにモディファイアを適用する必要がある場合は、[タップダンス](ja/feature_tap_dance.md#example-5-using-tap-dance-for-advanced-mod-tap-and-layer-tap-keys)を使うことができます。
|
||||||
|
|
||||||
|
さらに、モッドタップあるいはレイヤータップで少なくとも1つの右手用のモディファイアが指定された場合、指定された全てのモディファイアが右手用になるため、2つをうまく組み合わせて一致させることはできません。
|
||||||
|
|
||||||
|
# レイヤーの使用
|
||||||
|
|
||||||
|
レイヤーを切り替える時は注意してください。(キーボードを取り外さずに)そのレイヤーを非アクティブにすることができずレイヤーから移動できなくなる可能性があります。最も一般的な問題を避けるためのガイドラインを作成しました。
|
||||||
|
|
||||||
|
## 初心者
|
||||||
|
|
||||||
|
QMK を使い始めたばかりの場合は、全てを単純にしたいでしょう。レイヤーをセットアップする時は、これらのガイドラインに従ってください:
|
||||||
|
|
||||||
|
* デフォルトの "base" レイヤーとして、layer 0 をセットアップします。これは通常の入力レイヤーであり、任意のレイアウト (qwerty、dvorak、colemak など)にすることができます。通常はキーボードのキーのほとんどまたは全てが定義されているため、これを最下位のレイヤーとして設定することが重要です。そうすることで、もしそれが他のレイヤーの上 (つまりレイヤー番号が大きい)にある場合の影響を防ぎます。
|
||||||
|
* layer 0 をルートとして、レイヤーを "ツリー" レイアウトに配置します。他の複数のレイヤーから同じレイヤーに行こうとしないでください。
|
||||||
|
* 各レイヤーのキーマップでは、より高い番号のレイヤーのみを参照します。レイヤーは最大の番号(最上位)のアクティブレイヤーから処理されるため、下位レイヤーの状態を変更するのは難しくエラーが発生しやすくなります。
|
||||||
|
|
||||||
|
## 中級ユーザ
|
||||||
|
|
||||||
|
複数の基本レイヤーが必要な場合があります。例えば、QWERTY と Dvorak を切り替える場合、国ごとに異なるレイアウトを切り替える場合、あるいは異なるビデオゲームごとにレイアウトを切り替える場合などです。基本レイヤーは常に最小の番号のレイヤーである必要があります。複数の基本レイヤーがある場合、常にそれらを相互排他的に扱う必要があります。1つの基本レイヤーがオンの場合、他をオフにします。
|
||||||
|
|
||||||
|
## 上級ユーザ
|
||||||
|
|
||||||
|
レイヤーがどのように動作し、何ができるかを理解したら、より創造的になります。初心者のセクションで列挙されている規則は、幾つかの巧妙な詳細を回避するのに役立ちますが、特に超コンパクトなキーボードのユーザにとって制約になる場合があります。レイヤーの仕組みを理解することで、レイヤーをより高度な方法で使うことができます。
|
||||||
|
|
||||||
|
レイヤーは番号順に上に積み重なっています。キーの押下の動作を決定する時に、QMK は上から順にレイヤーを走査し、`KC_TRNS` に設定されていない最初のアクティブなレイヤーに到達すると停止します。結果として、現在のレイヤーよりも数値的に低いレイヤーをアクティブにし、現在のレイヤー(あるいはアクティブでターゲットレイヤーよりも高い別のレイヤー)に `KC_TRNS` 以外のものがある場合、それが送信されるキーであり、アクティブ化したばかりのレイヤー上のキーではありません。これが、ほとんどの人の "なぜレイヤーが切り替わらないのか" 問題の原因です。
|
||||||
|
|
||||||
|
場合によっては、マクロ内あるいはタップダンスルーチンの一部としてレイヤーを切り替えほうが良いかもしれません。`layer_on` はレイヤーをアクティブにし、`layer_off` はそれを非アクティブにします。もっと多くのレイヤーに関する関数は、[action_layer.h](https://github.com/qmk/qmk_firmware/blob/master/tmk_core/common/action_layer.h) で見つけることができます。
|
||||||
|
|
||||||
|
# 修飾キー :id=modifier-keys
|
||||||
|
|
||||||
|
以下のようにキーコードとモディファイアを組み合わせることができます。押すと、モディファイアのキーダウンイベントが送信され、次に `kc` のキーダウンイベントが送信されます。放すと、`kc` のキーアップイベントが送信され、次にモディファイアのキーアップイベントが送信されます。
|
||||||
|
|
||||||
|
| キー | エイリアス | 説明 |
|
||||||
|
|----------|-------------------------------|----------------------------------------------------|
|
||||||
|
| `LCTL(kc)` | `C(kc)` | 左 Control を押しながら `kc` を押します。 |
|
||||||
|
| `LSFT(kc)` | `S(kc)` | 左 Shift を押しながら `kc` を押します。 |
|
||||||
|
| `LALT(kc)` | `A(kc)`, `LOPT(kc)` | 左 Alt を押しながら `kc`を押します。 |
|
||||||
|
| `LGUI(kc)` | `G(kc)`, `LCMD(kc)`, `LWIN(kc)` | 左 GUI を押しながら `kc` を押します。 |
|
||||||
|
| `RCTL(kc)` | | 右 Control を押しながら `kc` を押します。 |
|
||||||
|
| `RSFT(kc)` | | 右 Shift を押しながら `kc` を押します。 |
|
||||||
|
| `RALT(kc)` | `ROPT(kc)`, `ALGR(kc)` | 右 Alt を押しながら `kc` を押します。 |
|
||||||
|
| `RGUI(kc)` | `RCMD(kc)`, `LWIN(kc)` | 右 GUI を押しながら `kc` を押します。 |
|
||||||
|
| `SGUI(kc)` | `SCMD(kc)`, `SWIN(kc)` | 左 Shift と左 GUI を押しながら `kc` を押します。 |
|
||||||
|
| `LCA(kc)` | | 左 Control と左 Alt を押しながら `kc` を押します。 |
|
||||||
|
| `LCAG(kc)` | | 左 Control、左 Alt、左 GUI を押しながら `kc` を押します。 |
|
||||||
|
| `MEH(kc)` | | 左 Control、左 Shift、左 Alt を押しながら `kc` を押します。 |
|
||||||
|
| `HYPR(kc)` | | 左 Control、左 Shift、左 Alt、左 GUI を押しながら `kc` を押します。 |
|
||||||
|
|
||||||
|
また、それらを繋げることができます。例えば、`LCTL(LALT(KC_DEL))` は1回のキー押下で Control+Alt+Delete を送信するキーを作成します。
|
||||||
|
|
||||||
|
# 過去の内容
|
||||||
|
|
||||||
|
このページには多くの機能が含まれていました。このページを構成していた多くのセクションをそれぞれのページに移動しました。これより下は全て単なるリダイレクトであるため、web上で古いリンクをたどっている人は探しているものを見つけることができます。
|
||||||
|
|
||||||
|
## モッドタップ :id=mod-tap
|
||||||
|
|
||||||
|
* [モッドタップ](ja/mod_tap.md)
|
||||||
|
|
||||||
|
## ワンショットキー :id=one-shot-keys
|
||||||
|
|
||||||
|
* [ワンショットキー](ja/one_shot_keys.md)
|
||||||
|
|
||||||
|
## タップホールド設定オプション :id=tap-hold-configuration-options
|
||||||
|
|
||||||
|
* [タップホールド設定オプション](ja/tap_hold.md)
|
||||||
328
docs/ja/feature_audio.md
Normal file
328
docs/ja/feature_audio.md
Normal file
@@ -0,0 +1,328 @@
|
|||||||
|
# オーディオ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 5d5ff80:docs/feature_audio.md
|
||||||
|
git diff 5d5ff80 HEAD -- docs/feature_audio.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
キーボードは音を出すことができます!Planck、Preonic あるいは特定の PWM 対応ピンにアクセスできる AVR キーボードがある場合は、単純なスピーカーを接続してビープ音を鳴らすことができます。これらのビープ音を使ってレイヤーの変化、モディファイア、特殊キーを示したり、あるいは単にイカした8ビットの曲を鳴らすことができます。
|
||||||
|
|
||||||
|
最大2つの同時オーディオ音声がサポートされ、1つはタイマー1によってもう一つはタイマー3によって駆動されます。以下のピンは config.h の中でオーディオ出力として定義することができます:
|
||||||
|
|
||||||
|
Timer 1:
|
||||||
|
`#define B5_AUDIO`
|
||||||
|
`#define B6_AUDIO`
|
||||||
|
`#define B7_AUDIO`
|
||||||
|
|
||||||
|
Timer 3:
|
||||||
|
`#define C4_AUDIO`
|
||||||
|
`#define C5_AUDIO`
|
||||||
|
`#define C6_AUDIO`
|
||||||
|
|
||||||
|
`rules.mk` に `AUDIO_ENABLE = yes` を追加すると、他の設定無しで自動的に有効になる幾つかの異なるサウンドがあります:
|
||||||
|
|
||||||
|
```
|
||||||
|
STARTUP_SONG // キーボードの起動時に再生 (audio.c)
|
||||||
|
GOODBYE_SONG // RESET キーを押すと再生 (quantum.c)
|
||||||
|
AG_NORM_SONG // AG_NORM キーを押すと再生 (quantum.c)
|
||||||
|
AG_SWAP_SONG // AG_SWAP キーを押すと再生 (quantum.c)
|
||||||
|
CG_NORM_SONG // CG_NORM キーを押すと再生 (quantum.c)
|
||||||
|
CG_SWAP_SONG // CG_SWAP キーを押すと再生 (quantum.c)
|
||||||
|
MUSIC_ON_SONG // 音楽モードがアクティブになると再生 (process_music.c)
|
||||||
|
MUSIC_OFF_SONG // 音楽モードが非アクティブになると再生 (process_music.c)
|
||||||
|
CHROMATIC_SONG // 半音階音楽モードが選択された時に再生 (process_music.c)
|
||||||
|
GUITAR_SONG // ギター音楽モードが選択された時に再生 (process_music.c)
|
||||||
|
VIOLIN_SONG // バイオリン音楽モードが選択された時に再生 (process_music.c)
|
||||||
|
MAJOR_SONG // メジャー音楽モードが選択された時に再生 (process_music.c)
|
||||||
|
```
|
||||||
|
|
||||||
|
`config.h` の中で以下のような操作を行うことで、デフォルトの曲を上書きすることができます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
#define STARTUP_SONG SONG(STARTUP_SOUND)
|
||||||
|
#endif
|
||||||
|
```
|
||||||
|
|
||||||
|
サウンドの完全なリストは、[quantum/audio/song_list.h](https://github.com/qmk/qmk_firmware/blob/master/quantum/audio/song_list.h) で見つかります - このリストに自由に追加してください!利用可能な音は [quantum/audio/musical_notes.h](https://github.com/qmk/qmk_firmware/blob/master/quantum/audio/musical_notes.h) で見つかります。
|
||||||
|
|
||||||
|
特定の時にカスタムサウンドを再生するために、以下のように曲を定義することができます(ファイルの上部付近に):
|
||||||
|
|
||||||
|
```c
|
||||||
|
float my_song[][2] = SONG(QWERTY_SOUND);
|
||||||
|
```
|
||||||
|
|
||||||
|
以下のように曲を再生します:
|
||||||
|
|
||||||
|
```c
|
||||||
|
PLAY_SONG(my_song);
|
||||||
|
```
|
||||||
|
|
||||||
|
または、以下のようにループで再生することができます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
PLAY_LOOP(my_song);
|
||||||
|
```
|
||||||
|
|
||||||
|
オーディオがキーボードに組み込まれていない時に問題が起きる事を避けるために、`#ifdef AUDIO_ENABLE` / `#endif` で全てのオーディオ機能をくるむことをお勧めします。
|
||||||
|
|
||||||
|
オーディオで利用可能なキーコードは以下の通りです:
|
||||||
|
|
||||||
|
* `AU_ON` - オーディオ機能をオン
|
||||||
|
* `AU_OFF` - オーディオ機能をオフ
|
||||||
|
* `AU_TOG` - オーディオ機能を切り替え
|
||||||
|
|
||||||
|
!> これらのキーコードは全てのオーディオ機能をオンおよびオフにします。オフにするとオーディオフィードバック、オーディオクリック、音楽モードなどが完全に無効になります。
|
||||||
|
|
||||||
|
## ARM オーディオボリューム
|
||||||
|
|
||||||
|
ARM デバイスの場合、DAC サンプル値を調整できます。キーボードがあなたやあなたの同僚にとって騒々しい場合、`config.h` 内の `DAC_SAMPLE_MAX` を使って最大量を設定することができます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define DAC_SAMPLE_MAX 65535U
|
||||||
|
```
|
||||||
|
|
||||||
|
## 音楽モード
|
||||||
|
|
||||||
|
音楽モードは列を半音階に、行をオクターブにマップします。これは格子配列キーボードで最適に動作しますが、他のものでも動作させることができます。`0xFF` 未満の全てのキーコードはブロックされるため、音の演奏中は入力できません - 特別なキー/mod があればそれらは引き続き動作します。これを回避するには、音楽モードを有効にする前(あるいは後)で、KC_NO を使って別のレイヤーにジャンプします。
|
||||||
|
|
||||||
|
メモリの問題により、録音は実験的です - 奇妙な動作が発生した場合は、キーボードの取り外しと再接続で問題が解決するでしょう。
|
||||||
|
|
||||||
|
利用可能なキーコード:
|
||||||
|
|
||||||
|
* `MU_ON` - 音楽モードをオン
|
||||||
|
* `MU_OFF` - 音楽モードをオフ
|
||||||
|
* `MU_TOG` - 音楽モードの切り替え
|
||||||
|
* `MU_MOD` - 音楽モードの循環
|
||||||
|
* `CHROMATIC_MODE` - 半音階。行はオクターブを変更します
|
||||||
|
* `GUITAR_MODE` - 半音階、ただし行は弦を変更します (+5 階)
|
||||||
|
* `VIOLIN_MODE` - 半音階。ただし行は弦を変換します (+7 階)
|
||||||
|
* `MAJOR_MODE` - メージャースケール
|
||||||
|
|
||||||
|
音楽モードでは、以下のキーコードは動作が異なり、通過しません:
|
||||||
|
|
||||||
|
* `LCTL` - 録音を開始
|
||||||
|
* `LALT` - 録音を停止/演奏を停止
|
||||||
|
* `LGUI` - 録音を再生
|
||||||
|
* `KC_UP` - 再生をスピードアップ
|
||||||
|
* `KC_DOWN` - 再生をスローダウン
|
||||||
|
|
||||||
|
ピッチ標準 (`PITCH_STANDARD_A`) はデフォルトで 440.0f です - これを変更するには、`config.h` に以下のようなものを追加します:
|
||||||
|
|
||||||
|
#define PITCH_STANDARD_A 432.0f
|
||||||
|
|
||||||
|
音楽モードも完全に無効にすることができます。コントローラの容量が足りなくて困っている場合に役に立ちます。無効にするには、これを `config.h` に追加します:
|
||||||
|
|
||||||
|
#define NO_MUSIC_MODE
|
||||||
|
|
||||||
|
### 音楽マスク
|
||||||
|
|
||||||
|
デフォルトで、`MUSIC_MASK` は `keycode < 0xFF` に設定されます。これは、`0xFF` 未満のキーコードが音に変換され、何も出力しないことを意味します。`config.h` の中で以下のものを定義することで、これを変更することができます:
|
||||||
|
|
||||||
|
#define MUSIC_MASK keycode != KC_NO
|
||||||
|
|
||||||
|
これは全てのキーコードを捕捉します - これは、キーボードを再起動するまで、音楽モードで動けなくなることに注意してください!
|
||||||
|
|
||||||
|
どのキーコードを引き続き処理するかを制御する、より高度な方法については、`<keyboard>.c` の中の `music_mask_kb(keycode)` および `keymap.c` の中の `music_mask_user(keycode)` を使うことができます:
|
||||||
|
|
||||||
|
bool music_mask_user(uint16_t keycode) {
|
||||||
|
switch (keycode) {
|
||||||
|
case RAISE:
|
||||||
|
case LOWER:
|
||||||
|
return false;
|
||||||
|
default:
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
false を返すものはマスクの一部では無く、常に処理されます。
|
||||||
|
|
||||||
|
### 音楽マップ
|
||||||
|
|
||||||
|
デフォルトでは、音楽モードはキーのスケールを決定するために列と行を使います。キーボードレイアウトに一致する長方形のマトリックスを使うキーボードの場合、これで十分です。しかし、(Planck Rev6 あるいは多くの分割キーボードなどのように)より複雑なマトリックスを使うキーボードの場合、非常に歪んだ感じを受けることになります。
|
||||||
|
|
||||||
|
しかしながら、音楽マップオプションにより、音楽モードのためにスケーリングを再マップすることができるため、レイアウトに一致し、より自然になります。
|
||||||
|
|
||||||
|
この機能を使うには、`#define MUSIC_MAP` を `config.h` ファイルに追加します。そして、`キーボードの名前.c` または `keymap.c` に `uint8_t music_map` を追加します。
|
||||||
|
|
||||||
|
```c
|
||||||
|
const uint8_t music_map[MATRIX_ROWS][MATRIX_COLS] = LAYOUT_ortho_4x12(
|
||||||
|
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
|
||||||
|
24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
|
||||||
|
12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
|
||||||
|
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11
|
||||||
|
);
|
||||||
|
```
|
||||||
|
|
||||||
|
キーボードが使用する `LAYOUT` マクロも使用したいでしょう。これは正しいキーの位置にマップします。キーボードレイアウトの左下から開始し、右に移動してさらに上に移動します。完全なマトリックスができるまで、全てのエントリを入力します。
|
||||||
|
|
||||||
|
これを実装する方法の例として、[Planck Keyboard](https://github.com/qmk/qmk_firmware/blob/e9ace1487887c1f8b4a7e8e6d87c322988bec9ce/keyboards/planck/planck.c#L24-L29) を見ることができます。
|
||||||
|
|
||||||
|
## オーディオクリック
|
||||||
|
|
||||||
|
これは、ボタンを押すたびにクリック音を追加し、キーボードからのクリック音をシミュレートします。キーを押すたびにわずかに音が異なるため、すばやく入力しても長い単一の音のようには聞こえません。
|
||||||
|
|
||||||
|
* `CK_TOGG` - ステータスを切り替えます (有効にされた場合、音を再生します)
|
||||||
|
* `CK_ON` - オーディオクリックをオンにします (音を再生します)
|
||||||
|
* `CK_OFF` - オーディオクリックをオフにします (音を再生しません)
|
||||||
|
* `CK_RST` - 周波数をデフォルトの状態に再設定します (デフォルトの周波数で音を再生します)
|
||||||
|
* `CK_UP` - クリック音の周波数を増やします (新しい周波数で音を再生します)
|
||||||
|
* `CK_DOWN` - クリック音の周波数を減らします (新しい周波数で音を再生します)
|
||||||
|
|
||||||
|
|
||||||
|
容量を節約するためにデフォルトではこの機能は無効です。有効にするには、`config.h` に以下を追加します:
|
||||||
|
|
||||||
|
#define AUDIO_CLICKY
|
||||||
|
|
||||||
|
|
||||||
|
これらの値を定義することで、デフォルト、最小および最大周波数、ステッピングおよび組み込みのランダム性を設定することができます:
|
||||||
|
|
||||||
|
| オプション | デフォルト値 | 説明 |
|
||||||
|
|--------|---------------|-------------|
|
||||||
|
| `AUDIO_CLICKY_FREQ_DEFAULT` | 440.0f | クリック音のデフォルト/開始音の周波数を設定します。 |
|
||||||
|
| `AUDIO_CLICKY_FREQ_MIN` | 65.0f | 最小周波数を設定します (60f 未満は少しバグがあります)。 |
|
||||||
|
| `AUDIO_CLICKY_FREQ_MAX` | 1500.0f | 最大周波数を設定します。高すぎると同僚があなたを攻撃する可能性があります。 |
|
||||||
|
| `AUDIO_CLICKY_FREQ_FACTOR` | 1.18921f | UP/DOWN キーコードのステップを設定します。これは掛け算の係数です。デフォルトでは、音楽のマイナーの1/3ずつ、周波数を上げ/下げします。 |
|
||||||
|
| `AUDIO_CLICKY_FREQ_RANDOMNESS` | 0.05f | クリックのランダム性の係数を設定します。これを `0f` に設定すると各クリックが同一になり、`1.0f` に設定するとこの音は90年代のコンピュータ画面のスクロール/タイピングの効果があります。 |
|
||||||
|
| `AUDIO_CLICKY_DELAY_DURATION` | 1 | 1がテンポの 1/16、または64分音符である整数音符の長さ (実装の詳細については、`quantum/audio/musical_notes.h` を見てください)。メインのクリック効果は、この時間だけ遅れます。これらを6-12前後の値に調整すると、うるさいスイッチの補正に役立ちます。 |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## MIDI 機能
|
||||||
|
|
||||||
|
これはまだ WIP ですが、何が起きているかを見るために、`quantum/process_keycode/process_midi.c` を調べてください。Makefile から有効にします。
|
||||||
|
|
||||||
|
|
||||||
|
## オーディオキーコード
|
||||||
|
|
||||||
|
| キー | エイリアス | 説明 |
|
||||||
|
|----------------|---------|----------------------------------|
|
||||||
|
| `AU_ON` | | オーディオモードオン |
|
||||||
|
| `AU_OFF` | | オーディオモードオフ |
|
||||||
|
| `AU_TOG` | | オーディオモードを切り替えます |
|
||||||
|
| `CLICKY_TOGGLE` | `CK_TOGG` | オーディオクリックモードを切り替えます |
|
||||||
|
| `CLICKY_UP` | `CK_UP` | クリック音の周波数を増やします |
|
||||||
|
| `CLICKY_DOWN` | `CK_DOWN` | クリック音の周波数を減らします |
|
||||||
|
| `CLICKY_RESET` | `CK_RST` | 周波数をデフォルトに再設定します |
|
||||||
|
| `MU_ON` | | 音楽モードをオンにします |
|
||||||
|
| `MU_OFF` | | 音楽モードをオフにします |
|
||||||
|
| `MU_TOG` | | 音楽モードを切り替えます |
|
||||||
|
| `MU_MOD` | | 音楽モードを循環します |
|
||||||
|
|
||||||
|
<!-- FIXME: this formatting needs work
|
||||||
|
|
||||||
|
## Audio
|
||||||
|
|
||||||
|
```c
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
AU_ON,
|
||||||
|
AU_OFF,
|
||||||
|
AU_TOG,
|
||||||
|
|
||||||
|
#ifdef FAUXCLICKY_ENABLE
|
||||||
|
FC_ON,
|
||||||
|
FC_OFF,
|
||||||
|
FC_TOG,
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// Music mode on/off/toggle
|
||||||
|
MU_ON,
|
||||||
|
MU_OFF,
|
||||||
|
MU_TOG,
|
||||||
|
|
||||||
|
// Music voice iterate
|
||||||
|
MUV_IN,
|
||||||
|
MUV_DE,
|
||||||
|
#endif
|
||||||
|
```
|
||||||
|
|
||||||
|
### Midi
|
||||||
|
|
||||||
|
#if !MIDI_ENABLE_STRICT || (defined(MIDI_ENABLE) && defined(MIDI_BASIC))
|
||||||
|
MI_ON, // send midi notes when music mode is enabled
|
||||||
|
MI_OFF, // don't send midi notes when music mode is enabled
|
||||||
|
#endif
|
||||||
|
|
||||||
|
MIDI_TONE_MIN,
|
||||||
|
MIDI_TONE_MAX
|
||||||
|
|
||||||
|
MI_C = MIDI_TONE_MIN,
|
||||||
|
MI_Cs,
|
||||||
|
MI_Db = MI_Cs,
|
||||||
|
MI_D,
|
||||||
|
MI_Ds,
|
||||||
|
MI_Eb = MI_Ds,
|
||||||
|
MI_E,
|
||||||
|
MI_F,
|
||||||
|
MI_Fs,
|
||||||
|
MI_Gb = MI_Fs,
|
||||||
|
MI_G,
|
||||||
|
MI_Gs,
|
||||||
|
MI_Ab = MI_Gs,
|
||||||
|
MI_A,
|
||||||
|
MI_As,
|
||||||
|
MI_Bb = MI_As,
|
||||||
|
MI_B,
|
||||||
|
|
||||||
|
MIDI_TONE_KEYCODE_OCTAVES > 1
|
||||||
|
|
||||||
|
where x = 1-5:
|
||||||
|
MI_C_x,
|
||||||
|
MI_Cs_x,
|
||||||
|
MI_Db_x = MI_Cs_x,
|
||||||
|
MI_D_x,
|
||||||
|
MI_Ds_x,
|
||||||
|
MI_Eb_x = MI_Ds_x,
|
||||||
|
MI_E_x,
|
||||||
|
MI_F_x,
|
||||||
|
MI_Fs_x,
|
||||||
|
MI_Gb_x = MI_Fs_x,
|
||||||
|
MI_G_x,
|
||||||
|
MI_Gs_x,
|
||||||
|
MI_Ab_x = MI_Gs_x,
|
||||||
|
MI_A_x,
|
||||||
|
MI_As_x,
|
||||||
|
MI_Bb_x = MI_As_x,
|
||||||
|
MI_B_x,
|
||||||
|
|
||||||
|
MI_OCT_Nx 1-2
|
||||||
|
MI_OCT_x 0-7
|
||||||
|
MIDI_OCTAVE_MIN = MI_OCT_N2,
|
||||||
|
MIDI_OCTAVE_MAX = MI_OCT_7,
|
||||||
|
MI_OCTD, // octave down
|
||||||
|
MI_OCTU, // octave up
|
||||||
|
|
||||||
|
MI_TRNS_Nx 1-6
|
||||||
|
MI_TRNS_x 0-6
|
||||||
|
MIDI_TRANSPOSE_MIN = MI_TRNS_N6,
|
||||||
|
MIDI_TRANSPOSE_MAX = MI_TRNS_6,
|
||||||
|
MI_TRNSD, // transpose down
|
||||||
|
MI_TRNSU, // transpose up
|
||||||
|
|
||||||
|
MI_VEL_x 1-10
|
||||||
|
MIDI_VELOCITY_MIN = MI_VEL_1,
|
||||||
|
MIDI_VELOCITY_MAX = MI_VEL_9,
|
||||||
|
MI_VELD, // velocity down
|
||||||
|
MI_VELU, // velocity up
|
||||||
|
|
||||||
|
MI_CHx 1-16
|
||||||
|
MIDI_CHANNEL_MIN = MI_CH1
|
||||||
|
MIDI_CHANNEL_MAX = MI_CH16,
|
||||||
|
MI_CHD, // previous channel
|
||||||
|
MI_CHU, // next channel
|
||||||
|
|
||||||
|
MI_ALLOFF, // all notes off
|
||||||
|
|
||||||
|
MI_SUS, // sustain
|
||||||
|
MI_PORT, // portamento
|
||||||
|
MI_SOST, // sostenuto
|
||||||
|
MI_SOFT, // soft pedal
|
||||||
|
MI_LEG, // legato
|
||||||
|
|
||||||
|
MI_MOD, // modulation
|
||||||
|
MI_MODSD, // decrease modulation speed
|
||||||
|
MI_MODSU, // increase modulation speed
|
||||||
|
#endif // MIDI_ADVANCED
|
||||||
|
|
||||||
|
-->
|
||||||
135
docs/ja/feature_auto_shift.md
Normal file
135
docs/ja/feature_auto_shift.md
Normal file
@@ -0,0 +1,135 @@
|
|||||||
|
# 自動シフト: なぜシフトキーが必要ですか?
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 5d5ff80:docs/feature_auto_shift.md
|
||||||
|
git diff 5d5ff80 HEAD -- docs/feature_auto_shift.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
キーをタップすると、その文字を取得します。キーをタップするが、*わずかに*長く押し続けると、シフト状態になります。ほら!シフトキーは必要ありません!
|
||||||
|
|
||||||
|
## なぜ自動シフトなのですか?
|
||||||
|
|
||||||
|
多くの人が腱鞘炎などの症状に苦しんでいます。一般的な原因は、指を繰り返し長い距離を伸ばすことです。私たちはキーボード上でシフトキーに手を伸ばすためにあまりにも頻繁に小指を伸ばします。自動シフトキーはそれを軽減しようとしています。
|
||||||
|
|
||||||
|
## どのように動作しますか?
|
||||||
|
|
||||||
|
キーをタップする時に、キーを放す前にほんの短い間押したままにします。この押したままにする時間は全ての人にとって異なる長さです。自動シフトは、定数 `AUTO_SHIFT_TIMEOUT` を定義し、これは普段の押された状態の時間の2倍に通常は設定されます。タイマーは、キーを押す時に開始され、キーを放す時に止まります。押された時間が `AUTO_SHIFT_TIMEOUT` 以上の場合に、キーのシフトバージョンが発行されます。時間が `AUTO_SHIFT_TIMEOUT` 時間よりも短い場合は、通常の状態が発行されます。
|
||||||
|
|
||||||
|
## 自動シフトには制限がありますか?
|
||||||
|
|
||||||
|
残念ながらあります。
|
||||||
|
|
||||||
|
1. キーリピートが動作しなくなります。例えば、20個の 'a' 文字が必要な場合、'a' キーを1、2秒押し続けるかもしれません。オペレーティングシステムに押されたキーの状態を発行する代わりに押された時間を計るので、自動シフトでは動作しません。
|
||||||
|
2. シフトをするつもりがない時にシフトされた文字を取得し、シフトしたい時にそうではない他の文字を取得するでしょう。これは結局は練習になります。急いでいる時は、シフトされたバージョンのために十分長くキーを押したと思うかもしれませんが、そうではありませんでした。一方、キーをタップしていると思うかもしれませんが、実際には予想よりも少し長い間押していました。
|
||||||
|
|
||||||
|
## どうやって自動シフトを有効にしますか?
|
||||||
|
|
||||||
|
キーマップフォルダの `rules.mk` に追加します:
|
||||||
|
|
||||||
|
AUTO_SHIFT_ENABLE = yes
|
||||||
|
|
||||||
|
`rules.mk` が存在しない場合、それを作成することができます。
|
||||||
|
|
||||||
|
そして自動シフトキーを有効にした新しいファームウェアをコンパイルしてインストールします!以上です!
|
||||||
|
|
||||||
|
## モディファイア
|
||||||
|
|
||||||
|
デフォルトで、1つ以上のモディファイアと一緒にキーが押されると自動シフトは無効になります。従って、本当に長い間 Ctrl+A を保持しても、Ctrl+Shift+A と同じではありません。
|
||||||
|
|
||||||
|
`config.h` に定義を追加することで、モディファイアの自動シフトを再度有効にすることができます
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define AUTO_SHIFT_MODIFIERS
|
||||||
|
```
|
||||||
|
|
||||||
|
この場合、`AUTO_SHIFT_TIMEOUT` を超えて押された Ctrl+A は Ctrl+Shift+A として送信されます
|
||||||
|
|
||||||
|
|
||||||
|
## 自動シフトの設定
|
||||||
|
|
||||||
|
必要に応じて、自動シフトの挙動を変更することができる幾つかの設定があります。キーマップフォルダにある `config.h` に様々な変数を設定することで行われます。`config.h` ファイルが存在しない場合、それを作成することができます。
|
||||||
|
|
||||||
|
例
|
||||||
|
|
||||||
|
```c
|
||||||
|
#pragma once
|
||||||
|
|
||||||
|
#define AUTO_SHIFT_TIMEOUT 150
|
||||||
|
#define NO_AUTO_SHIFT_SPECIAL
|
||||||
|
```
|
||||||
|
|
||||||
|
### AUTO_SHIFT_TIMEOUT (単位: ミリ秒)
|
||||||
|
|
||||||
|
これは、シフトされた状態を取得するためにどれだけ長くキーを押し続けなければならないかを制御します。
|
||||||
|
明らかにこれは人によって異なります。一般的な人にとって、135 から 150 の設定がうまく機能します。ただし、少なくとも 175 の値から開始する必要があります。これはデフォルト値です。その後、ここから下げていきます。間違って検出することなくシフトされた状態を取得するのに必要な、最も短い時間を得るという考え方です。
|
||||||
|
|
||||||
|
完璧に動作するまで、いろいろな値を試してみます。多くの人は、全てが所定の値で適切に動作するものの、時々、1つあるいは2つのキーがシフト状態を発行することが分かるでしょう。これは単に習慣と、幾つかのキーを他のキーよりも少し長く押し続けることによるものです。この値を見つけたら、問題のキーを通常よりも少し早くタップするとともに、その値を設定します。
|
||||||
|
|
||||||
|
?> 自動シフトには、この値を素早く取得するのに役立つ3つの特別なキーがあります。詳細は「自動シフトのセットアップ」を見てください!
|
||||||
|
|
||||||
|
### NO_AUTO_SHIFT_SPECIAL (単純にこのように定義します)
|
||||||
|
|
||||||
|
-\_, =+, [{, ]}, ;:, '", ,<, .> および /? を含む特殊キーを自動シフトしません
|
||||||
|
|
||||||
|
### NO_AUTO_SHIFT_NUMERIC (単純にこのように定義します)
|
||||||
|
|
||||||
|
0から9までの数字キーを自動シフトしません。
|
||||||
|
|
||||||
|
### NO_AUTO_SHIFT_ALPHA (単純にこのように定義します)
|
||||||
|
|
||||||
|
AからZを含むアルファベット文字を自動シフトしません。
|
||||||
|
|
||||||
|
## 自動シフトセットアップの使用
|
||||||
|
|
||||||
|
これにより、`AUTO_SHIFT_TIMEOUT` で設定している時間を一時的に増減させたり報告するために、3つのキーを定義することができます。
|
||||||
|
|
||||||
|
### セットアップ
|
||||||
|
|
||||||
|
3つのキーを一時的にキーマップにマップします:
|
||||||
|
|
||||||
|
| キー名 | 説明 |
|
||||||
|
|----------|-----------------------------------------------------|
|
||||||
|
| KC_ASDN | 自動シフトタイムアウト変数を下げる |
|
||||||
|
| KC_ASUP | 自動シフトタイムアウト変数を上げる |
|
||||||
|
| KC_ASRP | 現在の自動シフトタイムアウト値を報告する |
|
||||||
|
| KC_ASON | 自動シフト機能をオンにする |
|
||||||
|
| KC_ASOFF | 自動シフト機能をオフにする |
|
||||||
|
| KC_ASTG | 自動シフト機能の状態を切り替える |
|
||||||
|
|
||||||
|
新しいファームウェアをコンパイルしてアップロードします。
|
||||||
|
|
||||||
|
### 使い方
|
||||||
|
|
||||||
|
これらのテスト中は、完全に普段通り入力する必要があり、意図的にシフトされたキーを使わずに入力するように注意する必要があります。
|
||||||
|
|
||||||
|
1. アルファベットの複数の文を入力します。
|
||||||
|
2. 大文字に注意してください。
|
||||||
|
3. 大文字が存在しない場合は、自動シフトタイムアウト値を減らすために `KC_ASDN` にマップしたキーを押し、ステップ1に戻ります。
|
||||||
|
4. 大文字が幾つかある場合は、押す時間を短くしてこれらのキーをタップする必要があるか、あるいはタイムアウトを増やす必要があるかを決定します。
|
||||||
|
5. タイムアウトを増やすことに決めた場合は、`KC_ASUP` にマップしたキーを押し、ステップ1に戻ります。
|
||||||
|
6. 結果に満足したら、`KC_ASRP` にマップしたキーを押します。キーボードは `AUTO_SHIFT_TIMEOUT` の値を自動的に入力します。
|
||||||
|
7. 報告された値で `config.h` の `AUTO_SHIFT_TIMEOUT` を更新します。
|
||||||
|
8. `config.h` から `AUTO_SHIFT_SETUP` を削除します。
|
||||||
|
9. `KC_ASDN`、`KC_ASUP` および `KC_ASRP` のキーバインディングを削除します。
|
||||||
|
10. 新しいファームウェアをコンパイルしてアップロードします。
|
||||||
|
|
||||||
|
#### 実行例
|
||||||
|
|
||||||
|
hello world. my name is john doe. i am a computer programmer playing with
|
||||||
|
keyboards right now.
|
||||||
|
|
||||||
|
[KC_ASDN を何度か押します]
|
||||||
|
|
||||||
|
heLLo woRLd. mY nAMe is JOHn dOE. i AM A compUTeR proGRaMMER PlAYiNG witH
|
||||||
|
KEYboArDS RiGHT NOw.
|
||||||
|
|
||||||
|
[KC_ASUP を数回押します]
|
||||||
|
|
||||||
|
hello world. my name is john Doe. i am a computer programmer playing with
|
||||||
|
keyboarDs right now.
|
||||||
|
|
||||||
|
[KC_ASRPを押します]
|
||||||
|
|
||||||
|
115
|
||||||
|
|
||||||
|
キーボードは現在の `AUTO_SHIFT_TIMEOUT` 値を表す `115` を入力しました。これで設定が完了しました!テスト中に現れる *D* キーを少し練習してください。それで完璧です。
|
||||||
253
docs/ja/feature_backlight.md
Normal file
253
docs/ja/feature_backlight.md
Normal file
@@ -0,0 +1,253 @@
|
|||||||
|
# バックライト
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 5d5ff80:docs/feature_backlight.md
|
||||||
|
git diff 5d5ff80 HEAD -- docs/feature_backlight.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
多くのキーボードは、キースイッチを貫通して配置されたり、キースイッチの下に配置された個々の LED によって、バックライトキーをサポートします。この機能は通常スイッチごとに単一の色しか使用できないため、[RGB アンダーグロー](ja/feature_rgblight.md)および [RGB マトリックス](ja/feature_rgb_matrix.md)機能のどちらとも異なりますが、キーボードに複数の異なる単一色の LED を取り付けることは当然可能です。
|
||||||
|
|
||||||
|
QMK は *パルス幅変調*(*Pulse Width Modulation*) すなわち PWM として知られている技術で急速にオンおよびオフを切り替えることで、これらの LED の輝度を制御できます。PWM 信号のデューティサイクルを変えることで、調光の錯覚を起こすことができます。
|
||||||
|
|
||||||
|
MCU は、GPIO ピンにはそんなに電流を供給できません。MCU から直接バックライトに給電せずに、バックライトピンは LED への電力を切り替えるトランジスタあるいは MOSFET に接続されます。
|
||||||
|
|
||||||
|
## 機能の設定
|
||||||
|
|
||||||
|
ほとんどのキーボードではバックライトをサポートしている場合にデフォルトで有効になっていますが、もし機能しない場合は `rules.mk` が以下を含んでいることを確認してください:
|
||||||
|
|
||||||
|
```makefile
|
||||||
|
BACKLIGHT_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
## キーコード
|
||||||
|
有効にすると、以下のキーコードを使ってバックライトレベルを変更することができます。
|
||||||
|
|
||||||
|
| キー | 説明 |
|
||||||
|
|---------|------------------------------------------|
|
||||||
|
| `BL_TOGG` | バックライトをオンあるいはオフにする |
|
||||||
|
| `BL_STEP` | バックライトレベルを循環する |
|
||||||
|
| `BL_ON` | バックライトを最大輝度に設定する |
|
||||||
|
| `BL_OFF` | バックライトをオフにする |
|
||||||
|
| `BL_INC` | バックライトレベルを上げる |
|
||||||
|
| `BL_DEC` | バックライトレベルを下げる |
|
||||||
|
| `BL_BRTG` | バックライトの明滅動作を切り替える |
|
||||||
|
|
||||||
|
## バックライト関数群
|
||||||
|
|
||||||
|
| 関数 | 説明 |
|
||||||
|
|----------|-----------------------------------------------------------|
|
||||||
|
| `backlight_toggle()` | バックライトをオンあるいはオフにする |
|
||||||
|
| `backlight_enable()` | バックライトをオンにする |
|
||||||
|
| `backlight_disable()` | バックライトをオフにする |
|
||||||
|
| `backlight_step()` | バックライトレベルを循環する |
|
||||||
|
| `backlight_increase()` | バックライトレベルを上げる |
|
||||||
|
| `backlight_decrease()` | バックライトレベルを下げる |
|
||||||
|
| `backlight_level(x)` | バックライトのレベルを特定のレベルに設定する |
|
||||||
|
| `get_backlight_level()` | 現在のバックライトレベルを返す |
|
||||||
|
| `is_backlight_enabled()` | バックライトが現在オンかどうかを返す |
|
||||||
|
|
||||||
|
### バックライトの明滅動作の関数群
|
||||||
|
|
||||||
|
| 関数 | 説明 |
|
||||||
|
|----------|---------------------------------------------------|
|
||||||
|
| `breathing_toggle()` | バックライトの明滅動作をオンまたはオフにする |
|
||||||
|
| `breathing_enable()` | バックライトの明滅動作をオンにする |
|
||||||
|
| `breathing_disable()` | バックライトの明滅動作をオフにする |
|
||||||
|
|
||||||
|
## ドライバの設定
|
||||||
|
|
||||||
|
どのドライバを使うかを選択するには、以下を使って `rules.mk` を設定します:
|
||||||
|
|
||||||
|
```makefile
|
||||||
|
BACKLIGHT_DRIVER = software # 有効なドライバの値は 'pwm,software,no' です
|
||||||
|
```
|
||||||
|
|
||||||
|
各ドライバについてのヘルプは以下を見てください。
|
||||||
|
|
||||||
|
## 共通のドライバ設定
|
||||||
|
|
||||||
|
バックライトの挙動を変更するには、`config.h` の中で以下の `#define` をします:
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|---------------------|-------------|--------------------------------------------------------------------------------------|
|
||||||
|
| `BACKLIGHT_LEVELS` | `3` | 輝度のレベルの数 (オフを除いて最大 31) |
|
||||||
|
| `BACKLIGHT_CAPS_LOCK` | *定義なし* | バックライトを使って Caps Lock のインジケータを有効にする (専用 LED の無いキーボードのため) |
|
||||||
|
| `BACKLIGHT_BREATHING` | *定義なし* | サポートされる場合は、バックライトの明滅動作を有効にする |
|
||||||
|
| `BREATHING_PERIOD` | `6` | 各バックライトの "明滅" の長さ(秒) |
|
||||||
|
| `BACKLIGHT_ON_STATE` | `0` | バックライトが "オン" の時のバックライトピンの状態 - high の場合は `1`、low の場合は `0` |
|
||||||
|
|
||||||
|
### バックライトオン状態
|
||||||
|
|
||||||
|
ほとんどのバックライトの回路は N チャンネルの MOSFET あるいは NPN トランジスタによって駆動されます。これは、トランジスタを*オン*にして LED を点灯させるには、ゲートまたはベースに接続されているバックライトピンを *high* に駆動する必要があることを意味します。
|
||||||
|
ただし、P チャンネルの MOSFET あるいは PNP トランジスタが使われる場合があります。この場合、トランジスタがオンの時、ピンは代わりに *low* で駆動されます。
|
||||||
|
|
||||||
|
この機能は `BACKLIGHT_ON_STATE` 定義することでキーボードレベルで設定されます。
|
||||||
|
|
||||||
|
## AVR ドライバ
|
||||||
|
|
||||||
|
AVR ボードでは、デフォルトのドライバは現在のところ最善のシナリオを選択するために構成を探っています。ドライバはデフォルトで設定されますが、rules.mk 内の同等の設定は以下の通りです:
|
||||||
|
```makefile
|
||||||
|
BACKLIGHT_DRIVER = pwm
|
||||||
|
```
|
||||||
|
|
||||||
|
### 注意事項
|
||||||
|
|
||||||
|
ハードウェア PWM は以下の表に従ってサポートされます:
|
||||||
|
|
||||||
|
| バックライトピン | AT90USB64/128 | ATmega16/32U4 | ATmega16/32U2 | ATmega32A | ATmega328P |
|
||||||
|
|-------------|-------------|-------------|-------------|---------|----------|
|
||||||
|
| `B1` | | | | | Timer 1 |
|
||||||
|
| `B2` | | | | | Timer 1 |
|
||||||
|
| `B5` | Timer 1 | Timer 1 | | | |
|
||||||
|
| `B6` | Timer 1 | Timer 1 | | | |
|
||||||
|
| `B7` | Timer 1 | Timer 1 | Timer 1 | | |
|
||||||
|
| `C4` | Timer 3 | | | | |
|
||||||
|
| `C5` | Timer 3 | | Timer 1 | | |
|
||||||
|
| `C6` | Timer 3 | Timer 3 | Timer 1 | | |
|
||||||
|
| `D4` | | | | Timer 1 | |
|
||||||
|
| `D5` | | | | Timer 1 | |
|
||||||
|
|
||||||
|
他の全てのピンはソフトウェア PWM を使います。[オーディオ](ja/feature_audio.md)機能が無効あるいは1つのタイマだけを使っている場合は、ハードウェアタイマによってバックライト PWM を引き起こすことができます:
|
||||||
|
|
||||||
|
| オーディオピン | オーディオタイマ | ソフトウェア PWM タイマ |
|
||||||
|
|---------|-----------|------------------|
|
||||||
|
| `C4` | Timer 3 | Timer 1 |
|
||||||
|
| `C5` | Timer 3 | Timer 1 |
|
||||||
|
| `C6` | Timer 3 | Timer 1 |
|
||||||
|
| `B5` | Timer 1 | Timer 3 |
|
||||||
|
| `B6` | Timer 1 | Timer 3 |
|
||||||
|
| `B7` | Timer 1 | Timer 3 |
|
||||||
|
|
||||||
|
両方のタイマーがオーディオのために使われている場合、バックライト PWM はハードウェアタイマを使いませんが、代わりにマトリックススキャンの間に引き起こされます。この場合、PWM の計算は十分なタイミングの精度で呼ばれないかもしれないため、バックライトの明滅はサポートされず、バックライトもちらつくかもしれません。
|
||||||
|
|
||||||
|
### AVR 設定
|
||||||
|
|
||||||
|
バックライトの挙動を変更するには、`config.h` の中で以下の `#define` をします:
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|---------------------|-------------|--------------------------------------------------------------------------------------------------------------|
|
||||||
|
| `BACKLIGHT_PIN` | `B7` | LED を制御するピン。自身のキーボードを設計している場合を除き、これを変更する必要はないはずです |
|
||||||
|
| `BACKLIGHT_PINS` | *定義なし* | 実験的: 詳細は以下を見てください |
|
||||||
|
| `BACKLIGHT_LEVELS` | `3` | 輝度のレベルの数 (オフを除いて最大 31) |
|
||||||
|
| `BACKLIGHT_CAPS_LOCK` | *定義なし* | バックライトを使って Caps Lock のインジケータを有効にする (専用 LED の無いキーボードのため) |
|
||||||
|
| `BACKLIGHT_BREATHING` | *定義なし* | サポートされる場合は、バックライトの明滅動作を有効にする |
|
||||||
|
| `BREATHING_PERIOD` | `6` | 各バックライトの "明滅" の長さ(秒) |
|
||||||
|
| `BACKLIGHT_ON_STATE` | `1` | バックライトが "オン" の時のバックライトピンの状態 - high の場合は `1`、low の場合は `0` |
|
||||||
|
|
||||||
|
### バックライトオン状態
|
||||||
|
|
||||||
|
ほとんどのバックライトの回路は N チャンネルの MOSFET あるいは NPN トランジスタによって駆動されます。これは、トランジスタを*オン*にして LED を点灯させるには、ゲートまたはベースに接続されているバックライトピンを *high* に駆動する必要があることを意味します。
|
||||||
|
ただし、P チャンネルの MOSFET あるいは PNP トランジスタが使われる場合があります。この場合、トランジスタがオンの時、ピンは代わりに *low* で駆動されます。
|
||||||
|
|
||||||
|
この機能は `BACKLIGHT_ON_STATE` 定義することでキーボードレベルで設定されます。
|
||||||
|
|
||||||
|
### 複数のバックライトピン
|
||||||
|
|
||||||
|
ほとんどのキーボードは、全てのバックライト LED を制御するたった1つのバックライトピンを持ちます (特にバックライトがハードウェア PWM ピンに接続されている場合)。
|
||||||
|
ソフトウェア PWM では、複数のバックライトピンを定義することができます。これらすべてのピンは PWM デューティサイクル時に同時にオンおよびオフになります。
|
||||||
|
この機能により、例えば Caps Lock LED (またはその他の制御可能な LED) の輝度を、バックライトの他の LED と同じレベルに設定することができます。Caps Lock の代わりに LCTRL をマップしていて、Caps Lock がオンの時に Caps Lock LED をアクティブにする代わりにバックライトの一部にする必要がある場合に便利です。
|
||||||
|
|
||||||
|
複数のバックライトピンをアクティブにするには、`config.h` に次のようなものを追加する必要があります:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define BACKLIGHT_LED_COUNT 2
|
||||||
|
#undef BACKLIGHT_PIN
|
||||||
|
#define BACKLIGHT_PINS { F5, B2 }
|
||||||
|
```
|
||||||
|
|
||||||
|
### ハードウェア PWM 実装
|
||||||
|
|
||||||
|
バックライト用にサポートされているピンを使う場合、QMK は PWM 信号を出力するように設定されたハードウェアタイマを使います。タイマーは 0 にリセットする前に `ICRx` (デフォルトでは `0xFFFF`) までカウントします。
|
||||||
|
希望の輝度が計算され、`OCRxx` レジスタ内に格納されます。カウンタがこの値まで達すると、バックライトピンは low になり、カウンタがリセットされると再び high になります。
|
||||||
|
このように `OCRxx` は基本的に LED のデューティサイクル、従って輝度を制御します。`0x0000` は完全にオフで、 `0xFFFF` は完全にオンです。
|
||||||
|
|
||||||
|
明滅動作の効果はカウンタがリセットされる(秒間あたりおよそ244回)たびに呼び出される `TIMER1_OVF_vect` の割り込みハンドラを登録することで可能になります。
|
||||||
|
このハンドラ内で、増分カウンタの値が事前に計算された輝度曲線にマップされます。明滅動作をオフにするには、割り込みを単純に禁止し、輝度を EEPROM に格納されているレベルに再設定します。
|
||||||
|
|
||||||
|
### タイマーにアシストされた PWM 実装
|
||||||
|
|
||||||
|
`BACKLIGHT_PIN` がハードウェアバックライトピンに設定されていない場合、QMK はソフトウェア割り込みを引き起こすように設定されているハードウェアタイマを使います。タイマーは 0 にリセットする前に `ICRx` (デフォルトでは `0xFFFF`) までカウントします。
|
||||||
|
0 に再設定すると、CPU は LED をオンにする OVF (オーバーフロー)割り込みを発火し、デューティサイクルを開始します。
|
||||||
|
希望の輝度が計算され、`OCRxx` レジスタ内に格納されます。カウンタがこの値に達すると、CPU は比較出力一致割り込みを発火し、LED をオフにします。
|
||||||
|
このように `OCRxx` は基本的に LED のデューティサイクル、従って輝度を制御します。 `0x0000` は完全にオフで、 `0xFFFF` は完全にオンです。
|
||||||
|
|
||||||
|
明滅の効果はハードウェア PWM 実装と同じです。
|
||||||
|
|
||||||
|
## ARM ドライバ
|
||||||
|
|
||||||
|
まだ初期段階ですが、ARM バックライトサポートは最終的に AVR と同等の機能を持つことを目指しています。ドライバはデフォルトで設定されますが、rules.mk 内の同等の設定は以下の通りです:
|
||||||
|
```makefile
|
||||||
|
BACKLIGHT_DRIVER = pwm
|
||||||
|
```
|
||||||
|
|
||||||
|
### 注意事項
|
||||||
|
|
||||||
|
現在のところ、ハードウェア PWM のみがサポートされ、タイマーはアシストされず、自動設定は提供されません。
|
||||||
|
|
||||||
|
?> STMF072 のバックライトサポートのテストは制限されています。人によって違うかもしれません。不明な場合は、rules.mk で `BACKLIGHT_ENABLE = no` を設定します。
|
||||||
|
|
||||||
|
### ARM 設定
|
||||||
|
|
||||||
|
バックライトの挙動を変更するには、`config.h` の中で以下の `#define` をします:
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|------------------------|-------------|-------------------------------------------------------------------------------------------------------------|
|
||||||
|
| `BACKLIGHT_PIN` | `B7` | LED を制御するピン。自身のキーボードを設計している場合を除き、これを変更する必要はないはずです |
|
||||||
|
| `BACKLIGHT_PWM_DRIVER` | `PWMD4` | 使用する PWM ドライバ。ピンから PWM タイマへのマッピングについては、ST データシートを見てください。自身のキーボードを設計している場合を除き、これを変更する必要はないはずです |
|
||||||
|
| `BACKLIGHT_PWM_CHANNEL` | `3` | 使用する PWM チャンネル。ピンから PWM チャンネルへのマッピングについては、ST データシートを見てください。自身のキーボードを設計している場合を除き、これを変更する必要はないはずです |
|
||||||
|
| `BACKLIGHT_PAL_MODE` | `2` | 使用するピンの代替機能。ピンの AF マッピングについては ST データシートを見てください。自身のキーボードを設計している場合を除き、これを変更する必要はないはずです |
|
||||||
|
|
||||||
|
## Software PWM Driver :id=software-pwm-driver
|
||||||
|
|
||||||
|
他のキーボードのタスクを実行中に PWM をエミュレートすることにより、追加のプラットフォーム設定なしで最大のハードウェア互換性を提供します。トレードオフは、キーボードが忙しい時にバックライトが揺れる可能性があることです。有効にするには、rules.mk に以下を追加します:
|
||||||
|
```makefile
|
||||||
|
BACKLIGHT_DRIVER = software
|
||||||
|
```
|
||||||
|
|
||||||
|
### ソフトウェア PWM 設定
|
||||||
|
|
||||||
|
バックライトの挙動を変更するには、`config.h` の中で以下の `#define` をします:
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|-----------------|-------------|-------------------------------------------------------------------------------------------------------------|
|
||||||
|
| `BACKLIGHT_PIN` | `B7` | LED を制御するピン。自身のキーボードを設計している場合を除き、これを変更する必要はないはずです |
|
||||||
|
| `BACKLIGHT_PINS` | *定義なし* | 実験的: 詳細は以下を見てください |
|
||||||
|
|
||||||
|
### 複数のバックライトピン
|
||||||
|
|
||||||
|
ほとんどのキーボードは、全てのバックライト LED を制御するたった1つのバックライトピンを持ちます (特にバックライトがハードウェア PWM ピンに接続されている場合)。
|
||||||
|
ソフトウェア PWM では、複数のバックライトピンを定義することができます。これらすべてのピンは PWM デューティサイクル時に同時にオンおよびオフになります。
|
||||||
|
この機能により、例えば Caps Lock LED (またはその他の制御可能な LED) の輝度を、バックライトの他の LED と同じレベルに設定することができます。Caps Lock の代わりに LCTRL をマップしていて、Caps Lock がオンの時に Caps Lock LED をアクティブにする代わりにバックライトの一部にする必要がある場合に便利です。
|
||||||
|
|
||||||
|
複数のバックライトピンをアクティブにするには、`config.h` に次のようなものを追加する必要があります:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#undef BACKLIGHT_PIN
|
||||||
|
#define BACKLIGHT_PINS { F5, B2 }
|
||||||
|
```
|
||||||
|
|
||||||
|
## カスタムドライバ
|
||||||
|
|
||||||
|
有効にするには、rules.mk に以下を追加します:
|
||||||
|
|
||||||
|
```makefile
|
||||||
|
BACKLIGHT_DRIVER = custom
|
||||||
|
```
|
||||||
|
|
||||||
|
カスタムドライバ API を実装する場合、提供されるキーボードフックは以下の通りです:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void backlight_init_ports(void) {
|
||||||
|
// オプション - 起動時に実行されます
|
||||||
|
// - 通常、ここでピンを設定します
|
||||||
|
}
|
||||||
|
void backlight_set(uint8_t level) {
|
||||||
|
// オプション - レベルの変更時に実行されます
|
||||||
|
// - 通常、ここで新しい値に応答します
|
||||||
|
}
|
||||||
|
|
||||||
|
void backlight_task(void) {
|
||||||
|
// オプション - 定期的に実行されます
|
||||||
|
// - ここで長時間実行されるアクションはパフォーマンスの問題を引き起こします
|
||||||
|
}
|
||||||
|
```
|
||||||
52
docs/ja/feature_bluetooth.md
Normal file
52
docs/ja/feature_bluetooth.md
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
# Bluetooth
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 5d5ff80:docs/feature_bluetooth.md
|
||||||
|
git diff 5d5ff80 HEAD -- docs/feature_bluetooth.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
## Bluetooth の既知のサポートハードウェア
|
||||||
|
|
||||||
|
現在のところ Bluetooth のサポートは AVR ベースのチップに限られます。Bluetooth 2.1 については、QMK は RN-42 モジュールと、Bluefruit EZ-Key をサポートしますが、後者はもう生産されていません。より最近の BLE プロトコルについては、現在のところ Adafruit Bluefruit SPI Friend のみが直接サポートされています。iOS デバイスに接続するには、BLE が必要です。iOS はマウス入力をサポートしないことに注意してください。
|
||||||
|
|
||||||
|
| ボード | Bluetooth プロトコル | 接続タイプ | rules.mk | Bluetooth チップ |
|
||||||
|
|----------------------------------------------------------------|----------------------------|----------------|---------------------------|--------------|
|
||||||
|
| [Adafruit EZ-Key HID](https://www.adafruit.com/product/1535) | Bluetooth Classic | UART | `BLUETOOTH = AdafruitEZKey` | |
|
||||||
|
| 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)
|
||||||
|
* RN-42 ファームウェアが書き込まれた HC-05 ボード。どちらも明らかに CSR BC417 チップを使っています。RN-42 ファームウェアを使って書き込むと、HID 機能が提供されます。
|
||||||
|
* Sparkfun Bluetooth Mate
|
||||||
|
* HM-13 ベースのボード
|
||||||
|
|
||||||
|
### Adafruit BLE SPI Friend
|
||||||
|
現在のところ QMK によってサポートされている唯一の bluetooth チップセットは、Adafruit Bluefruit SPI Friend です。Adafruit のカスタムファームウェアを実行する Nordic nRF5182 ベースのチップです。データは Hardware SPI を介した Adafruit の SDEP を使って転送されます。[Feather 32u4 Bluefruit LE](https://www.adafruit.com/product/2829) は Adafruit ファームウェアを搭載した Nordic BLE チップに SPI 経由で接続された AVR mcu であるため、サポートされます。SPI friend を使ってカスタムボードを構築する場合、32u4 feather が使用するピン選択を使うのが最も簡単ですが、以下の定義で config.h オプションでピンを変更することができます:
|
||||||
|
* #define AdafruitBleResetPin D4
|
||||||
|
* #define AdafruitBleCSPin B4
|
||||||
|
* #define AdafruitBleIRQPin E6
|
||||||
|
|
||||||
|
Bluefruit UART friend は SPI friend に変換することができますが、これにはMDBT40 チップへの直接の再書き込みとはんだ付けが[必要です](https://github.com/qmk/qmk_firmware/issues/2274)。
|
||||||
|
|
||||||
|
## Adafruit EZ-Key hid
|
||||||
|
これには[ハードウェアの変更](https://www.reddit.com/r/MechanicalKeyboards/comments/3psx0q/the_planck_keyboard_with_bluetooth_guide_and/?ref=search_posts)が必要ですが、Makefile を使って有効にすることができます。ファームウェアは引き続き USB 経由で文字を出力するため、コンピュータ経由で充電する場合は注意してください。任意にオフにするために Bluefruit 上にスイッチを持つことは理にかなっています。
|
||||||
|
|
||||||
|
|
||||||
|
<!-- FIXME: Document bluetooth support more completely. -->
|
||||||
|
## Bluetooth の Rules.mk オプション
|
||||||
|
これらのうちの1つだけを使ってください
|
||||||
|
* BLUETOOTH_ENABLE = yes (レガシーオプション)
|
||||||
|
* BLUETOOTH = RN42
|
||||||
|
* BLUETOOTH = AdafruitEZKey
|
||||||
|
* BLUETOOTH = AdafruitBLE
|
||||||
|
|
||||||
|
## Bluetooth キーコード
|
||||||
|
|
||||||
|
これは複数のキーボードの出力が選択できる場合に使われます。現在のところ、これは USB と Bluetooth の両方をサポートするキーボードで、それらの間の切り替えのみが可能です。
|
||||||
|
|
||||||
|
| 名前 | 説明 |
|
||||||
|
|----------|----------------------------------------------|
|
||||||
|
| `OUT_AUTO` | USB と Bluetooth を自動的に切り替える |
|
||||||
|
| `OUT_USB` | USB のみ |
|
||||||
|
| `OUT_BT` | Bluetooth のみ |
|
||||||
171
docs/ja/feature_bootmagic.md
Normal file
171
docs/ja/feature_bootmagic.md
Normal file
@@ -0,0 +1,171 @@
|
|||||||
|
# ブートマジック
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 5d5ff80:docs/feature_bootmagic.md
|
||||||
|
git diff 5d5ff80 HEAD -- docs/feature_bootmagic.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
再書き込みせずにキーボードの挙動を変更することができる、3つの独立した関連する機能があります。それぞれは似たような機能を持ちますが、キーボードがどのように設定されているかによって異なる方法でアクセスされます。
|
||||||
|
|
||||||
|
**ブートマジック**は初期化の間にキーボードを設定するためのシステムです。ブートマジックコマンドを起動するには、ブートマジックキーと1つ以上のコマンドキーを押し続けます。
|
||||||
|
|
||||||
|
**ブートマジックキーコード** は前に `MAGIC_` が付いており、キーボードが初期化された*後で*ブートマジックの機能にアクセスすることができます。キーコードを使うには、他のキーコードと同じようにそれらをキーマップに割り当てます。
|
||||||
|
|
||||||
|
以前は**マジック**として知られていた**コマンド**は、キーボードの異なる側面を制御することができる別の機能です。ブートマジックと一部の機能を共有しますが、コンソールにバージョン情報を出力するような、ブートマジックにはできないこともできます。詳細は、[コマンド](ja/feature_command.md)を見てください。
|
||||||
|
|
||||||
|
一部のキーボードでは、ブートマジックはデフォルトで無効になっています。その場合、`rules.mk` 内で以下のように明示的に有効にする必要があります:
|
||||||
|
|
||||||
|
```make
|
||||||
|
BOOTMAGIC_ENABLE = full
|
||||||
|
```
|
||||||
|
|
||||||
|
?> `full` の代わりに `yes` が使われていることがあるかもしれませんが、これは問題ありません。ただし、`yes` は非推奨で、理想的には `full` (あるいは`lite`) が使われるべきです。
|
||||||
|
|
||||||
|
さらに、以下を `rules.mk` ファイルに追加することで、[ブートマジックライト](#bootmagic-lite) (スケールダウンした、とても基本的なバージョンのブートマジック)を使うことができます:
|
||||||
|
|
||||||
|
```make
|
||||||
|
BOOTMAGIC_ENABLE = lite
|
||||||
|
```
|
||||||
|
|
||||||
|
## ホットキー
|
||||||
|
|
||||||
|
キーボードを接続しながら、ブートマジックキー(デフォルトはスペース)と目的のホットキーを押します。例えば、スペースと `B` を押したままにすると、ブートローダに入ります。
|
||||||
|
|
||||||
|
| ホットキー | 説明 |
|
||||||
|
|------------------|---------------------------------------------|
|
||||||
|
| エスケープ | EEPROM のブートマジック設定を無視する |
|
||||||
|
| `B` | ブートローダに入る |
|
||||||
|
| `D` | シリアルを介するデバッグ出力の切り替え |
|
||||||
|
| `X` | キーマトリックスのデバッグ出力の切り替え |
|
||||||
|
| `K` | キーボードのデバッグの切り替え |
|
||||||
|
| `M` | マウスのデバッグの切り替え |
|
||||||
|
| `L` | EE_HANDS 左右設定に、"左手"を設定 |
|
||||||
|
| `R` | EE_HANDS 左右設定に、"右手"を設定 |
|
||||||
|
| Backspace | EEPROM をクリア |
|
||||||
|
| Caps Lock | Caps Lock を左コントロールとして扱うかを切り替え |
|
||||||
|
| 左 Control | Caps Lock と左コントロールの入れ替えを切り替え |
|
||||||
|
| 左 Alt | 左 Alt と左 GUI の入れ替えを切り替え |
|
||||||
|
| 右 Alt | 右 Alt と右 GUI の入れ替えを切り替え |
|
||||||
|
| 左 GUI | GUI キーの有効・無効を切り替え (ゲームの時に便利です) |
|
||||||
|
| <code>`</code> | <code>`</code> とエスケープの入れ替えを切り替え |
|
||||||
|
| `\` | `\` とバックスペースの入れ替えを切り替え |
|
||||||
|
| `N` | N キーロールオーバー (NKRO) の有効・無効を切り替え |
|
||||||
|
| `0` | レイヤー 0 をデフォルトレイヤーにする |
|
||||||
|
| `1` | レイヤー 1 をデフォルトレイヤーにする |
|
||||||
|
| `2` | レイヤー 2 をデフォルトレイヤーにする |
|
||||||
|
| `3` | レイヤー 3 をデフォルトレイヤーにする |
|
||||||
|
| `4` | レイヤー 4 をデフォルトレイヤーにする |
|
||||||
|
| `5` | レイヤー 5 をデフォルトレイヤーにする |
|
||||||
|
| `6` | レイヤー 6 をデフォルトレイヤーにする |
|
||||||
|
| `7` | レイヤー 7 をデフォルトレイヤーにする |
|
||||||
|
|
||||||
|
## キーコード :id=keycodes
|
||||||
|
|
||||||
|
| キー | エイリアス | 説明 |
|
||||||
|
|----------------------------------|---------|--------------------------------------------------------------------------|
|
||||||
|
| `MAGIC_SWAP_CONTROL_CAPSLOCK` | `CL_SWAP` | Caps Lock と左コントロールの入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_CONTROL_CAPSLOCK` | `CL_NORM` | Caps Lock と左コントロールの入れ替えの解除 |
|
||||||
|
| `MAGIC_CAPSLOCK_TO_CONTROL` | `CL_CTRL` | Caps Lock をコントロールとして扱う |
|
||||||
|
| `MAGIC_UNCAPSLOCK_TO_CONTROL` | `CL_CAPS` | Caps Lock をコントロールとして扱うことを止める |
|
||||||
|
| `MAGIC_SWAP_LCTL_LGUI` | `LCG_SWP` | 左コントロールと GUI の入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_LCTL_LGUI` | `LCG_NRM` | 左コントロールと GUI の入れ替えを解除 |
|
||||||
|
| `MAGIC_SWAP_RCTL_RGUI` | `RCG_SWP` | 右コントロールと GUI の入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_RCTL_RGUI` | `RCG_NRM` | 右コントロールと GUI の入れ替えを解除 |
|
||||||
|
| `MAGIC_SWAP_CTL_GUI` | `CG_SWAP` | 両側のコントロールと GUI の入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_CTL_GUI` | `CG_NORM` | 両側のコントロールと GUI の入れ替えを解除 |
|
||||||
|
| `MAGIC_TOGGLE_CTL_GUI` | `CG_TOGG` | 両側のコントロールと GUI の入れ替えの切り替え |
|
||||||
|
| `MAGIC_SWAP_LALT_LGUI` | `LAG_SWP` | 左 Alt と GUI の入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_LALT_LGUI` | `LAG_NRM` | 左 Alt と GUI の入れ替えを解除 |
|
||||||
|
| `MAGIC_SWAP_RALT_RGUI` | `RAG_SWP` | 右 Alt と GUI の入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_RALT_RGUI` | `RAG_NRM` | 右 Alt と GUI の入れ替えを解除 |
|
||||||
|
| `MAGIC_SWAP_ALT_GUI` | `AG_SWAP` | 両側の Alt と GUI の入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_ALT_GUI` | `AG_NORM` | 両側の Alt と GUI の入れ替えを解除 |
|
||||||
|
| `MAGIC_TOGGLE_ALT_GUI` | `AG_TOGG` | 両側の Alt と GUI の入れ替えの切り替え |
|
||||||
|
| `MAGIC_NO_GUI` | `GUI_OFF` | GUI キーを無効にする |
|
||||||
|
| `MAGIC_UNNO_GUI` | `GUI_ON` | GUI キーを有効にする |
|
||||||
|
| `MAGIC_SWAP_GRAVE_ESC` | `GE_SWAP` | <code>`</code> とエスケープの入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_GRAVE_ESC` | `GE_NORM` | <code>`</code> とエスケープの入れ替えを解除 |
|
||||||
|
| `MAGIC_SWAP_BACKSLASH_BACKSPACE` | `BS_SWAP` | `\` とバックスペースを入れ替え |
|
||||||
|
| `MAGIC_UNSWAP_BACKSLASH_BACKSPACE` | `BS_NORM` | `\` とバックスペースの入れ替えを解除する |
|
||||||
|
| `MAGIC_HOST_NKRO` | `NK_ON` | N キーロールオーバーを有効にする |
|
||||||
|
| `MAGIC_UNHOST_NKRO` | `NK_OFF` | N キーロールオーバーを無効にする |
|
||||||
|
| `MAGIC_TOGGLE_NKRO` | `NK_TOGG` | N キーロールオーバーの有効・無効を切り替え |
|
||||||
|
| `MAGIC_EE_HANDS_LEFT` | `EH_LEFT` | 分割キーボードのマスター側を左手に設定(`EE_HANDS` 用) |
|
||||||
|
| `MAGIC_EE_HANDS_RIGHT` | `EH_RGHT` | 分割キーボードのマスター側を右手に設定(`EE_HANDS` 用) |
|
||||||
|
|
||||||
|
## 設定
|
||||||
|
|
||||||
|
ブートマジックのためのホットキーの割り当てを変更したい場合は、キーボードあるいはキーマップレベルのどちらかで、`config.h` にこれらを `#define` します。
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|----------------------------------------|-------------|---------------------------------------------------|
|
||||||
|
| `BOOTMAGIC_KEY_SALT` | `KC_SPACE` | ブートマジックキー |
|
||||||
|
| `BOOTMAGIC_KEY_SKIP` | `KC_ESC` | EEPROM のブートマジック設定を無視する |
|
||||||
|
| `BOOTMAGIC_KEY_EEPROM_CLEAR` | `KC_BSPACE` | EEPROM 設定をクリアする |
|
||||||
|
| `BOOTMAGIC_KEY_BOOTLOADER` | `KC_B` | ブートローダに入る |
|
||||||
|
| `BOOTMAGIC_KEY_DEBUG_ENABLE` | `KC_D` | シリアルを介するデバッグ出力の切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_DEBUG_MATRIX` | `KC_X` | マトリックスのデバッグを切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_DEBUG_KEYBOARD` | `KC_K` | キーボードのデバッグの切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_DEBUG_MOUSE` | `KC_M` | マウスのデバッグの切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_EE_HANDS_LEFT` | `KC_L` | EE_HANDS 左右設定に、"左手"を設定 |
|
||||||
|
| `BOOTMAGIC_KEY_EE_HANDS_RIGHT` | `KC_R` | EE_HANDS 左右設定に、"右手"を設定 |
|
||||||
|
| `BOOTMAGIC_KEY_SWAP_CONTROL_CAPSLOCK` | `KC_LCTRL` | 左コントロールと Caps Lock の入れ替え |
|
||||||
|
| `BOOTMAGIC_KEY_CAPSLOCK_TO_CONTROL` | `KC_CAPSLOCK` | Caps Lock を左コントロールとして扱うかを切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_SWAP_LALT_LGUI` | `KC_LALT` | 左 Alt と左 GUI の入れ替えを切り替え (macOS 用) |
|
||||||
|
| `BOOTMAGIC_KEY_SWAP_RALT_RGUI` | `KC_RALT` | 右 Alt と右 GUI の入れ替えを切り替え (macOS 用) |
|
||||||
|
| `BOOTMAGIC_KEY_NO_GUI` | `KC_LGUI` | GUI キーの有効・無効を切り替え (ゲームの時に便利です) |
|
||||||
|
| `BOOTMAGIC_KEY_SWAP_GRAVE_ESC` | `KC_GRAVE` | <code>`</code> とエスケープの入れ替えを切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_SWAP_BACKSLASH_BACKSPACE` | `KC_BSLASH` | `\` とバックスペースの入れ替えを切り替え |
|
||||||
|
| `BOOTMAGIC_HOST_NKRO` | `KC_N` | N キーロールオーバー (NKRO) の有効・無効を切り替え |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_0` | `KC_0` | レイヤー 0 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_1` | `KC_1` | レイヤー 1 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_2` | `KC_2` | レイヤー 2 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_3` | `KC_3` | レイヤー 3 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_4` | `KC_4` | レイヤー 4 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_5` | `KC_5` | レイヤー 5 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_6` | `KC_6` | レイヤー 6 をデフォルトレイヤーにする |
|
||||||
|
| `BOOTMAGIC_KEY_DEFAULT_LAYER_7` | `KC_7` | レイヤー 7 をデフォルトレイヤーにする |
|
||||||
|
|
||||||
|
# ブートマジックライト :id=bootmagic-lite
|
||||||
|
|
||||||
|
本格的なブートマジック機能の他に、ブートローダへのジャンプのみを処理するブートマジックライトがあります。これは、物理的なリセットボタンが無くブートローダにジャンプする方法が必要だが、ブートマジックが引き起こす問題を扱いたくないキーボードに適しています。
|
||||||
|
|
||||||
|
ブートマジックのこのバージョンを有効にするには、以下を使って `rules.mk` で有効にする必要があります:
|
||||||
|
|
||||||
|
```make
|
||||||
|
BOOTMAGIC_ENABLE = lite
|
||||||
|
```
|
||||||
|
|
||||||
|
さらに、どのキーを使うかを指定したほうが良いかもしれません。これは普通ではないマトリックスを持つキーボードで特に便利です。そのためには、使いたいキーの行と列を指定する必要があります。`config.h` ファイルにこれらのエントリを追加します:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define BOOTMAGIC_LITE_ROW 0
|
||||||
|
#define BOOTMAGIC_LITE_COLUMN 1
|
||||||
|
```
|
||||||
|
|
||||||
|
デフォルトでは、これらは 0 と 0 に設定されます。これは通常はほとんどのキーボードで "ESC" キーです。
|
||||||
|
|
||||||
|
ブートローダを起動するには、キーボードを接続する時にこのキーを押し続けます。たった1つのキーです。
|
||||||
|
|
||||||
|
!> ブートマジックライトを使用すると、EEPROM を**常にリセットします**。つまり保存された全ての設定は失われます。
|
||||||
|
|
||||||
|
## 高度なブートマジックライト
|
||||||
|
|
||||||
|
`bootmagic_lite` 関数は必要に応じてコード内で置き換えることができるように、弱く定義されています。これの良い例は Zeal60 キーボードで、追加の処理が必要です。
|
||||||
|
|
||||||
|
関数を置き換えるには、以下のようなものをコードに追加するだけです:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void bootmagic_lite(void) {
|
||||||
|
matrix_scan();
|
||||||
|
wait_ms(DEBOUNCE * 2);
|
||||||
|
matrix_scan();
|
||||||
|
|
||||||
|
if (matrix_get_row(BOOTMAGIC_LITE_ROW) & (1 << BOOTMAGIC_LITE_COLUMN)) {
|
||||||
|
// ブートローダにジャンプする。
|
||||||
|
bootloader_jump();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
追加の機能をここに追加することができます。例えば、eeprom のリセットやブートマジックを起動するために押す必要がある追加のキーです。`bootmagic_lite` はファームウェア内で大部分の機能が初期化される前に呼ばれることに注意してください。
|
||||||
108
docs/ja/feature_combo.md
Normal file
108
docs/ja/feature_combo.md
Normal file
@@ -0,0 +1,108 @@
|
|||||||
|
# コンボ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.94:docs/feature_combo.md
|
||||||
|
git diff 0.8.94 HEAD -- docs/feature_combo.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
コンボ機能は、同時押し方式でのカスタムアクション追加機能です。同時に複数のキーを押して、異なる効果を生み出すことができます。例えば、タッピング時間内で `A` と `S` を押すと、代わりに `ESC` が押されます。もっと複雑なタスクを実行させることもできます。
|
||||||
|
|
||||||
|
この機能を有効にするには、`rules.mk` に `COMBO_ENABLE = yes` を追加する必要があります。
|
||||||
|
|
||||||
|
さらに、使用するコンボの数を `config.h` の中で、`#define COMBO_COUNT 1` (1を使用するコンボの数で置き換えます)と書いて、指定する必要があります。
|
||||||
|
<!-- At this time, this is necessary -->
|
||||||
|
|
||||||
|
また、デフォルトでは、コンボのタッピング時間は `TAPPING_TERM` と同じ値に設定されます (ほとんどのキーボードではデフォルトで 200)。ただし、`config.h` で定義することにより異なる値を指定することができます。例えば: `#define COMBO_TERM 300` はコンボのためのタイムアウト時間を 300ms に設定します。
|
||||||
|
|
||||||
|
次に、`keymap.c` ファイルに、`COMBO_END` で終了するキーのシーケンス、およびキーの組み合わせを列挙する構造体、その結果のアクションを定義する必要があります。
|
||||||
|
|
||||||
|
```c
|
||||||
|
const uint16_t PROGMEM test_combo[] = {KC_A, KC_B, COMBO_END};
|
||||||
|
combo_t key_combos[COMBO_COUNT] = {COMBO(test_combo, KC_ESC)};
|
||||||
|
```
|
||||||
|
|
||||||
|
これは、A と B のキーを押した場合に、"Escape" を送信します。
|
||||||
|
|
||||||
|
!> このメソッドは[基本的なキーコード](ja/keycodes_basic.md)のみをサポートします。詳細な制御については例を見てください。
|
||||||
|
|
||||||
|
## 例
|
||||||
|
|
||||||
|
リストを追加したい場合は、以下のようなものを使います:
|
||||||
|
|
||||||
|
```c
|
||||||
|
enum combos {
|
||||||
|
AB_ESC,
|
||||||
|
JK_TAB
|
||||||
|
};
|
||||||
|
|
||||||
|
const uint16_t PROGMEM ab_combo[] = {KC_A, KC_B, COMBO_END};
|
||||||
|
const uint16_t PROGMEM jk_combo[] = {KC_J, KC_K, COMBO_END};
|
||||||
|
|
||||||
|
combo_t key_combos[COMBO_COUNT] = {
|
||||||
|
[AB_ESC] = COMBO(ab_combo, KC_ESC),
|
||||||
|
[JK_TAB] = COMBO(jk_combo, KC_TAB)
|
||||||
|
};
|
||||||
|
```
|
||||||
|
|
||||||
|
より複雑な実装として、カスタム処理を追加するために `process_combo_event` 関数を使うことができます。
|
||||||
|
|
||||||
|
```c
|
||||||
|
enum combo_events {
|
||||||
|
ZC_COPY,
|
||||||
|
XV_PASTE
|
||||||
|
};
|
||||||
|
|
||||||
|
const uint16_t PROGMEM copy_combo[] = {KC_Z, KC_C, COMBO_END};
|
||||||
|
const uint16_t PROGMEM paste_combo[] = {KC_X, KC_V, COMBO_END};
|
||||||
|
|
||||||
|
combo_t key_combos[COMBO_COUNT] = {
|
||||||
|
[ZC_COPY] = COMBO_ACTION(copy_combo),
|
||||||
|
[XV_PASTE] = COMBO_ACTION(paste_combo),
|
||||||
|
};
|
||||||
|
|
||||||
|
void process_combo_event(uint8_t combo_index, bool pressed) {
|
||||||
|
switch(combo_index) {
|
||||||
|
case ZC_COPY:
|
||||||
|
if (pressed) {
|
||||||
|
tap_code16(LCTL(KC_C));
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case XV_PASTE:
|
||||||
|
if (pressed) {
|
||||||
|
tap_code16(LCTL(KC_V));
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
これは、Z と C を押すと Ctrl+C を送信し、X と V を押すと Ctrl+V を送信します。これを変更して、レイヤーの変更、サウンドの再生、設定の変更などを行うこともできます。
|
||||||
|
|
||||||
|
## 追加の設定
|
||||||
|
|
||||||
|
長いコンボあるいはさらに長いコンボを使っている場合、構造体があなたのしていることに対応するのに十分な大きさで無いかもしれないため、問題が発生するかもしれません。
|
||||||
|
|
||||||
|
この場合、`config.h` ファイルに `#define EXTRA_LONG_COMBOS` または `#define EXTRA_EXTRA_LONG_COMBOS` のどちらかを追加することができます。
|
||||||
|
|
||||||
|
`COMBO_ALLOW_ACTION_KEYS` を定義することでアクションキーを有効にすることもできます。
|
||||||
|
|
||||||
|
## キーコード
|
||||||
|
|
||||||
|
その場でコンボ機能を有効、無効および切り替えすることができます。ゲームなどで、一時的にそれらを無効にする必要がある場合に便利です。
|
||||||
|
|
||||||
|
| キーコード | 説明 |
|
||||||
|
|----------|---------------------------------|
|
||||||
|
| `CMB_ON` | コンボ機能をオンにします |
|
||||||
|
| `CMB_OFF` | コンボ機能をオフにします |
|
||||||
|
| `CMB_TOG` | コンボ機能のオンとオフを切り替えます |
|
||||||
|
|
||||||
|
## ユーザコールバック
|
||||||
|
|
||||||
|
キーコードに加えて、状態を設定または状態をチェックするために使うことができる幾つかの関数があります:
|
||||||
|
|
||||||
|
| 関数 | 説明 |
|
||||||
|
|-----------|--------------------------------------------------------------------|
|
||||||
|
| `combo_enable()` | コンボ機能を有効にします |
|
||||||
|
| `combo_disable()` | コンボ機能を無効にし、コンボバッファをクリアします |
|
||||||
|
| `combo_toggle()` | コンボ機能の状態を切り替えます |
|
||||||
|
| `is_combo_enabled()` | コンボ機能の状態(true か false)を返します |
|
||||||
56
docs/ja/feature_command.md
Normal file
56
docs/ja/feature_command.md
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
# コマンド
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.94:docs/feature_command.md
|
||||||
|
git diff 0.8.94 HEAD -- docs/feature_command.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
コマンド(旧称:マジック)は、ファームウェアを書き込んだり、[ブートマジック](ja/feature_bootmagic.md)を使うためにプラグを抜いたりすることなくキーボードの挙動を変更する方法です。この機能と[ブートマジックキーコード](feature_bootmagic.md#keycodes)には多くの重複があります。可能な限り、コマンドでは無くブートマジックキーコードの機能を使うことをお勧めします。
|
||||||
|
|
||||||
|
一部のキーボードではコマンドがデフォルトで無効になっています。その場合、`rules.mk` 内で明示的に有効にする必要があります:
|
||||||
|
|
||||||
|
```make
|
||||||
|
COMMAND_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
## 使用法
|
||||||
|
|
||||||
|
コマンドを使うには、`IS_COMMAND()` マクロで定義されたキーの組み合わせを押し続けます。デフォルトでは、これは「左Shift + 右Shift」です。次に、目的のコマンドに対応するキーを押します。例えば、現在の QMK バージョンを QMK Toolbox コンソールに出力するには、「左Shift + 右Shift + `V`」を押します。
|
||||||
|
|
||||||
|
## 設定
|
||||||
|
|
||||||
|
コマンドのためのキーの割り当てを変更したい場合は、キーボードあるいはキーマップレベルのどちらかで、`config.h` にこれらを `#define` します。ここで割り当てる全てのキーコードは `KC_` 接頭辞を省略する必要があります。
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|------------------------------------|--------------------------------|------------------------------------------------|
|
||||||
|
| `IS_COMMAND()` | `(get_mods() == MOD_MASK_SHIFT)` | コマンドをアクティブにするキーの組み合わせ |
|
||||||
|
| `MAGIC_KEY_SWITCH_LAYER_WITH_FKEYS` | `true` | ファンクション行を使ってデフォルトレイヤーを設定 |
|
||||||
|
| `MAGIC_KEY_SWITCH_LAYER_WITH_NKEYS` | `true` | 数字キーでデフォルトレイヤーを設定 |
|
||||||
|
| `MAGIC_KEY_SWITCH_LAYER_WITH_CUSTOM` | `false` | `MAGIC_KEY_LAYER0..9` を使ってデフォルトレイヤーを設定 |
|
||||||
|
| `MAGIC_KEY_DEBUG` | `D` | シリアルを介するデバッグの切り替え |
|
||||||
|
| `MAGIC_KEY_DEBUG_MATRIX` | `X` | キーマトリックスのデバッグの切り替え |
|
||||||
|
| `MAGIC_KEY_DEBUG_KBD` | `K` | キーボードのデバッグの切り替え |
|
||||||
|
| `MAGIC_KEY_DEBUG_MOUSE` | `M` | マウスのデバッグの切り替え |
|
||||||
|
| `MAGIC_KEY_CONSOLE` | `C` | コマンドコンソールを有効にする |
|
||||||
|
| `MAGIC_KEY_VERSION` | `V` | コンソールに実行中の QMK バージョンを出力 |
|
||||||
|
| `MAGIC_KEY_STATUS` | `S` | コンソールに現在のキーボードの状態を出力 |
|
||||||
|
| `MAGIC_KEY_HELP` | `H` | コンソールにコマンドのヘルプを出力 |
|
||||||
|
| `MAGIC_KEY_HELP_ALT` | `SLASH` | コンソールにコマンドのヘルプを出力 (代替) |
|
||||||
|
| `MAGIC_KEY_LAYER0` | `0` | レイヤー 0 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER0_ALT` | `GRAVE` | レイヤー 0 をデフォルトレイヤーにする (代替) |
|
||||||
|
| `MAGIC_KEY_LAYER1` | `1` | レイヤー 1 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER2` | `2` | レイヤー 2 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER3` | `3` | レイヤー 3 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER4` | `4` | レイヤー 4 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER5` | `5` | レイヤー 5 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER6` | `6` | レイヤー 6 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER7` | `7` | レイヤー 7 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER8` | `8` | レイヤー 8 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_LAYER9` | `9` | レイヤー 9 をデフォルトレイヤーにする |
|
||||||
|
| `MAGIC_KEY_BOOTLOADER` | `B` | ブートローダにジャンプする |
|
||||||
|
| `MAGIC_KEY_BOOTLOADER_ALT` | `ESC` | ブートローダにジャンプする (代替) |
|
||||||
|
| `MAGIC_KEY_LOCK` | `CAPS` | 何も入力できないようにキーボードをロック |
|
||||||
|
| `MAGIC_KEY_EEPROM` | `E` | 保存された EEPROM 設定をコンソールに出力 |
|
||||||
|
| `MAGIC_KEY_EEPROM_CLEAR` | `BSPACE` | EEPROM をクリア |
|
||||||
|
| `MAGIC_KEY_NKRO` | `N` | N キーロールオーバー (NKRO) の有効・無効を切り替え |
|
||||||
|
| `MAGIC_KEY_SLEEP_LED` | `Z` | コンピュータがスリープの時に LED を切り替え |
|
||||||
95
docs/ja/feature_dip_switch.md
Normal file
95
docs/ja/feature_dip_switch.md
Normal file
@@ -0,0 +1,95 @@
|
|||||||
|
# DIP スイッチ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.94:docs/feature_dip_switch.md
|
||||||
|
git diff 0.8.94 HEAD -- docs/feature_dip_switch.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
DIP スイッチは、以下を `rules.mk` に追加することでサポートされます:
|
||||||
|
|
||||||
|
DIP_SWITCH_ENABLE = yes
|
||||||
|
|
||||||
|
さらに、以下を `config.h` に追加します:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define DIP_SWITCH_PINS { B14, A15, A10, B9 }
|
||||||
|
```
|
||||||
|
|
||||||
|
## コールバック
|
||||||
|
|
||||||
|
コールバック関数を `<keyboard>.c` に記述することができます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void dip_switch_update_kb(uint8_t index, bool active) {
|
||||||
|
dip_switch_update_user(index, active);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
あるいは `keymap.c` に記述することもできます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void dip_switch_update_user(uint8_t index, bool active) {
|
||||||
|
switch (index) {
|
||||||
|
case 0:
|
||||||
|
if(active) { audio_on(); } else { audio_off(); }
|
||||||
|
break;
|
||||||
|
case 1:
|
||||||
|
if(active) { clicky_on(); } else { clicky_off(); }
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
if(active) { music_on(); } else { music_off(); }
|
||||||
|
break;
|
||||||
|
case 3:
|
||||||
|
if (active) {
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
PLAY_SONG(plover_song);
|
||||||
|
#endif
|
||||||
|
layer_on(_PLOVER);
|
||||||
|
} else {
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
PLAY_SONG(plover_gb_song);
|
||||||
|
#endif
|
||||||
|
layer_off(_PLOVER);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
更に、より複雑な処理ができるビットマスク関数をサポートします。
|
||||||
|
|
||||||
|
|
||||||
|
```c
|
||||||
|
void dip_switch_update_mask_kb(uint32_t state) {
|
||||||
|
dip_switch_update_mask_user(state);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
あるいは `keymap.c` に記述することもできます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void dip_switch_update_mask_user(uint32_t state) {
|
||||||
|
if (state & (1UL<<0) && state & (1UL<<1)) {
|
||||||
|
layer_on(_ADJUST); // C on esc
|
||||||
|
} else {
|
||||||
|
layer_off(_ADJUST);
|
||||||
|
}
|
||||||
|
if (state & (1UL<<0)) {
|
||||||
|
layer_on(_TEST_A); // A on ESC
|
||||||
|
} else {
|
||||||
|
layer_off(_TEST_A);
|
||||||
|
}
|
||||||
|
if (state & (1UL<<1)) {
|
||||||
|
layer_on(_TEST_B); // B on esc
|
||||||
|
} else {
|
||||||
|
layer_off(_TEST_B);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
## ハードウェア
|
||||||
|
|
||||||
|
DIP スイッチの片側は MCU のピンへ直接配線し、もう一方の側はグラウンドに配線する必要があります。機能的に同じであるため、どちら側がどちらに接続されているかは問題にはならないはずです。
|
||||||
71
docs/ja/feature_dynamic_macros.md
Normal file
71
docs/ja/feature_dynamic_macros.md
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
# 動的マクロ: ランタイムでのマクロの記録および再生
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.123:docs/feature_dynamic_macros.md
|
||||||
|
git diff 0.8.123 HEAD -- docs/feature_dynamic_macros.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
QMK はその場で作られた一時的なマクロをサポートします。これらを動的マクロと呼びます。それらはユーザがキーボードから定義し、キーボードのプラグを抜くか再起動すると失われます。
|
||||||
|
|
||||||
|
1つまたは2つのマクロに合計128のキー押下を保存できます。RAM をより多く使用してサイズを増やすことができます。
|
||||||
|
|
||||||
|
有効にするには、最初に `rules.mk` に `DYNAMIC_MACRO_ENABLE = yes` を記述します。そして、以下のキーをキーマップに追加します:
|
||||||
|
|
||||||
|
| キー | Alias | 説明 |
|
||||||
|
|------------------|----------|---------------------------------------------------|
|
||||||
|
| `DYN_REC_START1` | `DM_REC1` | マクロ 1 の記録を開始します |
|
||||||
|
| `DYN_REC_START2` | `DM_REC2` | マクロ 2 の記録を開始します |
|
||||||
|
| `DYN_MACRO_PLAY1` | `DM_PLY1` | マクロ 1 を再生します |
|
||||||
|
| `DYN_MACRO_PLAY2` | `DM_PLY2` | マクロ 2 を再生します |
|
||||||
|
| `DYN_REC_STOP` | `DM_RSTP` | 現在記録中のマクロの記録を終了します。 |
|
||||||
|
|
||||||
|
これが必要な全てです。
|
||||||
|
|
||||||
|
マクロの記録を開始するには、`DYN_REC_START1` または `DYN_REC_START2` のどちらかを押します。
|
||||||
|
|
||||||
|
記録を終了するには、`DYN_REC_STOP` レイヤーボタンを押します。
|
||||||
|
|
||||||
|
マクロを再生するには、`DYN_MACRO_PLAY1` あるいは `DYN_MACRO_PLAY2` のどちらかを押します。
|
||||||
|
|
||||||
|
マクロの一部としてマクロを再生することができます。マクロ 1 を記録中にマクロ 2 を再生、またはその逆も問題ありません。ただし、再帰的なマクロ、つまりマクロ 1 を再生するマクロ 1 は作成しないでください。もしそうしてキーボードが反応しなくなった場合は、キーボードを取り外し再び接続します。これを完全に無効にするには、`config.h` ファイルで `DYNAMIC_MACRO_NO_NESTING` を定義します。
|
||||||
|
|
||||||
|
?> 動的マクロの内部の詳細については、`process_dynamic_macro.h` および `process_dynamic_macro.c` ファイルのコメントを読んでください。
|
||||||
|
|
||||||
|
## カスタマイズ
|
||||||
|
|
||||||
|
ある程度のカスタマイズを可能にするオプションがいくつか追加されています。
|
||||||
|
|
||||||
|
| 定義 | デフォルト | 説明 |
|
||||||
|
|----------------------------|----------------|-----------------------------------------------------------------------------------------------------------------|
|
||||||
|
| `DYNAMIC_MACRO_SIZE` | 128 | 動的マクロが使用できるメモリ量を設定します。これは限られたリソースであり、コントローラに依存します。 |
|
||||||
|
| `DYNAMIC_MACRO_USER_CALL` | *定義なし* | これを定義すると、ユーザの `keymap.c` ファイルを使ってマクロが起動されます。 |
|
||||||
|
| `DYNAMIC_MACRO_NO_NESTING` | *定義なし* | これを定義すると、別のマクロからマクロを呼び出す(入れ子になったマクロ)機能を無効にします。 |
|
||||||
|
|
||||||
|
|
||||||
|
記録中にキーを押すたびに LED が点滅し始めた場合は、マクロバッファにマクロを入れるスペースがもう無いことを意味します。マクロを入れるには、他のマクロ(それらは同じバッファを共有します)を短くするか、`config.h` に `DYNAMIC_MACRO_SIZE` 定義を追加することでバッファを増やします(デフォルト値: 128; ヘッダ内のコメントを読んでください)。
|
||||||
|
|
||||||
|
|
||||||
|
### DYNAMIC_MACRO_USER_CALL
|
||||||
|
|
||||||
|
以前のバージョンの動的マクロをお使いの方へ: 専用の `DYN_REC_STOP` キーを使わずに動的マクロキーへのアクセスに使われるレイヤーモディファイアのみを使って、マクロの記録を終了することもまだ可能です。この動作に戻したい場合は、`#define DYNAMIC_MACRO_USER_CALL` を `config.h` に追加し、以下のスニペットを `process_record_user()` 関数の先頭に記述します:
|
||||||
|
|
||||||
|
```c
|
||||||
|
uint16_t macro_kc = (keycode == MO(_DYN) ? DYN_REC_STOP : keycode);
|
||||||
|
|
||||||
|
if (!process_record_dynamic_macro(macro_kc, record)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### ユーザフック
|
||||||
|
|
||||||
|
カスタム機能とフィードバックオプションを動的マクロ機能に追加するために使うことができるフックが幾つかあります。これによりある程度のカスタマイズが可能になります。
|
||||||
|
|
||||||
|
direction がどのマクロであるかを示すことに注意してください。`1` がマクロ 1、`-1` がマクロ 2、0 がマクロ無しです。
|
||||||
|
|
||||||
|
* `dynamic_macro_record_start_user(void)` - マクロの記録を開始する時に起動されます。
|
||||||
|
* `dynamic_macro_play_user(int8_t direction)` - マクロを再生する時に起動されます。
|
||||||
|
* `dynamic_macro_record_key_user(int8_t direction, keyrecord_t *record)` - マクロの記録中に各キー押下で起動されます。
|
||||||
|
* `dynamic_macro_record_end_user(int8_t direction)` - マクロの記録を停止した時に起動されます。
|
||||||
|
|
||||||
|
さらに、動的マクロ機能が有効な場合にバックライトを点滅させるために `dynamic_macro_led_blink()` を呼び出すことができます。
|
||||||
81
docs/ja/feature_encoders.md
Normal file
81
docs/ja/feature_encoders.md
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
# エンコーダ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.123:docs/feature_encoders.md
|
||||||
|
git diff 0.8.123 HEAD -- docs/feature_encoders.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
以下を `rules.mk` に追加することで基本的なエンコーダがサポートされます:
|
||||||
|
|
||||||
|
```make
|
||||||
|
ENCODER_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
さらに、以下を `config.h` に追加します:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define ENCODERS_PAD_A { B12 }
|
||||||
|
#define ENCODERS_PAD_B { B13 }
|
||||||
|
```
|
||||||
|
|
||||||
|
各 PAD_A/B 変数は配列を定義するため、複数のエンコーダを定義することができます。例えば:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define ENCODERS_PAD_A { encoder1a, encoder2a }
|
||||||
|
#define ENCODERS_PAD_B { encoder1b, encoder2b }
|
||||||
|
```
|
||||||
|
|
||||||
|
エンコーダの時計回りの方向が間違っている場合は、A と B のパッド定義を交換することができます。define を使って逆にすることもできます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define ENCODER_DIRECTION_FLIP
|
||||||
|
```
|
||||||
|
|
||||||
|
さらに、解像度を同じファイルで指定することができます (デフォルトかつお勧めは4):
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define ENCODER_RESOLUTION 4
|
||||||
|
```
|
||||||
|
|
||||||
|
## 分割キーボード
|
||||||
|
|
||||||
|
分割キーボードのそれぞれの側のエンコーダに異なるピン配列を使っている場合、右側のピン配列を以下のように定義することができます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define ENCODERS_PAD_A_RIGHT { encoder1a, encoder2a }
|
||||||
|
#define ENCODERS_PAD_B_RIGHT { encoder1b, encoder2b }
|
||||||
|
```
|
||||||
|
|
||||||
|
## コールバック
|
||||||
|
|
||||||
|
コールバック関数を `<keyboard>.c` に記述することができます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void encoder_update_kb(uint8_t index, bool clockwise) {
|
||||||
|
encoder_update_user(index, clockwise);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
あるいは `keymap.c` に記述することもできます:
|
||||||
|
|
||||||
|
```c
|
||||||
|
void encoder_update_user(uint8_t index, bool clockwise) {
|
||||||
|
if (index == 0) { /* First encoder */
|
||||||
|
if (clockwise) {
|
||||||
|
tap_code(KC_PGDN);
|
||||||
|
} else {
|
||||||
|
tap_code(KC_PGUP);
|
||||||
|
}
|
||||||
|
} else if (index == 1) { /* Second encoder */
|
||||||
|
if (clockwise) {
|
||||||
|
tap_code(KC_DOWN);
|
||||||
|
} else {
|
||||||
|
tap_code(KC_UP);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## ハードウェア
|
||||||
|
|
||||||
|
エンコーダの A と B の線は MCU に直接配線し、C/common 線はグランドに配線する必要があります。
|
||||||
37
docs/ja/feature_grave_esc.md
Normal file
37
docs/ja/feature_grave_esc.md
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
# グレイブエスケープ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.123:docs/feature_grave_esc.md
|
||||||
|
git diff 0.8.123 HEAD -- docs/feature_grave_esc.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
60% キーボード、またはファンクションキー行の無い他のレイアウトを使っている場合、専用の Escape キーが無いことに気付くでしょう。グレイブエスケープは grave キー (<code>`</code> および `~`) を Escape と共有することができる機能です。
|
||||||
|
|
||||||
|
## 使用法
|
||||||
|
|
||||||
|
キーマップ内の `KC_GRAVE` キー (通常は`1` キーの左)を `KC_GESC` に置き換えます。ほとんどの場合、このキーは押された時に `KC_ESC` を出力します。ただし、Shift あるいは GUI を押したままにすると、代わりに `KC_GRV` を出力します。
|
||||||
|
|
||||||
|
## OS に見えるもの
|
||||||
|
|
||||||
|
メアリーがキーボードで GESC を押すと、OS には KC_ESC 文字が見えます。メアリーが Shift を押しながら GESC を押すと、`~` または Shift された時はバッククォートを出力します。彼女が GUI/CMD/WIN を押したままにすると、1つの <code>`</code> 文字を出力します。
|
||||||
|
|
||||||
|
## キーコード
|
||||||
|
|
||||||
|
| キー | エイリアス | 説明 |
|
||||||
|
|---------|-----------|------------------------------------------------------------------|
|
||||||
|
| `KC_GESC` | `GRAVE_ESC` | 押された場合に Escape。Shift あるいは GUI が押されたままの場合は <code>`</code> |
|
||||||
|
|
||||||
|
### 注意事項
|
||||||
|
|
||||||
|
macOS では、Command+<code>`</code> はデフォルトで "次のウィンドウを操作対象にする" にマップされます。つまりバッククォートを出力しません。さらに、ショートカットがキーボード環境設定で変更された場合でも、ターミナルは常にこのショートカットを認識してウィンドウを切り替えます。
|
||||||
|
|
||||||
|
## 設定
|
||||||
|
|
||||||
|
グレイブエスケープが壊す可能性のあるキーの組み合わせが幾つかあります。その中には、Windows では Control+Shift+Escape、macOSでは Command+Option+Escape があります。これを回避するには、`config.h` で以下のオプションを `#define` することができます:
|
||||||
|
|
||||||
|
| 定義 | 説明 |
|
||||||
|
|--------------------------|-----------------------------------------|
|
||||||
|
| `GRAVE_ESC_ALT_OVERRIDE` | Alt が押された場合、常に Escape を送信する |
|
||||||
|
| `GRAVE_ESC_CTRL_OVERRIDE` | Control が押された場合、常に Escape を送信する |
|
||||||
|
| `GRAVE_ESC_GUI_OVERRIDE` | GUI が押された場合、常に Escape を送信する |
|
||||||
|
| `GRAVE_ESC_SHIFT_OVERRIDE` | Shift が押された場合、常に Escape を送信する |
|
||||||
163
docs/ja/feature_haptic_feedback.md
Normal file
163
docs/ja/feature_haptic_feedback.md
Normal file
@@ -0,0 +1,163 @@
|
|||||||
|
# 触覚フィードバック
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.123:docs/feature_haptic_feedback.md
|
||||||
|
git diff 0.8.123 HEAD -- docs/feature_haptic_feedback.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
## 触覚フィードバック の rules.mk オプション
|
||||||
|
|
||||||
|
現在のところ、`rules.mk` で触覚フィードバック用に以下のオプションを利用可能です:
|
||||||
|
|
||||||
|
`HAPTIC_ENABLE += DRV2605L`
|
||||||
|
|
||||||
|
`HAPTIC_ENABLE += SOLENOID`
|
||||||
|
|
||||||
|
## サポートされる既知のハードウェア
|
||||||
|
|
||||||
|
| 名前 | 説明 |
|
||||||
|
|--------------------|-------------------------------------------------|
|
||||||
|
| [LV061228B-L65-A](https://www.digikey.com/product-detail/en/jinlong-machinery-electronics-inc/LV061228B-L65-A/1670-1050-ND/7732325) | z-axis 2v LRA |
|
||||||
|
| [Mini Motor Disc](https://www.adafruit.com/product/1201) | small 2-5v ERM |
|
||||||
|
|
||||||
|
## 触覚キーコード
|
||||||
|
|
||||||
|
以下のキーコードは、選択した触覚メカニズムに依存して動作するかどうか決まります。
|
||||||
|
|
||||||
|
| 名前 | 説明 |
|
||||||
|
|-----------|-------------------------------------------------------|
|
||||||
|
| `HPT_ON` | 触覚フィードバックをオン |
|
||||||
|
| `HPT_OFF` | 触覚フィードバックをオフ |
|
||||||
|
| `HPT_TOG` | 触覚フィードバックのオン/オフを切り替え |
|
||||||
|
| `HPT_RST` | 触覚フィードバック設定をデフォルトに戻す |
|
||||||
|
| `HPT_FBK` | キー押下またはリリースまたはその両方でフィードバックを切り替え |
|
||||||
|
| `HPT_BUZ` | ソレノイドの振動のオン/オフを切り替え |
|
||||||
|
| `HPT_MODI` | 次の DRV2605L 波形に移動 |
|
||||||
|
| `HPT_MODD` | 前の DRV2605L 波形に移動 |
|
||||||
|
| `HPT_CONT` | 連続触覚モードのオン/オフを切り替え |
|
||||||
|
| `HPT_CONI` | DRV2605L の連続触覚強度を増加 |
|
||||||
|
| `HPT_COND` | DRV2605L の連続触覚強度を減少 |
|
||||||
|
| `HPT_DWLI` | ソレノイドの滞留時間を増加 |
|
||||||
|
| `HPT_DWLD` | ソレノイドの滞留時間を減少 |
|
||||||
|
|
||||||
|
### ソレノイド
|
||||||
|
|
||||||
|
ほとんどの MCU はソレノイドのコイルを駆動するために必要な電流を供給できないため、最初に MOSFET を介してソレノイドを駆動する回路を構築する必要があります。
|
||||||
|
|
||||||
|
[Adafruit が提供する配線図](https://playground.arduino.cc/uploads/Learning/solenoid_driver.pdf)
|
||||||
|
|
||||||
|
|
||||||
|
| 設定 | デフォルト | 説明 |
|
||||||
|
|--------------------------|---------------|-------------------------------------------------------|
|
||||||
|
| `SOLENOID_PIN` | *定義なし* | ソレノイドが接続されているピンを設定する。 |
|
||||||
|
| `SOLENOID_DEFAULT_DWELL` | `12` ms | ソレノイドのデフォルトの滞留時間を設定する。 |
|
||||||
|
| `SOLENOID_MIN_DWELL` | `4` ms | 滞留時間の下限を設定する。 |
|
||||||
|
| `SOLENOID_MAX_DWELL` | `100` ms | 滞留時間の上限を設定する。 |
|
||||||
|
|
||||||
|
?> 滞留時間とは、「プランジャー」が作動したままになる時間です。滞留時間により、ソレノイドの音が変わります。
|
||||||
|
|
||||||
|
ブートローダ実行中に一部のピンが給電されているかもしれず (例えば、STM32F303 チップ上の A13)、そうすると書き込みプロセスの間ずっとソレノイドがオン状態になることに注意してください。これはソレノイドを加熱し損傷を与えるかもしれません。ソレノイドが接続されているピンがブートローダ/DFU 実行中にソレノイドをオンにしていることが分かった場合は、他のピンを選択してください。
|
||||||
|
|
||||||
|
### DRV2605L
|
||||||
|
|
||||||
|
DRV2605Lは i2c プロトコルで制御され、SDA および SCL ピンに接続する必要があります。これらは使用する MCU によって異なります。
|
||||||
|
|
||||||
|
#### フィードバックモータのセットアップ
|
||||||
|
|
||||||
|
このドライバは2つの異なるフィードバックモータをサポートします。選択したモータに基づいて、`config.h` で以下を設定します。
|
||||||
|
|
||||||
|
##### ERM
|
||||||
|
|
||||||
|
偏心回転質量振動モータ (ERM) は偏りのある重りが取り付けられたモータで、駆動信号が取り付けられると偏りのある重りが回転し、正弦波が振動に変換されます。
|
||||||
|
|
||||||
|
```
|
||||||
|
#define FB_ERM_LRA 0
|
||||||
|
#define FB_BRAKEFACTOR 3 /* For 1x:0, 2x:1, 3x:2, 4x:3, 6x:4, 8x:5, 16x:6, Disable Braking:7 */
|
||||||
|
#define FB_LOOPGAIN 1 /* For Low:0, Medium:1, High:2, Very High:3 */
|
||||||
|
|
||||||
|
/* 特定のモータに最適な設定については、データシートを参照してください。*/
|
||||||
|
#define RATED_VOLTAGE 3
|
||||||
|
#define V_PEAK 5
|
||||||
|
```
|
||||||
|
##### LRA
|
||||||
|
|
||||||
|
線形共振アクチュエータ (LRA、線形バイブレータとしても知られています)は、ERM と異なります。LRA は重りと磁石をバネで吊るしたものとボイスコイルで構成されています。駆動信号が印加されるとされると、重りは単一の軸で振動します (左右または上下)。重りはバネに取り付けられているため、特定の周波数で共振効果があります。この周波数は LRA が最も効率的に動作する箇所です。この周波数の推奨範囲については、モータのデータシートを参照してください。
|
||||||
|
|
||||||
|
```
|
||||||
|
#define FB_ERM_LRA 1
|
||||||
|
#define FB_BRAKEFACTOR 3 /* For 1x:0, 2x:1, 3x:2, 4x:3, 6x:4, 8x:5, 16x:6, Disable Braking:7 */
|
||||||
|
#define FB_LOOPGAIN 1 /* For Low:0, Medium:1, High:2, Very High:3 */
|
||||||
|
|
||||||
|
/* 特定のモータに最適な設定については、データシートを参照してください。*/
|
||||||
|
#define RATED_VOLTAGE 2
|
||||||
|
#define V_PEAK 2.8
|
||||||
|
#define V_RMS 2.0
|
||||||
|
#define V_PEAK 2.1
|
||||||
|
#define F_LRA 205 /* 共振周波数 */
|
||||||
|
```
|
||||||
|
|
||||||
|
#### DRV2605L 波形ライブラリ
|
||||||
|
|
||||||
|
DRV2605L には呼び出して再生できる様々な波形シーケンスのプリロードライブラリが同梱されています。マクロを書く場合、これらの波形は `DRV_pulse(*sequence name or number*)` を使って再生することができます
|
||||||
|
|
||||||
|
データシートの波形シーケンスのリスト
|
||||||
|
|
||||||
|
| seq# | シーケンス名 | seq# | シーケンス名 | seq# | シーケンス名 |
|
||||||
|
|-----|---------------------|-----|-----------------------------------|-----|--------------------------------------|
|
||||||
|
| 1 | strong_click | 43 | lg_dblclick_med_60 | 85 | transition_rampup_med_smooth2 |
|
||||||
|
| 2 | strong_click_60 | 44 | lg_dblsharp_tick | 86 | transition_rampup_short_smooth1 |
|
||||||
|
| 3 | strong_click_30 | 45 | lg_dblsharp_tick_80 | 87 | transition_rampup_short_smooth2 |
|
||||||
|
| 4 | sharp_click | 46 | lg_dblsharp_tick_60 | 88 | transition_rampup_long_sharp1 |
|
||||||
|
| 5 | sharp_click_60 | 47 | buzz | 89 | transition_rampup_long_sharp2 |
|
||||||
|
| 6 | sharp_click_30 | 48 | buzz_80 | 90 | transition_rampup_med_sharp1 |
|
||||||
|
| 7 | soft_bump | 49 | buzz_60 | 91 | transition_rampup_med_sharp2 |
|
||||||
|
| 8 | soft_bump_60 | 50 | buzz_40 | 92 | transition_rampup_short_sharp1 |
|
||||||
|
| 9 | soft_bump_30 | 51 | buzz_20 | 93 | transition_rampup_short_sharp2 |
|
||||||
|
| 10 | dbl_click | 52 | pulsing_strong | 94 | transition_rampdown_long_smooth1_50 |
|
||||||
|
| 11 | dbl_click_60 | 53 | pulsing_strong_80 | 95 | transition_rampdown_long_smooth2_50 |
|
||||||
|
| 12 | trp_click | 54 | pulsing_medium | 96 | transition_rampdown_med_smooth1_50 |
|
||||||
|
| 13 | soft_fuzz | 55 | pulsing_medium_80 | 97 | transition_rampdown_med_smooth2_50 |
|
||||||
|
| 14 | strong_buzz | 56 | pulsing_sharp | 98 | transition_rampdown_short_smooth1_50 |
|
||||||
|
| 15 | alert_750ms | 57 | pulsing_sharp_80 | 99 | transition_rampdown_short_smooth2_50 |
|
||||||
|
| 16 | alert_1000ms | 58 | transition_click | 100 | transition_rampdown_long_sharp1_50 |
|
||||||
|
| 17 | strong_click1 | 59 | transition_click_80 | 101 | transition_rampdown_long_sharp2_50 |
|
||||||
|
| 18 | strong_click2_80 | 60 | transition_click_60 | 102 | transition_rampdown_med_sharp1_50 |
|
||||||
|
| 19 | strong_click3_60 | 61 | transition_click_40 | 103 | transition_rampdown_med_sharp2_50 |
|
||||||
|
| 20 | strong_click4_30 | 62 | transition_click_20 | 104 | transition_rampdown_short_sharp1_50 |
|
||||||
|
| 21 | medium_click1 | 63 | transition_click_10 | 105 | transition_rampdown_short_sharp2_50 |
|
||||||
|
| 22 | medium_click2_80 | 64 | transition_hum | 106 | transition_rampup_long_smooth1_50 |
|
||||||
|
| 23 | medium_click3_60 | 65 | transition_hum_80 | 107 | transition_rampup_long_smooth2_50 |
|
||||||
|
| 24 | sharp_tick1 | 66 | transition_hum_60 | 108 | transition_rampup_med_smooth1_50 |
|
||||||
|
| 25 | sharp_tick2_80 | 67 | transition_hum_40 | 109 | transition_rampup_med_smooth2_50 |
|
||||||
|
| 26 | sharp_tick3_60 | 68 | transition_hum_20 | 110 | transition_rampup_short_smooth1_50 |
|
||||||
|
| 27 | sh_dblclick_str | 69 | transition_hum_10 | 111 | transition_rampup_short_smooth2_50 |
|
||||||
|
| 28 | sh_dblclick_str_80 | 70 | transition_rampdown_long_smooth1 | 112 | transition_rampup_long_sharp1_50 |
|
||||||
|
| 29 | sh_dblclick_str_60 | 71 | transition_rampdown_long_smooth2 | 113 | transition_rampup_long_sharp2_50 |
|
||||||
|
| 30 | sh_dblclick_str_30 | 72 | transition_rampdown_med_smooth1 | 114 | transition_rampup_med_sharp1_50 |
|
||||||
|
| 31 | sh_dblclick_med | 73 | transition_rampdown_med_smooth2 | 115 | transition_rampup_med_sharp2_50 |
|
||||||
|
| 32 | sh_dblclick_med_80 | 74 | transition_rampdown_short_smooth1 | 116 | transition_rampup_short_sharp1_50 |
|
||||||
|
| 33 | sh_dblclick_med_60 | 75 | transition_rampdown_short_smooth2 | 117 | transition_rampup_short_sharp2_50 |
|
||||||
|
| 34 | sh_dblsharp_tick | 76 | transition_rampdown_long_sharp1 | 118 | long_buzz_for_programmatic_stopping |
|
||||||
|
| 35 | sh_dblsharp_tick_80 | 77 | transition_rampdown_long_sharp2 | 119 | smooth_hum1_50 |
|
||||||
|
| 36 | sh_dblsharp_tick_60 | 78 | transition_rampdown_med_sharp1 | 120 | smooth_hum2_40 |
|
||||||
|
| 37 | lg_dblclick_str | 79 | transition_rampdown_med_sharp2 | 121 | smooth_hum3_30 |
|
||||||
|
| 38 | lg_dblclick_str_80 | 80 | transition_rampdown_short_sharp1 | 122 | smooth_hum4_20 |
|
||||||
|
| 39 | lg_dblclick_str_60 | 81 | transition_rampdown_short_sharp2 | 123 | smooth_hum5_10 |
|
||||||
|
| 40 | lg_dblclick_str_30 | 82 | transition_rampup_long_smooth1 | | |
|
||||||
|
| 41 | lg_dblclick_med | 83 | transition_rampup_long_smooth2 | | |
|
||||||
|
| 42 | lg_dblclick_med_80 | 84 | transition_rampup_med_smooth1 | | |
|
||||||
|
### オプションの DRV2605L の定義
|
||||||
|
|
||||||
|
```
|
||||||
|
#define DRV_GREETING *sequence name or number*
|
||||||
|
```
|
||||||
|
触覚フィードバッグが有効な場合、キーボード起動時に特定のシーケンスに合わせて振動します。以下の定義を使って選択することができます:
|
||||||
|
|
||||||
|
```
|
||||||
|
#define DRV_MODE_DEFAULT *sequence name or number*
|
||||||
|
```
|
||||||
|
これにより HPT_RST がアクティブモードとして設定するシーケンスを設定します。未定義の場合、HPT_RST が押された時にモードが 1 に設定されます。
|
||||||
|
|
||||||
|
### DRV2605L 連続触覚モード
|
||||||
|
|
||||||
|
このモードは強さを増減するオプションを使って連続触覚フィードバッグを設定します。
|
||||||
62
docs/ja/feature_hd44780.md
Normal file
62
docs/ja/feature_hd44780.md
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
# HD44780 LCD ディスプレイ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.123:docs/feature_hd44780.md
|
||||||
|
git diff 0.8.123 HEAD -- docs/feature_hd44780.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
これは Peter Fleury の LCD ライブラリの統合です。このページは基本について説明します。[詳細なドキュメントについてはこのページをご覧ください](http://homepage.hispeed.ch/peterfleury/doxygen/avr-gcc-libraries/group__pfleury__lcd.html) (訳注)原文のリンク先のページは、サービスの終了に伴って削除されています。移行先は (http://www.peterfleury.epizy.com/doxygen/avr-gcc-libraries/group__pfleury__lcd.html) と思われます。
|
||||||
|
|
||||||
|
HD44780 ディスプレイのサポートを有効にするには、キーボードの `rules.mk` の `HD44780_ENABLE` フラグを yes に設定します。
|
||||||
|
|
||||||
|
## 設定
|
||||||
|
|
||||||
|
ディスプレイで使用されるピンとディスプレイの行と列の数を、キーボードの `config.h` に設定する必要があります。
|
||||||
|
|
||||||
|
|
||||||
|
HD44780 のラベルが付いたセクションのコメントを外し、必要に応じてパラメータを変更します。
|
||||||
|
````
|
||||||
|
/*
|
||||||
|
* HD44780 LCD ディスプレイ設定
|
||||||
|
*/
|
||||||
|
|
||||||
|
#define LCD_LINES 2 //< ディスプレイの表示行数
|
||||||
|
#define LCD_DISP_LENGTH 16 //< ディスプレイの行ごとの表示文字数
|
||||||
|
#define LCD_IO_MODE 1 //< 0: メモリマップモード 1: IO ポートモード
|
||||||
|
#if LCD_IO_MODE
|
||||||
|
#define LCD_PORT PORTB //< LCD 行のためのポート
|
||||||
|
#define LCD_DATA0_PORT LCD_PORT //< 4ビットデータビット 0 のポート
|
||||||
|
#define LCD_DATA1_PORT LCD_PORT //< 4ビットデータビット 1 のポート
|
||||||
|
#define LCD_DATA2_PORT LCD_PORT //< 4ビットデータビット 2 のポート
|
||||||
|
#define LCD_DATA3_PORT LCD_PORT //< 4ビットデータビット 3 のポート
|
||||||
|
#define LCD_DATA0_PIN 4 //< 4ビットデータビット 0 のピン
|
||||||
|
#define LCD_DATA1_PIN 5 //< 4ビットデータビット 1 のピン
|
||||||
|
#define LCD_DATA2_PIN 6 //< 4ビットデータビット 2 のピン
|
||||||
|
#define LCD_DATA3_PIN 7 //< 4ビットデータビット 3 のピン
|
||||||
|
#define LCD_RS_PORT LCD_PORT //< RS 線のためのポート
|
||||||
|
#define LCD_RS_PIN 3 //< RS 線のためのピン
|
||||||
|
#define LCD_RW_PORT LCD_PORT //< RW 線のためのポート
|
||||||
|
#define LCD_RW_PIN 2 //< RW 線のためのピン
|
||||||
|
#define LCD_E_PORT LCD_PORT //< Enable 線のためのポート
|
||||||
|
#define LCD_E_PIN 1 //< Enable 線のためのピン
|
||||||
|
#endif
|
||||||
|
````
|
||||||
|
|
||||||
|
他のプロパティを設定する必要がある場合は、それらを `quantum/hd44780.h` からコピーし、`config.h` に設定することができます。(訳注)`quantum/hd44780.h` は `drivers/avr/hd44780.h` の間違いではないかと思われます。
|
||||||
|
|
||||||
|
## 使用法
|
||||||
|
|
||||||
|
ディスプレイを初期化するには、以下のパラメータのうちの1つを使って `lcd_init()` を呼び出します:
|
||||||
|
````
|
||||||
|
LCD_DISP_OFF : ディスプレイオフ
|
||||||
|
LCD_DISP_ON : ディスプレイオン、カーソルオフ
|
||||||
|
LCD_DISP_ON_CURSOR : ディスプレイオン、カーソルオン
|
||||||
|
LCD_DISP_ON_CURSOR_BLINK : ディスプレイオン、点滅カーソル
|
||||||
|
````
|
||||||
|
これはキーボードの `matrix_init_kb` またはキーマップの `matrix_init_user` で行うのが最適です。
|
||||||
|
使用前にディスプレイをクリアすることをお勧めします。
|
||||||
|
そのためには、`lcd_clrscr()` を呼びます。
|
||||||
|
|
||||||
|
ディスプレイに何かを表示するには、最初に `lcd_gotoxy(column, line)` を呼びます。最初の行の先頭に移動するには、`lcd_gotoxy(0, 0)` を呼び出し、その後 `lcd_puts("example string")` を使って文字列を出力します。
|
||||||
|
|
||||||
|
ディスプレイを制御することができる、より多くのメソッドがあります。[詳細なドキュメントについてはリンクされたページをご覧ください](http://homepage.hispeed.ch/peterfleury/doxygen/avr-gcc-libraries/group__pfleury__lcd.html) (訳注)原文のリンク先のページは、サービスの終了に伴って削除されています。移行先は (http://www.peterfleury.epizy.com/doxygen/avr-gcc-libraries/group__pfleury__lcd.html) と思われます。
|
||||||
27
docs/ja/feature_key_lock.md
Normal file
27
docs/ja/feature_key_lock.md
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# キーロック
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.134:docs/feature_key_lock.md
|
||||||
|
git diff 0.8.134 HEAD -- docs/feature_key_lock.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
特定のキーを長時間押すことが必要になる場合があります。キーロックは次に押すキーを押したままにします。もう一度押すと、リリースされます。
|
||||||
|
|
||||||
|
いくつかの文を全て大文字で入力する必要があるとしましょう。`KC_LOCK` を押し、次にシフトを押します。これで、シフトは次にタップするまで押していると見なされます。キーロックを Caps Lock と考えることができますが、さらに強力です。
|
||||||
|
|
||||||
|
## 使用法
|
||||||
|
|
||||||
|
最初に `rules.mk` で `KEY_LOCK_ENABLE = yes` を設定することでキーロックを有効にします。次に、キーマップでキーを選択し、それをキーコード `KC_LOCK` に割り当てます。
|
||||||
|
|
||||||
|
## キーコード
|
||||||
|
|
||||||
|
| キーコード | 説明 |
|
||||||
|
|---------|--------------------------------------------------------------|
|
||||||
|
| `KC_LOCK` | キーが再び押されるまで次のキーを押したままにします。 |
|
||||||
|
|
||||||
|
## 注意事項
|
||||||
|
|
||||||
|
キーロックは、標準アクションキーと[ワンショットモディファイア](ja/one_shot_keys.md)キー (例えば、Shift を `OSM(KC_LSFT)` と定義した場合)のみを押し続けることができます。
|
||||||
|
これは、QMK の特殊機能(ワンショットモディファイアを除く)、または `KC_LPRN` のような shift を押されたキーのバージョンは含みません。[基本的なキーコード](ja/keycodes_basic.md)リストにある場合、押したままにすることができます。
|
||||||
|
|
||||||
|
レイヤーの切り替えは、キーロックを解除しません。
|
||||||
114
docs/ja/feature_layouts.md
Normal file
114
docs/ja/feature_layouts.md
Normal file
@@ -0,0 +1,114 @@
|
|||||||
|
# レイアウト: 複数のキーボードで1つのキーマップを使用
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.134:docs/feature_layouts.md
|
||||||
|
git diff 0.8.134 HEAD -- docs/feature_layouts.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
`layouts/` フォルダは、様々なキーボードに適用できる色々な物理キーレイアウトを含みます。
|
||||||
|
|
||||||
|
```
|
||||||
|
layouts/
|
||||||
|
+ default/
|
||||||
|
| + 60_ansi/
|
||||||
|
| | + readme.md
|
||||||
|
| | + layout.json
|
||||||
|
| | + a_good_keymap/
|
||||||
|
| | | + keymap.c
|
||||||
|
| | | + readme.md
|
||||||
|
| | | + config.h
|
||||||
|
| | | + rules.mk
|
||||||
|
| | + <keymap folder>/
|
||||||
|
| | + ...
|
||||||
|
| + <layout folder>/
|
||||||
|
+ community/
|
||||||
|
| + <layout folder>/
|
||||||
|
| + ...
|
||||||
|
```
|
||||||
|
|
||||||
|
`layouts/default/` と `layouts/community/` は、レイアウト「repositories」の2つの例です。現在のところ、`default` にはユーザの参考用に、レイアウトに関する全ての情報および、`default_<layout>` という名前の1つのデフォルトのキーマップが含まれています。`community` には全ての共有キーマップが含まれており、それらはユーザが `layouts/` にクローンするための別のリポジトリに分割することを最終的な目的としていますQMK は `layouts/` 内のすべてのフォルダを検索するため、ここに複数のリポジトリを持つことができます。
|
||||||
|
|
||||||
|
各レイアウトフォルダは、レイアウトの物理的な側面に基づいて、可能な限り一般的な名称で(`[a-z0-9_]`)という名前が付けられ、キーボードで定義されるレイアウトと一緒に `readme.md` を含みます。
|
||||||
|
|
||||||
|
```md
|
||||||
|
# 60_ansi
|
||||||
|
|
||||||
|
LAYOUT_60_ansi
|
||||||
|
```
|
||||||
|
|
||||||
|
新しい名前は既存のレイアウトで設定された標準に準拠しようと努力する必要があり、必要に応じて PR/Issue で議論することができます。
|
||||||
|
|
||||||
|
## レイアウトのサポート
|
||||||
|
|
||||||
|
キーボードがレイアウトをサポートするために、変数は `<keyboard>.h` で定義し、引数/キー (できれば物理レイアウト)の数に一致している必要があります。
|
||||||
|
|
||||||
|
#define LAYOUT_60_ansi KEYMAP_ANSI
|
||||||
|
|
||||||
|
レイアウトの名前は次の正規表現に一致しなければなりません: `[a-z0-9_]+`
|
||||||
|
|
||||||
|
フォルダ名はキーボードの `rules.mk` に追加する必要があります:
|
||||||
|
|
||||||
|
LAYOUTS = 60_ansi
|
||||||
|
|
||||||
|
`LAYOUTS` は任意のキーボードフォルダレべルの `rules.mk` に設定することができます:
|
||||||
|
|
||||||
|
LAYOUTS = 60_iso
|
||||||
|
|
||||||
|
ただし、`LAYOUT_<layout>` 変数は `<folder>.h` でも定義する必要があります。
|
||||||
|
|
||||||
|
## キーマップのビルド
|
||||||
|
|
||||||
|
以下の形式でコマンドを使ってキーボードキーマップを作成できるはずです:
|
||||||
|
|
||||||
|
make <keyboard>:<layout>
|
||||||
|
|
||||||
|
### レイアウトの競合
|
||||||
|
キーボードが複数のレイアウトオプションをサポートし、
|
||||||
|
|
||||||
|
LAYOUTS = ortho_4x4 ortho_4x12
|
||||||
|
|
||||||
|
なおかつ両方のオプションについてレイアウトが存在する場合、
|
||||||
|
```
|
||||||
|
layouts/
|
||||||
|
+ community/
|
||||||
|
| + ortho_4x4/
|
||||||
|
| | + <layout>/
|
||||||
|
| | | + ...
|
||||||
|
| + ortho_4x12/
|
||||||
|
| | + <layout>/
|
||||||
|
| | | + ...
|
||||||
|
| + ...
|
||||||
|
```
|
||||||
|
|
||||||
|
FORCE_LAYOUT 引数はどのレイアウトをビルドするかを指定するために使うことができます
|
||||||
|
|
||||||
|
make <keyboard>:<layout> FORCE_LAYOUT=ortho_4x4
|
||||||
|
make <keyboard>:<layout> FORCE_LAYOUT=ortho_4x12
|
||||||
|
|
||||||
|
## キーボードに依存しないレイアウトを作成するためのヒント
|
||||||
|
|
||||||
|
### インクルード
|
||||||
|
|
||||||
|
`#include "planck.h"` を使う代わりに、以下の行を使ってコンパイルされる `<keyboard>.h` (`<folder>.h` はここでインクルードすべきではありません)ファイルをインクルードすることができます:
|
||||||
|
|
||||||
|
#include QMK_KEYBOARD_H
|
||||||
|
|
||||||
|
キーボード固有のコードを保持したい場合は、これらの変数を使って `#ifdef` 文でエスケープすることができます:
|
||||||
|
|
||||||
|
* `KEYBOARD_<folder1>_<folder2>`
|
||||||
|
|
||||||
|
例えば:
|
||||||
|
|
||||||
|
```c
|
||||||
|
#ifdef KEYBOARD_planck
|
||||||
|
#ifdef KEYBOARD_planck_rev4
|
||||||
|
planck_rev4_function();
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
```
|
||||||
|
|
||||||
|
名前は小文字でキーボード/リビジョンのフォルダ/ファイル名と正確に一致することに注意してください。
|
||||||
|
|
||||||
|
### キーマップ
|
||||||
|
|
||||||
|
同じレイアウトで分割および非分割キーボードをサポートするためには、キーマップでキーボード非依存の `LAYOUT_<layout name>` マクロを使う必要があります。例えば、Let's Split および Planck が同じレイアウトを共有するには、`LAYOUT_planck_grid` や C 配列の場合の単なる `{}` の代わりに、`LAYOUT_ortho_4x12` を使う必要があります。
|
||||||
151
docs/ja/feature_leader_key.md
Normal file
151
docs/ja/feature_leader_key.md
Normal file
@@ -0,0 +1,151 @@
|
|||||||
|
# リーダーキー: 新しい種類のモディファイア
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.134:docs/feature_leader_key.md
|
||||||
|
git diff 0.8.134 HEAD -- docs/feature_leader_key.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
もしあなたが Vim を使ったことがある場合、リーダーキーは何であるかを知っています。そうでなければ、素晴らしい概念を発見しようとしています。:) 例えば、Alt+Shift+W を押す(3つのキーを同時に押す)代わりに、キーの_シーケンス_を押すことができたらどうでしょう?つまり、特別なモディファイア (リーダーキー)を押して、続けて W と C を押すと (単純にキーを高速に繋げます)、何かが起こります。
|
||||||
|
|
||||||
|
それが `KC_LEAD` の機能です。以下は例です:
|
||||||
|
|
||||||
|
1. リーダーキーとして使いたいキーボードのキーを選択します。それにキーコード `KC_LEAD` を割り当てます。このキーはこのためだけの専用です -- 単一アクションのキーで、他の用途には使うことができません。
|
||||||
|
2. `config.h` に `#define LEADER_TIMEOUT 300` という行を追加します。これによって `KC_LEAD` キーのタイムアウトを設定します。具体的には、`KC_LEAD` キーを押してからリーダーキーのシーケンスを完了するまで一定の時間しかありません。ここでの `300` はそれを300msに設定します。この値を増やして、シーケンスを入力する時間を増やすことができます。ただし、この時間中に押されたキーは全て途中で遮られ、送信されません。そのためこの値は小さくしておいたほうが良いかもしれません。
|
||||||
|
* デフォルトでは、このタイムアウトは、`KC_LEAD` を押してからシーケンス全体が完了するまでに掛かる時間です。これは一部の人にとっては非常に短いかもしれません。そのため、このタイムアウトを増やしたほうが良い場合もあります。必要に応じて、`LEADER_PER_KEY_TIMING` オプションを有効にしたほうが良い場合もあります。これは各キーがタップされる度にタイムアウトまでの時間をリセットする機能です。これにより、タイムアウト時間を短くしつつも、比較的長いシーケンスを使うことができます。このオプションを有効にするには、`config.h` に `#define LEADER_PER_KEY_TIMING` を追加します。
|
||||||
|
3. `matrix_scan_user` 関数の中で、以下のようなものを追加します:
|
||||||
|
|
||||||
|
```c
|
||||||
|
LEADER_EXTERNS();
|
||||||
|
|
||||||
|
void matrix_scan_user(void) {
|
||||||
|
LEADER_DICTIONARY() {
|
||||||
|
leading = false;
|
||||||
|
leader_end();
|
||||||
|
|
||||||
|
SEQ_ONE_KEY(KC_F) {
|
||||||
|
// マクロ内でできること
|
||||||
|
SEND_STRING("QMK is awesome.");
|
||||||
|
}
|
||||||
|
SEQ_TWO_KEYS(KC_D, KC_D) {
|
||||||
|
SEND_STRING(SS_LCTL("a") SS_LCTL("c"));
|
||||||
|
}
|
||||||
|
SEQ_THREE_KEYS(KC_D, KC_D, KC_S) {
|
||||||
|
SEND_STRING("https://start.duckduckgo.com\n");
|
||||||
|
}
|
||||||
|
SEQ_TWO_KEYS(KC_A, KC_S) {
|
||||||
|
register_code(KC_LGUI);
|
||||||
|
register_code(KC_S);
|
||||||
|
unregister_code(KC_S);
|
||||||
|
unregister_code(KC_LGUI);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
ご覧のとおり、幾つかの関数があります。`SEQ_ONE_KEY` を単一キーシーケンス (リーダーの後に1つのキーのみ)に使い、より長いシーケンスについては `SEQ_TWO_KEYS`、`SEQ_THREE_KEYS` から `SEQ_FIVE_KEYS` を使うことができます。
|
||||||
|
|
||||||
|
これらはそれぞれ1つ以上のキーコードを引数として受け付けます。これは重要な点です: **キーボードの任意のレイヤー**のキーコードを使うことができます。当たり前ですが、リーダーマクロが発動するにはそのレイヤーがアクティブである必要があります
|
||||||
|
|
||||||
|
## `rules.mk` にリーダーキーサポートを追加
|
||||||
|
|
||||||
|
リーダーキーのサポートを追加するには、単純にキーマップの `rules.mk` に1行を追加します:
|
||||||
|
|
||||||
|
```make
|
||||||
|
LEADER_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
## リーダーキーのキーごとのタイミング
|
||||||
|
|
||||||
|
長いリーダーキー文字列のためや 200wpm のタイピングスキルが無い場合に、非常に長いタイムアウト時間に頼るのではなく、キーを押すごとに入力を完了するまでの時間を増やす機能を使用することができます。これは、リーダーキーを使ってタップダンスを再現する場合に非常に役立ちます (C, C, C のような同じキーを複数回タップする場合)。
|
||||||
|
|
||||||
|
これを有効にするには、以下を `config.h` に配置します:
|
||||||
|
```c
|
||||||
|
#define LEADER_PER_KEY_TIMING
|
||||||
|
```
|
||||||
|
|
||||||
|
この後、`LEADER_TIMEOUT` を 300ms 未満に下げることをお勧めします。
|
||||||
|
|
||||||
|
```c
|
||||||
|
#define LEADER_TIMEOUT 250
|
||||||
|
```
|
||||||
|
|
||||||
|
これで、リーダーキーのタイムアウト時間を 1000ms に設定することなく以下のようなことが可能になると思われます。
|
||||||
|
|
||||||
|
```c
|
||||||
|
SEQ_THREE_KEYS(KC_C, KC_C, KC_C) {
|
||||||
|
SEND_STRING("Per key timing is great!!!");
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## 厳密なキー処理
|
||||||
|
|
||||||
|
デフォルトでは、リーダーキー機能は、リーダーシーケンスの確認時に [`モッドタップ`](ja/mod_tap.md) および [`レイヤータップ`](ja/feature_layers.md#switching-and-toggling-layers) 機能からのキーコードをフィルターします。つまり、`LT(3, KC_A)` を使っている場合、`LT(3, KC_A)` ではなくシーケンスの `KC_A` として取り出され、新しいユーザにとってより期待される動作を提供します。
|
||||||
|
|
||||||
|
ほとんどの場合これで問題ありませんが、シーケンスでキーコード全体(例えば、上の例での `LT(3, KC_A)`) を指定したい場合は、`config.h` ファイルに `#define LEADER_KEY_STRICT_KEY_PROCESSING` を追加することこのような機能を有効にすることができます。これでフィルタリングが無効になり、キーコード全体を指定する必要があります。
|
||||||
|
|
||||||
|
## カスタマイズ
|
||||||
|
|
||||||
|
リーダーキー機能には、リーダーキー機能の動作にいくらかのカスタマイズを追加する方法があります。リーダーキー機能のプロセスの特定の部分で呼び出すことができる2つの関数、`leader_start()` と `leader_end()` です。
|
||||||
|
|
||||||
|
`KC_LEAD` キーがタップされた時に `leader_start()` 関数が呼ばれ、リーダーシーケンスが完了するか、リーダータイムアウトの時間に達した時に `leader_end()` 関数が呼ばれます。
|
||||||
|
|
||||||
|
リーダーシーケンスにフィードバック(ビープまたは音楽を再生するなど)を追加するために、これらの関数をコード (通常 は`keymap.c`)に追加することができます。
|
||||||
|
|
||||||
|
```c
|
||||||
|
void leader_start(void) {
|
||||||
|
// シーケンスの開始
|
||||||
|
}
|
||||||
|
|
||||||
|
void leader_end(void) {
|
||||||
|
// シーケンスの終了 (成功しない/失敗を検知)
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### 例
|
||||||
|
|
||||||
|
この例では、リーダーシーケンスを開始するために `KC_LEAD` を押すとマリオの "One Up" 音が再生され、正常に完了した場合は "All Star" が再生され、失敗した場合は "Rick Roll" を再生されます。
|
||||||
|
|
||||||
|
```c
|
||||||
|
bool did_leader_succeed;
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
float leader_start[][2] = SONG(ONE_UP_SOUND );
|
||||||
|
float leader_succeed[][2] = SONG(ALL_STAR);
|
||||||
|
float leader_fail[][2] = SONG(RICK_ROLL);
|
||||||
|
#endif
|
||||||
|
LEADER_EXTERNS();
|
||||||
|
|
||||||
|
void matrix_scan_user(void) {
|
||||||
|
LEADER_DICTIONARY() {
|
||||||
|
did_leader_succeed = leading = false;
|
||||||
|
|
||||||
|
SEQ_ONE_KEY(KC_E) {
|
||||||
|
// マクロ内でできること
|
||||||
|
SEND_STRING(SS_LCTL(SS_LSFT("t")));
|
||||||
|
did_leader_succeed = true;
|
||||||
|
} else
|
||||||
|
SEQ_TWO_KEYS(KC_E, KC_D) {
|
||||||
|
SEND_STRING(SS_LGUI("r") "cmd\n" SS_LCTL("c"));
|
||||||
|
did_leader_succeed = true;
|
||||||
|
}
|
||||||
|
leader_end();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void leader_start(void) {
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
PLAY_SONG(leader_start);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void leader_end(void) {
|
||||||
|
if (did_leader_succeed) {
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
PLAY_SONG(leader_succeed);
|
||||||
|
#endif
|
||||||
|
} else {
|
||||||
|
#ifdef AUDIO_ENABLE
|
||||||
|
PLAY_SONG(leader_fail);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
95
docs/ja/feature_led_matrix.md
Normal file
95
docs/ja/feature_led_matrix.md
Normal file
@@ -0,0 +1,95 @@
|
|||||||
|
# LED マトリックスライト
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.141:docs/feature_led_matrix.md
|
||||||
|
git diff 0.8.141 HEAD -- docs/feature_led_matrix.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
この機能により、外部ドライバによって駆動される LED マトリックスを使うことができます。この機能は、バックライト制御と同じキーコードを使えるようにするため、バックライトシステムに接続します。
|
||||||
|
|
||||||
|
RGB LED を使いたい場合は、代わりに [RGB マトリックスサブシステム](ja/feature_rgb_matrix.md) を使うべきです。
|
||||||
|
|
||||||
|
## ドライバ設定
|
||||||
|
|
||||||
|
### IS31FL3731
|
||||||
|
|
||||||
|
I2C IS31FL3731 RGB コントローラを使ったアドレス指定可能な LED マトリックスライトのための基本的なサポートがあります:有効にするには、`rules.mk` に以下を追加します:
|
||||||
|
|
||||||
|
LED_MATRIX_ENABLE = IS31FL3731
|
||||||
|
|
||||||
|
1から4個の IS31FL3731 IC を使うことができます。キーボード上に存在しない IC の `LED_DRIVER_ADDR_<N>` 定義を指定しないでください。`config.h` に以下の項目を定義することができます:
|
||||||
|
|
||||||
|
| 変数 | 説明 | デフォルト |
|
||||||
|
|----------|-------------|---------|
|
||||||
|
| `ISSI_TIMEOUT` | (オプション) i2c メッセージを待つ時間 | 100 |
|
||||||
|
| `ISSI_PERSISTENCE` | (オプション) 失敗したメッセージをこの回数再試行する | 0 |
|
||||||
|
| `LED_DRIVER_COUNT` | (必須) LED ドライバ IC の数 | |
|
||||||
|
| `LED_DRIVER_LED_COUNT` | (必須) 全てのドライバの LED ライトの数 | |
|
||||||
|
| `LED_DRIVER_ADDR_1` | (必須) 最初の LED ドライバのアドレス | |
|
||||||
|
| `LED_DRIVER_ADDR_2` | (オプション) 2番目の LED ドライバのアドレス | |
|
||||||
|
| `LED_DRIVER_ADDR_3` | (オプション) 3番目の LED ドライバのアドレス | |
|
||||||
|
| `LED_DRIVER_ADDR_4` | (オプション) 4番目の LED ドライバのアドレス | |
|
||||||
|
|
||||||
|
2つのドライバを使う例です。
|
||||||
|
|
||||||
|
// これは7ビットのアドレスで、左シフトされます
|
||||||
|
// ビット0に0を設定すると書き込み、1を設定すると読み込みです (I2C プロトコルに従う)
|
||||||
|
// アドレスは配線によって変わります:
|
||||||
|
// 0b1110100 AD <-> GND
|
||||||
|
// 0b1110111 AD <-> VCC
|
||||||
|
// 0b1110101 AD <-> SCL
|
||||||
|
// 0b1110110 AD <-> SDA
|
||||||
|
#define LED_DRIVER_ADDR_1 0b1110100
|
||||||
|
#define LED_DRIVER_ADDR_2 0b1110110
|
||||||
|
|
||||||
|
#define LED_DRIVER_COUNT 2
|
||||||
|
#define LED_DRIVER_1_LED_COUNT 25
|
||||||
|
#define LED_DRIVER_2_LED_COUNT 24
|
||||||
|
#define LED_DRIVER_LED_COUNT LED_DRIVER_1_LED_TOTAL + LED_DRIVER_2_LED_TOTAL
|
||||||
|
|
||||||
|
現在、2つのドライバのみがサポートされますが、4つの組み合わせ全てをサポートすることは簡単です。
|
||||||
|
|
||||||
|
`<keyboard>.c` に全ての LED を列挙する配列を定義します:
|
||||||
|
|
||||||
|
const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
|
||||||
|
/* これらの位置については IS31 マニュアルを参照してください
|
||||||
|
* driver
|
||||||
|
* | LED address
|
||||||
|
* | | */
|
||||||
|
{0, C3_3},
|
||||||
|
....
|
||||||
|
}
|
||||||
|
|
||||||
|
ここで、`Cx_y` は[データシート](http://www.issi.com/WW/pdf/31FL3731.pdf)およびヘッダファイル `drivers/issi/is31fl3731-simple.h` で定義されるマトリックス内の LED の位置です。`driver` は `config.h` で定義したドライバのインデックス(`0`、`1`、`2`、`3`のいずれか)です。
|
||||||
|
|
||||||
|
## キーコード
|
||||||
|
|
||||||
|
現在のところ、全ての LED マトリックスのキーコードは[バックライトシステム](ja/feature_backlight.md)と共有されます。
|
||||||
|
|
||||||
|
## LED マトリックス効果
|
||||||
|
|
||||||
|
現在のところ、LED マトリックス効果は作成されていません。
|
||||||
|
|
||||||
|
## カスタムレイヤー効果
|
||||||
|
|
||||||
|
カスタムレイヤー効果は `<keyboard>.c` 内で以下を定義することで行うことができます:
|
||||||
|
|
||||||
|
void led_matrix_indicators_kb(void) {
|
||||||
|
led_matrix_set_index_value(index, value);
|
||||||
|
}
|
||||||
|
|
||||||
|
同様の関数がキーマップ内で `led_matrix_indicators_user` として動作します。
|
||||||
|
|
||||||
|
## サスペンド状態
|
||||||
|
|
||||||
|
サスペンド機能を使うには、以下を `<keyboard>.c` に追加します:
|
||||||
|
|
||||||
|
void suspend_power_down_kb(void)
|
||||||
|
{
|
||||||
|
led_matrix_set_suspend_state(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
void suspend_wakeup_init_kb(void)
|
||||||
|
{
|
||||||
|
led_matrix_set_suspend_state(false);
|
||||||
|
}
|
||||||
49
docs/ja/feature_pointing_device.md
Normal file
49
docs/ja/feature_pointing_device.md
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
# ポインティングデバイス :id=pointing-device
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.182:docs/feature_pointing_device.md
|
||||||
|
git diff 0.8.182 HEAD -- docs/feature_pointing_device.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
ポインティングデバイスは汎用的な機能の総称です: システムポインタを移動します。マウスキーのような他のオプションも確かにありますが、これは簡単に変更可能で軽量であることを目指しています。機能を制御するためにカスタムキーを実装したり、他の周辺機器から情報を収集してここに直接挿入したりできます - QMK に処理を任せてください。
|
||||||
|
|
||||||
|
ポインティングデバイスを有効にするには、rules.mk の以下の行のコメントを解除します:
|
||||||
|
|
||||||
|
```makefile
|
||||||
|
POINTING_DEVICE_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
マウスレポートを操作するために、以下の関数を使うことができます:
|
||||||
|
|
||||||
|
* `pointing_device_get_report()` - ホストコンピュータに送信された情報を表す現在の report_mouse_t を返します。
|
||||||
|
* `pointing_device_set_report(report_mouse_t newMouseReport)` - ホストコンピュータに送信される report_mouse_t を上書き保存します。
|
||||||
|
|
||||||
|
report_mouse_t (ここでは "mouseReport") が以下のプロパティを持つことを覚えておいてください:
|
||||||
|
|
||||||
|
* `mouseReport.x` - これは、x軸の動き(+ 右へ、- 左へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。
|
||||||
|
* `mouseReport.y` - これは、y軸の動き(+ 上へ、- 下へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。
|
||||||
|
* `mouseReport.v` - これは、垂直スクロール(+ 上へ、- 下へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。
|
||||||
|
* `mouseReport.h` - これは、水平スクロール(+ 右へ、- 左へ)を表す -127 から 127 (128ではなく、USB HID 仕様で定義されています)の符号付き整数です。
|
||||||
|
* `mouseReport.buttons` - これは uint8_t で、上位の5ビットを使っています。これらのビットはマウスボタンの状態を表します - ビット 3 はマウスボタン 5、ビット 7 はマウスボタン 1 です。
|
||||||
|
|
||||||
|
マウスレポートが送信されると、x、y、v、h のいずれの値も 0 に設定されます (これは "pointing_device_send()" で行われます。この挙動を回避するためにオーバーライドすることができます)。このように、ボタンの状態は持続しますが、動きは1度だけ起こります。さらにカスタマイズするために、`pointing_device_init` と `pointing_device_task` のどちらもオーバーライドすることができます。
|
||||||
|
|
||||||
|
以下の例では、カスタムキーを使ってマウスをクリックし垂直および水平方向に127単位スクロールし、リリースされた時にそれを全て元に戻します - なぜならこれは完全に便利な機能だからです。いいですか、以下はひとつの例です:
|
||||||
|
|
||||||
|
```c
|
||||||
|
case MS_SPECIAL:
|
||||||
|
report_mouse_t currentReport = pointing_device_get_report();
|
||||||
|
if (record->event.pressed) {
|
||||||
|
currentReport.v = 127;
|
||||||
|
currentReport.h = 127;
|
||||||
|
currentReport.buttons |= MOUSE_BTN1; // this is defined in report.h
|
||||||
|
} else {
|
||||||
|
currentReport.v = -127;
|
||||||
|
currentReport.h = -127;
|
||||||
|
currentReport.buttons &= ~MOUSE_BTN1;
|
||||||
|
}
|
||||||
|
pointing_device_set_report(currentReport);
|
||||||
|
break;
|
||||||
|
```
|
||||||
|
|
||||||
|
マウスレポートは送信されるたびに 0 (ボタンを除く)に設定されることを思い出してください。そのため、スクロールはそれぞれの場合に1度だけ発生します。
|
||||||
15
docs/ja/feature_thermal_printer.md
Normal file
15
docs/ja/feature_thermal_printer.md
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# 感熱式プリンタ
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.147:docs/feature_thermal_printer.md
|
||||||
|
git diff 0.8.147 HEAD -- docs/feature_thermal_printer.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
<!-- FIXME: Describe thermal printers support here. -->
|
||||||
|
|
||||||
|
## 感熱式プリンタのキーコード
|
||||||
|
|
||||||
|
| キー | 説明 |
|
||||||
|
|-----------|----------------------------------------|
|
||||||
|
| `PRINT_ON` | ユーザが入力した全ての印刷を開始 |
|
||||||
|
| `PRINT_OFF` | ユーザが入力した全ての印刷を停止 |
|
||||||
35
docs/ja/feature_velocikey.md
Normal file
35
docs/ja/feature_velocikey.md
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
# Velocikey
|
||||||
|
|
||||||
|
<!---
|
||||||
|
original document: 0.8.147:docs/feature_velocikey.md
|
||||||
|
git diff 0.8.147 HEAD -- docs/feature_velocikey.md | cat
|
||||||
|
-->
|
||||||
|
|
||||||
|
Velocikey は入力の速度を使って(レインボー渦巻効果のような)ライト効果の速度を制御できる機能です。速く入力すればするほどライトが速くなります!
|
||||||
|
|
||||||
|
## 使用法
|
||||||
|
Velocikey を使うためには、2つのステップがあります。最初に、キーボードをコンパイルする時に、`rules.mk` に `VELOCIKEY_ENABLE=yes` を設定する必要があります。例えば:
|
||||||
|
|
||||||
|
```
|
||||||
|
BOOTMAGIC_ENABLE = no
|
||||||
|
MOUSEKEY_ENABLE = no
|
||||||
|
STENO_ENABLE = no
|
||||||
|
EXTRAKEY_ENABLE = yes
|
||||||
|
VELOCIKEY_ENABLE = yes
|
||||||
|
```
|
||||||
|
|
||||||
|
次に、キーボードの使用中に、VLK_TOG キーコードを使って Velocikey を有効にする必要もあります。これは機能をオンおよびオフにします。
|
||||||
|
|
||||||
|
以下の全てのライト効果が、Velocikey を有効にすることで制御されます:
|
||||||
|
- RGB 明滅動作
|
||||||
|
- RGB レインボームード
|
||||||
|
- RGB レインボー渦巻
|
||||||
|
- RGB スネーク
|
||||||
|
- RGB ナイト
|
||||||
|
|
||||||
|
LED 明滅動作の効果のサポートは計画されていますがまだ利用できません。
|
||||||
|
|
||||||
|
Velocikey が有効になっている限り、現在オンになっている RGB ライトの他の全ての速度設定に関係なく、速度が制御されます。
|
||||||
|
|
||||||
|
## 設定
|
||||||
|
Velocikey は現在のところキーボード設定を介したどのような設定もサポートしません。速度の増加あるいは減少率などを調整したい場合は、`velocikey.c` を編集し、そこで値を調整して、好みの速度を実現する必要があります。
|
||||||
@@ -31,7 +31,6 @@ BOOTLOADER = atmel-dfu
|
|||||||
|
|
||||||
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (推奨の GUI)
|
* [QMK Toolbox](https://github.com/qmk/qmk_toolbox/releases) (推奨の GUI)
|
||||||
* QMK の [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` (推奨のコマンドライン)
|
* QMK の [dfu-programmer](https://github.com/dfu-programmer/dfu-programmer) / `:dfu` (推奨のコマンドライン)
|
||||||
* [Atmel の Flip](http://www.microchip.com/developmenttools/productdetails.aspx?partno=flip) (非推奨)
|
|
||||||
|
|
||||||
書き込み手順:
|
書き込み手順:
|
||||||
|
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user