aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--keyboards/cradio/config.h83
-rw-r--r--keyboards/cradio/cradio.c20
-rw-r--r--keyboards/cradio/cradio.h50
-rw-r--r--keyboards/cradio/info.json52
-rw-r--r--keyboards/cradio/keymaps/default/keymap.c51
-rw-r--r--keyboards/cradio/readme.md33
-rw-r--r--keyboards/cradio/rules.mk23
7 files changed, 312 insertions, 0 deletions
diff --git a/keyboards/cradio/config.h b/keyboards/cradio/config.h
new file mode 100644
index 000000000..2d76de6a8
--- /dev/null
+++ b/keyboards/cradio/config.h
@@ -0,0 +1,83 @@
1/* Copyright 2018-2021
2 * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
3 * David Philip Barr <@davidphilipbarr>
4 * Pierre Chevalier <pierrechevalier83@gmail.com>
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#pragma once
21
22#include "config_common.h"
23
24/* USB Device descriptor parameter */
25#define VENDOR_ID 0xC88B
26#define PRODUCT_ID 0x3988
27#define DEVICE_VER 0x0001
28#define MANUFACTURER DPB
29#define PRODUCT Cradio
30
31/* key matrix size */
32#define MATRIX_ROWS 8
33#define MATRIX_COLS 5
34
35/*
36 * Keyboard Matrix Assignments
37 *
38 * Change this to how you wired your keyboard
39 * COLS: AVR pins used for columns, left to right
40 * ROWS: AVR pins used for rows, top to bottom
41 * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
42 * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
43 * NO_DIODE = switches are directly connected to AVR pins
44 *
45*/
46#define DIRECT_PINS { \
47 { E6, F7, F6, F5, F4 }, \
48 { B1, B3, B2, B6, D3 }, \
49 { D1, D0, D4, C6, D7 }, \
50 { B4, B5, NO_PIN, NO_PIN, NO_PIN } \
51}
52
53#define DIRECT_PINS_RIGHT { \
54 { F4, F5, F6, F7, E6 }, \
55 { D3, B6, B2, B3, B1 }, \
56 { D7, C6, D4, D0, D1 }, \
57 { B5, B4, NO_PIN, NO_PIN, NO_PIN } \
58}
59
60#define UNUSED_PINS
61
62/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
63#define DEBOUNCE 5
64
65/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
66#define LOCKING_SUPPORT_ENABLE
67/* Locking resynchronize hack */
68#define LOCKING_RESYNC_ENABLE
69
70/* Serial settings */
71#define USE_SERIAL
72/* serial.c configuration for split keyboard */
73#define SOFT_SERIAL_PIN D2
74
75/* Split handedness */
76#define EE_HANDS
77
78/* Top left key on left half */
79#define BOOTMAGIC_LITE_ROW 0
80#define BOOTMAGIC_LITE_COLUMN 0
81/* Top right key on right half */
82#define BOOTMAGIC_LITE_ROW_RIGHT 4
83#define BOOTMAGIC_LITE_COLUMN_RIGHT 4
diff --git a/keyboards/cradio/cradio.c b/keyboards/cradio/cradio.c
new file mode 100644
index 000000000..6ef938122
--- /dev/null
+++ b/keyboards/cradio/cradio.c
@@ -0,0 +1,20 @@
1/* Copyright 2018-2021
2 * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
3 * David Philip Barr <@davidphilipbarr>
4 * Pierre Chevalier <pierrechevalier83@gmail.com>
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#include "cradio.h"
diff --git a/keyboards/cradio/cradio.h b/keyboards/cradio/cradio.h
new file mode 100644
index 000000000..29e81ef9b
--- /dev/null
+++ b/keyboards/cradio/cradio.h
@@ -0,0 +1,50 @@
1/* Copyright 2018-2021
2 * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
3 * David Philip Barr <@davidphilipbarr>
4 * Pierre Chevalier <pierrechevalier83@gmail.com>
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#include "quantum.h"
21
22/* This a shortcut to help you visually see your layout.
23 *
24 * The first section contains all of the arguments representing the physical
25 * layout of the board and position of the keys.
26 *
27 * The second converts the arguments into a two-dimensional array which
28 * represents the switch matrix.
29 */
30
31// readability
32#define ___ KC_NO
33
34#define LAYOUT( \
35 L01, L02, L03, L04, L05, R01, R02, R03, R04, R05, \
36 L06, L07, L08, L09, L10, R06, R07, R08, R09, R10, \
37 L11, L12, L13, L14, L15, R11, R12, R13, R14, R15, \
38 L16, L17, R16, R17 \
39 ) \
40 { \
41 { L01, L02, L03, L04, L05 }, \
42 { L06, L07, L08, L09, L10 }, \
43 { L11, L12, L13, L14, L15 }, \
44 { L16, L17, ___, ___, ___ }, \
45 { R01, R02, R03, R04, R05 }, \
46 { R06, R07, R08, R09, R10 }, \
47 { R11, R12, R13, R14, R15 }, \
48 { R16, R17, ___, ___, ___ } \
49 }
50
diff --git a/keyboards/cradio/info.json b/keyboards/cradio/info.json
new file mode 100644
index 000000000..77b611f32
--- /dev/null
+++ b/keyboards/cradio/info.json
@@ -0,0 +1,52 @@
1{
2 "keyboard_name": "Cradio",
3 "url": "https://github.com/davidphilipbarr/Sweep",
4 "maintainer": "@davidphilipbarr",
5 "layouts": {
6 "LAYOUT": {
7 "layout": [
8 {"x": 0, "y": 0.93},
9 {"x": 1, "y": 0.31},
10 {"x": 2, "y": 0},
11 {"x": 3, "y": 0.28},
12 {"x": 4, "y": 0.42},
13
14 {"x": 7, "y": 0.42},
15 {"x": 8, "y": 0.28},
16 {"x": 9, "y": 0},
17 {"x": 10, "y": 0.31},
18 {"x": 11, "y": 0.93},
19
20 {"x": 0, "y": 1.93},
21 {"x": 1, "y": 1.31},
22 {"x": 2, "y": 1},
23 {"x": 3, "y": 1.28},
24 {"x": 4, "y": 1.42},
25
26 {"x": 7, "y": 1.42},
27 {"x": 8, "y": 1.28},
28 {"x": 9, "y": 1},
29 {"x": 10, "y": 1.31},
30 {"x": 11, "y": 1.93},
31
32 {"x": 0, "y": 2.93},
33 {"x": 1, "y": 2.31},
34 {"x": 2, "y": 2},
35 {"x": 3, "y": 2.28},
36 {"x": 4, "y": 2.42},
37
38 {"x": 7, "y": 2.42},
39 {"x": 8, "y": 2.28},
40 {"x": 9, "y": 2},
41 {"x": 10, "y": 2.31},
42 {"x": 11, "y": 2.93},
43
44 {"x": 3.5, "y": 3.75},
45 {"x": 4.5, "y": 4},
46
47 {"x": 6.5, "y": 4},
48 {"x": 7.5, "y": 3.75}
49 ]
50 }
51 }
52}
diff --git a/keyboards/cradio/keymaps/default/keymap.c b/keyboards/cradio/keymaps/default/keymap.c
new file mode 100644
index 000000000..bb7e2d35e
--- /dev/null
+++ b/keyboards/cradio/keymaps/default/keymap.c
@@ -0,0 +1,51 @@
1/* Copyright 2018-2021
2 * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
3 * David Philip Barr <@davidphilipbarr>
4 * Pierre Chevalier <pierrechevalier83@gmail.com>
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#include QMK_KEYBOARD_H
21
22/* Base layer 0 layout uses home row mods. See the following guide for details:
23 * https://precondition.github.io/home-row-mods
24 */
25
26const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
27 [0] = LAYOUT(
28 KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P,
29 SFT_T(KC_A),ALT_T(KC_S),CTL_T(KC_D),GUI_T(KC_F), KC_G, KC_H, GUI_T(KC_J),CTL_T(KC_K),ALT_T(KC_L),SFT_T(KC_SCLN),
30 KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH,
31 LT(2,KC_TAB), KC_ENT, KC_SPC, LT(1,KC_BSPC)
32 ),
33 [1] = LAYOUT(
34 _______, KC_1, KC_2, KC_3, KC_VOLU, KC_HOME, KC_PGDN, KC_PGUP, KC_END, KC_DQUO,
35 _______, KC_4, KC_5, KC_6, KC_VOLD, KC_LEFT, KC_DOWN, KC_UP, KC_RGHT, KC_QUOT,
36 KC_CAPS, KC_7, KC_8, KC_9, KC_0, _______, _______, _______, _______, _______,
37 MO(3), KC_GESC, _______, _______
38 ),
39 [2] = LAYOUT(
40 _______, KC_LBRC, KC_LCBR, KC_RCBR, _______, KC_CIRC, KC_LPRN, KC_RPRN, KC_RBRC, KC_TILD,
41 KC_EXLM, KC_AT, KC_HASH, KC_DLR, KC_PERC, KC_AMPR, KC_MINS, KC_EQL, KC_BSLS, KC_GRV,
42 _______, _______, _______, _______, _______, KC_ASTR, KC_UNDS, KC_PLUS, KC_PIPE, _______,
43 _______, _______, KC_DEL, MO(3)
44 ),
45 [3] = LAYOUT(
46 _______, KC_F1, KC_F2, KC_F3, KC_F10, _______, KC_WH_U, KC_WH_D, _______, RESET,
47 _______, KC_F4, KC_F5, KC_F6, KC_F11, KC_MS_L, KC_MS_D, KC_MS_U, KC_MS_R, KC_INS,
48 _______, KC_F7, KC_F8, KC_F9, KC_F12, _______, KC_BTN1, KC_BTN2, _______, _______,
49 _______, _______, _______, _______
50 )
51};
diff --git a/keyboards/cradio/readme.md b/keyboards/cradio/readme.md
new file mode 100644
index 000000000..b8520a366
--- /dev/null
+++ b/keyboards/cradio/readme.md
@@ -0,0 +1,33 @@
1# Cradio keyboards
2
3![Cradio](https://github.com/davidphilipbarr/hypergolic/raw/main/hypergarlic/ht.png)
4
5Cradio are low-profile 34-key split-keyboards designed by [@davidphilipbarr](https://github.com/davidphilipbarr), with no diodes and direct micro-controller pin wiring.
6
7## Keyboard Info
8
9* Keyboard Maintainer: [davidphilipbarr](https://github.com/davidphilipbarr)
10* Hardware Supported:
11 * [Sweep](https://github.com/davidphilipbarr/Sweep)
12 * [Hypergarlic](https://github.com/davidphilipbarr/hypergolic/tree/main/hypergarlic)
13 * Variants of the same 34-key direct pin PCB
14* Hardware Availability: PCBs can be printed with gerber files from the repository
15
16Make examples for this keyboard (after setting up your build environment):
17
18 make cradio:default
19
20Firmware uses `EE_HANDS` split handedness by default. Each halve should be flashed once with the following:
21
22 make cradio:default:dfu-split-left
23 make cradio:default:dfu-split-right
24
25See 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).
26
27## Bootloader
28
29Enter the bootloader in 3 ways:
30
31* **Bootmagic reset**: Hold down the top left key on the left half (or the top right right key on the right half) and plug in the controller on that side.
32* **Physical reset button**: Briefly press the reset button soldered on the PCB.
33* **Keycode in layout**: Press the key mapped to `RESET` if it is configured.
diff --git a/keyboards/cradio/rules.mk b/keyboards/cradio/rules.mk
new file mode 100644
index 000000000..437ca573d
--- /dev/null
+++ b/keyboards/cradio/rules.mk
@@ -0,0 +1,23 @@
1# MCU name
2MCU = atmega32u4
3
4# Bootloader selection
5BOOTLOADER = atmel-dfu
6
7# Build Options
8# change yes to no to disable
9#
10BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite
11MOUSEKEY_ENABLE = yes # Mouse keys
12EXTRAKEY_ENABLE = yes # 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
21UNICODE_ENABLE = yes # Unicode
22AUDIO_ENABLE = no # Audio output
23SPLIT_KEYBOARD = yes # Use shared split_common code