Browse Source

[Keyboard] Add yetis keyboard

The yeti truly exists!

Signed-off-by: Norbert Pocs <norbertpocs0@gmail.com>
pull/22535/head
jOgmE 1 year ago
committed by Norbert Pocs
parent
commit
7f9ba0b1b5
6 changed files with 306 additions and 0 deletions
  1. +17
    -0
      keyboards/yetis/config.h
  2. +99
    -0
      keyboards/yetis/info.json
  3. +55
    -0
      keyboards/yetis/keymaps/default/keymap.c
  4. +25
    -0
      keyboards/yetis/readme.md
  5. +1
    -0
      keyboards/yetis/rules.mk
  6. +109
    -0
      keyboards/yetis/yetis.c

+ 17
- 0
keyboards/yetis/config.h View File

@ -0,0 +1,17 @@
/*
* Copyright 2023 Norbert Pocs (norbertpocs0@gmail.com, jogme)
* SPDX-License-Identifier: GPL-2.0-or-later
*/
#pragma once
/* Uncomment if you wish to use USB on the right half */
#define MASTER_RIGHT
//#define MASTER_LEFT
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 200U
#define OLED_DC_PIN D1
#define OLED_CS_PIN D0

+ 99
- 0
keyboards/yetis/info.json View File

@ -0,0 +1,99 @@
{
"manufacturer": "jogme",
"keyboard_name": "Yetis",
"maintainer": "qmk",
"development_board": "elite_c",
"features": {
"bootmagic": true,
"extrakey": true,
"mousekey": true,
"nkro": true,
"oled": true,
"rgblight": true
},
"matrix_pins": {
"direct": [
[null, null, "F7", "F6", "F5", "F4"],
["F0", "F1", "B1", "B3", "B2", "B6"],
[null, "C7", "D5", "B7", "B5", "E6"],
[null, null, null, null, "D7", "C6"]
]
},
"rgblight": {
"led_count": 12,
"split": true,
"split_count": [6, 6],
"animations": {
"breathing": true,
"knight": true
}
},
"ws2812": {
"pin": "D3"
},
"split": {
"enabled": true,
"matrix_pins": {
"right": {
"direct": [
["F4", "F5", "F6", "F7", null, null],
["B6", "B2", "B3", "B1", "F1", "F0"],
["E6", "B5", "B7", "D5", "C7", null],
["C6", "D7", null, null, null, null]
]
}
},
"soft_serial_pin": "D2",
"transport": {
"sync": {
"oled": true
}
}
},
"url": "https://github.com/jogme/yetis-keyboard",
"usb": {
"device_version": "1.1.0",
"pid": "0x8008",
"vid": "0xFEED"
},
"layouts": {
"LAYOUT": {
"layout": [
{"matrix": [0, 2], "x": 2, "y": 0.25},
{"matrix": [0, 3], "x": 3.25, "y": 0},
{"matrix": [0, 4], "x": 4.6, "y": 0.6},
{"matrix": [0, 5], "x": 5.6, "y": 0.85},
{"matrix": [4, 0], "x": 10, "y": 0.85},
{"matrix": [4, 1], "x": 11, "y": 0.6},
{"matrix": [4, 2], "x": 12.35, "y": 0},
{"matrix": [4, 3], "x": 13.6, "y": 0.25},
{"matrix": [1, 0], "x": 0, "y": 1.9},
{"matrix": [1, 1], "x": 1, "y": 1.9},
{"matrix": [1, 2], "x": 2, "y": 1.25},
{"matrix": [1, 3], "x": 3.25, "y": 1},
{"matrix": [1, 4], "x": 4.6, "y": 1.6},
{"matrix": [1, 5], "x": 5.6, "y": 1.85},
{"matrix": [5, 0], "x": 10, "y": 1.85},
{"matrix": [5, 1], "x": 11, "y": 1.6},
{"matrix": [5, 2], "x": 12.35, "y": 1},
{"matrix": [5, 3], "x": 13.6, "y": 1.25},
{"matrix": [5, 4], "x": 14.6, "y": 1.9},
{"matrix": [5, 5], "x": 15.6, "y": 1.9},
{"matrix": [2, 1], "x": 0.85, "y": 2.9},
{"matrix": [2, 2], "x": 2, "y": 2.25},
{"matrix": [2, 3], "x": 3.25, "y": 2},
{"matrix": [2, 4], "x": 4.6, "y": 2.6},
{"matrix": [2, 5], "x": 5.6, "y": 2.85},
{"matrix": [6, 0], "x": 10, "y": 2.85},
{"matrix": [6, 1], "x": 11, "y": 2.6},
{"matrix": [6, 2], "x": 12.35, "y": 2},
{"matrix": [6, 3], "x": 13.6, "y": 2.25},
{"matrix": [6, 4], "x": 14.75, "y": 2.9},
{"matrix": [3, 4], "x": 5.6, "y": 5},
{"matrix": [3, 5], "x": 6.4, "y": 6},
{"matrix": [7, 0], "x": 9.2, "y": 6},
{"matrix": [7, 1], "x": 10, "y": 5}
]
}
}
}

