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.

142 lines
5.4 KiB

[Keymap] Drashna's Feature madness (#6128) * Fix my Tap Dance issues after I broke them * Cleanup and organization of userspace documentation As well as some additional cleanup of functions due to review of documentation. * Enable Tapdance on Glow and remove more animations * Revert to Eager PR debouncing * Add better check for startup animation * Move where RGB Matrix defines are listed * Limit RGB Matrix max val * Update keyboard for Iris Rev 3 conflicts * Enable encoder support on planck ez * Remove is_master check from corne\'s OLED code * Overhaul OLED screens for my Corne * One last removal * Show RGB valu On both sides * Updates for OLED display info * Fix compile issues for rgb config * Disabled Space Cadet for all drashna keymaps * Fix OLED Screen configs * Minor OLED Tweaks * Revert some Iris changes * Fix song include * Handle MAKE macro for the Corne boards better * Add super hacky-hack for eeconfig initialization * Add audio support for Fractal since Elite Cs support it * Add defines for keycode steps * Add White layout * Update Corne RGB info * Add fun effects to layer indication for RGB Matrix enabled boards * Use proper define for product name detection * Update formatting * Use custom timeout mechanism for OLED timeout * Fix up OLED screen HSV code for new HSV structure * Better handle turning off RGB Matrix when sleeping * Disable MultiSplash Animation * Change Iris back to using serial * Why was RGB disabled?!?!?! * Limit val in rgb_matrix_layer_helper function * Remove EECONFIG setting for RGB matrix
4 years ago
[Keymap] Drashna's Feature madness (#6128) * Fix my Tap Dance issues after I broke them * Cleanup and organization of userspace documentation As well as some additional cleanup of functions due to review of documentation. * Enable Tapdance on Glow and remove more animations * Revert to Eager PR debouncing * Add better check for startup animation * Move where RGB Matrix defines are listed * Limit RGB Matrix max val * Update keyboard for Iris Rev 3 conflicts * Enable encoder support on planck ez * Remove is_master check from corne\'s OLED code * Overhaul OLED screens for my Corne * One last removal * Show RGB valu On both sides * Updates for OLED display info * Fix compile issues for rgb config * Disabled Space Cadet for all drashna keymaps * Fix OLED Screen configs * Minor OLED Tweaks * Revert some Iris changes * Fix song include * Handle MAKE macro for the Corne boards better * Add super hacky-hack for eeconfig initialization * Add audio support for Fractal since Elite Cs support it * Add defines for keycode steps * Add White layout * Update Corne RGB info * Add fun effects to layer indication for RGB Matrix enabled boards * Use proper define for product name detection * Update formatting * Use custom timeout mechanism for OLED timeout * Fix up OLED screen HSV code for new HSV structure * Better handle turning off RGB Matrix when sleeping * Disable MultiSplash Animation * Change Iris back to using serial * Why was RGB disabled?!?!?! * Limit val in rgb_matrix_layer_helper function * Remove EECONFIG setting for RGB matrix
4 years ago
  1. /* Copyright 2020 Christopher Courtney, aka Drashna Jael're (@drashna) <drashna@live.com>
  2. *
  3. * This program is free software: you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation, either version 2 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. */
  16. #pragma once
  17. #include "drashna.h"
  18. #if defined(KEYBOARD_handwired_tractyl_manuform)
  19. # define PLACEHOLDER_SAFE_RANGE KEYMAP_SAFE_RANGE
  20. #else
  21. # define PLACEHOLDER_SAFE_RANGE SAFE_RANGE
  22. #endif
  23. enum userspace_custom_keycodes {
  24. VRSN = PLACEHOLDER_SAFE_RANGE, // Prints QMK Firmware and board info
  25. KC_QWERTY, // Sets default layer to QWERTY
  26. FIRST_DEFAULT_LAYER_KEYCODE = KC_QWERTY, // Sets default layer to QWERTY
  27. KC_COLEMAK_DH, // Sets default layer to COLEMAK
  28. KC_COLEMAK, // Sets default layer to COLEMAK
  29. KC_DVORAK, // Sets default layer to DVORAK
  30. LAST_DEFAULT_LAYER_KEYCODE = KC_DVORAK, // Sets default layer to WORKMAN
  31. KC_DIABLO_CLEAR, // Clears all Diablo Timers
  32. KC_MAKE, // Run keyboard's customized make command
  33. KC_RGB_T, // Toggles RGB Layer Indication mode
  34. RGB_IDL, // RGB Idling animations
  35. KC_SECRET_1, // test1
  36. KC_SECRET_2, // test2
  37. KC_SECRET_3, // test3
  38. KC_SECRET_4, // test4
  39. KC_SECRET_5, // test5
  40. KC_CCCV, // Hold to copy, tap to paste
  41. KC_NUKE, // NUCLEAR LAUNCH DETECTED!!!
  42. UC_FLIP, // (ಠ痊ಠ)┻━┻
  43. UC_TABL, // ┬─┬ノ( º _ ºノ)
  44. UC_SHRG, // ¯\_(ツ)_/¯
  45. UC_DISA, // ಠ_ಠ
  46. UC_IRNY,
  47. UC_CLUE,
  48. KEYLOCK, // Locks keyboard by unmounting driver
  49. KC_NOMODE,
  50. KC_WIDE,
  51. KC_SCRIPT,
  52. KC_BLOCKS,
  53. KC_REGIONAL,
  54. KC_AUSSIE,
  55. KC_ZALGO,
  56. KC_ACCEL,
  57. AUTO_CTN, // Toggle Autocorrect status
  58. NEW_SAFE_RANGE // use "NEWPLACEHOLDER for keymap specific codes
  59. };
  60. bool process_record_secrets(uint16_t keycode, keyrecord_t *record);
  61. bool process_record_keymap(uint16_t keycode, keyrecord_t *record);
  62. void post_process_record_keymap(uint16_t keycode, keyrecord_t *record);
  63. #ifdef CUSTOM_UNICODE_ENABLE
  64. bool process_record_unicode(uint16_t keycode, keyrecord_t *record);
  65. void matrix_init_unicode(void);
  66. #endif
  67. #define LOWER MO(_LOWER)
  68. #define RAISE MO(_RAISE)
  69. #define ADJUST MO(_ADJUST)
  70. #define TG_MODS OS_TOGG
  71. #define TG_GAME TG(_GAMEPAD)
  72. #define TG_DBLO TG(_DIABLO)
  73. #define OS_LWR OSL(_LOWER)
  74. #define OS_RSE OSL(_RAISE)
  75. #define KC_SEC1 KC_SECRET_1
  76. #define KC_SEC2 KC_SECRET_2
  77. #define KC_SEC3 KC_SECRET_3
  78. #define KC_SEC4 KC_SECRET_4
  79. #define KC_SEC5 KC_SECRET_5
  80. #define QWERTY KC_QWERTY
  81. #define DVORAK KC_DVORAK
  82. #define COLEMAK KC_COLEMAK
  83. #define COLEMAKDH KC_COLEMAK_DH
  84. #define DEFLYR1 FIRST_DEFAULT_LAYER_KEYCODE
  85. #define DEFLYR2 (FIRST_DEFAULT_LAYER_KEYCODE + 1)
  86. #define DEFLYR3 (FIRST_DEFAULT_LAYER_KEYCODE + 2)
  87. #define DEFLYR4 (FIRST_DEFAULT_LAYER_KEYCODE + 3)
  88. #if LAST_DEFAULT_LAYER_KEYCODE > (FIRST_DEFAULT_LAYER_KEYCODE + 3)
  89. # define DEFLYR5 (FIRST_DEFAULT_LAYER_KEYCODE + 4)
  90. # define DEFLYR6 (FIRST_DEFAULT_LAYER_KEYCODE + 5)
  91. # define DEFLYR7 (FIRST_DEFAULT_LAYER_KEYCODE + 6)
  92. # define DEFLYR8 (FIRST_DEFAULT_LAYER_KEYCODE + 7)
  93. # if LAST_DEFAULT_LAYER_KEYCODE > (FIRST_DEFAULT_LAYER_KEYCODE + 7)
  94. # define DEFLYR9 (FIRST_DEFAULT_LAYER_KEYCODE + 8)
  95. # define DEFLYR10 (FIRST_DEFAULT_LAYER_KEYCODE + 9)
  96. # define DEFLYR11 (FIRST_DEFAULT_LAYER_KEYCODE + 10)
  97. # define DEFLYR12 (FIRST_DEFAULT_LAYER_KEYCODE + 11)
  98. # endif
  99. #endif
  100. #define KC_RESET RESET
  101. #define KC_RST KC_RESET
  102. #ifdef SWAP_HANDS_ENABLE
  103. # define KC_C1R3 SH_T(KC_TAB)
  104. #elif defined(DRASHNA_LP)
  105. # define KC_C1R3 TG(_GAMEPAD)
  106. #else // SWAP_HANDS_ENABLE
  107. # define KC_C1R3 KC_TAB
  108. #endif // SWAP_HANDS_ENABLE
  109. #define BK_LWER LT(_LOWER, KC_BSPC)
  110. #define SP_LWER LT(_LOWER, KC_SPC)
  111. #define DL_RAIS LT(_RAISE, KC_DEL)
  112. #define ET_RAIS LT(_RAISE, KC_ENTER)
  113. /* OSM keycodes, to keep things clean and easy to change */
  114. #define KC_MLSF OSM(MOD_LSFT)
  115. #define KC_MRSF OSM(MOD_RSFT)
  116. #define OS_LGUI OSM(MOD_LGUI)
  117. #define OS_RGUI OSM(MOD_RGUI)
  118. #define OS_LSFT OSM(MOD_LSFT)
  119. #define OS_RSFT OSM(MOD_RSFT)
  120. #define OS_LCTL OSM(MOD_LCTL)
  121. #define OS_RCTL OSM(MOD_RCTL)
  122. #define OS_LALT OSM(MOD_LALT)
  123. #define OS_RALT OSM(MOD_RALT)
  124. #define OS_MEH OSM(MOD_MEH)
  125. #define OS_HYPR OSM(MOD_HYPR)
  126. #define ALT_APP ALT_T(KC_APP)
  127. #define MG_NKRO MAGIC_TOGGLE_NKRO