Add new handwired keyboard (Ergocheap) (#11857)

Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
master
Adrian 2021-04-08 23:47:24 +07:00 committed by GitHub
parent 2170b75b26
commit 75f83210f4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 402 additions and 0 deletions

View File

@ -0,0 +1,57 @@
/* Copyright 2020 QMK
*
* 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/>.
*/
/*
* This file was auto-generated by:
* `qmk chibios-confupdate -i keyboards/handwired/ergocheap/chconf.h -r platforms/chibios/common/configs/chconf.h`
*/
#pragma once
#define CH_CFG_ST_TIMEDELTA 0
#define CH_CFG_USE_TM FALSE
#define CH_CFG_USE_CONDVARS_TIMEOUT FALSE
#define CH_CFG_USE_MESSAGES_PRIORITY FALSE
#define CH_CFG_USE_MEMPOOLS FALSE
#define CH_CFG_USE_OBJ_FIFOS FALSE
#define CH_CFG_USE_PIPES FALSE
#define CH_CFG_USE_DYNAMIC FALSE
#define CH_CFG_USE_FACTORY FALSE
#define CH_CFG_FACTORY_OBJECTS_REGISTRY FALSE
#define CH_CFG_FACTORY_GENERIC_BUFFERS FALSE
#define CH_CFG_FACTORY_SEMAPHORES FALSE
#define CH_CFG_FACTORY_MAILBOXES FALSE
#define CH_CFG_FACTORY_OBJ_FIFOS FALSE
#define CH_CFG_FACTORY_PIPES FALSE
#define CH_DBG_ENABLE_STACK_CHECK FALSE
#include_next <chconf.h>

View File

@ -0,0 +1,67 @@
/*
Copyright 2021 xSteins <itsmesteins@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/>.
*/
#pragma once
/* USB Device descriptor parameter */
#define VENDOR_ID 0xFEDE //0xFEED
#define PRODUCT_ID 0x6942 //0x6465
#define DEVICE_VER 0x0001
#define MANUFACTURER xSteins
#define PRODUCT ERGOCHEAP
/* key matrix size */
#define MATRIX_ROWS 5
#define MATRIX_COLS 15
#define MATRIX_COL_PINS { A8, A9, B14, B12, B13, B15, B3, B11, A4, A5, A6, A7, B0, B1, B10 }
#define MATRIX_ROW_PINS { B5, B6, B7, B9, B8 }
#define DIODE_DIRECTION COL2ROW
/* key led setting */
//#define BACKLIGHT_PIN A8
//#define BACKLIGHT_PWM_DRIVER PWMD1
//#define BACKLIGHT_PWM_CHANNEL 1
//#define BACKLIGHT_LEVELS 6
//#define BACKLIGHT_BREATHING
//#define BREATHING_PERIOD 6
/* define if matrix has ghost */
//#define MATRIX_HAS_GHOST
/* Set 0 if debouncing isn't needed */
#define DEBOUNCE 5
#define TAPPING_TERM 500
/*
* 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
//#define NO_ACTION_MACRO
//#define NO_ACTION_FUNCTION

View File

@ -0,0 +1,16 @@
/* Copyright 2021 xSteins <itsmesteins@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 "ergocheap.h"

View File

@ -0,0 +1,42 @@
/*
Copyright 2021 xSteins <itsmesteins@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/>.
*/
#pragma once
#include "quantum.h"
/*
* The first section contains all of the arguments representing the physical
* layout of the board and position of the Keys.
*
* The second converts the arguments into a two-dimensional array which
* represents the switch matrix.
*/
#define LAYOUT( \
K00, K01, K02, K0B, K0D, K0E, K0F, \
K10, K11, K03, K04, K05, K06, K07, K08, K09, K0A, K1B, K1D, K1E, K1F, \
K20, K21,K12, K13, K14, K15, K16, K17, K18, K19, K1A, K2B, K2D, K2E, K2F, \
K30, K31,K22, K23, K24, K25, K26, K27, K28, K29, K3B, K3D, K3E, K3F, \
K40, K32, K33, K34, K35, K36, K37, K38, K39, K4B, K4D, K4E, K4F, \
K42, K44, K45, K46, K47, K48 \
) { \
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0D, K0E, K0F, }, \
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1D, K1E, K1F, }, \
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, KC_NO, K2B, K2D, K2E, K2F, }, \
{ K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, KC_NO, K3B, K3D, K3E, K3F, }, \
{ K40, KC_NO, K42, KC_NO, K44, K45, K46, K47, K48, KC_NO, KC_NO, K4B, K4D, K4E, K4F } \
}

View File

@ -0,0 +1,37 @@
/* Copyright 2020 QMK
*
* 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/>.
*/
/*
* This file was auto-generated by:
* `qmk chibios-confupdate -i keyboards/handwired/ergocheap/halconf.h -r platforms/chibios/common/configs/halconf.h`
*/
#pragma once
#define HAL_USE_DAC FALSE
#define HAL_USE_GPT FALSE
#define HAL_USE_I2C FALSE
#define HAL_USE_SERIAL_USB FALSE
#define PAL_USE_CALLBACKS FALSE
#define PAL_USE_WAIT FALSE
#include_next <halconf.h>

