mirror of
https://github.com/Keychron/qmk_firmware.git
synced 2024-12-24 02:05:01 +06:00
Zeal60/Zeal65/M60-A implementation (#3879)
* Initial version of zeal60 * WIP * Fixes issue #900 * Adding RGB underglow functionality. Fixed a compile-time conflict caused by enabling RGB underglow functionality. * Refactor RPC protocol * Fix last merge * README for RGB underglow updated. * Additional README changes. * Adding RGBW strip software-based current-limiting functionality. * RGBW current-limiting functionality should be handled by RGBSTRIP_MAX_CURRENT_PER_LIGHT instead. * Updated README to reflect implementation of built-in current limiting. * Keymap readability improvements. * Minor keymap improvements. * Fixed LED driver init sequence, formatting * Dimming implementation tested, working. * Stab LEDs synced with spacebar hits in effects. * RGB underglow tested and functional. Simplified README for RGB underglow. * Undid accidental file deletion from previous merge conflict. Safer values for RGB underglow. * Improved arrow key positions in keymap. * Added functionality to correct uneven RGB underglow. Refactored related code. * Reverted to safer values for underglow. * Changes for v0.3 * Custom LED brightness scaling will take place after current adjustment in order to avoid being overridden. * Create keymap.c Added split backspace and split shift to ISO layout * Create config.h Turned on LEDs for new layout * Fixed bug where left spacebar stabilizer LED (LC06) would adopt color of row above. * Added hhkb_wilba keymap * Update keymap.c * Update keymap.c * Update keymap.c * Added indicators, full param setting via host * Added "mousekey" layout * Added Zeal65 support, factory test mode * Keycode safe range changed, caused bugs * Bumped EEPROM version due to change in QMK keycodes * Disable HHKB "blocked" LEDs if KC_NO in keymap * Added "disable_hhkb_blocker_leds" * Required overridden function for keymaps in EEPROM * Added polar coordinate mapping, effect speed * Force Raw HID interface number to 1 always * Fixed last merge from master * Added effect speed to default keymaps * add BACKLIGHT_ prefix to vars * add BACKLIGHT_ prefix to vars * Keymap speed effect; keymap improvements/fixes Readme updated to match changes * Refactored to use common IS31FL3731/I2C drivers * Fixed make rules, backlight disabled feature * Make split rightshift default for Zeal65 * Added M60-A as a "version" of Zeal60. * Renamed IS31FL3731 driver functions * Fix suspend_wakeup_init_kb() being defined twice * First pass refactor dynamic keymaps * Updated to changed I2C and ISSI drivers * Refactor zeal_color.* usage to quantum/color.* * Updated Zeal65, fixed dynamic_keymap * Major refactoring of Zeal60 backlight and API * Lots of little cleanups * Added readme.md * Added readme.md * Added LAYOUT_60*() macros, refactored and cleaned up default keymaps * Fix compile error in suspend.c * Added Zeal65 LAYOUT macros, info.json * Added rama/m60_a, deleted zeal60/keymaps/m60_a * Fixed rama/m60_a/keymaps/proto * Fixed compilation error for suspend.c * Requested changes for PR * Fixed readme.md images * Another readme.md fix * Added drashna's requested changes
This commit is contained in:
parent
170de1273c
commit
48a992f1c0
@ -227,6 +227,11 @@ ifeq ($(strip $(HD44780_ENABLE)), yes)
|
||||
OPT_DEFS += -DHD44780_ENABLE
|
||||
endif
|
||||
|
||||
ifeq ($(strip $(DYNAMIC_KEYMAP_ENABLE)), yes)
|
||||
OPT_DEFS += -DDYNAMIC_KEYMAP_ENABLE
|
||||
SRC += $(QUANTUM_DIR)/dynamic_keymap.c
|
||||
endif
|
||||
|
||||
QUANTUM_SRC:= \
|
||||
$(QUANTUM_DIR)/quantum.c \
|
||||
$(QUANTUM_DIR)/keymap_common.c \
|
||||
|
128
keyboards/rama/m60_a/config.h
Normal file
128
keyboards/rama/m60_a/config.h
Normal file
@ -0,0 +1,128 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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"
|
||||
|
||||
// USB Device descriptor parameter
|
||||
#define VENDOR_ID 0xFEED // This is same as Zeal60 for now
|
||||
#define PRODUCT_ID 0x6060 // This is same as Zeal60 for now
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER RAMA.WORKS
|
||||
#define PRODUCT RAMA M60-A
|
||||
#define DESCRIPTION RAMA M60-A Keyboard
|
||||
|
||||
|
||||
|
||||
// key matrix size
|
||||
#define MATRIX_ROWS 5
|
||||
#define MATRIX_COLS 14
|
||||
|
||||
// Zeal60 PCB default pin-out
|
||||
#define MATRIX_ROW_PINS { F0, F1, F4, F6, F7 }
|
||||
#define MATRIX_COL_PINS { F5, D5, B1, B2, B3, D3, D2, C7, C6, B6, B5, B4, D7, D6 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
// IS31FL3731 driver
|
||||
#define DRIVER_COUNT 2
|
||||
#define DRIVER_LED_TOTAL 72
|
||||
|
||||
// COL2ROW or ROW2COL
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
// Set 0 if debouncing isn't needed
|
||||
#define DEBOUNCING_DELAY 5
|
||||
|
||||
// Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
// Locking resynchronize hack
|
||||
#define LOCKING_RESYNC_ENABLE
|
||||
|
||||
// key combination for command
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
|
||||
)
|
||||
|
||||
/*
|
||||
* 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
|
||||
|
||||
#define RGB_BACKLIGHT_ENABLED 1
|
||||
|
||||
// This conditionally compiles the backlight code for M60-A specifics
|
||||
#define RGB_BACKLIGHT_M60_A
|
||||
|
||||
// enable/disable LEDs based on layout
|
||||
// they aren't really used if RGB_BACKLIGHT_M60_A defined
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 1
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 1
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 1
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 1
|
||||
|
||||
// disable backlight when USB suspended (PC sleep/hibernate/shutdown)
|
||||
#define RGB_BACKLIGHT_DISABLE_WHEN_USB_SUSPENDED 0
|
||||
|
||||
// disable backlight after timeout in minutes, 0 = no timeout
|
||||
#define RGB_BACKLIGHT_DISABLE_AFTER_TIMEOUT 0
|
||||
|
||||
// the default effect (RGB test)
|
||||
#define RGB_BACKLIGHT_EFFECT 255
|
||||
|
||||
// These define which keys in the matrix are alphas/mods
|
||||
// Used for backlight effects so colors are different for
|
||||
// alphas vs. mods
|
||||
// Each value is for a row, bit 0 is column 0
|
||||
// Alpha=0 Mod=1
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_0 0b0000000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_1 0b0010000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_2 0b0011000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_3 0b0011000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_4 0b0011100000000111
|
||||
|
||||
#define DYNAMIC_KEYMAP_LAYER_COUNT 4
|
||||
|
||||
// EEPROM usage
|
||||
|
||||
// TODO: refactor with new user EEPROM code (coming soon)
|
||||
#define EEPROM_MAGIC 0x451F
|
||||
#define EEPROM_MAGIC_ADDR 32
|
||||
// Bump this every time we change what we store
|
||||
// This will automatically reset the EEPROM with defaults
|
||||
// and avoid loading invalid data from the EEPROM
|
||||
#define EEPROM_VERSION 0x07
|
||||
#define EEPROM_VERSION_ADDR 34
|
||||
|
||||
// Backlight config starts after EEPROM version
|
||||
#define RGB_BACKLIGHT_CONFIG_EEPROM_ADDR 35
|
||||
// Dynamic keymap starts after backlight config (35+37)
|
||||
#define DYNAMIC_KEYMAP_EEPROM_ADDR 72
|
||||
|
13
keyboards/rama/m60_a/info.json
Normal file
13
keyboards/rama/m60_a/info.json
Normal file
@ -0,0 +1,13 @@
|
||||
{
|
||||
"keyboard_name": "M60-A",
|
||||
"url": "",
|
||||
"maintainer": "Wilba",
|
||||
"bootloader": "DFU",
|
||||
"width": 15,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_60_hhkb": {
|
||||
"layout": [{"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"~", "x":14, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"Delete", "x":13.5, "y":1, "w":1.5}, {"label":"Control", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"label":"Fn", "x":14, "y":3}, {"label":"Os", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Os", "x":12.5, "y":4}]
|
||||
}
|
||||
}
|
||||
}
|
40
keyboards/rama/m60_a/keymaps/default/keymap.c
Normal file
40
keyboards/rama/m60_a/keymaps/default/keymap.c
Normal file
@ -0,0 +1,40 @@
|
||||
// M60-A layout
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_60_hhkb(
|
||||
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_BSLS, 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_BSPC,
|
||||
KC_LCTL, 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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, FN_MO13,
|
||||
KC_LGUI, KC_LALT, KC_SPC, KC_RALT, FN_MO23),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_60_hhkb(
|
||||
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_INS, KC_DEL,
|
||||
KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_EJCT, KC_TRNS, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_60_hhkb(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_60_hhkb(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, ES_DEC, ES_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
||||
|
||||
|
5
keyboards/rama/m60_a/keymaps/proto/config.h
Normal file
5
keyboards/rama/m60_a/keymaps/proto/config.h
Normal file
@ -0,0 +1,5 @@
|
||||
#pragma once
|
||||
|
||||
// This fixes the diodes mounted reversed (fab fail) on M60-A prototype
|
||||
#undef DIODE_DIRECTION
|
||||
#define DIODE_DIRECTION ROW2COL
|
40
keyboards/rama/m60_a/keymaps/proto/keymap.c
Normal file
40
keyboards/rama/m60_a/keymaps/proto/keymap.c
Normal file
@ -0,0 +1,40 @@
|
||||
// M60-A layout
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_60_hhkb(
|
||||
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_BSLS, 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_BSPC,
|
||||
KC_LCTL, 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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, FN_MO13,
|
||||
KC_LGUI, KC_LALT, KC_SPC, KC_RALT, FN_MO23),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_60_hhkb(
|
||||
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_INS, KC_DEL,
|
||||
KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_EJCT, KC_TRNS, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_60_hhkb(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_60_hhkb(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, ES_DEC, ES_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
||||
|
||||
|
18
keyboards/rama/m60_a/m60_a.c
Normal file
18
keyboards/rama/m60_a/m60_a.c
Normal file
@ -0,0 +1,18 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#ifndef RGB_BACKLIGHT_M60_A
|
||||
#error RGB_BACKLIGHT_M60_A not defined, you done goofed somehao, brah
|
||||
#endif
|
37
keyboards/rama/m60_a/m60_a.h
Normal file
37
keyboards/rama/m60_a/m60_a.h
Normal file
@ -0,0 +1,37 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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"
|
||||
#include "../../zeal60/rgb_backlight_keycodes.h"
|
||||
#include "../../zeal60/zeal60_keycodes.h"
|
||||
|
||||
#define XXX KC_NO
|
||||
|
||||
#define LAYOUT_60_hhkb( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K2D, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
|
||||
K41, K42, K47, K4B, K4C \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D }, \
|
||||
{ K30, XXX, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D }, \
|
||||
{ XXX, K41, K42, XXX, XXX, XXX, XXX, K47, XXX, XXX, XXX, K4B, K4C, XXX } \
|
||||
}
|
||||
|
15
keyboards/rama/m60_a/readme.md
Normal file
15
keyboards/rama/m60_a/readme.md
Normal file
@ -0,0 +1,15 @@
|
||||
# RAMA M60-A
|
||||
|
||||
![RAMA M60-A](https://static1.squarespace.com/static/563c788ae4b099120ae219e2/t/5aafa6a20e2e7254480b21bf/1535873164793/RAMA-M60-A-03.688.jpg?format=1500w)
|
||||
|
||||
The M60-A represents the benchmark and equilibrium between function and design for us at Rama Works. The gently exaggerated design of the frame is not understated, but rather provocative. Inspiration and evolution from previous models are evident in the beautifully articulated design and the well defined aesthetic, the fingerprint of our 'Industrial Modern' designs. The M60-A offers a unique contender in the traditional 60% form factor. [More info at RAMA WORKS](https://rama.works/m60-a/)
|
||||
|
||||
Keyboard Maintainer: [Wilba6582](https://github.com/Wilba6582)
|
||||
Hardware Supported: RAMA M60-A PCB
|
||||
Hardware Availability: [RAMA WORKS Store](https://ramaworks.store/)
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make rama/m60_a: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).
|
79
keyboards/rama/m60_a/rules.mk
Normal file
79
keyboards/rama/m60_a/rules.mk
Normal file
@ -0,0 +1,79 @@
|
||||
|
||||
|
||||
# project specific files
|
||||
SRC = ../zeal60/zeal60.c \
|
||||
../zeal60/rgb_backlight.c \
|
||||
quantum/color.c \
|
||||
drivers/issi/is31fl3731.c \
|
||||
drivers/avr/i2c_master.c
|
||||
|
||||
# MCU name
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Boot Section
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
# Do not put the microcontroller into power saving mode
|
||||
# when we get USB suspend event. We want it to keep updating
|
||||
# backlight effects.
|
||||
OPT_DEFS += -DNO_SUSPEND_POWER_DOWN
|
||||
|
||||
# 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(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = yes # 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 = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
|
||||
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
|
||||
RAW_ENABLE = yes
|
||||
DYNAMIC_KEYMAP_ENABLE = yes
|
||||
CIE1931_CURVE = yes
|
||||
|
125
keyboards/zeal60/config.h
Normal file
125
keyboards/zeal60/config.h
Normal file
@ -0,0 +1,125 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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"
|
||||
|
||||
// USB Device descriptor parameter
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x6060
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER ZealPC
|
||||
#define PRODUCT Zeal60
|
||||
#define DESCRIPTION Zeal60 (QMK Firmware)
|
||||
|
||||
// key matrix size
|
||||
#define MATRIX_ROWS 5
|
||||
#define MATRIX_COLS 14
|
||||
|
||||
// Zeal60 PCB default pin-out
|
||||
#define MATRIX_ROW_PINS { F0, F1, F4, F6, F7 }
|
||||
#define MATRIX_COL_PINS { F5, D5, B1, B2, B3, D3, D2, C7, C6, B6, B5, B4, D7, D6 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
// IS31FL3731 driver
|
||||
#define DRIVER_COUNT 2
|
||||
#define DRIVER_LED_TOTAL 72
|
||||
|
||||
// COL2ROW or ROW2COL
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
// Set 0 if debouncing isn't needed
|
||||
#define DEBOUNCING_DELAY 5
|
||||
|
||||
// Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
// Locking resynchronize hack
|
||||
#define LOCKING_RESYNC_ENABLE
|
||||
|
||||
// key combination for command
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
|
||||
)
|
||||
|
||||
/*
|
||||
* 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
|
||||
|
||||
#define RGB_BACKLIGHT_ENABLED 1
|
||||
|
||||
// This conditionally compiles the backlight code for Zeal60 specifics
|
||||
#define RGB_BACKLIGHT_ZEAL60
|
||||
|
||||
// enable/disable LEDs based on layout
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 0
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
||||
|
||||
// disable backlight when USB suspended (PC sleep/hibernate/shutdown)
|
||||
#define RGB_BACKLIGHT_DISABLE_WHEN_USB_SUSPENDED 0
|
||||
|
||||
// disable backlight after timeout in minutes, 0 = no timeout
|
||||
#define RGB_BACKLIGHT_DISABLE_AFTER_TIMEOUT 0
|
||||
|
||||
// the default effect (RGB test)
|
||||
#define RGB_BACKLIGHT_EFFECT 255
|
||||
|
||||
// These define which keys in the matrix are alphas/mods
|
||||
// Used for backlight effects so colors are different for
|
||||
// alphas vs. mods
|
||||
// Each value is for a row, bit 0 is column 0
|
||||
// Alpha=0 Mod=1
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_0 0b0010000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_1 0b0000000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_2 0b0001000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_3 0b0011000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_4 0b0011110000000111
|
||||
|
||||
#define DYNAMIC_KEYMAP_LAYER_COUNT 4
|
||||
|
||||
// EEPROM usage
|
||||
|
||||
// TODO: refactor with new user EEPROM code (coming soon)
|
||||
#define EEPROM_MAGIC 0x451F
|
||||
#define EEPROM_MAGIC_ADDR 32
|
||||
// Bump this every time we change what we store
|
||||
// This will automatically reset the EEPROM with defaults
|
||||
// and avoid loading invalid data from the EEPROM
|
||||
#define EEPROM_VERSION 0x07
|
||||
#define EEPROM_VERSION_ADDR 34
|
||||
|
||||
// Backlight config starts after EEPROM version
|
||||
#define RGB_BACKLIGHT_CONFIG_EEPROM_ADDR 35
|
||||
// Dynamic keymap starts after backlight config (35+37)
|
||||
#define DYNAMIC_KEYMAP_EEPROM_ADDR 72
|
||||
|
25
keyboards/zeal60/info.json
Normal file
25
keyboards/zeal60/info.json
Normal file
@ -0,0 +1,25 @@
|
||||
{
|
||||
"keyboard_name": "Zeal60",
|
||||
"url": "",
|
||||
"maintainer": "Wilba",
|
||||
"bootloader": "DFU",
|
||||
"width": 15,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_all": {
|
||||
"layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":1.25}, {"x":1.25, "y":3}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"Alt", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_60_ansi": {
|
||||
"layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":2.75}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"Alt", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_60_iso": {
|
||||
"layout": [{"label":"\u00ac", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"\"", "x":2, "y":0}, {"label":"\u00a3", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"Enter", "x":13.75, "y":1, "w":1.25, "h":2}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"@", "x":11.75, "y":2}, {"label":"~", "x":12.75, "y":2}, {"label":"Shift", "x":0, "y":3, "w":1.25}, {"label":"|", "x":1.25, "y":3}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":2.75}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"AltGr", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_60_ansi_split_bs_rshift": {
|
||||
"layout": [{"label":"~", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"x":13, "y":0}, {"x":14, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"Caps Lock", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"x":14, "y":3}, {"label":"Ctrl", "x":0, "y":4, "w":1.25}, {"label":"Win", "x":1.25, "y":4, "w":1.25}, {"label":"Alt", "x":2.5, "y":4, "w":1.25}, {"x":3.75, "y":4, "w":6.25}, {"label":"Alt", "x":10, "y":4, "w":1.25}, {"label":"Win", "x":11.25, "y":4, "w":1.25}, {"label":"Menu", "x":12.5, "y":4, "w":1.25}, {"label":"Ctrl", "x":13.75, "y":4, "w":1.25}]
|
||||
},
|
||||
"LAYOUT_60_hhkb": {
|
||||
"layout": [{"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"~", "x":14, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"Delete", "x":13.5, "y":1, "w":1.5}, {"label":"Control", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"label":"Fn", "x":14, "y":3}, {"label":"Os", "x":1.5, "y":4}, {"label":"Alt", "x":2.5, "y":4, "w":1.5}, {"x":4, "y":4, "w":7}, {"label":"Alt", "x":11, "y":4, "w":1.5}, {"label":"Os", "x":12.5, "y":4}]
|
||||
}
|
||||
}
|
||||
}
|
21
keyboards/zeal60/keymaps/ansi_split_bs_rshift/config.h
Normal file
21
keyboards/zeal60/keymaps/ansi_split_bs_rshift/config.h
Normal file
@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
|
||||
#undef RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
||||
|
38
keyboards/zeal60/keymaps/ansi_split_bs_rshift/keymap.c
Normal file
38
keyboards/zeal60/keymaps/ansi_split_bs_rshift/keymap.c
Normal file
@ -0,0 +1,38 @@
|
||||
// ANSI split backspace/right shift layout for Zeal60
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_60_ansi_split_bs_rshift(
|
||||
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_BSLS, 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_BSPC,
|
||||
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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, FN_MO13,
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, KC_RGUI, FN_MO23, KC_RCTL),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_60_ansi_split_bs_rshift(
|
||||
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_INS, KC_DEL,
|
||||
KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_EJCT, KC_TRNS, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_60_ansi_split_bs_rshift(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_60_ansi_split_bs_rshift(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, ES_DEC, ES_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
20
keyboards/zeal60/keymaps/default/config.h
Normal file
20
keyboards/zeal60/keymaps/default/config.h
Normal file
@ -0,0 +1,20 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
|
||||
#undef RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
38
keyboards/zeal60/keymaps/default/keymap.c
Normal file
38
keyboards/zeal60/keymaps/default/keymap.c
Normal file
@ -0,0 +1,38 @@
|
||||
// Default layout for Zeal60
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_60_ansi(
|
||||
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_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_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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT,
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, FN_MO13, FN_MO23, KC_RCTL),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_60_ansi(
|
||||
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_DEL ,
|
||||
KC_CAPS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_INS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_TRNS,
|
||||
KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PGUP, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_END, KC_PGDN, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_60_ansi(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_60_ansi(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, ES_DEC, ES_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
20
keyboards/zeal60/keymaps/hhkb/config.h
Normal file
20
keyboards/zeal60/keymaps/hhkb/config.h
Normal file
@ -0,0 +1,20 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 1
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 1
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 1
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
|
||||
#undef RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 1
|
38
keyboards/zeal60/keymaps/hhkb/keymap.c
Normal file
38
keyboards/zeal60/keymaps/hhkb/keymap.c
Normal file
@ -0,0 +1,38 @@
|
||||
// HHKB layout for Zeal60
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_60_hhkb(
|
||||
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_BSLS, KC_GRV,
|
||||
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_BSPC,
|
||||
KC_LCTL, 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_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, FN_MO13,
|
||||
KC_LGUI, KC_LALT, KC_SPC, KC_RALT, FN_MO23),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_60_hhkb(
|
||||
KC_PWR, 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_INS, KC_DEL,
|
||||
KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_UP, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_EJCT, KC_TRNS, KC_PAST, KC_PSLS, KC_HOME, KC_PGUP, KC_LEFT, KC_RGHT, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PPLS, KC_PMNS, KC_END, KC_PGDN, KC_DOWN, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_60_hhkb(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_60_hhkb(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, ES_DEC, ES_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
20
keyboards/zeal60/keymaps/iso/config.h
Normal file
20
keyboards/zeal60/keymaps/iso/config.h
Normal file
@ -0,0 +1,20 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 1
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 1
|
||||
|
||||
#undef RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
38
keyboards/zeal60/keymaps/iso/keymap.c
Normal file
38
keyboards/zeal60/keymaps/iso/keymap.c
Normal file
@ -0,0 +1,38 @@
|
||||
// ISO layout for Zeal60
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_60_iso(
|
||||
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_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_ENT,
|
||||
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_NUHS,
|
||||
KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT,
|
||||
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, FN_MO13, FN_MO23, KC_RCTL),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_60_iso(
|
||||
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_DEL ,
|
||||
KC_CAPS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_INS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_TRNS,
|
||||
KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_HOME, KC_PGUP, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_END, KC_PGDN, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_60_iso(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_60_iso(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, ES_DEC, ES_INC, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
21
keyboards/zeal60/keymaps/ryanmaclean/config.h
Normal file
21
keyboards/zeal60/keymaps/ryanmaclean/config.h
Normal file
@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 1
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 1
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
|
||||
#undef RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
||||
|
84
keyboards/zeal60/keymaps/ryanmaclean/keymap.c
Normal file
84
keyboards/zeal60/keymaps/ryanmaclean/keymap.c
Normal file
@ -0,0 +1,84 @@
|
||||
// Ryan MacLean's layout for Zeal60
|
||||
// Note that LGUI and RGUI are swapped with LALT and RALT respectively, for use with Macs
|
||||
// Also note that Control has replaced Caps Lock, and that pressing left or right shift once
|
||||
// will output left parenthese and right parenthese respectively.
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
// [0,13] is either left key of split backspace (e.g. HHKB \| key) or 2U backspace
|
||||
// [1,13] is either backslash or ISO Enter
|
||||
// [2,12] is either ANSI Enter or key left of ISO Enter
|
||||
// [2,13] is right key of split backspace (e.g. HHKB `~ key)
|
||||
// [3,1] is right key of split left-shift (e.g ISO key)
|
||||
// [3,13] is right key of split right-shift (e.g. HHKB Fn key)
|
||||
|
||||
|
||||
|
||||
const macro_t *action_get_macro(keyrecord_t *record, uint8_t id, uint8_t opt) // this is the function signature -- just copy/paste it into your keymap file as it is. KC_LSFT KC_LALT KC_LGUI KC_4
|
||||
{
|
||||
switch(id) {
|
||||
case 0: // macOS screenshot to capture are to clipboard - this would trigger when you hit a key mapped as M(0)
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LSFT), D(LCTL), D(LGUI), T(4), U(LSFT), U(LCTL), U(LGUI), W(255), END ); // this sends the string 'hello' when the macro executes
|
||||
}
|
||||
break;
|
||||
case 1: // macOS screenshot capture area to file - this would trigger when you hit a key mapped as M(1)
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LSFT), D(LGUI), T(4), U(LSFT), U(LGUI), W(255), END ); // this sends the string 'hello' when the macro executes
|
||||
}
|
||||
break;
|
||||
case 2: // macOS screenshot to clipboard - this would trigger when you hit a key mapped as M(2)
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LSFT), D(LCTL), D(LGUI), T(3), U(LSFT), U(LCTL), U(LGUI), W(255), END ); // this sends the string 'hello' when the macro executes
|
||||
}
|
||||
break;
|
||||
case 3: // macOS screenshot to file - this would trigger when you hit a key mapped as M(3)
|
||||
if (record->event.pressed) {
|
||||
return MACRO( D(LSFT), D(LGUI), T(3), U(LSFT), U(LGUI), W(255), END ); // this sends the string 'hello' when the macro executes
|
||||
}
|
||||
break;
|
||||
}
|
||||
return MACRO_NONE;
|
||||
};
|
||||
|
||||
#define CADETL MT(KC_LSFT, KC_LBRC)
|
||||
#define CADETR MT(KC_RSFT, KC_RBRC)
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = {
|
||||
{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_BSLS},
|
||||
{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_BSPC},
|
||||
{KC_LGUI, 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_GRV},
|
||||
{KC_LSPO, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSPC, FN_MO13},
|
||||
{KC_LCTL, KC_LALT, KC_LGUI, KC_NO, KC_NO, KC_NO, KC_NO, KC_SPC, KC_NO, KC_NO, KC_RGUI, KC_RALT, KC_RCTL, FN_MO23}
|
||||
},
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = {
|
||||
{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_TRNS},
|
||||
{KC_CAPS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_INS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_DEL},
|
||||
{KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_TRNS, KC_LEFT, KC_UP, KC_DOWN, KC_RGHT, KC_HOME, KC_PGUP, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_END, KC_PGDN, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS}
|
||||
},
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = {
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, M(2), M(3), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, M(1), M(0), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS}
|
||||
},
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = {
|
||||
{KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS},
|
||||
{KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS}
|
||||
}
|
||||
|
||||
};
|
6
keyboards/zeal60/keymaps/tusing/Makefile
Normal file
6
keyboards/zeal60/keymaps/tusing/Makefile
Normal file
@ -0,0 +1,6 @@
|
||||
# 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
|
||||
#
|
||||
RGBLIGHT_ENABLE = yes
|
||||
AUDIO_ENABLE = no # Underglow cannot be used with audio.
|
80
keyboards/zeal60/keymaps/tusing/README.md
Normal file
80
keyboards/zeal60/keymaps/tusing/README.md
Normal file
@ -0,0 +1,80 @@
|
||||
# RGB Underglow Strip on the Zeal60: A Guide
|
||||
|
||||
<img src="https://i.imgur.com/UuUdOCb.jpg" width="800">
|
||||
|
||||
## Requirements
|
||||
|
||||
- WS2812B RGB strip, preferably 60 LEDs/meter
|
||||
- Wire, solder
|
||||
- Tape, hot glue, or some sort of adhesive
|
||||
|
||||
## A. Connecting the strip
|
||||
You might find the [**full PCB image**](https://cdn.shopify.com/s/files/1/0490/7329/files/zeal60jumpers.png) helpful. Ignore the red boxes!
|
||||
|
||||
1. Connect V+ to the receiving end of the thermistor labeled F1; connect GND to the board's GND pin. (*Avoid connecting +V to the board's +5V pin* - you will likely overload the thermistor, and you will limit your maximum brightness.)
|
||||
|
||||
<img src="https://i.imgur.com/jd7qivh.png" width="300">
|
||||
|
||||
2. Connect DI to PB0.
|
||||
|
||||
<img src="https://i.imgur.com/BiMyMLv.jpg" width="300">
|
||||
|
||||
3. Should look something like this when finished:
|
||||
|
||||
<img src="https://i.imgur.com/ngxYMuA.jpg" width="600">
|
||||
|
||||
*Optional:* To allow considerably more light to escape, consider angling the strip outwards by using some sort of fulcrum under the strip. (I used a thick wire.)
|
||||
|
||||
## B. Enabling the strip
|
||||
1. If it is not present already, add the following to your ***keymap's*** ```Makefile```:
|
||||
|
||||
```Makefile
|
||||
RGBLIGHT_ENABLE = yes
|
||||
AUDIO_ENABLE = no #Underglow animations cannot be used with audio.
|
||||
```
|
||||
2. If it is not present already, add the following to your *keymap's* ```config.h```, and edit the values as necessary:
|
||||
|
||||
```c
|
||||
// Set up RGB underglow.
|
||||
#define RGB_DI_PIN B0 // The pin your RGB strip is wired to
|
||||
#define RGBLIGHT_ANIMATIONS // Require for fancier stuff (not compatible with audio)
|
||||
#define RGBLED_NUM 35 // Number of LEDs
|
||||
#define RGBLIGHT_HUE_STEP 5 // How much each press of rgb_hue changes hue
|
||||
#define RGBLIGHT_SAT_STEP 10 // How much each press of rgb_sat changes sat
|
||||
#define RGBLIGHT_VAL_STEP 10 // How much each press of rgb_val changes val
|
||||
```
|
||||
3. If they are not present already, add the following keycodes to your keymap to control the RGB strip: ```RGB_TOG``` (on/off), ```RGB_MOD``` (step through modes), ```RGB_HUI```, ```RGB_HUD```, ```RGB_SAI```, ```RGB_SAD```, ```RGB_VAI```, ```RGB_VAD``` (HSV increase/decrease). Add these to your keymap.
|
||||
|
||||
## C. Dealing with current limits
|
||||
USB 2.0 ports on laptops provide up to 500mA max, but USB 3.0 ports can provide up to 900mA; USB 3.1 up to 1.5A; and powered USB hubs even more. We can run our keyboard at a higher brightness if we draw more power. **The Zeal60 uses 500mA at max brightness.** This means that **you have about 400mA remaining for the strip to use on a USB 3.0 port**; 1000mA free on a USB 3.1 port, so on and so forth.
|
||||
|
||||
***Warning:*** **This means you will need to turn *off* your RGB strip before connecting to a USB 2.0 port**, as USB 2.0 cannot sustain the current necessary!
|
||||
|
||||
1. If not present already, add the following to your keymap's ```config.h```. Change the numbers based on your needs. The ones below are safe underestimates.
|
||||
|
||||
```c
|
||||
// Enable current limiting for RGB underglow.
|
||||
#define RGBSTRIP_CURRENT_LIMIT 400 // Strip current limit in mA. (USB amperage - 500mA for keyboard)
|
||||
#define RGBSTRIP_MAX_CURRENT_PER_LIGHT 50 // mA per light when at max brightness.
|
||||
```
|
||||
*Example:* I use a USB port capable of providing 1800 mA. The keyboard uses 500mA, so my personal value (in the `tusing` keymap) for `RGBSTRIP_CURRENT_LIMIT` is 1300. The particular WS2812B RGB strip I have uses a maximum of 60 mA per LED, so that is my personal value for `RGBSTRIP_MAX_CURRENT_PER_LIGHT`.
|
||||
2. Toggle on the LED strip (```RGB_TOG```) and step through animations (```RGB_MOD```) to test it out!
|
||||
|
||||
## D. Sources and resources
|
||||
### A. Connecting the strip.
|
||||
* [In-depth description of connecting an RGB strip to the GH60](https://www.reddit.com/r/MechanicalKeyboards/comments/4d5or2/my_first_custom_build_satan_gh60_rbg_underglow_in/d1nz3o7/)
|
||||
* [32U4 Pinout](https://40.media.tumblr.com/93b6bbd4113418c2b45459bb177e67c5/tumblr_mi49a20QMB1s5t695o1_1280.png)
|
||||
* [Redditor describes connecting RGB strips on his Satan GH60](https://www.reddit.com/r/MechanicalKeyboards/comments/4hbjw4/finally_finished_my_satan_gh60_also_granite_o/d2qn8zx/?context=3)
|
||||
* [Another Redditor on RGB with the Satan GH60](https://www.reddit.com/r/MechanicalKeyboards/comments/4ewzdx/gh60_satan_with_the_rgb_mod/d251uu6/ )
|
||||
|
||||
### B. Enabling the strip.
|
||||
* [QMK Wiki portion on underglow](https://github.com/jackhumbert/qmk_firmware/wiki#rgb-under-glow-mod)
|
||||
* [Planck ```Makefile```, ```config.h```, and ```keymap.c``` config example](https://github.com/jackhumbert/qmk_firmware/tree/master/keyboards/planck/keymaps/yang)
|
||||
* [Video demonstrating keycode functions and RGB modes on a KC60](https://www.youtube.com/watch?v=VKrpPAHlisY)
|
||||
|
||||
### C. Dealing with current limits.
|
||||
* [Discussion of cutting jumpers and adding resistors to lower current from Zeal60](https://www.reddit.com/r/MechanicalKeyboards/comments/5hou92/photos_zeal60_lets_just_say_santa_came_early_this/db23qid/)
|
||||
* [A selection of 900mA-1.5A current hold fuses - look for an SMD 0805-sized fuse.](https://goo.gl/748avG)
|
||||
* [Video detailing technique to solder 0805 resistors](https://www.youtube.com/watch?v=PU7wLcuqc-I&t=123s&list=FLheMlKEVQ5cmVXazUt6HrxQ&index=2)
|
||||
* [QMK feature request to implement max power draw limits in ```config.h```](https://github.com/jackhumbert/qmk_firmware/issues/954)
|
||||
* [Commit enabling max power draw limits in ```config.h```](https://github.com/jackhumbert/qmk_firmware/commit/83e613ad239459582ae28f78b6c81535b9b138d7)
|
40
keyboards/zeal60/keymaps/tusing/config.h
Normal file
40
keyboards/zeal60/keymaps/tusing/config.h
Normal file
@ -0,0 +1,40 @@
|
||||
#pragma once
|
||||
|
||||
/* Enable/disable LEDs based on layout. */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
|
||||
#undef RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
|
||||
#undef RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
||||
|
||||
// Set up RGB underglow.
|
||||
#define RGB_DI_PIN B0 // The pin your RGB strip is wired to
|
||||
#define RGBLIGHT_ANIMATIONS // Require for fancier stuff (not compatible with audio)
|
||||
#define RGBLED_NUM 35 // Number of LEDs
|
||||
#define RGBLIGHT_HUE_STEP 5 // How much each press of rgb_hue changes hue
|
||||
#define RGBLIGHT_SAT_STEP 10 // How much each press of rgb_sat changes sat
|
||||
#define RGBLIGHT_VAL_STEP 10 // How much each press of rgb_val changes val
|
||||
|
||||
// Enable current limiting for RGB underglow.
|
||||
#define RGBSTRIP_CURRENT_LIMIT 1300 // Strip current limit in mA. (USB amperage - 500mA for keyboard)
|
||||
#define RGBSTRIP_MAX_CURRENT_PER_LIGHT 40 // mA per light when at max brightness.
|
||||
|
||||
// Scale brightnes according to BRIGHTNESS_CORRECTION_TABLE in quantum/rgblight.c.
|
||||
// This allows to mitigate uneven brightness from LED underglow strips.
|
||||
// #define LED_BRIGHTNESS_CORRECTION
|
||||
|
||||
// Prevent modifiers on layer 1 from persisting after we let go
|
||||
#define PREVENT_STUCK_MODIFIERS
|
||||
|
49
keyboards/zeal60/keymaps/tusing/keymap.c
Normal file
49
keyboards/zeal60/keymaps/tusing/keymap.c
Normal file
@ -0,0 +1,49 @@
|
||||
// Default layout for Zeal60
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
// For readability.
|
||||
#define _______ KC_TRNS
|
||||
#define _x_ KC_NO
|
||||
#define AUD_PRV LCTL(KC_MPRV) // Previous music track
|
||||
#define AUD_PLY LCTL(KC_MPLY) // Pause music
|
||||
#define AUD_NXT LCTL(KC_MNXT) // Next music track
|
||||
|
||||
// Zeal60-specific keys:
|
||||
// EF_INC, EF_DEC, // next/previous backlight effect
|
||||
// H1_INC, H1_DEC, // Color 1 hue increase/decrease
|
||||
// S1_INC, S1_DEC, // Color 1 saturation increase/decrease
|
||||
// H2_INC, H2_DEC, // Color 2 hue increase/decrease
|
||||
// S2_INC, S2_DEC, // Color 2 saturation increase/decrease
|
||||
// BR_INC, BR_DEC, // backlight brightness increase/decrease
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
// Default layer: Pressing caps-lock momentarily switches to Layer 1.
|
||||
// This is the default layer. Pressing an empty keycode on another layer will take you here.
|
||||
[0] = {
|
||||
{KC_GRV, 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_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},
|
||||
{MO(1), KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, _x_ },
|
||||
{KC_LSFT, _x_ , KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, _x_ },
|
||||
{KC_LCTL, KC_LGUI, KC_LALT, _x_ , _x_ , _x_ , _x_ , KC_SPC, _x_ , _x_ , KC_LEFT, KC_UP, KC_DOWN, KC_RGHT}
|
||||
},
|
||||
|
||||
// Layer 1: Pressing enter switches to layer 2, where backlight controls live.
|
||||
// This is a momentary layer: once you let go of caps, you'll be back in layer 1.
|
||||
[1] = {
|
||||
{KC_ESC, 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_DEL },
|
||||
{_______, KC_VOLD, KC_MUTE, KC_VOLU, _______, _______, _______, _______, KC_PSCR, KC_SLCK, KC_PAUS, KC_INS, KC_DEL, _______},
|
||||
{_______, AUD_PRV, AUD_PLY, AUD_NXT, _______, _______, _______, _______, _______, _______, _______, _______, TO(2) , _x_ },
|
||||
{KC_CAPS, _x_ , _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _x_ },
|
||||
{KC_RCTL, KC_RGUI, KC_RALT, _x_ , _x_ , _x_ , _x_ , _______, _x_ , _x_ , KC_HOME, KC_PGUP, KC_PGDN, KC_END}
|
||||
},
|
||||
|
||||
// Layer 2: Zeal60 and backlight configuration. (Get here quickly by pressing Caps+Enter from Layer 1.)
|
||||
// This is a persistent layer. Get back to the default layer by pressing enter.
|
||||
[2] = {
|
||||
{RESET, EF_DEC, EF_INC, BR_DEC, BR_INC, ES_DEC, ES_INC, _______, _______, _______, _______, _______, _______, _______},
|
||||
{_______, H1_DEC, H1_INC, S1_DEC, S1_INC, _______, _______, _______, _______, _______, _______, _______, _______, _______},
|
||||
{_______, H2_DEC, H2_INC, S2_DEC, S2_INC, _______, _______, _______, _______, _______, _______, _______, TO(0) , _x_ },
|
||||
{RGB_MOD, _x_ , RGB_HUD, RGB_HUI, RGB_SAD, RGB_SAI, _______, _______, _______, _______, _______, _______, _______, _x_ },
|
||||
{RGB_TOG, RGB_VAD, RGB_VAI, _x_ , _x_ , _x_ , _x_ , _______, _x_ , _x_ , _______, _______, _______, _______}
|
||||
}
|
||||
};
|
47
keyboards/zeal60/readme.md
Normal file
47
keyboards/zeal60/readme.md
Normal file
@ -0,0 +1,47 @@
|
||||
Zeal60
|
||||
====
|
||||
|
||||
![Zeal60](https://cdn.shopify.com/s/files/1/0490/7329/products/Zeal60.jpg)
|
||||
|
||||
This is a 60% PCB with per-key RGB LEDs and supports ANSI, ISO, winkey/winkeyless bottom row, HHKB-layout (split right shift and backspace).
|
||||
|
||||
Keyboard Maintainer: [Wilba](http://wilba.tech/) and on [github](https://github.com/Wilba6582)
|
||||
Hardware Supported: Zeal60 PCB Rev 0-3
|
||||
Hardware Availability: https://zealpc.net/collections/group-buy-pre-orders/products/zeal60rgb
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make zeal60: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).
|
||||
|
||||
|
||||
RGB Backlight Configuration
|
||||
====
|
||||
|
||||
A keymap (in the keymaps directory) can optionally configure which RGB backlight LEDs are used, depending on the needs of the layout, by adding a config.h file in the keymap's directory.
|
||||
The following #define symbols will enable/disable a feature using 1 or 0.
|
||||
|
||||
RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
|
||||
Split backspace is being used, enables the right LED of the split backspace (the top-right corner)
|
||||
|
||||
RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT
|
||||
|
||||
Split left shift is being used (i.e. ISO layout), enables the right LED of the split left shift (the ISO key)
|
||||
|
||||
RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT
|
||||
|
||||
Split right shift is being used (i.e. HHKB style layouts), enables the right LED of the split right shift (the Fn key)
|
||||
|
||||
RGB_BACKLIGHT_USE_7U_SPACEBAR
|
||||
|
||||
A 7U spacebar is being used, controls the LEDs under the right stabilizer (of 7U spacebar) and right Alt (if 6.25U spacebar).
|
||||
|
||||
RGB_BACKLIGHT_USE_ISO_ENTER
|
||||
|
||||
An ISO Enter is being used. Only used to tweak the location of the LED being used under ANSI Enter/backslash
|
||||
|
||||
RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS
|
||||
|
||||
Disables the LEDs under HHKB corner blockers, useful for transparent cases.
|
1519
keyboards/zeal60/rgb_backlight.c
Normal file
1519
keyboards/zeal60/rgb_backlight.c
Normal file
File diff suppressed because it is too large
Load Diff
101
keyboards/zeal60/rgb_backlight.h
Normal file
101
keyboards/zeal60/rgb_backlight.h
Normal file
@ -0,0 +1,101 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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
|
||||
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
#else
|
||||
#error rgb_backlight.h included when RGB_BACKLIGHT_ENABLED == 0
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
#include "quantum/color.h"
|
||||
|
||||
typedef struct
|
||||
{
|
||||
HSV color;
|
||||
uint8_t index;
|
||||
} backlight_config_indicator;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
bool use_split_backspace:1; // |
|
||||
bool use_split_left_shift:1; // |
|
||||
bool use_split_right_shift:1; // |
|
||||
bool use_7u_spacebar:1; // |
|
||||
bool use_iso_enter:1; // |
|
||||
bool disable_when_usb_suspended:1; // |
|
||||
bool disable_hhkb_blocker_leds:1; // |
|
||||
bool __pad7:1; // 1 byte
|
||||
uint8_t disable_after_timeout; // 1 byte
|
||||
uint8_t brightness; // 1 byte
|
||||
uint8_t effect; // 1 byte
|
||||
uint8_t effect_speed; // 1 byte
|
||||
HSV color_1; // 3 bytes
|
||||
HSV color_2; // 3 bytes
|
||||
backlight_config_indicator caps_lock_indicator; // 4 bytes
|
||||
backlight_config_indicator layer_1_indicator; // 4 bytes
|
||||
backlight_config_indicator layer_2_indicator; // 4 bytes
|
||||
backlight_config_indicator layer_3_indicator; // 4 bytes
|
||||
uint16_t alphas_mods[5]; // 10 bytes
|
||||
} backlight_config; // = 37 bytes
|
||||
|
||||
void backlight_config_load(void);
|
||||
void backlight_config_save(void);
|
||||
void backlight_config_set_value( uint8_t *data );
|
||||
void backlight_config_get_value( uint8_t *data );
|
||||
|
||||
void backlight_init_drivers(void);
|
||||
|
||||
void backlight_timer_init(void);
|
||||
void backlight_timer_enable(void);
|
||||
void backlight_timer_disable(void);
|
||||
|
||||
void backlight_set_suspend_state(bool state);
|
||||
void backlight_set_indicator_state(uint8_t state);
|
||||
|
||||
// This should not be called from an interrupt
|
||||
// (eg. from a timer interrupt).
|
||||
// Call this while idle (in between matrix scans).
|
||||
// If the buffer is dirty, it will update the driver with the buffer.
|
||||
void backlight_update_pwm_buffers(void);
|
||||
|
||||
// Handle backlight specific keycodes
|
||||
bool process_record_backlight(uint16_t keycode, keyrecord_t *record);
|
||||
|
||||
void backlight_set_key_hit(uint8_t row, uint8_t col);
|
||||
|
||||
void backlight_effect_increase(void);
|
||||
void backlight_effect_decrease(void);
|
||||
void backlight_effect_speed_increase(void);
|
||||
void backlight_effect_speed_decrease(void);
|
||||
|
||||
void backlight_brightness_increase(void);
|
||||
void backlight_brightness_decrease(void);
|
||||
|
||||
void backlight_color_1_hue_increase(void);
|
||||
void backlight_color_1_hue_decrease(void);
|
||||
void backlight_color_1_sat_increase(void);
|
||||
void backlight_color_1_sat_decrease(void);
|
||||
void backlight_color_2_hue_increase(void);
|
||||
void backlight_color_2_hue_decrease(void);
|
||||
void backlight_color_2_sat_increase(void);
|
||||
void backlight_color_2_sat_decrease(void);
|
||||
|
||||
void backlight_test_led( uint8_t index, bool red, bool green, bool blue );
|
||||
void backlight_debug_led(bool state);
|
||||
|
42
keyboards/zeal60/rgb_backlight_api.h
Normal file
42
keyboards/zeal60/rgb_backlight_api.h
Normal file
@ -0,0 +1,42 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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
|
||||
|
||||
enum backlight_config_value
|
||||
{
|
||||
id_use_split_backspace = 0x01,
|
||||
id_use_split_left_shift = 0x02,
|
||||
id_use_split_right_shift = 0x03,
|
||||
id_use_7u_spacebar = 0x04,
|
||||
id_use_iso_enter = 0x05,
|
||||
id_disable_hhkb_blocker_leds = 0x06,
|
||||
id_disable_when_usb_suspended = 0x07,
|
||||
id_disable_after_timeout = 0x08,
|
||||
id_brightness = 0x09,
|
||||
id_effect = 0x0A,
|
||||
id_effect_speed = 0x0B,
|
||||
id_color_1 = 0x0C,
|
||||
id_color_2 = 0x0D,
|
||||
id_caps_lock_indicator_color = 0x0E,
|
||||
id_caps_lock_indicator_row_col = 0x0F,
|
||||
id_layer_1_indicator_color = 0x10,
|
||||
id_layer_1_indicator_row_col = 0x11,
|
||||
id_layer_2_indicator_color = 0x12,
|
||||
id_layer_2_indicator_row_col = 0x13,
|
||||
id_layer_3_indicator_color = 0x14,
|
||||
id_layer_3_indicator_row_col = 0x15,
|
||||
id_alphas_mods = 0x16
|
||||
};
|
34
keyboards/zeal60/rgb_backlight_keycodes.h
Normal file
34
keyboards/zeal60/rgb_backlight_keycodes.h
Normal file
@ -0,0 +1,34 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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
|
||||
|
||||
// This is hardcoded at 0x5F00 so it's well after keycode value SAFE_RANGE
|
||||
enum backlight_keycodes {
|
||||
BR_INC = 0x5F00, // backlight brightness increase
|
||||
BR_DEC, // backlight brightness decrease
|
||||
EF_INC, // backlight effect increase
|
||||
EF_DEC, // backlight effect decrease
|
||||
ES_INC,
|
||||
ES_DEC,
|
||||
H1_INC,
|
||||
H1_DEC,
|
||||
S1_INC,
|
||||
S1_DEC,
|
||||
H2_INC,
|
||||
H2_DEC,
|
||||
S2_INC,
|
||||
S2_DEC
|
||||
};
|
78
keyboards/zeal60/rules.mk
Normal file
78
keyboards/zeal60/rules.mk
Normal file
@ -0,0 +1,78 @@
|
||||
|
||||
|
||||
# project specific files
|
||||
SRC = rgb_backlight.c \
|
||||
quantum/color.c \
|
||||
drivers/issi/is31fl3731.c \
|
||||
drivers/avr/i2c_master.c
|
||||
|
||||
# MCU name
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Boot Section
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
# Do not put the microcontroller into power saving mode
|
||||
# when we get USB suspend event. We want it to keep updating
|
||||
# backlight effects.
|
||||
OPT_DEFS += -DNO_SUSPEND_POWER_DOWN
|
||||
|
||||
# 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(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = yes # 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 = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
|
||||
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE ?= no # Breathing sleep LED during USB suspend
|
||||
|
||||
RAW_ENABLE = yes
|
||||
DYNAMIC_KEYMAP_ENABLE = yes
|
||||
CIE1931_CURVE = yes
|
||||
|
341
keyboards/zeal60/zeal60.c
Normal file
341
keyboards/zeal60/zeal60.c
Normal file
@ -0,0 +1,341 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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 "zeal60.h"
|
||||
#include "zeal60_api.h"
|
||||
|
||||
// Check that no backlight functions are called
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
#include "rgb_backlight.h"
|
||||
#endif // BACKLIGHT_ENABLED
|
||||
|
||||
#include "raw_hid.h"
|
||||
#include "dynamic_keymap.h"
|
||||
#include "timer.h"
|
||||
#include "tmk_core/common/eeprom.h"
|
||||
|
||||
bool eeprom_is_valid(void)
|
||||
{
|
||||
return (eeprom_read_word(((void*)EEPROM_MAGIC_ADDR)) == EEPROM_MAGIC &&
|
||||
eeprom_read_byte(((void*)EEPROM_VERSION_ADDR)) == EEPROM_VERSION);
|
||||
}
|
||||
|
||||
void eeprom_set_valid(bool valid)
|
||||
{
|
||||
eeprom_update_word(((void*)EEPROM_MAGIC_ADDR), valid ? EEPROM_MAGIC : 0xFFFF);
|
||||
eeprom_update_byte(((void*)EEPROM_VERSION_ADDR), valid ? EEPROM_VERSION : 0xFF);
|
||||
}
|
||||
|
||||
#ifdef RAW_ENABLE
|
||||
|
||||
void raw_hid_receive( uint8_t *data, uint8_t length )
|
||||
{
|
||||
uint8_t *command_id = &(data[0]);
|
||||
uint8_t *command_data = &(data[1]);
|
||||
switch ( *command_id )
|
||||
{
|
||||
case id_get_protocol_version:
|
||||
{
|
||||
command_data[0] = PROTOCOL_VERSION >> 8;
|
||||
command_data[1] = PROTOCOL_VERSION & 0xFF;
|
||||
break;
|
||||
}
|
||||
case id_get_keyboard_value:
|
||||
{
|
||||
if ( command_data[0] == 0x01 )
|
||||
{
|
||||
uint32_t value = timer_read32();
|
||||
command_data[1] = (value >> 24 ) & 0xFF;
|
||||
command_data[2] = (value >> 16 ) & 0xFF;
|
||||
command_data[3] = (value >> 8 ) & 0xFF;
|
||||
command_data[4] = value & 0xFF;
|
||||
}
|
||||
else
|
||||
{
|
||||
*command_id = id_unhandled;
|
||||
}
|
||||
break;
|
||||
}
|
||||
#ifdef DYNAMIC_KEYMAP_ENABLE
|
||||
case id_dynamic_keymap_get_keycode:
|
||||
{
|
||||
uint16_t keycode = dynamic_keymap_get_keycode( command_data[0], command_data[1], command_data[2] );
|
||||
command_data[3] = keycode >> 8;
|
||||
command_data[4] = keycode & 0xFF;
|
||||
break;
|
||||
}
|
||||
case id_dynamic_keymap_set_keycode:
|
||||
{
|
||||
dynamic_keymap_set_keycode( command_data[0], command_data[1], command_data[2], ( command_data[3] << 8 ) | command_data[4] );
|
||||
break;
|
||||
}
|
||||
case id_dynamic_keymap_clear_all:
|
||||
{
|
||||
dynamic_keymap_clear_all();
|
||||
break;
|
||||
}
|
||||
#endif // DYNAMIC_KEYMAP_ENABLE
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
case id_backlight_config_set_value:
|
||||
{
|
||||
backlight_config_set_value(command_data);
|
||||
break;
|
||||
}
|
||||
case id_backlight_config_get_value:
|
||||
{
|
||||
backlight_config_get_value(command_data);
|
||||
break;
|
||||
}
|
||||
case id_backlight_config_save:
|
||||
{
|
||||
backlight_config_save();
|
||||
break;
|
||||
}
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
default:
|
||||
{
|
||||
// Unhandled message.
|
||||
*command_id = id_unhandled;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// Return same buffer with values changed
|
||||
raw_hid_send( data, length );
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
void bootmagic_lite(void)
|
||||
{
|
||||
// The lite version of TMK's bootmagic.
|
||||
// 100% less potential for accidentally making the
|
||||
// keyboard do stupid things.
|
||||
|
||||
// We need multiple scans because debouncing can't be turned off.
|
||||
matrix_scan();
|
||||
wait_ms(DEBOUNCING_DELAY);
|
||||
wait_ms(DEBOUNCING_DELAY);
|
||||
matrix_scan();
|
||||
|
||||
// If the Esc and space bar are held down on power up,
|
||||
// reset the EEPROM valid state and jump to bootloader.
|
||||
// Assumes Esc is at [0,0] and spacebar is at [4,7].
|
||||
// This isn't very generalized, but we need something that doesn't
|
||||
// rely on user's keymaps in firmware or EEPROM.
|
||||
if ( ( matrix_get_row(0) & (1<<0) ) &&
|
||||
( matrix_get_row(4) & (1<<7) ) )
|
||||
{
|
||||
// Set the Zeal60 specific EEPROM state as invalid.
|
||||
eeprom_set_valid(false);
|
||||
// Set the TMK/QMK EEPROM state as invalid.
|
||||
eeconfig_disable();
|
||||
// Jump to bootloader.
|
||||
bootloader_jump();
|
||||
}
|
||||
}
|
||||
|
||||
void matrix_init_kb(void)
|
||||
{
|
||||
bootmagic_lite();
|
||||
|
||||
// If the EEPROM has the magic, the data is good.
|
||||
// OK to load from EEPROM.
|
||||
if (eeprom_is_valid())
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
backlight_config_load();
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
// TODO: do something to "turn on" keymaps in EEPROM?
|
||||
}
|
||||
else
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
// If the EEPROM has not been saved before, or is out of date,
|
||||
// save the default values to the EEPROM. Default values
|
||||
// come from construction of the zeal_backlight_config instance.
|
||||
backlight_config_save();
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
|
||||
#ifdef DYNAMIC_KEYMAP_ENABLE
|
||||
// This saves "empty" keymaps so it falls back to the keymaps
|
||||
// in the firmware (aka. progmem/flash)
|
||||
dynamic_keymap_clear_all();
|
||||
#endif
|
||||
|
||||
// Save the magic number last, in case saving was interrupted
|
||||
eeprom_set_valid(true);
|
||||
}
|
||||
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
// Initialize LED drivers for backlight.
|
||||
backlight_init_drivers();
|
||||
|
||||
backlight_timer_init();
|
||||
backlight_timer_enable();
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
|
||||
matrix_init_user();
|
||||
}
|
||||
|
||||
void matrix_scan_kb(void)
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
// This only updates the LED driver buffers if something has changed.
|
||||
backlight_update_pwm_buffers();
|
||||
#endif // BACKLIGHT_ENABLED
|
||||
matrix_scan_user();
|
||||
}
|
||||
|
||||
bool process_record_kb(uint16_t keycode, keyrecord_t *record)
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
process_record_backlight(keycode, record);
|
||||
#endif // BACKLIGHT_ENABLED
|
||||
|
||||
switch(keycode)
|
||||
{
|
||||
case FN_MO13:
|
||||
if (record->event.pressed)
|
||||
{
|
||||
layer_on(1);
|
||||
update_tri_layer(1, 2, 3);
|
||||
}
|
||||
else
|
||||
{
|
||||
layer_off(1);
|
||||
update_tri_layer(1, 2, 3);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
case FN_MO23:
|
||||
if (record->event.pressed)
|
||||
{
|
||||
layer_on(2);
|
||||
update_tri_layer(1, 2, 3);
|
||||
}
|
||||
else
|
||||
{
|
||||
layer_off(2);
|
||||
update_tri_layer(1, 2, 3);
|
||||
}
|
||||
return false;
|
||||
break;
|
||||
}
|
||||
|
||||
return process_record_user(keycode, record);
|
||||
}
|
||||
|
||||
// This overrides the one in quantum/keymap_common.c
|
||||
uint16_t keymap_function_id_to_action( uint16_t function_id )
|
||||
{
|
||||
// Zeal60 specific "action functions" are 0xF00 to 0xFFF
|
||||
// i.e. F(0xF00) to F(0xFFF) are mapped to
|
||||
// enum zeal60_action_functions by masking last 8 bits.
|
||||
if ( function_id >= 0x0F00 && function_id <= 0x0FFF )
|
||||
{
|
||||
uint8_t id = function_id & 0xFF;
|
||||
switch ( id )
|
||||
{
|
||||
case TRIPLE_TAP_1_3:
|
||||
case TRIPLE_TAP_2_3:
|
||||
{
|
||||
return ACTION_FUNCTION_TAP(id);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
#if USE_KEYMAPS_IN_EEPROM
|
||||
|
||||
#if 0
|
||||
// This is how to implement actions stored in EEPROM.
|
||||
// Not yet implemented. Not sure if it's worth the trouble
|
||||
// before we have a nice GUI for keymap editing.
|
||||
if ( eeprom_is_valid() &&
|
||||
function_id < 32 ) // TODO: replace magic number
|
||||
{
|
||||
uint16_t action = keymap_action_load(function_id);
|
||||
|
||||
// If action is not "empty", return it, otherwise
|
||||
// drop down to return the one in flash
|
||||
if ( action != 0x0000 ) // TODO: replace magic number
|
||||
{
|
||||
return action;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // USE_KEYMAPS_IN_EEPROM
|
||||
|
||||
return pgm_read_word(&fn_actions[function_id]);
|
||||
}
|
||||
|
||||
|
||||
// Zeal60 specific "action functions"
|
||||
void action_function(keyrecord_t *record, uint8_t id, uint8_t opt)
|
||||
{
|
||||
switch (id)
|
||||
{
|
||||
case TRIPLE_TAP_1_3:
|
||||
case TRIPLE_TAP_2_3:
|
||||
if (record->event.pressed)
|
||||
{
|
||||
layer_on( id == TRIPLE_TAP_1_3 ? 1 : 2 );
|
||||
|
||||
if (record->tap.count && !record->tap.interrupted)
|
||||
{
|
||||
if (record->tap.count >= 3)
|
||||
{
|
||||
layer_invert(3);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
record->tap.count = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
layer_off( id == TRIPLE_TAP_1_3 ? 1 : 2 );
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void led_set_kb(uint8_t usb_led)
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
backlight_set_indicator_state(usb_led);
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
}
|
||||
|
||||
void suspend_power_down_kb(void)
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
backlight_set_suspend_state(true);
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
}
|
||||
|
||||
void suspend_wakeup_init_kb(void)
|
||||
{
|
||||
#if RGB_BACKLIGHT_ENABLED
|
||||
backlight_set_suspend_state(false);
|
||||
#endif // RGB_BACKLIGHT_ENABLED
|
||||
}
|
||||
|
93
keyboards/zeal60/zeal60.h
Normal file
93
keyboards/zeal60/zeal60.h
Normal file
@ -0,0 +1,93 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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"
|
||||
#include "rgb_backlight_keycodes.h"
|
||||
#include "zeal60_keycodes.h"
|
||||
|
||||
#define XXX KC_NO
|
||||
|
||||
#define LAYOUT_60_all( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K2D, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, \
|
||||
K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
|
||||
K40, K41, K42, K47, K4A, K4B, K4C, K4D \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D }, \
|
||||
{ K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D }, \
|
||||
{ K40, K41, K42, XXX, XXX, XXX, XXX, K47, XXX, XXX, K4A, K4B, K4C, K4D } \
|
||||
}
|
||||
|
||||
#define LAYOUT_60_ansi( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, \
|
||||
K40, K41, K42, K47, K4A, K4B, K4C, K4D \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, XXX }, \
|
||||
{ K30, XXX, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, XXX }, \
|
||||
{ K40, K41, K42, XXX, XXX, XXX, XXX, K47, XXX, XXX, K4A, K4B, K4C, K4D } \
|
||||
}
|
||||
|
||||
#define LAYOUT_60_iso( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, \
|
||||
K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, \
|
||||
K40, K41, K42, K47, K4A, K4B, K4C, K4D \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, XXX }, \
|
||||
{ K30, K31, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, XXX }, \
|
||||
{ K40, K41, K42, XXX, XXX, XXX, XXX, K47, XXX, XXX, K4A, K4B, K4C, K4D } \
|
||||
}
|
||||
|
||||
#define LAYOUT_60_ansi_split_bs_rshift( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K2D, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
|
||||
K40, K41, K42, K47, K4A, K4B, K4C, K4D \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D }, \
|
||||
{ K30, XXX, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D }, \
|
||||
{ K40, K41, K42, XXX, XXX, XXX, XXX, K47, XXX, XXX, K4A, K4B, K4C, K4D } \
|
||||
}
|
||||
|
||||
#define LAYOUT_60_hhkb( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K2D, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, \
|
||||
K41, K42, K47, K4B, K4C \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D }, \
|
||||
{ K30, XXX, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D }, \
|
||||
{ XXX, K41, K42, XXX, XXX, XXX, XXX, K47, XXX, XXX, XXX, K4B, K4C, XXX } \
|
||||
}
|
||||
|
33
keyboards/zeal60/zeal60_api.h
Normal file
33
keyboards/zeal60/zeal60_api.h
Normal file
@ -0,0 +1,33 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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 PROTOCOL_VERSION 0x0007
|
||||
|
||||
enum zeal60_command_id
|
||||
{
|
||||
id_get_protocol_version = 0x01, // always 0x01
|
||||
id_get_keyboard_value,
|
||||
id_set_keyboard_value,
|
||||
id_dynamic_keymap_get_keycode,
|
||||
id_dynamic_keymap_set_keycode,
|
||||
id_dynamic_keymap_clear_all,
|
||||
id_backlight_config_set_value,
|
||||
id_backlight_config_get_value,
|
||||
id_backlight_config_save,
|
||||
|
||||
id_unhandled = 0xFF,
|
||||
};
|
42
keyboards/zeal60/zeal60_keycodes.h
Normal file
42
keyboards/zeal60/zeal60_keycodes.h
Normal file
@ -0,0 +1,42 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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
|
||||
|
||||
// Can't use SAFE_RANGE here, it might change if someone adds
|
||||
// new values to enum quantum_keycodes.
|
||||
// Need to keep checking 0x5F10 is still in the safe range.
|
||||
// TODO: merge this into quantum_keycodes
|
||||
// Backlight keycodes are in range 0x5F00-0x5F0F
|
||||
enum zeal60_keycodes {
|
||||
FN_MO13 = 0x5F10,
|
||||
FN_MO23
|
||||
};
|
||||
|
||||
// Zeal60 specific "action functions"
|
||||
// These are only valid IDs in action_function()
|
||||
// Use FN_TT13, FN_TT23, etc. in keymaps
|
||||
enum zeal60_action_functions {
|
||||
TRIPLE_TAP_1_3 = 0x31,
|
||||
TRIPLE_TAP_2_3 = 0x32
|
||||
};
|
||||
|
||||
// Bitwise OR the above with 0x0F00 to use in F(x) macro
|
||||
// This reserves the top 256 of the 4096 range of F(x) keycodes,
|
||||
// leaving the rest for use in fn_actions[] or actions in EEPROM.
|
||||
#define FN_TT13 F((0x0F00|TRIPLE_TAP_1_3))
|
||||
#define FN_TT23 F((0x0F00|TRIPLE_TAP_2_3))
|
||||
|
||||
#define TG_NKRO MAGIC_TOGGLE_NKRO
|
125
keyboards/zeal65/config.h
Normal file
125
keyboards/zeal65/config.h
Normal file
@ -0,0 +1,125 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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"
|
||||
|
||||
// USB Device descriptor parameter
|
||||
#define VENDOR_ID 0xFEED
|
||||
#define PRODUCT_ID 0x6065
|
||||
#define DEVICE_VER 0x0001
|
||||
#define MANUFACTURER ZealPC
|
||||
#define PRODUCT Zeal65
|
||||
#define DESCRIPTION Zeal65 (QMK Firmware)
|
||||
|
||||
// key matrix size
|
||||
#define MATRIX_ROWS 5
|
||||
#define MATRIX_COLS 15
|
||||
|
||||
// Zeal60 PCB default pin-out
|
||||
#define MATRIX_ROW_PINS { F0, F1, F4, F6, F7 }
|
||||
#define MATRIX_COL_PINS { F5, D5, B1, B2, B3, D3, D2, C7, C6, B6, B5, B4, D7, D6, D4 }
|
||||
#define UNUSED_PINS
|
||||
|
||||
// IS31FL3731 driver
|
||||
#define DRIVER_COUNT 2
|
||||
#define DRIVER_LED_TOTAL 72
|
||||
|
||||
// COL2ROW or ROW2COL
|
||||
#define DIODE_DIRECTION COL2ROW
|
||||
|
||||
// Set 0 if debouncing isn't needed
|
||||
#define DEBOUNCING_DELAY 5
|
||||
|
||||
// Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap
|
||||
#define LOCKING_SUPPORT_ENABLE
|
||||
// Locking resynchronize hack
|
||||
#define LOCKING_RESYNC_ENABLE
|
||||
|
||||
// key combination for command
|
||||
#define IS_COMMAND() ( \
|
||||
keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \
|
||||
)
|
||||
|
||||
/*
|
||||
* 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
|
||||
|
||||
#define RGB_BACKLIGHT_ENABLED 1
|
||||
|
||||
// This conditionally compiles the backlight code for Zeal65 specifics
|
||||
#define RGB_BACKLIGHT_ZEAL65
|
||||
|
||||
// enable/disable LEDs based on layout
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_LEFT_SHIFT 0
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_RIGHT_SHIFT 1
|
||||
#define RGB_BACKLIGHT_USE_7U_SPACEBAR 0
|
||||
#define RGB_BACKLIGHT_USE_ISO_ENTER 0
|
||||
#define RGB_BACKLIGHT_DISABLE_HHKB_BLOCKER_LEDS 0
|
||||
|
||||
// disable backlight when USB suspended (PC sleep/hibernate/shutdown)
|
||||
#define RGB_BACKLIGHT_DISABLE_WHEN_USB_SUSPENDED 0
|
||||
|
||||
// disable backlight after timeout in minutes, 0 = no timeout
|
||||
#define RGB_BACKLIGHT_DISABLE_AFTER_TIMEOUT 0
|
||||
|
||||
// the default effect (RGB test)
|
||||
#define RGB_BACKLIGHT_EFFECT 255
|
||||
|
||||
// These define which keys in the matrix are alphas/mods
|
||||
// Used for backlight effects so colors are different for
|
||||
// alphas vs. mods
|
||||
// Each value is for a row, bit 0 is column 0
|
||||
// Alpha=0 Mod=1
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_0 0b0110000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_1 0b0100000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_2 0b0101000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_3 0b0111000000000001
|
||||
#define RGB_BACKLIGHT_ALPHAS_MODS_ROW_4 0b0111110000000011
|
||||
|
||||
#define DYNAMIC_KEYMAP_LAYER_COUNT 4
|
||||
|
||||
// EEPROM usage
|
||||
|
||||
// TODO: refactor with new user EEPROM code (coming soon)
|
||||
#define EEPROM_MAGIC 0x451F
|
||||
#define EEPROM_MAGIC_ADDR 32
|
||||
// Bump this every time we change what we store
|
||||
// This will automatically reset the EEPROM with defaults
|
||||
// and avoid loading invalid data from the EEPROM
|
||||
#define EEPROM_VERSION 0x07
|
||||
#define EEPROM_VERSION_ADDR 34
|
||||
|
||||
// Backlight config starts after EEPROM version
|
||||
#define RGB_BACKLIGHT_CONFIG_EEPROM_ADDR 35
|
||||
// Dynamic keymap starts after backlight config (35+37)
|
||||
#define DYNAMIC_KEYMAP_EEPROM_ADDR 72
|
||||
|
16
keyboards/zeal65/info.json
Normal file
16
keyboards/zeal65/info.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"keyboard_name": "Zeal65",
|
||||
"url": "",
|
||||
"maintainer": "Wilba",
|
||||
"bootloader": "DFU",
|
||||
"width": 16,
|
||||
"height": 5,
|
||||
"layouts": {
|
||||
"LAYOUT_65_split_bs": {
|
||||
"layout": [{"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"|", "x":13, "y":0}, {"label":"Del", "x":14, "y":0}, {"label":"Home", "x":15, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"Backspace", "x":13.5, "y":1, "w":1.5}, {"label":"PgUp", "x":15, "y":1}, {"label":"Control", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"PgDn", "x":15, "y":2}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"label":"\u2191", "x":14, "y":3}, {"label":"End", "x":15, "y":3}, {"label":"Win", "x":0, "y":4, "w":1.5}, {"label":"Alt", "x":1.5, "y":4, "w":1.5}, {"x":3, "y":4, "w":7}, {"label":"Fn2", "x":10, "y":4, "w":1.5}, {"label":"Fn1", "x":11.5, "y":4, "w":1.5}, {"label":"\u2190", "x":13, "y":4}, {"label":"\u2193", "x":14, "y":4}, {"label":"\u2192", "x":15, "y":4}]
|
||||
},
|
||||
"LAYOUT_65_normie": {
|
||||
"layout": [{"label":"Esc", "x":0, "y":0}, {"label":"!", "x":1, "y":0}, {"label":"@", "x":2, "y":0}, {"label":"#", "x":3, "y":0}, {"label":"$", "x":4, "y":0}, {"label":"%", "x":5, "y":0}, {"label":"^", "x":6, "y":0}, {"label":"&", "x":7, "y":0}, {"label":"*", "x":8, "y":0}, {"label":"(", "x":9, "y":0}, {"label":")", "x":10, "y":0}, {"label":"_", "x":11, "y":0}, {"label":"+", "x":12, "y":0}, {"label":"Backspace", "x":13, "y":0, "w":2}, {"label":"Home", "x":15, "y":0}, {"label":"Tab", "x":0, "y":1, "w":1.5}, {"label":"Q", "x":1.5, "y":1}, {"label":"W", "x":2.5, "y":1}, {"label":"E", "x":3.5, "y":1}, {"label":"R", "x":4.5, "y":1}, {"label":"T", "x":5.5, "y":1}, {"label":"Y", "x":6.5, "y":1}, {"label":"U", "x":7.5, "y":1}, {"label":"I", "x":8.5, "y":1}, {"label":"O", "x":9.5, "y":1}, {"label":"P", "x":10.5, "y":1}, {"label":"{", "x":11.5, "y":1}, {"label":"}", "x":12.5, "y":1}, {"label":"|", "x":13.5, "y":1, "w":1.5}, {"label":"PgUp", "x":15, "y":1}, {"label":"Control", "x":0, "y":2, "w":1.75}, {"label":"A", "x":1.75, "y":2}, {"label":"S", "x":2.75, "y":2}, {"label":"D", "x":3.75, "y":2}, {"label":"F", "x":4.75, "y":2}, {"label":"G", "x":5.75, "y":2}, {"label":"H", "x":6.75, "y":2}, {"label":"J", "x":7.75, "y":2}, {"label":"K", "x":8.75, "y":2}, {"label":"L", "x":9.75, "y":2}, {"label":":", "x":10.75, "y":2}, {"label":"\"", "x":11.75, "y":2}, {"label":"Enter", "x":12.75, "y":2, "w":2.25}, {"label":"PgDn", "x":15, "y":2}, {"label":"Shift", "x":0, "y":3, "w":2.25}, {"label":"Z", "x":2.25, "y":3}, {"label":"X", "x":3.25, "y":3}, {"label":"C", "x":4.25, "y":3}, {"label":"V", "x":5.25, "y":3}, {"label":"B", "x":6.25, "y":3}, {"label":"N", "x":7.25, "y":3}, {"label":"M", "x":8.25, "y":3}, {"label":"<", "x":9.25, "y":3}, {"label":">", "x":10.25, "y":3}, {"label":"?", "x":11.25, "y":3}, {"label":"Shift", "x":12.25, "y":3, "w":1.75}, {"label":"\u2191", "x":14, "y":3}, {"label":"End", "x":15, "y":3}, {"label":"Win", "x":0, "y":4, "w":1.5}, {"label":"Alt", "x":1.5, "y":4, "w":1.5}, {"x":3, "y":4, "w":7}, {"label":"Fn2", "x":10, "y":4, "w":1.5}, {"label":"Fn1", "x":11.5, "y":4, "w":1.5}, {"label":"\u2190", "x":13, "y":4}, {"label":"\u2193", "x":14, "y":4}, {"label":"\u2192", "x":15, "y":4}]
|
||||
}
|
||||
}
|
||||
}
|
5
keyboards/zeal65/keymaps/default/config.h
Normal file
5
keyboards/zeal65/keymaps/default/config.h
Normal file
@ -0,0 +1,5 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 0
|
38
keyboards/zeal65/keymaps/default/keymap.c
Normal file
38
keyboards/zeal65/keymaps/default/keymap.c
Normal file
@ -0,0 +1,38 @@
|
||||
// Default layout for Zeal65
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_65_normie(
|
||||
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_HOME,
|
||||
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_PGUP,
|
||||
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_PGDN,
|
||||
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_END,
|
||||
KC_LCTL, KC_LALT, KC_SPC, FN_MO23, FN_MO13, KC_LEFT, KC_DOWN, KC_RGHT),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_65_normie(
|
||||
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_DEL, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_65_normie(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_65_normie(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
5
keyboards/zeal65/keymaps/split_bs/config.h
Normal file
5
keyboards/zeal65/keymaps/split_bs/config.h
Normal file
@ -0,0 +1,5 @@
|
||||
#pragma once
|
||||
|
||||
/* enable/disable LEDs based on layout */
|
||||
#undef RGB_BACKLIGHT_USE_SPLIT_BACKSPACE
|
||||
#define RGB_BACKLIGHT_USE_SPLIT_BACKSPACE 1
|
38
keyboards/zeal65/keymaps/split_bs/keymap.c
Normal file
38
keyboards/zeal65/keymaps/split_bs/keymap.c
Normal file
@ -0,0 +1,38 @@
|
||||
// Split-backspace layout for Zeal65
|
||||
#include QMK_KEYBOARD_H
|
||||
|
||||
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
|
||||
|
||||
// Default layer
|
||||
[0] = LAYOUT_65_split_bs(
|
||||
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_BSLS, KC_DEL, KC_HOME,
|
||||
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_BSPC, KC_PGUP,
|
||||
KC_LCTL, 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_PGDN,
|
||||
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_END,
|
||||
KC_LGUI, KC_LALT, KC_SPC, FN_MO23, FN_MO13, KC_LEFT, KC_DOWN, KC_RGHT),
|
||||
|
||||
// Fn1 Layer
|
||||
[1] = LAYOUT_65_split_bs(
|
||||
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_INS, KC_DEL, KC_TRNS,
|
||||
KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_PSCR, KC_SLCK, KC_PAUS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn2 Layer
|
||||
[2] = LAYOUT_65_split_bs(
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
// Fn3 Layer (zeal60 Configuration)
|
||||
[3] = LAYOUT_65_split_bs(
|
||||
KC_TRNS, EF_DEC, EF_INC, H1_DEC, H1_INC, H2_DEC, H2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, BR_DEC, BR_INC, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, S1_DEC, S1_INC, S2_DEC, S2_INC, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
|
||||
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
|
||||
|
||||
};
|
16
keyboards/zeal65/readme.md
Normal file
16
keyboards/zeal65/readme.md
Normal file
@ -0,0 +1,16 @@
|
||||
Zeal65
|
||||
====
|
||||
|
||||
![Zeal65](https://cdn.shopify.com/s/files/1/0490/7329/products/Zeal65_PCB2.jpg)
|
||||
|
||||
This is a 65% PCB with per-key RGB LEDs and supports fixed, 1800-like bottom row and split backspace. It was designed for the Zephyr custom keyboard.
|
||||
|
||||
Keyboard Maintainer: [Wilba](http://wilba.tech/) and on [github](https://github.com/Wilba6582)
|
||||
Hardware Supported: Zeal65 PCB Rev 1
|
||||
Hardware Availability: https://zealpc.net/collections/group-buy-pre-orders/products/zephyr
|
||||
|
||||
Make example for this keyboard (after setting up your build environment):
|
||||
|
||||
make zeal65: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).
|
79
keyboards/zeal65/rules.mk
Normal file
79
keyboards/zeal65/rules.mk
Normal file
@ -0,0 +1,79 @@
|
||||
|
||||
|
||||
# project specific files
|
||||
SRC = ../zeal60/zeal60.c \
|
||||
../zeal60/rgb_backlight.c \
|
||||
quantum/color.c \
|
||||
drivers/issi/is31fl3731.c \
|
||||
drivers/avr/i2c_master.c
|
||||
|
||||
# MCU name
|
||||
MCU = atmega32u4
|
||||
|
||||
# Processor frequency.
|
||||
# This will define a symbol, F_CPU, in all source code files equal to the
|
||||
# processor frequency in Hz. You can then use this symbol in your source code to
|
||||
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
|
||||
# automatically to create a 32-bit value in your source code.
|
||||
#
|
||||
# This will be an integer division of F_USB below, as it is sourced by
|
||||
# F_USB after it has run through any CPU prescalers. Note that this value
|
||||
# does not *change* the processor frequency - it should merely be updated to
|
||||
# reflect the processor speed set externally so that the code can use accurate
|
||||
# software delays.
|
||||
F_CPU = 16000000
|
||||
|
||||
#
|
||||
# LUFA specific
|
||||
#
|
||||
# Target architecture (see library "Board Types" documentation).
|
||||
ARCH = AVR8
|
||||
|
||||
# Input clock frequency.
|
||||
# This will define a symbol, F_USB, in all source code files equal to the
|
||||
# input clock frequency (before any prescaling is performed) in Hz. This value may
|
||||
# differ from F_CPU if prescaling is used on the latter, and is required as the
|
||||
# raw input clock is fed directly to the PLL sections of the AVR for high speed
|
||||
# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
|
||||
# at the end, this will be done automatically to create a 32-bit value in your
|
||||
# source code.
|
||||
#
|
||||
# If no clock division is performed on the input clock inside the AVR (via the
|
||||
# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
|
||||
F_USB = $(F_CPU)
|
||||
|
||||
# Interrupt driven control endpoint task(+60)
|
||||
OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
|
||||
|
||||
# Boot Section
|
||||
BOOTLOADER = atmel-dfu
|
||||
|
||||
# Do not put the microcontroller into power saving mode
|
||||
# when we get USB suspend event. We want it to keep updating
|
||||
# backlight effects.
|
||||
OPT_DEFS += -DNO_SUSPEND_POWER_DOWN
|
||||
|
||||
# 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(+1000)
|
||||
MOUSEKEY_ENABLE = no # Mouse keys(+4700)
|
||||
EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
|
||||
CONSOLE_ENABLE = no # Console for debug(+400)
|
||||
COMMAND_ENABLE = no # Commands for debug and configuration
|
||||
NKRO_ENABLE = yes # 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 = no # Enable WS2812 RGB underlight. Do not enable this with audio at the same time.
|
||||
|
||||
# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
|
||||
SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
|
||||
|
||||
RAW_ENABLE = yes
|
||||
DYNAMIC_KEYMAP_ENABLE = yes
|
||||
CIE1931_CURVE = yes
|
||||
|
18
keyboards/zeal65/zeal65.c
Normal file
18
keyboards/zeal65/zeal65.c
Normal file
@ -0,0 +1,18 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
#ifndef RGB_BACKLIGHT_ZEAL65
|
||||
#error RGB_BACKLIGHT_ZEAL65 not defined, you done goofed somehao, brah
|
||||
#endif
|
50
keyboards/zeal65/zeal65.h
Normal file
50
keyboards/zeal65/zeal65.h
Normal file
@ -0,0 +1,50 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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"
|
||||
#include "../zeal60/rgb_backlight_keycodes.h"
|
||||
#include "../zeal60/zeal60_keycodes.h"
|
||||
|
||||
#define XXX KC_NO
|
||||
|
||||
#define LAYOUT_65_split_bs( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K2D, K0E, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2E, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E, \
|
||||
K40, K41, K47, K4A, K4B, K4C, K4D, K4E \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2D, K2E }, \
|
||||
{ K30, XXX, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E }, \
|
||||
{ K40, K41, XXX, XXX, XXX, XXX, XXX, K47, XXX, XXX, K4A, K4B, K4C, K4D, K4E } \
|
||||
}
|
||||
|
||||
#define LAYOUT_65_normie( \
|
||||
K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E, \
|
||||
K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E, \
|
||||
K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, K2E, \
|
||||
K30, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E, \
|
||||
K40, K41, K47, K4A, K4B, K4C, K4D, K4E \
|
||||
) { \
|
||||
{ K00, K01, K02, K03, K04, K05, K06, K07, K08, K09, K0A, K0B, K0C, K0D, K0E }, \
|
||||
{ K10, K11, K12, K13, K14, K15, K16, K17, K18, K19, K1A, K1B, K1C, K1D, K1E }, \
|
||||
{ K20, K21, K22, K23, K24, K25, K26, K27, K28, K29, K2A, K2B, K2C, XXX, K2E }, \
|
||||
{ K30, XXX, K32, K33, K34, K35, K36, K37, K38, K39, K3A, K3B, K3C, K3D, K3E }, \
|
||||
{ K40, K41, XXX, XXX, XXX, XXX, XXX, K47, XXX, XXX, K4A, K4B, K4C, K4D, K4E } \
|
||||
}
|
97
quantum/dynamic_keymap.c
Normal file
97
quantum/dynamic_keymap.c
Normal file
@ -0,0 +1,97 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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 "config.h"
|
||||
#include "keymap.h" // to get keymaps[][][]
|
||||
|
||||
#include "dynamic_keymap.h"
|
||||
|
||||
#ifdef DYNAMIC_KEYMAP_ENABLE
|
||||
|
||||
#ifndef DYNAMIC_KEYMAP_EEPROM_ADDR
|
||||
#error DYNAMIC_KEYMAP_EEPROM_ADDR not defined
|
||||
#endif
|
||||
|
||||
#ifndef DYNAMIC_KEYMAP_LAYER_COUNT
|
||||
#error DYNAMIC_KEYMAP_LAYER_COUNT not defined
|
||||
#endif
|
||||
|
||||
#define KC_EENULL 0xFFFF // TODO: move to enum quantum_keycodes
|
||||
|
||||
void *dynamic_keymap_key_to_eeprom_address(uint8_t layer, uint8_t row, uint8_t column)
|
||||
{
|
||||
// TODO: optimize this with some left shifts
|
||||
return ((void*)DYNAMIC_KEYMAP_EEPROM_ADDR) + ( layer * MATRIX_ROWS * MATRIX_COLS * 2 ) +
|
||||
( row * MATRIX_COLS * 2 ) + ( column * 2 );
|
||||
}
|
||||
|
||||
uint16_t dynamic_keymap_get_keycode(uint8_t layer, uint8_t row, uint8_t column)
|
||||
{
|
||||
void *address = dynamic_keymap_key_to_eeprom_address(layer, row, column);
|
||||
// Big endian, so we can read/write EEPROM directly from host if we want
|
||||
uint16_t keycode = eeprom_read_byte(address) << 8;
|
||||
keycode |= eeprom_read_byte(address + 1);
|
||||
return keycode;
|
||||
}
|
||||
|
||||
void dynamic_keymap_set_keycode(uint8_t layer, uint8_t row, uint8_t column, uint16_t keycode)
|
||||
{
|
||||
void *address = dynamic_keymap_key_to_eeprom_address(layer, row, column);
|
||||
// Big endian, so we can read/write EEPROM directly from host if we want
|
||||
eeprom_update_byte(address, (uint8_t)(keycode >> 8));
|
||||
eeprom_update_byte(address+1, (uint8_t)(keycode & 0xFF));
|
||||
}
|
||||
|
||||
void dynamic_keymap_clear_all(void)
|
||||
{
|
||||
// Save "empty" keymaps.
|
||||
for ( int layer = 0; layer < DYNAMIC_KEYMAP_LAYER_COUNT; layer++ )
|
||||
{
|
||||
for ( int row = 0; row < MATRIX_ROWS; row++ )
|
||||
{
|
||||
for ( int column = 0; column < MATRIX_COLS; column++ )
|
||||
{
|
||||
dynamic_keymap_set_keycode(layer, row, column, KC_EENULL);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// This overrides the one in quantum/keymap_common.c
|
||||
uint16_t keymap_key_to_keycode(uint8_t layer, keypos_t key)
|
||||
{
|
||||
// This used to test EEPROM for magic bytes, but it was redundant.
|
||||
// Test for EEPROM usage change (fresh install, address change, etc.)
|
||||
// externally and call dynamic_keymap_default_save()
|
||||
if ( layer < DYNAMIC_KEYMAP_LAYER_COUNT &&
|
||||
key.row < MATRIX_ROWS && // possibly redundant
|
||||
key.col < MATRIX_COLS ) // possibly redundant
|
||||
{
|
||||
uint16_t keycode = dynamic_keymap_get_keycode(layer, key.row, key.col);
|
||||
|
||||
// If keycode is not "empty", return it, otherwise
|
||||
// drop down to return the one in flash
|
||||
if ( keycode != KC_EENULL)
|
||||
{
|
||||
return keycode;
|
||||
}
|
||||
}
|
||||
|
||||
return pgm_read_word(&keymaps[layer][key.row][key.col]);
|
||||
}
|
||||
|
||||
#endif // DYNAMIC_KEYMAP_ENABLE
|
||||
|
31
quantum/dynamic_keymap.h
Normal file
31
quantum/dynamic_keymap.h
Normal file
@ -0,0 +1,31 @@
|
||||
/* Copyright 2017 Jason Williams (Wilba)
|
||||
*
|
||||
* 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/>.
|
||||
*/
|
||||
|
||||
#ifndef DYNAMIC_KEYMAP_H
|
||||
#define DYNAMIC_KEYMAP_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
void *dynamic_keymap_key_to_eeprom_address(uint8_t layer, uint8_t row, uint8_t column);
|
||||
uint16_t dynamic_keymap_get_keycode(uint8_t layer, uint8_t row, uint8_t column);
|
||||
void dynamic_keymap_set_keycode(uint8_t layer, uint8_t row, uint8_t column, uint16_t keycode);
|
||||
void dynamic_keymap_clear_all(void);
|
||||
|
||||
// This overrides the one in quantum/keymap_common.c
|
||||
// uint16_t keymap_key_to_keycode(uint8_t layer, keypos_t key);
|
||||
|
||||
#endif //DYNAMIC_KEYMAP_H
|
@ -56,6 +56,24 @@ void suspend_idle(uint8_t time)
|
||||
sleep_disable();
|
||||
}
|
||||
|
||||
|
||||
// TODO: This needs some cleanup
|
||||
|
||||
/** \brief Run keyboard level Power down
|
||||
*
|
||||
* FIXME: needs doc
|
||||
*/
|
||||
__attribute__ ((weak))
|
||||
void suspend_power_down_user (void) { }
|
||||
/** \brief Run keyboard level Power down
|
||||
*
|
||||
* FIXME: needs doc
|
||||
*/
|
||||
__attribute__ ((weak))
|
||||
void suspend_power_down_kb(void) {
|
||||
suspend_power_down_user();
|
||||
}
|
||||
|
||||
#ifndef NO_SUSPEND_POWER_DOWN
|
||||
/** \brief Power down MCU with watchdog timer
|
||||
*
|
||||
@ -73,21 +91,6 @@ void suspend_idle(uint8_t time)
|
||||
*/
|
||||
static uint8_t wdt_timeout = 0;
|
||||
|
||||
/** \brief Run keyboard level Power down
|
||||
*
|
||||
* FIXME: needs doc
|
||||
*/
|
||||
__attribute__ ((weak))
|
||||
void suspend_power_down_user (void) { }
|
||||
/** \brief Run keyboard level Power down
|
||||
*
|
||||
* FIXME: needs doc
|
||||
*/
|
||||
__attribute__ ((weak))
|
||||
void suspend_power_down_kb(void) {
|
||||
suspend_power_down_user();
|
||||
}
|
||||
|
||||
/** \brief Power down
|
||||
*
|
||||
* FIXME: needs doc
|
||||
@ -144,6 +147,8 @@ static void power_down(uint8_t wdto)
|
||||
*/
|
||||
void suspend_power_down(void)
|
||||
{
|
||||
suspend_power_down_kb();
|
||||
|
||||
#ifndef NO_SUSPEND_POWER_DOWN
|
||||
power_down(WDTO_15MS);
|
||||
#endif
|
||||
@ -198,7 +203,7 @@ void suspend_wakeup_init(void)
|
||||
rgblight_timer_enable();
|
||||
#endif
|
||||
#endif
|
||||
suspend_wakeup_init_kb();
|
||||
suspend_wakeup_init_kb();
|
||||
}
|
||||
|
||||
#ifndef NO_SUSPEND_POWER_DOWN
|
||||
|
Loading…
Reference in New Issue
Block a user