Browse Source

Initial release of the vckyb6 keymap

main
Abhas Abhinav 2 years ago
commit
334f682fc0
8 changed files with 262 additions and 0 deletions
  1. +46
    -0
      config.h
  2. +19
    -0
      info.json
  3. +36
    -0
      keymaps/default/keymap.c
  4. +0
    -0
      keymaps/default/rules.mk
  5. +94
    -0
      readme.md
  6. +24
    -0
      rules.mk
  7. +16
    -0
      vckyb6.c
  8. +27
    -0
      vckyb6.h

+ 46
- 0
config.h View File

@ -0,0 +1,46 @@
/* Copyright 2020 Bratzworth
*
* 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
#include "config_common.h"
/* USB Device descriptor parameter */
#define VENDOR_ID 0xBEEF
#define PRODUCT_ID 0x0008
#define DEVICE_VER 0x0001
#define MANUFACTURER Mostly Harmless
#define PRODUCT vckb6
/* key matrix size */
#define MATRIX_ROWS 2
#define MATRIX_COLS 3
/* pin-out */
#define MATRIX_ROW_PINS { C6, D4 }
#define MATRIX_COL_PINS { B1, B2, B3 }
#define ENCODERS_PAD_A { D0 }
#define ENCODERS_PAD_B { D1 }
#define ENCODER_RESOLUTION 4
/* COL2ROW or ROW2COL */
#define DIODE_DIRECTION COL2ROW
/* VIAL */
#define VIAL_KEYBOARD_UID {0x61, 0x45, 0x29, 0x5C, 0xF3, 0x73, 0xF0, 0x1B}
#define VIAL_ENCODER_DEFAULT { KC_VOLD, KC_VOLU, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS }
#define VIAL_ENCODER_KEYCODE_DELAY 25

+ 19
- 0
info.json View File

@ -0,0 +1,19 @@
{
"keyboard_name": "vckyb6",
"url": "https://sovran.dev/mh/vckyb6/",
"maintainer": "mh",
"width": 3,
"height": 2,
"layouts": {
"LAYOUT": {
"layout": [
{"x":0, "y":0},
{"x":1, "y":0},
{"x":2, "y":0},
{"x":0, "y":1},
{"x":1, "y":1},
{"x":2, "y":1}
]
}
}
}

+ 36
- 0
keymaps/default/keymap.c View File

@ -0,0 +1,36 @@
/* Copyright 2020 Bratzworth *
* 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
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT(
LCA(KC_C), KC_F11, LCTL(KC_D),
MO(1), LCTL(KC_E), LCTL(KC_D)
),
[1] = LAYOUT(
LCA(KC_C), KC_F11, RESET,
KC_TRNS, LCTL(KC_E), KC_MUTE
)
};
bool encoder_update_user(uint8_t index, bool clockwise) {
if (clockwise) {
tap_code(KC_VOLU);
} else {
tap_code(KC_VOLD);
}
return true;
}

+ 0
- 0
keymaps/default/rules.mk View File


+ 94
- 0
readme.md View File

@ -0,0 +1,94 @@
# Welcome to the Mostly Harmless vckyb6
## Introduction
`vckyb6` is a small macro pad that offers quick access to common keyboard
shortcuts that might be useful during video conferences and meetings.
## Why?
Keyboard shortcuts are good ways of quickly doing something - as compared to
using the mouse to click around the screen. Most video conferencing
applications have built-in keyboard shortcuts to aid activities such as
mute/un-mute or toggling the video or raising the hand and so on.
Most of these keyboard shortcuts, unfortunately, require the use of single or
multiple keys (eg. `CTRL + D` or `CTRL + ALT + C`). These can not only be
difficult to remember but also tough for children to use or use with one-hand.
## Enter: Custom Keyboards
A custom programmable keyboard can send complex keystrokes or key sequences or
even macros to the computer on the click of a single button. This means that
one need not remember complex keyboard shortcuts and can instead just press a
button to do the job.
The custom keyboard can be even have multiple layers of shortcuts so that it
can be used in a similar manner with multiple video conferencing tools.
# Compiling and Flashing the keymap
1. Close the `qmk_firmware` repository from:
<https://github.com/qmk/qmk_firmware/>
You can also use this mirror on sovran.dev:
<https://sovran.dev/mh/qmk_firmware>
2. Pull in the `qmk_firmware` submodules:
```
cd qmk_firmware/
make git-submodules
```
3. Clone [this repository](https://sovran.dev/mh/vckyb6) into `keyboards/mh/`:
```
cd qmk_firmware/
mkdir keyboards/mh/
cd keyboards/mh/
git clone https://sovran.dev/mh/vckyb6/
```
4. Now compile the firmware:
```
make mh/vckyb6:default
```
5. Reset your keyboard and put it into programming mode and then flash the
firmware:
```
make mh/vckyb6:default:flash
```
## USB Messages:
You should see messages similar to these when you plugin the keyboard. Run
`sudo dmesg` to check:
```
usb 1-3.2: new full-speed USB device number 18 using xhci_hcd
usb 1-3.2: New USB device found, idVendor=beef, idProduct=0008, bcdDevice= 0.01
usb 1-3.2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
usb 1-3.2: Product: vckb6
usb 1-3.2: Manufacturer: Mostly Harmless
input: Mostly Harmless vckb6 as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3.2/1-3.2:1.0/0003:BEEF:0008.0078/input/input232
hid-generic 0003:BEEF:0008.0078: input,hidraw5: USB HID v1.11 Keyboard [Mostly Harmless vckb6] on usb-0000:00:14.0-3.2/input0
input: Mostly Harmless vckb6 Mouse as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3.2/1-3.2:1.1/0003:BEEF:0008.0079/input/input233
input: Mostly Harmless vckb6 System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3.2/1-3.2:1.1/0003:BEEF:0008.0079/input/input234
input: Mostly Harmless vckb6 Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3.2/1-3.2:1.1/0003:BEEF:0008.0079/input/input235
input: Mostly Harmless vckb6 Keyboard as /devices/pci0000:00/0000:00:14.0/usb1/1-3/1-3.2/1-3.2:1.1/0003:BEEF:0008.0079/input/input236
hid-generic 0003:BEEF:0008.0079: input,hidraw7: USB HID v1.11 Mouse [Mostly Harmless vckb6] on usb-0000:00:14.0-3.2/input1
```
## Credits
The repository and code is inspired by
<https://github.com/xkonni/qmk_xkonni_xk8/> and build upon the excellent
[qmk_firmware project](https://qmk.fm).

+ 24
- 0
rules.mk View File

@ -0,0 +1,24 @@
# MCU name
MCU = atmega32u4
# Bootloader selection
BOOTLOADER = caterina
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration
MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = no # Console for debug
COMMAND_ENABLE = no # Commands for debug and configuration
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
NKRO_ENABLE = yes # USB Nkey Rollover
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
DIP_SWITCH_ENABLE = no
ENCODER_ENABLE = yes # enable rotary encoders

+ 16
- 0
vckyb6.c View File

@ -0,0 +1,16 @@
/* Copyright 2020 Bratzworth
*
* 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 "vckyb6.h"

+ 27
- 0
vckyb6.h View File

@ -0,0 +1,27 @@
/* Copyright 2020 Bratzworth
*
* 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
#include "quantum.h"
#define LAYOUT( \
k00, k01, k02, \
k03, k04, k05 \
) \
{ \
{ k00, k01, k02 }, \
{ k03, k04, k05 } \
}

Loading…
Cancel
Save