1
0
This repo is archived. You can view files and clone it, but cannot push or open issues or pull requests.
tmk_keyboard_custom/keyboard/faceu/keymap_faceu.c
2014-04-09 16:13:19 +09:00

114 lines
5.8 KiB
C

#include "keymap_common.h"
// FaceU
#ifdef KEYMAP_SECTION_ENABLE
const uint8_t keymaps[KEYMAPS_COUNT][MATRIX_ROWS][MATRIX_COLS] __attribute__ ((section (".keymap.keymaps"))) = {
#else
const uint8_t keymaps[][MATRIX_ROWS][MATRIX_COLS] PROGMEM = {
#endif
/* Keymap 0: Default Layer
* ,-----------------------------------------------------------.
* |Esc| 1| 2| 3| 4| 5| 6| 7| 8| 9| 0| -| =|Backsp |
* |-----------------------------------------------------------|
* |Tab | Q| W| E| R| T| Y| U| I| O| P| [| ]| \|
* |-----------------------------------------------------------|
* |Caps | A| S| D| F| G| H| J| K| L| ;| '|Return |
* |-----------------------------------------------------------|
* |Shift | Z| X| C| V| B| N| M| ,| .| /|Shift |Fn0|
* |-----------------------------------------------------------|
* |Ctrl|Gui |Alt | Space |Alt |App |Fn0 |Ctrl|
* `-----------------------------------------------------------'
*/
KEYMAP(
ESC, 1, 2, 3, 4, 5, 6, 7, 8, 9, 0, MINS,EQL, BSPC, GRV, \
TAB, Q, W, E, R, T, Y, U, I, O, P, LBRC,RBRC,BSLS, \
CAPS,A, S, D, F, G, H, J, K, L, SCLN,QUOT,NUHS,ENT, \
LSFT,NUBS,Z, X, C, V, B, N, M, COMM,DOT, SLSH,RSFT,FN0, \
LCTL,LGUI,LALT, SPC, RALT,APP, FN0, RCTL),
/* Keymap 1: Fn Layer
* ,-----------------------------------------------------------.
* | `| F1| F2| F3| F4| F5| F6| F7| F8| F9|F10|F11|F12|Delete |
* |-----------------------------------------------------------|
* | | |Up | | | | |Nlk|Psc|Slk|Pau|Up |Ins| |
* |-----------------------------------------------------------|
* |Fn1 |Lef|Dow|Rig| | | | |Hom|PgU|Lef|Rig| |
* |-----------------------------------------------------------|
* | | | | | | | | |End|PgD|Dow| | |
* |-----------------------------------------------------------|
* | | | | Fn4 |Fn2 | | |Fn3 |
* `-----------------------------------------------------------'
*/
KEYMAP(
GRV, F1, F2, F3, F4, F5, F6, F7, F8, F9, F10, F11, F12, DEL, TRNS, \
TRNS,TRNS,UP, TRNS,TRNS,TRNS,TRNS,NLCK,PSCR,SLCK,PAUS,UP, INS, TRNS, \
FN1, LEFT,DOWN,RGHT,TRNS,TRNS,TRNS,TRNS,HOME,PGUP,LEFT,RGHT,TRNS,TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,END, PGDN,DOWN,TRNS,TRNS, \
TRNS,TRNS,TRNS, FN4, FN2, TRNS,TRNS,FN3),
/* Keymap 2: Arrow Keys Overlayer
* ,-----------------------------------------------------------.
* |Fn5| | | | | | | | | | | | | |
* |-----------------------------------------------------------|
* | | | | | | | | | | | | | | |
* |-----------------------------------------------------------|
* | | | | | | | | | | | | | |
* |-----------------------------------------------------------|
* | | | | | | | | | | | |Up | |
* |-----------------------------------------------------------|
* | | | | |Left|Left|Down|Righ|
* `-----------------------------------------------------------'
*/
KEYMAP(
FN5, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,UP, TRNS, \
TRNS,TRNS,TRNS, TRNS, LEFT,LEFT,DOWN,RGHT),
/* Keymap 3: Overlayer for exiting overlayer
* ,-----------------------------------------------------------.
* |Fn5| | | | | | | | | | | | |Fn6 |
* |-----------------------------------------------------------|
* | | | | | | | | | | | | | | |
* |-----------------------------------------------------------|
* | | | | | | | | | | | | | |
* |-----------------------------------------------------------|
* | | | | | | | | | | | | | |
* |-----------------------------------------------------------|
* | | | | | | | | |
* `-----------------------------------------------------------'
*/
KEYMAP(
FN5, TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,FN6, TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS,TRNS, \
TRNS,TRNS,TRNS, TRNS, TRNS,TRNS,TRNS,TRNS),
};
/*
* Fn action definition
*/
#ifdef KEYMAP_SECTION_ENABLE
const uint16_t fn_actions[FN_ACTIONS_COUNT] __attribute__ ((section (".keymap.fn_actions"))) = {
#else
const uint16_t fn_actions[] PROGMEM = {
#endif
/* Poker2 Layout */
[0] = ACTION_LAYER_MOMENTARY(1),
[1] = ACTION_BACKLIGHT_TOGGLE(),
[2] = ACTION_BACKLIGHT_DECREASE(),
[3] = ACTION_BACKLIGHT_INCREASE(),
[4] = ACTION_LAYER_ON(2, ON_RELEASE),
[5] = ACTION_LAYER_TAP_KEY(3, KC_ESC),
[6] = ACTION_LAYER_OFF(2, ON_RELEASE)
};
#ifdef KEYMAP_EX_ENABLE
uint16_t keys_count(void) {
return sizeof(keymaps) / sizeof(keymaps[0]) * MATRIX_ROWS * MATRIX_COLS;
}
uint16_t fn_actions_count(void) {
return sizeof(fn_actions) / sizeof(fn_actions[0]);
}
#endif