forked from qmk/qmk_firmware
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/master'
* upstream/master: implement rgb matrix for momokai keyboards (qmk#19904) [Keymap] Smooted's BM80v2 keymap (qmk#19873) [Keyboard] Add Karn Keyboard (qmk#19846) Add disable git safe directory check step (qmk#20040) [Keyboard] Sejin EAT-1010R2 keyboard (qmk#19809) [Docs] Discuss layout macro (qmk#19803) [Keyboard] Add gummykey (qmk#19695) keyboards/anavi: Add ANAVI Knobs 3 (qmk#18624) Reject VIA keys within info.json (qmk#20026) Unbreak switchplate/southpaw_65 after qmk#16277 (qmk#20015)
- Loading branch information
Showing
45 changed files
with
1,238 additions
and
184 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
{ | ||
"keyboard_name": "Knobs 3", | ||
"manufacturer": "ANAVI", | ||
"url": "https://github.com/AnaviTechnology/anavi-knobs-3", | ||
"maintainer": "leon-anavi", | ||
"processor": "RP2040", | ||
"bootloader": "rp2040", | ||
"matrix_pins": { | ||
"direct": [ | ||
["GP26", "GP29", "GP0"] | ||
] | ||
}, | ||
"features": { | ||
"bootmagic": false, | ||
"command": false, | ||
"console": false, | ||
"extrakey": true, | ||
"mousekey": false, | ||
"nkro": true, | ||
"rgblight": true | ||
}, | ||
"rgblight": { | ||
"pin": "GP12", | ||
"led_count": 1, | ||
"hue_steps": 10, | ||
"saturation_steps": 17, | ||
"brightness_steps": 17, | ||
"max_brightness": 255, | ||
"animations": { | ||
"alternating": true, | ||
"breathing": true, | ||
"christmas": true, | ||
"knight": true, | ||
"rainbow_mood": true, | ||
"rainbow_swirl": true, | ||
"rgb_test": true, | ||
"snake": true, | ||
"static_gradient": true, | ||
"twinkle": true | ||
} | ||
}, | ||
"encoder": { | ||
"enabled": true, | ||
"rotary": [ | ||
{ | ||
"pin_a": "GP27", | ||
"pin_b": "GP28", | ||
"resolution": 2 | ||
}, | ||
{ | ||
"pin_a": "GP4", | ||
"pin_b": "GP3", | ||
"resolution": 2 | ||
}, | ||
{ | ||
"pin_a": "GP1", | ||
"pin_b": "GP2", | ||
"resolution": 2 | ||
} | ||
] | ||
}, | ||
"layouts": { | ||
"LAYOUT": { | ||
"layout": [ | ||
{ "label":"Mute", "x": 0, "y": 0, "matrix": [0, 0] }, | ||
{ "label":"RGB", "x": 0, "y": 1, "matrix": [0, 1] }, | ||
{ "label":"Animation", "x": 0, "y": 2, "matrix": [0, 2] } | ||
] | ||
} | ||
}, | ||
"usb": { | ||
"device_version": "1.0.0", | ||
"pid": "0x9A25", | ||
"vid": "0xFEED" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// Copyright 2022 Leon Anavi <leon@anavi.org> | ||
// SPDX-License-Identifier: GPL-2.0-or-later | ||
|
||
#include QMK_KEYBOARD_H | ||
|
||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
[0] = LAYOUT( | ||
KC_MUTE, RGB_TOG, RGB_MOD | ||
) | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
// Copyright 2022 Leon Anavi <leon@anavi.org> | ||
// SPDX-License-Identifier: GPL-2.0-or-later | ||
|
||
#include "quantum.h" | ||
#include <stdio.h> | ||
|
||
void keyboard_post_init_kb(void) { | ||
// Enable RGB LED | ||
setPinOutput(GP11); | ||
writePinHigh(GP11); | ||
rgblight_enable(); | ||
|
||
// Offload to the user func | ||
keyboard_post_init_user(); | ||
} | ||
|
||
#ifdef ENCODER_ENABLE | ||
bool encoder_update_kb(uint8_t index, bool clockwise) { | ||
if (!encoder_update_user(index, clockwise)) { return false; } | ||
if (0 == index) { | ||
if (clockwise) { | ||
tap_code(KC_VOLU); | ||
} else { | ||
tap_code(KC_VOLD); | ||
} | ||
} else if (1 == index) { | ||
if (clockwise) { | ||
tap_code(KC_UP); | ||
} else { | ||
tap_code(KC_DOWN); | ||
} | ||
} else if (2 == index) { | ||
if (clockwise) { | ||
tap_code(KC_LEFT); | ||
} else { | ||
tap_code(KC_RIGHT); | ||
} | ||
} | ||
return true; | ||
} | ||
#endif | ||
|
||
#ifdef OLED_ENABLE | ||
|
||
bool oled_task_kb(void) { | ||
|
||
if (!oled_task_user()) { | ||
return false; | ||
} | ||
|
||
// Host Keyboard Layer Status | ||
oled_write_ln_P(PSTR("ANAVI Knobs 3"), false); | ||
oled_write_ln_P(PSTR("Keymap: Default"), false); | ||
|
||
// Host Keyboard LED Status | ||
led_t led_state = host_keyboard_led_state(); | ||
oled_write_P(PSTR("Num Lock: "), false); | ||
oled_write_ln_P(led_state.num_lock ? PSTR("On") : PSTR("Off"), false); | ||
oled_write_P(PSTR("Caps Lock: "), false); | ||
oled_write_ln_P(led_state.caps_lock ? PSTR("On") : PSTR("Off"), false); | ||
oled_write_P(PSTR("Scroll Lock: "), false); | ||
oled_write_ln_P(led_state.scroll_lock ? PSTR("On") : PSTR("Off"), false); | ||
#ifdef RGBLIGHT_ENABLE | ||
static char rgbStatusLine1[26] = {0}; | ||
snprintf(rgbStatusLine1, sizeof(rgbStatusLine1), "RGB Mode: %d", rgblight_get_mode()); | ||
oled_write_ln(rgbStatusLine1, false); | ||
static char rgbStatusLine2[26] = {0}; | ||
snprintf(rgbStatusLine2, sizeof(rgbStatusLine2), "h:%d s:%d v:%d", rgblight_get_hue(), rgblight_get_sat(), rgblight_get_val()); | ||
oled_write_ln(rgbStatusLine2, false); | ||
#endif | ||
return false; | ||
} | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// Copyright 2022 Leon Anavi (@leon-anavi) | ||
// SPDX-License-Identifier: GPL-2.0-or-later | ||
|
||
#pragma once | ||
|
||
#include_next <mcuconf.h> | ||
|
||
#undef RP_I2C_USE_I2C0 | ||
#define RP_I2C_USE_I2C0 FALSE | ||
|
||
#undef RP_I2C_USE_I2C1 | ||
#define RP_I2C_USE_I2C1 TRUE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# ANAVI Knobs 3 | ||
|
||
Mini mechanical keyboard with 3 clickable rotary encoders, USB-C, RP2040 microcontroller and I2C slot for mini OLED display. | ||
|
||
* Keyboard Maintainer: [Leon Anavi](https://github.com/leon-anavi) | ||
* Hardware Supported: ANAVI Knobs 3 | ||
* Hardware Availability: [Crowd Supply](https://www.crowdsupply.com/anavi-technology/anavi-macro-pad-10), [GitHub repository](https://github.com/AnaviTechnology/anavi-knobs-3) | ||
|
||
Make example for this keyboard (after setting up your build environment): | ||
|
||
make anavi/knobs3:default | ||
|
||
Flashing example for this keyboard: | ||
|
||
make anavi/knobs3: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 top left key on the left half, or top right key on the right half, and then plug in the USB cable on that keyboard half. | ||
* **Physical reset button**: Double tap the reset button on the XIAO RP2040. | ||
* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is available. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
WS2812_DRIVER = vendor | ||
|
||
OLED_ENABLE = yes | ||
OLED_DRIVER = SSD1306 # Enable Support for SSD1306 or SH1106 OLED Displays; Communicating over I2C | ||
|
||
OPT_DEFS += -DHAL_USE_I2C=TRUE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// Copyright 2023 Gummor (@gumorr) | ||
// SPDX-License-Identifier: GPL-2.0-or-later | ||
|
||
#pragma once | ||
|
||
|
||
#define MATRIX_ROW_PINS { C6, D7, E6, B4, B5 } | ||
#define MATRIX_COL_PINS { F5, F6, F7, B1, B3, B2 } | ||
|
||
#define USE_I2C | ||
|
||
/* | ||
* 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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// Copyright 2023 Gummor (@gumorr) | ||
// SPDX-License-Identifier: GPL-2.0-or-later | ||
|
||
#include "gummykey.h" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// Copyright 2023 Gummor (@gumorr) | ||
// SPDX-License-Identifier: GPL-2.0-or-later | ||
|
||
#pragma once | ||
|
||
#include "quantum.h" | ||
|
||
#define ___ KC_NO | ||
|
||
#define LAYOUT_split_4x6_5( \ | ||
L00, L01, L02, L03, L04, L05, R05, R04, R03, R02, R01, R00, \ | ||
L10, L11, L12, L13, L14, L15, R15, R14, R13, R12, R11, R10, \ | ||
L20, L21, L22, L23, L24, L25, R25, R24, R23, R22, R21, R20, \ | ||
L30, L31, L32, L33, L34, L35, R35, R34, R33, R32, R31, R30, \ | ||
L40, L41, L42, L44, L45, R45, R44, R42, R41, R40 \ | ||
) \ | ||
{ \ | ||
{ L00, L01, L02, L03, L04, L05 }, \ | ||
{ L10, L11, L12, L13, L14, L15 }, \ | ||
{ L20, L21, L22, L23, L24, L25 }, \ | ||
{ L30, L31, L32, L33, L34, L35 }, \ | ||
{ L40, L41, L42, ___, L44, L45 }, \ | ||
{ R00, R01, R02, R03, R04, R05 }, \ | ||
{ R10, R11, R12, R13, R14, R15 }, \ | ||
{ R20, R21, R22, R23, R24, R25 }, \ | ||
{ R30, R31, R32, R33, R34, R35 }, \ | ||
{ R40, R41, R42, ___, R44, R45 } \ | ||
} |
Oops, something went wrong.