Skip to content

Commit

Permalink
Add personal keymap + halcyon display
Browse files Browse the repository at this point in the history
  • Loading branch information
VeyPatch committed Dec 15, 2024
1 parent 35edec2 commit 6953a5a
Show file tree
Hide file tree
Showing 38 changed files with 6,101 additions and 2 deletions.
18 changes: 18 additions & 0 deletions keyboards/splitkb/halcyon/kyria/rev4/keymaps/veypatch/config.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#pragma once

// LCD Configuration
#define LCD_RST_PIN GP26
#define LCD_CS_PIN GP13
#define LCD_DC_PIN GP16
#define LCD_SPI_DIVISOR 0
#define LCD_SPI_MODE 3
#define LCD_WAIT_TIME 150

// Backlight configuration
#define BACKLIGHT_PIN GP27

// Backlight
#define BACKLIGHT_PWM_DRIVER PWMD5
#define BACKLIGHT_LEVELS 10
#define BACKLIGHT_PWM_CHANNEL RP2040_PWM_CHANNEL_B

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#pragma once

#define HAL_USE_PWM TRUE

#include_next <halconf.h>
206 changes: 206 additions & 0 deletions keyboards/splitkb/halcyon/kyria/rev4/keymaps/veypatch/keymap.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
// Copyright 2024 VeyPatch
// SPDX-License-Identifier: GPL-2.0-or-later

#include QMK_KEYBOARD_H

enum layers {
_QWERTY = 0,
_DVORAK,
_COLEMAK_DH,
_NAV,
_SYM,
_FUNCTION,
_ADJUST,
};


// Aliases for readability
#define QWERTY DF(_QWERTY)
#define COLEMAK DF(_COLEMAK_DH)
#define DVORAK DF(_DVORAK)

#define SYM MO(_SYM)
#define NAV MO(_NAV)
#define FKEYS MO(_FUNCTION)
#define ADJUST MO(_ADJUST)

#define CTL_ESC MT(MOD_LCTL, KC_ESC)
#define CTL_QUOT MT(MOD_RCTL, KC_QUOTE)
#define CTL_MINS MT(MOD_RCTL, KC_MINUS)
#define ALT_ENT MT(MOD_LALT, KC_ENT)

// Note: LAlt/Enter (ALT_ENT) is not the same thing as the keyboard shortcut Alt+Enter.
// The notation `mod/tap` denotes a key that activates the modifier `mod` when held down, and
// produces the key `tap` when tapped (i.e. pressed and released).

// clang-format off
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
/*
* Base Layer: QWERTY
*
* ,-------------------------------------------. ,-------------------------------------------.
* | Esc | Q | W | E | R | T | | Y | U | I | O | P | Bksp |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* | LShift | A | S | D | F | G | | H | J | K | L | ; : | ' " |
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | LCtrl | Z | X | C | V | B | F23 |CapsLk| | F22 | F24 | N | M | , < | . > | / ? | Prtscr |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* | LGUI | DEL | LAlt |LShift|LT(3)/| |LT(4)/| Space| Bksp | RGUI | Menu |
* | | | | |Enter | | Tab | | | | |
* `----------------------------------' `----------------------------------'
*/
[_QWERTY] = LAYOUT(
KC_ESC , KC_Q , KC_W , KC_E , KC_R , KC_T , KC_Y, KC_U , KC_I , KC_O , KC_P , KC_BSPC,
KC_LSFT , KC_A , KC_S , KC_D , KC_F , KC_G , KC_H, KC_J , KC_K , KC_L ,KC_SCLN,KC_QUOTE,
KC_LCTL , KC_Z , KC_X , KC_C , KC_V , KC_B , KC_F23 ,KC_CAPS , KC_F22 , KC_F24 ,KC_N, KC_M ,KC_COMM, KC_DOT ,KC_SLSH, KC_PSCR,
KC_LGUI, KC_DEL , KC_LALT, KC_LSFT,LT(3, KC_ENTER), LT(4, KC_TAB) , KC_SPC ,KC_BSPC, KC_RGUI, KC_APP
),

