From 36db7457b299d91f665f931a5f60bd059ada0210 Mon Sep 17 00:00:00 2001 From: Arturo Avila <69410272+ADPenrose@users.noreply.github.com> Date: Fri, 24 Dec 2021 19:33:47 -0600 Subject: [Keyboard] Add Kintsugi keyboard (#15439) --- keyboards/adpenrose/kintsugi/config.h | 146 ++++++++++++ keyboards/adpenrose/kintsugi/info.json | 80 +++++++ .../adpenrose/kintsugi/keymaps/default/keymap.c | 48 ++++ .../adpenrose/kintsugi/keymaps/default/readme.md | 1 + .../adpenrose/kintsugi/keymaps/franky/keymap.c | 164 ++++++++++++++ .../adpenrose/kintsugi/keymaps/franky/readme.md | 1 + .../adpenrose/kintsugi/keymaps/franky/rules.mk | 3 + keyboards/adpenrose/kintsugi/keymaps/via/keymap.c | 62 ++++++ keyboards/adpenrose/kintsugi/keymaps/via/readme.md | 1 + keyboards/adpenrose/kintsugi/keymaps/via/rules.mk | 2 + keyboards/adpenrose/kintsugi/kintsugi.c | 74 +++++++ keyboards/adpenrose/kintsugi/kintsugi.h | 46 ++++ keyboards/adpenrose/kintsugi/lib/kintsugifont.c | 244 +++++++++++++++++++++ keyboards/adpenrose/kintsugi/post_config.h | 21 ++ keyboards/adpenrose/kintsugi/readme.md | 37 ++++ keyboards/adpenrose/kintsugi/rules.mk | 21 ++ 16 files changed, 951 insertions(+) create mode 100644 keyboards/adpenrose/kintsugi/config.h create mode 100644 keyboards/adpenrose/kintsugi/info.json create mode 100644 keyboards/adpenrose/kintsugi/keymaps/default/keymap.c create mode 100644 keyboards/adpenrose/kintsugi/keymaps/default/readme.md create mode 100644 keyboards/adpenrose/kintsugi/keymaps/franky/keymap.c create mode 100644 keyboards/adpenrose/kintsugi/keymaps/franky/readme.md create mode 100644 keyboards/adpenrose/kintsugi/keymaps/franky/rules.mk create mode 100644 keyboards/adpenrose/kintsugi/keymaps/via/keymap.c create mode 100644 keyboards/adpenrose/kintsugi/keymaps/via/readme.md create mode 100644 keyboards/adpenrose/kintsugi/keymaps/via/rules.mk create mode 100644 keyboards/adpenrose/kintsugi/kintsugi.c create mode 100644 keyboards/adpenrose/kintsugi/kintsugi.h create mode 100644 keyboards/adpenrose/kintsugi/lib/kintsugifont.c create mode 100644 keyboards/adpenrose/kintsugi/post_config.h create mode 100644 keyboards/adpenrose/kintsugi/readme.md create mode 100644 keyboards/adpenrose/kintsugi/rules.mk (limited to 'keyboards/adpenrose') diff --git a/keyboards/adpenrose/kintsugi/config.h b/keyboards/adpenrose/kintsugi/config.h new file mode 100644 index 0000000000..cbd38b6664 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/config.h @@ -0,0 +1,146 @@ +/* +Copyright 2021 adpenrose + +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 . +*/ + +#pragma once + +#include "config_common.h" + +/* USB Device descriptor parameter */ +#define VENDOR_ID 0x4450 // "ADP" +#define PRODUCT_ID 0x0001 // 'Cause it's my first keeb +#define DEVICE_VER 0x0001 +#define MANUFACTURER adpenrose +#define PRODUCT Kintsugi + +/* key matrix size */ +#define MATRIX_ROWS 10 +#define MATRIX_COLS 7 + +/* + * Keyboard Matrix Assignments + * + * Change this to how you wired your keyboard + * COLS: AVR pins used for columns, left to right + * ROWS: AVR pins used for rows, top to bottom + * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) + * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) + * + */ +#define MATRIX_ROW_PINS { B0, E6, D7, C6, D4, D2, F4, F5, B5, B4 } +#define MATRIX_COL_PINS { F6, F7, B1, B3, B2, B6, F0 } +#define UNUSED_PINS { D3, C7 } + +/* COL2ROW, ROW2COL */ +#define DIODE_DIRECTION COL2ROW + +/*Rotary encoder - set the resolution fitting your encoder. +Most will need a value of 4. If 1 encoder click results in 2 keycodes sent +increase the value. If you need 2 clicks for 1 keycode, decrease*/ +#define ENCODER_RESOLUTION 4 +#define ENCODERS_PAD_A { B7 } +#define ENCODERS_PAD_B { D5 } +#define TAP_CODE_DELAY 10 + +/* Underglow options: */ +#define RGB_DI_PIN F1 +#ifdef RGB_DI_PIN +# define RGBLED_NUM 16 +# define RGBLIGHT_HUE_STEP 8 +# define RGBLIGHT_SAT_STEP 8 +# define RGBLIGHT_VAL_STEP 8 +# define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */ +# define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */ +/*== all animations enable ==*/ +// # define RGBLIGHT_ANIMATIONS +/*== or choose animations ==*/ +# define RGBLIGHT_EFFECT_BREATHING +# define RGBLIGHT_EFFECT_RAINBOW_MOOD +# define RGBLIGHT_EFFECT_RAINBOW_SWIRL +# define RGBLIGHT_EFFECT_SNAKE +# define RGBLIGHT_EFFECT_KNIGHT +# define RGBLIGHT_EFFECT_CHRISTMAS +# define RGBLIGHT_EFFECT_STATIC_GRADIENT +# define RGBLIGHT_EFFECT_RGB_TEST +# define RGBLIGHT_EFFECT_ALTERNATING +/*== customize breathing effect ==*/ +/*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/ +//# define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64 +/*==== use exp() and sin() ====*/ +//# define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7 +//# define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255 +#endif + +/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ +#define DEBOUNCE 5 + +/* define if matrix has ghost (lacks anti-ghosting diodes) */ +//#define MATRIX_HAS_GHOST + +/* 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 + +/* If defined, GRAVE_ESC will always act as ESC when CTRL is held. + * This is useful for the Windows task manager shortcut (ctrl+shift+esc). + */ +//#define GRAVE_ESC_CTRL_OVERRIDE + +/* + * Force NKRO + * + * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved + * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the + * makefile for this to work.) + * + * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N) + * until the next keyboard reset. + * + * NKRO may prevent your keystrokes from being detected in the BIOS, but it is + * fully operational during normal computer usage. + * + * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N) + * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by + * bootmagic, NKRO mode will always be enabled until it is toggled again during a + * power-up. + * + */ +//#define FORCE_NKRO + +/* + * Feature disable options + * These options are also useful to firmware size reduction. + */ + +/* disable debug print */ +//#define NO_DEBUG + +/* disable print */ +//#define NO_PRINT + +/* disable action features */ +//#define NO_ACTION_LAYER +//#define NO_ACTION_TAPPING +//#define NO_ACTION_ONESHOT + +/* disable these deprecated features by default */ +#define NO_ACTION_MACRO +#define NO_ACTION_FUNCTION + +/* Bootmagic Lite key configuration */ +#define BOOTMAGIC_LITE_ROW 0 +#define BOOTMAGIC_LITE_COLUMN 0 diff --git a/keyboards/adpenrose/kintsugi/info.json b/keyboards/adpenrose/kintsugi/info.json new file mode 100644 index 0000000000..0e76187335 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/info.json @@ -0,0 +1,80 @@ +{ + "keyboard_name": "Kintsugi", + "url": "https://github.com/ADPenrose/kintsugi_keeb", + "maintainer": "adpenrose", + "layouts": { + "LAYOUT_65_ansi_blocker": { + "layout": [ + {"label":"Esc", "x":0, "y":0}, + {"label":"1", "x":1, "y":0}, + {"label":"2", "x":2, "y":0}, + {"label":"3", "x":3, "y":0}, + {"label":"4", "x":4, "y":0}, + {"label":"5", "x":5, "y":0}, + {"label":"6", "x":6, "y":0}, + {"label":"7", "x":7, "y":0}, + {"label":"8", "x":8, "y":0}, + {"label":"9", "x":9, "y":0}, + {"label":"0", "x":10, "y":0}, + {"label":"-", "x":11, "y":0}, + {"label":"=", "x":12, "y":0}, + {"label":"Backspace", "x":13, "y":0, "w":2}, + + {"label":"Tab", "x":0, "y":1, "w":1.5}, + {"label":"Q", "x":1.5, "y":1}, + {"label":"W", "x":2.5, "y":1}, + {"label":"E", "x":3.5, "y":1}, + {"label":"R", "x":4.5, "y":1}, + {"label":"T", "x":5.5, "y":1}, + {"label":"Y", "x":6.5, "y":1}, + {"label":"U", "x":7.5, "y":1}, + {"label":"I", "x":8.5, "y":1}, + {"label":"O", "x":9.5, "y":1}, + {"label":"P", "x":10.5, "y":1}, + {"label":"[", "x":11.5, "y":1}, + {"label":"]", "x":12.5, "y":1}, + {"label":"\\", "x":13.5, "y":1, "w":1.5}, + + {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, + {"label":"A", "x":1.75, "y":2}, + {"label":"S", "x":2.75, "y":2}, + {"label":"D", "x":3.75, "y":2}, + {"label":"F", "x":4.75, "y":2}, + {"label":"G", "x":5.75, "y":2}, + {"label":"H", "x":6.75, "y":2}, + {"label":"J", "x":7.75, "y":2}, + {"label":"K", "x":8.75, "y":2}, + {"label":"L", "x":9.75, "y":2}, + {"label":";", "x":10.75, "y":2}, + {"label":"'", "x":11.75, "y":2}, + {"label":"Enter", "x":12.75, "y":2, "w":2.25}, + {"label":"Enc", "x":15, "y":2}, + + {"label":"LShift", "x":0, "y":3, "w":2.25}, + {"label":"Z", "x":2.25, "y":3}, + {"label":"X", "x":3.25, "y":3}, + {"label":"C", "x":4.25, "y":3}, + {"label":"V", "x":5.25, "y":3}, + {"label":"B", "x":6.25, "y":3}, + {"label":"N", "x":7.25, "y":3}, + {"label":"M", "x":8.25, "y":3}, + {"label":",", "x":9.25, "y":3}, + {"label":".", "x":10.25, "y":3}, + {"label":"/", "x":11.25, "y":3}, + {"label":"RShift", "x":12.25, "y":3, "w":1.75}, + {"label":"Up", "x":14, "y":3}, + {"label":"M1", "x":15, "y":3}, + + {"label":"LCtrl", "x":0, "y":4, "w":1.25}, + {"label":"LSuper", "x":1.25, "y":4, "w":1.25}, + {"label":"LAlt", "x":2.5, "y":4, "w":1.25}, + {"label":"Space", "x":3.75, "y":4, "w":6.25}, + {"label":"L1", "x":10, "y":4, "w":1.5}, + {"label":"L2", "x":11.5, "y":4, "w":1.5}, + {"label":"Left", "x":13, "y":4}, + {"label":"Down", "x":14, "y":4}, + {"label":"Right", "x":15, "y":4} + ] + } + } +} diff --git a/keyboards/adpenrose/kintsugi/keymaps/default/keymap.c b/keyboards/adpenrose/kintsugi/keymaps/default/keymap.c new file mode 100644 index 0000000000..7e03701461 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/default/keymap.c @@ -0,0 +1,48 @@ +/* Copyright 2021 adpenrose + * + * 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 . + */ +#include QMK_KEYBOARD_H + +/* Base layout: + * ,---------------------------------------------------------------------| + * |` |1 |2 |3 |4 |5 |6 |7 |8 |9 |0 |- |= |Backspace| OLED| + * |--------------------------------------------------------------- | + * |Tab |Q |W |E |R |T |Y |U |I |O |P |[ | ] | \ OLED| + * |---------------------------------------------------------------------| + * |Caps |A |S |D |F |G |H |J |K |L |; |' | Enter | ENC | + * |---------------------------------------------------------------------| + * |Shft |Z |X |C |V |B |N |M |, |. |/ |Shift |Up| M1 | + * |---------------------------------------------------------------------| + * |Ctrl|GUI |Alt | Space |Alt |MO(1)| |Lt |Dn |Rt | + * `---------------------------------------------------------------------|' + */ + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [0] = LAYOUT_65_ansi_blocker( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, + KC_TAB, KC_A, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_MUTE, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_65_ansi_blocker( + _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, + _______, RGB_TOG, RGB_VAI, RGB_VAD, RGB_MODE_FORWARD, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPLY, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, KC_SPC, _______, _______, _______, _______, _______ + ), +}; \ No newline at end of file diff --git a/keyboards/adpenrose/kintsugi/keymaps/default/readme.md b/keyboards/adpenrose/kintsugi/keymaps/default/readme.md new file mode 100644 index 0000000000..83bc48086d --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/default/readme.md @@ -0,0 +1 @@ +# The default keymap for Kintsugi diff --git a/keyboards/adpenrose/kintsugi/keymaps/franky/keymap.c b/keyboards/adpenrose/kintsugi/keymaps/franky/keymap.c new file mode 100644 index 0000000000..55098afbfd --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/franky/keymap.c @@ -0,0 +1,164 @@ +/* Copyright 2021 adpenrose + * + * 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 . + */ +#include QMK_KEYBOARD_H + +/* Base layout: + * ,---------------------------------------------------------------------| + * |` |1 |2 |3 |4 |5 |6 |7 |8 |9 |0 |- |= |Backspace| OLED| + * |--------------------------------------------------------------- | + * |Tab |Q |W |E |R |T |Y |U |I |O |P |[ | ] | \ OLED| + * |---------------------------------------------------------------------| + * |Caps |A |S |D |F |G |H |J |K |L |; |' | Enter | ENC | + * |---------------------------------------------------------------------| + * |Shft |Z |X |C |V |B |N |M |, |. |/ |Shift |Up| M1 | + * |---------------------------------------------------------------------| + * |Ctrl|GUI |Alt | Space |MO(2) |MO(3)| |Lt |Dn |Rt | + * `---------------------------------------------------------------------|' + */ + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [0] = LAYOUT_65_ansi_blocker( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, + KC_LGUI, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_MUTE, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(2), MO(3), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_65_ansi_blocker( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + [2] = LAYOUT_65_ansi_blocker( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + [3] = LAYOUT_65_ansi_blocker( + _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPLY, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, KC_SPC, _______, _______, _______, _______, _______ + ), +}; + +/* Encoder */ +#ifdef ENCODER_ENABLE +bool encoder_update_user(uint8_t index, bool clockwise) { + static uint8_t selected_layer = 0; /* Used to change the layer using the encoder. */ + + if (clockwise){ + /* Check if left shift is pressed: */ + if (selected_layer < 3 && get_mods() & MOD_BIT(KC_LSFT)){ + selected_layer ++; + layer_move(selected_layer); /* Jump up one layer. */ + } else { + /* If shift isn't pressed, encoder will do this stuff: */ + switch (get_highest_layer(layer_state)){ + case 3: + tap_code(KC_MNXT); + break; + default: + tap_code(KC_VOLU); + break; + } + } + } else { + /* Check if left shift is pressed: */ + if (selected_layer > 0 && get_mods() & MOD_BIT(KC_LSFT)){ + selected_layer --; + layer_move(selected_layer); /* Go down one layer. */ + } else { + /* If shift isn't pressed, encoder will do this stuff: */ + switch (get_highest_layer(layer_state)){ + case 3: + tap_code(KC_MPRV); + break; + default: + tap_code(KC_VOLD); + break; + } + } + } + return false; +} +#endif + +/* Rotation of the OLED: */ +#ifdef OLED_ENABLE +/* Function that renders the kintsugi logo in the desired order. */ +static void render_logo(void) { + static const char PROGMEM logo_1[] = { + 0x83, 0x84, 0x85, 0x86, 0x87, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, 0x00 + }; + static const char PROGMEM logo_2[] = { + 0x88, 0x89, 0x8A, 0x8B, 0x8C, 0xA8, 0xA9, 0xAA, 0xAB, 0xAC, 0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0x00 + }; + static const char PROGMEM logo_3[] = { + 0x8D, 0x8E, 0x8F, 0x90, 0x91, 0xAD, 0xAE, 0xAF, 0xB0, 0xB1, 0xCD, 0xCE, 0xCF, 0xD0, 0xD1, 0x00 + }; + oled_set_cursor(1,0); + oled_write_P(logo_1, false); + oled_set_cursor(1,4); + oled_write_P(logo_2, false); + oled_set_cursor(1,8); + oled_write_P(logo_3, false); +} + +/* Function that renders the current layer to the user. */ +void render_layer(void) { + oled_set_cursor(0,12); + switch (get_highest_layer(layer_state)){ + case 0: + oled_write_P(PSTR("_BASE"), false); + break; + case 1: + oled_write_P(PSTR("_KCAD"), false); + break; + case 2: + oled_write_P(PSTR("_NMPD"), false); + break; + case 3: + oled_write_P(PSTR("_FNCT"), false); + break; + default: + oled_write_P(PSTR("_OhNo"), false); + break; + } +} + +/* The following function displays wpm to the user. */ +void render_wpm(void) { + oled_set_cursor(1,14); + oled_write(get_u8_str(get_current_wpm(), '0'), false); + oled_set_cursor(1,15); + oled_write_P(PSTR("WPM"), false); +} + +/* Function that renders stuff on the oled: */ +bool oled_task_user(void) { + render_logo(); + render_layer(); + render_wpm(); + return false; +} +#endif diff --git a/keyboards/adpenrose/kintsugi/keymaps/franky/readme.md b/keyboards/adpenrose/kintsugi/keymaps/franky/readme.md new file mode 100644 index 0000000000..9f44122306 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/franky/readme.md @@ -0,0 +1 @@ +# Franky keymap for Kintsugi. Here to serve as a way to test snippets of code. diff --git a/keyboards/adpenrose/kintsugi/keymaps/franky/rules.mk b/keyboards/adpenrose/kintsugi/keymaps/franky/rules.mk new file mode 100644 index 0000000000..7e72249a18 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/franky/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes +WPM_ENABLE = yes diff --git a/keyboards/adpenrose/kintsugi/keymaps/via/keymap.c b/keyboards/adpenrose/kintsugi/keymaps/via/keymap.c new file mode 100644 index 0000000000..80764047df --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/via/keymap.c @@ -0,0 +1,62 @@ +/* Copyright 2021 adpenrose + * + * 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 . + */ +#include QMK_KEYBOARD_H + +/* Base layout: + * ,---------------------------------------------------------------------| + * |` |1 |2 |3 |4 |5 |6 |7 |8 |9 |0 |- |= |Backspace| OLED| + * |--------------------------------------------------------------- | + * |Tab |Q |W |E |R |T |Y |U |I |O |P |[ | ] | \ OLED| + * |---------------------------------------------------------------------| + * |Caps |A |S |D |F |G |H |J |K |L |; |' | Enter | ENC | + * |---------------------------------------------------------------------| + * |Shft |Z |X |C |V |B |N |M |, |. |/ |Shift |Up| M1 | + * |---------------------------------------------------------------------| + * |Ctrl|GUI |Alt | Space |MO(2) |MO(3)| |Lt |Dn |Rt | + * `---------------------------------------------------------------------|' + */ + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* Base */ + [0] = LAYOUT_65_ansi_blocker( + KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, + KC_LGUI, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_MUTE, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_DEL, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, MO(1), MO(2), KC_LEFT, KC_DOWN, KC_RIGHT + ), + [1] = LAYOUT_65_ansi_blocker( + _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPLY, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, KC_SPC, _______, _______, _______, _______, _______ + ), + [2] = LAYOUT_65_ansi_blocker( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MNXT, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), + [3] = LAYOUT_65_ansi_blocker( + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______ + ), +}; diff --git a/keyboards/adpenrose/kintsugi/keymaps/via/readme.md b/keyboards/adpenrose/kintsugi/keymaps/via/readme.md new file mode 100644 index 0000000000..afdea1ca5b --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/via/readme.md @@ -0,0 +1 @@ +# VIA keymap for Kintsugi diff --git a/keyboards/adpenrose/kintsugi/keymaps/via/rules.mk b/keyboards/adpenrose/kintsugi/keymaps/via/rules.mk new file mode 100644 index 0000000000..36b7ba9cbc --- /dev/null +++ b/keyboards/adpenrose/kintsugi/keymaps/via/rules.mk @@ -0,0 +1,2 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes diff --git a/keyboards/adpenrose/kintsugi/kintsugi.c b/keyboards/adpenrose/kintsugi/kintsugi.c new file mode 100644 index 0000000000..c697793172 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/kintsugi.c @@ -0,0 +1,74 @@ +/* Copyright 2021 adpenrose + * + * 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 . + */ + +#include "kintsugi.h" + +/* Encoder */ +#ifdef ENCODER_ENABLE +bool encoder_update_kb(uint8_t index, bool clockwise) { + if (!encoder_update_user(index, clockwise)) { + return false; + } +/* The switch case allows for different encoder mappings on different layers, "default" map gets applied for all unspecified layers */ + switch(get_highest_layer(layer_state)){ + case 1: + if (clockwise) { + tap_code(KC_MNXT); + } else { + tap_code(KC_MPRV); + } + break; + default: + if (clockwise){ + tap_code(KC_VOLU); + } else{ + tap_code(KC_VOLD); + } + break; + } + return true; +} +#endif + +/* Rotation of the OLED: */ +#ifdef OLED_ENABLE +oled_rotation_t oled_init_user(oled_rotation_t rotation) { + return OLED_ROTATION_270; +} + +bool oled_task_kb(void) { + if (!oled_task_user()) { + return false; + } + /* Kintsugi logo render: */ + static const char PROGMEM logo_1[] = { + 0x83, 0x84, 0x85, 0x86, 0x87, 0xA3, 0xA4, 0xA5, 0xA6, 0xA7, 0xC3, 0xC4, 0xC5, 0xC6, 0xC7, 0x00 + }; + static const char PROGMEM logo_2[] = { + 0x88, 0x89, 0x8A, 0x8B, 0x8C, 0xA8, 0xA9, 0xAA, 0xAB, 0xAC, 0xC8, 0xC9, 0xCA, 0xCB, 0xCC, 0x00 + }; + static const char PROGMEM logo_3[] = { + 0x8D, 0x8E, 0x8F, 0x90, 0x91, 0xAD, 0xAE, 0xAF, 0xB0, 0xB1, 0xCD, 0xCE, 0xCF, 0xD0, 0xD1, 0x00 + }; + oled_set_cursor(1,3); + oled_write_P(logo_1, false); + oled_set_cursor(1,7); + oled_write_P(logo_2, false); + oled_set_cursor(1,11); + oled_write_P(logo_3, false); + return true; +} +#endif diff --git a/keyboards/adpenrose/kintsugi/kintsugi.h b/keyboards/adpenrose/kintsugi/kintsugi.h new file mode 100644 index 0000000000..37ce6cc6e5 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/kintsugi.h @@ -0,0 +1,46 @@ +/* Copyright 2021 adpenrose + * + * 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 . + */ + +#pragma once + +#include "quantum.h" + +/* This is 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_65_ansi_blocker( \ + K00, K01, K02, K03, K04, K05, K06, K50, K51, K52, K53, K54, K55, K56, \ + K10, K11, K12, K13, K14, K15, K16, K60, K61, K62, K63, K64, K65, K66, \ + K20, K21, K22, K23, K24, K25, K26, K70, K71, K72, K73, K74, K75, K76, \ + K30, K31, K32, K33, K34, K35, K36, K80, K81, K82, K83, K84, K85, K86, \ + K40, K41, K42, K46, K92, K93, K94, K95, K96 \ +) { \ + { K00, K01, K02, K03, K04, K05, K06 }, \ + { K10, K11, K12, K13, K14, K15, K16 }, \ + { K20, K21, K22, K23, K24, K25, K26 }, \ + { K30, K31, K32, K33, K34, K35, K36 }, \ + { K40, K41, K42, KC_NO, KC_NO, KC_NO, K46 }, \ + { K50, K51, K52, K53, K54, K55, K56 }, \ + { K60, K61, K62, K63, K64, K65, K66 }, \ + { K70, K71, K72, K73, K74, K75, K76 }, \ + { K80, K81, K82, K83, K84, K85, K86 }, \ + { KC_NO, KC_NO, K92, K93, K94, K95, K96 } \ +} diff --git a/keyboards/adpenrose/kintsugi/lib/kintsugifont.c b/keyboards/adpenrose/kintsugi/lib/kintsugifont.c new file mode 100644 index 0000000000..bfa05d53a4 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/lib/kintsugifont.c @@ -0,0 +1,244 @@ +/* Copyright 2021 adpenrose + * + * 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 . + */ + +#include "progmem.h" + +const unsigned char font[] PROGMEM = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3E, 0x5B, 0x4F, 0x5B, 0x3E, 0x00, + 0x3E, 0x6B, 0x4F, 0x6B, 0x3E, 0x00, + 0x1C, 0x3E, 0x7C, 0x3E, 0x1C, 0x00, + 0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x00, + 0x1C, 0x57, 0x7D, 0x57, 0x1C, 0x00, + 0x1C, 0x5E, 0x7F, 0x5E, 0x1C, 0x00, + 0x00, 0x18, 0x3C, 0x18, 0x00, 0x00, + 0xFF, 0xE7, 0xC3, 0xE7, 0xFF, 0x00, + 0x00, 0x18, 0x24, 0x18, 0x00, 0x00, + 0xFF, 0xE7, 0xDB, 0xE7, 0xFF, 0x00, + 0x30, 0x48, 0x3A, 0x06, 0x0E, 0x00, + 0x26, 0x29, 0x79, 0x29, 0x26, 0x00, + 0x40, 0x7F, 0x05, 0x05, 0x07, 0x00, + 0x40, 0x7F, 0x05, 0x25, 0x3F, 0x00, + 0x5A, 0x3C, 0xE7, 0x3C, 0x5A, 0x00, + 0x7F, 0x3E, 0x1C, 0x1C, 0x08, 0x00, + 0x08, 0x1C, 0x1C, 0x3E, 0x7F, 0x00, + 0x14, 0x22, 0x7F, 0x22, 0x14, 0x00, + 0x5F, 0x5F, 0x00, 0x5F, 0x5F, 0x00, + 0x06, 0x09, 0x7F, 0x01, 0x7F, 0x00, + 0x00, 0x66, 0x89, 0x95, 0x6A, 0x00, + 0x60, 0x60, 0x60, 0x60, 0x60, 0x00, + 0x94, 0xA2, 0xFF, 0xA2, 0x94, 0x00, + 0x08, 0x04, 0x7E, 0x04, 0x08, 0x00, + 0x10, 0x20, 0x7E, 0x20, 0x10, 0x00, + 0x08, 0x08, 0x2A, 0x1C, 0x08, 0x00, + 0x08, 0x1C, 0x2A, 0x08, 0x08, 0x00, + 0x1E, 0x10, 0x10, 0x10, 0x10, 0x00, + 0x0C, 0x1E, 0x0C, 0x1E, 0x0C, 0x00, + 0x30, 0x38, 0x3E, 0x38, 0x30, 0x00, + 0x06, 0x0E, 0x3E, 0x0E, 0x06, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x5F, 0x00, 0x00, 0x00, + 0x00, 0x07, 0x00, 0x07, 0x00, 0x00, + 0x14, 0x7F, 0x14, 0x7F, 0x14, 0x00, + 0x24, 0x2A, 0x7F, 0x2A, 0x12, 0x00, + 0x23, 0x13, 0x08, 0x64, 0x62, 0x00, + 0x36, 0x49, 0x56, 0x20, 0x50, 0x00, + 0x00, 0x08, 0x07, 0x03, 0x00, 0x00, + 0x00, 0x1C, 0x22, 0x41, 0x00, 0x00, + 0x00, 0x41, 0x22, 0x1C, 0x00, 0x00, + 0x2A, 0x1C, 0x7F, 0x1C, 0x2A, 0x00, + 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, + 0x00, 0x80, 0x70, 0x30, 0x00, 0x00, + 0x08, 0x08, 0x08, 0x08, 0x08, 0x00, + 0x00, 0x00, 0x60, 0x60, 0x00, 0x00, + 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, + 0x3E, 0x51, 0x49, 0x45, 0x3E, 0x00, + 0x00, 0x42, 0x7F, 0x40, 0x00, 0x00, + 0x72, 0x49, 0x49, 0x49, 0x46, 0x00, + 0x21, 0x41, 0x49, 0x4D, 0x33, 0x00, + 0x18, 0x14, 0x12, 0x7F, 0x10, 0x00, + 0x27, 0x45, 0x45, 0x45, 0x39, 0x00, + 0x3C, 0x4A, 0x49, 0x49, 0x31, 0x00, + 0x41, 0x21, 0x11, 0x09, 0x07, 0x00, + 0x36, 0x49, 0x49, 0x49, 0x36, 0x00, + 0x46, 0x49, 0x49, 0x29, 0x1E, 0x00, + 0x00, 0x00, 0x14, 0x00, 0x00, 0x00, + 0x00, 0x40, 0x34, 0x00, 0x00, 0x00, + 0x00, 0x08, 0x14, 0x22, 0x41, 0x00, + 0x14, 0x14, 0x14, 0x14, 0x14, 0x00, + 0x00, 0x41, 0x22, 0x14, 0x08, 0x00, + 0x02, 0x01, 0x59, 0x09, 0x06, 0x00, + 0x3E, 0x41, 0x5D, 0x59, 0x4E, 0x00, + 0x7C, 0x12, 0x11, 0x12, 0x7C, 0x00, + 0x7F, 0x49, 0x49, 0x49, 0x36, 0x00, + 0x3E, 0x41, 0x41, 0x41, 0x22, 0x00, + 0x7F, 0x41, 0x41, 0x41, 0x3E, 0x00, + 0x7F, 0x49, 0x49, 0x49, 0x41, 0x00, + 0x7F, 0x09, 0x09, 0x09, 0x01, 0x00, + 0x3E, 0x41, 0x41, 0x51, 0x73, 0x00, + 0x7F, 0x08, 0x08, 0x08, 0x7F, 0x00, + 0x00, 0x41, 0x7F, 0x41, 0x00, 0x00, + 0x20, 0x40, 0x41, 0x3F, 0x01, 0x00, + 0x7F, 0x08, 0x14, 0x22, 0x41, 0x00, + 0x7F, 0x40, 0x40, 0x40, 0x40, 0x00, + 0x7F, 0x02, 0x1C, 0x02, 0x7F, 0x00, + 0x7F, 0x04, 0x08, 0x10, 0x7F, 0x00, + 0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00, + 0x7F, 0x09, 0x09, 0x09, 0x06, 0x00, + 0x3E, 0x41, 0x51, 0x21, 0x5E, 0x00, + 0x7F, 0x09, 0x19, 0x29, 0x46, 0x00, + 0x26, 0x49, 0x49, 0x49, 0x32, 0x00, + 0x03, 0x01, 0x7F, 0x01, 0x03, 0x00, + 0x3F, 0x40, 0x40, 0x40, 0x3F, 0x00, + 0x1F, 0x20, 0x40, 0x20, 0x1F, 0x00, + 0x3F, 0x40, 0x38, 0x40, 0x3F, 0x00, + 0x63, 0x14, 0x08, 0x14, 0x63, 0x00, + 0x03, 0x04, 0x78, 0x04, 0x03, 0x00, + 0x61, 0x59, 0x49, 0x4D, 0x43, 0x00, + 0x00, 0x7F, 0x41, 0x41, 0x41, 0x00, + 0x02, 0x04, 0x08, 0x10, 0x20, 0x00, + 0x00, 0x41, 0x41, 0x41, 0x7F, 0x00, + 0x04, 0x02, 0x01, 0x02, 0x04, 0x00, + 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, + 0x00, 0x03, 0x07, 0x08, 0x00, 0x00, + 0x20, 0x54, 0x54, 0x78, 0x40, 0x00, + 0x7F, 0x28, 0x44, 0x44, 0x38, 0x00, + 0x38, 0x44, 0x44, 0x44, 0x28, 0x00, + 0x38, 0x44, 0x44, 0x28, 0x7F, 0x00, + 0x38, 0x54, 0x54, 0x54, 0x18, 0x00, + 0x00, 0x08, 0x7E, 0x09, 0x02, 0x00, + 0x18, 0xA4, 0xA4, 0x9C, 0x78, 0x00, + 0x7F, 0x08, 0x04, 0x04, 0x78, 0x00, + 0x00, 0x44, 0x7D, 0x40, 0x00, 0x00, + 0x20, 0x40, 0x40, 0x3D, 0x00, 0x00, + 0x7F, 0x10, 0x28, 0x44, 0x00, 0x00, + 0x00, 0x41, 0x7F, 0x40, 0x00, 0x00, + 0x7C, 0x04, 0x78, 0x04, 0x78, 0x00, + 0x7C, 0x08, 0x04, 0x04, 0x78, 0x00, + 0x38, 0x44, 0x44, 0x44, 0x38, 0x00, + 0x7C, 0x18, 0x24, 0x24, 0x18, 0x00, + 0x18, 0x24, 0x24, 0x18, 0x7C, 0x00, + 0x7C, 0x08, 0x04, 0x04, 0x08, 0x00, + 0x48, 0x54, 0x54, 0x54, 0x24, 0x00, + 0x04, 0x04, 0x3F, 0x44, 0x24, 0x00, + 0x3C, 0x40, 0x40, 0x20, 0x7C, 0x00, + 0x1C, 0x20, 0x40, 0x20, 0x1C, 0x00, + 0x3C, 0x40, 0x30, 0x40, 0x3C, 0x00, + 0x44, 0x28, 0x10, 0x28, 0x44, 0x00, + 0x4C, 0x90, 0x90, 0x90, 0x7C, 0x00, + 0x44, 0x64, 0x54, 0x4C, 0x44, 0x00, + 0x00, 0x08, 0x36, 0x41, 0x00, 0x00, + 0x00, 0x00, 0x77, 0x00, 0x00, 0x00, + 0x00, 0x41, 0x36, 0x08, 0x00, 0x00, + 0x02, 0x01, 0x02, 0x04, 0x02, 0x00, + 0x3C, 0x26, 0x23, 0x26, 0x3C, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x80, 0xC0, 0xC0, + 0xE0, 0xF0, 0xF0, 0xF8, 0xFC, 0xBC, + 0x9E, 0x9E, 0xBC, 0xFC, 0xF8, 0xF0, + 0xF0, 0xE0, 0xC0, 0xC0, 0x80, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x80, 0xC0, 0xF0, 0xFC, 0xFE, 0x8E, + 0xE6, 0x70, 0x00, 0xFC, 0xFE, 0xFE, + 0xFC, 0x00, 0x38, 0x78, 0xF0, 0xFE, + 0xFE, 0xF0, 0x78, 0x38, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x78, 0x78, 0x78, 0x78, 0x78, + 0x78, 0x78, 0x7E, 0x7E, 0xFE, 0xFC, + 0xFC, 0x7C, 0x18, 0x00, 0x9E, 0xBC, + 0x1C, 0x02, 0x0F, 0x1E, 0x0C, 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, + 0xE0, 0xF0, 0xF0, 0xF0, 0xE0, 0xEC, + 0xEE, 0xF7, 0xF3, 0x70, 0x20, 0x00, + 0x7C, 0x7C, 0x7C, 0x7E, 0x00, 0x7E, + 0x7E, 0x7E, 0x7F, 0x7F, 0x7F, 0x00, + 0x00, 0x80, 0xC0, 0xE0, 0x7E, 0x5B, + 0x4F, 0x5B, 0xFE, 0xC0, 0x00, 0x00, + 0xC0, 0x00, 0xDC, 0xD7, 0xDE, 0xDE, + 0xDE, 0xD7, 0xDC, 0x00, 0xC0, 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, 0x01, 0xE1, 0xE1, 0xE1, + 0xE1, 0xE3, 0xE7, 0xE7, 0xE3, 0xE3, + 0xFF, 0xFF, 0xE3, 0xE3, 0xE7, 0xE7, + 0xE3, 0xE1, 0xE1, 0xE1, 0xE1, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x40, 0xF1, 0xFB, 0xFF, 0xFF, 0xE7, + 0xF3, 0xF8, 0x00, 0xFF, 0xFF, 0xFF, + 0xFF, 0x87, 0xC7, 0xE7, 0xFF, 0xFF, + 0xFF, 0xFF, 0xE7, 0xC7, 0x87, 0x07, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x8E, 0x9E, 0x9E, 0x1E, 0x1E, + 0x1E, 0x1E, 0x1E, 0x1E, 0x9F, 0xDF, + 0xFF, 0xFF, 0xFE, 0xCF, 0x0F, 0x0F, + 0x07, 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, + 0x0F, 0x1F, 0x3F, 0x7F, 0x7F, 0x7F, + 0x7F, 0x7F, 0x3F, 0x1E, 0x0C, 0x00, + 0x1F, 0x1F, 0x1F, 0x3F, 0x00, 0x3F, + 0x3F, 0x3F, 0x7F, 0x7F, 0x7F, 0x00, + 0x30, 0x7B, 0x7F, 0x78, 0x30, 0x20, + 0x20, 0x30, 0x78, 0x7F, 0x3B, 0x00, + 0x03, 0x00, 0x0F, 0x7F, 0x0F, 0x0F, + 0x0F, 0x7F, 0x0F, 0x00, 0x03, 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, 0x70, 0x70, 0x71, 0x73, + 0x73, 0x7F, 0x7E, 0x7C, 0x70, 0x70, + 0x7F, 0x7F, 0x70, 0x70, 0x7C, 0x7E, + 0x7F, 0x73, 0x73, 0x71, 0x70, 0x70, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x60, 0x7C, 0x3E, 0x01, 0x3E, 0x61, + 0x0E, 0x1E, 0x00, 0x3F, 0x7F, 0x7F, + 0x7F, 0x73, 0x73, 0x71, 0x70, 0x77, + 0x77, 0x70, 0x71, 0x73, 0x73, 0x73, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x1F, 0x7F, 0x7F, 0x78, 0x78, + 0x78, 0x78, 0x78, 0x78, 0x79, 0x7B, + 0x7B, 0x7B, 0x03, 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, +}; diff --git a/keyboards/adpenrose/kintsugi/post_config.h b/keyboards/adpenrose/kintsugi/post_config.h new file mode 100644 index 0000000000..e1f92f9e60 --- /dev/null +++ b/keyboards/adpenrose/kintsugi/post_config.h @@ -0,0 +1,21 @@ +/* +Copyright 2021 adpenrose + +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 . +*/ + +#ifndef OLED_FONT_H +# define OLED_FONT_H "lib/kintsugifont.c" +# define OLED_TIMEOUT 120000 +#endif \ No newline at end of file diff --git a/keyboards/adpenrose/kintsugi/readme.md b/keyboards/adpenrose/kintsugi/readme.md new file mode 100644 index 0000000000..2aa402543e --- /dev/null +++ b/keyboards/adpenrose/kintsugi/readme.md @@ -0,0 +1,37 @@ +# Kintsugi + +![kintsugi](https://i.imgur.com/HPdmzdCl.jpeg) + +A 65%-ish keyboard with some extra features. + +## Features + +* Powered by an ATmega32u4 microcontroller (current version needs an Elite-C to work). +* Encoder. +* OLED screen. +* Underglow. +* Hotswap sockets. + +## General info + +* Keyboard Maintainer: [Arturo Avila](https://github.com/ADPenrose) +* Hardware Supported: Kintsugi V1 PCB +* Hardware Availability: [Arturo Avila](https://github.com/ADPenrose) + +Make example for this keyboard (after setting up your build environment): + + make kintsugi:default + +Flashing example for this keyboard: + + make kintsugi: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 in 3 ways: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard +* **Physical reset button**: Briefly press the button on the front of the Elite-C microcontroller _**before soldering**_ it to the PCB- some may have pads you must short instead +* **Keycode in layout**: Press the key mapped to `RESET` if it is available diff --git a/keyboards/adpenrose/kintsugi/rules.mk b/keyboards/adpenrose/kintsugi/rules.mk new file mode 100644 index 0000000000..fe95a9b72b --- /dev/null +++ b/keyboards/adpenrose/kintsugi/rules.mk @@ -0,0 +1,21 @@ +# MCU name +MCU = atmega32u4 + +# Bootloader selection +BOOTLOADER = atmel-dfu + +# Build Options +# change yes to no to disable +# +BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite +MOUSEKEY_ENABLE = no # Mouse keys +EXTRAKEY_ENABLE = yes # Audio control and System control +CONSOLE_ENABLE = no # Console for debug +COMMAND_ENABLE = no # Commands for debug and configuration +NKRO_ENABLE = no # Enable N-Key Rollover +BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality +RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow +AUDIO_ENABLE = no # Audio output +ENCODER_ENABLE = yes # Encoder functionality +OLED_ENABLE = yes # OLED functionality +OLED_DRIVER = SSD1306 -- cgit v1.2.3