1
0
Fork 0

[Keyboard] add initial ergoslab directory (#7730)

* feat: add initial ergoslab directory

* fix: address all comments from noroadsleft

* fix: address comment from drashna

* feat: add swap hands config to ergoslab

* chore: change ergoslab image to real photo

* re
This commit is contained in:
Tom Saleeba 2020-01-03 09:10:13 +10:30 committed by James Young
parent 61173dce5d
commit 474f7f399c
11 changed files with 385 additions and 0 deletions

View file

@ -0,0 +1,28 @@
/*
Copyright 2019 Tom Saleeba <ergoslab@techotom.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 "config_common.h"
#define MOUSEKEY_INTERVAL 16
#define MOUSEKEY_DELAY 0
#define MOUSEKEY_TIME_TO_MAX 40
#define MOUSEKEY_MAX_SPEED 7
#define MOUSEKEY_WHEEL_MAX_SPEED 4
#define MOUSEKEY_WHEEL_TIME_TO_MAX 255
#define MOUSEKEY_WHEEL_DELAY 0

View file

@ -0,0 +1 @@
#include "ergoslab.h"

View file

@ -0,0 +1,7 @@
#pragma once
#ifdef KEYBOARD_ergoslab_rev1
#include "rev1.h"
#endif
#include "quantum.h"

View file

@ -0,0 +1,66 @@
{
"keyboard_name": "ergoslab",
"url": "https://github.com/tomsaleeba/ergoslab",
"maintainer": "tomsaleeba",
"width": 13,
"height": 5.25,
"layouts": {
"LAYOUT_ergoslab": {
"key_count": 52,
"layout": [
{"label":"Q", "x":0, "y":0.625},
{"label":"W", "x":1, "y":0.125},
{"label":"E", "x":2, "y":0},
{"label":"R", "x":3, "y":0.125},
{"label":"T", "x":4, "y":0.25},
{"label":"Y", "x":8, "y":0.25},
{"label":"U", "x":9, "y":0.125},
{"label":"I", "x":10, "y":0},
{"label":"O", "x":11, "y":0.125},
{"label":"P", "x":12, "y":0.625},
{"label":"A", "x":0, "y":1.625},
{"label":"S", "x":1, "y":1.125},
{"label":"D", "x":2, "y":1},
{"label":"F", "x":3, "y":1.125},
{"label":"G", "x":4, "y":1.25},
{"label":"H", "x":8, "y":1.25},
{"label":"J", "x":9, "y":1.125},
{"label":"K", "x":10, "y":1},
{"label":"L", "x":11, "y":1.125},
{"label":";", "x":12, "y":1.625},
{"label":"Z", "x":0, "y":2.625},
{"label":"X", "x":1, "y":2.125},
{"label":"C", "x":2, "y":2},
{"label":"V", "x":3, "y":2.125},
{"label":"B", "x":4, "y":2.25},
{"label":"N", "x":8, "y":2.25},
{"label":"M", "x":9, "y":2.125},
{"label":",", "x":10, "y":2},
{"label":".", "x":11, "y":2.125},
{"label":"/", "x":12, "y":2.625},
{"label":"'", "x":0, "y":3.625},
{"label":"Alt", "x":1, "y":3.125},
{"label":"Del", "x":2, "y":3},
{"label":"Enter", "x":3, "y":3.125},
{"label":"Shift", "x":4, "y":3.25},
{"label":"Ctrl", "x":5, "y":3.25},
{"label":"Numb", "x":7, "y":3.25},
{"label":"Space", "x":8, "y":3.25},
{"label":"Left", "x":9, "y":3.125},
{"label":"Down", "x":10, "y":3},
{"label":"Up", "x":11, "y":3.125},
{"label":"Right", "x":12, "y":3.625},
{"label":"[", "x":1, "y":4.25},
{"label":"(", "x":2, "y":4.25},
{"label":"Esc", "x":3, "y":4.25},
{"label":"Media", "x":4, "y":4.25},
{"label":"GUI", "x":5, "y":4.25},
{"label":"Tab", "x":7, "y":4.25},
{"label":"Mouse", "x":8, "y":4.25},
{"label":"Bspc", "x":9, "y":4.25},
{"label":")", "x":10, "y":4.25},
{"label":"]", "x":11, "y":4.25}
]
}
}
}

View file

@ -0,0 +1,29 @@
/*
Copyright 2019 Tom Saleeba <ergoslab@techotom.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
/* Use I2C or Serial, not both */
#define USE_SERIAL
// #define USE_I2C
/* Select hand configuration */
// #define MASTER_LEFT
#define MASTER_RIGHT
// #define EE_HANDS

View file

@ -0,0 +1,73 @@
#include QMK_KEYBOARD_H
enum layer_names {
BASE,
MDIA,
NUMB,
MOUS
};
#ifdef RGBLIGHT_ENABLE
#define ERGOSLAB_BRIGHTNESS 112
#define HSV_ERGOSLAB_ORANGE 28, 255, 16
#define HSV_ERGOSLAB_RED 0, 255, ERGOSLAB_BRIGHTNESS
#define HSV_ERGOSLAB_GREEN 85, 255, ERGOSLAB_BRIGHTNESS
#define HSV_ERGOSLAB_CYAN 128, 255, ERGOSLAB_BRIGHTNESS
#endif
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[BASE] = LAYOUT_ergoslab(
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P,
KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN,
KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH,
KC_QUOT, KC_LALT, KC_DEL, KC_ENT, KC_LSFT, KC_LCTL, MO(NUMB), KC_SPC, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT,
KC_LBRC, KC_LPRN, KC_ESC, MO(MDIA),KC_RGUI, KC_TAB, TG(MOUS), KC_BSPC, KC_RPRN, KC_RBRC
),
[MDIA] = LAYOUT_ergoslab(
KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10,
_______, _______, _______, _______, KC_F11, KC_F12, KC_HOME, KC_PGDN, KC_PGUP, KC_END,
_______, _______, _______, _______, _______, RGB_TOG, _______, _______, _______, KC_MUTE,
_______, RESET, _______, _______, _______, _______, _______, _______, _______, KC_VOLD, KC_VOLU, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
[NUMB] = LAYOUT_ergoslab(
KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_BSLS, KC_PIPE,
KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0,
KC_UNDS, KC_MINS, KC_PLUS, KC_EQL, KC_GRV, KC_COLN, KC_TILD, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, KC_QUOT, KC_DQT, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
[MOUS] = LAYOUT_ergoslab(
_______, _______, KC_MS_U, _______, _______, _______, _______, KC_WH_U, _______, _______,
_______, KC_MS_L, KC_MS_D, KC_MS_R, _______, _______, KC_BTN3, KC_WH_D, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, KC_ACL0, _______, KC_BTN2, KC_BTN1, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
};
#ifdef RGBLIGHT_ENABLE
layer_state_t layer_state_set_user(layer_state_t state) {
uint8_t layer = biton32(state);
switch (layer) {
case BASE:
rgblight_sethsv(HSV_ERGOSLAB_ORANGE);
break;
case MDIA:
rgblight_sethsv(HSV_ERGOSLAB_RED);
break;
case NUMB:
rgblight_sethsv(HSV_ERGOSLAB_GREEN);
break;
case MOUS:
rgblight_sethsv(HSV_ERGOSLAB_CYAN);
break;
default:
break;
}
return state;
};
#endif

View file

@ -0,0 +1,33 @@
# ergoslab
![ergoslab](https://raw.githubusercontent.com/tomsaleeba/ergoslab/master/ergoslab.jpg)
A split ergo 5x6 keyboard with hotswap sockets and a heap of thumb keys designed
by Tom Saleeba. [More info on the GitHub
Repo](https://github.com/tomsaleeba/ergoslab).
**Status** The ergoslab is currently being beta-tested.
* Keyboard Maintainer: [Tom Saleeba](https://github.com/tomsaleeba)
* Hardware Supported: Pro Micro (ATmega32U4)
* Hardware Availability: gerbers are available from the [releases page on the
GitHub repo](https://github.com/tomsaleeba/ergoslab/releases). Get them
manufactured at your favourite PCB house. I used JLCPCB.
Make example for this keyboard (after setting up your build environment):
make ergoslab:default
Example of flashing this keyboard:
make ergoslab: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).
A build guide for this keyboard can be found here: [Build
Guide](https://github.com/tomsaleeba/ergoslab/blob/master/build-guide.md)

View file

@ -0,0 +1,71 @@
/*
Copyright 2019 Tom Saleeba <ergoslab@techotom.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 0xFEED
#define PRODUCT_ID 0x5148
#define DEVICE_VER 0x0100
#define MANUFACTURER tomsaleeba
#define PRODUCT Ergoslab Keyboard
#define DESCRIPTION Split 45 percent ergonomic keyboard
/* key matrix size */
// Rows are doubled-up
#define MATRIX_ROWS 10
#define MATRIX_COLS 6
// wiring of each half
#define MATRIX_ROW_PINS { D4, C6, D7, E6, B4 }
#define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3 }
/* COL2ROW or ROW2COL */
#define DIODE_DIRECTION COL2ROW
/* Set 0 if debouncing isn't needed */
#define DEBOUNCE 5
/* serial.c configuration for split keyboard */
#define SOFT_SERIAL_PIN D2
/* ws2812 RGB LED */
#define RGB_DI_PIN D3
#define RGBLED_NUM 2 // Number of LEDs
// FIXME this following line should enable our layer status LEDs to work on both
// sides without need to wire them into a chain. It doesn't though. Uncommenting
// means the slave side of the keyboard stops working (and the LEDs don't work).
// #define RGBLED_SPLIT {1,1}
/*
* 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,18 @@
#include "rev1.h"
#ifdef SWAP_HANDS_ENABLE
__attribute__ ((weak))
const keypos_t hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
{{0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5}},
{{0, 6}, {1, 6}, {2, 6}, {3, 6}, {4, 6}, {5, 6}},
{{0, 7}, {1, 7}, {2, 7}, {3, 7}, {4, 7}, {5, 7}},
{{0, 8}, {1, 8}, {2, 8}, {3, 8}, {4, 8}, {5, 8}},
{{0, 9}, {1, 9}, {2, 9}, {3, 9}, {4, 9}, {5, 9}},
{{0, 0}, {1, 0}, {2, 0}, {3, 0}, {4, 0}, {5, 0}},
{{0, 1}, {1, 1}, {2, 1}, {3, 1}, {4, 1}, {5, 1}},
{{0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2}, {5, 2}},
{{0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3}},
{{0, 4}, {1, 4}, {2, 4}, {3, 4}, {4, 4}, {5, 4}},
};
#endif

View file

@ -0,0 +1,24 @@
#pragma once
#include "ergoslab.h"
#include "quantum.h"
#define LAYOUT_ergoslab( \
L00, L01, L02, L03, L04, R04, R03, R02, R01, R00, \
L10, L11, L12, L13, L14, R14, R13, R12, R11, R10, \
L20, L21, L22, L23, L24, R24, R23, R22, R21, R20, \
L30, L31, L32, L33, L34, L35, R35, R34, R33, R32, R31, R30, \
L41, L42, L43, L44, L45, R45, R44, R43, R42, R41 \
) { \
{ L00, L01, L02, L03, L04, KC_NO }, \
{ L10, L11, L12, L13, L14, KC_NO }, \
{ L20, L21, L22, L23, L24, KC_NO }, \
{ L30, L31, L32, L33, L34, L35 }, \
{ KC_NO, L41, L42, L43, L44, L45 }, \
{ R00, R01, R02, R03, R04, KC_NO }, \
{ R10, R11, R12, R13, R14, KC_NO }, \
{ R20, R21, R22, R23, R24, KC_NO }, \
{ R30, R31, R32, R33, R34, R35 }, \
{ KC_NO, R41, R42, R43, R44, R45 } \
}

View file

@ -0,0 +1,35 @@
# MCU name
MCU = atmega32u4
# Bootloader selection
# Teensy halfkay
# Pro Micro caterina
# Atmel DFU atmel-dfu
# LUFA DFU lufa-dfu
# QMK DFU qmk-dfu
# ATmega32A bootloadHID
# ATmega328P USBasp
BOOTLOADER = caterina
# Build Options
# change to "no" to disable the options, or define them in the Makefile in
# the appropriate keymap folder that will get included automatically
#
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 = yes # Commands for debug and configuration
NKRO_ENABLE = no # Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
MIDI_ENABLE = no # MIDI controls
AUDIO_ENABLE = no # Audio output on port C6
UNICODE_ENABLE = no # Unicode
BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
RGBLIGHT_ENABLE = yes # Enable WS2812 RGB underlight.
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
SPLIT_KEYBOARD = yes
DEFAULT_FOLDER = ergoslab/rev1