/*
* Base Layer: Dvorak
*
* ,-------------------------------------------. ,-------------------------------------------.
* | Tab | ' " | , < | . > | P | Y | | F | G | C | R | L | Bksp |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* |Ctrl/Esc| A | O | E | U | I | | D | H | T | N | S |Ctrl/- _|
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | LShift | ; : | Q | J | K | X | [ { |CapsLk| |F-keys| ] } | B | M | W | V | Z | RShift |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* |Adjust| LGUI | LAlt/| Space| Nav | | Sym | Space| AltGr| RGUI | Menu |
* | | | Enter| | | | | | | | |
* `----------------------------------' `----------------------------------'
*/
[_DVORAK] = LAYOUT(
KC_TAB ,KC_QUOTE,KC_COMM, KC_DOT, KC_P , KC_Y , KC_F, KC_G , KC_C , KC_R , KC_L , KC_BSPC,
CTL_ESC , KC_A , KC_O , KC_E , KC_U , KC_I , KC_D, KC_H , KC_T , KC_N , KC_S , CTL_MINS,
KC_LSFT ,KC_SCLN, KC_Q , KC_J , KC_K , KC_X , KC_LBRC,KC_CAPS, FKEYS , KC_RBRC, KC_B, KC_M , KC_W , KC_V , KC_Z , KC_RSFT,
ADJUST, KC_LGUI, ALT_ENT, KC_SPC , NAV , SYM , KC_SPC ,KC_RALT, KC_RGUI, KC_APP
),

/*
* Base Layer: Colemak DH
*
* ,-------------------------------------------. ,-------------------------------------------.
* | Tab | Q | W | F | P | B | | J | L | U | Y | ; : | Bksp |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* |Ctrl/Esc| A | R | S | T | G | | M | N | E | I | O |Ctrl/' "|
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | LShift | Z | X | C | D | V | [ { |CapsLk| |F-keys| ] } | K | H | , < | . > | / ? | RShift |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* |Adjust| LGUI | LAlt/| Space| Nav | | Sym | Space| AltGr| RGUI | Menu |
* | | | Enter| | | | | | | | |
* `----------------------------------' `----------------------------------'
*/
[_COLEMAK_DH] = LAYOUT(
KC_TAB , KC_Q , KC_W , KC_F , KC_P , KC_B , KC_J, KC_L , KC_U , KC_Y ,KC_SCLN, KC_BSPC,
CTL_ESC , KC_A , KC_R , KC_S , KC_T , KC_G , KC_M, KC_N , KC_E , KC_I , KC_O , CTL_QUOT,
KC_LSFT , KC_Z , KC_X , KC_C , KC_D , KC_V , KC_LBRC,KC_CAPS, FKEYS , KC_RBRC, KC_K, KC_H ,KC_COMM, KC_DOT ,KC_SLSH, KC_RSFT,
ADJUST, KC_LGUI, ALT_ENT, KC_SPC , NAV , SYM , KC_SPC ,KC_RALT, KC_RGUI, KC_APP
),

/*
* Nav Layer: Media, navigation
*
* ,-------------------------------------------. ,-------------------------------------------.
* | | ! | @ | { | } | | | | | | | \ | | |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* | | # | $ | ( | ) | ` | | + | - | / | * | | |
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | | % | ^ | [ | ] | ~ | | | | | | & | = | | | | |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* | | | | | | | | | | | |
* | | | | | | | MO(5)| | | | |
* `----------------------------------' `----------------------------------'
*/
[_NAV] = LAYOUT(
_______, LSFT(KC_1), LSFT(KC_2), LSFT(KC_LBRC), LSFT(KC_RBRC), LSFT(KC_BSLS), _______ , _______, _______, KC_BSLS , _______, _______,
_______, LSFT(KC_3), LSFT(KC_4), LSFT(KC_9) , LSFT(KC_0) , KC_GRV , LSFT(KC_EQL), KC_MINS, KC_SLSH, LSFT(KC_8), _______, _______,
_______, LSFT(KC_5), LSFT(KC_6), KC_LBRC , KC_RBRC , LSFT(KC_GRV) , _______, _______, _______, _______, LSFT(KC_7) , KC_EQL , _______, _______ , _______, _______,
_______ , _______ , _______ , _______, _______, MO(5) , _______, _______ , _______, _______
),

