Compare commits
5 Commits
bf3e3b4d3e
...
5b697beacb
Author | SHA1 | Date | |
---|---|---|---|
5b697beacb | |||
2268816111 | |||
eeecb56966 | |||
9fa165a9a0 | |||
96a7967e0e |
16
Makefile
Normal file
16
Makefile
Normal file
@ -0,0 +1,16 @@
|
||||
all: clean build flash
|
||||
|
||||
clean:
|
||||
rm qmk_firmware/ktec_ergodone_dejvino.hex
|
||||
|
||||
build: qmk_firmware/ktec_ergodone_dejvino.hex
|
||||
|
||||
flash: build | hid_bootloader_cli
|
||||
sudo ./hid_bootloader_cli -mmcu=atmega32u4 qmk_firmware/ktec_ergodone_dejvino.hex
|
||||
|
||||
qmk_firmware/ktec_ergodone_dejvino.hex:
|
||||
cd qmk_firmware && make ktec/ergodone:dejvino
|
||||
|
||||
hid_bootloader_cli:
|
||||
wget https://raw.githubusercontent.com/kairyu/tkg-toolkit/master/linux/bin/hid_bootloader_cli -O hid_bootloader_cli
|
||||
chmod +x hid_bootloader_cli
|
22
README.md
22
README.md
@ -1,30 +1,26 @@
|
||||
# Dejvino's ErgoDone Keyboard Firmware
|
||||
|
||||
## Compile
|
||||
## Setup
|
||||
1. Clone this repo in recursive mode (with submodules): `git clone --recurse-submodules <url>`
|
||||
2. Setup QMK (see [docs](https://docs.qmk.fm/#/newbs_getting_started))
|
||||
1. Install qmk helper: `python3 -m pip install --user qmk`
|
||||
2. Run the setup: `qmk setup`
|
||||
3. Compile (inside `qmk_firmware`)
|
||||
1. default ErgoDone keyboard (optional): `make ktec/ergodone:default`
|
||||
2. link Dejvino's keyboard layout: `ln -s $(pwd)../keymap keyboards/ktec/ergodone/keymaps/dejvino`
|
||||
3. Dejvino's ErgoDone keyboard layout: `make ktec/ergodone:dejvino`
|
||||
3. Install Dejvino's keyboard layout: `ln -s $(pwd)../keymap keyboards/ktec/ergodone/keymaps/dejvino`
|
||||
|
||||
## Compile
|
||||
Run `make build`.
|
||||
|
||||
## Flash
|
||||
(see [ErgoDone Readme](./qmk_firmware/keyboards/ktec/ergodone/readme.md))
|
||||
If you're not on Linux, download the [TKG Toolkit](https://github.com/kairyu/tkg-toolkit) flashing utility for your system manually, otherwise let `make` do it.
|
||||
|
||||
Get the [TKG Toolkit](https://github.com/kairyu/tkg-toolkit) flashing utility: `wget https://raw.githubusercontent.com/kairyu/tkg-toolkit/master/linux/bin/hid_bootloader_cli -O hid_bootloader_cli && chmod +x hid_bootloader_cli`
|
||||
|
||||
### Enter flashing mode
|
||||
1. Enter flashing mode
|
||||
1. Disconnect KBD
|
||||
2. Press and hold two top-right-most keys on the left-half KBD
|
||||
3. Connect KBD (LEDs will be blinking)
|
||||
2. Run `make flash`. (Tip: just run `make` to compile & flash)
|
||||
|
||||
### Flashing
|
||||
1. `sudo ./hid_bootloader_cli -mmcu=atmega32u4 qmk_firmware/ktec_ergodone_dejvino.hex`
|
||||
2. Disconnect & connect KBD
|
||||
(see [ErgoDone Readme](https://github.com/qmk/qmk_firmware/blob/master/keyboards/ktec/ergodone/readme.md) for details)
|
||||
|
||||
## Resources
|
||||
- [QMK Firmware](https://github.com/qmk/qmk_firmware)
|
||||
- [TKG Toolkit](https://github.com/kairyu/tkg-toolkit)
|
||||
- [ErgoDone Readme](./qmk_firmware/keyboards/ktec/ergodone/readme.md)
|
||||
|
@ -11,14 +11,11 @@
|
||||
|
||||
enum custom_keycodes {
|
||||
PLACEHOLDER = SAFE_RANGE, // can always be here
|
||||
VRSN,
|
||||
DYNAMIC_MACRO_RANGE
|
||||
};
|
||||
|
||||
#include "dynamic_macro.h"
|
||||
|
||||
// [Info]
|
||||
// Meh = LCtrl + LAlt + LShift
|
||||
// L_X = Layer X
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
/* Keymap 0: WORKMAN-D Basic layer
|
||||
@ -37,7 +34,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* ,-------------. ,-------------.
|
||||
* |L_NUMB| ` | | Home | End |
|
||||
* ,------|------|------| |------+------+------.
|
||||
* | | | App | | PgUp | | |
|
||||
* | | | Alt | | PgUp | | |
|
||||
* | Space|Backsp|------| |------| Del |Enter |
|
||||
* | |ace | LCmd | | PgDn | | |
|
||||
* `--------------------' `--------------------'
|
||||
@ -79,7 +76,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
* | | | | 0 | . | | | | | | |
|
||||
* `-----------------------------------' `----------------------------------'
|
||||
* ,-------------. ,-------------
|
||||
* | | | | | |
|
||||
* | |NLock | | | |
|
||||
* ,------|------|------| |------+------+------.
|
||||
* | | | | | | | |
|
||||
* | | |------| |------| | |
|
||||
@ -94,7 +91,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
_______,_______,_______,KC_KP_4,KC_KP_5,KC_KP_6,
|
||||
_______,_______,_______,KC_KP_1,KC_KP_2,KC_KP_3,KC_KP_ENTER,
|
||||
_______,_______,_______,KC_KP_0,KC_KP_DOT,
|
||||
_______,_______,
|
||||
_______,KC_NUM_LOCK,
|
||||
_______,
|
||||
_______,_______,_______,
|
||||
// right hand
|
||||
@ -152,30 +149,21 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
};
|
||||
|
||||
const uint16_t PROGMEM fn_actions[] = {
|
||||
[1] = ACTION_LAYER_TAP_TOGGLE(NUMB), // FN1 - Momentary Layer 1 (Numbers)
|
||||
};
|
||||
int capslock = 0;
|
||||
int numlock = 0;
|
||||
|
||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||
if (!process_record_dynamic_macro(keycode, record)) {
|
||||
bool led_update_user(led_t led_state) {
|
||||
// Following disables the default LED indicators:
|
||||
return false;
|
||||
}
|
||||
switch (keycode) {
|
||||
case VRSN:
|
||||
if (record->event.pressed) {
|
||||
SEND_STRING (" <[ Dejvino's Keyboard ]> ");
|
||||
}
|
||||
|
||||
bool led_update_kb(led_t led_state) {
|
||||
numlock = led_state.num_lock;
|
||||
capslock = led_state.caps_lock;
|
||||
// Following disables the default LED indicators:
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
// Runs just one time when the keyboard initializes.
|
||||
void matrix_init_user(void) {
|
||||
//set_unicode_input_mode(UC_LINX);
|
||||
};
|
||||
|
||||
/**/
|
||||
|
||||
// Runs constantly in the background, in a loop.
|
||||
void matrix_scan_user(void) {
|
||||
@ -187,17 +175,21 @@ void matrix_scan_user(void) {
|
||||
ergodox_right_led_2_off();
|
||||
ergodox_right_led_3_off();
|
||||
|
||||
|
||||
switch (layer) {
|
||||
case FNCK:
|
||||
ergodox_right_led_1_on();
|
||||
ergodox_board_led_on();
|
||||
break;
|
||||
case NUMB:
|
||||
ergodox_right_led_2_on();
|
||||
ergodox_board_led_on();
|
||||
if (numlock) {
|
||||
ergodox_right_led_1_on();
|
||||
}
|
||||
break;
|
||||
|
||||
default:
|
||||
// none
|
||||
if (capslock) {
|
||||
ergodox_right_led_2_on();
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user