aboutsummaryrefslogtreecommitdiff
path: root/keyboards/lime
diff options
context:
space:
mode:
authorHellTM <lisca94@gmail.com>2021-11-11 04:32:31 +0000
committerGitHub <noreply@github.com>2021-11-10 20:32:31 -0800
commitc48e9f9e77a8f8c722957ef306280014b098758d (patch)
tree976e882a487645f8ba9536f29c03e21797ce2cd6 /keyboards/lime
parent48eddeeea401a4ebaff8590137da01b594ba6909 (diff)
downloadqmk_firmware-c48e9f9e77a8f8c722957ef306280014b098758d.tar.gz
qmk_firmware-c48e9f9e77a8f8c722957ef306280014b098758d.zip
[Keyboard] Lime by HellTM (#14710)
Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: Ryan <fauxpark@gmail.com>
Diffstat (limited to 'keyboards/lime')
-rw-r--r--keyboards/lime/config.h20
-rw-r--r--keyboards/lime/keymaps/default/config.h22
-rw-r--r--keyboards/lime/keymaps/default/keymap.c713
-rw-r--r--keyboards/lime/keymaps/default/readme.md52
-rw-r--r--keyboards/lime/keymaps/default/rules.mk7
-rw-r--r--keyboards/lime/lib/glcdfont.c232
-rw-r--r--keyboards/lime/lime.c46
-rw-r--r--keyboards/lime/lime.h21
-rw-r--r--keyboards/lime/readme.md30
-rw-r--r--keyboards/lime/rev1/config.h68
-rw-r--r--keyboards/lime/rev1/info.json25
-rw-r--r--keyboards/lime/rev1/rev1.c38
-rw-r--r--keyboards/lime/rev1/rev1.h41
-rw-r--r--keyboards/lime/rev1/rules.mk4
-rw-r--r--keyboards/lime/rules.mk24
15 files changed, 1343 insertions, 0 deletions
diff --git a/keyboards/lime/config.h b/keyboards/lime/config.h
new file mode 100644
index 000000000..22d4f632d
--- /dev/null
+++ b/keyboards/lime/config.h
@@ -0,0 +1,20 @@
1/* Copyright 2021 HellSingCoder
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#pragma once
18
19#include "config_common.h"
20
diff --git a/keyboards/lime/keymaps/default/config.h b/keyboards/lime/keymaps/default/config.h
new file mode 100644
index 000000000..f19e25923
--- /dev/null
+++ b/keyboards/lime/keymaps/default/config.h
@@ -0,0 +1,22 @@
1 /* Copyright 2021 HellSingCoder
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#define OLED_TIMEOUT 120000
21#define OLED_BRIGHTNESS 120
22#define OLED_FONT_H "keyboards/lime/lib/glcdfont.c"
diff --git a/keyboards/lime/keymaps/default/keymap.c b/keyboards/lime/keymaps/default/keymap.c
new file mode 100644
index 000000000..f6c711597
--- /dev/null
+++ b/keyboards/lime/keymaps/default/keymap.c
@@ -0,0 +1,713 @@
1 /* Copyright 2021 HellSingCoder
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#include QMK_KEYBOARD_H
18
19#ifdef JOYSTICK_ENABLE
20# include "joystick.h"
21# include "analog.h"
22#endif
23
24enum lime_layers {
25 /* _M_XYZ = Mac Os, _W_XYZ = Win/Linux */
26 _QWERTY,
27 _COLEMAK,
28 _LOWER,
29 _RAISE,
30 _ADJUST,
31};
32
33enum custom_keycodes {
34 KC_QWERTY = SAFE_RANGE,
35 KC_COLEMAK,
36 KC_LOWER,
37 KC_RAISE,
38 KC_ADJUST,
39 KC_PRVWD,
40 KC_NXTWD,
41 KC_LSTRT,
42 KC_LEND,
43 KC_DLINE,
44 KC_BSPC_DEL,
45 KC_THUMB_SWAP,
46 KC_THUMB_LEFT,
47 KC_THUMB_RIGHT,
48 KC_JOYSTICK_DEBUG,
49};
50
51const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
52/*
53 * QWERTY
54 * ,-----------------------------------------. ,-----------------------------------------.
55 * | Esc | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | BS |
56 * |------+------+------+------+------+------| |------+------+------+------+------+------|
57 * | Tab | Q | W | E | R | T | | Y | U | I | O | P | ` |
58 * |------+------+------+------+------+------| |------+------+------+------+------+------|
59 * | Caps | A | S | D | F | G |-------. ,-------| H | J | K | L | ; | ' |
60 * |------+------+------+------+------+------| | | Mute |------+------+------+------+------+------|
61 * |LShift| Z | X | C | V | B |-------| |-------| N | M | , | . | / | \ |
62 * `-----------------------------------------/ / \ \-----------------------------------------'
63 * |Lower | LGUI | LAlt | DEL | LCTR | /Enter / \Space \ |Raise | [ | ] | - | = |
64 * | | | | | |/ / \ \ | | | | | |
65 * `----------------------------------------' '------''----------------------------------'
66 */
67
68[_QWERTY] = LAYOUT(
69 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC_DEL,
70 KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_GRV,
71 KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT,
72 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, XXXXXXX, KC_MUTE, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_BSLS,
73 KC_LOWER, KC_LGUI,KC_LALT,KC_DEL, KC_LCTRL, KC_THUMB_LEFT, KC_THUMB_RIGHT, KC_RAISE, KC_LBRC, KC_RBRC, KC_MINS, KC_EQL
74),
75
76/*
77 * COLEMAK
78 * ,-----------------------------------------. ,-----------------------------------------.
79 * | Esc | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | BS |
80 * |------+------+------+------+------+------| |------+------+------+------+------+------|
81 * | Tab | Q | W | F | P | G | | J | L | U | Y | ; | ` |
82 * |------+------+------+------+------+------| |------+------+------+------+------+------|
83 * | Caps | A | R | S | T | D |-------. ,-------| H | N | E | I | O | ' |
84 * |------+------+------+------+------+------| | | Mute |------+------+------+------+------+------|
85 * |LShift| Z | X | C | V | B |-------| |-------| K | M | , | . | / | \ |
86 * `-----------------------------------------/ / \ \-----------------------------------------'
87 * |Lower | LGUI | LAlt | DEL | LCTR | /Enter / \Space \ |Raise | [ | ] | - | = |
88 * | | | | | |/ / \ \ | | | | | |
89 * `----------------------------------------' '------''----------------------------------'
90 */
91
92[_COLEMAK] = LAYOUT(
93 KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_BSPC_DEL,
94 KC_TAB, KC_Q, KC_W, KC_F, KC_P, KC_G, KC_J, KC_L, KC_U, KC_Y, KC_SCLN, KC_GRV,
95 KC_CAPS, KC_A, KC_R, KC_S, KC_T, KC_D, KC_H, KC_N, KC_E, KC_I, KC_O, KC_QUOT,
96 KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, XXXXXXX, KC_MUTE, KC_K, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_BSLS,
97 KC_LOWER, KC_LGUI,KC_LALT,KC_DEL, KC_LCTRL, KC_THUMB_LEFT, KC_THUMB_RIGHT, KC_RAISE, KC_LBRC, KC_RBRC, KC_MINS, KC_EQL
98),
99
100/* RAISE
101 * ,-----------------------------------------. ,-----------------------------------------.
102 * | Esc | | | | | | | | | | | | |
103 * |------+------+------+------+------+------| |------+------+------+------+------+------|
104 * | Tab | Ins | Pscr | Menu | | | | | PWrd | Up | NWrd | | |
105 * |------+------+------+------+------+------| |------+------+------+------+------+------|
106 * | Caps | LAt | LCtl |LShift| | |-------. ,-------| | Left | Down | Rigth| | |
107 * |------+------+------+------+------+------| | | Mute |------+------+------+------+------+------|
108 * |LShift| | | | | |-------| |-------| | LStr | DLine| LEnd | | |
109 * `-----------------------------------------/ / \ \-----------------------------------------'
110 * |Lower | LGUI | LAlt | DEL | LCTR | /Enter / \Space \ |Raise | | | | |
111 * | | | | | |/ / \ \ | | | | | |
112 * `----------------------------------------' '------''----------------------------------'
113 */
114[_RAISE] = LAYOUT(
115 _______, _______ , _______ , _______ , _______ , _______, _______, _______ , _______ , _______ , _______ , _______,
116 _______, KC_INS, KC_PSCR, KC_APP, XXXXXXX, XXXXXXX, KC_PGUP, KC_PRVWD, KC_UP, KC_NXTWD, XXXXXXX, XXXXXXX,
117 _______, KC_LALT, KC_LCTL, KC_LSFT, XXXXXXX, XXXXXXX, KC_PGDN, KC_LEFT, KC_DOWN, KC_RGHT, XXXXXXX, XXXXXXX,
118 _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, _______, _______, XXXXXXX, KC_LSTRT, KC_DLINE, KC_LEND, XXXXXXX, XXXXXXX,
119 _______, _______, _______, _______, _______, _______, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
120),
121
122/* LOWER
123 * ,-----------------------------------------. ,-----------------------------------------.
124 * | Esc | F1 | F2 | F3 | F4 | F5 | | F6 | F7 | F8 | F9 | F10 | F11 |
125 * |------+------+------+------+------+------| |------+------+------+------+------+------|
126 * | Tab | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 0 | F12 |
127 * |------+------+------+------+------+------| |------+------+------+------+------+------|
128 * | Caps | ! | @ | # | $ | % |-------. ,-------| ^ | & | * | ( | ) | | |
129 * |------+------+------+------+------+------| | | Mute |------+------+------+------+------+------|
130 * |LShift| = | - | + | { | } |-------| |-------| [ | ] | ; | : | \ | ` |
131 * `-----------------------------------------/ / \ \-----------------------------------------'
132 * |Lower | LGUI | LAlt | DEL | LCTR | /Enter / \Space \ |Raise | | | | |
133 * | | | | | |/ / \ \ | | | | | |
134 * `----------------------------------------' '------''----------------------------------'
135 */
136[_LOWER] = LAYOUT(
137 _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11,
138 _______, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_F12,
139 _______, KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_CIRC, KC_AMPR, KC_ASTR, KC_LPRN, KC_RPRN, KC_PIPE,
140 _______, KC_EQL, KC_MINS, KC_PLUS, KC_LCBR, KC_RCBR, _______, _______, KC_LBRC, KC_RBRC, KC_SCLN, KC_COLN, KC_BSLS, KC_GRV,
141 _______, _______, _______, _______, _______, _______, _______, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
142),
143
144/* ADJUST
145 * ,-----------------------------------------. ,-----------------------------------------.
146 * | RESET| | | | | | | | | | | | |
147 * |------+------+------+------+------+------| |------+------+------+------+------+------|
148 * | |QWERTY| | | | | | | | | | | |
149 * |------+------+------+------+------+------| |------+------+------+------+------+------|
150 * | | | |JDEBUG| | |-------. ,-------| | VOLDO| MUTE | VOLUP| | |
151 * |------+------+------+------+------+------| | | Mute |------+------+------+------+------+------|
152 * | | | |COLEMA| | |-------| |-------| | PREV | PLAY | NEXT | | |
153 * `-----------------------------------------/ / \ \-----------------------------------------'
154 * |Lower |MACWIN| | | | / Swap / \ \ |Raise | | | | |
155 * | | | | | |/ / \ \ | | | | | |
156 * `----------------------------------------' '------''----------------------------------'
157 */
158 [_ADJUST] = LAYOUT(
159 RESET, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
160 XXXXXXX, KC_QWERTY, XXXXXXX, XXXXXXX, CG_TOGG, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX,
161 XXXXXXX, XXXXXXX, XXXXXXX, KC_JOYSTICK_DEBUG,XXXXXXX, XXXXXXX, XXXXXXX, KC_VOLD, KC_MUTE, KC_VOLU, XXXXXXX, XXXXXXX,
162 XXXXXXX, XXXXXXX, XXXXXXX, KC_COLEMAK, XXXXXXX, XXXXXXX, XXXXXXX, _______, XXXXXXX, KC_MPRV, KC_MPLY, KC_MNXT, XXXXXXX, XXXXXXX,
163 _______, CG_TOGG, XXXXXXX, XXXXXXX, XXXXXXX, KC_THUMB_SWAP, XXXXXXX, _______, XXXXXXX, XXXXXXX, XXXXXXX, XXXXXXX
164 )
165};
166
167#ifdef JOYSTICK_ENABLE
168 /* Joystick pins */
169# ifndef JOYSTICK_X_PIN
170# define JOYSTICK_X_PIN F5
171# define JOYSTICK_Y_PIN F4
172# endif
173
174 /* Joystick + Encoder fix */
175 void keyboard_post_init_kb(void) {
176 if (is_keyboard_master()) {
177 writePinLow(JOYSTICK_X_PIN);
178 writePinLow(JOYSTICK_Y_PIN);
179 }
180 }
181
182 /* Joystick axes settings */
183 joystick_config_t joystick_axes[JOYSTICK_AXES_COUNT] = {
184 [0] = JOYSTICK_AXIS_IN(JOYSTICK_X_PIN, 268, 514, 813),
185 [1] = JOYSTICK_AXIS_IN(JOYSTICK_Y_PIN, 865, 519, 260)
186 };
187#endif
188
189/* Joystick Debug */
190bool joystick_debug = false;
191
192/* Space Enter swap */
193bool swap_space_enter = false;
194
195/* Smart Backspace Delete */
196bool shift_held = false;
197static uint16_t held_shift = 0;
198
199/* keyboard pet jump status variables */
200bool isJumping = false;
201bool showedJump = true;
202
203#ifdef OLED_ENABLE
204 /* Keyboard logo (from gdlcfont.c) */
205 static void render_logo(void) {
206 static const char PROGMEM lime_logo[] = {
207 0x80, 0x81, 0x82, 0x83, 0x84,
208 0xA0, 0xA1, 0xA2, 0xA3, 0xA4,
209 0xC0, 0xC1, 0xC2, 0xC3, 0xC4, 0
210 };
211
212 oled_write_P(lime_logo, false);
213 }
214
215 /* Keyboard Pet settings */
216 #define MIN_WALK_SPEED 10
217 #define MIN_RUN_SPEED 50
218 #define ANIM_FRAME_DURATION 200 // how long each frame lasts in ms
219 #define ANIM_SIZE 96 // number of bytes per image
220
221 /* Keyboard Pet status variables */
222 led_t led_usb_state;
223 uint8_t current_wpm = 0;
224 uint8_t current_frame = 0;
225 uint32_t anim_timer = 0;
226 uint32_t anim_sleep = 0;
227
228 /* Keyboard Pet logic */
229 static void render_keyboard_pet(int KEYBOARD_PET_X, int KEYBOARD_PET_Y) {
230
231 /* Sit */
232 static const char PROGMEM sit[2][ANIM_SIZE] = {
233 {
234 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1c,
235 0x02, 0x05, 0x02, 0x24, 0x04, 0x04, 0x02, 0xa9, 0x1e, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
236 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x10, 0x08, 0x68, 0x10, 0x08, 0x04, 0x03, 0x00, 0x00,
237 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x06, 0x82, 0x7c, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
238 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x04, 0x0c, 0x10, 0x10, 0x20, 0x20, 0x20, 0x28,
239 0x3e, 0x1c, 0x20, 0x20, 0x3e, 0x0f, 0x11, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
240 },
241 {
242 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1c,
243 0x02, 0x05, 0x02, 0x24, 0x04, 0x04, 0x02, 0xa9, 0x1e, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
244 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x90, 0x08, 0x18, 0x60, 0x10, 0x08, 0x04, 0x03, 0x00, 0x00,
245 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0e, 0x82, 0x7c, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
246 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x04, 0x0c, 0x10, 0x10, 0x20, 0x20, 0x20, 0x28,
247 0x3e, 0x1c, 0x20, 0x20, 0x3e, 0x0f, 0x11, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
248 }
249 };
250
251 /* Walk */
252 static const char PROGMEM walk[2][ANIM_SIZE] = {
253 {
254 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x40, 0x20, 0x10, 0x90, 0x90, 0x90, 0xa0, 0xc0, 0x80, 0x80,
255 0x80, 0x70, 0x08, 0x14, 0x08, 0x90, 0x10, 0x10, 0x08, 0xa4, 0x78, 0x80, 0x00, 0x00, 0x00, 0x00,
256 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x08, 0xfc, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00,
257 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x18, 0xea, 0x10, 0x0f, 0x00, 0x00, 0x00, 0x00,
258 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x1c, 0x20, 0x20, 0x3c, 0x0f, 0x11, 0x1f, 0x03,
259 0x06, 0x18, 0x20, 0x20, 0x3c, 0x0c, 0x12, 0x1e, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
260 },
261 {
262 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x40, 0x20, 0x20, 0x20, 0x40, 0x80, 0x00, 0x00, 0x00,
263 0x00, 0xe0, 0x10, 0x28, 0x10, 0x20, 0x20, 0x20, 0x10, 0x48, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00,
264 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x20, 0xf8, 0x02, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
265 0x03, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x10, 0x30, 0xd5, 0x20, 0x1f, 0x00, 0x00, 0x00, 0x00,
266 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x20, 0x30, 0x0c, 0x02, 0x05, 0x09, 0x12, 0x1e,
267 0x02, 0x1c, 0x14, 0x08, 0x10, 0x20, 0x2c, 0x32, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
268 }
269 };
270
271 /* Run */
272 static const char PROGMEM run[2][ANIM_SIZE] = {
273 {
274 0x00, 0x00, 0x00, 0x00, 0xe0, 0x10, 0x08, 0x08, 0xc8, 0xb0, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80,
275 0x80, 0x40, 0x40, 0x3c, 0x14, 0x04, 0x08, 0x90, 0x18, 0x04, 0x08, 0xb0, 0x40, 0x80, 0x00, 0x00,
276 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0xc4, 0xa4, 0xfc, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00,
277 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xc8, 0x58, 0x28, 0x2a, 0x10, 0x0f, 0x00, 0x00,
278 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x09, 0x04, 0x04, 0x04, 0x04, 0x02, 0x03, 0x02, 0x01, 0x01,
279 0x02, 0x02, 0x04, 0x08, 0x10, 0x26, 0x2b, 0x32, 0x04, 0x05, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00
280 },
281 {
282 0x00, 0x00, 0x00, 0xe0, 0x10, 0x10, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80,
283 0x80, 0x80, 0x78, 0x28, 0x08, 0x10, 0x20, 0x30, 0x08, 0x10, 0x20, 0x40, 0x80, 0x00, 0x00, 0x00,
284 0x00, 0x00, 0x00, 0x03, 0x04, 0x08, 0x10, 0x11, 0xf9, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00,
285 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x10, 0xb0, 0x50, 0x55, 0x20, 0x1f, 0x00, 0x00,
286 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x0c, 0x10, 0x20, 0x28, 0x37,
287 0x02, 0x1e, 0x20, 0x20, 0x18, 0x0c, 0x14, 0x1e, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
288 }
289 };
290
291 /* Bark */
292 static const char PROGMEM bark[2][ANIM_SIZE] = {
293 {
294 0x00, 0xc0, 0x20, 0x10, 0xd0, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x40,
295 0x3c, 0x14, 0x04, 0x08, 0x90, 0x18, 0x04, 0x08, 0xb0, 0x40, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00,
296 0x00, 0x03, 0x04, 0x08, 0x10, 0x11, 0xf9, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00,
297 0x00, 0x00, 0x00, 0x00, 0x80, 0xc8, 0x48, 0x28, 0x2a, 0x10, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00,
298 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x0c, 0x10, 0x20, 0x28, 0x37, 0x02, 0x02,
299 0x04, 0x08, 0x10, 0x26, 0x2b, 0x32, 0x04, 0x05, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
300 },
301 {
302 0x00, 0xe0, 0x10, 0x10, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x80, 0x40,
303 0x40, 0x2c, 0x14, 0x04, 0x08, 0x90, 0x18, 0x04, 0x08, 0xb0, 0x40, 0x80, 0x00, 0x00, 0x00, 0x00,
304 0x00, 0x03, 0x04, 0x08, 0x10, 0x11, 0xf9, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00,
305 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xc0, 0x48, 0x28, 0x2a, 0x10, 0x0f, 0x20, 0x4a, 0x09, 0x10,
306 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x0c, 0x10, 0x20, 0x28, 0x37, 0x02, 0x02,
307 0x04, 0x08, 0x10, 0x26, 0x2b, 0x32, 0x04, 0x05, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
308 }
309 };
310
311 /* animation */
312 void animate_keyboard_pet(void) {
313
314 /* jump */
315 if (isJumping || !showedJump) {
316 oled_set_cursor(KEYBOARD_PET_X,KEYBOARD_PET_Y +2);
317 oled_write_P(PSTR(" "), false);
318 oled_set_cursor(KEYBOARD_PET_X,KEYBOARD_PET_Y -1);
319 showedJump = true;
320 } else {
321 oled_set_cursor(KEYBOARD_PET_X,KEYBOARD_PET_Y -1);
322 oled_write_P(PSTR(" "), false);
323 oled_set_cursor(KEYBOARD_PET_X,KEYBOARD_PET_Y);
324 }
325
326 /* switch frame */
327 current_frame = (current_frame + 1) % 2;
328
329 /* current animation status */
330 if(led_usb_state.caps_lock) {
331 oled_write_raw_P(bark[abs(1 - current_frame)], ANIM_SIZE);
332 } else if(current_wpm <= MIN_WALK_SPEED) {
333 oled_write_raw_P(sit[abs(1 - current_frame)], ANIM_SIZE);
334 } else if(current_wpm <= MIN_RUN_SPEED) {
335 oled_write_raw_P(walk[abs(1 - current_frame)], ANIM_SIZE);
336 } else {
337 oled_write_raw_P(run[abs(1 - current_frame)], ANIM_SIZE);
338 }
339 }
340
341 /* animation timer */
342 if(timer_elapsed32(anim_timer) > ANIM_FRAME_DURATION) {
343 anim_timer = timer_read32();
344 if(timer_elapsed32(anim_sleep) < OLED_TIMEOUT) {
345 animate_keyboard_pet();
346 }
347 }
348
349 if (current_wpm > 0) {
350 anim_sleep = timer_read32();
351 } else if(timer_elapsed32(anim_sleep) > OLED_TIMEOUT) {
352 oled_off();
353 }
354
355 }
356
357 static void print_logo_narrow(void) {
358
359 /* Keyboard logo */
360 render_logo();
361
362 /* wpm counter */
363 char wpm_str[5];
364 wpm_str[4] = '\0';
365 wpm_str[3] = '0' + current_wpm % 10;
366 wpm_str[2] = '0' + ( current_wpm /= 10) % 10;
367 wpm_str[1] = '0' + current_wpm / 10;
368 wpm_str[0] = ' ';
369 oled_set_cursor(0,14);
370 oled_write(wpm_str, false);
371 oled_write_P(PSTR(" wpm"), false);
372 }
373
374 static void print_status_narrow(void) {
375
376 /* Print current OS */
377 oled_set_cursor(2,0);
378 if (keymap_config.swap_lctl_lgui) {
379 oled_write_P(PSTR("\x9E"), false);
380 } else {
381 oled_write_P(PSTR("\x9F"), false);
382 }
383
384 /* Print current layout */
385 oled_set_cursor(0,2);
386 switch (get_highest_layer(default_layer_state)) {
387 case _QWERTY:
388 oled_write_P(PSTR("QWRTY"), false);
389 break;
390 case _COLEMAK:
391 oled_write_P(PSTR("COLMK"), false);
392 break;
393 default:
394 oled_write_P(PSTR("UNDEF"), false);
395 }
396
397 /* Print current layer */
398 oled_set_cursor(0,4);
399 oled_write_P(PSTR("LAYER"), false);
400 oled_set_cursor(0,5);
401 switch (get_highest_layer(layer_state)) {
402 case _QWERTY:
403 oled_write_P(PSTR("Base "), false);
404 break;
405 case _RAISE:
406 oled_write_P(PSTR("Raise"), false);
407 break;
408 case _LOWER:
409 oled_write_P(PSTR("Lower"), false);
410 break;
411 case _ADJUST:
412 oled_write_P(PSTR("Adj "), false);
413 break;
414 default:
415 oled_write_P(PSTR("Undef"), false);
416 }
417
418 /* caps lock */
419 oled_set_cursor(0,7);
420 oled_write_P(PSTR("CAPS"), false);
421 if (led_usb_state.caps_lock) {
422 oled_write_P(PSTR("\x9A"), false);
423 } else {
424 oled_write_P(PSTR("\x99"), false);
425 }
426
427 /* Space Enter swap */
428 oled_set_cursor(0,9);
429 oled_write_P(PSTR("\x9B"), false);
430 oled_set_cursor(2,9);
431 oled_write_P(PSTR("\x9C"), !swap_space_enter);
432 oled_set_cursor(4,9);
433 oled_write_P(PSTR("\x9D"), swap_space_enter);
434
435 /* Joystick debugging */
436# ifdef JOYSTICK_ENABLE
437 if (joystick_debug) {
438 oled_set_cursor(0,10);
439 oled_write_P(PSTR("X:"), false);
440 uint16_t val = analogReadPin(JOYSTICK_X_PIN);
441 char val_str[3];
442 itoa(val, val_str, 10);
443 oled_write(val_str, false);
444 oled_set_cursor(0,11);
445 oled_write_P(PSTR("Y:"), false);
446 val = analogReadPin(JOYSTICK_Y_PIN);
447 itoa(val, val_str, 10);
448 oled_write(val_str, false);
449 } else {
450 oled_set_cursor(0,10);
451 oled_write_P(PSTR(" "), false);
452 oled_set_cursor(0,11);
453 oled_write_P(PSTR(" "), false);
454 }
455# endif
456
457 /* Keyboard Pet Render */
458 render_keyboard_pet(0,13);
459 }
460
461 /* vertical screens orientation fix */
462 oled_rotation_t oled_init_user(oled_rotation_t rotation) {
463 return OLED_ROTATION_270;
464 }
465
466 void oled_task_user(void) {
467
468 /* Keyboard Pet Variables */
469 current_wpm = get_current_wpm();
470 led_usb_state = host_keyboard_led_state();
471
472 if (is_keyboard_master()) {
473 print_status_narrow();
474 } else {
475 print_logo_narrow();
476 }
477 }
478
479#endif
480
481bool process_record_user(uint16_t keycode, keyrecord_t *record) {
482 switch (keycode) {
483 case KC_QWERTY:
484 if (record->event.pressed) {
485 set_single_persistent_default_layer(_QWERTY);
486 }
487 return false;
488 case KC_COLEMAK:
489 if (record->event.pressed) {
490 set_single_persistent_default_layer(_COLEMAK);
491 }
492 return false;
493 case KC_LOWER:
494 if (record->event.pressed) {
495 layer_on(_LOWER);
496 update_tri_layer(_LOWER, _RAISE, _ADJUST);
497 } else {
498 layer_off(_LOWER);
499 update_tri_layer(_LOWER, _RAISE, _ADJUST);
500 }
501 return false;
502 case KC_RAISE:
503 if (record->event.pressed) {
504 layer_on(_RAISE);
505 update_tri_layer(_LOWER, _RAISE, _ADJUST);
506 } else {
507 layer_off(_RAISE);
508 update_tri_layer(_LOWER, _RAISE, _ADJUST);
509 }
510 return false;
511 case KC_ADJUST:
512 if (record->event.pressed) {
513 layer_on(_ADJUST);
514 } else {
515 layer_off(_ADJUST);
516 }
517 return false;
518 case KC_PRVWD:
519 if (record->event.pressed) {
520 if (keymap_config.swap_lctl_lgui) {
521 register_mods(mod_config(MOD_LALT));
522 register_code(KC_LEFT);
523 } else {
524 register_mods(mod_config(MOD_LCTL));
525 register_code(KC_LEFT);
526 }
527 } else {
528 if (keymap_config.swap_lctl_lgui) {
529 unregister_mods(mod_config(MOD_LALT));
530 unregister_code(KC_LEFT);
531 } else {
532 unregister_mods(mod_config(MOD_LCTL));
533 unregister_code(KC_LEFT);
534 }
535 }
536 break;
537 case KC_NXTWD:
538 if (record->event.pressed) {
539 if (keymap_config.swap_lctl_lgui) {
540 register_mods(mod_config(MOD_LALT));
541 register_code(KC_RIGHT);
542 } else {
543 register_mods(mod_config(MOD_LCTL));
544 register_code(KC_RIGHT);
545 }
546 } else {
547 if (keymap_config.swap_lctl_lgui) {
548 unregister_mods(mod_config(MOD_LALT));
549 unregister_code(KC_RIGHT);
550 } else {
551 unregister_mods(mod_config(MOD_LCTL));
552 unregister_code(KC_RIGHT);
553 }
554 }
555 break;
556 case KC_LSTRT:
557 if (record->event.pressed) {
558 if (keymap_config.swap_lctl_lgui) {
559 /* CMD-arrow on Mac, but we have CTL and GUI swapped */
560 register_mods(mod_config(MOD_LCTL));
561 register_code(KC_LEFT);
562 } else {
563 register_code(KC_HOME);
564 }
565 } else {
566 if (keymap_config.swap_lctl_lgui) {
567 unregister_mods(mod_config(MOD_LCTL));
568 unregister_code(KC_LEFT);
569 } else {
570 unregister_code(KC_HOME);
571 }
572 }
573 break;
574 case KC_LEND:
575 if (record->event.pressed) {
576 if (keymap_config.swap_lctl_lgui) {
577 /* CMD-arrow on Mac, but we have CTL and GUI swapped */
578 register_mods(mod_config(MOD_LCTL));
579 register_code(KC_RIGHT);
580 } else {
581 register_code(KC_END);
582 }
583 } else {
584 if (keymap_config.swap_lctl_lgui) {
585 unregister_mods(mod_config(MOD_LCTL));
586 unregister_code(KC_RIGHT);
587 } else {
588 unregister_code(KC_END);
589 }
590 }
591 break;
592 case KC_DLINE:
593 if (record->event.pressed) {
594 register_mods(mod_config(MOD_LCTL));
595 register_code(KC_BSPC);
596 } else {
597 unregister_mods(mod_config(MOD_LCTL));
598 unregister_code(KC_BSPC);
599 }
600 break;
601
602 case KC_JOYSTICK_DEBUG:
603 if (record->event.pressed) {
604 joystick_debug = !joystick_debug;
605 }
606 return false;
607 break;
608
609 /* Space Enter swap */
610 case KC_THUMB_SWAP:
611 if (record->event.pressed) {
612 swap_space_enter = !swap_space_enter;
613 }
614 return false;
615 break;
616 case KC_THUMB_LEFT:
617 if (record->event.pressed) {
618 if (swap_space_enter) {
619 register_code(KC_SPC);
620
621 /*Keyboard Pet jump*/
622 isJumping = true;
623 showedJump = false;
624 } else {
625 register_code(KC_ENT);
626 }
627 } else {
628 if (swap_space_enter) {
629 unregister_code(KC_SPC);
630
631 /*Keyboard Pet jump reset*/
632 isJumping = false;
633 } else {
634 unregister_code(KC_ENT);
635 }
636 }
637 return false;
638 case KC_THUMB_RIGHT:
639 if (record->event.pressed) {
640 if (swap_space_enter) {
641 register_code(KC_ENT);
642 } else {
643 register_code(KC_SPC);
644 isJumping = true;
645 showedJump = false;
646 }
647 } else {
648 if (swap_space_enter) {
649 unregister_code(KC_ENT);
650 } else {
651 unregister_code(KC_SPC);
652 isJumping = false;
653 }
654 }
655 return false;
656
657 /* Smart Backspace Delete */
658 case KC_RSFT:
659 case KC_LSFT:
660 shift_held = record->event.pressed;
661 held_shift = keycode;
662 break;
663 case KC_BSPC_DEL:
664 if (record->event.pressed) {
665 if (shift_held) {
666 unregister_code(held_shift);
667 register_code(KC_DEL);
668 } else {
669 register_code(KC_BSPC);
670 }
671 } else {
672 unregister_code(KC_DEL);
673 unregister_code(KC_BSPC);
674 if (shift_held) {
675 register_code(held_shift);
676 }
677 }
678 return false;
679 }
680 return true;
681}
682
683/* The default rotary encoder code can be found at the bottom of qmk_firmware/keyboards/lime/rev1/rev1.c
684 * These default settings can be overriden by your own settings in your keymap.c
685 * For your convenience, here's a copy of those settings so that you can uncomment them if you wish to apply your own modifications.
686 * DO NOT edit the rev1.c file; instead override the weakly defined default functions by your own.
687 */
688
689/* DELETE THIS LINE TO UNCOMMENT (1/2)
690
691// Encoders
692#ifdef ENCODER_ENABLE
693 bool encoder_update_user(uint8_t index, bool clockwise) {
694
695 if (index == 0) {
696 if (clockwise) {
697 tap_code(KC_MNXT);
698 } else {
699 tap_code(KC_MPRV);
700 }
701 } else if (index == 1) {
702 if (clockwise) {
703 tap_code(KC_VOLU);
704 } else {
705 tap_code(KC_VOLD);
706 }
707 }
708 return false;
709 }
710#endif
711
712#endif
713DELETE THIS LINE TO UNCOMMENT (2/2) */
diff --git a/keyboards/lime/keymaps/default/readme.md b/keyboards/lime/keymaps/default/readme.md
new file mode 100644
index 000000000..006be983c
--- /dev/null
+++ b/keyboards/lime/keymaps/default/readme.md
@@ -0,0 +1,52 @@
1## Default layout
2Joystick on the left side, encoder on the right. No underglow.
3
4### Base layer
5![Base layout for Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/base-layer.png?raw=true)
6The layout can be switched for COLEMAK in the settings layer
7
8### Lower layer
9![Lower layout for Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/lower-layer.png?raw=true)
10
11### Raise layer
12![Raise layout for Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/raise-layer.png?raw=true)
13
14### Settings layer
15![Adj layout for Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/adj-layer.png?raw=true)
16
17This layer can be accessed with the following combination:
18
19![Adj layout combination for Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/buttons-layer.png?raw=true)
20
21## Extras
22
23### Keyboard Pet (Luna)
24![Adj layout for Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/luna.gif?raw=true)
25
26Luna jumps every time you hit Space and will bark at people on the internet if you activate Caps Lock!
27
28This keyboard pet reacts to your WPM counter:
29- under 10 -> sit
30- between 10 and 50 -> walk
31- over 50 -> run
32
33### Joystick
34The joystick on the left side will act as a controller for games.
35
36### Shift + Backspace = Delete
37This one is pretty self explanatory.
38
39### Space / Enter swap
40The Enter and Space functions can be swapped pressing the left thumb button from the Setting layer. The current mode will be displayed on the left display. This one may be useful to all the gamers out there!
41
42### OS Switch
43Pressing the OS button while on the settings layer will toggle the MAC / WIN mode. This corrects the behaviour of the Alt and Control modifiers. The current selection will be displayed with an icon at the top of the left display.
44
45### Media Buttons
46The right encoder controls the volume and can be pressed to mute. Extra media buttons are hidden away on the settings layer.
47
48### WPM indicator
49Current WPM will be displayed at the bottom of the right screen.
50
51### Joystick Debug
52The JDebug button on the settings layer toggles the ADC readings of the joystick pins for X and Y axis. These will be displayed on the left OLED.
diff --git a/keyboards/lime/keymaps/default/rules.mk b/keyboards/lime/keymaps/default/rules.mk
new file mode 100644
index 000000000..cc5b7ac9a
--- /dev/null
+++ b/keyboards/lime/keymaps/default/rules.mk
@@ -0,0 +1,7 @@
1OLED_ENABLE = yes
2ENCODER_ENABLE = yes
3JOYSTICK_ENABLE = yes
4JOYSTICK_DRIVER = analog
5EXTRAKEY_ENABLE = yes
6WPM_ENABLE = yes
7SRC += analog.c
diff --git a/keyboards/lime/lib/glcdfont.c b/keyboards/lime/lib/glcdfont.c
new file mode 100644
index 000000000..bfc2cef1e
--- /dev/null
+++ b/keyboards/lime/lib/glcdfont.c
@@ -0,0 +1,232 @@
1// This is the 'classic' fixed-space bitmap font for Adafruit_GFX since 1.0.
2// See gfxfont.h for newer custom bitmap font info.
3
4#include "progmem.h"
5
6// Standard ASCII 5x7 font
7const unsigned char font[] PROGMEM = {
8 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
9 0x3E, 0x5B, 0x4F, 0x5B, 0x3E, 0x00,
10 0x3E, 0x6B, 0x4F, 0x6B, 0x3E, 0x00,
11 0x1C, 0x3E, 0x7C, 0x3E, 0x1C, 0x00,
12 0x18, 0x3C, 0x7E, 0x3C, 0x18, 0x00,
13 0x1C, 0x57, 0x7D, 0x57, 0x1C, 0x00,
14 0x1C, 0x5E, 0x7F, 0x5E, 0x1C, 0x00,
15 0x00, 0x18, 0x3C, 0x18, 0x00, 0x00,
16 0xFF, 0xE7, 0xC3, 0xE7, 0xFF, 0x00,
17 0x00, 0x18, 0x24, 0x18, 0x00, 0x00,
18 0xFF, 0xE7, 0xDB, 0xE7, 0xFF, 0x00,
19 0x30, 0x48, 0x3A, 0x06, 0x0E, 0x00,
20 0x26, 0x29, 0x79, 0x29, 0x26, 0x00,
21 0x40, 0x7F, 0x05, 0x05, 0x07, 0x00,
22 0x40, 0x7F, 0x05, 0x25, 0x3F, 0x00,
23 0x5A, 0x3C, 0xE7, 0x3C, 0x5A, 0x00,
24 0x7F, 0x3E, 0x1C, 0x1C, 0x08, 0x00,
25 0x08, 0x1C, 0x1C, 0x3E, 0x7F, 0x00,
26 0x14, 0x22, 0x7F, 0x22, 0x14, 0x00,
27 0x5F, 0x5F, 0x00, 0x5F, 0x5F, 0x00,
28 0x06, 0x09, 0x7F, 0x01, 0x7F, 0x00,
29 0x00, 0x66, 0x89, 0x95, 0x6A, 0x00,
30 0x60, 0x60, 0x60, 0x60, 0x60, 0x00,
31 0x94, 0xA2, 0xFF, 0xA2, 0x94, 0x00,
32 0x08, 0x04, 0x7E, 0x04, 0x08, 0x00,
33 0x10, 0x20, 0x7E, 0x20, 0x10, 0x00,
34 0x08, 0x08, 0x2A, 0x1C, 0x08, 0x00,
35 0x08, 0x1C, 0x2A, 0x08, 0x08, 0x00,
36 0x1E, 0x10, 0x10, 0x10, 0x10, 0x00,
37 0x0C, 0x1E, 0x0C, 0x1E, 0x0C, 0x00,
38 0x30, 0x38, 0x3E, 0x38, 0x30, 0x00,
39 0x06, 0x0E, 0x3E, 0x0E, 0x06, 0x00,
40 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
41 0x00, 0x00, 0x5F, 0x00, 0x00, 0x00,
42 0x00, 0x07, 0x00, 0x07, 0x00, 0x00,
43 0x14, 0x7F, 0x14, 0x7F, 0x14, 0x00,
44 0x24, 0x2A, 0x7F, 0x2A, 0x12, 0x00,
45 0x23, 0x13, 0x08, 0x64, 0x62, 0x00,
46 0x36, 0x49, 0x56, 0x20, 0x50, 0x00,
47 0x00, 0x08, 0x07, 0x03, 0x00, 0x00,
48 0x00, 0x1C, 0x22, 0x41, 0x00, 0x00,
49 0x00, 0x41, 0x22, 0x1C, 0x00, 0x00,
50 0x2A, 0x1C, 0x7F, 0x1C, 0x2A, 0x00,
51 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00,
52 0x00, 0x80, 0x70, 0x30, 0x00, 0x00,
53 0x08, 0x08, 0x08, 0x08, 0x08, 0x00,
54 0x00, 0x00, 0x60, 0x60, 0x00, 0x00,
55 0x20, 0x10, 0x08, 0x04, 0x02, 0x00,
56 0x3E, 0x51, 0x49, 0x45, 0x3E, 0x00,
57 0x00, 0x42, 0x7F, 0x40, 0x00, 0x00,
58 0x72, 0x49, 0x49, 0x49, 0x46, 0x00,
59 0x21, 0x41, 0x49, 0x4D, 0x33, 0x00,
60 0x18, 0x14, 0x12, 0x7F, 0x10, 0x00,
61 0x27, 0x45, 0x45, 0x45, 0x39, 0x00,
62 0x3C, 0x4A, 0x49, 0x49, 0x31, 0x00,
63 0x41, 0x21, 0x11, 0x09, 0x07, 0x00,
64 0x36, 0x49, 0x49, 0x49, 0x36, 0x00,
65 0x46, 0x49, 0x49, 0x29, 0x1E, 0x00,
66 0x00, 0x00, 0x14, 0x00, 0x00, 0x00,
67 0x00, 0x40, 0x34, 0x00, 0x00, 0x00,
68 0x00, 0x08, 0x14, 0x22, 0x41, 0x00,
69 0x14, 0x14, 0x14, 0x14, 0x14, 0x00,
70 0x00, 0x41, 0x22, 0x14, 0x08, 0x00,
71 0x02, 0x01, 0x59, 0x09, 0x06, 0x00,
72 0x3E, 0x41, 0x5D, 0x59, 0x4E, 0x00,
73 0x7C, 0x12, 0x11, 0x12, 0x7C, 0x00,
74 0x7F, 0x49, 0x49, 0x49, 0x36, 0x00,
75 0x3E, 0x41, 0x41, 0x41, 0x22, 0x00,
76 0x7F, 0x41, 0x41, 0x41, 0x3E, 0x00,
77 0x7F, 0x49, 0x49, 0x49, 0x41, 0x00,
78 0x7F, 0x09, 0x09, 0x09, 0x01, 0x00,
79 0x3E, 0x41, 0x41, 0x51, 0x73, 0x00,
80 0x7F, 0x08, 0x08, 0x08, 0x7F, 0x00,
81 0x00, 0x41, 0x7F, 0x41, 0x00, 0x00,
82 0x20, 0x40, 0x41, 0x3F, 0x01, 0x00,
83 0x7F, 0x08, 0x14, 0x22, 0x41, 0x00,
84 0x7F, 0x40, 0x40, 0x40, 0x40, 0x00,
85 0x7F, 0x02, 0x1C, 0x02, 0x7F, 0x00,
86 0x7F, 0x04, 0x08, 0x10, 0x7F, 0x00,
87 0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00,
88 0x7F, 0x09, 0x09, 0x09, 0x06, 0x00,
89 0x3E, 0x41, 0x51, 0x21, 0x5E, 0x00,
90 0x7F, 0x09, 0x19, 0x29, 0x46, 0x00,
91 0x26, 0x49, 0x49, 0x49, 0x32, 0x00,
92 0x03, 0x01, 0x7F, 0x01, 0x03, 0x00,
93 0x3F, 0x40, 0x40, 0x40, 0x3F, 0x00,
94 0x1F, 0x20, 0x40, 0x20, 0x1F, 0x00,
95 0x3F, 0x40, 0x38, 0x40, 0x3F, 0x00,
96 0x63, 0x14, 0x08, 0x14, 0x63, 0x00,
97 0x03, 0x04, 0x78, 0x04, 0x03, 0x00,
98 0x61, 0x59, 0x49, 0x4D, 0x43, 0x00,
99 0x00, 0x7F, 0x41, 0x41, 0x41, 0x00,
100 0x02, 0x04, 0x08, 0x10, 0x20, 0x00,
101 0x00, 0x41, 0x41, 0x41, 0x7F, 0x00,
102 0x04, 0x02, 0x01, 0x02, 0x04, 0x00,
103 0x40, 0x40, 0x40, 0x40, 0x40, 0x00,
104 0x00, 0x03, 0x07, 0x08, 0x00, 0x00,
105 0x20, 0x54, 0x54, 0x78, 0x40, 0x00,
106 0x7F, 0x28, 0x44, 0x44, 0x38, 0x00,
107 0x38, 0x44, 0x44, 0x44, 0x28, 0x00,
108 0x38, 0x44, 0x44, 0x28, 0x7F, 0x00,
109 0x38, 0x54, 0x54, 0x54, 0x18, 0x00,
110 0x00, 0x08, 0x7E, 0x09, 0x02, 0x00,
111 0x18, 0x24, 0x24, 0x1C, 0x78, 0x00,
112 0x7F, 0x08, 0x04, 0x04, 0x78, 0x00,
113 0x00, 0x44, 0x7D, 0x40, 0x00, 0x00,
114 0x20, 0x40, 0x40, 0x3D, 0x00, 0x00,
115 0x7F, 0x10, 0x28, 0x44, 0x00, 0x00,
116 0x00, 0x41, 0x7F, 0x40, 0x00, 0x00,
117 0x7C, 0x04, 0x78, 0x04, 0x78, 0x00,
118 0x7C, 0x08, 0x04, 0x04, 0x78, 0x00,
119 0x38, 0x44, 0x44, 0x44, 0x38, 0x00,
120 0x7C, 0x18, 0x24, 0x24, 0x18, 0x00,
121 0x18, 0x24, 0x24, 0x18, 0x7C, 0x00,
122 0x7C, 0x08, 0x04, 0x04, 0x08, 0x00,
123 0x48, 0x54, 0x54, 0x54, 0x24, 0x00,
124 0x04, 0x04, 0x3F, 0x44, 0x24, 0x00,
125 0x3C, 0x40, 0x40, 0x20, 0x7C, 0x00,
126 0x1C, 0x20, 0x40, 0x20, 0x1C, 0x00,
127 0x3C, 0x40, 0x30, 0x40, 0x3C, 0x00,
128 0x44, 0x28, 0x10, 0x28, 0x44, 0x00,
129 0x4C, 0x90, 0x90, 0x90, 0x7C, 0x00,
130 0x44, 0x64, 0x54, 0x4C, 0x44, 0x00,
131 0x00, 0x08, 0x36, 0x41, 0x00, 0x00,
132 0x00, 0x00, 0x77, 0x00, 0x00, 0x00,
133 0x00, 0x41, 0x36, 0x08, 0x00, 0x00,
134 0x02, 0x01, 0x02, 0x04, 0x02, 0x00,
135 0x3C, 0x26, 0x23, 0x26, 0x3C, 0x00,
136 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
137 0x00, 0x00, 0xC0, 0x30, 0xC8, 0xF4,
138 0xEA, 0xDA, 0xBD, 0x7D, 0x83, 0x7D,
139 0xBD, 0xDA, 0xEA, 0xF4, 0xC8, 0x30,
140 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00,
141 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
142 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
143 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
144 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
145 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
146 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
147 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
148 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
149 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
150 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
151 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
152 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
153 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
154 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
155 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
156 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
157 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
158 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
159 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
160 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
161 0xF0, 0xFE, 0xF1, 0x91, 0xF6, 0xF0,
162 0xF0, 0xFC, 0xF2, 0x92, 0xFC, 0xF0,
163 0x10, 0x38, 0x54, 0x10, 0x10, 0x1E,
164 0x00, 0x7E, 0x40, 0x40, 0x40, 0x00,
165 0x00, 0x7E, 0x12, 0x12, 0x6C, 0x00,
166 0x18, 0x3C, 0x7C, 0x3A, 0x7D, 0x24,
167 0x14, 0x36, 0x00, 0x36, 0x77, 0x77,
168 0x00, 0x00, 0x00, 0x00, 0x80, 0x40,
169 0xC0, 0x00, 0x07, 0x19, 0x26, 0x5E,
170 0xAE, 0xB6, 0x7A, 0x7D, 0x82, 0x7D,
171 0x7A, 0xB6, 0xAE, 0x5E, 0x26, 0x19,
172 0x07, 0x00, 0x00, 0x00, 0x00, 0x00,
173 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
174 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
175 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
176 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
177 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
178 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
179 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
180 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
181 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
182 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
183 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
184 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
185 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
186 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
187 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
188 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
189 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
190 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
191 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
192 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
193 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
194 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
195 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
196 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
197 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
198 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
199 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
200 0x80, 0x40, 0x3C, 0x53, 0x88, 0x84,
201 0xC3, 0x60, 0x90, 0x84, 0x60, 0x30,
202 0x90, 0x70, 0x21, 0x11, 0x71, 0x81,
203 0x61, 0x50, 0xB0, 0x80, 0x00, 0x00,
204 0x30, 0xC0, 0x30, 0x00, 0x20, 0xF0,
205 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
206 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
207 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
208 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
209 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
210 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
211 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
212 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
213 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
214 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
215 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
216 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
217 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
218 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
219 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
220 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
221 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
222 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
223 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
224 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
225 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
226 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
227 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
228 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
229 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
230 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
231 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
232};
diff --git a/keyboards/lime/lime.c b/keyboards/lime/lime.c
new file mode 100644
index 000000000..bfc9ea0fa
--- /dev/null
+++ b/keyboards/lime/lime.c
@@ -0,0 +1,46 @@
1#include "lime.h"
2
3#ifdef SWAP_HANDS_ENABLE
4
5__attribute__ ((weak))
6const keypos_t PROGMEM hand_swap_config[MATRIX_ROWS][MATRIX_COLS] =
7 // The LAYOUT macro could work for this, but it was harder to figure out the
8 // identity using it.
9
10 // This is the identity layout.
11/*
12{ \
13 { {0, 0}, {1, 0}, {2, 0}, {3, 0}, {4, 0}, {5, 0} }, \
14 { {0, 1}, {1, 1}, {2, 1}, {3, 1}, {4, 1}, {5, 1} }, \
15 { {0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2}, {5, 2} }, \
16 { {0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3} }, \
17 { {0, 4}, {1, 4}, {2, 4}, {3, 4}, {4, 4}, {5, 4} }, \
18 { {0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5} }, \
19 \
20 { {0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5} }, \
21 { {0, 6}, {1, 6}, {2, 6}, {3, 6}, {4, 6}, {5, 6} }, \
22 { {0, 7}, {1, 7}, {2, 7}, {3, 7}, {4, 7}, {5, 7} }, \
23 { {0, 8}, {1, 8}, {2, 8}, {3, 8}, {4, 8}, {5, 8} }, \
24 { {0, 9}, {1, 9}, {2, 9}, {3, 9}, {4, 9}, {5, 9} }, \
25 { {0, 10}, {1, 10}, {2, 10}, {3, 10}, {4, 10}, {5, 10} }, \
26};
27*/
28
29 // This is the mirror, q <-> p, w <-> o, etc...
30{ \
31 { {0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5} }, \
32 { {0, 6}, {1, 6}, {2, 6}, {3, 6}, {4, 6}, {5, 6} }, \
33 { {0, 7}, {1, 7}, {2, 7}, {3, 7}, {4, 7}, {5, 7} }, \
34 { {0, 8}, {1, 8}, {2, 8}, {3, 8}, {4, 8}, {5, 8} }, \
35 { {0, 9}, {1, 9}, {2, 9}, {3, 9}, {4, 9}, {5, 9} }, \
36 { {0, 10}, {1, 10}, {2, 10}, {3, 10}, {4, 10}, {5, 10} }, \
37 \
38 { {0, 0}, {1, 0}, {2, 0}, {3, 0}, {4, 0}, {5, 0} }, \
39 { {0, 1}, {1, 1}, {2, 1}, {3, 1}, {4, 1}, {5, 1} }, \
40 { {0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2}, {5, 2} }, \
41 { {0, 3}, {1, 3}, {2, 3}, {3, 3}, {4, 3}, {5, 3} }, \
42 { {0, 4}, {1, 4}, {2, 4}, {3, 4}, {4, 4}, {5, 4} }, \
43 { {0, 5}, {1, 5}, {2, 5}, {3, 5}, {4, 5}, {5, 5} }, \
44};
45
46#endif
diff --git a/keyboards/lime/lime.h b/keyboards/lime/lime.h
new file mode 100644
index 000000000..97cee454b
--- /dev/null
+++ b/keyboards/lime/lime.h
@@ -0,0 +1,21 @@
1 /* Copyright 2021 HellSingCoder
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#pragma once
18
19#ifdef KEYBOARD_lime_rev1
20 #include "rev1.h"
21#endif
diff --git a/keyboards/lime/readme.md b/keyboards/lime/readme.md
new file mode 100644
index 000000000..539ae97fd
--- /dev/null
+++ b/keyboards/lime/readme.md
@@ -0,0 +1,30 @@
1# Lime Keyboard
2
3![Lime Keyboard](https://github.com/HellSingCoder/LimeKeyboard/blob/main/media/lime_keyboard.jpeg?raw=true)
4
5Lime is a 6×4+6 keys column-staggered split keyboard with encoder and joystick support. Based on [Lily58](https://github.com/kata0510/Lily58), [Corne](https://github.com/foostan/crkbd), [Helix](https://github.com/MakotoKurauchi/helix) and [Sofle](https://github.com/josefadamcik/SofleKeyboard) keyboards. This board features a reversible PCB, OLEDs, Underglow and Bluetooth support. The PCB has holes for floating or screwed mounts but can be also mounted with a gasket.
6
7The Lime keyboard was created by [HellTM](https://github.com/HellSingCoder) with the help of the QMK and custom keyboard community.
8
9Build guide and a build log not available yet
10
11* Keyboard Maintainer: [HellSingCoder](https://www.simonepellegrino.com/) (GitHub: [HellTM](https://github.com/HellSingCoder))
12* Hardware Supported: LimeKeyboard PCB, ProMicro
13* Hardware Availability: [PCB & Case Data](https://github.com/HellSingCoder/LimeKeyboard)
14
15Make example for this keyboard (after setting up your build environment):
16
17 make lime:default
18
19Flashing example for this keyboard:
20
21 make lime:default:flash
22
23Press reset button on he keyboard when asked. You can do that in 3 ways:
24* **Physical reset button**: Briefly press the button near the TRRS connector on the PCB - if you haven't installed one, short the pads instead
25* **Keycode in layout**: Press the key mapped to `RESET` (`Lower` + `Raise` + `Esc` on the default layout)
26* **Bootmagic reset**: Hold down the key at (0,0) in the matrix (usually the top left key or Escape) and plug in the keyboard
27
28Disconnect the first half, connect the second one and repeat the process.
29
30See 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/lime/rev1/config.h b/keyboards/lime/rev1/config.h
new file mode 100644
index 000000000..55c045dc6
--- /dev/null
+++ b/keyboards/lime/rev1/config.h
@@ -0,0 +1,68 @@
1 /* Copyright 2021 HellSingCoder
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#pragma once
18
19/* USB Device descriptor parameter */
20#define VENDOR_ID 0x0666
21#define PRODUCT_ID 0x2784
22#define DEVICE_VER 0x0001
23#define MANUFACTURER HellSingCoder
24#define PRODUCT Lime
25
26/* key matrix size */
27// Rows are doubled-up
28#define MATRIX_ROWS 12
29#define MATRIX_COLS 6
30
31// wiring of each half
32#define MATRIX_ROW_PINS { D4, C6, D7, E6, B4, B5 }
33#define MATRIX_COL_PINS { F6, F7, B1, B3, B2, B6 }
34#define DIODE_DIRECTION COL2ROW
35
36#define TAPPING_TERM 100
37#define DEBOUNCE 5
38
39/* encoder support */
40#ifdef ENCODER_ENABLE
41# define ENCODERS_PAD_A { F5 }
42# define ENCODERS_PAD_B { F4 }
43# define ENCODERS_PAD_A_RIGHT { F4 }
44# define ENCODERS_PAD_B_RIGHT { F5 }
45# define ENCODER_RESOLUTION 2
46#endif
47
48/* joystick support */
49#ifdef JOYSTICK_ENABLE
50# define JOYSTICK_AXES_COUNT 2
51# define JOYSTICK_BUTTON_COUNT 1
52# define JOYSTICK_AXES_RESOLUTION 8
53#endif
54
55#define TAP_CODE_DELAY 10
56
57/* communication between sides */
58#define USE_SERIAL
59#define SOFT_SERIAL_PIN D2
60
61#define NO_ACTION_MACRO
62#define NO_ACTION_FUNCTION
63#define SPLIT_USB_DETECT
64
65#ifdef WPM_ENABLE
66# define SPLIT_WPM_ENABLE
67#endif
68
diff --git a/keyboards/lime/rev1/info.json b/keyboards/lime/rev1/info.json
new file mode 100644
index 000000000..14aafb323
--- /dev/null
+++ b/keyboards/lime/rev1/info.json
@@ -0,0 +1,25 @@
1{
2 "keyboard_name": "Lime",
3 "url": "https://github.com/HellSingCoder/LimeKeyboard",
4 "maintainer": "HellSingCoder",
5 "layouts": {
6 "LAYOUT": {
7 "layout": [
8 {"label":"#", "x":3, "y":0}, {"label":"*", "x":11.5, "y":0}, {"label":"@", "x":2, "y":0.13}, {"label":"$", "x":4, "y":0.13}, {"label":"&", "x":10.5, "y":0.13},
9 {"label":"(", "x":12.5, "y":0.13}, {"label":"%", "x":5, "y":0.25}, {"label":"^", "x":9.5, "y":0.25}, {"label":"!", "x":1, "y":0.38}, {"label":")", "x":13.5, "y":0.38},
10 {"label":"Esc", "x":0, "y":0.5}, {"label":"<i class='fa fa-trash'></i>", "x":14.5, "y":0.5}, {"label":"E", "x":3, "y":1}, {"label":"I", "x":11.5, "y":1},
11 {"label":"W", "x":2, "y":1.13}, {"label":"R", "x":4, "y":1.13}, {"label":"U", "x":10.5, "y":1.13}, {"label":"O", "x":12.5, "y":1.13}, {"label":"T", "x":5, "y":1.25},
12 {"label":"Y", "x":9.5, "y":1.25}, {"label":"Q", "x":1, "y":1.38}, {"label":"P", "x":13.5, "y":1.38}, {"label":"<i class='fa fa-arrow-left'></i>", "x":0, "y":1.5},
13 {"label":"~", "x":14.5, "y":1.5}, {"label":"D", "x":3, "y":2}, {"label":"K", "x":11.5, "y":2}, {"label":"S", "x":2, "y":2.13}, {"label":"F", "x":4, "y":2.13},
14 {"label":"J", "x":10.5, "y":2.13}, {"label":"L", "x":12.5, "y":2.13}, {"label":"G", "x":5, "y":2.25}, {"label":"H", "x":9.5, "y":2.25}, {"label":"A", "x":1, "y":2.38},
15 {"label":":", "x":13.5, "y":2.38}, {"label":"<i class='fa fa-lock'></i>", "x":0, "y":2.5}, {"label":"\"", "x":14.5, "y":2.5}, {"label":"C", "x":3, "y":3},
16 {"label":"<", "x":11.5, "y":3}, {"label":"X", "x":2, "y":3.13}, {"label":"V", "x":4, "y":3.13}, {"label":"M", "x":10.5, "y":3.13}, {"label":">", "x":12.5, "y":3.13},
17 {"label":"B", "x":5, "y":3.25}, {"label":"Joystick", "x":6, "y":3.25}, {"label":"Encoder", "x":8.5, "y":3.25}, {"label":"N", "x":9.5, "y":3.25},
18 {"label":"Z", "x":1, "y":3.38}, {"label":"?", "x":13.5, "y":3.38}, {"label":"<i class='fa fa-arrow-up'></i>", "x":0, "y":3.5}, {"label":"|", "x":14.5, "y":3.5},
19 {"label":"Alt", "x":2.35, "y":4.13}, {"label":"Del", "x":3.35, "y":4.13}, {"label":"{", "x":11.15, "y":4.13}, {"label":"}", "x":12.15, "y":4.13},
20 {"label":"OS", "x":1.35, "y":4.35}, {"label":"_", "x":13.15, "y":4.38}, {"label":"Lower", "x":0.35, "y":4.5}, {"label":"+", "x":14.15, "y":4.5},
21 {"label":"Ctrl", "x":5.55, "y":2.85}, {"label":"Enter", "x":-0.4, "y":4.1, "h":1.25}, {"label":"Space", "x":-4.1, "y":3.35, "h":1.25}, {"label":"Raise", "x":8.4, "y":11.2}
22 ]
23 }
24 }
25}
diff --git a/keyboards/lime/rev1/rev1.c b/keyboards/lime/rev1/rev1.c
new file mode 100644
index 000000000..4cc560623
--- /dev/null
+++ b/keyboards/lime/rev1/rev1.c
@@ -0,0 +1,38 @@
1 /* Copyright 2021 HellSingCoder
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#include "lime.h"
18
19/* Encoders */
20#ifdef ENCODER_ENABLE
21 bool encoder_update_user(uint8_t index, bool clockwise) {
22
23 if (index == 0) {
24 if (clockwise) {
25 tap_code(KC_MNXT);
26 } else {
27 tap_code(KC_MPRV);
28 }
29 } else if (index == 1) {
30 if (clockwise) {
31 tap_code(KC_VOLU);
32 } else {
33 tap_code(KC_VOLD);
34 }
35 }
36 return false;
37 }
38#endif
diff --git a/keyboards/lime/rev1/rev1.h b/keyboards/lime/rev1/rev1.h
new file mode 100644
index 000000000..24a3f7212
--- /dev/null
+++ b/keyboards/lime/rev1/rev1.h
@@ -0,0 +1,41 @@
1 /* Copyright 2021 HellSingCoder
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#pragma once
18#include "quantum.h"
19
20#define LAYOUT( \
21 L00, L01, L02, L03, L04, L05, R00, R01, R02, R03, R04, R05, \
22 L10, L11, L12, L13, L14, L15, R10, R11, R12, R13, R14, R15, \
23 L20, L21, L22, L23, L24, L25, R20, R21, R22, R23, R24, R25, \
24 L30, L31, L32, L33, L34, L35, L50, R50, R30, R31, R32, R33, R34, R35, \
25 L40, L41, L42, L43, L44, L45, R40, R41, R42, R43, R44, R45 \
26 ) \
27 { \
28 { L00, L01, L02, L03, L04, L05 }, \
29 { L10, L11, L12, L13, L14, L15 }, \
30 { L20, L21, L22, L23, L24, L25 }, \
31 { L30, L31, L32, L33, L34, L35 }, \
32 { L40, L41, L42, L43, L44, L45 }, \
33 { L50, KC_NO, KC_NO, KC_NO, KC_NO, KC_NO }, \
34 { R05, R04, R03, R02, R01, R00 }, \
35 { R15, R14, R13, R12, R11, R10 }, \
36 { R25, R24, R23, R22, R21, R20 }, \
37 { R35, R34, R33, R32, R31, R30 }, \
38 { R45, R44, R43, R42, R41, R40 }, \
39 { KC_NO, KC_NO, KC_NO, KC_NO, KC_NO, R50 } \
40 }
41
diff --git a/keyboards/lime/rev1/rules.mk b/keyboards/lime/rev1/rules.mk
new file mode 100644
index 000000000..f83c13ac8
--- /dev/null
+++ b/keyboards/lime/rev1/rules.mk
@@ -0,0 +1,4 @@
1ENCODER_ENABLE = yes
2ENCODER_RIGHT_ENABLE = yes
3OLED_ENABLE = yes
4OLED_DRIVER = SSD1306
diff --git a/keyboards/lime/rules.mk b/keyboards/lime/rules.mk
new file mode 100644
index 000000000..b6d3c2b7d
--- /dev/null
+++ b/keyboards/lime/rules.mk
@@ -0,0 +1,24 @@
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 = no # Enable Bootmagic Lite
11MOUSEKEY_ENABLE = no # Mouse keys
12EXTRAKEY_ENABLE = no # 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
21AUDIO_ENABLE = no # Audio output
22SPLIT_KEYBOARD = yes
23SWAP_HANDS_ENABLE = yes
24DEFAULT_FOLDER = lime/rev1