You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

131 lines
5.4 KiB

[Keymap] Update bcat's keymaps/userspace to share logic, add OLED functionality, and set up one of my macropads for WFH (#14702) * Add script to build all bcat keymaps at once * Move userspace RGB to separate source file * Move layer handling logic into userspace * Move keycap aliases into userspace * Add OLED userspace library and Lily58 OLED setup * Add Luna keyboard pet, generic OLED pet framework Luna artwork and original implementation by HellSingCoder, licensed under GPL v2.0. See also: https://github.com/qmk/qmk_firmware/blob/6dfe915e26d7147e6c2bed495d3b01cf5b21e6ec/keyboards/sofle/keymaps/helltm/keymap.c * Use OLED on bcat's Crkbd I had to turn off a few unused features to address firmware size limits. * Remove vestigial NK_TOGG keybindings * Add post-render hook to OLED pet API This enables OLED pets to draw custom widgets (e.g., LED indicator status) on top of their animation frames. * Add Isda keyboard pet For future use on my Unicorne keyboard. Unicorn artwork by sparrow666, licensed under GPL v2.0. See also: https://opengameart.org/content/unicorn-2 * Replace OLED timeout implementation with custom The default implementation never lets the OLED turn off if a continuous animation is in progress. The custom one does. * Move keyboard state for OLED functions into struct No change in firmware size, but makes keymaps read a little nicer and enables more functionality in OLED pets. * Enable continuously running OLED pet (for Luna) * Sync OLED state; enable Bootmagic only when needed The new extensible split transport for Split Common finally allows OLED on/off status to be synced between halves of the keyboard. :) Unfortunately, this required disabling Bootmagic Lite to keep my Crkbd under the firmware size limit. (I now after 28 bytes free on avr-gcc version 8.5.0.) So now I'll enable Bootmagic only on keyboards that actually require it, i.e., ones lacking an accessible reset button. * Update 9-Key macropad keymap for working from home * Remove includes redundant with quantum.h Co-authored-by: Drashna Jaelre <drashna@live.com> * Simplify BCAT_OLED_PET makefile logic * Swap some keys on my 9-Key macropad around * Inline spurious variable in OLED code * Remove max brightness that's now set by default The default max brightness is only 120 rather than 150, but that might actually fix some weirdness I've seen with bright white LED settings. * Enable specific RGBLIGHT modes instead of default The general trend these days seems to be enabling only the modes you want, so I'm manually expanding the ones currently enabled by RGBLIGHT_ANIMATIONS. I'd like to try out the TWINKLE mode too, but it seems not to work at all on ARM right now, and all my usable RGBLIGHT keebs are ARM boards. * Reenable RGB_MATRIX animations after #15018 My Crkbd still has a reasonable amount of free space with these: 27974/28672 (97%, 698 bytes free). The RGB_MATRIX_KEYPRESSES effects would put it over the firmware size limit, but I really don't ever use those anyway. * Use new get_u8_str function for WPM display Co-authored-by: Drashna Jaelre <drashna@live.com>
2 years ago
  1. # bcat's split 3x6 + 3 thumb keys layout
  2. (See also the
  3. [BlueMicro](https://github.com/jpconstantineau/BlueMicro_BLE/tree/master/firmware/keyboards/crkbd/keymaps/bcat)
  4. and [ZMK](https://github.com/bcat/zmk-config/blob/master/config/corne.keymap)
  5. versions of this keymap.)
  6. This is my favorite split ergo layout for typing, featuring the traditional
  7. four ortho/ergo layers (Default, Lower, Raise, Adjust). It is loosely inspired
  8. by the default Planck (numbers on Lower, symbols on Raise) and Crkbd (Space on
  9. left, Enter on right) layouts, but has since been redesigned heavily according
  10. to the principles described below.
  11. * Since my most-frequently-used keyboard shortcuts involve Ctrl, which lives on
  12. the left half of the keyboard, keys frequently used with it (numbers, function
  13. keys, etc.) are on the Raise layer activated by the right thumb.
  14. * Navigation can be done on the right half alone, to enable simultaneous
  15. left-handed mousing. Additionally, Web pages can be scrolled with Space or
  16. Shift+Space on the left half alone, to enable taking notes with the right hand
  17. at the same time.
  18. * Other than Right Shift (which I seldom use), mods aren't rebound on layers.
  19. * Likewise, Backspace is not rebound on layers to avoid having to let go of
  20. layer-switch keys to correct mistakes.
  21. ## Default layer
  22. ![Default layer layout](https://i.imgur.com/g5N7g8D.png)
  23. ([KLE](http://www.keyboard-layout-editor.com/#/gists/08d9827d916662a9414f48805aa895a5))
  24. * The alpha keys are a standard QWERTY layout, no funny business there.
  25. * Tab and Backspace are in familiar locations from my row-staggered boards
  26. (almost all of which use HHKB-style split backspace).
  27. * The Esc key is next to the home row for convenience in Vim.
  28. * There are two Shift keys, although I generally use Left Shift. (I've
  29. considered replacing Right Shift with another key, but haven't chosen one.)
  30. * Lower and Raise layer-switch keys are in the resting position of my left and
  31. right thumbs, respectively.
  32. * Space and Enter are on the big thumb keys so they're easy to press.
  33. * Ctrl is on the left for ease of chording, especially one-handed use of common
  34. shortcuts like Ctrl+T and Ctrl+W. This puts Alt on the right by the process of
  35. elimination. (I would really like one more 1U thumb key on each half to allow
  36. for a redundant Alt key on the left and a dedicated Super key on the right.)
  37. ## Lower layer
  38. ![Lower layer layout](https://i.imgur.com/vaIc9JY.png)
  39. ([KLE](http://www.keyboard-layout-editor.com/#/gists/c3fba5eaa2cd70fdfbdbc0f9e34d3bc0))
  40. * This could also be called the "symbol layer".
  41. * Shifted numbers are bound in their usual positions on the top row.
  42. * Hyphen/Underscore and Equals/Plus are in the right index- and middle-finger
  43. columns for easy reach. They share the same relative position as on a
  44. row-staggered keyboard, and the shifted versions are physically above the
  45. unshifted versions as a mnemonic device.
  46. * Brackets and braces are placed below the parens for easy recall. Once again,
  47. the shifted versions are on the home row and the unshifted versions are on the
  48. bottom row.
  49. * Forward Slash/Pipe and Backtick/Tilde fill out the remaining positions on the
  50. right half, with the same relative positions as on a row-staggered HHKB layout.
  51. And yup, the shifted versions are above the unshifted versions.
  52. * Remaining keys from a TKL are placed out of the way on the bottom row of the
  53. left half.
  54. * The home row on the left half contains handy shortcuts for zooming and browser
  55. navigation.
  56. * Lower+Esc is bound to Ctrl+Space because the Ctrl and Space keys are both on
  57. the left thumb, so this key combination (which I use for tmux prefix and editor
  58. autocomplete) is hard to press in its natural location.
  59. * Lower+Tab is bound to a custom Alt+Tab macro that keeps the Alt modifier held
  60. as long as the Lower key is held down. This means that window switching is on
  61. Lower+Tab immediately next to browser tab switching (Ctrl+Tab).
  62. ## Raise layer
  63. ![Raise layer layout](https://i.imgur.com/VNEiV9A.png)
  64. ([KLE](http://www.keyboard-layout-editor.com/#/gists/08b44355d4ca85d294bad9e2821f91d7))
  65. * This could also be called the "number layer".
  66. * Unshifted numbers are bound in their usual positions on the top row.
  67. * Arrow keys are on VIM-style HJKL keys.
  68. * Home/End and Page Up/Page Down are in the same column as the arrow keys, but
  69. translated down one row. (This means that the comma and period keys are not
  70. bound on the number layer, which makes data entry a bit funky. I might add a
  71. dedicated numpad layer to compensate.)
  72. * Function keys F1–F10 take up most of remaining space on the left half, with
  73. F11 and F12 spilling over to the right half. (This puts the most used function
  74. keys (F1–F5) on the home row.)
  75. * Insert and Delete are on the rightmost column, because there didn't seem to
  76. be a better place to put them.
  77. * Caps Lock is bound in the same position as on an HHKB, for lack of an obvious
  78. better location.
  79. ## Adjust layer
  80. ![Adjust layer layout](https://i.imgur.com/Q4rN6cQ.png)
  81. ([KLE](http://www.keyboard-layout-editor.com/#/gists/77e7572e077b36a23eb2086017e16fee))
  82. * Media keys are centered around the ESDF cluster, just like I arrange them on
  83. row-staggered keyboards. (It's even more sensible with columnar stagger.)
  84. * The navigation keys are replaced by RGB controls. Again, this mirrors the
  85. positioning I use on my row-staggered keyboards.
  86. * Finally, reset keys live at the top-left corner of the right half where it's
  87. reasonably hard to press them by accident.