qmk_firmware

QMK firmware for my keyboards (Corne, Sweep Ferris) and trackball (Ploopy Adept)
Log | Files | Refs | Submodules | LICENSE

keymap.c (5907B)


      1 /* vim: noai:ts=4:sw=4:nowrap
      2 */
      3 /*
      4 Copyright 2012 Jun Wako <wakojun@gmail.com> Nikolai Grigoriev @ngrigoriev
      5 
      6 This program is free software: you can redistribute it and/or modify
      7 it under the terms of the GNU General Public License as published by
      8 the Free Software Foundation, either version 2 of the License, or
      9 (at your option) any later version.
     10 
     11 This program is distributed in the hope that it will be useful,
     12 but WITHOUT ANY WARRANTY; without even the implied warranty of
     13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     14 GNU General Public License for more details.
     15 
     16 You should have received a copy of the GNU General Public License
     17 along with this program.  If not, see <http://www.gnu.org/licenses/>.
     18 */
     19 
     20 #include QMK_KEYBOARD_H
     21 
     22 enum layers {
     23     _BASE,
     24     _MAGIC,
     25     _NUMPAD,
     26     _FN
     27 };
     28 
     29 const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
     30     [_BASE] = LAYOUT_5x7_2_6(
     31         KC_GRV,         KC_1,       KC_2,   KC_3,   KC_4,   KC_5,   MO(_MAGIC),                     KC_EQL,     KC_6,   KC_7,   KC_8,       KC_9,   KC_0,       KC_BSPC,
     32         KC_TAB,         KC_Q,       KC_W,   KC_E,   KC_R,   KC_T,   MO(_NUMPAD),                    KC_MINUS,   KC_Y,   KC_U,   KC_I,       KC_O,   KC_P,       KC_BSLS,
     33         KC_LCTL,        KC_A,       KC_S,   KC_D,   KC_F,   KC_G,   _______,                        KC_DEL,     KC_H,   KC_J,   KC_K,       KC_L,   KC_SCLN,    KC_QUOT,
     34         OSM(MOD_LSFT),  KC_Z,       KC_X,   KC_C,   KC_V,   KC_B,                                               KC_N,   KC_M,   KC_COMM,    KC_DOT, KC_SLSH,    OSM(MOD_RSFT),
     35                         KC_PGUP,    KC_PGDN,                                                                                    KC_LBRC,    KC_RBRC,
     36                                                         KC_LCTL,    LT(_FN, KC_ESC),                KC_ENTER,KC_SPC,
     37                                                                         KC_UP,  KC_DOWN,        KC_LEFT,    KC_RIGHT,
     38                                                                         KC_LCMD,    KC_LALT,    KC_RCTL,    KC_RALT
     39     ),
     40 
     41     [_FN] = LAYOUT_5x7_2_6(
     42         _______,    KC_F1,      KC_F2,      KC_F3,      KC_F4,      KC_F5,      MO(_MAGIC),         _______,    KC_F6,      KC_F7,      KC_F8,      KC_F9,      KC_F10,     KC_F11,
     43         _______,    _______,    _______,    KC_UP,      _______,    _______,    _______,            _______,    _______,    _______,    _______,    _______,    _______,    KC_F12,
     44         _______,    _______,    KC_LEFT,    KC_DOWN,    KC_RGHT,    _______,    QK_BOOT,            _______,    KC_LEFT,    KC_DOWN,    KC_UP,      KC_RIGHT,   _______,    _______,
     45         _______,    _______,    _______,    _______,    _______,    _______,                                    _______,    _______,    _______,    _______,    _______,    _______,
     46                     KC_MPRV,    KC_MNXT,                                                                                                _______,    _______,
     47                                                                 _______,    _______,                KC_DEL,     _______,
     48                                                                             _______, _______,   _______, _______,
     49                                                                             _______, _______,   _______, _______
     50     ),
     51 
     52     [_NUMPAD] = LAYOUT_5x7_2_6(
     53         _______,    _______,    _______,    _______,    _______,    _______,    MO(_MAGIC),         _______,    _______,    KC_NUM,     _______,    KC_PMNS,    KC_PPLS,    _______,
     54         _______,    _______,    _______,    _______,    _______,    _______,    _______,            _______,    _______,    KC_P7,      KC_P8,      KC_P9,      _______,    _______,
     55         _______,    _______,    _______,    _______,    _______,    _______,    _______,            _______,    KC_LEFT,    KC_P4,      KC_P5,      KC_P6,      KC_PAST,    _______,
     56         _______,    _______,    _______,    _______,    _______,    _______,                                    _______,    KC_P1,      KC_P2,      KC_P3,      KC_PSLS,    _______,
     57                     _______,    _______,                                                                                                KC_P0,      KC_PDOT,
     58                                                                 _______,    _______,                _______,    KC_PENT,
     59                                                                             _______, _______,   _______, _______,
     60                                                                             _______, _______,   _______, _______
     61     ),
     62 
     63     [_MAGIC] = LAYOUT_5x7_2_6(
     64         _______,    _______,    _______,    _______,    _______,    _______,    _______,            CG_SWAP,    _______,    _______,    _______,    _______,    _______,    QK_REBOOT,
     65         _______,    _______,    _______,    _______,    _______,    _______,    _______,            CG_NORM,    _______,    _______,    _______,    _______,    _______,    _______,
     66         _______,    _______,    _______,    _______,    _______,    _______,    _______,            _______,    _______,    _______,    _______,    _______,    _______,    QK_BOOTLOADER,
     67         _______,    _______,    _______,    _______,    _______,    _______,                                    _______,    _______,    _______,    _______,    _______,    _______,
     68                     _______,    _______,                                                                                                _______,    _______,
     69                                                                 _______,    _______,                _______,    _______,
     70                                                                             _______, _______,   _______, _______,
     71                                                                             _______, _______,   _______, _______
     72     )
     73 };
     74