+ 55
- 0
keyboards/yetis/keymaps/default/keymap.c View File

@ -0,0 +1,55 @@
/*
* Copyright 2023 Norbert Pocs (norbertpocs0@gmail.com, jogme)
* SPDX-License-Identifier: GPL-2.0-or-later
*/
#include QMK_KEYBOARD_H
#define LA_SYM MO(LAYER_SYM)
#define LA_NAV MO(LAYER_NAV)
#define LA_RGB TG(LAYER_GAM_LED)
#define ALT OSM(MOD_LALT)
#define SHIFT OSM(MOD_LSFT)
#define CTRL OSM(MOD_LCTL)
#define WIN OSM(MOD_LGUI)
enum layers {
LAYER_COLMAC,
LAYER_SYM,
LAYER_NAV,
LAYER_NUM,
LAYER_GAM_LED
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[LAYER_COLMAC] = LAYOUT(
KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y,
KC_Q, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT,
KC_Z, KC_X, KC_C, KC_V, KC_B, KC_K, KC_M, KC_COMM, KC_DOT, KC_ENT,
LA_NAV, KC_ESC, KC_SPC, LA_SYM),
[LAYER_SYM] = LAYOUT(
KC_LBRC, KC_LCBR, KC_LPRN, KC_TILD, KC_HASH, KC_RPRN, KC_RCBR, KC_RBRC,
KC_PLUS, KC_EQL, KC_ASTR, KC_MINS, KC_UNDS, KC_DLR, KC_CIRC, KC_SCLN, KC_WH_D, KC_WH_U, KC_SLSH, KC_GRV,
KC_BSLS, KC_PIPE, KC_AT, KC_AMPR, KC_PERC, KC_EXLM, KC_LT, KC_GT, KC_COLN, KC_QUES,
_______, _______, _______, _______),
[LAYER_NAV] = LAYOUT(
ALT, KC_BRID, KC_BRIU, KC_VOLU, KC_NO, KC_HOME, KC_PGDN, KC_PGUP,
KC_NO, SHIFT, CTRL, KC_TAB, WIN, KC_VOLD, KC_DEL, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_END,
KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, KC_PSCR, LA_RGB, KC_CAPS, KC_BTN1, KC_BTN2, KC_BSPC,
_______, _______, _______, _______),
[LAYER_NUM] = LAYOUT(
KC_5, KC_3, KC_1, KC_9, KC_8, KC_0, KC_2, KC_4,
KC_7, SHIFT, KC_NO, KC_NO, WIN, KC_F11, KC_F10, KC_NO, KC_NO, KC_NO, KC_NO, KC_6,
KC_F7, KC_F5, KC_F3, KC_F1, KC_F9, KC_F8, KC_F12, KC_F2, KC_F4, KC_F6,
_______, _______, _______, _______),
[LAYER_GAM_LED] = LAYOUT(
KC_1, KC_2, KC_3, KC_4, _______, RGB_SAD, RGB_SAI, _______,
KC_0, KC_P, KC_A, KC_W, KC_D, KC_R, RGB_HUD, RGB_VAD, RGB_VAI, RGB_HUI, _______, _______,
KC_LCTL, KC_Q, KC_S, KC_E, KC_F, LA_RGB, RGB_TOG, RGB_M_B, RGB_M_P, RGB_M_K,
KC_LALT, KC_B, _______, _______),
};
layer_state_t layer_state_set_user(layer_state_t state) {
return update_tri_layer_state(state, LAYER_SYM, LAYER_NAV, LAYER_NUM);
}

+ 25
- 0
keyboards/yetis/readme.md View File