/*
* Sym Layer: Numbers and symbols
*
* ,-------------------------------------------. ,-------------------------------------------.
* | | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* | | | @ | # | $ | % | | left | down | up | right| | |
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | | | | | | | | | | | | | left | down | right| | |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* | | | | | | | | | | | |
* | | | | | MO(5)| | | | | | |
* `----------------------------------' `----------------------------------'
*/
[_SYM] = LAYOUT(
_______, KC_1 , KC_2 , KC_3 , KC_4 , KC_5 , KC_6 , KC_7 , KC_8 , KC_9 , KC_0 , _______,
_______, _______, KC_MPRV, KC_MPLY, KC_MNXT, KC_VOLU, KC_LEFT, KC_DOWN, KC_UP , KC_RGHT, _______, _______,
_______, _______, _______, _______, KC_MUTE, KC_VOLD, _______, _______, _______, _______, _______, KC_LEFT, KC_DOWN, KC_RGHT, _______, _______,
_______, _______, _______, _______, MO(5) , _______, _______, _______, _______, _______
),

/*
* Function Layer: Function keys
*
* ,-------------------------------------------. ,-------------------------------------------.
* | | F1 | F2 | F3 | F4 | | | NUMLK| 7 | 8 | 9 | + | - |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* | | F5 | F6 | F7 | F8 | | | | 4 | 5 | 6 | = | * |
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | | F9 | F10 | F11 | F12 | | | | | | | | 1 | 2 | 3 | Enter| / |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* | | | | | | | | | | | |
* | | | | | | | | | | 0 | . |
* `----------------------------------' `----------------------------------'
*/
[_FUNCTION] = LAYOUT(
_______, KC_F1 , KC_F2 , KC_F3 , KC_F4 , _______, KC_NUM , KC_P7, KC_P8, KC_P9, KC_PPLS, KC_PMNS,
_______, KC_F5 , KC_F6 , KC_F7 , KC_F8 , _______, _______, KC_P4, KC_P5, KC_P6, KC_PEQL, KC_PAST,
_______, KC_F9 , KC_F10, KC_F11, KC_F12, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, KC_PENT, KC_PSLS,
_______, _______, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT
),

/*
* Adjust Layer: Default layer settings, RGB
*
* ,-------------------------------------------. ,-------------------------------------------.
* | | | |QWERTY| | | | | | | | | |
* |--------+------+------+------+------+------| |------+------+------+------+------+--------|
* | | | |Dvorak| | | | TOGG | SATU | HUEU | VALU | NEXT | SPDU |
* |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
* | | | |Colmak| | | | | | | | | SATD | HUED | VALD | PREV | SPDD |
* `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
* | | | | | | | | | | | |
* | | | | | | | | | | | |
* `----------------------------------' `----------------------------------'
*/
[_ADJUST] = LAYOUT(
_______, _______, _______, QWERTY , _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, DVORAK , _______, _______, RM_TOGG, RM_SATU, RM_HUEU, RM_VALU, RM_NEXT, RM_SPDU,
_______, _______, _______, COLEMAK, _______, _______,_______, _______, _______, _______, _______, RM_SATD, RM_HUED, RM_VALD, RM_PREV, RM_SPDD,
_______, _______, _______,_______, _______, _______, _______, _______, _______, _______
),

// /*
// * Layer template
// *
// * ,-------------------------------------------. ,-------------------------------------------.
// * | | | | | | | | | | | | | |
// * |--------+------+------+------+------+------| |------+------+------+------+------+--------|
// * | | | | | | | | | | | | | |
// * |--------+------+------+------+------+------+-------------. ,-------------+------+------+------+------+------+--------|
// * | | | | | | | | | | | | | | | | | |
// * `----------------------+------+------+------+------+------| |------+------+------+------+------+----------------------'
// * | | | | | | | | | | | |
// * | | | | | | | | | | | |
// * `----------------------------------' `----------------------------------'
// */
// [_LAYERINDEX] = LAYOUT(
// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
// _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
// ),
//
};
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#pragma once

#include_next <mcuconf.h>

#undef RP_PWM_USE_PWM5
#define RP_PWM_USE_PWM5 TRUE
Loading

0 comments on commit 6953a5a

Please sign in to comment.