diff options
author | gorbachev <tpp+github@iki.fi> | 2019-06-02 01:43:00 -0400 |
---|---|---|
committer | Drashna Jaelre <drashna@live.com> | 2019-06-01 22:43:00 -0700 |
commit | 6766c5315eb89eeafaf60c089ad028a963c48ab1 (patch) | |
tree | 7bc2bcfefa27bd5fe9d11c4bfbbeac126ee18209 /keyboards/8pack | |
parent | 0744af97af68da4b4ed6e4eca3c61facb39e7971 (diff) | |
download | qmk_firmware-6766c5315eb89eeafaf60c089ad028a963c48ab1.tar.gz qmk_firmware-6766c5315eb89eeafaf60c089ad028a963c48ab1.zip |
[Keyboard] 8 pack (#6031)
* 8-Pack Macropad
* Added MANUFACTUTER to config.h
* Fix the mirrored keymaps by creating rev1.1 and rev1.2 layouts, then using them in the keymaps
* fixes from code review comments
* Use revisions to manage the different layouts for rev1.1 and rev1.2
* Add DEFAULT_FOLDER to fix default build failures
* code review comments fixes
* code review comments fixes
Diffstat (limited to 'keyboards/8pack')
-rw-r--r-- | keyboards/8pack/8pack.c | 1 | ||||
-rw-r--r-- | keyboards/8pack/8pack.h | 11 | ||||
-rw-r--r-- | keyboards/8pack/config.h | 39 | ||||
-rw-r--r-- | keyboards/8pack/info.json | 21 | ||||
-rw-r--r-- | keyboards/8pack/keymaps/default/keymap.c | 12 | ||||
-rw-r--r-- | keyboards/8pack/readme.md | 13 | ||||
-rw-r--r-- | keyboards/8pack/rev11/config.h | 3 | ||||
-rw-r--r-- | keyboards/8pack/rev11/rev11.c | 1 | ||||
-rw-r--r-- | keyboards/8pack/rev11/rev11.h | 11 | ||||
-rw-r--r-- | keyboards/8pack/rev11/rules.mk | 0 | ||||
-rw-r--r-- | keyboards/8pack/rev12/config.h | 3 | ||||
-rw-r--r-- | keyboards/8pack/rev12/rev12.c | 1 | ||||
-rw-r--r-- | keyboards/8pack/rev12/rev12.h | 11 | ||||
-rw-r--r-- | keyboards/8pack/rev12/rules.mk | 0 | ||||
-rw-r--r-- | keyboards/8pack/rules.mk | 63 |
15 files changed, 190 insertions, 0 deletions
diff --git a/keyboards/8pack/8pack.c b/keyboards/8pack/8pack.c new file mode 100644 index 000000000..e89d7281d --- /dev/null +++ b/keyboards/8pack/8pack.c | |||
@@ -0,0 +1 @@ | |||
#include "8pack.h" | |||
diff --git a/keyboards/8pack/8pack.h b/keyboards/8pack/8pack.h new file mode 100644 index 000000000..1c4ffb55b --- /dev/null +++ b/keyboards/8pack/8pack.h | |||
@@ -0,0 +1,11 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #include "quantum.h" | ||
4 | |||
5 | #ifdef KEYBOARD_8pack_rev11 | ||
6 | #include "rev11.h" | ||
7 | #endif | ||
8 | |||
9 | #ifdef KEYBOARD_8pack_rev12 | ||
10 | #include "rev12.h" | ||
11 | #endif \ No newline at end of file | ||
diff --git a/keyboards/8pack/config.h b/keyboards/8pack/config.h new file mode 100644 index 000000000..88bd1f351 --- /dev/null +++ b/keyboards/8pack/config.h | |||
@@ -0,0 +1,39 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #include "config_common.h" | ||
4 | |||
5 | /* USB Device descriptor parameter */ | ||
6 | #define VENDOR_ID 0xFEED | ||
7 | #define PRODUCT_ID 0x2171 | ||
8 | #define MANUFACTURER Charles Garcia | ||
9 | #define PRODUCT 8-Pack | ||
10 | |||
11 | /* COL2ROW or ROW2COL */ | ||
12 | #define DIODE_DIRECTION COL2ROW | ||
13 | |||
14 | /* Set 0 if debouncing isn't needed */ | ||
15 | #define DEBOUNCE 5 | ||
16 | |||
17 | /* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */ | ||
18 | #define LOCKING_SUPPORT_ENABLE | ||
19 | |||
20 | /* Locking resynchronize hack */ | ||
21 | #define LOCKING_RESYNC_ENABLE | ||
22 | |||
23 | /* key matrix size */ | ||
24 | #define MATRIX_ROWS 2 | ||
25 | #define MATRIX_COLS 4 | ||
26 | |||
27 | /* key matrix pins */ | ||
28 | |||
29 | #define DIRECT_PINS { { F4, F5, F6, F7 }, { B1, B3, B2, B6 } } | ||
30 | |||
31 | #define BACKLIGHT_LED_COUNT 8 | ||
32 | #undef BACKLIGHT_PIN | ||
33 | #define BACKLIGHT_PINS { D1, D0, D4, C6, D7, E6, B4, B5 } | ||
34 | #define BACKLIGHT_LEVELS 8 | ||
35 | |||
36 | // ws2812 options | ||
37 | #define RGB_DI_PIN D2 // pin the DI on the ws2812 is hooked-up to | ||
38 | #define RGBLED_NUM 8 // number of LEDs | ||
39 | #define RGBLIGHT_ANIMATIONS | ||
diff --git a/keyboards/8pack/info.json b/keyboards/8pack/info.json new file mode 100644 index 000000000..82122b8f7 --- /dev/null +++ b/keyboards/8pack/info.json | |||
@@ -0,0 +1,21 @@ | |||
1 | { | ||
2 | "keyboard_name": "8-Pack", | ||
3 | "url": "https://github.com/cgarcia2097/8-Pack", | ||
4 | "maintainer": "Charles Garcia", | ||
5 | "width": 4, | ||
6 | "height": 2, | ||
7 | "layouts": { | ||
8 | "LAYOUT": { | ||
9 | "layout": [ | ||
10 | {"x":0, "y":0}, | ||
11 | {"x":1, "y":0}, | ||
12 | {"x":2, "y":0}, | ||
13 | {"x":3, "y":0}, | ||
14 | {"x":0, "y":1}, | ||
15 | {"x":1, "y":1}, | ||
16 | {"x":2, "y":1}, | ||
17 | {"x":3, "y":1} | ||
18 | ] | ||
19 | } | ||
20 | } | ||
21 | } \ No newline at end of file | ||
diff --git a/keyboards/8pack/keymaps/default/keymap.c b/keyboards/8pack/keymaps/default/keymap.c new file mode 100644 index 000000000..aa1aa9170 --- /dev/null +++ b/keyboards/8pack/keymaps/default/keymap.c | |||
@@ -0,0 +1,12 @@ | |||
1 | #include QMK_KEYBOARD_H | ||
2 | |||
3 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
4 | [0] = LAYOUT( | ||
5 | KC_V, KC_C, KC_X, MO(1), | ||
6 | KC_A, KC_S, KC_D, KC_F | ||
7 | ), | ||
8 | [1] = LAYOUT( | ||
9 | RGB_TOG, RGB_RMOD, RGB_MOD, KC_NO, | ||
10 | RESET, BL_DEC, BL_INC, BL_TOGG | ||
11 | ) | ||
12 | }; | ||
diff --git a/keyboards/8pack/readme.md b/keyboards/8pack/readme.md new file mode 100644 index 000000000..ad5df536a --- /dev/null +++ b/keyboards/8pack/readme.md | |||
@@ -0,0 +1,13 @@ | |||
1 | # 8-Pack Macropad | ||
2 | |||
3 | An open source 2x4 macropad designed by Charles Garcia. | ||
4 | |||
5 | Keyboard Maintainer: [Charles Garcia](https://github.com/cgarcia2097) | ||
6 | Hardware Supported: 8-Pack Macropad PCB | ||
7 | Hardware Availability: [8-Pack Github](https://github.com/cgarcia2097/8-Pack) | ||
8 | |||
9 | Make example for this keyboard (after setting up your build environment): | ||
10 | |||
11 | make 8pack:default | ||
12 | |||
13 | 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). \ No newline at end of file | ||
diff --git a/keyboards/8pack/rev11/config.h b/keyboards/8pack/rev11/config.h new file mode 100644 index 000000000..83ad51ada --- /dev/null +++ b/keyboards/8pack/rev11/config.h | |||
@@ -0,0 +1,3 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #define DEVICE_VER 0x0001 | ||
diff --git a/keyboards/8pack/rev11/rev11.c b/keyboards/8pack/rev11/rev11.c new file mode 100644 index 000000000..c54ecbe87 --- /dev/null +++ b/keyboards/8pack/rev11/rev11.c | |||
@@ -0,0 +1 @@ | |||
#include "rev11.h" | |||
diff --git a/keyboards/8pack/rev11/rev11.h b/keyboards/8pack/rev11/rev11.h new file mode 100644 index 000000000..ebf8529ad --- /dev/null +++ b/keyboards/8pack/rev11/rev11.h | |||
@@ -0,0 +1,11 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #include "8pack.h" | ||
4 | |||
5 | #define LAYOUT( \ | ||
6 | K00, K01, K02, K03, \ | ||
7 | K10, K11, K12, K13 \ | ||
8 | ) { \ | ||
9 | { K13, K12, K11, K10 }, \ | ||
10 | { K03, K02, K01, K00 } \ | ||
11 | } | ||
diff --git a/keyboards/8pack/rev11/rules.mk b/keyboards/8pack/rev11/rules.mk new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/keyboards/8pack/rev11/rules.mk | |||
diff --git a/keyboards/8pack/rev12/config.h b/keyboards/8pack/rev12/config.h new file mode 100644 index 000000000..9a527501a --- /dev/null +++ b/keyboards/8pack/rev12/config.h | |||
@@ -0,0 +1,3 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #define DEVICE_VER 0x0002 | ||
diff --git a/keyboards/8pack/rev12/rev12.c b/keyboards/8pack/rev12/rev12.c new file mode 100644 index 000000000..b2d091af4 --- /dev/null +++ b/keyboards/8pack/rev12/rev12.c | |||
@@ -0,0 +1 @@ | |||
#include "rev12.h" | |||
diff --git a/keyboards/8pack/rev12/rev12.h b/keyboards/8pack/rev12/rev12.h new file mode 100644 index 000000000..3efeb06de --- /dev/null +++ b/keyboards/8pack/rev12/rev12.h | |||
@@ -0,0 +1,11 @@ | |||
1 | #pragma once | ||
2 | |||
3 | #include "8pack.h" | ||
4 | |||
5 | #define LAYOUT( \ | ||
6 | K00, K01, K02, K03, \ | ||
7 | K10, K11, K12, K13 \ | ||
8 | ) { \ | ||
9 | { K03, K02, K01, K00 }, \ | ||
10 | { K13, K12, K11, K10 } \ | ||
11 | } | ||
diff --git a/keyboards/8pack/rev12/rules.mk b/keyboards/8pack/rev12/rules.mk new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/keyboards/8pack/rev12/rules.mk | |||
diff --git a/keyboards/8pack/rules.mk b/keyboards/8pack/rules.mk new file mode 100644 index 000000000..97496c8f2 --- /dev/null +++ b/keyboards/8pack/rules.mk | |||
@@ -0,0 +1,63 @@ | |||
1 | # MCU name | ||
2 | MCU = atmega32u4 | ||
3 | |||
4 | # Processor frequency. | ||
5 | # This will define a symbol, F_CPU, in all source code files equal to the | ||
6 | # processor frequency in Hz. You can then use this symbol in your source code to | ||
7 | # calculate timings. Do NOT tack on a 'UL' at the end, this will be done | ||
8 | # automatically to create a 32-bit value in your source code. | ||
9 | # | ||
10 | # This will be an integer division of F_USB below, as it is sourced by | ||
11 | # F_USB after it has run through any CPU prescalers. Note that this value | ||
12 | # does not *change* the processor frequency - it should merely be updated to | ||
13 | # reflect the processor speed set externally so that the code can use accurate | ||
14 | # software delays. | ||
15 | F_CPU = 16000000 | ||
16 | |||
17 | # | ||
18 | # LUFA specific | ||
19 | # | ||
20 | # Target architecture (see library "Board Types" documentation). | ||
21 | ARCH = AVR8 | ||
22 | |||
23 | # Input clock frequency. | ||
24 | # This will define a symbol, F_USB, in all source code files equal to the | ||
25 | # input clock frequency (before any prescaling is performed) in Hz. This value may | ||
26 | # differ from F_CPU if prescaling is used on the latter, and is required as the | ||
27 | # raw input clock is fed directly to the PLL sections of the AVR for high speed | ||
28 | # clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL' | ||
29 | # at the end, this will be done automatically to create a 32-bit value in your | ||
30 | # source code. | ||
31 | # | ||
32 | # If no clock division is performed on the input clock inside the AVR (via the | ||
33 | # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. | ||
34 | F_USB = $(F_CPU) | ||
35 | |||
36 | # Interrupt driven control endpoint task(+60) | ||
37 | OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT | ||
38 | |||
39 | # Bootloader selection | ||
40 | # Teensy halfkay | ||
41 | # Pro Micro caterina | ||
42 | # Atmel DFU atmel-dfu | ||
43 | # LUFA DFU lufa-dfu | ||
44 | # QMK DFU qmk-dfu | ||
45 | # atmega32a bootloadHID | ||
46 | BOOTLOADER = caterina | ||
47 | |||
48 | # Build Options | ||
49 | # comment out to disable the options. | ||
50 | # | ||
51 | BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000) | ||
52 | MOUSEKEY_ENABLE = no # Mouse keys(+4700) | ||
53 | EXTRAKEY_ENABLE = no # Audio control and System control(+450) | ||
54 | CONSOLE_ENABLE = yes # Console for debug(+400) | ||
55 | COMMAND_ENABLE = yes # Commands for debug and configuration | ||
56 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | ||
57 | NKRO_ENABLE = no # USB Nkey Rollover - if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | ||
58 | BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality | ||
59 | AUDIO_ENABLE = no | ||
60 | RGBLIGHT_ENABLE = yes | ||
61 | OLED_DRIVER_ENABLE = no | ||
62 | |||
63 | DEFAULT_FOLDER = 8pack/rev12 | ||