Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- Copyright 2012,2013 Jun Wako <wakojun@gmail.com>
- This program is free software: you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation, either version 2 of the License, or
- (at your option) any later version.
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
- You should have received a copy of the GNU General Public License
- along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
- #ifndef KEYMAP_COMMON_H
- #define KEYMAP_COMMON_H
- #include <stdint.h>
- #include <stdbool.h>
- #include "keycode.h"
- #include "action.h"
- #include "action_macro.h"
- #include "report.h"
- #include "host.h"
- #include "print.h"
- #include "debug.h"
- #include "keymap.h"
- extern const uint8_t keymaps[][MATRIX_ROWS][MATRIX_COLS];
- extern const uint16_t fn_actions[];
- /* GH60 keymap definition macro
- * K2C, K31 and K3C are extra keys for ISO
- */
- #define KEYMAP( \
- KFA,KFB,KFC,KFD,KFE,KFF, \
- KEA,KEB,KEC,KED,KEE,KEF, \
- KDA,KDB,KDC,KDD,KDE,KDF, \
- KCA,KCB,KCC,KCD,KCE,KCF, \
- KBA,KBB,KBC,KBD,KBE,KBF, \
- KAA,KAB,KAC,KAD,KAE,KAF, \
- K9A, K9B, K9C, K9D, K9E, K9F, \
- K8A, K8B, K8C, K8D, K8E, K8F, \
- K7A, K7B, K7C, K7D, K7E, K7F, \
- K6A, K6B, K6C, K6D, K6E, K6F, \
- K5A, K5B, K5C, K5D, K5E, K5F, \
- K4A, K4B, K4C, K4D, K4E, K4F, \
- K3A, K3B, K3C, K3D, K3E, K3F, \
- K2A, K2B, K2C, K2D, K2E, K2F, \
- K1A, K1B, K1C, K1D, K1E, K1F, \
- K0A, K0B, K0C, K0D, K0E, K0F \
- ) { \
- { KC_##KFA, KC_##KFB, KC_##KFC, KC_##KFD, KC_##KFE, KC_##KFF}, \
- { KC_##KEA, KC_##KEB, KC_##KEC, KC_##KED, KC_##KEE, KC_##KEF}, \
- { KC_##KDA, KC_##KDB, KC_##KDC, KC_##KDD, KC_##KDE, KC_##KDF}, \
- { KC_##KCA, KC_##KCB, KC_##KCC, KC_##KCD, KC_##KCE, KC_##KCF}, \
- { KC_##KBA, KC_##KBB, KC_##KBC, KC_##KBD, KC_##KBE, KC_##KBF}, \
- { KC_##KAA, KC_##KAB, KC_##KAC, KC_##KAD, KC_##KAE, KC_##KAF}, \
- { KC_##K9A, KC_##K9B, KC_##K9C, KC_##K9D, KC_##K9E, KC_##K9F}, \
- { KC_##K8A, KC_##K8B, KC_##K8C, KC_##K8D, KC_##K8E, KC_##K8F}, \
- { KC_##K7A, KC_##K7B, KC_##K7C, KC_##K7D, KC_##K7E, KC_##K7F}, \
- { KC_##K6A, KC_##K6B, KC_##K6C, KC_##K6D, KC_##K6E, KC_##K6F}, \
- { KC_##K5A, KC_##K5B, KC_##K5C, KC_##K5D, KC_##K5E, KC_##K5F}, \
- { KC_##K4A, KC_##K4B, KC_##K4C, KC_##K4D, KC_##K4E, KC_##K4F}, \
- { KC_##K3A, KC_##K3B, KC_##K3C, KC_##K3D, KC_##K3E, KC_##K3F}, \
- { KC_##K2A, KC_##K2B, KC_##K2C, KC_##K2D, KC_##K2E, KC_##K2F}, \
- { KC_##K1A, KC_##K1B, KC_##K1C, KC_##K1D, KC_##K1E, KC_##K1F}, \
- { KC_##K0A, KC_##K0B, KC_##K0C, KC_##K0D, KC_##K0E, KC_##K0F} \
- }
- /* ANSI valiant. No extra keys for ISO */
- #define KEYMAP_ANSI( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, \
- K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, \
- K40, K41, K42, K45, K4A, K4B, K4C, K4D \
- ) KEYMAP( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, NO, K2D, \
- K30, NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, NO, K3D, \
- K40, K41, K42, K45, NO, K4A, K4B, K4C, K4D \
- )
- #define KEYMAP_HHKB( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K49,\
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2D, \
- K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3D, K3C, \
- K40, K41, K42, K45, K4A, K4B, K4C, K4D \
- ) KEYMAP( \
- K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
- K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
- K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, NO, K2D, \
- K30, NO, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
- K40, K41, K42, K45, K49, K4A, K4B, K4C, K4D \
- )
- #endif
Add Comment
Please, Sign In to add comment