Commit Graph

712 Commits

Author SHA1 Message Date
Josh Klar
f5dae5f249
Merge pull request #35 from KMKfw/topic-purge-ampy
Load KMK from frozen modules on STM32 (no more ampy-flashed entrypoints)
2018-10-02 01:49:04 -07:00
Josh Klar
1ed2be66e6
Load KMK from frozen modules on STM32 (no more ampy-flashed entrypoints) 2018-10-01 22:14:55 -07:00
Josh Klar
d8adeea180
Merge pull request #34 from KMKfw/topic-super-quick-hotfix
Return state by default on Macro if not a key up or key down event
2018-10-01 22:14:46 -07:00
Josh Klar
fbefed283b
Return state by default on Macro if not a key up or key down event 2018-10-01 21:54:01 -07:00
Josh Klar
5fe54f6ca3
Merge pull request #33 from KMKfw/topic-macros-have-codes
Handle macros more consistently
2018-10-01 12:02:56 -07:00
Josh Klar
552e848a27
Handle macros more consistently: make them a proper internal keycode-style object and not a weird one-off. Fixes sanity_checker on my keymaps. 2018-10-01 11:54:43 -07:00
Josh Klar
27d1ee8755
Merge pull request #32 from KMKfw/topic-perf-grind
Grind out as much performance as possible with lower-ish hanging fruit
2018-10-01 10:34:55 -07:00
Josh Klar
f80873fdd0
Roll back the tuple indexing change (now access by dot notation), optimize GESC and fix a bug in how it interacts with the reducer 2018-10-01 01:07:57 -07:00
Josh Klar
b5457534bf
Completely overhaul the entire MatrixScanner and KEY_UP/DOWN_EVENT system for efficiency. Less delay() on HID sends. Speed is only BARELY slower than QMK now. 2018-10-01 00:33:59 -07:00
Josh Klar
784f8885bd
Remove a ton of dict lookups for minor perf gains 2018-10-01 00:33:58 -07:00
Josh Klar
a089675aa8
Merge pull request #31 from KMKfw/topic-macros-part-one
Macros: Support basic sequences of keys (either raw or specified by a string) and cross-platform Unicode sequences (ex. (ノಠ痊ಠ)ノ彡┻━┻)
2018-10-01 00:33:44 -07:00
Josh Klar
fde9b7e274
Add support for millisecond delays within a macro sequence 2018-09-30 21:34:16 -07:00
Josh Klar
2c05efa805
Support a massively-enhanced SEND_STRING equivalent 2018-09-30 21:14:30 -07:00
Josh Klar
96b5c4ee03
Ensure we always send at least four characters when sending Unicode sequences to better support MacOS/Windows 2018-09-30 20:49:40 -07:00
Josh Klar
0ccd27703d
Support Unicode sequences on Windows through WinCompose ONLY 2018-09-30 20:35:41 -07:00
Josh Klar
137de41743
Fix the sanity checker to use RawKeycodes where needed 2018-09-30 20:24:32 -07:00
Josh Klar
692d95018f
Enable switching Unicode modes at runtime; lots of Keycode cleanup again 2018-09-30 20:21:42 -07:00
Josh Klar
ffa81bcf43
Massive refactor largely to support Unicode on Mac
This does a bunch of crazy stuff:

- The ability to set a unicode mode (right now only Linux+ibus or
MacOS-RALT) in the keymap. This will be changeable at runtime soon, to
allow a single keyboard to be able to send table flips and whatever
other crazy stuff on any OS the board is plugged into (something that's
not currently doable on QMK, so yay us?)

- As part of the above, there is now just one user-facing macro for
unicode codepoint submission,
`kmk.common.macros.unicode.unicode_sequence`. Users should never use the
platform-specific macros, partly because they just outright won't work.
There's all sorts of fun stuff in these methods now, thank goodness
MicroPython supports the `yield from` construct.

- Keycode (these should really be renamed Keysym or something) objects
that are intended to not be pressed, or not be released. Right now these
properties are completely ignored if not part of a macro, and it's
probably sane to keep it that way. This was necessary to support MacOS's
"hold RALT while typing the codepoint characters" flow.

- Other refactor-y bits, like moving macro support to `kmk/common`
rather than sitting at the top level of the tree. One day `kmk/common`
may make sense to surface at top level `kmk/`, but that's a discussion
for another day.
2018-09-30 19:33:23 -07:00
Josh Klar
2024eb959f
Support the real reason we're all here: unicode key sequences (Linux only). Basically takes the same output style as klardotsh/qmk_emote_macro_generator outputs 2018-09-30 18:20:18 -07:00
Josh Klar
bdd4f86472
Support a simple macro of a sequence of keycodes (basis for SEND_STRING) 2018-09-30 18:03:43 -07:00
Josh Klar
99573de217
Epic keycode cleanup; make modifiers callable and chainable 2018-09-30 17:58:36 -07:00
Josh Klar
85cdf03572
Merge pull request #30 from KMKfw/topic-consumer-device
HID: Support Consumer (media) keys
2018-09-30 16:37:58 -07:00
Josh Klar
1fcff6cb8c
Stub pyb.hid_keyboard for tests 2018-09-30 16:33:03 -07:00
Josh Klar
b7b1866ac9
HID: Support Consumer (media) keys
What a short title for such a massive diff.

