]> git.donarmstrong.com Git - qmk_firmware.git/blob - keyboards/orthodox/keymaps/drashna/keymap.c
67f732c12779e67cda805fa3c9dc75fac30bb1db
[qmk_firmware.git] / keyboards / orthodox / keymaps / drashna / keymap.c
1 /*
2 This is the keymap for the keyboard
3
4 Copyright 2012 Jun Wako <wakojun@gmail.com>
5 Copyright 2015 Jack Humbert
6 Copyright 2017 Art Ortenburger
7
8 This program is free software: you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation, either version 2 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program.  If not, see <http://www.gnu.org/licenses/>.
20 */
21
22 #include QMK_KEYBOARD_H
23 #include "drashna.h"
24
25 #ifdef INDICATOR_LIGHTS
26 extern userspace_config_t userspace_config;
27
28 uint8_t last_mod;
29 uint8_t last_led;
30 uint8_t last_osm;
31 #endif
32
33 // Each layer gets a name for readability, which is then used in the keymap matrix below.
34 // The underscores don't mean anything - you can have a layer called STUFF or any other name.
35 // Layer names don't all need to be of the same length, obviously, and you can also skip them
36 // entirely and just use numbers.
37
38 // Fillers to make layering more clear
39 #define _______ KC_TRNS
40 #define XXXXXXX KC_NO
41
42
43
44 const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
45
46 [_QWERTY] = LAYOUT_wrapper(\
47   KC_ESC,  _________________QWERTY_L1_________________,                                                               _________________QWERTY_R1_________________, KC_BSPC,
48   KC_TAB,  _________________QWERTY_L2_________________,          ___________ORTHODOX_THUMP_TOP_____________,          _________________QWERTY_R2_________________, KC_QUOT,
49   KC_MLSF, _________________QWERTY_L3_________________, ___________________ORTHODOX_THUMB_BOTTOM____________________, _________________QWERTY_R3_________________, KC_MRSF
50 ),
51
52 [_COLEMAK] = LAYOUT_wrapper(\
53   KC_ESC,  _________________COLEMAK_L1________________,                                                               _________________COLEMAK_R1________________, KC_BSPC,
54   KC_TAB,  _________________COLEMAK_L2________________,          ___________ORTHODOX_THUMP_TOP_____________,          _________________COLEMAK_R2________________, KC_QUOT,
55   KC_MLSF, _________________COLEMAK_L3________________, ___________________ORTHODOX_THUMB_BOTTOM____________________, _________________COLEMAK_R3________________, KC_MRSF
56 ),
57
58 [_DVORAK] = LAYOUT_wrapper(\
59   KC_ESC,  _________________DVORAK_L1_________________,                                                               _________________DVORAK_R1_________________, KC_BSPC,
60   KC_TAB,  _________________DVORAK_L2_________________,          ___________ORTHODOX_THUMP_TOP_____________,          _________________DVORAK_R2_________________, KC_MINS,
61   KC_MLSF, _________________DVORAK_L3_________________, ___________________ORTHODOX_THUMB_BOTTOM____________________, _________________DVORAK_R3_________________, KC_MRSF
62 ),
63 [_WORKMAN] = LAYOUT_wrapper(\
64   KC_ESC,  _________________WORKMAN_L1________________,                                                               _________________WORKMAN_R1________________, KC_BSPC,
65   KC_TAB,  _________________WORKMAN_L2________________,          ___________ORTHODOX_THUMP_TOP_____________,          _________________WORKMAN_R2________________, KC_MINS,
66   KC_MLSF, _________________WORKMAN_L3________________, ___________________ORTHODOX_THUMB_BOTTOM____________________, _________________WORKMAN_R3________________, KC_MRSF
67 ),
68 [_MODS] = LAYOUT_wrapper(\
69   _______, _______, _______, _______, _______, _______,                                                               _______, _______, _______, _______, _______, _______,
70   _______, _______, _______, _______, _______, _______,          _______, _______,         _______, _______,          _______, _______, _______, _______, _______, _______,
71   KC_LSFT, _______, _______, _______, _______, _______, _______, _______, _______,         _______, _______, _______, _______, _______, _______, _______, _______, _______
72 ),
73
74 [_LOWER] = LAYOUT_wrapper(\
75   KC_TILD, _________________LOWER_L1__________________,                                                               _________________LOWER_R1__________________, KC_BSPC,
76   KC_F11,  _________________LOWER_L2__________________,          _______, _______,         _______, _______,          _________________LOWER_R2__________________, KC_PIPE,
77   KC_F12,  _________________LOWER_L3__________________, _______, _______, _______,         _______, _______, _______, _________________LOWER_R3__________________, _______
78 ),
79
80 [_RAISE] = LAYOUT_wrapper(\
81   KC_GRV,  _________________RAISE_L1__________________,                                                               _________________RAISE_R1__________________, KC_BSPC,
82   _______, _________________RAISE_L2__________________,          _______, _______,         _______, _______,          _________________RAISE_R2__________________, KC_BSLS,
83   _______, _________________RAISE_L3__________________, _______, _______, _______,         _______, _______, _______, _________________RAISE_R3__________________, _______
84 ),
85
86 [_ADJUST] = LAYOUT_wrapper(\
87   KC_MAKE, _________________ADJUST_L1_________________,                                                               _________________ADJUST_R1_________________, KC_RESET,
88   VRSN,    _________________ADJUST_L2_________________,          _______, _______,         _______, KC_NUKE,          _________________ADJUST_R2_________________, EPRM,
89   TG_MODS, _________________ADJUST_L3_________________, _______, _______, _______,         _______, _______, _______, _________________ADJUST_R3_________________, KC_MPLY
90 )
91 };
92
93 void matrix_init_keymap(void) {
94   DDRD &= ~(1<<5);
95   PORTD &= ~(1<<5);
96
97   DDRB &= ~(1<<0);
98   PORTB &= ~(1<<0);
99 }