Added ConsoleKeyboard (#11950)

Co-authored-by: Joel Challis <git@zvecr.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
master
gazeddy 2021-02-20 22:46:43 +00:00 committed by GitHub
parent 8efc3b39de
commit d35d65f2e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 243 additions and 0 deletions

View File

@ -0,0 +1,67 @@
/* Copyright 2021 Gareth Edwards
*
* 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 0x6761
#define PRODUCT_ID 0x3432
#define DEVICE_VER 0x0001
#define MANUFACTURER Stream Cheap
#define PRODUCT Console Keyboard
/* key matrix size */
#define MATRIX_ROWS 2
#define MATRIX_COLS 12
/*
* 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 { D1, D0 }
#define MATRIX_COL_PINS { D4, C6, D7, C4, B1, B3, B2, B6, C5, E6, B4, B5 }
#define DIODE_DIRECTION COL2ROW
#define RGB_DI_PIN F4
#ifdef RGB_DI_PIN
#define RGBLED_NUM 6
#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
#endif

View File

@ -0,0 +1,16 @@
/* Copyright 2021 Gareth Edwards
*
* 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 "consolekeyboard.h"

View File

@ -0,0 +1,26 @@
/* Copyright 2021 Gareth Edwards
*
* 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( \
K000, K001, K002, K004, K005, K006, K007, K009, K010, K011, \
K100, K101, K102, K104, K105, K106, K107, K109, K110, K111 \
) { \
{ K000, K001, K002, KC_NO, K004, K005, K006, K007, KC_NO, K009, K010, K011 }, \
{ K100, K101, K102, KC_NO, K104, K105, K106, K107, KC_NO, K109, K110, K111 }, \
}

View File

@ -0,0 +1,34 @@
{
"keyboard_name": "Console Keyboard",
"url": "https://www.thingiverse.com/thing:3167050",
"maintainer": "Gareth Edwards",
"width": 12,
"height": 2,
"layouts": {
"LAYOUT": {
"layout": [
{"label":"K00 (D1,D4)", "x":0, "y":0},
{"label":"K01 (D1,C6)", "x":1, "y":0},
{"label":"K02 (D1,D7)", "x":2, "y":0},
{"label":"K04 (D1,B3)", "x":4, "y":0},
{"label":"K05 (D1,B2)", "x":5, "y":0},
{"label":"K06 (D1,B6)", "x":6, "y":0},
{"label":"K07 (D1,E6)", "x":7, "y":0},
{"label":"K09 (D1,B5)", "x":9, "y":0},
{"label":"K0A (D1,C4)", "x":10, "y":0},
{"label":"K0B (D1,C5)", "x":11, "y":0},
{"label":"K10 (D0,D4)", "x":0, "y":1},
{"label":"K11 (D0,C6)", "x":1, "y":1},
{"label":"K12 (D0,D7)", "x":2, "y":1},
{"label":"K14 (D0,B3)", "x":4, "y":1},
{"label":"K15 (D0,B2)", "x":5, "y":1},
{"label":"K16 (D0,B6)", "x":6, "y":1},
{"label":"K17 (D0,E6)", "x":7, "y":1},
{"label":"K19 (D0,B5)", "x":9, "y":1},
{"label":"K1A (D0,C4)", "x":10, "y":1},
{"label":"K1B (D0,C5)", "x":11, "y":1}
]
}
}
}

View File

@ -0,0 +1,25 @@
/* Copyright 2021 Gareth Edwards
*
* 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(
KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0,
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P
),
};

View File

@ -0,0 +1,36 @@
/* Copyright 2021 Gareth Edwards
*
* 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(
KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0,
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P
),
[1] = LAYOUT(
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
),
[2] = LAYOUT(
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
),
[3] = LAYOUT(
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
),
};

View File

@ -0,0 +1 @@
VIA_ENABLE = yes

View File

@ -0,0 +1,15 @@
# Console Keyboard
[Console Keyboard](https://i.imgur.com/5aLT7CLl.jpeg)
A 3d printed macro pad based on the Stream Cheap
* Keyboard Maintainer: [Gareth Edwards](https://github.com/gazeddy)
* Hardware Supported: Arduino Pro Micro
* Hardware Availability:https://www.thingiverse.com/thing:3167050
Make example for this keyboard (after setting up your build environment):
make handwired/consolekeyboard: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).

View File

@ -0,0 +1,23 @@
# MCU name
MCU = atmega32u4
# Bootloader selection
BOOTLOADER = caterina
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
MOUSEKEY_ENABLE = no # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = no # Console for debug
COMMAND_ENABLE = yes # 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 = yes # Enable keyboard RGB underglow
BLUETOOTH_ENABLE = no # Enable Bluetooth
AUDIO_ENABLE = no # Audio output
LTO_ENABLE = yes # Link time optimize