This (heavily squashed) commit adds support for Consumer keys such as
volume keys, media play/pause/stop, etc. by exposing four HID devices
over a single USB lane (as opposed to just exposing a keyboard). This
heavily refactors how HIDHelper works due to the new reporting
structure.

Many of the media keys were changed (mostly Keycodes.Media section), but
many (especially anything regarding Application keys) haven't been
touched yet - thus many keycodes may still be wrong. Probably worth
updating those soon, but I didn't get around to it yet. The definitive
list I refered to was
http://www.freebsddiary.org/APC/usb_hid_usages.php, which is basically
copy-pasta from the official USB HID spec at
https://www.usb.org/sites/default/files/documents/hut1_12v2.pdf
(warning: massive PDF, not light reading).

The only known regression this introduces is that instead of 6KRO as the
USB spec usually supports, we can now only have 5KRO (maybe even 4KRO),
for reasons I have yet to fully debug - this seems to be related to the
report having to include the device descriptor _and_ not supporting a
full 8 bytes as it used to. For now I'm willing to accept this, but it
definitely will be great to squash that bug.

This adds descriptor support for MOUSE and SYSCONTROL devices, as of yet
unimplemented.
2018-09-30 16:08:08 -07:00
Josh Klar
a1bfaac691
Merge pull request #28 from KMKfw/topic-grave-escape
Topic grave escape
2018-09-29 16:29:48 -07:00
Josh Klar
ae521d1b38
Add udev rule to allow flashing STM32 devices as user 2018-09-29 16:20:43 -07:00
Kyle Brown
5de46e33bc
KC_GESC: Escape key that can also work as Grave/Tilde 2018-09-29 16:20:21 -07:00
Kyle Brown
b3469d9fb2 Most changes requested were done, and other general improvements. 2018-09-28 20:20:10 -07:00
Kyle Brown
14233b77d3 Added circuitpython support to utils 2018-09-28 20:20:10 -07:00
Kyle Brown
97f70d7a13 Clean up pyboard and add 2 utilities 2018-09-28 20:20:10 -07:00
Kyle Brown
ed5d542ab4 Update keymap 2018-09-25 12:40:49 -07:00
Kyle Brown
09096abe35 Mostly working. Can even game on it 2018-09-25 12:40:49 -07:00
Kyle Brown
b8a27b9605 Set better keycode values for KC_NO and KC_TRANSPARENT which is an alias to KC_TRNS 2018-09-24 18:01:03 -07:00
Josh Klar
dd69ca5422
Merge pull request #24 from KMKfw/topic-shifted-keycodes
Support ShiftedKeys, though the CODE_ stuff is odd
2018-09-23 05:40:30 -07:00
Josh Klar
ef921a5b99
Support ShiftedKeys, though the CODE_ stuff is odd 2018-09-23 05:19:57 -07:00
Josh Klar
84b7b42b0f
Merge pull request #23 from KMKfw/topic-fix-makefile
Remove useless crap from Makefile
2018-09-23 04:55:15 -07:00
Josh Klar
c39c91af12
Remove useless crap from Makefile 2018-09-23 04:51:27 -07:00
Josh Klar
d377f26bca
Merge pull request #22 from KMKfw/topic-declarative-keymaps
Make user keymaps fully declarative
2018-09-23 03:32:39 -07:00
Josh Klar
7aaaad5eef
Remove unused keymap, unbreak Kyle layout I think 2018-09-23 03:23:42 -07:00
Josh Klar
c90d75321a
Finish renaming targets in circle 2018-09-23 03:16:53 -07:00
Josh Klar
32dd2cecc4
Run the keymap tester on board builds usually 2018-09-23 03:12:31 -07:00
Josh Klar
94130740c4
Write a basic keymap sanity checker utility 2018-09-23 03:03:49 -07:00
Josh Klar
3f83e6a85b
Remove the auto-build 2018-09-23 03:03:48 -07:00
Josh Klar
91c6a2128e
Build the Unix port of MicroPython so we can sanity-check layouts using the actual target Python, rather than CPython with all its niceties 2018-09-23 03:03:48 -07:00
Josh Klar
97091ff4fd
Make user keymaps fully declarative
This removes the need for the user to define... most things, honestly.
Notably, `main()` is no longer the end user's responsibility. This also
allows us to do fun stuff going forward like validating keymaps for
sanity (ex: the key assigned to `KC_MO(x)` should be assigned to
`KC_TRNS` on the target layer or the user will never be able to escape
that layer).

This also disambiguates `BOARD` to always refer to an actual slab of
silicon, renaming to `USER_KEYMAP`.

Entrypoints are now a bit more wild, and mostly-unsupported boards no
longer have working entrypoints. It's probably just time to scrap those
boards for now (until we have BLE HID and/or bitbang USB HID, at least).
2018-09-23 03:03:47 -07:00
Josh Klar
5f9f3be966
Merge pull request #21 from KMKfw/topic-internal-keycodes
Internal Keycodes and partial layer support (MO, DF, TO, TG)
2018-09-23 03:03:26 -07:00
Josh Klar
6977ae94b4
Finish unbreaking my own layout... 2018-09-23 01:06:04 -07:00
Josh Klar
666f36d41a
Unbreak my own layout 2018-09-23 01:04:10 -07:00
Josh Klar
5cdd678073
We do not support the NRF52832 anyway, stop building it in Circle 2018-09-23 00:22:59 -07:00
Josh Klar
634e6f14e6
Support TO and TG layer switching 2018-09-23 00:14:30 -07:00