diff options
Diffstat (limited to 'keyboards/kprepublic/bm40hsrgb/rev2')
-rwxr-xr-x | keyboards/kprepublic/bm40hsrgb/rev2/config.h | 22 | ||||
-rw-r--r-- | keyboards/kprepublic/bm40hsrgb/rev2/info.json | 197 | ||||
-rwxr-xr-x | keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/keymap.c | 101 | ||||
-rw-r--r-- | keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/rules.mk | 1 | ||||
-rw-r--r-- | keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/keymap.c | 100 | ||||
-rw-r--r-- | keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/rules.mk | 3 | ||||
-rw-r--r-- | keyboards/kprepublic/bm40hsrgb/rev2/readme.md | 29 | ||||
-rwxr-xr-x | keyboards/kprepublic/bm40hsrgb/rev2/rev2.c | 73 | ||||
-rw-r--r-- | keyboards/kprepublic/bm40hsrgb/rev2/rules.mk | 0 |
9 files changed, 526 insertions, 0 deletions
diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/config.h b/keyboards/kprepublic/bm40hsrgb/rev2/config.h new file mode 100755 index 0000000000..84df5017b6 --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/config.h @@ -0,0 +1,22 @@ +/* Copyright 2020 tominabox1 + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ +#pragma once + +#define DRIVER_COUNT 1 +#define DRIVER_ADDR_1 0b1010000 +#define RGB_MATRIX_LED_COUNT 47 +#define RGB_MATRIX_KEYPRESSES +#define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/info.json b/keyboards/kprepublic/bm40hsrgb/rev2/info.json new file mode 100644 index 0000000000..dac848ed52 --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/info.json @@ -0,0 +1,197 @@ +{ + "keyboard_name": "BM40 Hotswap RGB", + "manufacturer": "KPRepublic", + "url": "", + "maintainer": "qmk", + "features": { + "bootmagic": true, + "mousekey": true, + "extrakey": true, + "rgblight": true, + "rgb_matrix": true, + "tri_layer": true, + "console": false, + "command": false, + "nkro": false, + "backlight": false, + "audio": false + }, + "usb": { + "vid": "0x4B50", + "pid": "0x3430", + "device_version": "0.0.2" + }, + "ws2812": { + "pin": "B0" + }, + "rgblight": { + "led_count": 6, + "max_brightness": 150, + "animations": { + "knight": true, + "rainbow_swirl": true + } + }, + "rgb_matrix": { + "driver": "is31fl3733", + "max_brightness": 150, + "animations": { + "alphas_mods": true, + "gradient_up_down": true, + "gradient_left_right": true, + "breathing": true, + "band_sat": true, + "band_val": true, + "band_pinwheel_sat": true, + "band_pinwheel_val": true, + "band_spiral_sat": true, + "band_spiral_val": true, + "cycle_all": true, + "cycle_left_right": true, + "cycle_up_down": true, + "rainbow_moving_chevron": true, + "cycle_out_in": true, + "cycle_out_in_dual": true, + "cycle_pinwheel": true, + "cycle_spiral": true, + "dual_beacon": true, + "rainbow_beacon": true, + "rainbow_pinwheels": true, + "raindrops": true, + "jellybean_raindrops": true, + "hue_breathing": true, + "hue_pendulum": true, + "hue_wave": true, + "pixel_rain": true, + "pixel_flow": true, + "pixel_fractal": true, + "typing_heatmap": true, + "digital_rain": true, + "solid_reactive_simple": true, + "solid_reactive": true, + "solid_reactive_wide": true, + "solid_reactive_multiwide": true, + "solid_reactive_cross": true, + "solid_reactive_multicross": true, + "solid_reactive_nexus": true, + "solid_reactive_multinexus": true, + "splash": true, + "multisplash": true, + "solid_splash": true, + "solid_multisplash": true + }, + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0, "flags": 1}, + {"matrix": [0, 1], "x": 20, "y": 0, "flags": 4}, + {"matrix": [0, 2], "x": 40, "y": 0, "flags": 4}, + {"matrix": [0, 3], "x": 61, "y": 0, "flags": 4}, + {"matrix": [0, 4], "x": 81, "y": 0, "flags": 4}, + {"matrix": [0, 5], "x": 101, "y": 0, "flags": 4}, + {"matrix": [0, 6], "x": 122, "y": 0, "flags": 4}, + {"matrix": [0, 7], "x": 142, "y": 0, "flags": 4}, + {"matrix": [0, 8], "x": 162, "y": 0, "flags": 4}, + {"matrix": [0, 9], "x": 183, "y": 0, "flags": 4}, + {"matrix": [0, 10], "x": 203, "y": 0, "flags": 4}, + {"matrix": [0, 11], "x": 224, "y": 0, "flags": 1}, + {"matrix": [1, 0], "x": 0, "y": 21, "flags": 1}, + {"matrix": [1, 1], "x": 20, "y": 21, "flags": 4}, + {"matrix": [1, 2], "x": 40, "y": 21, "flags": 4}, + {"matrix": [1, 3], "x": 61, "y": 21, "flags": 4}, + {"matrix": [1, 4], "x": 81, "y": 21, "flags": 4}, + {"matrix": [1, 5], "x": 101, "y": 21, "flags": 4}, + {"matrix": [1, 6], "x": 122, "y": 21, "flags": 4}, + {"matrix": [1, 7], "x": 142, "y": 21, "flags": 4}, + {"matrix": [1, 8], "x": 162, "y": 21, "flags": 4}, + {"matrix": [1, 9], "x": 183, "y": 21, "flags": 4}, + {"matrix": [1, 10], "x": 203, "y": 21, "flags": 4}, + {"matrix": [1, 11], "x": 224, "y": 21, "flags": 1}, + {"matrix": [2, 0], "x": 0, "y": 42, "flags": 1}, + {"matrix": [2, 1], "x": 20, "y": 42, "flags": 4}, + {"matrix": [2, 2], "x": 40, "y": 42, "flags": 4}, + {"matrix": [2, 3], "x": 61, "y": 42, "flags": 4}, + {"matrix": [2, 4], "x": 81, "y": 42, "flags": 4}, + {"matrix": [2, 5], "x": 101, "y": 42, "flags": 4}, + {"matrix": [2, 6], "x": 122, "y": 42, "flags": 4}, + {"matrix": [2, 7], "x": 142, "y": 42, "flags": 4}, + {"matrix": [2, 8], "x": 162, "y": 42, "flags": 4}, + {"matrix": [2, 9], "x": 183, "y": 42, "flags": 4}, + {"matrix": [2, 10], "x": 203, "y": 42, "flags": 4}, + {"matrix": [2, 11], "x": 224, "y": 42, "flags": 1}, + {"matrix": [3, 0], "x": 0, "y": 64, "flags": 1}, + {"matrix": [3, 1], "x": 20, "y": 64, "flags": 1}, + {"matrix": [3, 2], "x": 40, "y": 64, "flags": 1}, + {"matrix": [3, 3], "x": 61, "y": 64, "flags": 1}, + {"matrix": [3, 4], "x": 81, "y": 64, "flags": 1}, + {"matrix": [3, 5], "x": 111, "y": 64, "flags": 1}, + {"matrix": [3, 7], "x": 142, "y": 64, "flags": 1}, + {"matrix": [3, 8], "x": 162, "y": 64, "flags": 1}, + {"matrix": [3, 9], "x": 183, "y": 64, "flags": 1}, + {"matrix": [3, 10], "x": 203, "y": 64, "flags": 1}, + {"matrix": [3, 11], "x": 224, "y": 64, "flags": 1} + ] + }, + "matrix_pins": { + "cols": ["B2", "B3", "D5", "D3", "D2", "B7", "F0", "B4", "B5", "B6", "C6", "C7"], + "rows": ["D7", "F7", "F6", "F5"] + }, + "diode_direction": "ROW2COL", + "processor": "atmega32u4", + "bootloader": "atmel-dfu", + "community_layouts": ["planck_mit"], + "layout_aliases": { + "LAYOUT_planck_mit": "LAYOUT_ortho_4x12_1x2uC" + }, + "layouts": { + "LAYOUT_ortho_4x12_1x2uC": { + "layout": [ + {"label":"K00", "matrix": [0, 0], "x":0, "y":0}, + {"label":"K01", "matrix": [0, 1], "x":1, "y":0}, + {"label":"K02", "matrix": [0, 2], "x":2, "y":0}, + {"label":"K03", "matrix": [0, 3], "x":3, "y":0}, + {"label":"K04", "matrix": [0, 4], "x":4, "y":0}, + {"label":"K05", "matrix": [0, 5], "x":5, "y":0}, + {"label":"K06", "matrix": [0, 6], "x":6, "y":0}, + {"label":"K07", "matrix": [0, 7], "x":7, "y":0}, + {"label":"K08", "matrix": [0, 8], "x":8, "y":0}, + {"label":"K09", "matrix": [0, 9], "x":9, "y":0}, + {"label":"K0A", "matrix": [0, 10], "x":10, "y":0}, + {"label":"K0B", "matrix": [0, 11], "x":11, "y":0}, + {"label":"K10", "matrix": [1, 0], "x":0, "y":1}, + {"label":"K11", "matrix": [1, 1], "x":1, "y":1}, + {"label":"K12", "matrix": [1, 2], "x":2, "y":1}, + {"label":"K13", "matrix": [1, 3], "x":3, "y":1}, + {"label":"K14", "matrix": [1, 4], "x":4, "y":1}, + {"label":"K15", "matrix": [1, 5], "x":5, "y":1}, + {"label":"K16", "matrix": [1, 6], "x":6, "y":1}, + {"label":"K17", "matrix": [1, 7], "x":7, "y":1}, + {"label":"K18", "matrix": [1, 8], "x":8, "y":1}, + {"label":"K19", "matrix": [1, 9], "x":9, "y":1}, + {"label":"K1A", "matrix": [1, 10], "x":10, "y":1}, + {"label":"K1B", "matrix": [1, 11], "x":11, "y":1}, + {"label":"K20", "matrix": [2, 0], "x":0, "y":2}, + {"label":"K21", "matrix": [2, 1], "x":1, "y":2}, + {"label":"K22", "matrix": [2, 2], "x":2, "y":2}, + {"label":"K23", "matrix": [2, 3], "x":3, "y":2}, + {"label":"K24", "matrix": [2, 4], "x":4, "y":2}, + {"label":"K25", "matrix": [2, 5], "x":5, "y":2}, + {"label":"K26", "matrix": [2, 6], "x":6, "y":2}, + {"label":"K27", "matrix": [2, 7], "x":7, "y":2}, + {"label":"K28", "matrix": [2, 8], "x":8, "y":2}, + {"label":"K29", "matrix": [2, 9], "x":9, "y":2}, + {"label":"K2A", "matrix": [2, 10], "x":10, "y":2}, + {"label":"K2B", "matrix": [2, 11], "x":11, "y":2}, + {"label":"K30", "matrix": [3, 0], "x":0, "y":3}, + {"label":"K31", "matrix": [3, 1], "x":1, "y":3}, + {"label":"K32", "matrix": [3, 2], "x":2, "y":3}, + {"label":"K33", "matrix": [3, 3], "x":3, "y":3}, + {"label":"K34", "matrix": [3, 4], "x":4, "y":3}, + {"label":"K35", "matrix": [3, 5], "x":5, "y":3, "w":2}, + {"label":"K37", "matrix": [3, 7], "x":7, "y":3}, + {"label":"K38", "matrix": [3, 8], "x":8, "y":3}, + {"label":"K39", "matrix": [3, 9], "x":9, "y":3}, + {"label":"K3A", "matrix": [3, 10], "x":10, "y":3}, + {"label":"K3B", "matrix": [3, 11], "x":11, "y":3} + ] + } + } +} diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/keymap.c b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/keymap.c new file mode 100755 index 0000000000..5f389e4caf --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/keymap.c @@ -0,0 +1,101 @@ +/* Copyright 2020 tominabox1 + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ +#include QMK_KEYBOARD_H + +enum layers { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + +/* Qwerty + * ,-----------------------------------------------------------------------------------. + * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Esc | A | S | D | F | G | H | J | K | L | ; | " | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | BLTog| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right | + * `-----------------------------------------------------------------------------------' + */ +[_QWERTY] = LAYOUT_ortho_4x12_1x2uC( + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , + RGB_TOG, KC_LCTL, KC_LALT, KC_LGUI, TL_LOWR, KC_SPC, TL_UPPR, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT +), + +/* Lower + * ,-----------------------------------------------------------------------------------. + * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | Home | End | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | Next | Vol- | Vol+ | Play | + * `-----------------------------------------------------------------------------------' + */ +[_LOWER] = LAYOUT_ortho_4x12_1x2uC( + KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, + KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, + _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, S(KC_NUHS), S(KC_NUBS), KC_HOME, KC_END, _______, + _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY +), + +/* Raise + * ,-----------------------------------------------------------------------------------. + * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / |Pg Up |Pg Dn | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | Next | Vol- | Vol+ | Play | + * `-----------------------------------------------------------------------------------' + */ +[_RAISE] = LAYOUT_ortho_4x12_1x2uC( + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, + KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, + _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, KC_PGUP, KC_PGDN, _______, + _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY +), + +/* Adjust (Lower + Raise) + * v------------------------RGB CONTROL--------------------v + * ,-----------------------------------------------------------------------------------. + * | | Reset|Debug | RGB |RGBMOD| HUE+ | HUE- | SAT+ | SAT- |BRGTH+|BRGTH-| Del | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | | | | | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | | | | | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | | | | | + * `-----------------------------------------------------------------------------------' + */ +[_ADJUST] = LAYOUT_ortho_4x12_1x2uC( + _______, QK_BOOT, DB_TOGG, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_DEL , + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ +) + +}; + diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/rules.mk b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/rules.mk new file mode 100644 index 0000000000..4da205a168 --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/default/rules.mk @@ -0,0 +1 @@ +LTO_ENABLE = yes diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/keymap.c b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/keymap.c new file mode 100644 index 0000000000..216d7cb888 --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/keymap.c @@ -0,0 +1,100 @@ +/* Copyright 2020 tominabox1 + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ +#include QMK_KEYBOARD_H + +enum layers { + _QWERTY, + _LOWER, + _RAISE, + _ADJUST +}; + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + +/* Qwerty + * ,-----------------------------------------------------------------------------------. + * | Tab | Q | W | E | R | T | Y | U | I | O | P | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Esc | A | S | D | F | G | H | J | K | L | ; | " | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Shift| Z | X | C | V | B | N | M | , | . | / |Enter | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | BLTog| Ctrl | Alt | GUI |Lower | Space |Raise | Left | Down | Up |Right | + * `-----------------------------------------------------------------------------------' + */ +[_QWERTY] = LAYOUT_ortho_4x12_1x2uC( + KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, + KC_ESC, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, + KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT , + RGB_TOG, KC_LCTL, KC_LALT, KC_LGUI, TL_LOWR, KC_SPC, TL_UPPR, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT +), + +/* Lower + * ,-----------------------------------------------------------------------------------. + * | ~ | ! | @ | # | $ | % | ^ | & | * | ( | ) | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Del | F1 | F2 | F3 | F4 | F5 | F6 | _ | + | { | } | | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO ~ |ISO | | Home | End | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | Next | Vol- | Vol+ | Play | + * `-----------------------------------------------------------------------------------' + */ +[_LOWER] = LAYOUT_ortho_4x12_1x2uC( + KC_TILD, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_BSPC, + KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_UNDS, KC_PLUS, KC_LCBR, KC_RCBR, KC_PIPE, + _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, S(KC_NUHS), S(KC_NUBS), KC_HOME, KC_END, _______, + _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY +), + +/* Raise + * ,-----------------------------------------------------------------------------------. + * | ` | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 0 | Bksp | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | Del | F1 | F2 | F3 | F4 | F5 | F6 | - | = | [ | ] | \ | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | F7 | F8 | F9 | F10 | F11 | F12 |ISO # |ISO / |Pg Up |Pg Dn | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | Next | Vol- | Vol+ | Play | + * `-----------------------------------------------------------------------------------' + */ +[_RAISE] = LAYOUT_ortho_4x12_1x2uC( + KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC, + KC_DEL, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_MINS, KC_EQL, KC_LBRC, KC_RBRC, KC_BSLS, + _______, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_NUHS, KC_NUBS, KC_PGUP, KC_PGDN, _______, + _______, _______, _______, _______, _______, _______, _______, KC_MNXT, KC_VOLD, KC_VOLU, KC_MPLY +), + +/* Adjust (Lower + Raise) + * v------------------------RGB CONTROL--------------------v + * ,-----------------------------------------------------------------------------------. + * | | Reset|Debug | RGB |RGBMOD| HUE+ | HUE- | SAT+ | SAT- |BRGTH+|BRGTH-| Del | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | | | | | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | | | | | | + * |------+------+------+------+------+------+------+------+------+------+------+------| + * | | | | | | | | | | | | + * `-----------------------------------------------------------------------------------' + */ +[_ADJUST] = LAYOUT_ortho_4x12_1x2uC( + _______, QK_BOOT, DB_TOGG, RGB_TOG, RGB_MOD, RGB_HUI, RGB_HUD, RGB_SAI, RGB_SAD, RGB_VAI, RGB_VAD, KC_DEL , + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, + _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______ +) + +}; diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/rules.mk b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/rules.mk new file mode 100644 index 0000000000..0cea9288cc --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/keymaps/via/rules.mk @@ -0,0 +1,3 @@ +VIA_ENABLE = yes +LTO_ENABLE = yes +RGBLIGHT_ENABLE = no diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/readme.md b/keyboards/kprepublic/bm40hsrgb/rev2/readme.md new file mode 100644 index 0000000000..2c2264e4e8 --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/readme.md @@ -0,0 +1,29 @@ +# bm40hsrgb + +![BM40 RGB](https://i.imgur.com/eOqXMlNh.jpg) + +An ortholinear 40% hotswap keyboard with per-key RGB in-switch LEDs and RGB Backlighting, from KP Republic. + +This firmware was originally taken from a kbfirmware.json and manually converted. You may find the original `.json` files [here](https://drive.google.com/drive/folders/1tlTHQIFcluK2mjZ4UbbKCsdRLgSRSPw6). + +* Keyboard Maintainer: [rgoulter](https://github.com/rgoulter) +* Hardware Supported: bm40hsrgb PCB +* Hardware Availability: [KPRepublic](https://www.aliexpress.com/item/4001147779116.html) + +Make example for this keyboard (after setting up your build environment): + + make kprepublic/bm40hsrgb/rev2:default + +Flashing example for this keyboard: + + make kprepublic/bm40hsrgb/rev2: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 + +There are multiple ways to enter the bootloader so that firmware can be flashed onto the keyboard: + +* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (the top left key) and plug in the keyboard. +* **Physical reset button**: Briefly press the button labeled 'RST' on the back of the PCB. +* **Keycode in layout**: Press the key mapped to `RESET` if it is available. diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/rev2.c b/keyboards/kprepublic/bm40hsrgb/rev2/rev2.c new file mode 100755 index 0000000000..b4a7e4399f --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/rev2.c @@ -0,0 +1,73 @@ +/* Copyright 2020 tominabox1, Richard Goulter <richard.goulter@gmail.com> + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + */ +#include "quantum.h" + +#if defined(RGB_MATRIX_ENABLE) + +const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { + { 0, B_1, A_1, C_1 }, + { 0, B_2, A_2, C_2 }, + { 0, B_3, A_3, C_3 }, + { 0, B_4, A_4, C_4 }, + { 0, B_5, A_5, C_5 }, + { 0, B_6, A_6, C_6 }, + { 0, B_7, A_7, C_7 }, + { 0, B_8, A_8, C_8 }, + { 0, B_9, A_9, C_9 }, + { 0, B_10, A_10, C_10 }, + { 0, B_11, A_11, C_11 }, + { 0, B_12, A_12, C_12 }, + + { 0, E_1, D_1, F_1 }, + { 0, E_2, D_2, F_2 }, + { 0, E_3, D_3, F_3 }, + { 0, E_4, D_4, F_4 }, + { 0, E_5, D_5, F_5 }, + { 0, E_6, D_6, F_6 }, + { 0, E_7, D_7, F_7 }, + { 0, E_8, D_8, F_8 }, + { 0, E_9, D_9, F_9 }, + { 0, E_10, D_10, F_10 }, + { 0, E_11, D_11, F_11 }, + { 0, E_12, D_12, F_12 }, + + { 0, H_1, G_1, I_1 }, + { 0, H_2, G_2, I_2 }, + { 0, H_3, G_3, I_3 }, + { 0, H_4, G_4, I_4 }, + { 0, H_5, G_5, I_5 }, + { 0, H_6, G_6, I_6 }, + { 0, H_7, G_7, I_7 }, + { 0, H_8, G_8, I_8 }, + { 0, H_9, G_9, I_9 }, + { 0, H_10, G_10, I_10 }, + { 0, H_11, G_11, I_11 }, + { 0, H_12, G_12, I_12 }, + + { 0, K_1, J_1, L_1 }, + { 0, K_2, J_2, L_2 }, + { 0, K_3, J_3, L_3 }, + { 0, K_4, J_4, L_4 }, + { 0, K_5, J_5, L_5 }, + { 0, K_6, J_6, L_6 }, + { 0, K_8, J_8, L_8 }, + { 0, K_9, J_9, L_9 }, + { 0, K_10, J_10, L_10 }, + { 0, K_11, J_11, L_11 }, + { 0, K_12, J_12, L_12 } +}; + +#endif /* RGB_MATRIX_ENABLE */ diff --git a/keyboards/kprepublic/bm40hsrgb/rev2/rules.mk b/keyboards/kprepublic/bm40hsrgb/rev2/rules.mk new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/keyboards/kprepublic/bm40hsrgb/rev2/rules.mk |