mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-04-10 07:45:41 +00:00
Added default keymap variant
This commit is contained in:
parent
0f7be8b458
commit
de744807da
20
keyboards/kyria/config.h
Normal file
20
keyboards/kyria/config.h
Normal file
@ -0,0 +1,20 @@
|
||||
/*
|
||||
Copyright 2019 Thomas Baart <thomas@splitkb.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 CONFIG_H
|
||||
#define CONFIG_H
|
||||
|
||||
#include "config_common.h"
|
||||
|
||||
#endif // CONFIG_H
|
23
keyboards/kyria/info.json
Normal file
23
keyboards/kyria/info.json
Normal file
@ -0,0 +1,23 @@
|
||||
{
|
||||
"keyboard_name": "Kyria",
|
||||
"url": "https://splitkb.com",
|
||||
"maintainer": "splitkb.com",
|
||||
"width": 16.5,
|
||||
"height": 5.5,
|
||||
"layouts": {
|
||||
"LAYOUT": {
|
||||
"layout": [
|
||||
{"x":3, "y":0.25}, {"x":12.5, "y":0.25}, {"x":2, "y":0.5}, {"x":4, "y":0.5}, {"x":11.5, "y":0.5},
|
||||
{"x":13.5, "y":0.5}, {"x":5, "y":0.75}, {"x":10.5, "y":0.75}, {"x":0, "y":1}, {"x":1, "y":1},
|
||||
{"x":14.5, "y":1}, {"x":15.5, "y":1}, {"x":3, "y":1.25}, {"x":12.5, "y":1.25}, {"x":2, "y":1.5},
|
||||
{"x":4, "y":1.5}, {"x":11.5, "y":1.5}, {"x":13.5, "y":1.5}, {"x":5, "y":1.75}, {"x":10.5, "y":1.75},
|
||||
{"x":0, "y":2}, {"x":1, "y":2}, {"x":14.5, "y":2}, {"x":15.5, "y":2}, {"x":3, "y":2.25},
|
||||
{"x":12.5, "y":2.25}, {"x":2, "y":2.5}, {"x":4, "y":2.5}, {"x":11.5, "y":2.5}, {"x":13.5, "y":2.5},
|
||||
{"x":5, "y":2.75}, {"x":10.5, "y":2.75}, {"x":0, "y":3}, {"x":1, "y":3}, {"x":14.5, "y":3},
|
||||
{"x":15.5, "y":3}, {"x":6, "y":3.25}, {"x":9.5, "y":3.25}, {"x":2.5, "y":3.5}, {"x":3.5, "y":3.5},
|
||||
{"x":7, "y":3.5}, {"x":8.5, "y":3.5}, {"x":12, "y":3.5}, {"x":13, "y":3.5}, {"x":4.5, "y":3.75},
|
||||
{"x":11, "y":3.75}, {"x":5.5, "y":4.25}, {"x":10, "y":4.25}, {"x":6.5, "y":4.5}, {"x":9, "y":4.5}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
28
keyboards/kyria/keymaps/default/config.h
Normal file
28
keyboards/kyria/keymaps/default/config.h
Normal file
@ -0,0 +1,28 @@
|
||||
/* Copyright 2019 Thomas Baart <thomas@splitkb.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/>.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#ifdef OLED_DRIVER_ENABLE
|
||||
#define OLED_DISPLAY_128X64
|
||||
#endif
|
||||
|
||||
#ifdef RGBLIGHT_ENABLE
|
||||
#define RGBLIGHT_ANIMATIONS
|
||||
#define RGBLIGHT_HUE_STEP 8
|
||||
#define RGBLIGHT_SAT_STEP 8
|
||||
#define RGBLIGHT_VAL_STEP 8
|
||||
#endif
|
312
keyboards/kyria/keymaps/default/keymap.c
Normal file
312
keyboards/kyria/keymaps/default/keymap.c
Normal file
@ -0,0 +1,312 @@
|
||||
/* Copyright 2019 Thomas Baart
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
#define _QWERTY 0
|
||||
#define _LOWER 1
|
||||
#define _RAISE 2
|
||||
#define _ADJUST 3
|
||||
|
||||
enum custom_keycodes {
|
||||
LOWER = SAFE_RANGE,
|
||||
RAISE
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
[_QWERTY] = LAYOUT(
|
||||
KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, /**/ KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, \
|
||||
KC_LSFT, KC_A, KC_S, KC_D, KC_F, KC_G, /**/ KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, \
|
||||
KC_LCTL, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LCTL, KC_LSFT, /**/ KC_BSPC, KC_DEL, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ALGR, \
|
||||
KC_LGUI, KC_LALT, LOWER, KC_LSFT, KC_ENT, /**/ KC_BSPC, KC_SPC, RAISE, KC_TAB, KC_TAB
|
||||
),
|
||||
[_LOWER] = LAYOUT(
|
||||
_______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_SLSH, KC_7, KC_8, KC_9, KC_MINS, _______, \
|
||||
_______, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_ASTR, KC_4, KC_5, KC_6, KC_PLUS, _______, \
|
||||
_______, KC_F11, KC_F12, KC_F13, KC_F14, KC_F15, _______, _______, _______, _______, KC_COMM, KC_1, KC_2, KC_3, KC_EQL, _______, \
|
||||
_______, _______, _______, _______, _______, _______, KC_RALT, _______, KC_0, _______
|
||||
),
|
||||
[_RAISE] = LAYOUT(
|
||||
KC_TILD, KC_PLUS, KC_MINS, KC_LBRC, KC_RBRC, _______, KC_PGUP, KC_HOME, KC_UP, KC_END, _______, _______, \
|
||||
KC_GRV, KC_EQL, KC_UNDS, KC_LPRN, KC_RPRN, KC_BSLS, KC_PGDN, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______, \
|
||||
_______, _______, _______, KC_LCBR, KC_RCBR, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, \
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
[_ADJUST] = LAYOUT(
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, KC_VOLU, RGB_TOG, RGB_VAD, RGB_VAI, \
|
||||
_______, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT, RGB_HUD, RGB_HUI, \
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_VOLD, KC_MUTE, RGB_SAD, RGB_SAI, \
|
||||
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
|
||||
),
|
||||
};
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
switch (keycode) {
|
||||
case LOWER:
|
||||
if (record->event.pressed) {
|
||||
layer_on(_LOWER);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
} else {
|
||||
layer_off(_LOWER);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case RAISE:
|
||||
if (record->event.pressed) {
|
||||
layer_on(_RAISE);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
} else {
|
||||
layer_off(_RAISE);
|
||||
update_tri_layer(_LOWER, _RAISE, _ADJUST);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
#ifdef OLED_DRIVER_ENABLE
|
||||
oled_rotation_t oled_init_user(oled_rotation_t rotation) {
|
||||
return OLED_ROTATION_180;
|
||||
}
|
||||
|
||||
static void render_kyria_logo(void) {
|
||||
static const char PROGMEM kyria_logo[] = {
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0x7F, 0x7F, 0x3F, 0x1F, 0x0F,
|
||||
0x8F, 0x87, 0xC7, 0xC3, 0xE3, 0xE1,
|
||||
0xF1, 0xF1, 0xF1, 0xF8, 0xF8, 0xF8,
|
||||
0xF8, 0xF8, 0xF8, 0xF8, 0xF8, 0xF8,
|
||||
0xF8, 0xF8, 0xF8, 0xF8, 0xF8, 0xF8,
|
||||
0xF8, 0xF1, 0xF1, 0xF1, 0xE1, 0xE3,
|
||||
0xC3, 0xC7, 0x87, 0x8F, 0x0F, 0x1F,
|
||||
0x3F, 0x7F, 0x7F, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF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1F, 0x1F, 0x1F, 0x1F,
|
||||
0x1F, 0x1F, 0x1F, 0x1F, 0x1F, 0x1F,
|
||||
0x1F, 0x8F, 0x8F, 0x8F, 0x87, 0xC7,
|
||||
0xC3, 0xE3, 0xE1, 0xF1, 0xF0, 0xF8,
|
||||
0xFC, 0xFE, 0xFE, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
|
||||
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,0
|
||||
};
|
||||
oled_write_raw(&kyria_logo, sizeof(kyria_logo));
|
||||
}
|
||||
|
||||
static void render_qmk_logo(void) {
|
||||
static const char PROGMEM qmk_logo[] = {
|
||||
0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,0x92,0x93,0x94,
|
||||
0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,0xb0,0xb1,0xb2,0xb3,0xb4,
|
||||
0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xd0,0xd1,0xd2,0xd3,0xd4,0};
|
||||
|
||||
oled_write_P(qmk_logo, false);
|
||||
}
|
||||
|
||||
static void render_status(void) {
|
||||
render_qmk_logo();
|
||||
// Host Keyboard Layer Status
|
||||
oled_write_P(PSTR("Layer: "), false);
|
||||
switch (get_highest_layer(layer_state)) {
|
||||
case _QWERTY:
|
||||
oled_write_P(PSTR("DEFAULT\n"), false);
|
||||
break;
|
||||
case _LOWER:
|
||||
oled_write_P(PSTR("LOWER\n"), false);
|
||||
break;
|
||||
case _RAISE:
|
||||
oled_write_P(PSTR("RAISE\n"), false);
|
||||
break;
|
||||
case _ADJUST:
|
||||
oled_write_P(PSTR("ADJUST\n"), false);
|
||||
break;
|
||||
|
||||
default:
|
||||
// Or use the write_ln shortcut over adding '\n' to the end of your string
|
||||
oled_write_ln_P(PSTR("Undefined"), false);
|
||||
}
|
||||
|
||||
// Host Keyboard LED Status
|
||||
uint8_t led_usb_state = host_keyboard_leds();
|
||||
oled_write_P("\n", false);
|
||||
oled_write_P(led_usb_state & (1<<USB_LED_NUM_LOCK) ? PSTR("NUMLCK ") : PSTR(" "), false);
|
||||
oled_write_P(led_usb_state & (1<<USB_LED_CAPS_LOCK) ? PSTR("CAPLCK ") : PSTR(" "), false);
|
||||
oled_write_P(led_usb_state & (1<<USB_LED_SCROLL_LOCK) ? PSTR("SCRLCK ") : PSTR(" "), false);
|
||||
}
|
||||
|
||||
void oled_task_user(void) {
|
||||
if (is_keyboard_master()) {
|
||||
render_status(); // Renders the current keyboard state (layer, lock, caps, scroll, etc)
|
||||
} else {
|
||||
render_kyria_logo();
|
||||
// oled_write_P(PSTR("Kyria rev0.6 alpha\n"), false);
|
||||
// oled_write_P(PSTR("splitkb.com\n"), false);
|
||||
// oled_write_P(PSTR("Thomas Baart\n"), false);
|
||||
// oled_write_P(PSTR("thomasbaart.nl\n"), false);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void encoder_update_user(uint8_t index, bool clockwise) {
|
||||
if (index == 0) {
|
||||
switch (biton32(layer_state)) {
|
||||
case _QWERTY:
|
||||
if (clockwise) {
|
||||
SEND_STRING(SS_LCTRL("z"));
|
||||
} else {
|
||||
SEND_STRING(SS_LCTRL("y"));
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
// other layers - =/+ (quals/plus) (CW) and -/_ (minus/underscore) (CCW)
|
||||
if (clockwise) {
|
||||
tap_code(KC_EQL);
|
||||
} else {
|
||||
tap_code(KC_MINS);
|
||||
}
|
||||
break;
|
||||
}
|
||||
} else if (index == 1) {
|
||||
switch (biton32(layer_state)) {
|
||||
case _QWERTY:
|
||||
if (clockwise) {
|
||||
tap_code(KC_PGDN);
|
||||
} else {
|
||||
tap_code(KC_PGUP);
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
if (clockwise) {
|
||||
tap_code(KC_VOLU);
|
||||
} else {
|
||||
tap_code(KC_VOLD);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
3
keyboards/kyria/keymaps/default/rules.mk
Normal file
3
keyboards/kyria/keymaps/default/rules.mk
Normal file
@ -0,0 +1,3 @@
|
||||
OLED_DRIVER_ENABLE = yes # Enables the use of OLED displays
|
||||
ENCODER_ENABLE = yes # ENables the use of one or more encoders
|
||||
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
|
16
keyboards/kyria/kyria.c
Normal file
16
keyboards/kyria/kyria.c
Normal file
@ -0,0 +1,16 @@
|
||||
/* Copyright 2019 Thomas Baart <thomas@splitkb.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/>.
|
||||
*/
|
||||
#include "kyria.h"
|
43
keyboards/kyria/kyria.h
Normal file
43
keyboards/kyria/kyria.h
Normal file
@ -0,0 +1,43 @@
|
||||
/* Copyright 2019 Thomas Baart <thomas@splitkb.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/>.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include "quantum.h"
|
||||
|
||||
/* This a shortcut to help you visually see your layout.
|
||||
*
|
||||
* The first section contains all of the arguments representing the physical
|
||||
* layout of the board and position of the keys.
|
||||
*
|
||||
* The second converts the arguments into a two-dimensional array which
|
||||
* represents the switch matrix.
|
||||
*/
|
||||
#define LAYOUT( \
|
||||
L00, L01, L02, L03, L04, L05, R06, R07, R08, R09, R10, R11, \
|
||||
L12, L13, L14, L15, L16, L17, R18, R19, R20, R21, R22, R23, \
|
||||
L24, L25, L26, L27, L28, L29, L30, L31, R32, R33, R34, R35, R36, R37, R38, R39, \
|
||||
L40, L41, L42, L43, L44, R45, R46, R47, R48, R49 \
|
||||
) \
|
||||
{ \
|
||||
{ KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \
|
||||
{ KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \
|
||||
{ L31, L30, L29, L28, L27, L26, L25, L24 }, \
|
||||
{ L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \
|
||||
{ KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \
|
||||
{ KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \
|
||||
{ R32, R33, R34, R35, R36, R37, R38, R39 }, \
|
||||
{ R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \
|
||||
}
|
21
keyboards/kyria/readme.md
Normal file
21
keyboards/kyria/readme.md
Normal file
@ -0,0 +1,21 @@
|
||||
# Kyria
|
||||
|
||||

|
||||
|
||||
An ergonomical 40% split keyboard
|
||||
|
||||
Keyboard Maintainer: [splitkb.com](https://github.com/splitkb)
|
||||
Hardware Supported: Pro Micro 5V/16MHz and compatible.
|
||||
Hardware Availability: [splitkb.com](https://splitkb.com) and partners.
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make kyria:default
|
||||
|
||||
Example of flashing this keyboard:
|
||||
|
||||
make kyria/rev1:default:avrdude
|
||||
|
||||
See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
|
||||
|
||||
A build guide for the Kyria can be found at [docs.splitkb.com](https://docs.splitkb.com/docs/kyria-build-log/).
|
66
keyboards/kyria/rev1/config.h
Normal file
66
keyboards/kyria/rev1/config.h
Normal file
@ -0,0 +1,66 @@
|
||||
/*
|
||||
Copyright 2019 Thomas Baart <thomas@splitkb.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/>.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include QMK_KEYBOARD_CONFIG_H
|
||||
|
||||
/* USB Device descriptor parameter */
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x0000
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER splitkb
|
||||
#define PRODUCT Kyria Keyboard
|
||||
#define DESCRIPTION Split 40 percent ergonomic keyboard
|
||||
|
||||
/* key matrix size */
|
||||
/* Rows are doubled up */
|
||||
#define MATRIX_ROWS 8
|
||||
#define MATRIX_COLS 8
|
||||
|
||||
// wiring
|
||||
#define MATRIX_ROW_PINS { B4, E6, D7, D4 }
|
||||
#define MATRIX_COL_PINS { B6, B2, B3, B1, F7, F6, F5, F4 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
#define ENCODERS_PAD_A { C6 }
|
||||
#define ENCODERS_PAD_B { B5 }
|
||||
#define ENCODERS_PAD_A_RIGHT { B5 }
|
||||
#define ENCODERS_PAD_B_RIGHT { C6 }
|
||||
|
||||
/* COL2ROW, ROW2COL*/
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
/* define if matrix has ghost (lacks anti-ghosting diodes) */
|
||||
//#define MATRIX_HAS_GHOST
|
||||
|
||||
/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
|
||||
#define DEBOUNCING_DELAY 5
|
||||
|
||||
/*
|
||||
* Split Keyboard specific options, make sure you have 'SPLIT_KEYBOARD = yes' in your rules.mk, and define SOFT_SERIAL_PIN.
|
||||
*/
|
||||
#define SOFT_SERIAL_PIN D2
|
||||
|
||||
#define RGB_DI_PIN D3
|
||||
#define RGBLED_SPLIT { 10, 10 }
|
||||
#define RGBLED_NUM 20
|
||||
|
||||
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
/* Locking resynchronize hack */
|
||||
#define LOCKING_RESYNC_ENABLE
|
1
keyboards/kyria/rev1/rev1.c
Normal file
1
keyboards/kyria/rev1/rev1.c
Normal file
@ -0,0 +1 @@
|
||||
#include "rev1.h"
|
52
keyboards/kyria/rev1/rev1.h
Normal file
52
keyboards/kyria/rev1/rev1.h
Normal file
@ -0,0 +1,52 @@
|
||||
/* Copyright 2019 Thomas Baart <thomas@splitkb.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/>.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include "kyria.h"
|
||||
#include "quantum.h"
|
||||
|
||||
#ifdef USE_I2C
|
||||
#include <stddef.h>
|
||||
#ifdef __AVR__
|
||||
#include <avr/io.h>
|
||||
#include <avr/interrupt.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/* This a shortcut to help you visually see your layout.
|
||||
*
|
||||
* The first section contains all of the arguments representing the physical
|
||||
* layout of the board and position of the keys.
|
||||
*
|
||||
* The second converts the arguments into a two-dimensional array which
|
||||
* represents the switch matrix.
|
||||
*/
|
||||
#define LAYOUT( \
|
||||
L00, L01, L02, L03, L04, L05, R06, R07, R08, R09, R10, R11, \
|
||||
L12, L13, L14, L15, L16, L17, R18, R19, R20, R21, R22, R23, \
|
||||
L24, L25, L26, L27, L28, L29, L30, L31, R32, R33, R34, R35, R36, R37, R38, R39, \
|
||||
L40, L41, L42, L43, L44, R45, R46, R47, R48, R49 \
|
||||
) \
|
||||
{ \
|
||||
{ KC_NO, KC_NO, L05, L04, L03, L02, L01, L00 }, \
|
||||
{ KC_NO, KC_NO, L17, L16, L15, L14, L13, L12 }, \
|
||||
{ L31, L30, L29, L28, L27, L26, L25, L24 }, \
|
||||
{ L44, L43, L42, L41, L40, KC_NO, KC_NO, KC_NO }, \
|
||||
{ KC_NO, KC_NO, R06, R07, R08, R09, R10, R11 }, \
|
||||
{ KC_NO, KC_NO, R18, R19, R20, R21, R22, R23 }, \
|
||||
{ R32, R33, R34, R35, R36, R37, R38, R39 }, \
|
||||
{ R45, R46, R47, R48, R49, KC_NO, KC_NO, KC_NO }, \
|
||||
}
|
3
keyboards/kyria/rev1/rules.mk
Normal file
3
keyboards/kyria/rev1/rules.mk
Normal file
@ -0,0 +1,3 @@
|
||||
OLED_DRIVER_ENABLE = yes # Enables the use of OLED displays
|
||||
ENCODER_ENABLE = yes # ENables the use of one or more encoders
|
||||
RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
|
80
keyboards/kyria/rules.mk
Normal file
80
keyboards/kyria/rules.mk
Normal file
@ -0,0 +1,80 @@
|
||||
# MCU name
|
||||
#MCU = at90usb1286
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Bootloader selection
|
||||
# Teensy halfkay
|
||||
# Pro Micro caterina
|
||||
# Atmel DFU atmel-dfu
|
||||
# LUFA DFU lufa-dfu
|
||||
# QMK DFU qmk-dfu
|
||||
# atmega32a bootloadHID
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
# If you don't know the bootloader type, then you can specify the
|
||||
# Boot Section Size in *bytes* by uncommenting out the OPT_DEFS line
|
||||
# Teensy halfKay 512
|
||||
# Teensy++ halfKay 1024
|
||||
# Atmel DFU loader 4096
|
||||
# LUFA bootloader 4096
|
||||
# USBaspLoader 2048
|
||||
# OPT_DEFS += -DBOOTLOADER_SIZE=4096
|
||||
|
||||
# Build Options
|
||||
# change yes to no to disable
|
||||
#
|
||||
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
|
||||
MOUSEKEY_ENABLE = yes # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
|
||||
NKRO_ENABLE = no # USB Nkey Rollover
|
||||
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default
|
||||
MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
|
||||
UNICODE_ENABLE = no # Unicode
|
||||
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
|
||||
AUDIO_ENABLE = no # Audio output on port C6
|
||||
FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
|
||||
HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
|
||||
SPLIT_KEYBOARD = yes # Split common
|
||||
EXTRAFLAGS += -flto # Link time optimization in order to save space
|
||||
|
||||
DEFAULT_FOLDER = kyria/rev1
|
Loading…
Reference in New Issue
Block a user