Compare commits
6
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
33fa2ddb95 | ||
|
|
42bf60751e | ||
|
|
fd19795879 | ||
|
|
f069e9fc09 | ||
|
|
63a0b1241d | ||
|
|
75c9747787 |
No files matched your search
Vendored
+7
-5
@@ -8,10 +8,12 @@
|
|||||||
"**/*.hex": true
|
"**/*.hex": true
|
||||||
},
|
},
|
||||||
"files.associations": {
|
"files.associations": {
|
||||||
"*.h": "c",
|
"*.h": "c",
|
||||||
"*.c": "c",
|
"*.c": "c",
|
||||||
"*.cpp": "cpp",
|
"*.cpp": "cpp",
|
||||||
"*.hpp": "cpp",
|
"*.hpp": "cpp",
|
||||||
"xstddef": "c"
|
"xstddef": "c",
|
||||||
|
"type_traits": "c",
|
||||||
|
"utility": "c"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -30,7 +30,9 @@ Next, you will want to define some tap-dance keys, which is easiest to do with t
|
|||||||
After this, you'll want to use the `tap_dance_actions` array to specify what actions shall be taken when a tap-dance key is in action. Currently, there are five possible options:
|
After this, you'll want to use the `tap_dance_actions` array to specify what actions shall be taken when a tap-dance key is in action. Currently, there are five possible options:
|
||||||
|
|
||||||
* `ACTION_TAP_DANCE_DOUBLE(kc1, kc2)`: Sends the `kc1` keycode when tapped once, `kc2` otherwise. When the key is held, the appropriate keycode is registered: `kc1` when pressed and held, `kc2` when tapped once, then pressed and held.
|
* `ACTION_TAP_DANCE_DOUBLE(kc1, kc2)`: Sends the `kc1` keycode when tapped once, `kc2` otherwise. When the key is held, the appropriate keycode is registered: `kc1` when pressed and held, `kc2` when tapped once, then pressed and held.
|
||||||
* `ACTION_TAP_DANCE_DUAL_ROLE(kc, layer)`: Sends the `kc` keycode when tapped once, or moves to `layer`. (this functions like the `TO` layer keycode).
|
* `ACTION_TAP_DANCE_LAYER_MOVE(kc, layer)`: Sends the `kc` keycode when tapped once, or moves to `layer`. (this functions like the `TO` layer keycode).
|
||||||
|
* This is the same as `ACTION_TAP_DANCE_DUAL_ROLE`, but renamed to something that is clearer about its functionality. Both names will work.
|
||||||
|
* `ACTION_TAP_DANCE_LAYER_TOGGLE(kc, layer)`: Sends the `kc` keycode when tapped once, or toggles the state of `layer`. (this functions like the `TG` layer keycode).
|
||||||
* `ACTION_TAP_DANCE_FN(fn)`: Calls the specified function - defined in the user keymap - with the final tap count of the tap dance action.
|
* `ACTION_TAP_DANCE_FN(fn)`: Calls the specified function - defined in the user keymap - with the final tap count of the tap dance action.
|
||||||
* `ACTION_TAP_DANCE_FN_ADVANCED(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn)`: Calls the first specified function - defined in the user keymap - on every tap, the second function when the dance action finishes (like the previous option), and the last function when the tap dance action resets.
|
* `ACTION_TAP_DANCE_FN_ADVANCED(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn)`: Calls the first specified function - defined in the user keymap - on every tap, the second function when the dance action finishes (like the previous option), and the last function when the tap dance action resets.
|
||||||
* `ACTION_TAP_DANCE_FN_ADVANCED_TIME(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn, tap_specific_tapping_term)`: This functions identically to the `ACTION_TAP_DANCE_FN_ADVANCED` function, but uses a custom tapping term for it, instead of the predefined `TAPPING_TERM`.
|
* `ACTION_TAP_DANCE_FN_ADVANCED_TIME(on_each_tap_fn, on_dance_finished_fn, on_dance_reset_fn, tap_specific_tapping_term)`: This functions identically to the `ACTION_TAP_DANCE_FN_ADVANCED` function, but uses a custom tapping term for it, instead of the predefined `TAPPING_TERM`.
|
||||||
|
|||||||
@@ -0,0 +1,114 @@
|
|||||||
|
#include QMK_KEYBOARD_H
|
||||||
|
|
||||||
|
enum alt_keycodes {
|
||||||
|
U_T_AUTO = SAFE_RANGE, //USB Extra Port Toggle Auto Detect / Always Active
|
||||||
|
U_T_AGCR, //USB Toggle Automatic GCR control
|
||||||
|
DBG_TOG, //DEBUG Toggle On / Off
|
||||||
|
DBG_MTRX, //DEBUG Toggle Matrix Prints
|
||||||
|
DBG_KBD, //DEBUG Toggle Keyboard Prints
|
||||||
|
DBG_MOU, //DEBUG Toggle Mouse Prints
|
||||||
|
MD_BOOT, //Restart into bootloader after hold timeout
|
||||||
|
};
|
||||||
|
|
||||||
|
#define TG_NKRO MAGIC_TOGGLE_NKRO //Toggle 6KRO / NKRO mode
|
||||||
|
#define RGB_BRU RGB_VAI
|
||||||
|
#define RGB_BRD RGB_VAD
|
||||||
|
|
||||||
|
keymap_config_t keymap_config;
|
||||||
|
|
||||||
|
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||||
|
[0] = LAYOUT(
|
||||||
|
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_DEL, \
|
||||||
|
KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, KC_HOME, \
|
||||||
|
KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_PGUP, \
|
||||||
|
KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_PGDN, \
|
||||||
|
KC_LCTL, KC_LALT, KC_LGUI, KC_SPC, KC_RGUI, MO(1), KC_LEFT, KC_DOWN, KC_RGHT \
|
||||||
|
),
|
||||||
|
[1] = LAYOUT(
|
||||||
|
KC_GRV, 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_F13, KC_MUTE, \
|
||||||
|
_______, RGB_SPD, RGB_BRU, RGB_SPI, _______, _______, _______, U_T_AUTO,U_T_AGCR,_______, KC_PSCR, KC_SLCK, KC_PAUS, _______, KC_END, \
|
||||||
|
_______, RGB_RMOD,RGB_BRD, RGB_MOD, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_VOLU, \
|
||||||
|
_______, RGB_TOG, _______, _______, _______, MD_BOOT, TG_NKRO, _______, _______, _______, _______, _______, KC_VOLU, KC_VOLD, \
|
||||||
|
_______, _______, _______, KC_MPLY, _______, _______, KC_MPRV, KC_VOLD, KC_MNXT \
|
||||||
|
)
|
||||||
|
};
|
||||||
|
|
||||||
|
// Runs just one time when the keyboard initializes.
|
||||||
|
void matrix_init_user(void) {
|
||||||
|
};
|
||||||
|
|
||||||
|
// Runs constantly in the background, in a loop.
|
||||||
|
void matrix_scan_user(void) {
|
||||||
|
};
|
||||||
|
|
||||||
|
#define MODS_SHIFT (get_mods() & MOD_BIT(KC_LSHIFT) || get_mods() & MOD_BIT(KC_RSHIFT))
|
||||||
|
#define MODS_CTRL (get_mods() & MOD_BIT(KC_LCTL) || get_mods() & MOD_BIT(KC_RCTRL))
|
||||||
|
#define MODS_ALT (get_mods() & MOD_BIT(KC_LALT) || get_mods() & MOD_BIT(KC_RALT))
|
||||||
|
|
||||||
|
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
|
static uint32_t key_timer;
|
||||||
|
|
||||||
|
switch (keycode) {
|
||||||
|
case U_T_AUTO:
|
||||||
|
if (record->event.pressed && MODS_SHIFT && MODS_CTRL) {
|
||||||
|
TOGGLE_FLAG_AND_PRINT(usb_extra_manual, "USB extra port manual mode");
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case U_T_AGCR:
|
||||||
|
if (record->event.pressed && MODS_SHIFT && MODS_CTRL) {
|
||||||
|
TOGGLE_FLAG_AND_PRINT(usb_gcr_auto, "USB GCR auto mode");
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case DBG_TOG:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
TOGGLE_FLAG_AND_PRINT(debug_enable, "Debug mode");
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case DBG_MTRX:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
TOGGLE_FLAG_AND_PRINT(debug_matrix, "Debug matrix");
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case DBG_KBD:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
TOGGLE_FLAG_AND_PRINT(debug_keyboard, "Debug keyboard");
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case DBG_MOU:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
TOGGLE_FLAG_AND_PRINT(debug_mouse, "Debug mouse");
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case RGB_TOG:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
switch (rgb_matrix_get_flags()) {
|
||||||
|
case LED_FLAG_ALL: {
|
||||||
|
rgb_matrix_set_flags(LED_FLAG_KEYLIGHT);
|
||||||
|
rgb_matrix_set_color_all(0, 0, 0);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case LED_FLAG_KEYLIGHT: {
|
||||||
|
rgb_matrix_set_flags(LED_FLAG_UNDERGLOW);
|
||||||
|
rgb_matrix_set_color_all(0, 0, 0);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
default: {
|
||||||
|
rgb_matrix_set_flags(LED_FLAG_ALL);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
case MD_BOOT:
|
||||||
|
if (record->event.pressed) {
|
||||||
|
key_timer = timer_read32();
|
||||||
|
} else {
|
||||||
|
if (timer_elapsed32(key_timer) >= 500) {
|
||||||
|
reset_keyboard();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
default:
|
||||||
|
return true; //Process all other keycodes normally
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,30 +1,4 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
|
|
||||||
#define RGB_DIGITAL_RAIN_DROPS 18
|
#define RGB_DIGITAL_RAIN_DROPS 18
|
||||||
#define USB_MAX_POWER_CONSUMPTION 100
|
|
||||||
#define ONESHOT_TAP_TOGGLE 2
|
|
||||||
#define ONESHOT_TIMEOUT 3000
|
|
||||||
|
|
||||||
#define MOUSEKEY_INTERVAL 20
|
|
||||||
#define MOUSEKEY_DELAY 0
|
|
||||||
#define MOUSEKEY_TIME_TO_MAX 40
|
|
||||||
#define MOUSEKEY_MAX_SPEED 7
|
|
||||||
#define MOUSEKEY_WHEEL_DELAY 0
|
|
||||||
|
|
||||||
// dynamic macro keys
|
|
||||||
#define DM_PLAY DYN_MACRO_PLAY1
|
|
||||||
#define DM_STRT DYN_REC_START1
|
|
||||||
#define DM_STOP DYN_REC_STOP
|
|
||||||
|
|
||||||
// one-shot layer keys
|
|
||||||
#define OSL_FUN OSL(FUN)
|
|
||||||
|
|
||||||
// one-shot modifier keys
|
|
||||||
#define OSMLCTL OSM(MOD_LCTL)
|
|
||||||
#define OSMRCTL OSM(MOD_RCTL)
|
|
||||||
#define OSMLALT OSM(MOD_LALT)
|
|
||||||
#define OSMRALT OSM(MOD_RALT)
|
|
||||||
#define OSMLSFT OSM(MOD_LSFT)
|
|
||||||
#define OSMRSFT OSM(MOD_RSFT)
|
|
||||||
|
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
#include QMK_KEYBOARD_H
|
#include QMK_KEYBOARD_H
|
||||||
|
#include "dshields.h"
|
||||||
|
|
||||||
enum { DEF, FUN };
|
enum { DEF, FUN };
|
||||||
enum { DYNAMIC_MACRO_RANGE = SAFE_RANGE };
|
enum { DYNAMIC_MACRO_RANGE = SAFE_RANGE };
|
||||||
@@ -30,30 +31,3 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||||||
)
|
)
|
||||||
};
|
};
|
||||||
|
|
||||||
uint32_t layer_state_set_user(uint32_t state) {
|
|
||||||
switch (biton32(state)) {
|
|
||||||
case DEF:
|
|
||||||
set_all_leds_to(0,0,0);
|
|
||||||
break;
|
|
||||||
case FUN:
|
|
||||||
// TODO light the fn keys
|
|
||||||
// set_led_to(?, 0, 128, 0);
|
|
||||||
// set_led_to(?, 0, 128, 0);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
return state;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
void matrix_init_user(void) {
|
|
||||||
eeconfig_init();
|
|
||||||
};
|
|
||||||
*/
|
|
||||||
|
|
||||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|
||||||
if (!process_record_dynamic_macro(keycode, record)) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
MOUSEKEY_ENABLE = yes
|
|
||||||
EXTRAKEY_ENABLE = no
|
|
||||||
CONSOLE_ENABLE = no
|
|
||||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -1,5 +1,4 @@
|
|||||||
CANOE
|
# Canoe
|
||||||
========
|
|
||||||
|
|
||||||
A 65% keyboard with some RGB
|
A 65% keyboard with some RGB
|
||||||
|
|
||||||
@@ -9,7 +8,7 @@ Hardware Availability: https://geekhack.org/index.php?topic=92418.0
|
|||||||
|
|
||||||
Make example for this keyboard (after setting up your build environment):
|
Make example for this keyboard (after setting up your build environment):
|
||||||
|
|
||||||
make canoe:default
|
make percent/canoe:default
|
||||||
|
|
||||||
Flashing
|
Flashing
|
||||||
|
|
||||||
@@ -33,12 +32,13 @@ macOS:
|
|||||||
```
|
```
|
||||||
3. Install the following packages:
|
3. Install the following packages:
|
||||||
```
|
```
|
||||||
brew install python
|
brew install python3
|
||||||
pip install pyusb
|
pip3 install pyusb
|
||||||
brew install --HEAD https://raw.githubusercontent.com/robertgzr/homebrew-tap/master/bootloadhid.rb
|
brew install --HEAD https://raw.githubusercontent.com/robertgzr/homebrew-tap/master/bootloadhid.rb
|
||||||
|
```
|
||||||
|
|
||||||
4. Place your keyboard into reset.
|
4. Place your keyboard into reset.
|
||||||
5. Flash the board by typing `bootloadHID -r` followed by the path to your `.hex` file.
|
5. Flash the board by typing `bootloadHID -r` followed by the path to your `.hex` file.
|
||||||
|
|
||||||
|
|
||||||
See [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) then the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information.
|
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).
|
||||||
File renamed without changes.
File renamed without changes.
@@ -1,5 +1,4 @@
|
|||||||
Skog TKL by Percent
|
# Skog TKL
|
||||||
==========================
|
|
||||||
|
|
||||||
Keyboard Maintainer: QMK Community
|
Keyboard Maintainer: QMK Community
|
||||||
Hardware Supported: Skog PCB
|
Hardware Supported: Skog PCB
|
||||||
@@ -7,21 +6,14 @@ Hardware Availability: https://geekhack.org/index.php?topic=87953.0
|
|||||||
|
|
||||||
Make example for this keyboard (after setting up your build environment):
|
Make example for this keyboard (after setting up your build environment):
|
||||||
|
|
||||||
make skog:default
|
make percent/skog:default
|
||||||
|
|
||||||
## Setting the board to bootloader mode
|
Flashing
|
||||||
|
|
||||||
If you're lucky, the programming script does this automagically for you. If
|
|
||||||
however this doesn't work for you, you need to enter the bootloader mode manually
|
|
||||||
by plugging the keyboard in while holding the bootloader key. If you did this
|
|
||||||
correctly the LEDs will blink and you'll be able to flash your firmware.
|
|
||||||
|
|
||||||
The bootloader key is in the top-right (Pause).
|
|
||||||
|
|
||||||
## Flashing
|
|
||||||
|
|
||||||
ps2avr(GB) boards use an atmega32a microcontroller and a different bootloader. It is not flashable using the regular QMK methods.
|
ps2avr(GB) boards use an atmega32a microcontroller and a different bootloader. It is not flashable using the regular QMK methods.
|
||||||
|
|
||||||
|
**Reset Key:** Hold down the key located at `K00`, commonly programmed as Pause while plugging in the keyboard.
|
||||||
|
|
||||||
Windows:
|
Windows:
|
||||||
1. Download [HIDBootFlash](http://vusb.wikidot.com/project:hidbootflash).
|
1. Download [HIDBootFlash](http://vusb.wikidot.com/project:hidbootflash).
|
||||||
2. Place your keyboard into reset.
|
2. Place your keyboard into reset.
|
||||||
@@ -40,22 +32,14 @@ macOS:
|
|||||||
```
|
```
|
||||||
3. Install the following packages:
|
3. Install the following packages:
|
||||||
```
|
```
|
||||||
brew install python
|
brew install python3
|
||||||
brew install pyusb
|
pip3 install pyusb
|
||||||
brew install --HEAD`https://raw.githubusercontent.com/robertgzr/homebrew-tap/master/bootloadhid.rb
|
brew install --HEAD https://raw.githubusercontent.com/robertgzr/homebrew-tap/master/bootloadhid.rb
|
||||||
|
```
|
||||||
|
|
||||||
4. Place your keyboard into reset.
|
4. Place your keyboard into reset.
|
||||||
5. Flash the board by typing `bootloadHID -r` followed by the path to your `.hex` file.
|
5. Flash the board by typing `bootloadHID -r` followed by the path to your `.hex` file.
|
||||||
|
|
||||||
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).
|
**Please Note:** You will need to use the `EEP_RST` keycode first, followed by unplugging/replugging the board to get RGB underglow effects to work.
|
||||||
|
|
||||||
## Troubleshooting
|
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).
|
||||||
|
|
||||||
From my experience, it's really hard to brick these boards. But these
|
|
||||||
tricks have been useful when it got stuck in a weird scenario.
|
|
||||||
|
|
||||||
1. Try plugging the board in while holding the bootloader key. This will force
|
|
||||||
it to boot only the bootloader without loading the firmware. Once this is
|
|
||||||
done, just reflash the board with the original firmware.
|
|
||||||
2. Sometimes USB hubs can act weird, so try connecting the board directly
|
|
||||||
to your computer or plugging/unplugging the USB hub.
|
|
||||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -1,33 +1,4 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
|
|
||||||
#define RGB_DIGITAL_RAIN_DROPS 24
|
#define RGB_DIGITAL_RAIN_DROPS 24
|
||||||
#define USB_MAX_POWER_CONSUMPTION 100
|
|
||||||
#define ONESHOT_TAP_TOGGLE 2
|
|
||||||
#define ONESHOT_TIMEOUT 3000
|
|
||||||
#define RETRO_TAPPING
|
|
||||||
|
|
||||||
#define MOUSEKEY_INTERVAL 20
|
|
||||||
#define MOUSEKEY_DELAY 0
|
|
||||||
#define MOUSEKEY_TIME_TO_MAX 40
|
|
||||||
#define MOUSEKEY_MAX_SPEED 7
|
|
||||||
#define MOUSEKEY_WHEEL_DELAY 0
|
|
||||||
|
|
||||||
// dynamic macro keys
|
|
||||||
#define DM_PLAY DYN_MACRO_PLAY1
|
|
||||||
#define DM_STRT DYN_REC_START1
|
|
||||||
#define DM_STOP DYN_REC_STOP
|
|
||||||
|
|
||||||
// one-shot layer keys
|
|
||||||
#define OSL_RSE OSL(RSE)
|
|
||||||
#define OSL_LWR OSL(LWR)
|
|
||||||
#define OSL_FUN OSL(FUN)
|
|
||||||
|
|
||||||
// one-shot modifier keys
|
|
||||||
#define OSM_CTL OSM(MOD_LCTL)
|
|
||||||
#define OSM_ALT OSM(MOD_LALT)
|
|
||||||
#define OSM_SFT OSM(MOD_LSFT)
|
|
||||||
|
|
||||||
// mod-tap keys
|
|
||||||
#define MT_SPC SFT_T(KC_SPC)
|
|
||||||
|
|
||||||
@@ -1,27 +1,17 @@
|
|||||||
#include QMK_KEYBOARD_H
|
#include QMK_KEYBOARD_H
|
||||||
#include "config.h"
|
#include "dshields.h"
|
||||||
|
|
||||||
extern keymap_config_t keymap_config;
|
|
||||||
|
|
||||||
enum planck_layers { DEF, LWR, RSE, FUN };
|
enum planck_layers { DEF, LWR, RSE, FUN };
|
||||||
enum planck_keycodes { DYNAMIC_MACRO_RANGE = SAFE_RANGE };
|
enum planck_keycodes { DYNAMIC_MACRO_RANGE = SAFE_RANGE };
|
||||||
|
|
||||||
#include "dynamic_macro.h"
|
#include "dynamic_macro.h"
|
||||||
|
|
||||||
#ifdef KEYBOARD_planck_light
|
|
||||||
#define LGT_TOG RGB_TOG
|
|
||||||
#define LGT_MOD RGB_MOD
|
|
||||||
#else
|
|
||||||
#define LGT_TOG BL_TOGG
|
|
||||||
#define LGT_MOD BL_STEP
|
|
||||||
#endif
|
|
||||||
|
|
||||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||||
[DEF] = LAYOUT_planck_grid(
|
[DEF] = LAYOUT_planck_grid(
|
||||||
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_ESC, KC_BSPC, KC_Y, KC_U, KC_I, KC_O, KC_P ,
|
KC_Q, KC_W, KC_E, KC_R, KC_T, KC_ESC, KC_BSPC, KC_Y, KC_U, KC_I, KC_O, KC_P ,
|
||||||
KC_A, KC_S, KC_D, KC_F, KC_G, KC_TAB, KC_ENT, KC_H, KC_J, KC_K, KC_L, KC_SCLN,
|
KC_A, KC_S, KC_D, KC_F, KC_G, KC_TAB, KC_ENT, KC_H, KC_J, KC_K, KC_L, KC_SCLN,
|
||||||
KC_Z, KC_X, KC_C, KC_V, KC_B, OSM_SFT, DM_PLAY, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH,
|
KC_Z, KC_X, KC_C, KC_V, KC_B, OSMLSFT, DM_PLAY, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH,
|
||||||
OSM_CTL, KC_LGUI, OSM_ALT, OSL_FUN, OSL_LWR, MT_SPC, MT_SPC, OSL_RSE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
OSMLCTL, KC_LGUI, OSMLALT, OSL_FUN, OSL_LWR, MT_SPC, MT_SPC, OSL_RSE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
|
||||||
),
|
),
|
||||||
[LWR] = LAYOUT_planck_grid(
|
[LWR] = LAYOUT_planck_grid(
|
||||||
KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, _______, _______, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN,
|
KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, _______, _______, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN,
|
||||||
@@ -43,16 +33,3 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
|||||||
)
|
)
|
||||||
};
|
};
|
||||||
|
|
||||||
/*
|
|
||||||
void matrix_init_user(void) {
|
|
||||||
eeconfig_init();
|
|
||||||
};
|
|
||||||
*/
|
|
||||||
|
|
||||||
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
|
||||||
if (!process_record_dynamic_macro(keycode, record)) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -61,7 +61,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
@@ -43,7 +43,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
@@ -43,7 +43,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
@@ -43,7 +43,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
@@ -43,7 +43,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
@@ -119,7 +119,7 @@ LAYOUT_ortho_4x12( \
|
|||||||
)
|
)
|
||||||
|
|
||||||
#define KEYMAP LAYOUT_ortho_4x12
|
#define KEYMAP LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
#define LAYOUT_planck_mit LAYOUT_planck_1x2uC
|
||||||
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
#define LAYOUT_planck_grid LAYOUT_ortho_4x12
|
||||||
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
#define LAYOUT_kc_ortho_4x12 LAYOUT_kc
|
||||||
#define KC_KEYMAP LAYOUT_kc
|
#define KC_KEYMAP LAYOUT_kc
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
/**************************************************
|
/**************************************************
|
||||||
** Include headers specific to keyboard revision **
|
** Include headers specific to keyboard revision **
|
||||||
***************************************************/
|
**************************************************/
|
||||||
#ifdef KEYBOARD_preonic_rev1
|
#ifdef KEYBOARD_preonic_rev1
|
||||||
#include "rev1.h"
|
#include "rev1.h"
|
||||||
#endif
|
#endif
|
||||||
@@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
/**************************************************
|
/**************************************************
|
||||||
** Layout macros aliases common to all revisions **
|
** Layout macros aliases common to all revisions **
|
||||||
|
** **
|
||||||
Name of Alias Matrix Name:
|
** Name of Alias Matrix Name: **
|
||||||
----------------- ------------------- ****/
|
******* ----------------- ------------------- ****/
|
||||||
#define LAYOUT_ortho_5x12 LAYOUT_preonic_grid
|
#define LAYOUT_ortho_5x12 LAYOUT_preonic_grid
|
||||||
@@ -71,7 +71,7 @@ void qk_tap_dance_dual_role_finished(qk_tap_dance_state_t *state, void *user_dat
|
|||||||
if (state->count == 1) {
|
if (state->count == 1) {
|
||||||
register_code16(pair->kc);
|
register_code16(pair->kc);
|
||||||
} else if (state->count == 2) {
|
} else if (state->count == 2) {
|
||||||
layer_move(pair->layer);
|
pair->layer_function(pair->layer);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -56,13 +56,19 @@ typedef struct {
|
|||||||
typedef struct {
|
typedef struct {
|
||||||
uint16_t kc;
|
uint16_t kc;
|
||||||
uint8_t layer;
|
uint8_t layer;
|
||||||
|
void (*layer_function)(uint8_t);
|
||||||
} qk_tap_dance_dual_role_t;
|
} qk_tap_dance_dual_role_t;
|
||||||
|
|
||||||
# define ACTION_TAP_DANCE_DOUBLE(kc1, kc2) \
|
# define ACTION_TAP_DANCE_DOUBLE(kc1, kc2) \
|
||||||
{ .fn = {qk_tap_dance_pair_on_each_tap, qk_tap_dance_pair_finished, qk_tap_dance_pair_reset}, .user_data = (void *)&((qk_tap_dance_pair_t){kc1, kc2}), }
|
{ .fn = {qk_tap_dance_pair_on_each_tap, qk_tap_dance_pair_finished, qk_tap_dance_pair_reset}, .user_data = (void *)&((qk_tap_dance_pair_t){kc1, kc2}), }
|
||||||
|
|
||||||
# define ACTION_TAP_DANCE_DUAL_ROLE(kc, layer) \
|
# define ACTION_TAP_DANCE_DUAL_ROLE(kc, layer) \
|
||||||
{ .fn = {qk_tap_dance_dual_role_on_each_tap, qk_tap_dance_dual_role_finished, qk_tap_dance_dual_role_reset}, .user_data = (void *)&((qk_tap_dance_dual_role_t){kc, layer}), }
|
{ .fn = { qk_tap_dance_dual_role_on_each_tap, qk_tap_dance_dual_role_finished, qk_tap_dance_dual_role_reset }, .user_data = (void *)&((qk_tap_dance_dual_role_t) { kc, layer, layer_move }), }
|
||||||
|
|
||||||
|
# define ACTION_TAP_DANCE_TOGGLE_LAYER(kc, layer) \
|
||||||
|
{ .fn = { NULL, qk_tap_dance_dual_role_finished, qk_tap_dance_dual_role_reset }, .user_data = (void *)&((qk_tap_dance_dual_role_t) { kc, layer, layer_invert }), }
|
||||||
|
|
||||||
|
# define ACTION_TAP_DANCE_LAYER_MOVE(kc, layer) ACTION_TAP_DANCE_DUAL_ROLE(kc, layer)
|
||||||
|
|
||||||
# define ACTION_TAP_DANCE_FN(user_fn) \
|
# define ACTION_TAP_DANCE_FN(user_fn) \
|
||||||
{ .fn = {NULL, user_fn, NULL}, .user_data = NULL, }
|
{ .fn = {NULL, user_fn, NULL}, .user_data = NULL, }
|
||||||
@@ -73,6 +79,8 @@ typedef struct {
|
|||||||
# define ACTION_TAP_DANCE_FN_ADVANCED_TIME(user_fn_on_each_tap, user_fn_on_dance_finished, user_fn_on_dance_reset, tap_specific_tapping_term) \
|
# define ACTION_TAP_DANCE_FN_ADVANCED_TIME(user_fn_on_each_tap, user_fn_on_dance_finished, user_fn_on_dance_reset, tap_specific_tapping_term) \
|
||||||
{ .fn = {user_fn_on_each_tap, user_fn_on_dance_finished, user_fn_on_dance_reset}, .user_data = NULL, .custom_tapping_term = tap_specific_tapping_term, }
|
{ .fn = {user_fn_on_each_tap, user_fn_on_dance_finished, user_fn_on_dance_reset}, .user_data = NULL, .custom_tapping_term = tap_specific_tapping_term, }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
extern qk_tap_dance_action_t tap_dance_actions[];
|
extern qk_tap_dance_action_t tap_dance_actions[];
|
||||||
|
|
||||||
/* To be used internally */
|
/* To be used internally */
|
||||||
|
|||||||
@@ -7,6 +7,12 @@
|
|||||||
[](https://github.com/qmk/qmk_firmware/pulse/monthly)
|
[](https://github.com/qmk/qmk_firmware/pulse/monthly)
|
||||||
[](https://github.com/qmk/qmk_firmware/)
|
[](https://github.com/qmk/qmk_firmware/)
|
||||||
|
|
||||||
|
# THIS IS THE FUTURE BRANCH
|
||||||
|
|
||||||
|
Warning- This is the `future` branch of QMK Firmware. You may encounter broken code here. Please see [Breaking Changes](https://docs.qmk.fm/#/breaking_changes) for more information.
|
||||||
|
|
||||||
|
# Original readme continues
|
||||||
|
|
||||||
This is a keyboard firmware based on the [tmk\_keyboard firmware](https://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR and ARM controllers, and more specifically, the [OLKB product line](https://olkb.com), the [ErgoDox EZ](https://ergodox-ez.com) keyboard, and the [Clueboard product line](https://clueboard.co).
|
This is a keyboard firmware based on the [tmk\_keyboard firmware](https://github.com/tmk/tmk_keyboard) with some useful features for Atmel AVR and ARM controllers, and more specifically, the [OLKB product line](https://olkb.com), the [ErgoDox EZ](https://ergodox-ez.com) keyboard, and the [Clueboard product line](https://clueboard.co).
|
||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
|
||||||
|
#define USB_MAX_POWER_CONSUMPTION 100
|
||||||
|
#define ONESHOT_TAP_TOGGLE 2
|
||||||
|
#define ONESHOT_TIMEOUT 3000
|
||||||
|
#define RETRO_TAPPING
|
||||||
|
|
||||||
|
#define MOUSEKEY_INTERVAL 20
|
||||||
|
#define MOUSEKEY_DELAY 0
|
||||||
|
#define MOUSEKEY_TIME_TO_MAX 40
|
||||||
|
#define MOUSEKEY_MAX_SPEED 7
|
||||||
|
#define MOUSEKEY_WHEEL_DELAY 0
|
||||||
|
|
||||||
@@ -0,0 +1,30 @@
|
|||||||
|
extern keymap_config_t keymap_config;
|
||||||
|
|
||||||
|
/* uncomment to reset
|
||||||
|
void matrix_init_user(void) {
|
||||||
|
eeconfig_init();
|
||||||
|
};
|
||||||
|
*/
|
||||||
|
|
||||||
|
bool process_record_user(uint16_t keycode, keyrecord_t *record) {
|
||||||
|
if (!process_record_dynamic_macro(keycode, record)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// work in progress
|
||||||
|
uint32_t layer_state_set_user(uint32_t state) {
|
||||||
|
switch (biton32(state)) {
|
||||||
|
case DEF:
|
||||||
|
set_all_leds_to(0,0,0);
|
||||||
|
break;
|
||||||
|
case FUN:
|
||||||
|
// TODO light the fn keys
|
||||||
|
// set_led_to(?, 0, 128, 0);
|
||||||
|
// set_led_to(?, 0, 128, 0);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return state;
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
// dynamic macro keys
|
||||||
|
#define DM_PLAY DYN_MACRO_PLAY1
|
||||||
|
#define DM_STRT DYN_REC_START1
|
||||||
|
#define DM_STOP DYN_REC_STOP
|
||||||
|
|
||||||
|
// one-shot layer keys
|
||||||
|
#define OSL_RSE OSL(RSE)
|
||||||
|
#define OSL_LWR OSL(LWR)
|
||||||
|
#define OSL_FUN OSL(FUN)
|
||||||
|
|
||||||
|
// one-shot modifier keys
|
||||||
|
#define OSMLCTL OSM(MOD_LCTL)
|
||||||
|
#define OSMRCTL OSM(MOD_RCTL)
|
||||||
|
#define OSMLALT OSM(MOD_LALT)
|
||||||
|
#define OSMRALT OSM(MOD_RALT)
|
||||||
|
#define OSMLSFT OSM(MOD_LSFT)
|
||||||
|
#define OSMRSFT OSM(MOD_RSFT)
|
||||||
|
|
||||||
|
// mod-tap keys
|
||||||
|
#define MT_SPC SFT_T(KC_SPC)
|
||||||
|
|
||||||
|
#ifdef KEYBOARD_planck_light
|
||||||
|
#define LGT_TOG RGB_TOG
|
||||||
|
#define LGT_MOD RGB_MOD
|
||||||
|
#else
|
||||||
|
#define LGT_TOG BL_TOGG
|
||||||
|
#define LGT_MOD BL_STEP
|
||||||
|
#endif
|
||||||
|
|
||||||
File renamed without changes.
Reference in new issue
Block a user