aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--keyboards/handwired/prime_exl/config.h24
-rw-r--r--keyboards/handwired/prime_exl/keymaps/default/keymap.c42
-rw-r--r--keyboards/handwired/prime_exl/keymaps/via/keymap.c101
-rw-r--r--keyboards/handwired/prime_exl/keymaps/via/readme.md1
-rw-r--r--keyboards/handwired/prime_exl/keymaps/via/rules.mk86
-rw-r--r--keyboards/handwired/prime_exl/prime_exl.c3
-rw-r--r--keyboards/handwired/prime_exl/prime_exl.h6
-rw-r--r--keyboards/primekb/prime_e/config.h72
-rw-r--r--keyboards/primekb/prime_e/info.json16
-rw-r--r--keyboards/primekb/prime_e/keymaps/default/keymap.c74
-rw-r--r--keyboards/primekb/prime_e/keymaps/default/readme.md2
-rw-r--r--keyboards/primekb/prime_e/keymaps/via/keymap.c73
-rw-r--r--keyboards/primekb/prime_e/keymaps/via/readme.md2
-rw-r--r--keyboards/primekb/prime_e/keymaps/via/rules.mk85
-rw-r--r--keyboards/primekb/prime_e/prime_e.c22
-rw-r--r--keyboards/primekb/prime_e/prime_e.h34
-rw-r--r--keyboards/primekb/prime_e/readme.md16
-rw-r--r--keyboards/primekb/prime_e/rules.mk80
18 files changed, 712 insertions, 27 deletions
diff --git a/keyboards/handwired/prime_exl/config.h b/keyboards/handwired/prime_exl/config.h
index 948d6312b..3201a8247 100644
--- a/keyboards/handwired/prime_exl/config.h
+++ b/keyboards/handwired/prime_exl/config.h
@@ -20,8 +20,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
20#include "config_common.h" 20#include "config_common.h"
21 21
22/* USB Device descriptor parameter */ 22/* USB Device descriptor parameter */
23#define VENDOR_ID 0xFEED 23#define VENDOR_ID 0x5052
24#define PRODUCT_ID 0x4024 24#define PRODUCT_ID 0x6578
25#define DEVICE_VER 0x0001 25#define DEVICE_VER 0x0001
26#define MANUFACTURER PrimeKB 26#define MANUFACTURER PrimeKB
27#define PRODUCT Prime_EXL 27#define PRODUCT Prime_EXL
@@ -49,3 +49,23 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
49#define LOCKING_SUPPORT_ENABLE 49#define LOCKING_SUPPORT_ENABLE
50/* Locking resynchronize hack */ 50/* Locking resynchronize hack */
51#define LOCKING_RESYNC_ENABLE 51#define LOCKING_RESYNC_ENABLE
52
53#define DYNAMIC_KEYMAP_LAYER_COUNT 4
54
55// EEPROM usage
56
57// TODO: refactor with new user EEPROM code (coming soon)
58#define EEPROM_MAGIC 0x451F
59#define EEPROM_MAGIC_ADDR 32
60// Bump this every time we change what we store
61// This will automatically reset the EEPROM with defaults
62// and avoid loading invalid data from the EEPROM
63#define EEPROM_VERSION 0x08
64#define EEPROM_VERSION_ADDR 34
65
66// Dynamic keymap starts after EEPROM version
67#define DYNAMIC_KEYMAP_EEPROM_ADDR 35
68// Dynamic macro starts after dynamic keymaps (35+(4*10*9*2)) = (35+720)
69#define DYNAMIC_KEYMAP_MACRO_EEPROM_ADDR 755
70#define DYNAMIC_KEYMAP_MACRO_EEPROM_SIZE 269 // 1024-DYNAMIC_KEYMAP_MACRO_EEPROM_ADDR
71#define DYNAMIC_KEYMAP_MACRO_COUNT 16 \ No newline at end of file
diff --git a/keyboards/handwired/prime_exl/keymaps/default/keymap.c b/keyboards/handwired/prime_exl/keymaps/default/keymap.c
index 0e1c60d4a..815090bd1 100644
--- a/keyboards/handwired/prime_exl/keymaps/default/keymap.c
+++ b/keyboards/handwired/prime_exl/keymaps/default/keymap.c
@@ -37,7 +37,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
37 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_TRNS, 37 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_TRNS,
38 BL_TOGG, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS 38 BL_TOGG, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
39 ), 39 ),
40 40
41 [2] = LAYOUT( 41 [2] = LAYOUT(
42 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_F9, KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC, 42 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_F9, KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
43 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT, 43 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT,
@@ -45,7 +45,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
45 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LCTL, KC_LALT, KC_LBRC, KC_RBRC, MO(5), KC_SPC, KC_MINS, KC_EQL, KC_LGUI, MO(4), 45 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LCTL, KC_LALT, KC_LBRC, KC_RBRC, MO(5), KC_SPC, KC_MINS, KC_EQL, KC_LGUI, MO(4),
46 KC_LCTL, KC_LALT, TO(0), KC_P, KC_H, KC_SPC 46 KC_LCTL, KC_LALT, TO(0), KC_P, KC_H, KC_SPC
47 ), 47 ),
48 48
49 [3] = LAYOUT( 49 [3] = LAYOUT(
50 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_TRNS, 50 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_TRNS,
51 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, 51 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
@@ -53,7 +53,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
53 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, 53 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
54 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS 54 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
55 ), 55 ),
56 56
57 [4] = LAYOUT( 57 [4] = LAYOUT(
58 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, 58 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12,
59 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, 59 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
@@ -61,7 +61,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
61 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, 61 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
62 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS 62 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
63 ), 63 ),
64 64
65 [5] = LAYOUT( 65 [5] = LAYOUT(
66 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_TRNS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, KC_DEL, 66 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_TRNS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, KC_DEL,
67 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_SCLN, KC_BSLS, 67 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_SCLN, KC_BSLS,
@@ -96,14 +96,14 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
96 96
97void matrix_init_user(void) { 97void matrix_init_user(void) {
98 // set CapsLock LED to output and low 98 // set CapsLock LED to output and low
99 DDRC |= (1 << 6); 99 setPinOutput(C6);
100 PORTC &= ~(1 << 6); 100 writePinHigh(C6);
101 // set NumLock LED to output and low 101 // set NumLock LED to output and low
102 DDRB |= (1 << 6); 102 setPinOutput(B6);
103 PORTB &= ~(1 << 6); 103 writePinHigh(B6);
104 // set ScrollLock LED to output and low 104 // set ScrollLock LED to output and low
105 DDRB |= (1 << 5); 105 setPinOutput(B5);
106 PORTB &= ~(1 << 5); 106 writePinHigh(B5);
107} 107}
108 108
109void matrix_scan_user(void) { 109void matrix_scan_user(void) {
@@ -112,21 +112,21 @@ void matrix_scan_user(void) {
112 112
113 113
114void led_set_user(uint8_t usb_led) { 114void led_set_user(uint8_t usb_led) {
115 if (usb_led & (1<<USB_LED_NUM_LOCK)) { 115 if (IS_LED_ON(usb_led, USB_LED_NUM_LOCK)) {
116 PORTB |= (1<<6); 116 writePinLow(B6);
117 } else { 117 } else {
118 PORTB &= ~(1<<6); 118 writePinHigh(B6);
119 } 119 }
120 if (usb_led & (1<<USB_LED_CAPS_LOCK)) { 120 if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) {
121 PORTB |= (1<<5); 121 writePinLow(B5);
122 } else { 122 } else {
123 PORTB &= ~(1<<5); 123 writePinHigh(B5);
124 } 124 }
125 /* 125 /*
126 if (usb_led & (1<<USB_LED_SCROLL_LOCK)) { 126 if (IS_LED_ON(usb_led, USB_LED_SCROLL_LOCK)) {
127 PORTC |= (1<<6); 127 writePinLow(C6);
128 } else { 128 } else {
129 PORTC &= ~(1<<6); 129 writePinHigh(C6);
130 } 130 }
131 */ 131 */
132} 132}
@@ -135,9 +135,9 @@ void led_set_user(uint8_t usb_led) {
135uint32_t layer_state_set_user(uint32_t state) 135uint32_t layer_state_set_user(uint32_t state)
136{ 136{
137 if (biton32(state) == 2) { 137 if (biton32(state) == 2) {
138 PORTC |= (1<<6); 138 writePinLow(C6);
139 } else { 139 } else {
140 PORTC &= ~(1<<6); 140 writePinHigh(C6);
141 } 141 }
142 return state; 142 return state;
143} 143}
diff --git a/keyboards/handwired/prime_exl/keymaps/via/keymap.c b/keyboards/handwired/prime_exl/keymaps/via/keymap.c
new file mode 100644
index 000000000..4a2631c36
--- /dev/null
+++ b/keyboards/handwired/prime_exl/keymaps/via/keymap.c
@@ -0,0 +1,101 @@
1/* Copyright 2018 Holten Campbell
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#include QMK_KEYBOARD_H
17
18
19
20const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
21 LAYOUT(
22 KC_NLCK, KC_LPRN, KC_RPRN, KC_PSLS, KC_PAST, KC_BSPC, KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
23 KC_F1, KC_F2, KC_P7, KC_P8, KC_P9, KC_DEL, KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT,
24 KC_F3, KC_F4, KC_P4, KC_P5, KC_P6, KC_PMNS, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, MO(3), KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LSFT,
25 KC_F5, KC_F6, KC_P1, KC_P2, KC_P3, KC_PPLS, KC_LCTL, KC_LALT, KC_LBRC, KC_RBRC, MO(2), KC_SPC, KC_MINS, KC_EQL, KC_LGUI, MO(3),
26 KC_F7, KC_F8, MO(1), KC_PDOT, KC_P0, KC_PENT
27 ),
28
29 LAYOUT(
30 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_F9, KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_BSPC,
31 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT,
32 KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, MO(3), KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LSFT,
33 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_LCTL, KC_LALT, KC_LBRC, KC_RBRC, MO(2), KC_SPC, KC_MINS, KC_EQL, KC_LGUI, MO(3),
34 KC_LCTL, KC_LALT, TO(0), KC_P, KC_H, KC_SPC
35 ),
36
37 LAYOUT(
38 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_TRNS, KC_TRNS, KC_UP, KC_TRNS, KC_TRNS, KC_DEL,
39 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_CAPS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_LEFT, KC_DOWN, KC_RGHT, KC_SCLN, KC_BSLS,
40 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
41 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_VOLD, KC_VOLU, KC_MUTE, KC_TRNS,
42 BL_TOGG, BL_STEP, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
43 ),
44
45 LAYOUT(
46 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_TRNS,
47 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
48 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
49 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
50 KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
51 )
52};
53
54
55void matrix_init_user(void) {
56 // set CapsLock LED to output and low
57 setPinOutput(C6);
58 writePinHigh(C6);
59 // set NumLock LED to output and low
60 setPinOutput(B6);
61 writePinHigh(B6);
62 // set ScrollLock LED to output and low
63 setPinOutput(B5);
64 writePinHigh(B5);
65}
66
67void matrix_scan_user(void) {
68
69}
70
71
72void led_set_user(uint8_t usb_led) {
73 if (IS_LED_ON(usb_led, USB_LED_NUM_LOCK)) {
74 writePinLow(B6);
75 } else {
76 writePinHigh(B6);
77 }
78 if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) {
79 writePinLow(B5);
80 } else {
81 writePinHigh(B5);
82 }
83 /*
84 if (IS_LED_ON(usb_led, USB_LED_SCROLL_LOCK)) {
85 writePinLow(C6);
86 } else {
87 writePinHigh(C6);
88 }
89 */
90}
91
92//function for layer indicator LED
93uint32_t layer_state_set_user(uint32_t state)
94{
95 if (biton32(state) == 2) {
96 writePinLow(C6);
97 } else {
98 writePinHigh(C6);
99 }
100 return state;
101}
diff --git a/keyboards/handwired/prime_exl/keymaps/via/readme.md b/keyboards/handwired/prime_exl/keymaps/via/readme.md
new file mode 100644
index 000000000..c2278bd46
--- /dev/null
+++ b/keyboards/handwired/prime_exl/keymaps/via/readme.md
@@ -0,0 +1 @@
# The default keymap for prime_exl \ No newline at end of file
diff --git a/keyboards/handwired/prime_exl/keymaps/via/rules.mk b/keyboards/handwired/prime_exl/keymaps/via/rules.mk
new file mode 100644
index 000000000..e726a8a0e
--- /dev/null
+++ b/keyboards/handwired/prime_exl/keymaps/via/rules.mk
@@ -0,0 +1,86 @@
1# MCU name
2MCU = atmega32u4
3
4# Processor frequency.
5# This will define a symbol, F_CPU, in all source code files equal to the
6# processor frequency in Hz. You can then use this symbol in your source code to
7# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
8# automatically to create a 32-bit value in your source code.
9#
10# This will be an integer division of F_USB below, as it is sourced by
11# F_USB after it has run through any CPU prescalers. Note that this value
12# does not *change* the processor frequency - it should merely be updated to
13# reflect the processor speed set externally so that the code can use accurate
14# software delays.
15F_CPU = 16000000
16
17
18#
19# LUFA specific
20#
21# Target architecture (see library "Board Types" documentation).
22ARCH = AVR8
23
24# Input clock frequency.
25# This will define a symbol, F_USB, in all source code files equal to the
26# input clock frequency (before any prescaling is performed) in Hz. This value may
27# differ from F_CPU if prescaling is used on the latter, and is required as the
28# raw input clock is fed directly to the PLL sections of the AVR for high speed
29# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
30# at the end, this will be done automatically to create a 32-bit value in your
31# source code.
32#
33# If no clock division is performed on the input clock inside the AVR (via the
34# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
35F_USB = $(F_CPU)
36
37# Interrupt driven control endpoint task(+60)
38OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
39
40
41# Bootloader selection
42# Teensy halfkay
43# Pro Micro caterina
44# Atmel DFU atmel-dfu
45# LUFA DFU lufa-dfu
46# QMK DFU qmk-dfu
47# atmega32a bootloadHID
48BOOTLOADER = atmel-dfu
49
50
51# If you don't know the bootloader type, then you can specify the
52# Boot Section Size in *bytes* by uncommenting out the OPT_DEFS line
53# Teensy halfKay 512
54# Teensy++ halfKay 1024
55# Atmel DFU loader 4096
56# LUFA bootloader 4096
57# USBaspLoader 2048
58# OPT_DEFS += -DBOOTLOADER_SIZE=4096
59
60
61# Build Options
62# change yes to no to disable
63#
64BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
65MOUSEKEY_ENABLE = no # Mouse keys(+4700)
66EXTRAKEY_ENABLE = yes # Audio control and System control(+450)
67CONSOLE_ENABLE = no # Console for debug(+400)
68COMMAND_ENABLE = no # Commands for debug and configuration
69# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
70SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
71# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
72NKRO_ENABLE = yes # USB Nkey Rollover
73BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality on B7 by default
74RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
75MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
76UNICODE_ENABLE = no # Unicode
77BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
78AUDIO_ENABLE = no # Audio output on port C6
79FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
80HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
81
82# This is the VIA magic
83RAW_ENABLE = yes
84DYNAMIC_KEYMAP_ENABLE = yes
85SRC += keyboards/wilba_tech/wt_main.c
86
diff --git a/keyboards/handwired/prime_exl/prime_exl.c b/keyboards/handwired/prime_exl/prime_exl.c
index d088f6ad1..bae606ffb 100644
--- a/keyboards/handwired/prime_exl/prime_exl.c
+++ b/keyboards/handwired/prime_exl/prime_exl.c
@@ -14,7 +14,7 @@
14 * along with this program. If not, see <http://www.gnu.org/licenses/>. 14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */ 15 */
16#include "prime_exl.h" 16#include "prime_exl.h"
17 17/*
18void matrix_init_kb(void) { 18void matrix_init_kb(void) {
19 // put your keyboard start-up code here 19 // put your keyboard start-up code here
20 // runs once when the firmware starts up 20 // runs once when the firmware starts up
@@ -41,3 +41,4 @@ void led_set_kb(uint8_t usb_led) {
41 41
42 led_set_user(usb_led); 42 led_set_user(usb_led);
43} 43}
44*/ \ No newline at end of file
diff --git a/keyboards/handwired/prime_exl/prime_exl.h b/keyboards/handwired/prime_exl/prime_exl.h
index 727db5db8..03524da3c 100644
--- a/keyboards/handwired/prime_exl/prime_exl.h
+++ b/keyboards/handwired/prime_exl/prime_exl.h
@@ -13,8 +13,8 @@
13 * You should have received a copy of the GNU General Public License 13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>. 14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */ 15 */
16#ifndef PRIME_EXL_H 16//#ifndef PRIME_EXL_H
17#define PRIME_EXL_H 17//#define PRIME_EXL_H
18 18
19#include "quantum.h" 19#include "quantum.h"
20 20
@@ -37,4 +37,4 @@
37 { K090, K091, K092, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO } \ 37 { K090, K091, K092, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO } \
38} 38}
39 39
40#endif \ No newline at end of file 40//#endif \ No newline at end of file
diff --git a/keyboards/primekb/prime_e/config.h b/keyboards/primekb/prime_e/config.h
new file mode 100644
index 000000000..331993f4b
--- /dev/null
+++ b/keyboards/primekb/prime_e/config.h
@@ -0,0 +1,72 @@
1/*
2Copyright 2019 Holten Campbell
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#include "config_common.h"
21
22/* USB Device descriptor parameter */
23#define VENDOR_ID 0x5052
24#define PRODUCT_ID 0x0051
25#define DEVICE_VER 0x0001
26#define MANUFACTURER PrimeKB
27#define PRODUCT Prime_E
28#define DESCRIPTION Ergo_45
29
30/* key matrix size */
31#define MATRIX_ROWS 4
32#define MATRIX_COLS 13
33
34/* Keyboard Matrix Assignments */
35#define MATRIX_ROW_PINS { E6, C7, B5, B4 }
36#define MATRIX_COL_PINS { F0, F1, F4, F5, F6, F7, D6, D4, D5, D3, D2, D1, D0 }
37#define UNUSED_PINS
38
39/* COL2ROW, ROW2COL, or CUSTOM_MATRIX */
40#define DIODE_DIRECTION COL2ROW
41
42#define BACKLIGHT_PIN B7
43#define BACKLIGHT_LEVELS 5
44
45
46/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
47#define DEBOUNCING_DELAY 5
48
49/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
50#define LOCKING_SUPPORT_ENABLE
51/* Locking resynchronize hack */
52#define LOCKING_RESYNC_ENABLE
53
54#define DYNAMIC_KEYMAP_LAYER_COUNT 4
55
56// EEPROM usage
57
58// TODO: refactor with new user EEPROM code (coming soon)
59#define EEPROM_MAGIC 0x451F
60#define EEPROM_MAGIC_ADDR 32
61// Bump this every time we change what we store
62// This will automatically reset the EEPROM with defaults
63// and avoid loading invalid data from the EEPROM
64#define EEPROM_VERSION 0x08
65#define EEPROM_VERSION_ADDR 34
66
67// Dynamic keymap starts after EEPROM version
68#define DYNAMIC_KEYMAP_EEPROM_ADDR 35
69// Dynamic macro starts after dynamic keymaps (35+(4*13*4*2)) = (35+416)
70#define DYNAMIC_KEYMAP_MACRO_EEPROM_ADDR 451
71#define DYNAMIC_KEYMAP_MACRO_EEPROM_SIZE 573 // 1024-DYNAMIC_KEYMAP_MACRO_EEPROM_ADDR
72#define DYNAMIC_KEYMAP_MACRO_COUNT 16
diff --git a/keyboards/primekb/prime_e/info.json b/keyboards/primekb/prime_e/info.json
new file mode 100644
index 000000000..0cca27565
--- /dev/null
+++ b/keyboards/primekb/prime_e/info.json
@@ -0,0 +1,16 @@
1{
2 "keyboard_name": "Prime_E",
3 "url": "https://www.primekb.com",
4 "maintainer": "holtenc",
5 "width": 13,
6 "height": 4,
7 "layouts": {
8 "LAYOUT": {
9 "layout": [{"x":0,"y":0,"w":1,"h":1}, {"x":1,"y":0,"w":1,"h":1}, {"x":2,"y":0,"w":1,"h":1}, {"x":3,"y":0,"w":1,"h":1}, {"x":4,"y":0,"w":1,"h":1}, {"x":5,"y":0,"w":1,"h":1}, {"x":7,"y":0,"w":1,"h":1}, {"x":8,"y":0,"w":1,"h":1}, {"x":9,"y":0,"w":1,"h":1}, {"x":10,"y":0,"w":1,"h":1}, {"x":11,"y":0,"w":1,"h":1}, {"x":12,"y":0,"w":1,"h":1}, {"x":13,"y":0,"w":1,"h":1},
10 {"x":0,"y":1,"w":1.25,"h":1}, {"x":1.25,"y":1,"w":1,"h":1}, {"x":2.25,"y":1,"w":1,"h":1}, {"x":3.25,"y":1,"w":1,"h":1}, {"x":4.25,"y":1,"w":1,"h":1}, {"x":5.25,"y":1,"w":1,"h":1}, {"x":7.25,"y":1,"w":1,"h":1}, {"x":8.25,"y":1,"w":1,"h":1}, {"x":9.25,"y":1,"w":1,"h":1}, {"x":10.25,"y":1,"w":1,"h":1}, {"x":11.25,"y":1,"w":1,"h":1}, {"x":12.25,"y":1,"w":1.75,"h":1},
11 {"x":0,"y":2,"w":1.75,"h":1}, {"x":1.75,"y":2,"w":1,"h":1}, {"x":2.75,"y":2,"w":1,"h":1}, {"x":3.75,"y":2,"w":1,"h":1}, {"x":4.75,"y":2,"w":1,"h":1}, {"x":5.75,"y":2,"w":1,"h":1}, {"x":6.75,"y":2,"w":1,"h":1}, {"x":7.75,"y":2,"w":1,"h":1}, {"x":8.75,"y":2,"w":1,"h":1}, {"x":9.75,"y":2,"w":1,"h":1}, {"x":10.75,"y":2,"w":1,"h":1}, {"x":11.75,"y":2,"w":1,"h":1}, {"x":12.75,"y":2,"w":1.25,"h":1},
12 {"x":0,"y":3,"w":1.25,"h":1}, {"x":1.25,"y":3,"w":1.25,"h":1}, {"x":3.5,"y":3,"w":1.25,"h":1}, {"x":4.75,"y":3,"w":2,"h":1}, {"x":6.75,"y":3,"w":2.25,"h":1}, {"x":9,"y":3,"w":1.25,"h":1}, {"x":11.5,"y":3,"w":1.25,"h":1}, {"x":12.75,"y":3,"w":1.25,"h":1}
13 ]
14 }
15 }
16}
diff --git a/keyboards/primekb/prime_e/keymaps/default/keymap.c b/keyboards/primekb/prime_e/keymaps/default/keymap.c
new file mode 100644
index 000000000..47692c541
--- /dev/null
+++ b/keyboards/primekb/prime_e/keymaps/default/keymap.c
@@ -0,0 +1,74 @@
1/* Copyright 2018 Holten Campbell
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#include QMK_KEYBOARD_H
17
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19 LAYOUT(
20 KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_BSPC,
21 KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT,
22 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, MO(1), KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LSFT,
23 KC_LCTL, KC_LALT, KC_RBRC, MO(1), KC_SPC, KC_MINS, KC_LGUI, TO(1)
24 )
25
26};
27
28void matrix_init_user(void) {
29 // set CapsLock LED to output and low
30 setPinOutput(B1);
31 writePinHigh(B1);
32 // set NumLock LED to output and low
33 setPinOutput(B2);
34 writePinHigh(B2);
35 // set ScrollLock LED to output and low
36 setPinOutput(B3);
37 writePinHigh(B3);
38}
39
40void matrix_scan_user(void) {
41
42}
43
44
45void led_set_user(uint8_t usb_led) {
46 if (IS_LED_ON(usb_led, USB_LED_NUM_LOCK)) {
47 writePinLow(B2);
48 } else {
49 writePinHigh(B2);
50 }
51 if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) {
52 writePinLow(B1);
53 } else {
54 writePinHigh(B1);
55 }
56/*
57 if (IS_LED_ON(usb_led, USB_LED_SCROLL_LOCK)) {
58 writePinLow(B3);
59 } else {
60 writePinHigh(B3);
61 }*/
62
63}
64
65//function for layer indicator LED
66uint32_t layer_state_set_user(uint32_t state)
67{
68 if (biton32(state) == 1) {
69 writePinLow(B3);
70 } else {
71 writePinHigh(B3);
72 }
73 return state;
74}
diff --git a/keyboards/primekb/prime_e/keymaps/default/readme.md b/keyboards/primekb/prime_e/keymaps/default/readme.md
new file mode 100644
index 000000000..5266526ee
--- /dev/null
+++ b/keyboards/primekb/prime_e/keymaps/default/readme.md
@@ -0,0 +1,2 @@
1# The default keymap for Prime_E
2This is the default keymap for Prime_E. \ No newline at end of file
diff --git a/keyboards/primekb/prime_e/keymaps/via/keymap.c b/keyboards/primekb/prime_e/keymaps/via/keymap.c
new file mode 100644
index 000000000..9cc3e2f3d
--- /dev/null
+++ b/keyboards/primekb/prime_e/keymaps/via/keymap.c
@@ -0,0 +1,73 @@
1/* Copyright 2018 Holten Campbell
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#include QMK_KEYBOARD_H
17
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19 LAYOUT(
20 KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_DEL, KC_BSPC,
21 KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_QUOT, KC_ENT,
22 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, MO(1), KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_LSFT,
23 KC_LCTL, KC_LALT, KC_RBRC, MO(1), KC_SPC, KC_MINS, KC_LGUI, TO(1)
24 )
25};
26
27void matrix_init_user(void) {
28 // set CapsLock LED to output and low
29 setPinOutput(B1);
30 writePinHigh(B1);
31 // set NumLock LED to output and low
32 setPinOutput(B2);
33 writePinHigh(B2);
34 // set ScrollLock LED to output and low
35 setPinOutput(B3);
36 writePinHigh(B3);
37}
38
39void matrix_scan_user(void) {
40
41}
42
43
44void led_set_user(uint8_t usb_led) {
45 if (IS_LED_ON(usb_led, USB_LED_NUM_LOCK)) {
46 writePinLow(B2);
47 } else {
48 writePinHigh(B2);
49 }
50 if (IS_LED_ON(usb_led, USB_LED_CAPS_LOCK)) {
51 writePinLow(B1);
52 } else {
53 writePinHigh(B1);
54 }
55/*
56 if (IS_LED_ON(usb_led, USB_LED_SCROLL_LOCK)) {
57 writePinLow(B3);
58 } else {
59 writePinHigh(B3);
60 }*/
61
62}
63
64//function for layer indicator LED
65uint32_t layer_state_set_user(uint32_t state)
66{
67 if (biton32(state) == 1) {
68 writePinLow(B3);
69 } else {
70 writePinHigh(B3);
71 }
72 return state;
73}
diff --git a/keyboards/primekb/prime_e/keymaps/via/readme.md b/keyboards/primekb/prime_e/keymaps/via/readme.md
new file mode 100644
index 000000000..bbd56c0cc
--- /dev/null
+++ b/keyboards/primekb/prime_e/keymaps/via/readme.md
@@ -0,0 +1,2 @@
1# The VIA keymap for Prime_E
2This keymap is for compatibility with the VIA configurator. \ No newline at end of file
diff --git a/keyboards/primekb/prime_e/keymaps/via/rules.mk b/keyboards/primekb/prime_e/keymaps/via/rules.mk
new file mode 100644
index 000000000..93b2e70e7
--- /dev/null
+++ b/keyboards/primekb/prime_e/keymaps/via/rules.mk
@@ -0,0 +1,85 @@
1# MCU name
2MCU = atmega32u4
3
4# Processor frequency.
5# This will define a symbol, F_CPU, in all source code files equal to the
6# processor frequency in Hz. You can then use this symbol in your source code to
7# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
8# automatically to create a 32-bit value in your source code.
9#
10# This will be an integer division of F_USB below, as it is sourced by
11# F_USB after it has run through any CPU prescalers. Note that this value
12# does not *change* the processor frequency - it should merely be updated to
13# reflect the processor speed set externally so that the code can use accurate
14# software delays.
15F_CPU = 16000000
16
17
18#
19# LUFA specific
20#
21# Target architecture (see library "Board Types" documentation).
22ARCH = AVR8
23
24# Input clock frequency.
25# This will define a symbol, F_USB, in all source code files equal to the
26# input clock frequency (before any prescaling is performed) in Hz. This value may
27# differ from F_CPU if prescaling is used on the latter, and is required as the
28# raw input clock is fed directly to the PLL sections of the AVR for high speed
29# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
30# at the end, this will be done automatically to create a 32-bit value in your
31# source code.
32#
33# If no clock division is performed on the input clock inside the AVR (via the
34# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
35F_USB = $(F_CPU)
36
37# Interrupt driven control endpoint task(+60)
38OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
39
40
41# Bootloader selection
42# Teensy halfkay
43# Pro Micro caterina
44# Atmel DFU atmel-dfu
45# LUFA DFU lufa-dfu
46# QMK DFU qmk-dfu
47# atmega32a bootloadHID
48BOOTLOADER = atmel-dfu
49
50
51# If you don't know the bootloader type, then you can specify the
52# Boot Section Size in *bytes* by uncommenting out the OPT_DEFS line
53# Teensy halfKay 512
54# Teensy++ halfKay 1024
55# Atmel DFU loader 4096
56# LUFA bootloader 4096
57# USBaspLoader 2048
58# OPT_DEFS += -DBOOTLOADER_SIZE=4096
59
60
61# Build Options
62# change yes to no to disable
63#
64BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000)
65MOUSEKEY_ENABLE = no # Mouse keys(+4700)
66EXTRAKEY_ENABLE = no # Audio control and System control(+450)
67CONSOLE_ENABLE = no # Console for debug(+400)
68COMMAND_ENABLE = no # Commands for debug and configuration
69# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
70SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
71# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
72NKRO_ENABLE = yes # USB Nkey Rollover
73BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality on B7 by default
74RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
75MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
76UNICODE_ENABLE = no # Unicode
77BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
78AUDIO_ENABLE = no # Audio output on port C6
79FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
80HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400)
81
82# This is the VIA magic
83RAW_ENABLE = yes
84DYNAMIC_KEYMAP_ENABLE = yes
85SRC += keyboards/wilba_tech/wt_main.c \ No newline at end of file
diff --git a/keyboards/primekb/prime_e/prime_e.c b/keyboards/primekb/prime_e/prime_e.c
new file mode 100644
index 000000000..bd51ce008
--- /dev/null
+++ b/keyboards/primekb/prime_e/prime_e.c
@@ -0,0 +1,22 @@
1/* Copyright 2019 Holten Campbell
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#include "prime_e.h"
17
18void led_set_kb(uint8_t usb_led) {
19 // put your keyboard LED indicator (ex: Caps Lock LED) toggling code here
20
21 led_set_user(usb_led);
22}
diff --git a/keyboards/primekb/prime_e/prime_e.h b/keyboards/primekb/prime_e/prime_e.h
new file mode 100644
index 000000000..4af70fbe1
--- /dev/null
+++ b/keyboards/primekb/prime_e/prime_e.h
@@ -0,0 +1,34 @@
1/* Copyright 2019 Holten Campbell
2 *
3 * This program is free software: you can redistribute it and/or modify
4 * it under the terms of the GNU General Public License as published by
5 * the Free Software Foundation, either version 2 of the License, or
6 * (at your option) any later version.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16
17
18#pragma once
19
20#include "quantum.h"
21
22
23#define LAYOUT( \
24 K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012, \
25 K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K112, \
26 K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212, \
27 K300, K301, K303, K304, K306, K308, K311, K312 \
28) { \
29 { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, K012 }, \
30 { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, KC_NO, K112 }, \
31 { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, K212 }, \
32 { K300, K301, KC_NO, K303, K304, KC_NO, K306, KC_NO, K308, KC_NO, KC_NO, K311, K312 } \
33}
34
diff --git a/keyboards/primekb/prime_e/readme.md b/keyboards/primekb/prime_e/readme.md
new file mode 100644
index 000000000..6abe0bed0
--- /dev/null
+++ b/keyboards/primekb/prime_e/readme.md
@@ -0,0 +1,16 @@
1# Prime_E
2
3![Prime_E](https://imgur.com/7Rl4JOA.jpg)
4
5An ergonomic 45%.
6
7Keyboard Maintainer: [Holtenc](https://github.com/holtenc/)
8Hardware Supported: Prime_E PCB, ATMega32u4
9Hardware Availability: Group Buy, Retail
10
11Make example for this keyboard (after setting up your build environment):
12
13 make prime_e:default
14 make prime_e:via (when using VIA configurator)
15
16See 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).
diff --git a/keyboards/primekb/prime_e/rules.mk b/keyboards/primekb/prime_e/rules.mk
new file mode 100644
index 000000000..313bf3b3e
--- /dev/null
+++ b/keyboards/primekb/prime_e/rules.mk
@@ -0,0 +1,80 @@
1# MCU name
2MCU = atmega32u4
3
4# Processor frequency.
5# This will define a symbol, F_CPU, in all source code files equal to the
6# processor frequency in Hz. You can then use this symbol in your source code to
7# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
8# automatically to create a 32-bit value in your source code.
9#
10# This will be an integer division of F_USB below, as it is sourced by
11# F_USB after it has run through any CPU prescalers. Note that this value
12# does not *change* the processor frequency - it should merely be updated to
13# reflect the processor speed set externally so that the code can use accurate
14# software delays.
15F_CPU = 16000000
16
17
18#
19# LUFA specific
20#
21# Target architecture (see library "Board Types" documentation).
22ARCH = AVR8
23
24# Input clock frequency.
25# This will define a symbol, F_USB, in all source code files equal to the
26# input clock frequency (before any prescaling is performed) in Hz. This value may
27# differ from F_CPU if prescaling is used on the latter, and is required as the
28# raw input clock is fed directly to the PLL sections of the AVR for high speed
29# clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'
30# at the end, this will be done automatically to create a 32-bit value in your
31# source code.
32#
33# If no clock division is performed on the input clock inside the AVR (via the
34# CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.
35F_USB = $(F_CPU)
36
37# Interrupt driven control endpoint task(+60)
38OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT
39
40
41# Bootloader selection
42# Teensy halfkay
43# Pro Micro caterina
44# Atmel DFU atmel-dfu
45# LUFA DFU lufa-dfu
46# QMK DFU qmk-dfu
47# atmega32a bootloadHID
48BOOTLOADER = atmel-dfu
49
50
51# If you don't know the bootloader type, then you can specify the
52# Boot Section Size in *bytes* by uncommenting out the OPT_DEFS line
53# Teensy halfKay 512
54# Teensy++ halfKay 1024
55# Atmel DFU loader 4096
56# LUFA bootloader 4096
57# USBaspLoader 2048
58# OPT_DEFS += -DBOOTLOADER_SIZE=4096
59
60
61# Build Options
62# change yes to no to disable
63#
64BOOTMAGIC_ENABLE = yes # Virtual DIP switch configuration(+1000)
65MOUSEKEY_ENABLE = no # Mouse keys(+4700)
66EXTRAKEY_ENABLE = no # Audio control and System control(+450)
67CONSOLE_ENABLE = no # Console for debug(+400)
68COMMAND_ENABLE = no # Commands for debug and configuration
69# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
70SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
71# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
72NKRO_ENABLE = yes # USB Nkey Rollover
73BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality on B7 by default
74RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
75MIDI_ENABLE = no # MIDI support (+2400 to 4200, depending on config)
76UNICODE_ENABLE = no # Unicode
77BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID
78AUDIO_ENABLE = no # Audio output on port C6
79FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches
80HD44780_ENABLE = no # Enable support for HD44780 based LCDs (+400) \ No newline at end of file