View File

@ -0,0 +1,12 @@
{
"keyboard_name": "Ergocheap",
"url": "",
"maintainer": "xSteins",
"width": 17.8,
"height": 11.85,
"layouts": {
"LAYOUT": {
"layout": [{"label":"0,12", "x":13.47, "y":0}, {"label":"0,13", "x":14.5, "y":0, "w":2}, {"label":"0,14", "x":16.5, "y":0}, {"label":"0,0", "x":0.75, "y":0.25}, {"label":"0,1", "x":1.75, "y":0.25}, {"label":"1,11", "x":13.1, "y":1}, {"label":"1,12", "x":14.1, "y":1}, {"label":"1,13", "x":15.1, "y":1, "w":1.5}, {"label":"1,14", "x":16.6, "y":1}, {"label":"1,0", "x":0.5, "y":1.25, "w":1.5}, {"label":"1,1", "x":2, "y":1.25}, {"label":"2,11", "x":13.55, "y":2}, {"label":"2,12", "x":14.55, "y":2, "w":2.25}, {"label":"2,13", "x":16.8, "y":2}, {"label":"2,0", "x":0.25, "y":2.25, "w":1.75}, {"label":"2,1", "x":2, "y":2.25}, {"label":"3,11", "x":13.05, "y":3}, {"label":"3,12", "x":14.05, "y":3, "w":1.75}, {"label":"3,13", "x":15.75, "y":3}, {"label":"3,14", "x":16.75, "y":3}, {"label":"3,0", "x":0.1, "y":3.25, "w":2.25}, {"label":"3,1", "x":2.35, "y":3.25}, {"label":"4,8", "x":13.5, "y":4, "w":1.25}, {"label":"4,12", "x":14.75, "y":4}, {"label":"4,13", "x":15.75, "y":4}, {"label":"4,14", "x":16.75, "y":4}, {"label":"4,0", "x":0.1, "y":4.25, "w":1.25}, {"label":"0,11", "x":2.45, "y":5.25}, {"label":"0,2", "x":-7.25, "y":5.35}, {"label":"0,3", "x":-5.1, "y":4.1}, {"label":"0,4", "x":-4.1, "y":4.1}, {"label":"0,5", "x":-3.0999999999999996, "y":4.1}, {"label":"0,6", "x":-2.0999999999999996, "y":4.1}, {"label":"1,2", "x":-5.7, "y":5.1}, {"label":"1,3", "x":-4.7, "y":5.1}, {"label":"1,4", "x":-3.7, "y":5.1}, {"label":"1,5", "x":-2.7, "y":5.1}, {"label":"2,2", "x":-5.45, "y":6.1}, {"label":"2,3", "x":-4.45, "y":6.1}, {"label":"2,4", "x":-3.45, "y":6.1}, {"label":"2,5", "x":-2.45, "y":6.1}, {"label":"3,2", "x":-4.85, "y":7.1}, {"label":"3,3", "x":-3.8499999999999996, "y":7.1}, {"label":"3,4", "x":-2.8499999999999996, "y":7.1}, {"label":"3,5", "x":-1.8499999999999996, "y":7.1}, {"label":"4,2", "x":-4.9, "y":8.1, "w":1.25}, {"label":"4,4", "x":-3.6500000000000004, "y":8.1, "w":2}, {"label":"4,5", "x":-1.6500000000000004, "y":8.1, "w":1.25}, {"label":"0,7", "x":0.3, "y":6.85}, {"label":"0,8", "x":1.3, "y":6.85}, {"label":"0,9", "x":2.3, "y":6.85}, {"label":"0,10", "x":3.3, "y":6.85}, {"label":"1,6", "x":-0.2, "y":7.85}, {"label":"1,7", "x":0.7999999999999999, "y":7.85}, {"label":"1,8", "x":1.8, "y":7.85}, {"label":"1,9", "x":2.8, "y":7.85}, {"label":"1,10", "x":3.8, "y":7.85}, {"label":"2,6", "x":0.05, "y":8.85}, {"label":"2,7", "x":1.05, "y":8.85}, {"label":"2,8", "x":2.05, "y":8.85}, {"label":"2,9", "x":3.05, "y":8.85}, {"label":"2,10", "x":4, "y":8.85}, {"label":"3,6", "x":0.3, "y":9.85}, {"label":"3,7", "x":1.3, "y":9.85}, {"label":"3,8", "x":2.3, "y":9.85}, {"label":"3,9", "x":3.3, "y":9.85}, {"label":"4,6", "x":-0.2, "y":10.85, "w":2.75}, {"label":"4,7", "x":2.5, "y":10.85, "w":1.25}]
}
}
}

View File

