aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleblazer <60912320+Aleblazer@users.noreply.github.com>2021-03-06 12:56:48 -0600
committerGitHub <noreply@github.com>2021-03-06 18:56:48 +0000
commit86e28b4db84223152d959288f17e5bcfc5960e75 (patch)
treeead8a074100d7e5decf13954c3eff312cfe5489f
parent9c94de070a651c477ed8d65228af4255a35ea6aa (diff)
downloadqmk_firmware-86e28b4db84223152d959288f17e5bcfc5960e75.tar.gz
qmk_firmware-86e28b4db84223152d959288f17e5bcfc5960e75.zip
Adding Zodiark Split keyboard (#11837)
* Adding Files for Zodiark * zodiark.h and keymap.c layout corrections * Apply suggestions from code review Applied all suggestions from zvecr. Co-authored-by: Joel Challis <git@zvecr.com> * Applied all suggestions from fauxpark Co-authored-by: Ryan <fauxpark@gmail.com> * Defined matrix driver * Update keymap with GPL2 * Added GPL2+ to All keymap.c, cleaned up config.h, and removed the rgbmatrixwip keymap * Apply suggestions from code review Removed the two lines from the config.h and changed to the smaller resolution picture on the Readme. Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com> * Added VIA keymap * Corrected VIA Keymap oled.c Co-authored-by: Joel Challis <git@zvecr.com> Co-authored-by: Ryan <fauxpark@gmail.com> Co-authored-by: Drashna Jaelre <drashna@live.com>
-rw-r--r--keyboards/aleblazer/zodiark/config.h75
-rw-r--r--keyboards/aleblazer/zodiark/info.json12
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/default/config.h22
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/default/keymap.c327
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/default/rules.mk1
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/slimoled/config.h22
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/slimoled/keymap.c330
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/slimoled/rules.mk1
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/via/config.h22
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/via/encoder.c35
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/via/keymap.c52
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/via/oled.c78
-rw-r--r--keyboards/aleblazer/zodiark/keymaps/via/rules.mk2
-rw-r--r--keyboards/aleblazer/zodiark/readme.md23
-rw-r--r--keyboards/aleblazer/zodiark/rules.mk27
-rw-r--r--keyboards/aleblazer/zodiark/zodiark.c54
-rw-r--r--keyboards/aleblazer/zodiark/zodiark.h38
17 files changed, 1121 insertions, 0 deletions
diff --git a/keyboards/aleblazer/zodiark/config.h b/keyboards/aleblazer/zodiark/config.h
new file mode 100644
index 000000000..84795f024
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/config.h
@@ -0,0 +1,75 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#pragma once
18
19#include "config_common.h"
20
21/* USB Device descriptor parameter */
22#define VENDOR_ID 0xF901
23#define PRODUCT_ID 0xF902
24#define DEVICE_VER 0x0001
25#define MANUFACTURER Aleblazer
26#define PRODUCT Zodiark
27
28#define NO_ACTION_MACRO
29
30#define SOFT_SERIAL_PIN D3
31#define SERIAL_USE_MULTI_TRANSACTION
32#define SELECT_SOFT_SERIAL_SPEED 1
33
34/* key matrix size */
35#define MATRIX_ROWS 10
36#define MATRIX_COLS 7
37#define DIODE_DIRECTION COL2ROW
38
39#define ENCODERS_PAD_A { D2 }
40#define ENCODERS_PAD_B { D4 }
41#define ENCODERS_PAD_A_RIGHT { D4 }
42#define ENCODERS_PAD_B_RIGHT { D2 }
43#define ENCODER_RESOLUTION 3
44
45/* key matrix pins */
46#define MATRIX_ROW_PINS { C6, D7, E6, B4, F4 }
47#define MATRIX_COL_PINS { F5, F6, F7, B1, B3, B2, B6 }
48
49/* Set 0 if debouncing isn't needed */
50#define DEBOUNCE 5
51
52#define RGB_DI_PIN B5
53
54#ifdef RGBLIGHT_ENABLE
55#define RGBLED_NUM 68
56#define RGBLIGHT_SPLIT
57#define RGBLED_SPLIT { 34, 34 }
58#define RGBLIGHT_LIMIT_VAL 170
59#define RGBLIGHT_ANIMATIONS
60#define RGBLIGHT_HUE_STEP 8
61#define RGBLIGHT_SAT_STEP 8
62#define RGBLIGHT_VAL_STEP 8
63#endif
64
65#ifdef RGB_MATRIX_ENABLE
66#define DRIVER_LED_TOTAL 68
67#define RGB_MATRIX_SPLIT { 34, 34 }
68#define RGB_MATRIX_MAXIMUM_BRIGHTNESS 150 // limits maximum brightness of LEDs to 150 out of 255. Higher may cause the controller to crash.
69#define RGB_MATRIX_KEYPRESSES
70#define RGB_MATRIX_FRAMEBUFFER_EFFECTS
71#define RGB_MATRIX_HUE_STEP 8
72#define RGB_MATRIX_SAT_STEP 8
73#define RGB_MATRIX_VAL_STEP 8
74#define RGB_MATRIX_SPD_STEP 10
75#endif
diff --git a/keyboards/aleblazer/zodiark/info.json b/keyboards/aleblazer/zodiark/info.json
new file mode 100644
index 000000000..e0acaaa46
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/info.json
@@ -0,0 +1,12 @@
1{
2 "keyboard_name": "zodiark",
3 "url": "https://github.com/Aleblazer/qmk_firmware/tree/master/keyboards/zodiark",
4 "maintainer": "Aleblazer",
5 "width": 19,
6 "height": 8.48,
7 "layouts": {
8 "LAYOUT": {
9 "layout": [{"label":"L03", "x":3, "y":0}, {"label":"R03", "x":15, "y":0}, {"label":"L02", "x":2, "y":0.125}, {"label":"L04", "x":4, "y":0.125}, {"label":"R02", "x":14, "y":0.125}, {"label":"R04", "x":16, "y":0.125}, {"label":"L05", "x":5, "y":0.25}, {"label":"R01", "x":13, "y":0.25}, {"label":"L00", "x":0, "y":0.53}, {"label":"L01", "x":1, "y":0.53}, {"label":"R05", "x":17, "y":0.53}, {"label":"R06", "x":18, "y":0.53}, {"label":"L13", "x":3, "y":1}, {"label":"R13", "x":15, "y":1}, {"label":"L12", "x":2, "y":1.125}, {"label":"L14", "x":4, "y":1.125}, {"label":"R12", "x":14, "y":1.125}, {"label":"R14", "x":16, "y":1.125}, {"label":"L15", "x":5, "y":1.25}, {"label":"R11", "x":13, "y":1.25}, {"label":"L10", "x":0, "y":1.53}, {"label":"L11", "x":1, "y":1.53}, {"label":"R15", "x":17, "y":1.53}, {"label":"R16", "x":18, "y":1.53}, {"label":"L06", "x":6, "y":1.7000000000000002}, {"label":"R00", "x":12, "y":1.7000000000000002}, {"label":"L23", "x":3, "y":2.0}, {"label":"R23", "x":15, "y":2.0}, {"label":"L22", "x":2, "y":2.125}, {"label":"L24", "x":4, "y":2.125}, {"label":"R22", "x":14, "y":2.125}, {"label":"R24", "x":16, "y":2.125}, {"label":"L25", "x":5, "y":2.25}, {"label":"R21", "x":13, "y":2.25}, {"label":"L20", "x":0, "y":2.5300000000000002}, {"label":"L21", "x":1, "y":2.5300000000000002}, {"label":"R25", "x":17, "y":2.5300000000000002}, {"label":"R26", "x":18, "y":2.5300000000000002}, {"label":"L16", "x":6, "y":2.7}, {"label":"R10", "x":12, "y":2.7}, {"label":"L33", "x":3, "y":3.0000000000000004}, {"label":"R33", "x":15, "y":3.0000000000000004}, {"label":"L32", "x":2, "y":3.1250000000000004}, {"label":"L34", "x":4, "y":3.1250000000000004}, {"label":"R32", "x":14, "y":3.1250000000000004}, {"label":"R34", "x":16, "y":3.1250000000000004}, {"label":"L35", "x":5, "y":3.2500000000000004}, {"label":"R31", "x":13, "y":3.2500000000000004}, {"label":"L30", "x":0, "y":3.5300000000000002}, {"label":"L31", "x":1, "y":3.5300000000000002}, {"label":"R35", "x":17, "y":3.5300000000000002}, {"label":"R36", "x":18, "y":3.5300000000000002}, {"label":"L43", "x":3, "y":4.0}, {"label":"R43", "x":15, "y":4.0}, {"label":"L42", "x":2, "y":4.125}, {"label":"R44", "x":16, "y":4.125}, {"label":"L44", "x":4, "y":4.13}, {"label":"R42", "x":14, "y":4.13}, {"label":"L40", "x":0, "y":4.53}, {"label":"L41", "x":1, "y":4.53}, {"label":"R45", "x":17, "y":4.53}, {"label":"R46", "x":18, "y":4.53}, {"label":"L26", "x":-0.33, "y":5.13}, {"label":"L36", "x":0.6699999999999999, "y":5.13}, {"label":"L45", "x":-0.83, "y":6.13, "w":1.5}, {"label":"L46", "x":0.67, "y":6.13}, {"label":"R30", "x":-2.1, "y":6.48}, {"label":"R20", "x":-1.1, "y":6.48}, {"label":"R40", "x":-2.1, "y":7.48}, {"label":"R41", "x":-1.1, "y":7.48, "w":1.5}]
10 }
11 }
12}
diff --git a/keyboards/aleblazer/zodiark/keymaps/default/config.h b/keyboards/aleblazer/zodiark/keymaps/default/config.h
new file mode 100644
index 000000000..0c89f634b
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/default/config.h
@@ -0,0 +1,22 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#pragma once
18
19#ifdef OLED_DRIVER_ENABLE
20 #define OLED_DISPLAY_128X64
21 #define OLED_TIMEOUT 400000
22#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/default/keymap.c b/keyboards/aleblazer/zodiark/keymaps/default/keymap.c
new file mode 100644
index 000000000..0692aee12
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/default/keymap.c
@@ -0,0 +1,327 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3This program is free software: you can redistribute it and/or modify
4it under the terms of the GNU General Public License as published by
5the Free Software Foundation, either version 3 of the License, or
6(at your option) any later version.
7This program is distributed in the hope that it will be useful,
8but WITHOUT ANY WARRANTY; without even the implied warranty of
9MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10GNU General Public License for more details.
11You should have received a copy of the GNU General Public License
12along with this program. If not, see <http://www.gnu.org/licenses/>.
13*/
14#include QMK_KEYBOARD_H
15
16enum sofle_layers {
17 /* _M_XYZ = Mac Os, _W_XYZ = Win/Linux */
18 _QWERTY,
19 _COLEMAK,
20 _LOWER,
21 _RAISE,
22 _ADJUST,
23};
24
25enum custom_keycodes {
26 KC_QWERTY = SAFE_RANGE,
27 KC_COLEMAK,
28 KC_LOWER,
29 KC_RAISE,
30 KC_ADJUST,
31 KC_PRVWD,
32 KC_NXTWD,
33 KC_LSTRT,
34 KC_LEND,
35 KC_DLINE
36};
37
38const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
39
40 [_QWERTY] = LAYOUT(
41 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
42 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_LBRC, KC_RBRC, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
43 KC_ADJUST, KC_A, KC_S, KC_D, KC_F, KC_G, KC_MINS, KC_EQL, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
44 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_GRV, KC_MUTE, RGB_TOG, KC_DEL,KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT ,
45 KC_LCTL, KC_LALT, KC_LGUI, LALT(KC_TAB), KC_LOWER, KC_SPC, KC_ENT, KC_ENT, KC_SPC, KC_RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
46 ),
47
48 [_LOWER] = LAYOUT(
49 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
50 KC_PSLS, KC_P7, KC_P8, KC_P9, KC_NLCK, _______, _______, _______, _______, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_F12,
51 KC_CAPS, KC_P4, KC_P5, KC_P6, KC_NLCK, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_NLCK,
52 _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______,
53 _______, KC_P0, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT, KC_PENT, _______
54 ),
55
56 [_RAISE] = LAYOUT(
57 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
58 KC_PSLS, KC_P7, KC_P8, KC_P9, KC_NLCK, _______, _______, _______, _______, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_F12,
59 KC_CAPS, KC_P4, KC_P5, KC_P6, KC_NLCK, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_NLCK,
60 _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______,
61 _______, KC_P0, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT, KC_PENT, _______
62 ),
63
64 [_ADJUST] = LAYOUT(
65 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
66 _______, _______, _______, _______, _______, _______, _______, _______, _______, EEP_RST, _______, _______, _______, KC_F12,
67 _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_TOG, _______, _______, _______, _______,
68 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_MOD, RGB_SPI, RGB_HUI, RGB_SAI, RGB_VAI,
69 _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_SPD, RGB_HUD, RGB_SAD, RGB_VAD
70 )
71
72};
73#ifdef OLED_DRIVER_ENABLE
74
75static void render_logo(void) {
76 static const char PROGMEM qmk_logo[] = {
77 0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,0x92,0x93,0x94,
78 0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,0xb0,0xb1,0xb2,0xb3,0xb4,
79 0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xd0,0xd1,0xd2,0xd3,0xd4,0
80 };
81
82 oled_write_P(qmk_logo, false);
83}
84
85static void print_status_narrow(void) {
86 // Print current mode
87 oled_write_P(PSTR("\n\n"), false);
88 oled_write_ln_P(PSTR("MODE"), false);
89 oled_write_ln_P(PSTR(""), false);
90 if (keymap_config.swap_lctl_lgui) {
91 oled_write_ln_P(PSTR("MAC"), false);
92 } else {
93 oled_write_ln_P(PSTR("WIN"), false);
94 }
95
96 switch (get_highest_layer(default_layer_state)) {
97 case _QWERTY:
98 oled_write_ln_P(PSTR("Qwrt"), false);
99 break;
100 case _COLEMAK:
101 oled_write_ln_P(PSTR("Clmk"), false);
102 break;
103 default:
104 oled_write_P(PSTR("Undef"), false);
105 }
106 oled_write_P(PSTR("\n\n"), false);
107 // Print current layer
108 oled_write_ln_P(PSTR("LAYER"), false);
109 switch (get_highest_layer(layer_state)) {
110 case _COLEMAK:
111 case _QWERTY:
112 oled_write_P(PSTR("Base\n"), false);
113 break;
114 case _RAISE:
115 oled_write_P(PSTR("Raise"), false);
116 break;
117 case _LOWER:
118 oled_write_P(PSTR("Lower"), false);
119 break;
120 case _ADJUST:
121 oled_write_P(PSTR("Adj\n"), false);
122 break;
123 default:
124 oled_write_ln_P(PSTR("Undef"), false);
125 }
126 oled_write_P(PSTR("\n\n"), false);
127 led_t led_usb_state = host_keyboard_led_state();
128 oled_write_ln_P(PSTR("CPSLK"), led_usb_state.caps_lock);
129}
130
131oled_rotation_t oled_init_user(oled_rotation_t rotation) {
132 if (is_keyboard_master()) {
133 return OLED_ROTATION_90;
134 }
135 return rotation;
136}
137
138void oled_task_user(void) {
139 if (is_keyboard_master()) {
140 print_status_narrow();
141 } else {
142 render_logo();
143 }
144}
145
146#endif
147
148bool process_record_user(uint16_t keycode, keyrecord_t *record) {
149 switch (keycode) {
150 case KC_QWERTY:
151 if (record->event.pressed) {
152 set_single_persistent_default_layer(_QWERTY);
153 }
154 return false;
155 case KC_COLEMAK:
156 if (record->event.pressed) {
157 set_single_persistent_default_layer(_COLEMAK);
158 }
159 return false;
160 case KC_LOWER:
161 if (record->event.pressed) {
162 layer_on(_LOWER);
163 update_tri_layer(_LOWER, _RAISE, _ADJUST);
164 } else {
165 layer_off(_LOWER);
166 update_tri_layer(_LOWER, _RAISE, _ADJUST);
167 }
168 return false;
169 case KC_RAISE:
170 if (record->event.pressed) {
171 layer_on(_RAISE);
172 update_tri_layer(_LOWER, _RAISE, _ADJUST);
173 } else {
174 layer_off(_RAISE);
175 update_tri_layer(_LOWER, _RAISE, _ADJUST);
176 }
177 return false;
178 case KC_ADJUST:
179 if (record->event.pressed) {
180 layer_on(_ADJUST);
181 } else {
182 layer_off(_ADJUST);
183 }
184 return false;
185 case KC_PRVWD:
186 if (record->event.pressed) {
187 if (keymap_config.swap_lctl_lgui) {
188 register_mods(mod_config(MOD_LALT));
189 register_code(KC_LEFT);
190 } else {
191 register_mods(mod_config(MOD_LCTL));
192 register_code(KC_LEFT);
193 }
194 } else {
195 if (keymap_config.swap_lctl_lgui) {
196 unregister_mods(mod_config(MOD_LALT));
197 unregister_code(KC_LEFT);
198 } else {
199 unregister_mods(mod_config(MOD_LCTL));
200 unregister_code(KC_LEFT);
201 }
202 }
203 break;
204 case KC_NXTWD:
205 if (record->event.pressed) {
206 if (keymap_config.swap_lctl_lgui) {
207 register_mods(mod_config(MOD_LALT));
208 register_code(KC_RIGHT);
209 } else {
210 register_mods(mod_config(MOD_LCTL));
211 register_code(KC_RIGHT);
212 }
213 } else {
214 if (keymap_config.swap_lctl_lgui) {
215 unregister_mods(mod_config(MOD_LALT));
216 unregister_code(KC_RIGHT);
217 } else {
218 unregister_mods(mod_config(MOD_LCTL));
219 unregister_code(KC_RIGHT);
220 }
221 }
222 break;
223 case KC_LSTRT:
224 if (record->event.pressed) {
225 if (keymap_config.swap_lctl_lgui) {
226 //CMD-arrow on Mac, but we have CTL and GUI swapped
227 register_mods(mod_config(MOD_LCTL));
228 register_code(KC_LEFT);
229 } else {
230 register_code(KC_HOME);
231 }
232 } else {
233 if (keymap_config.swap_lctl_lgui) {
234 unregister_mods(mod_config(MOD_LCTL));
235 unregister_code(KC_LEFT);
236 } else {
237 unregister_code(KC_HOME);
238 }
239 }
240 break;
241 case KC_LEND:
242 if (record->event.pressed) {
243 if (keymap_config.swap_lctl_lgui) {
244 //CMD-arrow on Mac, but we have CTL and GUI swapped
245 register_mods(mod_config(MOD_LCTL));
246 register_code(KC_RIGHT);
247 } else {
248 register_code(KC_END);
249 }
250 } else {
251 if (keymap_config.swap_lctl_lgui) {
252 unregister_mods(mod_config(MOD_LCTL));
253 unregister_code(KC_RIGHT);
254 } else {
255 unregister_code(KC_END);
256 }
257 }
258 break;
259 case KC_DLINE:
260 if (record->event.pressed) {
261 register_mods(mod_config(MOD_LCTL));
262 register_code(KC_BSPC);
263 } else {
264 unregister_mods(mod_config(MOD_LCTL));
265 unregister_code(KC_BSPC);
266 }
267 break;
268 case KC_COPY:
269 if (record->event.pressed) {
270 register_mods(mod_config(MOD_LCTL));
271 register_code(KC_C);
272 } else {
273 unregister_mods(mod_config(MOD_LCTL));
274 unregister_code(KC_C);
275 }
276 return false;
277 case KC_PASTE:
278 if (record->event.pressed) {
279 register_mods(mod_config(MOD_LCTL));
280 register_code(KC_V);
281 } else {
282 unregister_mods(mod_config(MOD_LCTL));
283 unregister_code(KC_V);
284 }
285 return false;
286 case KC_CUT:
287 if (record->event.pressed) {
288 register_mods(mod_config(MOD_LCTL));
289 register_code(KC_X);
290 } else {
291 unregister_mods(mod_config(MOD_LCTL));
292 unregister_code(KC_X);
293 }
294 return false;
295 break;
296 case KC_UNDO:
297 if (record->event.pressed) {
298 register_mods(mod_config(MOD_LCTL));
299 register_code(KC_Z);
300 } else {
301 unregister_mods(mod_config(MOD_LCTL));
302 unregister_code(KC_Z);
303 }
304 return false;
305 }
306 return true;
307}
308
309#ifdef ENCODER_ENABLE
310
311void encoder_update_user(uint8_t index, bool clockwise) {
312 if (index == 0) {
313 if (clockwise) {
314 tap_code(KC_VOLU);
315 } else {
316 tap_code(KC_VOLD);
317 }
318 } else if (index == 1) {
319 if (clockwise) {
320 rgblight_step();
321 } else {
322 rgblight_step_reverse();
323 }
324 }
325}
326
327#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/default/rules.mk b/keyboards/aleblazer/zodiark/keymaps/default/rules.mk
new file mode 100644
index 000000000..1e3cebb14
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/default/rules.mk
@@ -0,0 +1 @@
RGBLIGHT_ENABLE = yes
diff --git a/keyboards/aleblazer/zodiark/keymaps/slimoled/config.h b/keyboards/aleblazer/zodiark/keymaps/slimoled/config.h
new file mode 100644
index 000000000..36d9637e7
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/slimoled/config.h
@@ -0,0 +1,22 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#pragma once
18
19#ifdef OLED_DRIVER_ENABLE
20 #define OLED_DISPLAY_128X32
21 #define OLED_TIMEOUT 400000
22#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/slimoled/keymap.c b/keyboards/aleblazer/zodiark/keymaps/slimoled/keymap.c
new file mode 100644
index 000000000..4e98b5cf0
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/slimoled/keymap.c
@@ -0,0 +1,330 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#include QMK_KEYBOARD_H
18
19enum sofle_layers {
20 /* _M_XYZ = Mac Os, _W_XYZ = Win/Linux */
21 _QWERTY,
22 _COLEMAK,
23 _LOWER,
24 _RAISE,
25 _ADJUST,
26};
27
28enum custom_keycodes {
29 KC_QWERTY = SAFE_RANGE,
30 KC_COLEMAK,
31 KC_LOWER,
32 KC_RAISE,
33 KC_ADJUST,
34 KC_PRVWD,
35 KC_NXTWD,
36 KC_LSTRT,
37 KC_LEND,
38 KC_DLINE
39};
40
41const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
42
43 [_QWERTY] = LAYOUT(
44 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
45 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_LBRC, KC_RBRC, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
46 KC_ADJUST, KC_A, KC_S, KC_D, KC_F, KC_G, KC_MINS, KC_EQL, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
47 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_GRV, KC_MUTE, RGB_TOG, KC_DEL,KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT ,
48 KC_LCTL, KC_LALT, KC_LGUI, LALT(KC_TAB), KC_LOWER, KC_SPC, KC_ENT, KC_ENT, KC_SPC, KC_RAISE, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
49 ),
50
51 [_LOWER] = LAYOUT(
52 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
53 KC_PSLS, KC_P7, KC_P8, KC_P9, KC_NLCK, _______, _______, _______, _______, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_F12,
54 KC_CAPS, KC_P4, KC_P5, KC_P6, KC_NLCK, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_NLCK,
55 _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______,
56 _______, KC_P0, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT, KC_PENT, _______
57 ),
58
59 [_RAISE] = LAYOUT(
60 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
61 KC_PSLS, KC_P7, KC_P8, KC_P9, KC_NLCK, _______, _______, _______, _______, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_F12,
62 KC_CAPS, KC_P4, KC_P5, KC_P6, KC_NLCK, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_NLCK,
63 _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______,
64 _______, KC_P0, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT, KC_PENT, _______
65 ),
66
67 [_ADJUST] = LAYOUT(
68 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
69 _______, _______, _______, _______, _______, _______, _______, _______, _______, EEP_RST, _______, _______, _______, KC_F12,
70 _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_TOG, _______, _______, _______, _______,
71 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_MOD, RGB_SPI, RGB_HUI, RGB_SAI, RGB_VAI,
72 _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_SPD, RGB_HUD, RGB_SAD, RGB_VAD
73 )
74
75};
76#ifdef OLED_DRIVER_ENABLE
77
78static void render_logo(void) {
79 static const char PROGMEM qmk_logo[] = {
80 0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,0x92,0x93,0x94,
81 0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,0xb0,0xb1,0xb2,0xb3,0xb4,
82 0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xd0,0xd1,0xd2,0xd3,0xd4,0
83 };
84
85 oled_write_P(qmk_logo, false);
86}
87
88static void print_status_narrow(void) {
89 // Print current mode
90 oled_write_P(PSTR("\n\n"), false);
91 oled_write_ln_P(PSTR("MODE"), false);
92 oled_write_ln_P(PSTR(""), false);
93 if (keymap_config.swap_lctl_lgui) {
94 oled_write_ln_P(PSTR("MAC"), false);
95 } else {
96 oled_write_ln_P(PSTR("WIN"), false);
97 }
98
99 switch (get_highest_layer(default_layer_state)) {
100 case _QWERTY:
101 oled_write_ln_P(PSTR("Qwrt"), false);
102 break;
103 case _COLEMAK:
104 oled_write_ln_P(PSTR("Clmk"), false);
105 break;
106 default:
107 oled_write_P(PSTR("Undef"), false);
108 }
109 oled_write_P(PSTR("\n\n"), false);
110 // Print current layer
111 oled_write_ln_P(PSTR("LAYER"), false);
112 switch (get_highest_layer(layer_state)) {
113 case _COLEMAK:
114 case _QWERTY:
115 oled_write_P(PSTR("Base\n"), false);
116 break;
117 case _RAISE:
118 oled_write_P(PSTR("Raise"), false);
119 break;
120 case _LOWER:
121 oled_write_P(PSTR("Lower"), false);
122 break;
123 case _ADJUST:
124 oled_write_P(PSTR("Adj\n"), false);
125 break;
126 default:
127 oled_write_ln_P(PSTR("Undef"), false);
128 }
129 oled_write_P(PSTR("\n\n"), false);
130 led_t led_usb_state = host_keyboard_led_state();
131 oled_write_ln_P(PSTR("CPSLK"), led_usb_state.caps_lock);
132}
133
134oled_rotation_t oled_init_user(oled_rotation_t rotation) {
135 if (is_keyboard_master()) {
136 return OLED_ROTATION_90;
137 }
138 return rotation;
139}
140
141void oled_task_user(void) {
142 if (is_keyboard_master()) {
143 print_status_narrow();
144 } else {
145 render_logo();
146 }
147}
148
149#endif
150
151bool process_record_user(uint16_t keycode, keyrecord_t *record) {
152 switch (keycode) {
153 case KC_QWERTY:
154 if (record->event.pressed) {
155 set_single_persistent_default_layer(_QWERTY);
156 }
157 return false;
158 case KC_COLEMAK:
159 if (record->event.pressed) {
160 set_single_persistent_default_layer(_COLEMAK);
161 }
162 return false;
163 case KC_LOWER:
164 if (record->event.pressed) {
165 layer_on(_LOWER);
166 update_tri_layer(_LOWER, _RAISE, _ADJUST);
167 } else {
168 layer_off(_LOWER);
169 update_tri_layer(_LOWER, _RAISE, _ADJUST);
170 }
171 return false;
172 case KC_RAISE:
173 if (record->event.pressed) {
174 layer_on(_RAISE);
175 update_tri_layer(_LOWER, _RAISE, _ADJUST);
176 } else {
177 layer_off(_RAISE);
178 update_tri_layer(_LOWER, _RAISE, _ADJUST);
179 }
180 return false;
181 case KC_ADJUST:
182 if (record->event.pressed) {
183 layer_on(_ADJUST);
184 } else {
185 layer_off(_ADJUST);
186 }
187 return false;
188 case KC_PRVWD:
189 if (record->event.pressed) {
190 if (keymap_config.swap_lctl_lgui) {
191 register_mods(mod_config(MOD_LALT));
192 register_code(KC_LEFT);
193 } else {
194 register_mods(mod_config(MOD_LCTL));
195 register_code(KC_LEFT);
196 }
197 } else {
198 if (keymap_config.swap_lctl_lgui) {
199 unregister_mods(mod_config(MOD_LALT));
200 unregister_code(KC_LEFT);
201 } else {
202 unregister_mods(mod_config(MOD_LCTL));
203 unregister_code(KC_LEFT);
204 }
205 }
206 break;
207 case KC_NXTWD:
208 if (record->event.pressed) {
209 if (keymap_config.swap_lctl_lgui) {
210 register_mods(mod_config(MOD_LALT));
211 register_code(KC_RIGHT);
212 } else {
213 register_mods(mod_config(MOD_LCTL));
214 register_code(KC_RIGHT);
215 }
216 } else {
217 if (keymap_config.swap_lctl_lgui) {
218 unregister_mods(mod_config(MOD_LALT));
219 unregister_code(KC_RIGHT);
220 } else {
221 unregister_mods(mod_config(MOD_LCTL));
222 unregister_code(KC_RIGHT);
223 }
224 }
225 break;
226 case KC_LSTRT:
227 if (record->event.pressed) {
228 if (keymap_config.swap_lctl_lgui) {
229 //CMD-arrow on Mac, but we have CTL and GUI swapped
230 register_mods(mod_config(MOD_LCTL));
231 register_code(KC_LEFT);
232 } else {
233 register_code(KC_HOME);
234 }
235 } else {
236 if (keymap_config.swap_lctl_lgui) {
237 unregister_mods(mod_config(MOD_LCTL));
238 unregister_code(KC_LEFT);
239 } else {
240 unregister_code(KC_HOME);
241 }
242 }
243 break;
244 case KC_LEND:
245 if (record->event.pressed) {
246 if (keymap_config.swap_lctl_lgui) {
247 //CMD-arrow on Mac, but we have CTL and GUI swapped
248 register_mods(mod_config(MOD_LCTL));
249 register_code(KC_RIGHT);
250 } else {
251 register_code(KC_END);
252 }
253 } else {
254 if (keymap_config.swap_lctl_lgui) {
255 unregister_mods(mod_config(MOD_LCTL));
256 unregister_code(KC_RIGHT);
257 } else {
258 unregister_code(KC_END);
259 }
260 }
261 break;
262 case KC_DLINE:
263 if (record->event.pressed) {
264 register_mods(mod_config(MOD_LCTL));
265 register_code(KC_BSPC);
266 } else {
267 unregister_mods(mod_config(MOD_LCTL));
268 unregister_code(KC_BSPC);
269 }
270 break;
271 case KC_COPY:
272 if (record->event.pressed) {
273 register_mods(mod_config(MOD_LCTL));
274 register_code(KC_C);
275 } else {
276 unregister_mods(mod_config(MOD_LCTL));
277 unregister_code(KC_C);
278 }
279 return false;
280 case KC_PASTE:
281 if (record->event.pressed) {
282 register_mods(mod_config(MOD_LCTL));
283 register_code(KC_V);
284 } else {
285 unregister_mods(mod_config(MOD_LCTL));
286 unregister_code(KC_V);
287 }
288 return false;
289 case KC_CUT:
290 if (record->event.pressed) {
291 register_mods(mod_config(MOD_LCTL));
292 register_code(KC_X);
293 } else {
294 unregister_mods(mod_config(MOD_LCTL));
295 unregister_code(KC_X);
296 }
297 return false;
298 break;
299 case KC_UNDO:
300 if (record->event.pressed) {
301 register_mods(mod_config(MOD_LCTL));
302 register_code(KC_Z);
303 } else {
304 unregister_mods(mod_config(MOD_LCTL));
305 unregister_code(KC_Z);
306 }
307 return false;
308 }
309 return true;
310}
311
312#ifdef ENCODER_ENABLE
313
314void encoder_update_user(uint8_t index, bool clockwise) {
315 if (index == 0) {
316 if (clockwise) {
317 tap_code(KC_VOLU);
318 } else {
319 tap_code(KC_VOLD);
320 }
321 } else if (index == 1) {
322 if (clockwise) {
323 rgblight_step();
324 } else {
325 rgblight_step_reverse();
326 }
327 }
328}
329
330#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/slimoled/rules.mk b/keyboards/aleblazer/zodiark/keymaps/slimoled/rules.mk
new file mode 100644
index 000000000..1e3cebb14
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/slimoled/rules.mk
@@ -0,0 +1 @@
RGBLIGHT_ENABLE = yes
diff --git a/keyboards/aleblazer/zodiark/keymaps/via/config.h b/keyboards/aleblazer/zodiark/keymaps/via/config.h
new file mode 100644
index 000000000..0c89f634b
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/via/config.h
@@ -0,0 +1,22 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#pragma once
18
19#ifdef OLED_DRIVER_ENABLE
20 #define OLED_DISPLAY_128X64
21 #define OLED_TIMEOUT 400000
22#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/via/encoder.c b/keyboards/aleblazer/zodiark/keymaps/via/encoder.c
new file mode 100644
index 000000000..06d7a2577
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/via/encoder.c
@@ -0,0 +1,35 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3This program is free software: you can redistribute it and/or modify
4it under the terms of the GNU General Public License as published by
5the Free Software Foundation, either version 3 of the License, or
6(at your option) any later version.
7This program is distributed in the hope that it will be useful,
8but WITHOUT ANY WARRANTY; without even the implied warranty of
9MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10GNU General Public License for more details.
11You should have received a copy of the GNU General Public License
12along with this program. If not, see <http://www.gnu.org/licenses/>.
13*/
14
15//Setting up what encoder rotation does. If your encoder can be pressed as a button, that function can be set in Via.
16
17#ifdef ENCODER_ENABLE
18
19void encoder_update_user(uint8_t index, bool clockwise) {
20 if (index == 0) {
21 if (clockwise) {
22 tap_code(KC_VOLU);
23 } else {
24 tap_code(KC_VOLD);
25 }
26 } else if (index == 1) {
27 if (clockwise) {
28 tap_code(KC_PGDOWN);
29 } else {
30 tap_code(KC_PGUP);
31 }
32 }
33}
34
35#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/via/keymap.c b/keyboards/aleblazer/zodiark/keymaps/via/keymap.c
new file mode 100644
index 000000000..1159afb43
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/via/keymap.c
@@ -0,0 +1,52 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3This program is free software: you can redistribute it and/or modify
4it under the terms of the GNU General Public License as published by
5the Free Software Foundation, either version 3 of the License, or
6(at your option) any later version.
7This program is distributed in the hope that it will be useful,
8but WITHOUT ANY WARRANTY; without even the implied warranty of
9MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10GNU General Public License for more details.
11You should have received a copy of the GNU General Public License
12along with this program. If not, see <http://www.gnu.org/licenses/>.
13*/
14#include QMK_KEYBOARD_H
15#include "oled.c"
16#include "encoder.c"
17
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19
20 [0] = LAYOUT(
21 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC,
22 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_LBRC, KC_RBRC, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSLS,
23 MO(3), KC_A, KC_S, KC_D, KC_F, KC_G, KC_MINS, KC_EQL, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
24 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_GRV, KC_MUTE, RGB_TOG, KC_DEL,KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_ENT ,
25 KC_LCTL, KC_LALT, KC_LGUI, KC_APP, MO(1), KC_SPC, KC_ENT, KC_ENT, KC_SPC, MO(2), KC_LEFT, KC_DOWN, KC_UP, KC_RGHT
26 ),
27
28 [1] = LAYOUT(
29 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
30 KC_PSLS, KC_P7, KC_P8, KC_P9, KC_NLCK, _______, _______, _______, _______, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_F12,
31 KC_CAPS, KC_P4, KC_P5, KC_P6, KC_NLCK, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_NLCK,
32 _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______,
33 _______, KC_P0, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT, KC_PENT, _______
34 ),
35
36 [2] = LAYOUT(
37 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
38 KC_PSLS, KC_P7, KC_P8, KC_P9, KC_NLCK, _______, _______, _______, _______, KC_PSLS, KC_P7, KC_P8, KC_P9, KC_F12,
39 KC_CAPS, KC_P4, KC_P5, KC_P6, KC_NLCK, _______, _______, _______, _______, _______, KC_P4, KC_P5, KC_P6, KC_NLCK,
40 _______, KC_P1, KC_P2, KC_P3, _______, _______, _______, _______, _______, _______, _______, _______, KC_P1, KC_P2, KC_P3, _______,
41 _______, KC_P0, KC_PDOT, KC_PENT, _______, _______, _______, _______, _______, _______, KC_P0, KC_PDOT, KC_PENT, _______
42 ),
43
44 [3] = LAYOUT(
45 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
46 _______, _______, _______, _______, _______, _______, _______, _______, _______, EEP_RST, _______, _______, _______, KC_F12,
47 _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_TOG, _______, _______, _______, _______,
48 _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_MOD, RGB_SPI, RGB_HUI, RGB_SAI, RGB_VAI,
49 _______, _______, _______, _______, _______, _______, _______, _______, _______, RGB_RMOD, RGB_SPD, RGB_HUD, RGB_SAD, RGB_VAD
50 )
51
52};
diff --git a/keyboards/aleblazer/zodiark/keymaps/via/oled.c b/keyboards/aleblazer/zodiark/keymaps/via/oled.c
new file mode 100644
index 000000000..037fe2ff7
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/via/oled.c
@@ -0,0 +1,78 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3This program is free software: you can redistribute it and/or modify
4it under the terms of the GNU General Public License as published by
5the Free Software Foundation, either version 3 of the License, or
6(at your option) any later version.
7This program is distributed in the hope that it will be useful,
8but WITHOUT ANY WARRANTY; without even the implied warranty of
9MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10GNU General Public License for more details.
11You should have received a copy of the GNU General Public License
12along with this program. If not, see <http://www.gnu.org/licenses/>.
13*/
14
15#ifdef OLED_DRIVER_ENABLE
16
17static void render_logo(void) {
18 static const char PROGMEM qmk_logo[] = {
19 0x80,0x81,0x82,0x83,0x84,0x85,0x86,0x87,0x88,0x89,0x8a,0x8b,0x8c,0x8d,0x8e,0x8f,0x90,0x91,0x92,0x93,0x94,
20 0xa0,0xa1,0xa2,0xa3,0xa4,0xa5,0xa6,0xa7,0xa8,0xa9,0xaa,0xab,0xac,0xad,0xae,0xaf,0xb0,0xb1,0xb2,0xb3,0xb4,
21 0xc0,0xc1,0xc2,0xc3,0xc4,0xc5,0xc6,0xc7,0xc8,0xc9,0xca,0xcb,0xcc,0xcd,0xce,0xcf,0xd0,0xd1,0xd2,0xd3,0xd4,0
22 };
23
24 oled_write_P(qmk_logo, false);
25}
26
27static void print_status_narrow(void) {
28 // Print current mode
29 oled_write_P(PSTR("\n\n"), false);
30
31 switch (get_highest_layer(layer_state)) {
32 case 0:
33 oled_write_ln_P(PSTR("Qwrt"), false);
34 break;
35 default:
36 oled_write_P(PSTR("Mod\n"), false);
37 break;
38 }
39 oled_write_P(PSTR("\n\n"), false);
40 // Print current layer
41 oled_write_ln_P(PSTR("LAYER"), false);
42 switch (get_highest_layer(layer_state)) {
43 case 0:
44 oled_write_P(PSTR("Base\n"), false);
45 break;
46 case 1:
47 oled_write_P(PSTR("Raise"), false);
48 break;
49 case 2:
50 oled_write_P(PSTR("Lower"), false);
51 break;
52 case 3:
53 oled_write_P(PSTR("Adjust"), false);
54 break;
55 default:
56 oled_write_ln_P(PSTR("Undef"), false);
57 }
58 oled_write_P(PSTR("\n\n"), false);
59 led_t led_usb_state = host_keyboard_led_state();
60 oled_write_ln_P(PSTR("CPSLK"), led_usb_state.caps_lock);
61}
62
63oled_rotation_t oled_init_user(oled_rotation_t rotation) {
64 if (is_keyboard_master()) {
65 return OLED_ROTATION_90;
66 }
67 return rotation;
68}
69
70void oled_task_user(void) {
71 if (is_keyboard_master()) {
72 print_status_narrow();
73 } else {
74 render_logo();
75 }
76}
77
78#endif
diff --git a/keyboards/aleblazer/zodiark/keymaps/via/rules.mk b/keyboards/aleblazer/zodiark/keymaps/via/rules.mk
new file mode 100644
index 000000000..76d3c49ff
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/keymaps/via/rules.mk
@@ -0,0 +1,2 @@
1RGBLIGHT_ENABLE = yes
2VIA_ENABLE = yes
diff --git a/keyboards/aleblazer/zodiark/readme.md b/keyboards/aleblazer/zodiark/readme.md
new file mode 100644
index 000000000..fe28bedd4
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/readme.md
@@ -0,0 +1,23 @@
1# Zodiark Keyboard
2
3![Zodiark Split](https://i.imgur.com/49O8aowl.jpg)
4
5A split keyboard with 5x7 including a thumbcluster, encoders on each side, per key RGB, and 2x I2C headers per side, supporiting 1.3"/.96" 128x64 OLEDs (the 1.3" is an SSH1106 OLED, refer to QMK documentation for limitations), .91" 128x32 OLEDs.
6
7* Keyboard Maintainer: [Aleblazer](https://github.com/Aleblazer/), [Discord Link](https://discord.gg/BCSbXwskVt)
8* Hardware Supported: Pro Micro and derivatives
9* Hardware Availability: Pending Group Buy - [Discord Link](https://discord.gg/BCSbXwskVt)
10
11Make example for this keyboard (after setting up your build environment):
12
13 make zodiark:default
14
15Flashing example for this keyboard:
16
17 make zodiark:default:flash
18
19Remove TRRS cable from halves, plug into one side, press reset button when asked. Repeat process on the other side.
20
21See 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).
22
23Credit to Sofle and Josef Adamcik <josef.adamcik@gmail.com> for OLED and layer code.
diff --git a/keyboards/aleblazer/zodiark/rules.mk b/keyboards/aleblazer/zodiark/rules.mk
new file mode 100644
index 000000000..89e4850d8
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/rules.mk
@@ -0,0 +1,27 @@
1# MCU name
2MCU = atmega32u4
3
4# Bootloader selection
5BOOTLOADER = caterina
6
7# Build Options
8# change yes to no to disable
9#
10BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
11MOUSEKEY_ENABLE = yes # Mouse keys
12EXTRAKEY_ENABLE = yes # Audio control and System control
13CONSOLE_ENABLE = no # Console for debug
14COMMAND_ENABLE = no # Commands for debug and configuration
15# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
16SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
17# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
18NKRO_ENABLE = no # USB Nkey Rollover
19BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
20RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
21BLUETOOTH_ENABLE = no # Enable Bluetooth
22AUDIO_ENABLE = no # Audio output
23OLED_DRIVER_ENABLE = yes # Enable Support for SSD1306 or SH1106 OLED Displays; Communicating over I2C
24ENCODER_ENABLE = yes
25SPLIT_KEYBOARD = yes
26LTO_ENABLE = yes
27RGB_MATRIX_DRIVER = WS2812
diff --git a/keyboards/aleblazer/zodiark/zodiark.c b/keyboards/aleblazer/zodiark/zodiark.c
new file mode 100644
index 000000000..d3893ada0
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/zodiark.c
@@ -0,0 +1,54 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#include "zodiark.h"
18
19#ifdef RGB_MATRIX_ENABLE
20led_config_t g_led_config = { {
21// Key Matrix to LED Index
22 // Left Hand
23 { 5, 4, 3, 2, 1, 0, 12 },
24 { 6, 7, 8, 9, 10, 11, 13 },
25 { 19, 18, 17, 16, 15, 14, 26 },
26 { 20, 21, 22, 23, 24, 25, NO_LED },
27 { 33, 32, 31, 30, 29, 28, 27},
28 // Right Hand
29 { 39, 38, 37, 36, 35, 34, 46 },
30 { 40, 41, 42, 43, 44, 45, 47 },
31 { 53, 52, 51, 50, 49, 48, 60 },
32 { 54, 55, 56, 57, 58, 59, NO_LED },
33 { 67, 66, 65, 64, 63, 62, 61 },
34
35
36}, {
37 // LED Index to Physical Position
38 // Left Hand
39 { 93, 0 }, { 74, 0 }, { 56, 0 }, { 37, 0 }, { 19, 0 }, { 0, 0 }, { 0, 16 },
40 { 19, 16 }, { 37, 16 }, { 56, 16 }, { 74, 16 }, { 93, 16 }, { 112, 24 }, { 112, 40 },
41 { 93, 32 }, { 74, 32 }, { 56, 32 }, { 37, 32 }, { 19, 32 }, { 0, 32 }, { 0, 48 },
42 { 19, 48 }, { 37, 48 }, { 56, 48 }, { 74, 48 }, { 93, 48 }, { 112, 52 },
43 { 112, 64 }, { 93, 64 }, { 74, 64 }, { 56, 64 }, { 37, 64 }, { 19, 64 }, { 0, 64 },
44 // Right Hand
45 { 132, 0 }, { 150, 0 }, { 169, 0 }, { 187, 0 }, { 206, 0 }, { 224, 0 }, { 224, 16 },
46 { 206, 16 }, { 187, 16 }, { 169, 16 }, { 150, 16 }, { 132, 16 }, { 113, 24 }, { 113, 40 },
47 { 132, 32 }, { 150, 32 }, { 169, 32 }, { 187, 32 }, { 206, 32 }, { 224, 32 }, { 224, 48 },
48 { 206, 48 }, { 187, 48 }, { 169, 48 }, { 150, 48 }, { 132, 48 }, { 113, 52 },
49 { 113, 64 }, { 132, 64 }, { 150, 64 }, { 169, 64 }, { 187, 64 }, { 206, 64 }, { 224, 64 },
50}, {
51 // LED Index to Flag
52 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4
53} };
54#endif
diff --git a/keyboards/aleblazer/zodiark/zodiark.h b/keyboards/aleblazer/zodiark/zodiark.h
new file mode 100644
index 000000000..5c25cea54
--- /dev/null
+++ b/keyboards/aleblazer/zodiark/zodiark.h
@@ -0,0 +1,38 @@
1/*
2Copyright 2021 Spencer Deven <splitlogicdesign@gmail.com>
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 3 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program. If not, see <http://www.gnu.org/licenses/>.
16*/
17#pragma once
18#include "quantum.h"
19
20#define LAYOUT( \
21 L00, L01, L02, L03, L04, L05, R01, R02, R03, R04, R05, R06, \
22 L10, L11, L12, L13, L14, L15, L06, R00, R11, R12, R13, R14, R15, R16, \
23 L20, L21, L22, L23, L24, L25, L16, R10, R21, R22, R23, R24, R25, R26, \
24 L30, L31, L32, L33, L34, L35, L26, L36, R30, R20, R31, R32, R33, R34, R35, R36, \
25 L40, L41, L42, L43, L44, L45, L46, R40, R41, R42, R43, R44, R45, R46 \
26 ) \
27 { \
28 { L00, L01, L02, L03, L04, L05, L06 }, \
29 { L10, L11, L12, L13, L14, L15, L16 }, \
30 { L20, L21, L22, L23, L24, L25, L26 }, \
31 { L30, L31, L32, L33, L34, L35, L36 }, \
32 { L40, L41, L42, L43, L44, L45, L46 }, \
33 { R06, R05, R04, R03, R02, R01, R00 }, \
34 { R16, R15, R14, R13, R12, R11, R10 }, \
35 { R26, R25, R24, R23, R22, R21, R20 }, \
36 { R36, R35, R34, R33, R32, R31, R30 }, \
37 { R46, R45, R44, R43, R42, R41, R40 } \
38}