keymap.c 3.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /* Copyright 2021 duckyb
  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. #include QMK_KEYBOARD_H
  17. // Defines names for use in layer keycodes and the keymap
  18. enum layer_names {
  19. _BASE,
  20. _ARROW,
  21. _FN
  22. };
  23. const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
  24. /* Base Layer
  25. * ,-------------------------------------.
  26. * | | Esc | 1| 2| 3| 4| 5| 6|
  27. * | |-------+---+---+---+---+---+---|
  28. * | | Tab | Q| W| E| R| T| 7|
  29. * |----||-------+---+---+---+---+---+---|
  30. * | F13|| Enter | A| S| D| F| G| 8|
  31. * |----||-------+---+---+---+---+---+---|
  32. * | F14|| Shift | Z| X| C| V| B| 9|
  33. * |----||-------------------------------|
  34. * | F15|| LCtrl | _FN |Alt| Space | 0|
  35. * `----'`-------------------------------'
  36. */
  37. [_BASE] = LAYOUT(
  38. KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6,
  39. KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_7,
  40. KC_F13, KC_ENT, KC_A, KC_S, KC_D, KC_F, KC_G, KC_8,
  41. KC_F14, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_9,
  42. KC_F15, KC_LCTL, OSL(_FN), KC_LALT, KC_SPC, LT(_ARROW, KC_0)
  43. ),
  44. /* Arrows Layer
  45. * ,--------------------------------------------------.
  46. * | | | | | | | | |
  47. * | |-------+----+----+-----+----+-------+-------|
  48. * | | | | UP| |RGB?| HUE+ | HUE- |
  49. * |----||-------+----+----+-----+----+-------+-------|
  50. * | || |LEFT|DOWN|RIGHT| |BRIGHT+|BRIGHT-|
  51. * |----||-------+----+----+-----+----+-------+-------|
  52. * | || | | | | | MODE+ | MODE- |
  53. * |----||--------------------------------------------|
  54. * | RST|| | | | | |
  55. * `----'`--------------------------------------------'
  56. */
  57. [_ARROW] = LAYOUT(
  58. _______, _______, _______, _______, _______, _______, _______,
  59. _______, _______, KC_UP, _______, RGB_TOG, RGB_HUI, RGB_HUD,
  60. _______, _______, KC_LEFT, KC_DOWN, KC_RIGHT, _______, RGB_VAI, RGB_VAD,
  61. _______, _______, _______, _______, _______, _______, RGB_MOD, RGB_RMOD,
  62. QK_BOOT, _______, _______, _______, _______, _______
  63. ),
  64. /* Function Layer
  65. * ,-------------------------------------.
  66. * | | | F1| F2| F3| F4| F5| F6|
  67. * | |-------+---+---+---+---+---+---|
  68. * | | | P| O| I| U| Y| F7|
  69. * |----||-------+---+---+---+---+---+---|
  70. * | || Bspc | ;| L| K| J| H| F8|
  71. * |----||-------+---+---+---+---+---+---|
  72. * | || |Gui| M| N|F12|F11| F9|
  73. * |----||-------------------------------|
  74. * | || | | | |F10|
  75. * `----'`-------------------------------'
  76. */
  77. [_FN] = LAYOUT(
  78. _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6,
  79. _______, KC_P, KC_O, KC_I, KC_U, KC_Y, KC_F7,
  80. _______, KC_BSPC, KC_SCLN, KC_L, KC_K, KC_J, KC_H, KC_F8,
  81. _______, _______, KC_LGUI, KC_M, KC_N, KC_F12, KC_F11, KC_F9,
  82. _______, _______, _______, _______, _______, KC_F10
  83. )
  84. };