Skip to content

Commit

Permalink
[Keyboard] Add Elrgo S to keyboards/handwired (#13893)
Browse files Browse the repository at this point in the history
Co-authored-by: Drashna Jaelre <drashna@live.com>
Co-authored-by: Ryan <fauxpark@gmail.com>
  • Loading branch information
3 people authored Aug 19, 2021
1 parent 1bfbaae commit c592128
Show file tree
Hide file tree
Showing 8 changed files with 303 additions and 0 deletions.
58 changes: 58 additions & 0 deletions keyboards/handwired/elrgo_s/config.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
/*
Copyright 2021 Yaroslav Smirnov <elorenn@bk.ru>
*
* 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"

// Rows are doubled-up for splits
#define MATRIX_ROWS 8
#define MATRIX_COLS 6

// Wiring of each half
#define MATRIX_ROW_PINS { B1, B3, B2, B6 }
#define MATRIX_COL_PINS { D4, C6, D7, E6, B4, B5 }
// Reversed sort

#define DIODE_DIRECTION COL2ROW

/* USB Device descriptor parameter */
#define PRODUCT Elrgo S
#define MANUFACTURER Eloren
#define VENDOR_ID 0x454C
#define PRODUCT_ID 0x3436
#define DEVICE_VER 0x0001

/* Set 0 if debouncing isn't needed */
#define DEBOUNCE 5

/* serial.c configuration for split keyboard */
#define SOFT_SERIAL_PIN D0


/* 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
17 changes: 17 additions & 0 deletions keyboards/handwired/elrgo_s/elrgo_s.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
/* Copyright 2021 Yaroslav Smirnov <elorenn@bk.ru>
*
* 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 "elrgo_s.h"
38 changes: 38 additions & 0 deletions keyboards/handwired/elrgo_s/elrgo_s.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/* Copyright 2021 Yaroslav Smirnov <elorenn@bk.ru>
*
* 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_split_3x6_5(\
L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
L31, L32, L33, L34, L35, R30, R31, R32, R33, R34 \
) \
{ \
{ L00, L01, L02, L03, L04, L05 }, \
{ L10, L11, L12, L13, L14, L15 }, \
{ L20, L21, L22, L23, L24, L25 }, \
{KC_NO, L31, L32, L33, L34, L35}, \
\
{ R00, R01, R02, R03, R04, R05 }, \
{ R10, R11, R12, R13, R14, R15 }, \
{ R20, R21, R22, R23, R24, R25 }, \
{ R30, R31, R32, R33, R34, KC_NO} \
}
59 changes: 59 additions & 0 deletions keyboards/handwired/elrgo_s/info.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
{
"keyboard_name": "Elrgo S",
"url": "",
"maintainer": "qmk",
"width": 17,
"height": 4,
"layouts": {
"LAYOUT_split_3x6_5": {
"layout": [
{"label":"L00", "x":0, "y":0},
{"label":"L01", "x":1, "y":0},
{"label":"L02", "x":2, "y":0},
{"label":"L03", "x":3, "y":0},
{"label":"L04", "x":4, "y":0},
{"label":"L05", "x":5, "y":0},
{"label":"R00", "x":9, "y":0},
{"label":"R01", "x":10, "y":0},
{"label":"R02", "x":11, "y":0},
{"label":"R03", "x":12, "y":0},
{"label":"R04", "x":13, "y":0},
{"label":"R05", "x":14, "y":0},
{"label":"L10", "x":0, "y":1},
{"label":"L11", "x":1, "y":1},
{"label":"L12", "x":2, "y":1},
{"label":"L13", "x":3, "y":1},
{"label":"L14", "x":4, "y":1},
{"label":"L15", "x":5, "y":1},
{"label":"R10", "x":9, "y":1},
{"label":"R11", "x":10, "y":1},
{"label":"R12", "x":11, "y":1},
{"label":"R13", "x":12, "y":1},
{"label":"R14", "x":13, "y":1},
{"label":"R15", "x":14, "y":1},
{"label":"L20", "x":0, "y":2},
{"label":"L21", "x":1, "y":2},
{"label":"L22", "x":2, "y":2},
{"label":"L23", "x":3, "y":2},
{"label":"L24", "x":4, "y":2},
{"label":"L25", "x":5, "y":2},
{"label":"R20", "x":9, "y":2},
{"label":"R21", "x":10, "y":2},
{"label":"R22", "x":11, "y":2},
{"label":"R23", "x":12, "y":2},
{"label":"R24", "x":13, "y":2},
{"label":"R25", "x":14, "y":2},
{"label":"L31", "x":3, "y":3},
{"label":"L32", "x":4, "y":3},
{"label":"L33", "x":5, "y":3},
{"label":"L34", "x":6, "y":3},
{"label":"L35", "x":6, "y":2},
{"label":"R30", "x":8, "y":2},
{"label":"R31", "x":8, "y":3},
{"label":"R32", "x":9, "y":3},
{"label":"R33", "x":10, "y":3},
{"label":"R34", "x":11, "y":3}
]
}
}
}
22 changes: 22 additions & 0 deletions keyboards/handwired/elrgo_s/keymaps/default/config.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
/* Copyright 2021 Yaroslav Smirnov <elorenn@bk.ru>
*
* 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

#define USE_SERIAL

#define MASTER_LEFT
// #define MASTER_RIGHT
58 changes: 58 additions & 0 deletions keyboards/handwired/elrgo_s/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
/* Copyright 2021 Yaroslav Smirnov <elorenn@bk.ru>
*
* 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

enum layers { _QWERTY, _LOWER, _RAISE, _ADJUST };

#define LOWER TT(_LOWER)
#define RAISE MO(_RAISE)

#define M_SHLL LCTL(KC_LSFT)
#define M_SHLA LCTL(KC_LALT)
#define M_BBSLS LSFT(KC_BSLS)
#define M_FLEFT LCTL(KC_LEFT)
#define M_FRIGHT LCTL(KC_RIGHT)

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[_QWERTY] = LAYOUT_split_3x6_5(
KC_ESC , KC_Q , KC_W , KC_E , KC_R , KC_T , KC_Y , KC_U , KC_I , KC_O , KC_P , KC_BSPC ,
KC_LBRC , KC_A , KC_S , KC_D , KC_F , KC_G , KC_H , KC_J , KC_K , KC_L , KC_SCLN , KC_QUOT ,
KC_RBRC , KC_Z , KC_X , KC_C , KC_V , KC_B , KC_N , KC_M , KC_COMM , KC_DOT , KC_SLSH , KC_GRAVE,
KC_LGUI , KC_LCTL , KC_LSFT , LOWER , M_SHLL , M_SHLA , RAISE , KC_SPC , KC_LALT , KC_ENT
),

[_LOWER] = LAYOUT_split_3x6_5(
KC_ESC , KC_PDOT , KC_PMNS , KC_PPLS , KC_MINS , KC_EQL , KC_MUTE , KC_MSTP , KC_MPLY , KC_MPRV , KC_MNXT , KC_BSPC ,
KC_PAST , KC_1 , KC_2 , KC_3 , KC_4 , KC_5 , KC_F1 , KC_F2 , KC_F3 , KC_F4 , KC_F5 , KC_F6 ,
KC_PSLS , KC_6 , KC_7 , KC_8 , KC_9 , KC_0 , KC_F7 , KC_F8 , KC_F9 , KC_F10 , KC_F11 , KC_F12 ,
KC_LGUI , KC_LCTL , KC_LSFT , KC_TRNS , M_SHLL , M_SHLA , KC_TRNS , KC_SPC , KC_LALT , KC_ENT
),

[_RAISE] = LAYOUT_split_3x6_5(
KC_ESC , KC_PDOT , M_BBSLS , KC_BSLS , LSFT(KC_MINS), LSFT(KC_EQL), KC_HOME , KC_WH_L , KC_UP , KC_WH_R , KC_PGUP , KC_BSPC ,
KC_TAB , LSFT(KC_1), LSFT(KC_2), LSFT(KC_3), LSFT(KC_4) , LSFT(KC_5) , M_FLEFT , KC_LEFT , KC_DOWN , KC_RIGHT, M_FRIGHT, KC_DEL ,
LSFT(KC_TAB), LSFT(KC_6), LSFT(KC_7), LSFT(KC_8), LSFT(KC_9) , LSFT(KC_0) , KC_END , KC_F22 , KC_F23 , KC_CAPS , KC_PGDN , MO(_ADJUST),
KC_LGUI , KC_LCTL , KC_LSFT , KC_LALT , M_SHLL , M_SHLA , KC_TRNS , KC_SPC , KC_RALT , KC_ENT
),

[_ADJUST] = LAYOUT_split_3x6_5(
KC_NO , KC_SLEP , KC_VOLU , KC_BRIU , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO , KC_NLCK ,
KC_NO , KC_WAKE , KC_VOLD , KC_BRID , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO , KC_NO ,
KC_NO , KC_NO , KC_NO , KC_F13 , KC_F14 , KC_F15 , KC_F16 , KC_F17 , KC_F18 , KC_NO , KC_NO , MO(_ADJUST),
RESET , KC_NO , KC_NO , KC_TRNS , KC_NO , KC_NO , KC_TRNS , KC_TRNS , KC_NO , KC_NO
)
};
28 changes: 28 additions & 0 deletions keyboards/handwired/elrgo_s/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Elrgo S Split Keyboard

This is a fork of the VOID Ergo S with QMK Configurator support.

Elrgo S uses 2x Arduino Pro Micro (ATmega32U4) with 3D printed case.

[Building guide, models for 3D printing](https://github.com/Eloren1/Elrgo_S)

* Keyboard Maintainer: [Eloren](https://github.com/Eloren1)
* Hardware Supported: Arduino Pro Micro
* Hardware Availability: [Open Source](https://github.com/Eloren1/Elrgo_S)

Make example for this keyboard (after setting up your build environment):

make handwired/elrgo_s:default

Flashing example for this keyboard:

make handwired/elrgo_s: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 2 ways:

* **Physical reset button**: Briefly press the button through the hole on the left side of the case.
* **Keycode in layout**: Press the key mapped to `RESET` if it is available
23 changes: 23 additions & 0 deletions keyboards/handwired/elrgo_s/rules.mk
Original file line number Diff line number Diff line change
@@ -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 = 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 = no # 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
SPLIT_KEYBOARD = yes

0 comments on commit c592128

Please sign in to comment.