First TypeK support (#22876)
This commit is contained in:
		
							parent
							
								
									e5466df800
								
							
						
					
					
						commit
						12d70ab1a4
					
				
							
								
								
									
										33
									
								
								keyboards/typek/config.h
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								keyboards/typek/config.h
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,33 @@ | |||||||
|  | /*
 | ||||||
|  | Copyright 2022 Gondolindrim | ||||||
|  | 
 | ||||||
|  | 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 WS2812_PWM_COMPLEMENTARY_OUTPUT | ||||||
|  | #define WS2812_PWM_DRIVER PWMD1 | ||||||
|  | #define WS2812_PWM_CHANNEL 3 | ||||||
|  | #define WS2812_PWM_PAL_MODE 1 | ||||||
|  | #define WS2812_DMA_STREAM STM32_DMA2_STREAM5 | ||||||
|  | #define WS2812_DMA_CHANNEL 6 | ||||||
|  | 
 | ||||||
|  | /* LED MAP
 | ||||||
|  | 		0 , 1 , 2														Three indicators | ||||||
|  | 		3 , 4 , 5														Three RGBs on left side | ||||||
|  | 		66, 67, 68														Three RGBs on right side | ||||||
|  | 		35, 34, 33, 32, 31, 30, 29, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14, 13, 12, 11, 10,  9,  8,  7,  6	Left RGB wing (30 LEDs) | ||||||
|  | 		36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65	Right RGB wing (30 LEDs) | ||||||
|  | 		*/ | ||||||
							
								
								
									
										21
									
								
								keyboards/typek/halconf.h
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								keyboards/typek/halconf.h
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,21 @@ | |||||||
|  | /* Copyright 2020 QMK
 | ||||||
|  |  * | ||||||
|  |  * 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 HAL_USE_PWM TRUE | ||||||
|  | 
 | ||||||
|  | #include_next <halconf.h> | ||||||
							
								
								
									
										197
									
								
								keyboards/typek/keyboard.json
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										197
									
								
								keyboards/typek/keyboard.json
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,197 @@ | |||||||
|  | { | ||||||
|  |     "manufacturer": "gok", | ||||||
|  |     "keyboard_name": "TypeK-S Rev. Zeta-RC2", | ||||||
|  |     "maintainer": "Gondolindrim", | ||||||
|  |     "bootloader": "stm32-dfu", | ||||||
|  |     "build": { | ||||||
|  |         "lto": true | ||||||
|  |     }, | ||||||
|  |     "diode_direction": "COL2ROW", | ||||||
|  |     "eeprom": { | ||||||
|  |         "wear_leveling": { | ||||||
|  |             "backing_size": 4096 | ||||||
|  |         } | ||||||
|  |     }, | ||||||
|  |     "features": { | ||||||
|  |         "bootmagic": true, | ||||||
|  |         "nkro": true, | ||||||
|  |         "rgblight": true | ||||||
|  |     }, | ||||||
|  |     "matrix_pins": { | ||||||
|  |         "cols": ["A3", "B12", "A0", "A10", "B0", "B1", "B10", "B3", "C15", "C14", "C13", "B9", "B8", "B5"], | ||||||
|  |         "rows": ["A7", "A8", "A15", "A1", "A2"] | ||||||
|  |     }, | ||||||
|  |     "processor": "STM32F411", | ||||||
|  |     "rgblight": { | ||||||
|  |         "animations": { | ||||||
|  |             "alternating": true, | ||||||
|  |             "breathing": true, | ||||||
|  |             "christmas": true, | ||||||
|  |             "knight": true, | ||||||
|  |             "rainbow_mood": true, | ||||||
|  |             "rainbow_swirl": true, | ||||||
|  |             "rgb_test": true, | ||||||
|  |             "snake": true, | ||||||
|  |             "static_gradient": true, | ||||||
|  |             "twinkle": true | ||||||
|  |         }, | ||||||
|  |         "default": { | ||||||
|  |             "animation": "rainbow_swirl", | ||||||
|  |             "val": 200 | ||||||
|  |         }, | ||||||
|  |         "led_count": 69, | ||||||
|  |         "led_map": [0, 1, 2, 3, 4, 5, 66, 67, 68, 35, 34, 33, 32, 31, 30, 29, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65] | ||||||
|  |     }, | ||||||
|  |     "url": "https://www.gok.design/type-k", | ||||||
|  |     "usb": { | ||||||
|  |         "device_version": "6.2.0", | ||||||
|  |         "pid": "0x8475", | ||||||
|  |         "vid": "0x7179" | ||||||
|  |     }, | ||||||
|  |     "ws2812": { | ||||||
|  |         "driver": "pwm", | ||||||
|  |         "pin": "B15" | ||||||
|  |     }, | ||||||
|  |     "layouts": { | ||||||
|  |         "LAYOUT_all": { | ||||||
|  |             "layout": [ | ||||||
|  |                 {"label": "Esc", "matrix": [0, 0], "x": 0.75, "y": 0}, | ||||||
|  |                 {"label": "`~", "matrix": [0, 1], "x": 2.5, "y": 0}, | ||||||
|  |                 {"label": "1!", "matrix": [0, 2], "x": 3.5, "y": 0}, | ||||||
|  |                 {"label": "2@", "matrix": [0, 3], "x": 5, "y": 0}, | ||||||
|  |                 {"label": "3#", "matrix": [0, 4], "x": 6, "y": 0}, | ||||||
|  |                 {"label": "4$", "matrix": [0, 5], "x": 7, "y": 0}, | ||||||
|  |                 {"label": "5%", "matrix": [0, 6], "x": 8, "y": 0}, | ||||||
|  |                 {"label": "7&", "matrix": [0, 7], "x": 12.75, "y": 0}, | ||||||
|  |                 {"label": "8*", "matrix": [0, 8], "x": 13.75, "y": 0}, | ||||||
|  |                 {"label": "9(", "matrix": [0, 9], "x": 14.75, "y": 0}, | ||||||
|  |                 {"label": "0)", "matrix": [0, 10], "x": 15.75, "y": 0}, | ||||||
|  |                 {"label": "-_", "matrix": [0, 11], "x": 17, "y": 0}, | ||||||
|  |                 {"label": "=+", "matrix": [0, 12], "x": 18, "y": 0}, | ||||||
|  |                 {"label": "\\|", "matrix": [0, 13], "x": 19, "y": 0}, | ||||||
|  |                 {"label": "Page Up", "matrix": [1, 0], "x": 0.5, "y": 1}, | ||||||
|  |                 {"label": "Tab", "matrix": [1, 1], "x": 2.25, "y": 1, "w": 1.5}, | ||||||
|  |                 {"label": "Q", "matrix": [1, 2], "x": 3.75, "y": 1}, | ||||||
|  |                 {"label": "W", "matrix": [1, 3], "x": 5.5, "y": 1}, | ||||||
|  |                 {"label": "E", "matrix": [1, 4], "x": 6.5, "y": 1}, | ||||||
|  |                 {"label": "R", "matrix": [1, 5], "x": 7.5, "y": 1}, | ||||||
|  |                 {"label": "T", "matrix": [1, 6], "x": 8.5, "y": 1}, | ||||||
|  |                 {"label": "Y", "matrix": [1, 7], "x": 12, "y": 1}, | ||||||
|  |                 {"label": "U", "matrix": [1, 8], "x": 13, "y": 1}, | ||||||
|  |                 {"label": "I", "matrix": [1, 9], "x": 14, "y": 1}, | ||||||
|  |                 {"label": "O", "matrix": [1, 10], "x": 15, "y": 1}, | ||||||
|  |                 {"label": "P", "matrix": [1, 11], "x": 16.75, "y": 1}, | ||||||
|  |                 {"label": "[{", "matrix": [1, 12], "x": 17.75, "y": 1}, | ||||||
|  |                 {"label": "]}", "matrix": [1, 13], "x": 18.75, "y": 1}, | ||||||
|  |                 {"label": "Page Down", "matrix": [2, 0], "x": 0.25, "y": 2}, | ||||||
|  |                 {"label": "Caps Lock", "matrix": [2, 1], "x": 2.25, "y": 2, "w": 1.75}, | ||||||
|  |                 {"label": "A", "matrix": [2, 2], "x": 4, "y": 2}, | ||||||
|  |                 {"label": "S", "matrix": [2, 3], "x": 5.75, "y": 2}, | ||||||
|  |                 {"label": "D", "matrix": [2, 4], "x": 6.75, "y": 2}, | ||||||
|  |                 {"label": "F", "matrix": [2, 5], "x": 7.75, "y": 2}, | ||||||
|  |                 {"label": "G", "matrix": [2, 6], "x": 8.75, "y": 2}, | ||||||
|  |                 {"label": "H", "matrix": [2, 7], "x": 12.25, "y": 2}, | ||||||
|  |                 {"label": "J", "matrix": [2, 8], "x": 13.25, "y": 2}, | ||||||
|  |                 {"label": "K", "matrix": [2, 9], "x": 14.25, "y": 2}, | ||||||
|  |                 {"label": "L", "matrix": [2, 10], "x": 15.25, "y": 2}, | ||||||
|  |                 {"label": ";:", "matrix": [2, 11], "x": 17.25, "y": 2}, | ||||||
|  |                 {"label": "\"", "matrix": [2, 12], "x": 18.25, "y": 2}, | ||||||
|  |                 {"label": "Del", "matrix": [2, 13], "x": 20, "y": 0}, | ||||||
|  |                 {"label": "End", "matrix": [3, 0], "x": 0, "y": 3}, | ||||||
|  |                 {"label": "Shift", "matrix": [3, 1], "x": 1.5, "y": 3, "w": 2.25}, | ||||||
|  |                 {"label": "Z", "matrix": [3, 2], "x": 3.75, "y": 3}, | ||||||
|  |                 {"label": "X", "matrix": [3, 3], "x": 6, "y": 3}, | ||||||
|  |                 {"label": "C", "matrix": [3, 4], "x": 7, "y": 3}, | ||||||
|  |                 {"label": "V", "matrix": [3, 5], "x": 8, "y": 3}, | ||||||
|  |                 {"label": "B", "matrix": [3, 6], "x": 9, "y": 3}, | ||||||
|  |                 {"label": "B", "matrix": [3, 7], "x": 11.75, "y": 3}, | ||||||
|  |                 {"label": "N", "matrix": [3, 8], "x": 12.75, "y": 3}, | ||||||
|  |                 {"label": "M", "matrix": [3, 9], "x": 13.75, "y": 3}, | ||||||
|  |                 {"label": ",<", "matrix": [3, 10], "x": 14.75, "y": 3}, | ||||||
|  |                 {"label": ".>", "matrix": [3, 11], "x": 17, "y": 3}, | ||||||
|  |                 {"label": "/?", "matrix": [3, 12], "x": 18, "y": 3}, | ||||||
|  |                 {"label": "Shift", "matrix": [3, 13], "x": 19, "y": 3, "w": 1.25}, | ||||||
|  |                 {"label": "Control", "matrix": [4, 1], "x": 1.5, "y": 4, "w": 1.5}, | ||||||
|  |                 {"label": "Alt", "matrix": [4, 2], "x": 6, "y": 4, "w": 1.5}, | ||||||
|  |                 {"label": "Space", "matrix": [4, 4], "x": 7.5, "y": 4, "w": 2}, | ||||||
|  |                 {"label": "Left GUI", "matrix": [4, 5], "x": 9.5, "y": 4}, | ||||||
|  |                 {"label": "^6", "matrix": [4, 6], "x": 9, "y": 0}, | ||||||
|  |                 {"label": "Space", "matrix": [4, 7], "x": 11.25, "y": 4}, | ||||||
|  |                 {"label": "Space", "matrix": [4, 8], "x": 12.25, "y": 4, "w": 2}, | ||||||
|  |                 {"label": "Alt", "matrix": [4, 9], "x": 14.25, "y": 4, "w": 1.5}, | ||||||
|  |                 {"label": "Backspace", "matrix": [4, 10], "x": 19.75, "y": 1, "w": 1.5}, | ||||||
|  |                 {"label": "Enter", "matrix": [4, 11], "x": 19.25, "y": 2, "w": 2.25}, | ||||||
|  |                 {"label": "MO(1)", "matrix": [4, 12], "x": 20.25, "y": 3}, | ||||||
|  |                 {"label": "Control", "matrix": [4, 13], "x": 19.25, "y": 4, "w": 1.5} | ||||||
|  |             ] | ||||||
|  |         }, | ||||||
|  |         "LAYOUT_nosplits": { | ||||||
|  |             "layout": [ | ||||||
|  |                 {"label": "Esc", "matrix": [0, 0], "x": 0.75, "y": 0}, | ||||||
|  |                 {"label": "`~", "matrix": [0, 1], "x": 2.5, "y": 0}, | ||||||
|  |                 {"label": "1!", "matrix": [0, 2], "x": 3.5, "y": 0}, | ||||||
|  |                 {"label": "2@", "matrix": [0, 3], "x": 5, "y": 0}, | ||||||
|  |                 {"label": "3#", "matrix": [0, 4], "x": 6, "y": 0}, | ||||||
|  |                 {"label": "4$", "matrix": [0, 5], "x": 7, "y": 0}, | ||||||
|  |                 {"label": "5%", "matrix": [0, 6], "x": 8, "y": 0}, | ||||||
|  |                 {"label": "7&", "matrix": [0, 7], "x": 12.75, "y": 0}, | ||||||
|  |                 {"label": "8*", "matrix": [0, 8], "x": 13.75, "y": 0}, | ||||||
|  |                 {"label": "9(", "matrix": [0, 9], "x": 14.75, "y": 0}, | ||||||
|  |                 {"label": "0)", "matrix": [0, 10], "x": 15.75, "y": 0}, | ||||||
|  |                 {"label": "-_", "matrix": [0, 11], "x": 17, "y": 0}, | ||||||
|  |                 {"label": "=+", "matrix": [0, 12], "x": 18, "y": 0}, | ||||||
|  |                 {"label": "Backspace", "matrix": [0, 13], "x": 19, "y": 0, "w": 2}, | ||||||
|  |                 {"label": "Page Up", "matrix": [1, 0], "x": 0.5, "y": 1}, | ||||||
|  |                 {"label": "Tab", "matrix": [1, 1], "x": 2.25, "y": 1, "w": 1.5}, | ||||||
|  |                 {"label": "Q", "matrix": [1, 2], "x": 3.75, "y": 1}, | ||||||
|  |                 {"label": "W", "matrix": [1, 3], "x": 5.5, "y": 1}, | ||||||
|  |                 {"label": "E", "matrix": [1, 4], "x": 6.5, "y": 1}, | ||||||
|  |                 {"label": "R", "matrix": [1, 5], "x": 7.5, "y": 1}, | ||||||
|  |                 {"label": "T", "matrix": [1, 6], "x": 8.5, "y": 1}, | ||||||
|  |                 {"label": "Y", "matrix": [1, 7], "x": 12, "y": 1}, | ||||||
|  |                 {"label": "U", "matrix": [1, 8], "x": 13, "y": 1}, | ||||||
|  |                 {"label": "I", "matrix": [1, 9], "x": 14, "y": 1}, | ||||||
|  |                 {"label": "O", "matrix": [1, 10], "x": 15, "y": 1}, | ||||||
|  |                 {"label": "P", "matrix": [1, 11], "x": 16.75, "y": 1}, | ||||||
|  |                 {"label": "[{", "matrix": [1, 12], "x": 17.75, "y": 1}, | ||||||
|  |                 {"label": "]}", "matrix": [1, 13], "x": 18.75, "y": 1}, | ||||||
|  |                 {"label": "Page Down", "matrix": [2, 0], "x": 0.25, "y": 2}, | ||||||
|  |                 {"label": "Caps Lock", "matrix": [2, 1], "x": 2.25, "y": 2, "w": 1.75}, | ||||||
|  |                 {"label": "A", "matrix": [2, 2], "x": 4, "y": 2}, | ||||||
|  |                 {"label": "S", "matrix": [2, 3], "x": 5.75, "y": 2}, | ||||||
|  |                 {"label": "D", "matrix": [2, 4], "x": 6.75, "y": 2}, | ||||||
|  |                 {"label": "F", "matrix": [2, 5], "x": 7.75, "y": 2}, | ||||||
|  |                 {"label": "G", "matrix": [2, 6], "x": 8.75, "y": 2}, | ||||||
|  |                 {"label": "H", "matrix": [2, 7], "x": 12.25, "y": 2}, | ||||||
|  |                 {"label": "J", "matrix": [2, 8], "x": 13.25, "y": 2}, | ||||||
|  |                 {"label": "K", "matrix": [2, 9], "x": 14.25, "y": 2}, | ||||||
|  |                 {"label": "L", "matrix": [2, 10], "x": 15.25, "y": 2}, | ||||||
|  |                 {"label": ";:", "matrix": [2, 11], "x": 17.25, "y": 2}, | ||||||
|  |                 {"label": "\"", "matrix": [2, 12], "x": 18.25, "y": 2}, | ||||||
|  |                 {"label": "End", "matrix": [3, 0], "x": 0, "y": 3}, | ||||||
|  |                 {"label": "Shift", "matrix": [3, 1], "x": 1.5, "y": 3, "w": 2.25}, | ||||||
|  |                 {"label": "Z", "matrix": [3, 2], "x": 3.75, "y": 3}, | ||||||
|  |                 {"label": "X", "matrix": [3, 3], "x": 6, "y": 3}, | ||||||
|  |                 {"label": "C", "matrix": [3, 4], "x": 7, "y": 3}, | ||||||
|  |                 {"label": "V", "matrix": [3, 5], "x": 8, "y": 3}, | ||||||
|  |                 {"label": "B", "matrix": [3, 6], "x": 9, "y": 3}, | ||||||
|  |                 {"label": "B", "matrix": [3, 7], "x": 11.75, "y": 3}, | ||||||
|  |                 {"label": "N", "matrix": [3, 8], "x": 12.75, "y": 3}, | ||||||
|  |                 {"label": "M", "matrix": [3, 9], "x": 13.75, "y": 3}, | ||||||
|  |                 {"label": ",<", "matrix": [3, 10], "x": 14.75, "y": 3}, | ||||||
|  |                 {"label": ".>", "matrix": [3, 11], "x": 17, "y": 3}, | ||||||
|  |                 {"label": "/?", "matrix": [3, 12], "x": 18, "y": 3}, | ||||||
|  |                 {"label": "Shift", "matrix": [3, 13], "x": 19, "y": 3, "w": 2.25}, | ||||||
|  |                 {"label": "Control", "matrix": [4, 1], "x": 1.5, "y": 4, "w": 1.5}, | ||||||
|  |                 {"label": "Alt", "matrix": [4, 2], "x": 6, "y": 4, "w": 1.5}, | ||||||
|  |                 {"label": "Space", "matrix": [4, 4], "x": 7.5, "y": 4, "w": 3}, | ||||||
|  |                 {"label": "^6", "matrix": [4, 6], "x": 9, "y": 0}, | ||||||
|  |                 {"label": "Space", "matrix": [4, 8], "x": 11.25, "y": 4, "w": 3}, | ||||||
|  |                 {"label": "Alt", "matrix": [4, 9], "x": 14.25, "y": 4, "w": 1.5}, | ||||||
|  |                 {"label": "Backspace", "matrix": [4, 10], "x": 19.75, "y": 1, "w": 1.5}, | ||||||
|  |                 {"label": "Enter", "matrix": [4, 11], "x": 19.25, "y": 2, "w": 2.25}, | ||||||
|  |                 {"label": "Control", "matrix": [4, 13], "x": 19.25, "y": 4, "w": 1.5} | ||||||
|  |             ] | ||||||
|  |         } | ||||||
|  |     } | ||||||
|  | } | ||||||
							
								
								
									
										34
									
								
								keyboards/typek/keymaps/default/keymap.c
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										34
									
								
								keyboards/typek/keymaps/default/keymap.c
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,34 @@ | |||||||
|  | /* Copyright 2023 Gondolindrim
 | ||||||
|  |  * | ||||||
|  |  * 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 QMK_KEYBOARD_H | ||||||
|  | 
 | ||||||
|  | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||||||
|  | 
 | ||||||
|  | [0] = LAYOUT_all( /* Base */ | ||||||
|  |     KC_ESC , KC_GRV , KC_1   , KC_2   , KC_3   , KC_4   , KC_5   ,          KC_7   , KC_8   , KC_9   , KC_0   , KC_MINS, KC_EQL,  KC_BSLS, | ||||||
|  |     KC_PGUP, 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_PGDN, 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_DEL , | ||||||
|  |     MO(1)  , KC_LSFT, KC_Z   , KC_X   , KC_C   , KC_V   , KC_B   ,          KC_B   , KC_N   , KC_M   , KC_COMM, KC_DOT , KC_SLSH, KC_RSFT, | ||||||
|  |              KC_LCTL, KC_LALT,          KC_SPC , KC_LGUI, KC_6   ,          KC_SPC , KC_SPC , KC_RALT, KC_BSPC, KC_ENT , MO(1)  , KC_RCTL | ||||||
|  | ), | ||||||
|  | [1] = LAYOUT_all( | ||||||
|  |     QK_BOOT, 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_HOME, KC_TRNS, KC_TRNS, KC_UP  , KC_TRNS, KC_TRNS, KC_TRNS,          KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, | ||||||
|  |     KC_END , KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_TRNS, KC_TRNS,          KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, | ||||||
|  |     KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,          KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, | ||||||
|  |              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/typek/mcuconf.h
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								keyboards/typek/mcuconf.h
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,21 @@ | |||||||
|  | /* Copyright 2020 QMK
 | ||||||
|  |  * | ||||||
|  |  * 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_next <mcuconf.h> | ||||||
|  | 
 | ||||||
|  | #undef STM32_PWM_USE_TIM1 | ||||||
|  | #define STM32_PWM_USE_TIM1 TRUE | ||||||
							
								
								
									
										30
									
								
								keyboards/typek/readme.md
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										30
									
								
								keyboards/typek/readme.md
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,30 @@ | |||||||
|  | # gok TypeK QMK Firmware Folder | ||||||
|  | 
 | ||||||
|  |  | ||||||
|  | 
 | ||||||
|  | ## Introduction | ||||||
|  | 
 | ||||||
|  | This is the QMK Firmware repository for the Type K, the tented ergo by Gok. The TypeK went through GB on August, 2023. It is supported by a proprietary PCB ecosystem. | ||||||
|  | 
 | ||||||
|  | ## How to flash | ||||||
|  | 
 | ||||||
|  | ### Enter bootloader | ||||||
|  | 
 | ||||||
|  | The DFU state in the bootloader can be accessed in 3 ways: | ||||||
|  | 
 | ||||||
|  | * **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key, escape in the default keymap) and plug in the keyboard; | ||||||
|  | * **Physical reset button**: press the button on the front of the PCB, next to caps lock, for at least five seconds; | ||||||
|  | * **Keycode in layout**: Press the key mapped to `RESET`; in the default layout, that is top left key ('escape') in layer 1. | ||||||
|  | 
 | ||||||
|  | ### How to compile and flash | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | After setting up your build environment, you can compile the Iron 165R2 default keymap by using one of the options below. | ||||||
|  | 
 | ||||||
|  |     make typek:default | ||||||
|  | 
 | ||||||
|  | And use dfu-util in the command line or through a GUI like QMK toolbox to upload the firmware to the PCB. To directly flash the PCB after it is put into a DFU state, use: | ||||||
|  | 
 | ||||||
|  |     make typek:default:flash | ||||||
|  | 
 | ||||||
|  | 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). | ||||||
							
								
								
									
										44
									
								
								keyboards/typek/typek.c
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										44
									
								
								keyboards/typek/typek.c
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,44 @@ | |||||||
|  | /* Copyright 2023 Gondolindrim <gondolindrim@acheronproject.com>
 | ||||||
|  |  * | ||||||
|  |  * 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 "quantum.h" | ||||||
|  | 
 | ||||||
|  | // This function gets called when caps, num, scroll change
 | ||||||
|  | bool led_update_kb(led_t led_state) { | ||||||
|  |     bool res = led_update_user(led_state); | ||||||
|  |     if (res) { | ||||||
|  |         led_state.caps_lock? rgblight_setrgb_at(RGB_RED, 0) : rgblight_setrgb_at(RGB_OFF, 0); | ||||||
|  |     } | ||||||
|  |     return res; | ||||||
|  | } | ||||||
|  | 
 | ||||||
|  | // This function is called when layers change
 | ||||||
|  | layer_state_t layer_state_set_kb(layer_state_t state) { | ||||||
|  |     state = layer_state_set_user(state); | ||||||
|  |     switch(get_highest_layer(state)) { | ||||||
|  |         case 1:    | ||||||
|  |             rgblight_setrgb_at(RGB_GREEN, 1); | ||||||
|  |             break; | ||||||
|  |         case 2:    | ||||||
|  |             rgblight_setrgb_at(RGB_BLUE, 2); | ||||||
|  |             break; | ||||||
|  |         default: | ||||||
|  |             rgblight_setrgb_at(RGB_OFF, 1); | ||||||
|  |             rgblight_setrgb_at(RGB_OFF, 2); | ||||||
|  |             break; | ||||||
|  |     } | ||||||
|  |     return state; | ||||||
|  | } | ||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user