@ -0,0 +1,42 @@
/* Copyright 2021 xSteins <itsmesteins@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 QMK_KEYBOARD_H
// Defines names for use in layer keycodes and the keymap
enum layer_names {
_BASE,
_FN1,
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_BASE] = LAYOUT(
KC_ESC, KC_1, KC_2, KC_MINS, KC_EQL, KC_BSPC, KC_GRV,
KC_TAB, KC_Q, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL,
KC_CAPS, KC_A, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_SCLN, KC_QUOT, KC_ENT, KC_HOME,
KC_LSFT, KC_Z, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SLSH, TO(_FN1), KC_UP, KC_END,
KC_LCTL, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_LGUI, KC_LEFT, KC_DOWN, KC_RGHT,
KC_LALT, KC_SPC, MO(_FN1),KC_SPC, KC_SPC, MO(_FN1)
),
[_FN1] = LAYOUT(
KC_GRV, KC_F1, KC_F2, KC_F11, KC_F12, _______, _______,
_______, _______, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_UP, _______, _______, _______,
KC_LCTL, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT, _______, KC_LEFT, KC_RIGHT, _______, _______,
KC_LSFT, KC_LEFT, KC_S, _______, _______, _______, _______, KC_VOLD, KC_MUTE, KC_VOLU, KC_DOWN, TO(_BASE), KC_MS_WH_UP, _______,
_______, KC_UP, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_MS_WH_LEFT, KC_MS_WH_DOWN, KC_MS_WH_RIGHT,
KC_LGUI, _______, _______, _______, _______, _______
)
};

View File

@ -0,0 +1,60 @@
/* Copyright 2021 xSteins <itsmesteins@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 QMK_KEYBOARD_H
// Defines names for use in layer keycodes and the keymap
enum layer_names {
_BASE,
_FN1,
_FN2,
_FN3,
};
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_BASE] = LAYOUT(
KC_ESC, KC_1, KC_2, KC_MINS, KC_EQL, KC_BSPC, KC_GRV,
KC_TAB, KC_Q, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_LBRC, KC_RBRC, KC_BSLS, KC_DEL,
KC_CAPS, KC_A, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_SCLN, KC_QUOT, KC_ENT, KC_HOME,
KC_LSFT, KC_Z, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SLSH, TO(_FN1), KC_UP, KC_END,
KC_LCTL, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_LGUI, KC_LEFT, KC_DOWN, KC_RGHT,
KC_LALT, KC_SPC, MO(_FN1),KC_SPC, KC_SPC, MO(_FN1)
),
[_FN1] = LAYOUT(
KC_GRV, KC_F1, KC_F2, KC_F11, KC_F12, _______, _______,
_______, _______, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_UP, _______, _______, _______,
KC_LCTL, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT, _______, KC_LEFT, KC_RIGHT, _______, _______,
KC_LSFT, KC_LEFT, KC_S, _______, _______, _______, _______, KC_VOLD, KC_MUTE, KC_VOLU, KC_DOWN, TO(_BASE), KC_MS_WH_UP, _______,
_______, KC_UP, KC_DOWN, KC_RGHT, _______, _______, _______, _______, _______, _______, KC_MS_WH_LEFT, KC_MS_WH_DOWN, KC_MS_WH_RIGHT,
KC_LGUI, _______, _______, _______, _______, _______
),
[_FN2] = LAYOUT(
_______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______
),
[_FN3] = LAYOUT(
_______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______
)
};

View File

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

View File

@ -0,0 +1,28 @@
/* Copyright 2020 QMK
*
* 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/>.
*/
/*
* This file was auto-generated by:
* `qmk chibios-confupdate -i keyboards/handwired/ergocheap/mcuconf.h -r platforms/chibios/STM32_F103_STM32DUINO/configs/mcuconf.h`
*/
#pragma once
#include_next <mcuconf.h>
#undef STM32_PWM_USE_TIM1
#define STM32_PWM_USE_TIM1 TRUE

View File

@ -0,0 +1,15 @@
# Ergocheap handwired keyboard
Ergocheap is an ergonomic keyboard with layout forked from adelheid with some minor adjustment in 13-15th row and standard keycaps size
![Ergocheap](https://i.imgur.com/II3aBYgl.jpg)
* Keyboard Maintainer: [xSteins](https://github.com/xSteins)
* Hardware Supported: bluepill
* Hardware Availability: [case files](https://github.com/xSteins/Mechanical-Keyboard/tree/master/ErgoCheap/CASE)
Make example for this keyboard (after setting up your build environment):
make handwired/ergocheap: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,25 @@
# MCU name
MCU = STM32F103
# Bootloader selection
BOOTLOADER = stm32duino
# Enter lower-power sleep mode when on the ChibiOS idle thread
OPT_DEFS += -DCORTEX_ENABLE_WFI_IDLE=TRUE
# Build Options
# change yes to no to disable
#
BOOTMAGIC_ENABLE = full # Virtual DIP switch configuration
MOUSEKEY_ENABLE = yes # Mouse keys
EXTRAKEY_ENABLE = yes # Audio control and System control
CONSOLE_ENABLE = yes # 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 = yes # 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