diff options
author | QMK Bot <hello@qmk.fm> | 2021-10-05 01:36:24 +0000 |
---|---|---|
committer | QMK Bot <hello@qmk.fm> | 2021-10-05 01:36:24 +0000 |
commit | d47f0c10feb95f7fd64cf4fdb35b0147328de340 (patch) | |
tree | a7b8eb3aa36822149601cbb6692c44d2c5dede3e /keyboards | |
parent | 95ead1bbd14a16680185db0f3cce5fcf120d92d1 (diff) | |
parent | 85ba5074825f608501e14594764cdc3c82a08c01 (diff) | |
download | qmk_firmware-d47f0c10feb95f7fd64cf4fdb35b0147328de340.tar.gz qmk_firmware-d47f0c10feb95f7fd64cf4fdb35b0147328de340.zip |
Merge remote-tracking branch 'origin/master' into develop
Diffstat (limited to 'keyboards')
-rw-r--r-- | keyboards/handwired/dc/mc/001/001.c | 17 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/001.h | 33 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/config.h | 83 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/info.json | 16 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/keymaps/default/keymap.c | 31 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/keymaps/default/readme.md | 1 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/readme.md | 24 | ||||
-rw-r--r-- | keyboards/handwired/dc/mc/001/rules.mk | 22 |
8 files changed, 227 insertions, 0 deletions
diff --git a/keyboards/handwired/dc/mc/001/001.c b/keyboards/handwired/dc/mc/001/001.c new file mode 100644 index 000000000..4745469fd --- /dev/null +++ b/keyboards/handwired/dc/mc/001/001.c | |||
@@ -0,0 +1,17 @@ | |||
1 | /* Copyright 2021 Daniel Cormier | ||
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 "001.h" | ||
diff --git a/keyboards/handwired/dc/mc/001/001.h b/keyboards/handwired/dc/mc/001/001.h new file mode 100644 index 000000000..317655162 --- /dev/null +++ b/keyboards/handwired/dc/mc/001/001.h | |||
@@ -0,0 +1,33 @@ | |||
1 | /* Copyright 2021 Daniel Cormier | ||
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 "quantum.h" | ||
20 | |||
21 | /* This is a shortcut to help you visually see your layout. | ||
22 | * | ||
23 | * The first section contains all of the arguments representing the physical | ||
24 | * layout of the board and position of the keys. | ||
25 | * | ||
26 | * The second converts the arguments into a two-dimensional array which | ||
27 | * represents the switch matrix. | ||
28 | */ | ||
29 | #define LAYOUT( \ | ||
30 | k00, k01, k02, k03, k04 \ | ||
31 | ) { \ | ||
32 | { k00, k01, k02, k03, k04 } \ | ||
33 | } | ||
diff --git a/keyboards/handwired/dc/mc/001/config.h b/keyboards/handwired/dc/mc/001/config.h new file mode 100644 index 000000000..4c687ae7f --- /dev/null +++ b/keyboards/handwired/dc/mc/001/config.h | |||
@@ -0,0 +1,83 @@ | |||
1 | /* | ||
2 | Copyright 2021 Daniel Cormier | ||
3 | |||
4 | This program is free software: you can redistribute it and/or modify | ||
5 | it under the terms of the GNU General Public License as published by | ||
6 | the Free Software Foundation, either version 2 of the License, or | ||
7 | (at your option) any later version. | ||
8 | |||
9 | This program is distributed in the hope that it will be useful, | ||
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | GNU General Public License for more details. | ||
13 | |||
14 | You should have received a copy of the GNU General Public License | ||
15 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
16 | */ | ||
17 | |||
18 | #pragma once | ||
19 | |||
20 | #include "config_common.h" | ||
21 | |||
22 | /* USB Device descriptor parameter */ | ||
23 | #define VENDOR_ID 0x4443 // 'D' 'C' | ||
24 | #define PRODUCT_ID 0x4D43 // 'M' 'C' | ||
25 | #define DEVICE_VER 0x0001 | ||
26 | #define MANUFACTURER Daniel Cormier | ||
27 | #define PRODUCT DC MC 001 | ||
28 | |||
29 | /* | ||
30 | BUTTON_MUTE = _BV(4), | ||
31 | BUTTON_STOP = _BV(0), | ||
32 | BUTTON_TRACK_PREVIOUS = _BV(1), | ||
33 | BUTTON_TRACK_NEXT = _BV(2), | ||
34 | BUTTON_PLAY_PAUSE = _BV(3), | ||
35 | */ | ||
36 | #define DIRECT_PINS \ | ||
37 | { \ | ||
38 | { B4, B0, B1, B2, B3 } \ | ||
39 | } | ||
40 | #define UNUSED_PINS | ||
41 | |||
42 | /* | ||
43 | RE_CHANNEL_A = _BV(6), | ||
44 | RE_CHANNEL_B = _BV(5), | ||
45 | */ | ||
46 | #define ENCODERS_PAD_A \ | ||
47 | { B6 } | ||
48 | #define ENCODERS_PAD_B \ | ||
49 | { B5 } | ||
50 | #define ENCODER_RESOLUTION 4 | ||
51 | |||
52 | /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ | ||
53 | // All the keys just need 5ms of debounce, but the mute button on the rotary | ||
54 | // encoderneeds much more (50ms). | ||
55 | #define DEBOUNCE 50 | ||
56 | |||
57 | /* | ||
58 | * Feature disable options | ||
59 | * These options are also useful to firmware size reduction. | ||
60 | */ | ||
61 | |||
62 | /* disable debug print */ | ||
63 | //#define NO_DEBUG | ||
64 | |||
65 | /* disable print */ | ||
66 | //#define NO_PRINT | ||
67 | |||
68 | /* disable action features */ | ||
69 | #define NO_ACTION_LAYER | ||
70 | #define NO_ACTION_TAPPING | ||
71 | #define NO_ACTION_ONESHOT | ||
72 | |||
73 | /* disable these deprecated features by default */ | ||
74 | #define NO_ACTION_MACRO | ||
75 | #define NO_ACTION_FUNCTION | ||
76 | |||
77 | /* Bootmagic Lite key configuration */ | ||
78 | // The (default) Stop key | ||
79 | // Doesn't work, though. Maybe becuase of the bootloader that's in use? | ||
80 | #define BOOTMAGIC_LITE_ROW 0 | ||
81 | #define BOOTMAGIC_LITE_COLUMN 1 | ||
82 | |||
83 | #define USB_MAX_POWER_CONSUMPTION 100 | ||
diff --git a/keyboards/handwired/dc/mc/001/info.json b/keyboards/handwired/dc/mc/001/info.json new file mode 100644 index 000000000..d9562f660 --- /dev/null +++ b/keyboards/handwired/dc/mc/001/info.json | |||
@@ -0,0 +1,16 @@ | |||
1 | { | ||
2 | "keyboard_name": "Daniel Cormier's Media Controller (v1)", | ||
3 | "url": "https://imgur.com/a/PM9lQ", | ||
4 | "maintainer": "Daniel Cormier (Twitter: @danielcormier)", | ||
5 | "layouts": { | ||
6 | "LAYOUT": { | ||
7 | "layout": [ | ||
8 | {"label": "Mute", "x": 0, "y": 0}, | ||
9 | {"label": "Stop", "x": 1, "y": 0}, | ||
10 | {"label": "Previous", "x": 2, "y": 0}, | ||
11 | {"label": "Next", "x": 3, "y": 0}, | ||
12 | {"label": "Play/Pause", "x": 4, "y": 0} | ||
13 | ] | ||
14 | } | ||
15 | } | ||
16 | } | ||
diff --git a/keyboards/handwired/dc/mc/001/keymaps/default/keymap.c b/keyboards/handwired/dc/mc/001/keymaps/default/keymap.c new file mode 100644 index 000000000..6f6ca52d7 --- /dev/null +++ b/keyboards/handwired/dc/mc/001/keymaps/default/keymap.c | |||
@@ -0,0 +1,31 @@ | |||
1 | /* Copyright 2021 Daniel Cormier | ||
2 | * | ||
3 | * This program is free software: you can redistribute it and/or modify | ||
4 | * it under the terms of the GNU General Public License as published by | ||
5 | * the Free Software Foundation, either version 2 of the License, or | ||
6 | * (at your option) any later version. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, | ||
9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
11 | * GNU General Public License for more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License | ||
14 | * along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
15 | */ | ||
16 | #include QMK_KEYBOARD_H | ||
17 | |||
18 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
19 | LAYOUT(KC_AUDIO_MUTE, KC_MEDIA_STOP, KC_MEDIA_PREV_TRACK, KC_MEDIA_NEXT_TRACK, KC_MEDIA_PLAY_PAUSE), | ||
20 | }; | ||
21 | |||
22 | bool encoder_update_user(uint8_t index, bool clockwise) { | ||
23 | if (index == 0) { | ||
24 | if (clockwise) { | ||
25 | tap_code(KC_VOLU); | ||
26 | } else { | ||
27 | tap_code(KC_VOLD); | ||
28 | } | ||
29 | } | ||
30 | return true; | ||
31 | } | ||
diff --git a/keyboards/handwired/dc/mc/001/keymaps/default/readme.md b/keyboards/handwired/dc/mc/001/keymaps/default/readme.md new file mode 100644 index 000000000..e207a7b80 --- /dev/null +++ b/keyboards/handwired/dc/mc/001/keymaps/default/readme.md | |||
@@ -0,0 +1 @@ | |||
# The default keymap for DC MC 001 | |||
diff --git a/keyboards/handwired/dc/mc/001/readme.md b/keyboards/handwired/dc/mc/001/readme.md new file mode 100644 index 000000000..9a20ac339 --- /dev/null +++ b/keyboards/handwired/dc/mc/001/readme.md | |||
@@ -0,0 +1,24 @@ | |||
1 | # handwired/dc/mc/001 | ||
2 | |||
3 | [ | ||
4 | *A freestanding media controller*](https://imgur.com/a/PM9lQ) | ||
5 | |||
6 | * Keyboard Maintainer: [Daniel Cormier](https://github.com/dcormier) | ||
7 | * Hardware Supported: Adafruit Atmega32u4 Breakout Board | ||
8 | * Hardware Availability: https://www.adafruit.com/product/296 | ||
9 | |||
10 | Make example for this keyboard (after setting up your build environment): | ||
11 | |||
12 | make handwired/dc/mc/001:default | ||
13 | |||
14 | Flashing example for this keyboard: | ||
15 | |||
16 | make handwired/dc/mc/001:default:flash | ||
17 | |||
18 | 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). | ||
19 | |||
20 | ## Bootloader | ||
21 | |||
22 | Enter the bootloader: | ||
23 | |||
24 | * **Physical reset button**: Briefly press the button on the top of the PCB | ||
diff --git a/keyboards/handwired/dc/mc/001/rules.mk b/keyboards/handwired/dc/mc/001/rules.mk new file mode 100644 index 000000000..3ec538b93 --- /dev/null +++ b/keyboards/handwired/dc/mc/001/rules.mk | |||
@@ -0,0 +1,22 @@ | |||
1 | # MCU name | ||
2 | MCU = atmega32u4 | ||
3 | |||
4 | # Bootloader selection | ||
5 | BOOTLOADER = caterina | ||
6 | |||
7 | # Build Options | ||
8 | # change yes to no to disable | ||
9 | # | ||
10 | BOOTMAGIC_ENABLE = yes # Enable Bootmagic Lite | ||
11 | EXTRAKEY_ENABLE = yes # Audio control and System control | ||
12 | ENCODER_ENABLE = yes # Using a rotary encoder for volume control | ||
13 | MOUSEKEY_ENABLE = no # Mouse keys | ||
14 | CONSOLE_ENABLE = no # Console for debug | ||
15 | COMMAND_ENABLE = no # Commands for debug and configuration | ||
16 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | ||
17 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | ||
18 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | ||
19 | NKRO_ENABLE = no # USB Nkey Rollover | ||
20 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality | ||
21 | RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow | ||
22 | AUDIO_ENABLE = no # Audio output | ||