summaryrefslogtreecommitdiff
path: root/keyboards/joshajohnson
diff options
context:
space:
mode:
authorJoel Challis <git@zvecr.com>2024-02-18 08:20:57 +0000
committerGitHub <noreply@github.com>2024-02-18 08:20:57 +0000
commit2eb9ff8efd1df2c98724481c71c8ab8a5b62e31e (patch)
tree8f3b9dd7e9a8dfc8657f1f2adfc24bc0ad185280 /keyboards/joshajohnson
parent2d1aed78a67b3d2b002cc739ef087963b05b76b8 (diff)
Remove obvious user keymaps, keyboards/{i,j,k}* edition (#23102)
Diffstat (limited to 'keyboards/joshajohnson')
-rw-r--r--keyboards/joshajohnson/hub16/keymaps/peepeetee/config.h45
-rw-r--r--keyboards/joshajohnson/hub16/keymaps/peepeetee/keymap.c209
-rw-r--r--keyboards/joshajohnson/hub16/keymaps/peepeetee/rules.mk1
3 files changed, 0 insertions, 255 deletions
diff --git a/keyboards/joshajohnson/hub16/keymaps/peepeetee/config.h b/keyboards/joshajohnson/hub16/keymaps/peepeetee/config.h
deleted file mode 100644
index 62b0df937b..0000000000
--- a/keyboards/joshajohnson/hub16/keymaps/peepeetee/config.h
+++ /dev/null
@@ -1,45 +0,0 @@
1/*
2Copyright 2019 Josh Johnson
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 2 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
18#pragma once
19
20#define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
21// /*== customize breathing effect ==*/
22// /*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/
23// #define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64
24// /*==== use exp() and sin() ====*/
25// #define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7
26// #define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255
27// #endif
28
29/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
30#define DEBOUNCE 20
31
32// Time out one shot layers after 3 seconds
33#define ONESHOT_TIMEOUT 3000
34
35// Undef and redefine default brightness to half of 255
36#undef RGBLIGHT_LIMIT_VAL
37#define RGBLIGHT_LIMIT_VAL 255
38
39//Define a preview timeout for RGB reviews
40#define PREVIEW_TIMEOUT 5000
41
42// Enable Light Layers implementation
43#define RGBLIGHT_LAYERS
44// Allow Light Layers to override RGB off configuration
45#define RGBLIGHT_LAYERS_OVERRIDE_RGB_OFF
diff --git a/keyboards/joshajohnson/hub16/keymaps/peepeetee/keymap.c b/keyboards/joshajohnson/hub16/keymaps/peepeetee/keymap.c
deleted file mode 100644
index dac88c8482..0000000000
--- a/keyboards/joshajohnson/hub16/keymaps/peepeetee/keymap.c
+++ /dev/null
@@ -1,209 +0,0 @@
1/*
2Copyright 2019 Josh Johnson 2021 peepeetee
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 2 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
18#include QMK_KEYBOARD_H
19
20#if defined(RGBLIGHT_ENABLE) && defined(RGBLIGHT_LAYERS)
21static uint32_t rgb_preview_timer = 0;
22#endif
23
24const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
25
26
27 // Layer 0 - Base Layer (F13 to F24, and One Shot Layer 1,2,3 or Toggle Layer 4)
28 [0] = LAYOUT(
29 KC_MPLY, KC_MUTE,
30 TG(3), TG(2), TG(1), TG(0),
31 KC_PSCR, KC_SCRL, KC_PAUS, A(KC_F4),
32 KC_INS, KC_HOME, KC_PGUP, KC_F12, //Transparent to let you go between layers
33 KC_DEL, A(KC_F4), KC_PGDN, KC_CALCULATOR
34
35 ),
36
37 [1] = LAYOUT(
38 KC_MPLY, KC_MUTE,
39 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
40 KC_F7, KC_F8, KC_F9, KC_F10,
41 KC_F4, KC_F5, KC_F6, KC_F11,
42 KC_F1, KC_F2, KC_F3, KC_F12 //Transparent to let you go between layers
43 ),
44
45
46 //Layer 5 - Keyboard Lights, Programming and Special Functions
47 [2] = LAYOUT(
48 KC_MPLY, KC_MUTE,
49 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, //Transparent to let you go between layers
50 RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI,
51 RGB_RMOD, RGB_HUD, RGB_SAD, RGB_VAD,
52 RGB_TOG, EE_CLR, QK_BOOT, KC_TRNS
53 ),
54
55 [3] = LAYOUT(
56 KC_MPLY, KC_MUTE,
57 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, //Transparent to let you go between layers
58 RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI,
59 RGB_RMOD, RGB_HUD, RGB_SAD, RGB_VAD,
60 RGB_TOG, EE_CLR, QK_BOOT, KC_TRNS
61 )
62
63
64 //Layer 0 - Base Layer (F13 to F24, and One Shot Layer 1,2,3 or Toggle Layer 4)
65 // [0] = LAYOUT(
66 // KC_MPLY, KC_MUTE,
67 // KC_F13, KC_F14, KC_F15, KC_F16,
68 // KC_F17, KC_F18, KC_F19, KC_F20,
69 // KC_F21, KC_F22, KC_F23, KC_F24,
70 // OSL(1), OSL(2), OSL(3), TG(4) //Transparent to let you go between layers
71 // ),
72
73 // [1] = LAYOUT(
74 // KC_MPLY, KC_MUTE,
75 // LALT(KC_F13), LALT(KC_F14), LALT(KC_F15), LALT(KC_F16),
76 // LALT(KC_F17), LALT(KC_F18), LALT(KC_F19), LALT(KC_F20),
77 // LALT(KC_F21), LALT(KC_F22), LALT(KC_F23), LALT(KC_F24),
78 // KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS //Transparent to let you go between layers
79 // ),
80
81 //Layer 2 - Shift + Function Key Layer
82 // [2] = LAYOUT(
83 // KC_MPLY, KC_MUTE,
84 // LSFT(KC_F13), LSFT(KC_F14), LSFT(KC_F15), LSFT(KC_F16),
85 // LSFT(KC_F17), LSFT(KC_F18), LSFT(KC_F19), LSFT(KC_F20),
86 // LSFT(KC_F21), LSFT(KC_F22), LSFT(KC_F23), LSFT(KC_F24),
87 // KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS //Transparent to let you go between layers
88 // ),
89
90 // //Layer 3 - Control + Function Key
91 // [3] = LAYOUT(
92 // KC_MPLY, KC_MUTE,
93 // LCTL(KC_F13), LCTL(KC_F14), LCTL(KC_F15), LCTL(KC_F16),
94 // LCTL(KC_F17), LCTL(KC_F18), LCTL(KC_F19), LCTL(KC_F20),
95 // LCTL(KC_F21), LCTL(KC_F22), LCTL(KC_F23), LCTL(KC_F24),
96 // KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS //Transparent to let you go between layers
97 // ),
98
99 // //Layer 4 - Multimedia
100 // [4] = LAYOUT(
101 // KC_MPLY, KC_MUTE,
102 // KC_MPRV, KC_MPLY, KC_U, KC_K,
103 // KC_NO, KC_NO, KC_ENT, KC_X,
104 // KC_NO, QK_BOOT, LSFT(KC_HASH), KC_J,
105 // TG(5), KC_TRNS, KC_TRNS, KC_TRNS //Transparent to let you go between layers
106 // ),
107
108 // //Layer 5 - Keyboard Lights, Programming and Special Functions
109 // [5] = LAYOUT(
110 // KC_MPLY, KC_MUTE,
111 // RGB_MOD, RGB_HUI, RGB_SAI, RGB_VAI,
112 // RGB_RMOD, RGB_HUD, RGB_SAD, RGB_VAD,
113 // RGB_TOG, EE_CLR, QK_BOOT, KC_LSFT,
114 // KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS //Transparent to let you go between layers
115 // ),
116};
117
118const rgblight_segment_t PROGMEM my_layer0_layer[] = RGBLIGHT_LAYER_SEGMENTS(
119 {0,16,HSV_WHITE}
120 );
121const rgblight_segment_t PROGMEM my_layer1_layer[] = RGBLIGHT_LAYER_SEGMENTS(
122 {0,16,HSV_ORANGE}
123 );
124 const rgblight_segment_t PROGMEM my_layer2_layer[] = RGBLIGHT_LAYER_SEGMENTS(
125 {0,16,HSV_RED}
126 );
127 const rgblight_segment_t PROGMEM my_layer3_layer[] = RGBLIGHT_LAYER_SEGMENTS(
128 {0,16,HSV_BLUE}
129 );
130// const rgblight_segment_t PROGMEM my_layer4_layer[] = RGBLIGHT_LAYER_SEGMENTS(
131// {0,16,HSV_WHITE}
132// );
133// const rgblight_segment_t PROGMEM my_layer5_layer[] = RGBLIGHT_LAYER_SEGMENTS(
134// {0,16,HSV_TEAL}
135// );
136const rgblight_segment_t* const PROGMEM my_rgb_layers[] = RGBLIGHT_LAYERS_LIST(
137 my_layer0_layer,
138 my_layer1_layer,
139 my_layer2_layer,
140 my_layer3_layer//,
141 // my_layer4_layer,
142 // my_layer5_layer
143 );
144
145bool encoder_update_user(uint8_t index, bool clockwise) {
146 if (index == 0) { /* Left Encoder */
147 if (clockwise) {
148 tap_code(KC_MPRV);
149 } else {
150 tap_code(KC_MNXT);
151 }
152 } else if (index == 1) { /* Right Encoder */
153 if (clockwise) {
154 tap_code(KC_VOLD);
155 } else {
156 tap_code(KC_VOLU);
157 }
158 }
159 return true;
160}
161void post_process_record_user(uint16_t keycode, keyrecord_t *record) {
162 // Allow for a preview of changes when modifying RGB
163# if defined(RGBLIGHT_ENABLE) && defined(RGBLIGHT_LAYERS)
164 switch (keycode) {
165 case RGB_TOG ... QK_VELOCIKEY_TOGGLE:
166 for (uint8_t i = 0; i < RGBLIGHT_MAX_LAYERS; i++) {
167 rgblight_set_layer_state(i, false);
168 }
169 rgb_preview_timer = timer_read32();
170 break;
171 }
172# endif
173 return;
174}
175
176//Set the appropriate layer color
177layer_state_t layer_state_set_user(layer_state_t state) {
178 rgblight_set_layer_state(0, false);
179 rgblight_set_layer_state(1, layer_state_cmp(state, 1));
180 rgblight_set_layer_state(2, layer_state_cmp(state, 2));
181 rgblight_set_layer_state(3, layer_state_cmp(state, 3));
182 // rgblight_set_layer_state(4, layer_state_cmp(state, 4));
183 // rgblight_set_layer_state(5, layer_state_cmp(state, 5));
184 return state;
185}
186
187void keyboard_post_init_user(void) {
188 //Enable the LED layers
189 rgblight_layers = my_rgb_layers;
190 layer_state_set_user(layer_state);
191}
192
193void matrix_scan_user(void) {
194# if defined(RGBLIGHT_ENABLE) && defined(RGBLIGHT_LAYERS)
195 // Allow preview for
196 if (rgb_preview_timer && TIMER_DIFF_32(timer_read32(), rgb_preview_timer) > PREVIEW_TIMEOUT) {
197 rgb_preview_timer = 0;
198 default_layer_state_set_user(default_layer_state);
199 layer_state_set_user(layer_state);
200 led_update_user((led_t) host_keyboard_leds());
201 }
202# endif
203}
204
205//EEPROM Reset Function
206void eeconfig_init_user(void) {
207 rgblight_enable(); // Enable RGB by default
208 rgblight_sethsv(HSV_ORANGE); // Set it to orange by default
209}
diff --git a/keyboards/joshajohnson/hub16/keymaps/peepeetee/rules.mk b/keyboards/joshajohnson/hub16/keymaps/peepeetee/rules.mk
deleted file mode 100644
index f6737b8e4a..0000000000
--- a/keyboards/joshajohnson/hub16/keymaps/peepeetee/rules.mk
+++ /dev/null
@@ -1 +0,0 @@
1BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite \ No newline at end of file