summaryrefslogtreecommitdiff
path: root/keyboards
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards')
-rw-r--r--keyboards/polycarbdiet/readme.md6
-rw-r--r--keyboards/polycarbdiet/s20/config.h61
-rw-r--r--keyboards/polycarbdiet/s20/info.json88
-rw-r--r--keyboards/polycarbdiet/s20/keymaps/default/keymap.c47
-rw-r--r--keyboards/polycarbdiet/s20/keymaps/default/readme.md1
-rw-r--r--keyboards/polycarbdiet/s20/readme.md27
-rw-r--r--keyboards/polycarbdiet/s20/rules.mk23
-rw-r--r--keyboards/polycarbdiet/s20/s20.c17
-rw-r--r--keyboards/polycarbdiet/s20/s20.h61
9 files changed, 331 insertions, 0 deletions
diff --git a/keyboards/polycarbdiet/readme.md b/keyboards/polycarbdiet/readme.md
new file mode 100644
index 0000000000..c928ebed57
--- /dev/null
+++ b/keyboards/polycarbdiet/readme.md
@@ -0,0 +1,6 @@
+# polycarbdiet
+QMK folder for custom PCB firmware.
+
+Github: polycarbdiet
+Discord: polycarb_diet
+Reddit: u/polycarb_diet
diff --git a/keyboards/polycarbdiet/s20/config.h b/keyboards/polycarbdiet/s20/config.h
new file mode 100644
index 0000000000..58f998e767
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/config.h
@@ -0,0 +1,61 @@
+/* Copyright 2020 Muhammad Galib (polycarbdiet) <pd.keyboards@gmail.com>
+
+This program is free software: you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation, either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+#pragma once
+
+#include "config_common.h"
+
+/* USB Device descriptor parameter */
+#define VENDOR_ID 0x5040 // PD = polycarbdiet
+#define PRODUCT_ID 0x7320 // S20
+#define DEVICE_VER 0x0001
+#define MANUFACTURER polycarbdiet
+#define PRODUCT S20
+
+/* key matrix size */
+#define MATRIX_ROWS 5
+#define MATRIX_COLS 4
+
+// 1 2 3 4 5
+#define MATRIX_ROW_PINS { B7, E6, D0, D1, D5 }
+#define MATRIX_COL_PINS { C6, C7, D4, D6 }
+#define UNUSED_PINS
+
+/* COL2ROW, ROW2COL */
+#define DIODE_DIRECTION ROW2COL
+
+#define BACKLIGHT_PIN B6
+#define BACKLIGHT_LEVELS 3
+#define BACKLIGHT_BREATHING
+
+#define RGB_DI_PIN B3
+#define RGBLED_NUM 4
+#define RGBLIGHT_HUE_STEP 8
+#define RGBLIGHT_SAT_STEP 8
+#define RGBLIGHT_VAL_STEP 8
+#define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
+#define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
+
+#define RGBLIGHT_ANIMATIONS
+
+#define DEBOUNCE 5
+
+/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
+#define LOCKING_SUPPORT_ENABLE
+/* Locking resynchronize hack */
+#define LOCKING_RESYNC_ENABLE
+
+#define FORCE_NKRO
diff --git a/keyboards/polycarbdiet/s20/info.json b/keyboards/polycarbdiet/s20/info.json
new file mode 100644
index 0000000000..32407beea2
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/info.json
@@ -0,0 +1,88 @@
+{
+ "keyboard_name": "S20 revA",
+ "url": "",
+ "maintainer": "polycarbdiet",
+ "width": 4,
+ "height": 5,
+ "layouts": {
+ "LAYOUT_ortho_5x4": {
+ "layout": [
+ {"x":0, "y":0},
+ {"x":1, "y":0},
+ {"x":2, "y":0},
+ {"x":3, "y":0},
+
+ {"x":0, "y":1},
+ {"x":1, "y":1},
+ {"x":2, "y":1},
+ {"x":3, "y":1},
+
+ {"x":0, "y":2},
+ {"x":1, "y":2},
+ {"x":2, "y":2},
+ {"x":3, "y":2},
+
+ {"x":0, "y":3},
+ {"x":1, "y":3},
+ {"x":2, "y":3},
+ {"x":3, "y":3},
+
+ {"x":0, "y":4},
+ {"x":1, "y":4},
+ {"x":2, "y":4},
+ {"x":3, "y":4}
+ ]
+ },
+ "LAYOUT_numpad_5x4":{
+ "layout": [
+ {"x":0, "y":0},
+ {"x":1, "y":0},
+ {"x":2, "y":0},
+ {"x":3, "y":0},
+
+ {"x":0, "y":1},
+ {"x":1, "y":1},
+ {"x":2, "y":1},
+
+ {"x":0, "y":2},
+ {"x":1, "y":2},
+ {"x":2, "y":2},
+ {"x":3, "y":1, "h":2},
+ {"x":0, "y":3},
+ {"x":1, "y":3},
+ {"x":2, "y":3},
+
+ {"x":0, "y":4, "w":2},
+ {"x":2, "y":4},
+ {"x":3, "y":3, "h":2}
+ ]
+ },
+ "LAYOUT_enter": {
+ "layout": [
+ {"x":0, "y":0},
+ {"x":1, "y":0},
+ {"x":2, "y":0},
+ {"x":3, "y":0},
+
+ {"x":0, "y":1},
+ {"x":1, "y":1},
+ {"x":2, "y":1},
+ {"x":3, "y":1},
+
+ {"x":0, "y":2},
+ {"x":1, "y":2},
+ {"x":2, "y":2},
+ {"x":3, "y":2},
+
+ {"x":0, "y":3},
+ {"x":1, "y":3},
+ {"x":2, "y":3},
+ {"x":3, "y":3, "h":2},
+
+ {"x":0, "y":4},
+ {"x":1, "y":4},
+ {"x":2, "y":4}
+ ]
+ }
+ }
+}
diff --git a/keyboards/polycarbdiet/s20/keymaps/default/keymap.c b/keyboards/polycarbdiet/s20/keymaps/default/keymap.c
new file mode 100644
index 0000000000..b399202062
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/keymaps/default/keymap.c
@@ -0,0 +1,47 @@
+/* Copyright 2020 Muhammad Galib (polycarbdiet) <pd.keyboards@gmail.com>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+#include QMK_KEYBOARD_H
+
+const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
+ [0] = LAYOUT_ortho_5x4(
+ KC_ESC, KC_PAST, KC_PSLS, KC_BSPC,
+ KC_P7, KC_P8, KC_P9, KC_PMNS,
+ KC_P4, KC_P5, KC_P6, KC_PPLS,
+ KC_P1, KC_P2, KC_P3, KC_PENT,
+ KC_P0, KC_PDOT, MO(1), RGB_TOG
+ ),
+ [1] = LAYOUT_ortho_5x4(
+ KC_NLCK, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_MPRV, KC_MPLY, KC_MNXT, KC_TRNS,
+ KC_VOLD, KC_MUTE, KC_VOLU, KC_TRNS,
+ RESET, MO(2), KC_TRNS, KC_TRNS
+ ),
+ [2] = LAYOUT_ortho_5x4(
+ RGB_TOG, RGB_HUI, RGB_SAI, RGB_VAI,
+ RGB_MOD, RGB_HUD, RGB_SAD, RGB_VAD,
+ BL_TOGG, BL_ON, BL_INC, BL_STEP,
+ KC_TRNS, BL_OFF, BL_DEC, BL_BRTG,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
+ ),
+ [3] = LAYOUT_ortho_5x4(
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS
+ )
+};
diff --git a/keyboards/polycarbdiet/s20/keymaps/default/readme.md b/keyboards/polycarbdiet/s20/keymaps/default/readme.md
new file mode 100644
index 0000000000..81c2266b4b
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/keymaps/default/readme.md
@@ -0,0 +1 @@
+# The default keymap for S20
diff --git a/keyboards/polycarbdiet/s20/readme.md b/keyboards/polycarbdiet/s20/readme.md
new file mode 100644
index 0000000000..7eb2927716
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/readme.md
@@ -0,0 +1,27 @@
+# S20
+
+![S20](https://i.imgur.com/RvOACqR.jpg?1)
+
+The S20 keyboard is a FR4 sandwich keyboard which was orginally designed to add extra functionality to a user's current keyboard setup.
+
+* Keyboard Maintainer: [polycarbdiet](https://github.com/polycarbdiet)
+* Hardware Supported: S20 - FR4 sandwich MacroPad/NumberPad
+* Hardware Availability: Custom, limitied quantaties.
+
+Make example for this keyboard (after setting up your build environment):
+
+ make polycarbdiet/s20:default
+
+Flashing example for this keyboard:
+
+ make polycarbdiet/s20:default:flash
+
+**Reset Method:**
+- Press the `RESET` button on the under side of the PCB
+
+**Bootloader Method:**
+- Hold down the key located at `K00`, commonly programmed as `ESC`, while plugging in the keyboard.
+- Hold down the key located at `K00`, commonly programmed as `ESC`, and press the RESET button on the PCB.
+- Hold down the key located at `K42` and then press the key located at `K40`.
+
+See the [build environment setup](https://docs.qmk.fm/#/getting_started_build_tools) and the [make instructions](https://docs.qmk.fm/#/getting_started_make_guide) for more information. Brand new to QMK? Start with our [Complete Newbs Guide](https://docs.qmk.fm/#/newbs).
diff --git a/keyboards/polycarbdiet/s20/rules.mk b/keyboards/polycarbdiet/s20/rules.mk
new file mode 100644
index 0000000000..152430af9b
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/rules.mk
@@ -0,0 +1,23 @@
+# MCU name
+MCU = atmega32u4
+
+# Bootloader selection
+BOOTLOADER = atmel-dfu
+
+# Build Options
+
+BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration
+MOUSEKEY_ENABLE = yes # Mouse keys
+EXTRAKEY_ENABLE = yes # Audio control and System control
+CONSOLE_ENABLE = no # Console for debug
+COMMAND_ENABLE = no # Commands for debug and configuration
+# Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE
+SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend
+# if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work
+NKRO_ENABLE = yes # USB Nkey Rollover
+BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
+RGBLIGHT_ENABLE = yes # Enable keyboard RGB underglow
+BLUETOOTH_ENABLE = no # Enable Bluetooth
+AUDIO_ENABLE = no # Audio output
+
+LAYOUTS = ortho_5x4 numpad_5x4
diff --git a/keyboards/polycarbdiet/s20/s20.c b/keyboards/polycarbdiet/s20/s20.c
new file mode 100644
index 0000000000..f7b3fa9036
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/s20.c
@@ -0,0 +1,17 @@
+/* Copyright 2020 Muhammad Galib (polycarbdiet) <pd.keyboards@gmail.com>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "s20.h"
diff --git a/keyboards/polycarbdiet/s20/s20.h b/keyboards/polycarbdiet/s20/s20.h
new file mode 100644
index 0000000000..0e3eec12e0
--- /dev/null
+++ b/keyboards/polycarbdiet/s20/s20.h
@@ -0,0 +1,61 @@
+/* Copyright 2020 Muhammad Galib (polycarbdiet) <pd.keyboards@gmail.com>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#pragma once
+
+#include "quantum.h"
+
+#define LAYOUT_ortho_5x4( \
+ K00, K01, K02, K03, \
+ K10, K11, K12, K13, \
+ K20, K21, K22, K23, \
+ K30, K31, K32, K33, \
+ K40, K41, K42, K43 \
+) { \
+ { K00, K01, K02, K03 }, \
+ { K10, K11, K12, K13 }, \
+ { K20, K21, K22, K23 }, \
+ { K30, K31, K32, K33 }, \
+ { K40, K41, K42, K43 } \
+}
+
+#define LAYOUT_numpad_5x4( \
+ K00, K01, K02, K03, \
+ K10, K11, K12, \
+ K20, K21, K22, K13, \
+ K30, K31, K32, \
+ K40, K42, K33 \
+) { \
+ { K00, K01, K02, K03 }, \
+ { K10, K11, K12, K13 }, \
+ { K20, K21, K22, KC_NO }, \
+ { K30, K31, K32, K33 }, \
+ { K40, KC_NO, K42, KC_NO } \
+}
+
+#define LAYOUT_enter( \
+ K00, K01, K02, K03, \
+ K10, K11, K12, K13, \
+ K20, K21, K22, K23, \
+ K30, K31, K32, K33, \
+ K40, K41, K42 \
+) { \
+ { K00, K01, K02, K03 }, \
+ { K10, K11, K12, K13 }, \
+ { K20, K21, K22, K23 }, \
+ { K30, K31, K32, K33 }, \
+ { K40, K41, K42, KC_NO } \
+}