aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorQMK Bot <hello@qmk.fm>2020-12-30 01:46:45 +0000
committerQMK Bot <hello@qmk.fm>2020-12-30 01:46:45 +0000
commit5e9b00280897914104583f7f820340ec6520beb7 (patch)
tree959b32433224edc75e3f16e31df01dd6a0d8eb0b
parent154bf92b5b475b563ec9ba37ce43bfbf1aa4f918 (diff)
parenta94044c15c8217d8a6ad016cc0233abe3de374b0 (diff)
downloadqmk_firmware-5e9b00280897914104583f7f820340ec6520beb7.tar.gz
qmk_firmware-5e9b00280897914104583f7f820340ec6520beb7.zip
Merge remote-tracking branch 'origin/master' into develop
-rw-r--r--keyboards/40percentclub/sixpack/config.h122
-rw-r--r--keyboards/40percentclub/sixpack/info.json15
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/default/keymap.c31
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/default/readme.md1
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/fkeys/keymap.c50
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/fkeys/readme.md1
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/fkeys/rules.mk1
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/via/keymap.c41
-rw-r--r--keyboards/40percentclub/sixpack/keymaps/via/rules.mk1
-rw-r--r--keyboards/40percentclub/sixpack/readme.md21
-rw-r--r--keyboards/40percentclub/sixpack/rules.mk22
-rw-r--r--keyboards/40percentclub/sixpack/sixpack.c24
-rw-r--r--keyboards/40percentclub/sixpack/sixpack.h34
13 files changed, 364 insertions, 0 deletions
diff --git a/keyboards/40percentclub/sixpack/config.h b/keyboards/40percentclub/sixpack/config.h
new file mode 100644
index 000000000..db91ca7b8
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/config.h
@@ -0,0 +1,122 @@
1/*
2Copyright 2020
3
4This program is free software: you can redistribute it and/or modify
5it under the terms of the GNU General Public License as published by
6the Free Software Foundation, either version 2 of the License, or
7(at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along 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 0x3430 // "40"
24#define PRODUCT_ID 0x5350 // "SP"
25#define DEVICE_VER 0x1001
26#define MANUFACTURER di0ib
27#define PRODUCT Six Pack
28
29/* key matrix size */
30#define MATRIX_ROWS 2
31#define MATRIX_COLS 3
32
33/*
34 * Keyboard Matrix Assignments
35 *
36 * Change this to how you wired your keyboard
37 * COLS: AVR pins used for columns, left to right
38 * ROWS: AVR pins used for rows, top to bottom
39 * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode)
40 * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode)
41 *
42 */
43// #define MATRIX_ROW_PINS { B0 } // B0 equivalents the ground pin
44// #define MATRIX_COL_PINS { E6, D7, C6, D4 }
45#define DIRECT_PINS { \
46 { D4, C6, D7 }, \
47 { E6, B4, B5 } \
48}
49#define UNUSED_PINS { D1, D0, C4, C5, B1, B2, B3 } // TX, RX, SDA, SCL, PB1, PB2, PB3 on expansion connector
50
51/* COL2ROW, ROW2COL*/
52#define DIODE_DIRECTION COL2ROW
53
54/* Backlight */
55#define BACKLIGHT_BREATHING
56#define BACKLIGHT_LEVELS 6
57#define BACKLIGHT_PINS { F4, F5 } // Top Row, Bottom Row
58
59// #define RGB_DI_PIN B1 // PB1 on expansion connector
60// #ifdef RGB_DI_PIN
61// #define RGBLED_NUM 16
62// #define RGBLIGHT_HUE_STEP 8
63// #define RGBLIGHT_SAT_STEP 8
64// #define RGBLIGHT_VAL_STEP 8
65// #define RGBLIGHT_LIMIT_VAL 255 /* The maximum brightness level */
66// #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
67// /*== all animations enable ==*/
68// #define RGBLIGHT_ANIMATIONS
69// /*== or choose animations ==*/
70// #define RGBLIGHT_EFFECT_BREATHING
71// #define RGBLIGHT_EFFECT_RAINBOW_MOOD
72// #define RGBLIGHT_EFFECT_RAINBOW_SWIRL
73// #define RGBLIGHT_EFFECT_SNAKE
74// #define RGBLIGHT_EFFECT_KNIGHT
75// #define RGBLIGHT_EFFECT_CHRISTMAS
76// #define RGBLIGHT_EFFECT_STATIC_GRADIENT
77// #define RGBLIGHT_EFFECT_RGB_TEST
78// #define RGBLIGHT_EFFECT_ALTERNATING
79// /*== customize breathing effect ==*/
80// /*==== (DEFAULT) use fixed table instead of exp() and sin() ====*/
81// #define RGBLIGHT_BREATHE_TABLE_SIZE 256 // 256(default) or 128 or 64
82// /*==== use exp() and sin() ====*/
83// #define RGBLIGHT_EFFECT_BREATHE_CENTER 1.85 // 1 to 2.7
84// #define RGBLIGHT_EFFECT_BREATHE_MAX 255 // 0 to 255
85// #endif
86
87/* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */
88#define DEBOUNCE 5
89
90/* define if matrix has ghost (lacks anti-ghosting diodes) */
91//#define MATRIX_HAS_GHOST
92
93/* If defined, GRAVE_ESC will always act as ESC when CTRL is held.
94 * This is userful for the Windows task manager shortcut (ctrl+shift+esc).
95 */
96// #define GRAVE_ESC_CTRL_OVERRIDE
97
98/*
99 * Force NKRO
100 *
101 * Force NKRO (nKey Rollover) to be enabled by default, regardless of the saved
102 * state in the bootmagic EEPROM settings. (Note that NKRO must be enabled in the
103 * makefile for this to work.)
104 *
105 * If forced on, NKRO can be disabled via magic key (default = LShift+RShift+N)
106 * until the next keyboard reset.
107 *
108 * NKRO may prevent your keystrokes from being detected in the BIOS, but it is
109 * fully operational during normal computer usage.
110 *
111 * For a less heavy-handed approach, enable NKRO via magic key (LShift+RShift+N)
112 * or via bootmagic (hold SPACE+N while plugging in the keyboard). Once set by
113 * bootmagic, NKRO mode will always be enabled until it is toggled again during a
114 * power-up.
115 *
116 */
117//#define FORCE_NKRO
118
119
120/* Bootmagic Lite key configuration */
121// #define BOOTMAGIC_LITE_ROW 0
122// #define BOOTMAGIC_LITE_COLUMN 0
diff --git a/keyboards/40percentclub/sixpack/info.json b/keyboards/40percentclub/sixpack/info.json
new file mode 100644
index 000000000..3c78e26fb
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/info.json
@@ -0,0 +1,15 @@
1{
2 "keyboard_name": "sixpack",
3 "url": "https://www.40percent.club/2017/05/six-pack-11.html",
4 "maintainer": "qmk",
5 "width": 3,
6 "height": 2,
7 "layouts": {
8 "LAYOUT_ortho_2x3": {
9 "layout": [
10 {"x":0, "y":0}, {"x":1, "y":0}, {"x":2, "y":0},
11 {"x":0, "y":1}, {"x":1, "y":1}, {"x":2, "y":1}
12 ]
13 }
14 }
15}
diff --git a/keyboards/40percentclub/sixpack/keymaps/default/keymap.c b/keyboards/40percentclub/sixpack/keymaps/default/keymap.c
new file mode 100644
index 000000000..48885fc50
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/default/keymap.c
@@ -0,0 +1,31 @@
1/* Copyright 2020
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
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19
20 /* Default 2x3 layout
21 * .--------------------------.
22 * | MUTE | UP | PLAY |
23 * |--------+--------+--------+
24 * | LEFT | DOWN | RIGHT |
25 * '--------------------------'
26 */
27
28 [0] = LAYOUT_ortho_2x3(/* Default */
29 KC_MUTE, KC_UP, KC_MPLY,
30 KC_LEFT, KC_DOWN, KC_RGHT),
31};
diff --git a/keyboards/40percentclub/sixpack/keymaps/default/readme.md b/keyboards/40percentclub/sixpack/keymaps/default/readme.md
new file mode 100644
index 000000000..178cae101
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/default/readme.md
@@ -0,0 +1 @@
# The default keymap for Six Pack
diff --git a/keyboards/40percentclub/sixpack/keymaps/fkeys/keymap.c b/keyboards/40percentclub/sixpack/keymaps/fkeys/keymap.c
new file mode 100644
index 000000000..8ca5a5a27
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/fkeys/keymap.c
@@ -0,0 +1,50 @@
1/* Copyright 2020
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// Tap Dance declarations
19enum {
20 F13F19,
21 F14F20,
22 F15F21,
23 F16F22,
24 F17F23,
25 F18F24,
26};
27
28// Tap Dance definitions
29qk_tap_dance_action_t tap_dance_actions[] = {
30 // Tap once for F13 to F18, twice for F19 to F24
31 [F13F19] = ACTION_TAP_DANCE_DOUBLE(KC_F13, KC_F19), [F14F20] = ACTION_TAP_DANCE_DOUBLE(KC_F14, KC_F20), [F15F21] = ACTION_TAP_DANCE_DOUBLE(KC_F15, KC_F21),
32 [F16F22] = ACTION_TAP_DANCE_DOUBLE(KC_F16, KC_F22), [F17F23] = ACTION_TAP_DANCE_DOUBLE(KC_F17, KC_F23), [F18F24] = ACTION_TAP_DANCE_DOUBLE(KC_F18, KC_F24)
33};
34
35// Add tap dance item in place of a key code
36const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
37
38 /* 2x3 layout
39 * .-----------------------------.
40 * | F13/F19 | D14/F20 | F15/F21 |
41 * |---------+---------+---------+
42 * | F16/F22 | D17/F23 | F18/F24 |
43 * '-----------------------------'
44 */
45
46 [0] = LAYOUT_ortho_2x3(/* F13 to F24 */
47 TD(F13F19), TD(F14F20), TD(F15F21),
48 TD(F16F22), TD(F17F23), TD(F18F24)
49 ),
50};
diff --git a/keyboards/40percentclub/sixpack/keymaps/fkeys/readme.md b/keyboards/40percentclub/sixpack/keymaps/fkeys/readme.md
new file mode 100644
index 000000000..9974588e5
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/fkeys/readme.md
@@ -0,0 +1 @@
# F13 to F24 keymap with Tap Dance for Six Pack
diff --git a/keyboards/40percentclub/sixpack/keymaps/fkeys/rules.mk b/keyboards/40percentclub/sixpack/keymaps/fkeys/rules.mk
new file mode 100644
index 000000000..e5ddcae8d
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/fkeys/rules.mk
@@ -0,0 +1 @@
TAP_DANCE_ENABLE = yes
diff --git a/keyboards/40percentclub/sixpack/keymaps/via/keymap.c b/keyboards/40percentclub/sixpack/keymaps/via/keymap.c
new file mode 100644
index 000000000..f3268a22a
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/via/keymap.c
@@ -0,0 +1,41 @@
1/* Copyright 2020
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
18const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
19
20 /* Default 2x3 layout with 6 Layers
21 * .--------------------------.
22 * | MUTE | UP | PLAY |
23 * |--------+--------+--------+
24 * | LEFT | DOWN | RIGHT |
25 * '--------------------------'
26 */
27
28 [0] = LAYOUT_ortho_2x3(KC_MUTE, KC_UP , KC_MPLY,
29 KC_LEFT, KC_DOWN, KC_RGHT),
30 [1] = LAYOUT_ortho_2x3(KC_TRNS, KC_TRNS, KC_TRNS,
31 KC_TRNS, KC_TRNS, KC_TRNS),
32 [2] = LAYOUT_ortho_2x3(KC_TRNS, KC_TRNS, KC_TRNS,
33 KC_TRNS, KC_TRNS, KC_TRNS),
34 [3] = LAYOUT_ortho_2x3(KC_TRNS, KC_TRNS, KC_TRNS,
35 KC_TRNS, KC_TRNS, KC_TRNS),
36 [4] = LAYOUT_ortho_2x3(KC_TRNS, KC_TRNS, KC_TRNS,
37 KC_TRNS, KC_TRNS, KC_TRNS),
38 [5] = LAYOUT_ortho_2x3(KC_TRNS, KC_TRNS, KC_TRNS,
39 KC_TRNS, KC_TRNS, KC_TRNS),
40
41};
diff --git a/keyboards/40percentclub/sixpack/keymaps/via/rules.mk b/keyboards/40percentclub/sixpack/keymaps/via/rules.mk
new file mode 100644
index 000000000..1e5b99807
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/keymaps/via/rules.mk
@@ -0,0 +1 @@
VIA_ENABLE = yes
diff --git a/keyboards/40percentclub/sixpack/readme.md b/keyboards/40percentclub/sixpack/readme.md
new file mode 100644
index 000000000..571f92708
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/readme.md
@@ -0,0 +1,21 @@
1# Six Pack
2
3![sixpack](https://4.bp.blogspot.com/-sCUGxPAmcu4/WQj4cd9ZlAI/AAAAAAACBhs/174XLIHIfzISucFFEgo53H73HdVJfn3ZwCLcB/s640/IMG_0265.JPG)
4
5A 6-key macropad PCB with its switch and LED pins wired directly to microcontroller IO pins.
6
7You can find the main blog post about this macropad [here](http://www.40percent.club/2017/05/six-pack-11.html), also the Gerber files and other documentation is located [here](https://git.40percent.club/di0ib/Misc/src/branch/master/Six%20Pack).
8
9* Keyboard Maintainer: [The QMK Community](https://github.com/qmk)
10* Hardware Supported: Six Pack PCB, Pro Micro
11* Hardware Availability: [40percent.club](https://git.40percent.club/di0ib/Misc/src/branch/master/Six%20Pack)
12
13Make example for this macropad (after setting up your build environment):
14
15 make 40percentclub/sixpack:default
16
17Flashing example for this keyboard:
18
19 make 40percentclub/sixpack:default:flash
20
21See 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/40percentclub/sixpack/rules.mk b/keyboards/40percentclub/sixpack/rules.mk
new file mode 100644
index 000000000..9d7d9a2cf
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/rules.mk
@@ -0,0 +1,22 @@
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 = lite # Virtual DIP switch configuration
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 = yes # Enable keyboard backlight functionality
20RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow
21BLUETOOTH_ENABLE = no # Enable Bluetooth
22AUDIO_ENABLE = no # Audio output
diff --git a/keyboards/40percentclub/sixpack/sixpack.c b/keyboards/40percentclub/sixpack/sixpack.c
new file mode 100644
index 000000000..cc0e9e3ad
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/sixpack.c
@@ -0,0 +1,24 @@
1/* Copyright 2020
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 "sixpack.h"
17
18void matrix_init_kb(void) {
19 setPinOutput(B6); // Backlight cathodes Col.3
20 setPinOutput(F6); // Backlight cathodes Col.2
21 setPinOutput(F7); // Backlight cathodes Col.1
22
23 matrix_init_user();
24}
diff --git a/keyboards/40percentclub/sixpack/sixpack.h b/keyboards/40percentclub/sixpack/sixpack.h
new file mode 100644
index 000000000..94db5ee9e
--- /dev/null
+++ b/keyboards/40percentclub/sixpack/sixpack.h
@@ -0,0 +1,34 @@
1/* Copyright 2020
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#pragma once
17
18#include "quantum.h"
19
20/* This a shortcut to help you visually see your layout.
21 *
22 * The first section contains all of the arguments representing the physical
23 * layout of the board and position of the keys.
24 *
25 * The second converts the arguments into a two-dimensional array which
26 * represents the switch matrix.
27 */
28#define LAYOUT_ortho_2x3( \
29 k00, k01, k02, \
30 k10, k11, k12 \
31) { \
32 { k00, k01, k02 }, \
33 { k10, k11, k12 } \
34}