@ -0,0 +1,25 @@
# Yetis keyboard
![yetis](https://i.imgur.com/sM9UuP7h.png)
34 key split keyboard with columnar stagger. Suitable for bigger palms.
* Keyboard Maintainer: [Norbert Pocs](https://github.com/jogme)
* Hardware Supported: Yetis pcb, Frood microcontroller (but any Elite C layout works fine)
* Hardware Availability: [pcb and case](https://www.jogmekeebs.com/)
Make example for this keyboard (after setting up your build environment):
make yetis:default
Flashing example for this keyboard:
make yetis:default:flash
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).
## Bootloader
Enter the bootloader:
* Short the pins on the microcontroller manually

+ 1
- 0
keyboards/yetis/rules.mk View File

@ -0,0 +1 @@
# This file intentionally left blank

+ 109
- 0
keyboards/yetis/yetis.c View File

@ -0,0 +1,109 @@
/*
* Copyright 2023 Norbert Pocs (norbertpocs0@gmail.com, jogme)
* SPDX-License-Identifier: GPL-2.0-or-later
*/
#include "quantum.h"
#ifdef OLED_ENABLE
/* corresponds to the layer number in keymaps/default/keymap.c */
#define LAYER_GAME 4
oled_rotation_t oled_init_kb(oled_rotation_t rotation) {
if (!is_keyboard_master()) {
return OLED_ROTATION_90;
}
return OLED_ROTATION_270;
}
static void render_logo(void) {
const char yeti_logo [] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x40, 0x40, 0xc0, 0x40, 0x40, 0x00, 0x00, 0x40, 0x40, 0x40, 0xc0, 0x00, 0x00, 0x00,
0x40, 0x40, 0x40, 0x40, 0xc0, 0x80, 0x00, 0x00, 0x00, 0xc0, 0xf0, 0x98, 0x18, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x5f, 0x18, 0x10, 0x00, 0x00, 0x00, 0x10, 0x10, 0x7f, 0x10, 0x10, 0x00,
0x06, 0x0e, 0x12, 0x12, 0x0a, 0x0f, 0x00, 0x00, 0x1e, 0x03, 0x00, 0x07, 0x1c, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x60, 0xe0, 0xf0, 0xf0, 0xe0, 0xf0, 0xf0, 0xf0, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0xc1, 0xf3, 0x33, 0x03, 0x03, 0xff, 0xff, 0x80, 0x00, 0x00, 0x00,
0x83, 0xff, 0xff, 0x07, 0x23, 0xf3, 0xe7, 0x87, 0x0f, 0x07, 0x07, 0x03, 0x03, 0x03, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x1e, 0xff, 0xff, 0x86, 0x03, 0xc0, 0xf1, 0xff, 0xff, 0xfe, 0xfe, 0xfe,
0xff, 0xff, 0xfd, 0xe0, 0x86, 0xff, 0xff, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfc, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x02, 0x07, 0x07, 0x0f, 0x0f, 0x0f, 0x2f, 0xff, 0xff, 0xff, 0xff, 0xff,
0xff, 0xff, 0x2f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x01, 0x01,
0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
};
oled_write_raw_P(yeti_logo, sizeof(yeti_logo));
}
static void oled_render_caps_lock(void) {
led_t l = host_keyboard_led_state();
oled_write_ln(l.caps_lock ? PSTR("Caps Lock") : PSTR(" \n"), false);
}
static void oled_render_layer_state(void) {
switch (get_highest_layer(layer_state)) {
case LAYER_GAME:
oled_write_ln(PSTR("GAME"), false);
break;
default:
oled_write_ln(PSTR(" \n"), false);
}
}
static void oled_render_mods(void) {
static uint8_t mods;
mods = get_mods() | get_oneshot_mods();
if (mods & MOD_MASK_SHIFT) {
oled_write_ln(PSTR("Shft"), false);
} else {
oled_write_ln(PSTR(" "), false);
}
if (mods & MOD_MASK_CTRL) {
oled_write_ln(PSTR("Ctrl"), false);
} else {
oled_write_ln(PSTR(" "), false);
}
if (mods & MOD_MASK_ALT) {
oled_write_ln(PSTR("Alt"), false);
} else {
oled_write_ln(PSTR(" "), false);
}
if (mods & MOD_MASK_GUI) {
oled_write_ln(PSTR("Win"), false);
} else {
oled_write_ln(PSTR(" "), false);
}
}
bool oled_task_kb(void) {
if (!is_keyboard_master()) {
render_logo();
} else {
oled_write_ln(PSTR("yeti\n"), false);
oled_render_mods();
oled_render_caps_lock();
oled_render_layer_state();
}
return false;
}
#endif

Loading…
Cancel
Save