summaryrefslogtreecommitdiff
path: root/keyboards/cradio
diff options
context:
space:
mode:
authorInigoGutierrez <inigogf.95@gmail.com>2022-09-25 16:02:54 +0200
committerInigoGutierrez <inigogf.95@gmail.com>2022-09-25 16:02:54 +0200
commit6afdd9d74da250e47ac64d6690bd19d037045e99 (patch)
tree661f6cfb244c02bcd1fbfe8fb9b2bd9242a91394 /keyboards/cradio
parent93a55e61b59d20f7cd842cce02e5b18a63a23612 (diff)
parent1bdf4cdc22ae57d111efb2f7d71e405e5c7b3f11 (diff)
downloadqmk_firmware-6afdd9d74da250e47ac64d6690bd19d037045e99.tar.gz
qmk_firmware-6afdd9d74da250e47ac64d6690bd19d037045e99.zip
Merge branch 'master' into taamas
Diffstat (limited to 'keyboards/cradio')
-rw-r--r--keyboards/cradio/config.h75
-rw-r--r--keyboards/cradio/cradio.c27
-rw-r--r--keyboards/cradio/cradio.h52
-rw-r--r--keyboards/cradio/info.json122
-rw-r--r--keyboards/cradio/readme.md8
-rw-r--r--keyboards/cradio/rules.mk22
6 files changed, 100 insertions, 206 deletions
diff --git a/keyboards/cradio/config.h b/keyboards/cradio/config.h
index aba6050af1..e4ecd29539 100644
--- a/keyboards/cradio/config.h
+++ b/keyboards/cradio/config.h
@@ -1,76 +1,11 @@
-/* Copyright 2018-2021
- * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
- * David Philip Barr <@davidphilipbarr>
- * Pierre Chevalier <pierrechevalier83@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/>.
- */
+// Copyright 2018-2021
+// ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
+// David Philip Barr <@davidphilipbarr>
+// Pierre Chevalier <pierrechevalier83@gmail.com>
+// SPDX-License-Identifier: GPL-2.0+
-#pragma once
-
-#include "config_common.h"
-
-/* USB Device descriptor parameter */
-#define VENDOR_ID 0xC88B
-#define PRODUCT_ID 0x3988
-#define DEVICE_VER 0x0001
-#define MANUFACTURER DPB
-#define PRODUCT Cradio
-
-/* key matrix size */
-#define MATRIX_ROWS 8
-#define MATRIX_COLS 5
-
-/*
- * Keyboard Matrix Assignments
- *
- * Change this to how you wired your keyboard
- * COLS: AVR pins used for columns, left to right
- * ROWS: AVR pins used for rows, top to bottom
- * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
- * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
- * NO_DIODE = switches are directly connected to AVR pins
- *
-*/
-#define DIRECT_PINS { \
- { E6, F7, F6, F5, F4 }, \
- { B1, B3, B2, B6, D3 }, \
- { D1, D0, D4, C6, D7 }, \
- { B4, B5, NO_PIN, NO_PIN, NO_PIN } \
-}
-
-#define DIRECT_PINS_RIGHT { \
- { F4, F5, F6, F7, E6 }, \
- { D3, B6, B2, B3, B1 }, \
- { D7, C6, D4, D0, D1 }, \
- { B5, B4, NO_PIN, NO_PIN, NO_PIN } \
-}
-
-#define UNUSED_PINS
-
-/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
-#define DEBOUNCE 5
-
-/* Serial settings */
-#define USE_SERIAL
-/* serial.c configuration for split keyboard */
-#define SOFT_SERIAL_PIN D2
-
-/* Top left key on left half */
#define BOOTMAGIC_LITE_ROW 0
#define BOOTMAGIC_LITE_COLUMN 0
/* Top right key on right half */
#define BOOTMAGIC_LITE_ROW_RIGHT 4
#define BOOTMAGIC_LITE_COLUMN_RIGHT 4
-
diff --git a/keyboards/cradio/cradio.c b/keyboards/cradio/cradio.c
index 76c64cbb8c..99a69ff755 100644
--- a/keyboards/cradio/cradio.c
+++ b/keyboards/cradio/cradio.c
@@ -1,24 +1,10 @@
-/* Copyright 2018-2021
- * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
- * David Philip Barr <@davidphilipbarr>
- * Pierre Chevalier <pierrechevalier83@gmail.com>
- * @filterpaper
- *
- * 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/>.
- */
+// Copyright 2018-2021
+// ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
+// David Philip Barr <@davidphilipbarr>
+// Pierre Chevalier <pierrechevalier83@gmail.com>
+// SPDX-License-Identifier: GPL-2.0+
-#include "cradio.h"
+#include "quantum.h"
#ifdef SWAP_HANDS_ENABLE
__attribute__ ((weak))
@@ -35,4 +21,3 @@ const keypos_t PROGMEM hand_swap_config[MATRIX_ROWS][MATRIX_COLS] = {
{{1, 3}, {0, 3}, {2, 3}, {3, 3}, {4, 3}}
};
#endif
-
diff --git a/keyboards/cradio/cradio.h b/keyboards/cradio/cradio.h
deleted file mode 100644
index f013386bf8..0000000000
--- a/keyboards/cradio/cradio.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/* Copyright 2018-2021
- * ENDO Katsuhiro <ka2hiro@curlybracket.co.jp>
- * David Philip Barr <@davidphilipbarr>
- * Pierre Chevalier <pierrechevalier83@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 "quantum.h"
-
-/* This a shortcut to help you visually see your layout.
- *
- * The first section contains all of the arguments representing the physical
- * layout of the board and position of the keys.
- *
- * The second converts the arguments into a two-dimensional array which
- * represents the switch matrix.
- */
-
-// readability
-#define ___ KC_NO
-
-#define LAYOUT_split_3x5_2( \
- L01, L02, L03, L04, L05, R01, R02, R03, R04, R05, \
- L06, L07, L08, L09, L10, R06, R07, R08, R09, R10, \
- L11, L12, L13, L14, L15, R11, R12, R13, R14, R15, \
- L16, L17, R16, R17 \
- ) \
- { \
- { L01, L02, L03, L04, L05 }, \
- { L06, L07, L08, L09, L10 }, \
- { L11, L12, L13, L14, L15 }, \
- { L16, L17, ___, ___, ___ }, \
- { R01, R02, R03, R04, R05 }, \
- { R06, R07, R08, R09, R10 }, \
- { R11, R12, R13, R14, R15 }, \
- { R16, R17, ___, ___, ___ } \
- }
-
-#define LAYOUT LAYOUT_split_3x5_2
-
diff --git a/keyboards/cradio/info.json b/keyboards/cradio/info.json
index 78cb7ef195..0b9cbb1fed 100644
--- a/keyboards/cradio/info.json
+++ b/keyboards/cradio/info.json
@@ -1,51 +1,91 @@
{
"keyboard_name": "Cradio",
+ "manufacturer": "DPB",
"url": "https://github.com/davidphilipbarr/Sweep",
"maintainer": "@davidphilipbarr",
+ "usb": {
+ "vid": "0xC88B",
+ "pid": "0x3988",
+ "device_version": "0.0.1"
+ },
+ "processor": "atmega32u4",
+ "protocol": "atmel-dfu",
+ "debounce": 5,
+ "features": {
+ "bootmagic": true,
+ "command": false,
+ "console": false,
+ "extrakey": true,
+ "mousekey": true,
+ "nkro": false,
+ "unicode": true
+ },
+ "matrix_pins": {
+ "direct": [
+ ["E6", "F7", "F6", "F5", "F4"],
+ ["B1", "B3", "B2", "B6", "D3"],
+ ["D1", "D0", "D4", "C6", "D7"],
+ ["B4", "B5", null, null, null]
+ ]
+ },
+ "split": {
+ "enabled": true,
+ "matrix_pins": {
+ "right": {
+ "direct": [
+ ["F4", "F5", "F6", "F7", "E6"],
+ ["D3", "B6", "B2", "B3", "B1"],
+ ["D7", "C6", "D4", "D0", "D1"],
+ ["B5", "B4", null, null, null]
+ ]
+ }
+ },
+ "soft_serial_pin": "D2",
+ "transport": {
+ "protocol": "serial"
+ }
+ },
+ "community_layouts": ["split_3x5_2"],
+ "layout_aliases": {
+ "LAYOUT": "LAYOUT_split_3x5_2"
+ },
"layouts": {
"LAYOUT_split_3x5_2": {
"layout": [
- {"x": 0, "y": 1.27},
- {"x": 1, "y": 0.31},
- {"x": 2, "y": 0},
- {"x": 3, "y": 0.28},
- {"x": 4, "y": 0.42},
-
- {"x": 8, "y": 0.42},
- {"x": 9, "y": 0.28},
- {"x": 10, "y": 0},
- {"x": 11, "y": 0.31},
- {"x": 12, "y": 1.27},
-
- {"x": 0, "y": 2.27},
- {"x": 1, "y": 1.31},
- {"x": 2, "y": 1},
- {"x": 3, "y": 1.28},
- {"x": 4, "y": 1.42},
-
- {"x": 8, "y": 1.42},
- {"x": 9, "y": 1.28},
- {"x": 10, "y": 1},
- {"x": 11, "y": 1.31},
- {"x": 12, "y": 2.27},
-
- {"x": 0, "y": 3.27},
- {"x": 1, "y": 2.31},
- {"x": 2, "y": 2},
- {"x": 3, "y": 2.28},
- {"x": 4, "y": 2.42},
-
- {"x": 8, "y": 2.42},
- {"x": 9, "y": 2.28},
- {"x": 10, "y": 2},
- {"x": 11, "y": 2.31},
- {"x": 12, "y": 3.27},
-
- {"x": 4, "y": 3.9},
- {"x": 5, "y": 3.7},
-
- {"x": 7, "y": 3.7},
- {"x": 8, "y": 3.9}
+ { "label": "L01", "matrix": [0, 0], "w": 1, "x": 0, "y": 1.27 },
+ { "label": "L02", "matrix": [0, 1], "w": 1, "x": 1, "y": 0.31 },
+ { "label": "L03", "matrix": [0, 2], "w": 1, "x": 2, "y": 0 },
+ { "label": "L04", "matrix": [0, 3], "w": 1, "x": 3, "y": 0.28 },
+ { "label": "L05", "matrix": [0, 4], "w": 1, "x": 4, "y": 0.42 },
+ { "label": "L06", "matrix": [1, 0], "w": 1, "x": 0, "y": 2.27 },
+ { "label": "L07", "matrix": [1, 1], "w": 1, "x": 1, "y": 1.31 },
+ { "label": "L08", "matrix": [1, 2], "w": 1, "x": 2, "y": 1 },
+ { "label": "L09", "matrix": [1, 3], "w": 1, "x": 3, "y": 1.28 },
+ { "label": "L10", "matrix": [1, 4], "w": 1, "x": 4, "y": 1.42 },
+ { "label": "L11", "matrix": [2, 0], "w": 1, "x": 0, "y": 3.27 },
+ { "label": "L12", "matrix": [2, 1], "w": 1, "x": 1, "y": 2.31 },
+ { "label": "L13", "matrix": [2, 2], "w": 1, "x": 2, "y": 2 },
+ { "label": "L14", "matrix": [2, 3], "w": 1, "x": 3, "y": 2.28 },
+ { "label": "L15", "matrix": [2, 4], "w": 1, "x": 4, "y": 2.42 },
+ { "label": "L16", "matrix": [3, 0], "w": 1, "x": 4, "y": 3.9 },
+ { "label": "L17", "matrix": [3, 1], "w": 1, "x": 5, "y": 3.7 },
+ { "label": "R01", "matrix": [4, 0], "w": 1, "x": 8, "y": 0.42 },
+ { "label": "R02", "matrix": [4, 1], "w": 1, "x": 9, "y": 0.28 },
+ { "label": "R03", "matrix": [4, 2], "w": 1, "x": 10, "y": 0 },
+ { "label": "R04", "matrix": [4, 3], "w": 1, "x": 11, "y": 0.31 },
+ { "label": "R05", "matrix": [4, 4], "w": 1, "x": 12, "y": 1.27 },
+ { "label": "R06", "matrix": [5, 0], "w": 1, "x": 8, "y": 1.42 },
+ { "label": "R07", "matrix": [5, 1], "w": 1, "x": 9, "y": 1.28 },
+ { "label": "R08", "matrix": [5, 2], "w": 1, "x": 10, "y": 1 },
+ { "label": "R09", "matrix": [5, 3], "w": 1, "x": 11, "y": 1.31 },
+ { "label": "R10", "matrix": [5, 4], "w": 1, "x": 12, "y": 2.27 },
+ { "label": "R11", "matrix": [6, 0], "w": 1, "x": 8, "y": 2.42 },
+ { "label": "R12", "matrix": [6, 1], "w": 1, "x": 9, "y": 2.28 },
+ { "label": "R13", "matrix": [6, 2], "w": 1, "x": 10, "y": 2 },
+ { "label": "R14", "matrix": [6, 3], "w": 1, "x": 11, "y": 2.31 },
+ { "label": "R15", "matrix": [6, 4], "w": 1, "x": 12, "y": 3.27 },
+ { "label": "R16", "matrix": [7, 0], "w": 1, "x": 7, "y": 3.7 },
+ { "label": "R17", "matrix": [7, 1], "w": 1, "x": 8, "y": 3.9 }
]
}
}
diff --git a/keyboards/cradio/readme.md b/keyboards/cradio/readme.md
index 7f3cef0969..09a5267a1a 100644
--- a/keyboards/cradio/readme.md
+++ b/keyboards/cradio/readme.md
@@ -18,13 +18,19 @@ Make example for this keyboard (after setting up your build environment):
make cradio:default
+### RP2040 Controllers
+
+Pro Micro RP2040 controllers are supported with [QMK Converters](https://docs.qmk.fm/#/feature_converters). The make command example for Adafruit's KB2040 are:
+
+ make CONVERT_TO=kb2040 cradio:default
+
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).
## Bootloader
Enter the bootloader in 3 ways:
-* **Keycode in layout**: Press the key mapped to `RESET` if it is configured.
+* **Keycode in layout**: Press the key mapped to `QK_BOOT` if it is configured.
* **Physical reset button**: Briefly press the reset button soldered on the PCB.
* **Bootmagic reset**: Hold down the top left key on the left half (or the top right key on the right half) and plug in the controller on that side.
diff --git a/keyboards/cradio/rules.mk b/keyboards/cradio/rules.mk
index 1e4940ca7d..6e7633bfe0 100644
--- a/keyboards/cradio/rules.mk
+++ b/keyboards/cradio/rules.mk
@@ -1,21 +1 @@
-# MCU name
-MCU = atmega32u4
-
-# Bootloader selection
-BOOTLOADER = atmel-dfu
-
-# Build Options
-# change yes to no to disable
-#
-BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite
-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
-NKRO_ENABLE = no # Enable N-Key Rollover
-BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality
-RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
-UNICODE_ENABLE = yes # Unicode
-AUDIO_ENABLE = no # Audio output
-SPLIT_KEYBOARD = yes # Use shared split_common code
-LAYOUTS = split_3x5_2
+# This file intentionally left blank