From 7e8abdb09d0eb0c0a73213bb141099dfcbfe19f8 Mon Sep 17 00:00:00 2001 From: Fernando Birra Date: Wed, 22 Nov 2023 12:25:49 +0000 Subject: [PATCH] [Keyboard] Add RK61 RGB dual mode & RK68 RGB dual mode keyboards (#363) * Added support for RK61-RGB * Added readme.md * Fixed some typos. * Minor changes to VIA keymap * Added support for RK68 (RK855) with VID 0C45 and PID 024F or 8008 * Moved RESET to Fn+CTRL on RK61-RGB * Corrected RGB LED pin order * Updated readme.md file * Moved readme.md images to cloud * Keymap changes * Moved RGB coords and flags into info.json * Removed unnecessary define for maximum brightness (default value is identical) * Update keyboards/royal_kludge/rk61_rgb/config_led.h Removed outdated defines not needed. Co-authored-by: dexter93 * Removed outdated defines not needed. * Removed NKRO force option * Removed leftover flag * Updated license header and added missing one * Removed empty VIA layers as they are automatically added. * Update keyboards/royal_kludge/rk61_rgb/config_led.h Removed obsolete flags. Co-authored-by: dexter93 * Moved Led coords and flags into info.json * Cleanup * Moved _user function into keymaps. Small corrections * More cleanup * Update keyboards/royal_kludge/rk68_rgb/rules.mk removing file no longer needed Co-authored-by: dexter93 * Code cleanup * Moved layout limits into config.h * Moved layer count limit to specific via keymap folder. --------- Co-authored-by: dexter93 --- keyboards/royal_kludge/rk61_rgb/config.h | 27 +++ keyboards/royal_kludge/rk61_rgb/info.json | 191 ++++++++++++++++ .../rk61_rgb/keymaps/default/keymap.c | 42 ++++ .../rk61_rgb/keymaps/via/keymap.c | 42 ++++ .../rk61_rgb/keymaps/via/rk61-rgb_via.json | 16 ++ .../rk61_rgb/keymaps/via/rules.mk | 1 + keyboards/royal_kludge/rk61_rgb/readme.md | 39 ++++ keyboards/royal_kludge/rk61_rgb/rules.mk | 3 + keyboards/royal_kludge/rk68_rgb/config.h | 27 +++ keyboards/royal_kludge/rk68_rgb/info.json | 204 ++++++++++++++++++ .../rk68_rgb/keymaps/default/keymap.c | 42 ++++ .../rk68_rgb/keymaps/via/config.h | 19 ++ .../rk68_rgb/keymaps/via/keymap.c | 42 ++++ .../rk68_rgb/keymaps/via/rk68-rgb_via.json | 16 ++ .../rk68_rgb/keymaps/via/rules.mk | 1 + keyboards/royal_kludge/rk68_rgb/readme.md | 59 +++++ keyboards/royal_kludge/rk68_rgb/rules.mk | 3 + 17 files changed, 774 insertions(+) create mode 100644 keyboards/royal_kludge/rk61_rgb/config.h create mode 100644 keyboards/royal_kludge/rk61_rgb/info.json create mode 100644 keyboards/royal_kludge/rk61_rgb/keymaps/default/keymap.c create mode 100644 keyboards/royal_kludge/rk61_rgb/keymaps/via/keymap.c create mode 100644 keyboards/royal_kludge/rk61_rgb/keymaps/via/rk61-rgb_via.json create mode 100644 keyboards/royal_kludge/rk61_rgb/keymaps/via/rules.mk create mode 100644 keyboards/royal_kludge/rk61_rgb/readme.md create mode 100644 keyboards/royal_kludge/rk61_rgb/rules.mk create mode 100644 keyboards/royal_kludge/rk68_rgb/config.h create mode 100644 keyboards/royal_kludge/rk68_rgb/info.json create mode 100644 keyboards/royal_kludge/rk68_rgb/keymaps/default/keymap.c create mode 100644 keyboards/royal_kludge/rk68_rgb/keymaps/via/config.h create mode 100644 keyboards/royal_kludge/rk68_rgb/keymaps/via/keymap.c create mode 100644 keyboards/royal_kludge/rk68_rgb/keymaps/via/rk68-rgb_via.json create mode 100644 keyboards/royal_kludge/rk68_rgb/keymaps/via/rules.mk create mode 100644 keyboards/royal_kludge/rk68_rgb/readme.md create mode 100644 keyboards/royal_kludge/rk68_rgb/rules.mk diff --git a/keyboards/royal_kludge/rk61_rgb/config.h b/keyboards/royal_kludge/rk61_rgb/config.h new file mode 100644 index 000000000000..85b96fecd5ea --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/config.h @@ -0,0 +1,27 @@ +/* Copyright (C) 2023 Benjamín Ausensi + * + * 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 + +/* RGB matrix configuration can't be fully expressed in JSON as of now */ +#define SN32_RGB_MATRIX_ROW_PINS { C5, C6, C4, C8, C9, C7, C11, C12, C10, C14, B13, C13, B15, B14, D3 } + +/* Enable additional RGB effects */ +#define RGB_MATRIX_FRAMEBUFFER_EFFECTS +#define RGB_MATRIX_KEYPRESSES + +/* Configure the effects: */ +#define RGB_MATRIX_TYPING_HEATMAP_DECREASE_DELAY_MS 50 \ No newline at end of file diff --git a/keyboards/royal_kludge/rk61_rgb/info.json b/keyboards/royal_kludge/rk61_rgb/info.json new file mode 100644 index 000000000000..85382f3a7ca3 --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/info.json @@ -0,0 +1,191 @@ +{ + "keyboard_name": "RK61-RGB", + "manufacturer": "Royal Kludge", + "url": "http://en.rkgaming.com", + "maintainer": "fpb", + "bootloader": "sn32-dfu", + + "processor": "SN32F248BF", + "usb": { + "vid": "0x0C45", + "pid": "0x8016", + "device_version": "1.0.0" + }, + + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": false, + "nkro": true, + "rgb_matrix": true + }, + + "debounce": 5, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": [ "A8", "A9", "A10", "A11", "A12", "A13", "A14", "A15", "B0", "B1", "B2", "B3", "B4", "B5" ], + "rows": [ "D11", "D10", "D9", "D8", "D7" ] + }, + + + "rgb_matrix": { + "animations": { + "band_val" : true, + "breathing" : true, + "cycle_left_right" : true, + "cycle_pinwheel" : true, + "cycle_spiral" : true, + "digital_rain" : true, + "gradient_left_right" : true, + "gradient_up_down" : true, + "raindrops" : true, + "solid_reactive_simple" : true, + "splash" : true, + "typing_heatmap" : true + }, + "driver": "sn32f24xb", + "layout": [ + { "matrix":[0, 0], "flags":4, "x":0, "y":0 }, + { "matrix":[0, 1], "flags":4, "x":16, "y":0 }, + { "matrix":[0, 2], "flags":4, "x":32, "y":0 }, + { "matrix":[0, 3], "flags":4, "x":48, "y":0 }, + { "matrix":[0, 4], "flags":4, "x":64, "y":0 }, + { "matrix":[0, 5], "flags":4, "x":80, "y":0 }, + { "matrix":[0, 6], "flags":4, "x":96, "y":0 }, + { "matrix":[0, 7], "flags":4, "x":112, "y":0 }, + { "matrix":[0, 8], "flags":4, "x":128, "y":0 }, + { "matrix":[0, 9], "flags":4, "x":144, "y":0 }, + { "matrix":[0, 10], "flags":4, "x":160, "y":0 }, + { "matrix":[0, 11], "flags":4, "x":176, "y":0 }, + { "matrix":[0, 12], "flags":4, "x":192, "y":0 }, + { "matrix":[0, 13], "flags":4, "x":208, "y":0 }, + + { "matrix":[1, 0], "flags":4, "x":4, "y":16 }, + { "matrix":[1, 1], "flags":4, "x":24, "y":16 }, + { "matrix":[1, 2], "flags":4, "x":40, "y":16 }, + { "matrix":[1, 3], "flags":4, "x":56, "y":16 }, + { "matrix":[1, 4], "flags":4, "x":72, "y":16 }, + { "matrix":[1, 5], "flags":4, "x":88, "y":16 }, + { "matrix":[1, 6], "flags":4, "x":104, "y":16 }, + { "matrix":[1, 7], "flags":4, "x":120, "y":16 }, + { "matrix":[1, 8], "flags":4, "x":136, "y":16 }, + { "matrix":[1, 9], "flags":4, "x":152, "y":16 }, + { "matrix":[1, 10], "flags":4, "x":168, "y":16 }, + { "matrix":[1, 11], "flags":4, "x":184, "y":16 }, + { "matrix":[1, 12], "flags":4, "x":200, "y":16 }, + { "matrix":[1, 13], "flags":4, "x":216, "y":16 }, + + { "matrix":[2, 0], "flags":4, "x":6, "y":32 }, + { "matrix":[2, 1], "flags":4, "x":28, "y":32 }, + { "matrix":[2, 2], "flags":4, "x":44, "y":32 }, + { "matrix":[2, 3], "flags":4, "x":60, "y":32 }, + { "matrix":[2, 4], "flags":4, "x":76, "y":32 }, + { "matrix":[2, 5], "flags":4, "x":92, "y":32 }, + { "matrix":[2, 6], "flags":4, "x":108, "y":32 }, + { "matrix":[2, 7], "flags":4, "x":124, "y":32 }, + { "matrix":[2, 8], "flags":4, "x":140, "y":32 }, + { "matrix":[2, 9], "flags":4, "x":156, "y":32 }, + { "matrix":[2, 10], "flags":4, "x":172, "y":32 }, + { "matrix":[2, 11], "flags":4, "x":188, "y":32 }, + { "matrix":[2, 13], "flags":4, "x":204, "y":32 }, + + { "matrix":[3, 0], "flags":4, "x":10, "y":48 }, + { "matrix":[3, 2], "flags":4, "x":36, "y":48 }, + { "matrix":[3, 3], "flags":4, "x":52, "y":48 }, + { "matrix":[3, 4], "flags":4, "x":68, "y":48 }, + { "matrix":[3, 5], "flags":4, "x":84, "y":48 }, + { "matrix":[3, 6], "flags":4, "x":100, "y":48 }, + { "matrix":[3, 7], "flags":4, "x":116, "y":48 }, + { "matrix":[3, 8], "flags":4, "x":132, "y":48 }, + { "matrix":[3, 9], "flags":4, "x":148, "y":48 }, + { "matrix":[3, 10], "flags":4, "x":164, "y":48 }, + { "matrix":[3, 11], "flags":4, "x":180, "y":48 }, + { "matrix":[3, 12], "flags":4, "x":196, "y":48 }, + + { "matrix":[4, 0], "flags":4, "x":2, "y":64 }, + { "matrix":[4, 1], "flags":4, "x":22, "y":64 }, + { "matrix":[4, 2], "flags":4, "x":42, "y":64 }, + { "matrix":[4, 6], "flags":4, "x":102, "y":64 }, + { "matrix":[4, 9], "flags":4, "x":162, "y":64 }, + { "matrix":[4, 10], "flags":4, "x":182, "y":64 }, + { "matrix":[4, 11], "flags":4, "x":202, "y":64 }, + { "matrix":[4, 13], "flags":4, "x":222, "y":64 } + ] + }, + + "layouts": { + "LAYOUT_60_ansi": { + "layout": [ + { "matrix":[0, 0], "x":0, "y":0 }, + { "matrix":[0, 1], "x":1, "y":0 }, + { "matrix":[0, 2], "x":2, "y":0 }, + { "matrix":[0, 3], "x":3, "y":0 }, + { "matrix":[0, 4], "x":4, "y":0 }, + { "matrix":[0, 5], "x":5, "y":0 }, + { "matrix":[0, 6], "x":6, "y":0 }, + { "matrix":[0, 7], "x":7, "y":0 }, + { "matrix":[0, 8], "x":8, "y":0 }, + { "matrix":[0, 9], "x":9, "y":0 }, + { "matrix":[0, 10], "x":10, "y":0 }, + { "matrix":[0, 11], "x":11, "y":0 }, + { "matrix":[0, 12], "x":12, "y":0 }, + { "matrix":[0, 13], "x":13, "y":0, "w":2 }, + + { "matrix":[1, 0], "x":0, "y":1, "w":1.5 }, + { "matrix":[1, 1], "x":1.5, "y":1 }, + { "matrix":[1, 2], "x":2.5, "y":1 }, + { "matrix":[1, 3], "x":3.5, "y":1 }, + { "matrix":[1, 4], "x":4.5, "y":1 }, + { "matrix":[1, 5], "x":5.5, "y":1 }, + { "matrix":[1, 6], "x":6.5, "y":1 }, + { "matrix":[1, 7], "x":7.5, "y":1 }, + { "matrix":[1, 8], "x":8.5, "y":1 }, + { "matrix":[1, 9], "x":9.5, "y":1 }, + { "matrix":[1, 10], "x":10.5, "y":1 }, + { "matrix":[1, 11], "x":11.5, "y":1 }, + { "matrix":[1, 12], "x":12.5, "y":1 }, + { "matrix":[1, 13], "x":13.5, "y":1, "w":1.5 }, + + { "matrix":[2, 0], "x":0, "y":2, "w":1.75 }, + { "matrix":[2, 1], "x":1.75, "y":2 }, + { "matrix":[2, 2], "x":2.75, "y":2 }, + { "matrix":[2, 3], "x":3.75, "y":2 }, + { "matrix":[2, 4], "x":4.75, "y":2 }, + { "matrix":[2, 5], "x":5.75, "y":2 }, + { "matrix":[2, 6], "x":6.75, "y":2 }, + { "matrix":[2, 7], "x":7.75, "y":2 }, + { "matrix":[2, 8], "x":8.75, "y":2 }, + { "matrix":[2, 9], "x":9.75, "y":2 }, + { "matrix":[2, 10], "x":10.75, "y":2 }, + { "matrix":[2, 11], "x":11.75, "y":2 }, + { "matrix":[2, 13], "x":12.75, "y":2, "w":2.25 }, + + { "matrix":[3, 0], "x":0, "y":3, "w":2.25 }, + { "matrix":[3, 2], "x":2.25, "y":3 }, + { "matrix":[3, 3], "x":3.25, "y":3 }, + { "matrix":[3, 4], "x":4.25, "y":3 }, + { "matrix":[3, 5], "x":5.25, "y":3 }, + { "matrix":[3, 6], "x":6.25, "y":3 }, + { "matrix":[3, 7], "x":7.25, "y":3 }, + { "matrix":[3, 8], "x":8.25, "y":3 }, + { "matrix":[3, 9], "x":9.25, "y":3 }, + { "matrix":[3, 10], "x":10.25, "y":3 }, + { "matrix":[3, 11], "x":11.25, "y":3 }, + { "matrix":[3, 12], "x":12.25, "y":3, "w":2.75 }, + + { "matrix":[4, 0], "x":0, "y":4, "w":1.25 }, + { "matrix":[4, 1], "x":1.25, "y":4, "w":1.25 }, + { "matrix":[4, 2], "x":2.5, "y":4, "w":1.25 }, + { "matrix":[4, 6], "x":3.75, "y":4, "w":6.25 }, + { "matrix":[4, 9], "x":10, "y":4, "w":1.25 }, + { "matrix":[4, 10], "x":11.25, "y":4, "w":1.25 }, + { "matrix":[4, 11], "x":12.5, "y":4, "w":1.25 }, + { "matrix":[4, 13], "x":13.75, "y":4, "w":1.25 } + ] + } + } +} diff --git a/keyboards/royal_kludge/rk61_rgb/keymaps/default/keymap.c b/keyboards/royal_kludge/rk61_rgb/keymaps/default/keymap.c new file mode 100644 index 000000000000..f5da0c54a565 --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/keymaps/default/keymap.c @@ -0,0 +1,42 @@ +/* Copyright (C) 2023 Benjamín Ausensi + * + * 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 + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_ansi( + 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_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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_LCTL, KC_LALT, KC_LCMD, KC_SPC, KC_RCMD, KC_RALT, KC_RCTL, MO(1) + ), + [1] = LAYOUT_60_ansi( + KC_GRV, 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, + KC_TRNS, KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_PSCR, KC_SCRL, KC_PAUS, RGB_HUD, RGB_HUI, RGB_VAD, RGB_VAI, RGB_MOD, + KC_TRNS, AG_SWAP, AG_NORM, KC_TRNS, KC_TRNS, KC_TRNS, KC_INS, KC_HOME, KC_PGUP, KC_TRNS, RGB_SPD, RGB_SPI, KC_TRNS, + KC_TRNS, KC_MUTE, KC_VOLD, KC_VOLU, KC_MPRV, KC_MNXT, KC_DEL, KC_END, KC_PGDN, RGB_HUI, KC_UP, KC_TRNS, + QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RIGHT, KC_TRNS + ) +}; + +bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { + if (host_keyboard_led_state().caps_lock) { + // Set capslock key to orange (capslock is led number 30) + rgb_matrix_set_color(28, 255, 130, 15); + } + return false; +} diff --git a/keyboards/royal_kludge/rk61_rgb/keymaps/via/keymap.c b/keyboards/royal_kludge/rk61_rgb/keymaps/via/keymap.c new file mode 100644 index 000000000000..f1c99454ec5b --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/keymaps/via/keymap.c @@ -0,0 +1,42 @@ +/* Copyright (C) 2023 Fernando Birra + * + * 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 + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT_60_ansi( + 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_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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, + KC_LCTL, KC_LALT, KC_LCMD, KC_SPC, KC_RCMD, KC_RALT, KC_RCTL, MO(1) + ), + [1] = LAYOUT_60_ansi( + KC_GRV, 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, + KC_TRNS, KC_F13, KC_F14, KC_F15, KC_F16, KC_F17, KC_PSCR, KC_SCRL, KC_PAUS, RGB_HUD, RGB_HUI, RGB_VAD, RGB_VAI, RGB_MOD, + KC_TRNS, AG_SWAP, AG_NORM, KC_TRNS, KC_TRNS, KC_TRNS, KC_INS, KC_HOME, KC_PGUP, KC_TRNS, RGB_SPD, RGB_SPI, KC_TRNS, + KC_TRNS, KC_MUTE, KC_VOLD, KC_VOLU, KC_MPRV, KC_MNXT, KC_DEL, KC_END, KC_PGDN, RGB_HUI, KC_UP, KC_TRNS, + QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RIGHT, KC_TRNS + ) +}; + +bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { + if (host_keyboard_led_state().caps_lock) { + // Set capslock key to orange (capslock is led number 30) + rgb_matrix_set_color(28, 255, 130, 15); + } + return false; +} \ No newline at end of file diff --git a/keyboards/royal_kludge/rk61_rgb/keymaps/via/rk61-rgb_via.json b/keyboards/royal_kludge/rk61_rgb/keymaps/via/rk61-rgb_via.json new file mode 100644 index 000000000000..5c71333764bd --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/keymaps/via/rk61-rgb_via.json @@ -0,0 +1,16 @@ +{ + "name": "Royal Kludge RK61 RGB", + "vendorId": "0x0C45", + "productId": "0x8016", + "menus": ["qmk_rgb_matrix"], + "matrix": {"rows": 5, "cols": 14}, + "layouts": { + "keymap": [ + [ "0,0", "0,1", "0,2", "0,3", "0,4", "0,5", "0,6", "0,7", "0,8", "0,9", "0,10", "0,11", "0,12", {"w":2}, "0,13" ], + [ {"w":1.5}, "1,0", "1,1", "1,2", "1,3", "1,4", "1,5", "1,6", "1,7", "1,8", "1,9", "1,10", "1,11", "1,12", {"w":1.5}, "1,13" ], + [ {"w":1.75}, "2,0", "2,1", "2,2", "2,3", "2,4", "2,5", "2,6", "2,7", "2,8", "2,9", "2,10", "2,11", {"w":2.25}, "2,13" ], + [ {"w":2.25}, "3,0", "3,2", "3,3", "3,4", "3,5", "3,6", "3,7", "3,8", "3,9", "3,10", "3,11", {"w":2.75}, "3,12" ], + [ {"w":1.25}, "4,0", {"w":1.25}, "4,1", {"w":1.25},"4,2", {"w":6.25}, "4,6", {"w":1.25},"4,9", {"w":1.25},"4,10", {"w":1.25},"4,11", {"w":1.25},"4,13" ] + ] + } +} \ No newline at end of file diff --git a/keyboards/royal_kludge/rk61_rgb/keymaps/via/rules.mk b/keyboards/royal_kludge/rk61_rgb/keymaps/via/rules.mk new file mode 100644 index 000000000000..1e5b99807cb7 --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes diff --git a/keyboards/royal_kludge/rk61_rgb/readme.md b/keyboards/royal_kludge/rk61_rgb/readme.md new file mode 100644 index 000000000000..4099e0b10f6a --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/readme.md @@ -0,0 +1,39 @@ +# RK61 RGB + +![RK61 RGB](https://i.pinimg.com/originals/01/e2/1f/01e21f1ba56526a0f2fe5047b6d25f11.png) + +Royal Kludge RK61 non-hotswap rgb edition, original PID 0x24F. + +Tested on the Royal Kludge RK61 non-hotswap RGB dual-mode edition, original PID 0x24F + +- MCU: HFD2201KBA (rebrand SN32F248BF) +- PCB: RK61-JX-RGB-HFD; REV: 01; 2019/08/13 +- Wired only, no bluetooth support. + +Based on previous work by [euwbah](https://github.com/euwbah). Added VIA 3.0 support. + +Keyboard Maintainer: [fpb](https://github.com/fpb) + +For the white-backlit non-rgb version of the RK61, check out [Diff-fusion's repo](https://github.com/Diff-fusion/qmk_firmware) + + +Note: keymap differs slightly from stock firmware for FN combinations + +See [keymap.c](keymaps/default/keymap.c), and refer to the [list +of QMK keycodes](https://beta.docs.qmk.fm/using-qmk/simple-keycodes/keycodes). + +----------------- + + +Make example for this keyboard (after setting up your build environment): + + make royal_kludge/rk61_rgb:default + +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: + +- Physical reset: short the two contacts to the left of the space bar switch with a wire/paperclip. Accessible from the front. +- Layout (after loading QMK): FN + Left Control diff --git a/keyboards/royal_kludge/rk61_rgb/rules.mk b/keyboards/royal_kludge/rk61_rgb/rules.mk new file mode 100644 index 000000000000..e0c218e90f4d --- /dev/null +++ b/keyboards/royal_kludge/rk61_rgb/rules.mk @@ -0,0 +1,3 @@ +# Data-driven structure doesn't support EEPROM yet +EEPROM_DRIVER = wear_leveling +WEAR_LEVELING_DRIVER = sn32_flash diff --git a/keyboards/royal_kludge/rk68_rgb/config.h b/keyboards/royal_kludge/rk68_rgb/config.h new file mode 100644 index 000000000000..df8e1cfee17a --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/config.h @@ -0,0 +1,27 @@ +/* Copyright (C) 2023 Benjamín Ausensi + * + * 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 + +/* RGB matrix configuration can't be fully expressed in JSON as of now */ +#define SN32_RGB_MATRIX_ROW_PINS { C4, C5, C6, C7, C8, C9, C10, C11, C12, C13, C14, B13, D3, B15, B14 } + +/* Enable additional RGB effects */ +#define RGB_MATRIX_FRAMEBUFFER_EFFECTS +#define RGB_MATRIX_KEYPRESSES + +/* Configure the effects: */ +#define RGB_MATRIX_TYPING_HEATMAP_DECREASE_DELAY_MS 50 \ No newline at end of file diff --git a/keyboards/royal_kludge/rk68_rgb/info.json b/keyboards/royal_kludge/rk68_rgb/info.json new file mode 100644 index 000000000000..34fe82ab7b7b --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/info.json @@ -0,0 +1,204 @@ +{ + "keyboard_name": "RK68-RGB", + "manufacturer": "Royal Kludge", + "url": "http://en.rkgaming.com", + "maintainer": "fpb", + "bootloader": "sn32-dfu", + + "processor": "SN32F248BF", + "usb": { + "vid": "0x0C45", + "pid": "0x8008", + "device_version": "1.0.0" + }, + + "features": { + "audio": false, + "backlight": false, + "bootmagic": true, + "command": false, + "console": false, + "extrakey": true, + "mousekey": false, + "nkro": true, + "rgb_matrix": true + }, + + "debounce": 5, + "diode_direction": "COL2ROW", + "matrix_pins": { + "cols": [ "A8", "A9", "A10", "A11", "A12", "A13", "A14", "A15", "B0", "B1", "B2", "B3", "B4", "B5", "B6" ], + "rows": [ "D11", "D10", "D9", "D8", "D7" ] + }, + + + "rgb_matrix": { + "animations": { + "band_val" : true, + "breathing" : true, + "cycle_left_right" : true, + "cycle_pinwheel" : true, + "cycle_spiral" : true, + "digital_rain" : true, + "gradient_left_right" : true, + "gradient_up_down" : true, + "raindrops" : true, + "solid_reactive_simple" : true, + "splash" : true, + "typing_heatmap" : true + }, + "driver": "sn32f24xb", + "layout": [ + { "matrix": [0,0], "x": 0, "y": 0, "flags": 4}, + { "matrix": [0,1], "x": 14, "y": 0, "flags": 4}, + { "matrix": [0,2], "x": 29, "y": 0, "flags": 4}, + { "matrix": [0,3], "x": 44, "y": 0, "flags": 4}, + { "matrix": [0,4], "x": 59, "y": 0, "flags": 4}, + { "matrix": [0,5], "x": 74, "y": 0, "flags": 4}, + { "matrix": [0,6], "x": 89, "y": 0, "flags": 4}, + { "matrix": [0,7], "x": 104, "y": 0, "flags": 4}, + { "matrix": [0,8], "x": 119, "y": 0, "flags": 4}, + { "matrix": [0,9], "x": 134, "y": 0, "flags": 4}, + { "matrix": [0,10], "x": 149, "y": 0, "flags": 4}, + { "matrix": [0,11], "x": 164, "y": 0, "flags": 4}, + { "matrix": [0,12], "x": 179, "y": 0, "flags": 4}, + { "matrix": [0,13], "x": 201, "y": 0, "flags": 4}, + { "matrix": [0,14], "x": 224, "y": 0, "flags": 4}, + + { "matrix": [1,0], "x": 3, "y": 16, "flags": 4}, + { "matrix": [1,1], "x": 22, "y": 16, "flags": 4}, + { "matrix": [1,2], "x": 37, "y": 16, "flags": 4}, + { "matrix": [1,3], "x": 52, "y": 16, "flags": 4}, + { "matrix": [1,4], "x": 67, "y": 16, "flags": 4}, + { "matrix": [1,5], "x": 82, "y": 16, "flags": 4}, + { "matrix": [1,6], "x": 97, "y": 16, "flags": 4}, + { "matrix": [1,7], "x": 112, "y": 16, "flags": 4}, + { "matrix": [1,8], "x": 126, "y": 16, "flags": 4}, + { "matrix": [1,9], "x": 141, "y": 16, "flags": 4}, + { "matrix": [1,10], "x": 156, "y": 16, "flags": 4}, + { "matrix": [1,11], "x": 171, "y": 16, "flags": 4}, + { "matrix": [1,12], "x": 186, "y": 16, "flags": 4}, + { "matrix": [1,13], "x": 205, "y": 16, "flags": 4}, + { "matrix": [1,14], "x": 224, "y": 16, "flags": 4}, + + { "matrix": [2,0], "x": 5, "y": 32, "flags": 8}, + { "matrix": [2,1], "x": 26, "y": 32, "flags": 4}, + { "matrix": [2,2], "x": 41, "y": 32, "flags": 4}, + { "matrix": [2,3], "x": 55, "y": 32, "flags": 4}, + { "matrix": [2,4], "x": 70, "y": 32, "flags": 4}, + { "matrix": [2,5], "x": 85, "y": 32, "flags": 4}, + { "matrix": [2,6], "x": 100, "y": 32, "flags": 4}, + { "matrix": [2,7], "x": 115, "y": 32, "flags": 4}, + { "matrix": [2,8], "x": 130, "y": 32, "flags": 4}, + { "matrix": [2,9], "x": 145, "y": 32, "flags": 4}, + { "matrix": [2,10], "x": 160, "y": 32, "flags": 4}, + { "matrix": [2,11], "x": 175, "y": 32, "flags": 4}, + { "matrix": [2,13], "x": 199, "y": 32, "flags": 4}, + { "matrix": [2,14], "x": 224, "y": 32, "flags": 4}, + + { "matrix": [3,0], "x": 9, "y": 48, "flags": 4}, + { "matrix": [3,2], "x": 33, "y": 48, "flags": 4}, + { "matrix": [3,3], "x": 48, "y": 48, "flags": 4}, + { "matrix": [3,4], "x": 63, "y": 48, "flags": 4}, + { "matrix": [3,5], "x": 78, "y": 48, "flags": 4}, + { "matrix": [3,6], "x": 93, "y": 48, "flags": 4}, + { "matrix": [3,7], "x": 108, "y": 48, "flags": 4}, + { "matrix": [3,8], "x": 123, "y": 48, "flags": 4}, + { "matrix": [3,9], "x": 138, "y": 48, "flags": 4}, + { "matrix": [3,10], "x": 153, "y": 48, "flags": 4}, + { "matrix": [3,11], "x": 167, "y": 48, "flags": 4}, + { "matrix": [3,12], "x": 188, "y": 48, "flags": 4}, + { "matrix": [3,13], "x": 209, "y": 48, "flags": 4}, + { "matrix": [3,14], "x": 224, "y": 48, "flags": 4}, + + { "matrix": [4,0], "x": 1, "y": 64, "flags": 4}, + { "matrix": [4,1], "x": 20, "y": 64, "flags": 4}, + { "matrix": [4,2], "x": 39, "y": 64, "flags": 4}, + { "matrix": [4,6], "x": 95, "y": 64, "flags": 4}, + { "matrix": [4,9], "x": 149, "y": 64, "flags": 4}, + { "matrix": [4,10], "x": 164, "y": 64, "flags": 4}, + { "matrix": [4,11], "x": 179, "y": 64, "flags": 4}, + { "matrix": [4,12], "x": 194, "y": 64, "flags": 4}, + { "matrix": [4,13], "x": 209, "y": 64, "flags": 4}, + { "matrix": [4,14], "x": 224, "y": 64, "flags": 4} + ] + }, + "layouts": { + "LAYOUT": { + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0}, + {"matrix": [0, 1], "x": 1, "y": 0}, + {"matrix": [0, 2], "x": 2, "y": 0}, + {"matrix": [0, 3], "x": 3, "y": 0}, + {"matrix": [0, 4], "x": 4, "y": 0}, + {"matrix": [0, 5], "x": 5, "y": 0}, + {"matrix": [0, 6], "x": 6, "y": 0}, + {"matrix": [0, 7], "x": 7, "y": 0}, + {"matrix": [0, 8], "x": 8, "y": 0}, + {"matrix": [0, 9], "x": 9, "y": 0}, + {"matrix": [0, 10], "x": 10, "y": 0}, + {"matrix": [0, 11], "x": 11, "y": 0}, + {"matrix": [0, 12], "x": 12, "y": 0}, + {"matrix": [0, 13], "x": 13, "y": 0, "w": 2}, + {"matrix": [0, 14], "x": 15, "y": 0}, + + {"matrix": [1, 0], "x": 0, "y": 1, "w": 1.5}, + {"matrix": [1, 1], "x": 1.5, "y": 1}, + {"matrix": [1, 2], "x": 2.5, "y": 1}, + {"matrix": [1, 3], "x": 3.5, "y": 1}, + {"matrix": [1, 4], "x": 4.5, "y": 1}, + {"matrix": [1, 5], "x": 5.5, "y": 1}, + {"matrix": [1, 6], "x": 6.5, "y": 1}, + {"matrix": [1, 7], "x": 7.5, "y": 1}, + {"matrix": [1, 8], "x": 8.5, "y": 1}, + {"matrix": [1, 9], "x": 9.5, "y": 1}, + {"matrix": [1, 10], "x": 10.5, "y": 1}, + {"matrix": [1, 11], "x": 11.5, "y": 1}, + {"matrix": [1, 12], "x": 12.5, "y": 1}, + {"matrix": [1, 13], "x": 13.5, "y": 1, "w": 1.5}, + {"matrix": [1, 14], "x": 15, "y": 1}, + + {"matrix": [2, 0], "x": 0, "y": 2, "w": 1.75}, + {"matrix": [2, 1], "x": 1.75, "y": 2}, + {"matrix": [2, 2], "x": 2.75, "y": 2}, + {"matrix": [2, 3], "x": 3.75, "y": 2}, + {"matrix": [2, 4], "x": 4.75, "y": 2}, + {"matrix": [2, 5], "x": 5.75, "y": 2}, + {"matrix": [2, 6], "x": 6.75, "y": 2}, + {"matrix": [2, 7], "x": 7.75, "y": 2}, + {"matrix": [2, 8], "x": 8.75, "y": 2}, + {"matrix": [2, 9], "x": 9.75, "y": 2}, + {"matrix": [2, 10], "x": 10.75, "y": 2}, + {"matrix": [2, 11], "x": 11.75, "y": 2}, + {"matrix": [2, 13], "x": 12.75, "y": 2, "w": 2.25}, + {"matrix": [2, 14], "x": 15, "y": 2}, + + {"matrix": [3, 0], "x": 0, "y": 3, "w": 2.25}, + {"matrix": [3, 2], "x": 2.25, "y": 3}, + {"matrix": [3, 3], "x": 3.25, "y": 3}, + {"matrix": [3, 4], "x": 4.25, "y": 3}, + {"matrix": [3, 5], "x": 5.25, "y": 3}, + {"matrix": [3, 6], "x": 6.25, "y": 3}, + {"matrix": [3, 7], "x": 7.25, "y": 3}, + {"matrix": [3, 8], "x": 8.25, "y": 3}, + {"matrix": [3, 9], "x": 9.25, "y": 3}, + {"matrix": [3, 10], "x": 10.25, "y": 3}, + {"matrix": [3, 11], "x": 11.25, "y": 3}, + {"matrix": [3, 12], "x": 12.25, "y": 3, "w": 1.75}, + {"matrix": [3, 13], "x": 14, "y": 3}, + {"matrix": [3, 14], "x": 15, "y": 3}, + + {"matrix": [4, 0], "x": 0, "y": 4, "w": 1.25}, + {"matrix": [4, 1], "x": 1.25, "y": 4, "w": 1.25}, + {"matrix": [4, 2], "x": 2.5, "y": 4, "w": 1.25}, + {"matrix": [4, 6], "x": 3.75, "y": 4, "w": 6.25}, + {"matrix": [4, 9], "x": 10, "y": 4}, + {"matrix": [4, 10], "x": 11, "y": 4}, + {"matrix": [4, 11], "x": 12, "y": 4}, + {"matrix": [4, 12], "x": 13, "y": 4}, + {"matrix": [4, 13], "x": 14, "y": 4}, + {"matrix": [4, 14], "x": 15, "y": 4} + ] + } + } +} diff --git a/keyboards/royal_kludge/rk68_rgb/keymaps/default/keymap.c b/keyboards/royal_kludge/rk68_rgb/keymaps/default/keymap.c new file mode 100644 index 000000000000..facb2d4fa4a1 --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/keymaps/default/keymap.c @@ -0,0 +1,42 @@ +/* Copyright 2022 DeskDaily + * + * 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 + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( + 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_GRV, + 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_DEL, + 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_PGUP, + 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_PGDN, + KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT( + KC_TRNS, 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_TRNS, KC_PSCR, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_END, RGB_MOD, KC_INS, + KC_TRNS, AG_SWAP, AG_NORM, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_BRK, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_HUI, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, KC_SCRL, + QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_SPD, RGB_VAD, RGB_SPI + ), +}; + +bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { + if (host_keyboard_led_state().caps_lock) { + // Set capslock key to orange (capslock is led number 30) + rgb_matrix_set_color(30, 255, 130, 15); + } + return false; +} \ No newline at end of file diff --git a/keyboards/royal_kludge/rk68_rgb/keymaps/via/config.h b/keyboards/royal_kludge/rk68_rgb/keymaps/via/config.h new file mode 100644 index 000000000000..c1c5c9162f98 --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/keymaps/via/config.h @@ -0,0 +1,19 @@ +/* Copyright (C) 2023 Benjamín Ausensi + * + * 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 + +#define DYNAMIC_KEYMAP_LAYER_COUNT 3 diff --git a/keyboards/royal_kludge/rk68_rgb/keymaps/via/keymap.c b/keyboards/royal_kludge/rk68_rgb/keymaps/via/keymap.c new file mode 100644 index 000000000000..72b9227ac3fd --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/keymaps/via/keymap.c @@ -0,0 +1,42 @@ +/* Copyright (C) 2023 Fernando Birra + * + * 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 + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + [0] = LAYOUT( + 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_GRV, + 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_DEL, + 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_PGUP, + 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_PGDN, + KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RGUI, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT + ), + [1] = LAYOUT( + KC_TRNS, 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_TRNS, KC_PSCR, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_END, RGB_MOD, KC_INS, + KC_TRNS, AG_SWAP, AG_NORM, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_BRK, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_HUI, KC_TRNS, KC_TRNS, KC_TRNS, RGB_VAI, KC_SCRL, + QK_BOOT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RGB_SPD, RGB_VAD, RGB_SPI + ) +}; + +bool rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) { + if (host_keyboard_led_state().caps_lock) { + // Set capslock key to orange (capslock is led number 30) + rgb_matrix_set_color(30, 255, 130, 15); + } + return false; +} \ No newline at end of file diff --git a/keyboards/royal_kludge/rk68_rgb/keymaps/via/rk68-rgb_via.json b/keyboards/royal_kludge/rk68_rgb/keymaps/via/rk68-rgb_via.json new file mode 100644 index 000000000000..16f7db4fcac6 --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/keymaps/via/rk68-rgb_via.json @@ -0,0 +1,16 @@ +{ + "name": "Royal Kludge RK68 RGB", + "vendorId": "0x0C45", + "productId": "0x8008", + "menus": ["qmk_rgb_matrix"], + "matrix": {"rows": 5, "cols": 15}, + "layouts": { + "keymap": [ + [ "0,0", "0,1", "0,2", "0,3", "0,4", "0,5", "0,6", "0,7", "0,8", "0,9", "0,10", "0,11", "0,12", {"w":2}, "0,13", "0,14" ], + [ {"w":1.5}, "1,0", "1,1", "1,2", "1,3", "1,4", "1,5", "1,6", "1,7", "1,8", "1,9", "1,10", "1,11", "1,12", {"w":1.5}, "1,13", "1,14" ], + [ {"w":1.75}, "2,0", "2,1", "2,2", "2,3", "2,4", "2,5", "2,6", "2,7", "2,8", "2,9", "2,10", "2,11", {"w":2.25}, "2,13", "2,14" ], + [ {"w":2.25}, "3,0", "3,2", "3,3", "3,4", "3,5", "3,6", "3,7", "3,8", "3,9", "3,10", "3,11", {"w":1.75}, "3,12", "3,13", "3,14" ], + [ {"w":1.25}, "4,0", {"w":1.25}, "4,1", {"w":1.25},"4,2", {"w":6.25}, "4,6", "4,9","4,10","4,11","4,12", "4,13", "4,14" ] + ] + } +} \ No newline at end of file diff --git a/keyboards/royal_kludge/rk68_rgb/keymaps/via/rules.mk b/keyboards/royal_kludge/rk68_rgb/keymaps/via/rules.mk new file mode 100644 index 000000000000..036bd6d1c3ec --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/keymaps/via/rules.mk @@ -0,0 +1 @@ +VIA_ENABLE = yes \ No newline at end of file diff --git a/keyboards/royal_kludge/rk68_rgb/readme.md b/keyboards/royal_kludge/rk68_rgb/readme.md new file mode 100644 index 000000000000..4565120b33d6 --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/readme.md @@ -0,0 +1,59 @@ +# RK68 RGB + +![RK68 RGB](https://i.ibb.co/bLYNDjb/IMG-20210321-025644.jpg) + +Royal Kludge RK68 hotswap dual mode, rgb edition, original PID 0x24F. Later updated to 0x8016. + +- MCU: HFD2201KBA (rebrand SN32F248BF) +- PCB: RK61-JX-RGB-HFD; REV: 01; 2020/11/04 +- Wired only, no bluetooth support. + +Updated to work with SonixQMK/qmk_firmware:sn32_develop branch. Based on previous work by [euwbah](https://github.com/euwbah). Added VIA 3.0 support. + +Keyboard Maintainer: [fpb](https://github.com/fpb) + +For the white-backlit non-rgb version of the RK68, check out [silasb' repo](https://github.com/silasb/qmk_firmware) + + +Note: keymap differs slightly from stock firmware for FN combinations + +See [keymap.c](keymaps/default/keymap.c), and refer to the [list +of QMK keycodes](https://beta.docs.qmk.fm/using-qmk/simple-keycodes/keycodes). + +Keyboard will always start in Mac mode but you can toggle between Windows (FN+A) and Mac (FN+S) layouts. Function keys work as function keys. + +Building instructions +----------------- + + +Make example for this keyboard (after setting up your build environment): + + $ make royal_kludge/rk68_rgb:all + +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: + +- Physical reset: short the two pins on the underside of the pcb, as indicated below. You need to remove some keycaps and 6 screws to be able to flip the PCB. +- Layout (after loading QMK): FN + CTRL + +![Bootloader mode](https://i.ibb.co/BT7sj31/bootmode.jpg) + +## Keymaps + +Keysmaps are identical in both VIA and default layouts. VIA version has one additional empty layer to customize. + +![Layer 0](https://i.ibb.co/9wXbcmM/layer0.jpg) +![Layer 1](https://i.ibb.co/q9T33QJ/layer1.jpg) + +## VIA Json file + +You need [this json file](./keymaps/via/rk68-rgb_via.json) to add your keyboard at https://usevia.app. Go to settings, Show Design TAB, Go to Design Tab and Load Draft Definition. + +## Final result + +Here is a picture of my RK68 with Mac style keycaps... + +![RK68 RGB running QMK/VIA firmware](https://i.ibb.co/HCrk3D3/IMG-20231118-133253.jpg) \ No newline at end of file diff --git a/keyboards/royal_kludge/rk68_rgb/rules.mk b/keyboards/royal_kludge/rk68_rgb/rules.mk new file mode 100644 index 000000000000..e0c218e90f4d --- /dev/null +++ b/keyboards/royal_kludge/rk68_rgb/rules.mk @@ -0,0 +1,3 @@ +# Data-driven structure doesn't support EEPROM yet +EEPROM_DRIVER = wear_leveling +WEAR_LEVELING_DRIVER = sn32_flash