diff options
author | MechMerlin <30334081+mechmerlin@users.noreply.github.com> | 2020-04-16 12:28:49 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-16 12:28:49 -0700 |
commit | 4a92dd327c7df11f10cbe85c5eb5868330062f2b (patch) | |
tree | f71819c285fdd8c0cba2ee6298679a58ccf66d2e | |
parent | 7873b49d40cef838268575d5b31a1d377b218787 (diff) | |
download | qmk_firmware-4a92dd327c7df11f10cbe85c5eb5868330062f2b.tar.gz qmk_firmware-4a92dd327c7df11f10cbe85c5eb5868330062f2b.zip |
[Keyboard] Botanical Keyboards FM2U (#8819)
* initial commit for fm2u keyboard
* add fm2u keyboard along with VIA keymap
* add meme LAYOUT support
* minor cleanups
* fixup layout macro names
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/config.h | 55 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/fm2u.c | 17 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/fm2u.h | 46 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/info.json | 56 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/keymaps/default/keymap.c | 25 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/keymaps/via/keymap.c | 37 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/keymaps/via/rules.mk | 4 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/readme.md | 13 | ||||
-rw-r--r-- | keyboards/botanicalkeyboards/fm2u/rules.mk | 32 |
9 files changed, 285 insertions, 0 deletions
diff --git a/keyboards/botanicalkeyboards/fm2u/config.h b/keyboards/botanicalkeyboards/fm2u/config.h new file mode 100644 index 000000000..944b7b3b2 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/config.h | |||
@@ -0,0 +1,55 @@ | |||
1 | /* | ||
2 | Copyright 2020 mechmerlin | ||
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 0x6969 | ||
24 | #define PRODUCT_ID 0x0001 | ||
25 | #define DEVICE_VER 0x0001 | ||
26 | #define MANUFACTURER botanicalkeyboards | ||
27 | #define PRODUCT fm2u | ||
28 | #define DESCRIPTION A 1 key macropad | ||
29 | |||
30 | /* key matrix size */ | ||
31 | #define MATRIX_ROWS 1 | ||
32 | #define MATRIX_COLS 1 | ||
33 | |||
34 | /* Keyboard Matrix Assignments */ | ||
35 | #define DIRECT_PINS { \ | ||
36 | { C4 } \ | ||
37 | } | ||
38 | |||
39 | /* | ||
40 | * Keyboard Matrix Assignments | ||
41 | * | ||
42 | * Change this to how you wired your keyboard | ||
43 | * COLS: AVR pins used for columns, left to right | ||
44 | * ROWS: AVR pins used for rows, top to bottom | ||
45 | * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) | ||
46 | * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) | ||
47 | * | ||
48 | */ | ||
49 | #define UNUSED_PINS | ||
50 | |||
51 | /* COL2ROW, ROW2COL*/ | ||
52 | #define DIODE_DIRECTION COL2ROW | ||
53 | |||
54 | |||
55 | |||
diff --git a/keyboards/botanicalkeyboards/fm2u/fm2u.c b/keyboards/botanicalkeyboards/fm2u/fm2u.c new file mode 100644 index 000000000..9729e5eec --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/fm2u.c | |||
@@ -0,0 +1,17 @@ | |||
1 | /* Copyright 2020 mechmerlin | ||
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 "fm2u.h" | ||
diff --git a/keyboards/botanicalkeyboards/fm2u/fm2u.h b/keyboards/botanicalkeyboards/fm2u/fm2u.h new file mode 100644 index 000000000..eb5564afc --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/fm2u.h | |||
@@ -0,0 +1,46 @@ | |||
1 | /* Copyright 2020 mechmerlin | ||
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_100u( \ | ||
30 | k00 \ | ||
31 | ) \ | ||
32 | { \ | ||
33 | { k00 } \ | ||
34 | } | ||
35 | |||
36 | #define LAYOUT_125u LAYOUT_100u | ||
37 | #define LAYOUT_150u LAYOUT_100u | ||
38 | #define LAYOUT_175u LAYOUT_100u | ||
39 | #define LAYOUT_200u LAYOUT_100u | ||
40 | #define LAYOUT_225u LAYOUT_100u | ||
41 | #define LAYOUT_275u LAYOUT_100u | ||
42 | #define LAYOUT_300u LAYOUT_100u | ||
43 | #define LAYOUT_600u LAYOUT_100u | ||
44 | #define LAYOUT_625u LAYOUT_100u | ||
45 | #define LAYOUT_700u LAYOUT_100u | ||
46 | #define LAYOUT_iso LAYOUT_100u | ||
diff --git a/keyboards/botanicalkeyboards/fm2u/info.json b/keyboards/botanicalkeyboards/fm2u/info.json new file mode 100644 index 000000000..6831dad94 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/info.json | |||
@@ -0,0 +1,56 @@ | |||
1 | { | ||
2 | "keyboard_name": "fm2u", | ||
3 | "url": "", | ||
4 | "maintainer": "qmk", | ||
5 | "width": 1, | ||
6 | "height": 1, | ||
7 | "layouts": { | ||
8 | "LAYOUT_100u": { | ||
9 | "layout": [{"x":0, "y":0}] | ||
10 | }, | ||
11 | |||
12 | "LAYOUT_125u": { | ||
13 | "layout": [{"x":0, "y":0, "w":1.25}] | ||
14 | }, | ||
15 | |||
16 | "LAYOUT_150u": { | ||
17 | "layout": [{"x":0, "y":0, "w":1.50}] | ||
18 | }, | ||
19 | |||
20 | "LAYOUT_175u": { | ||
21 | "layout": [{"x":0, "y":0, "w":1.75}] | ||
22 | }, | ||
23 | |||
24 | "LAYOUT_200u": { | ||
25 | "layout": [{"x":0, "y":0, "w":2.00}] | ||
26 | }, | ||
27 | |||
28 | "LAYOUT_225u": { | ||
29 | "layout": [{"x":0, "y":0, "w":2.25}] | ||
30 | }, | ||
31 | |||
32 | "LAYOUT_275u": { | ||
33 | "layout": [{"x":0, "y":0, "w":2.75}] | ||
34 | }, | ||
35 | |||
36 | "LAYOUT_300u": { | ||
37 | "layout": [{"x":0, "y":0, "w":3.00}] | ||
38 | }, | ||
39 | |||
40 | "LAYOUT_600u": { | ||
41 | "layout": [{"x":0, "y":0, "w":6.00}] | ||
42 | }, | ||
43 | |||
44 | "LAYOUT_625u": { | ||
45 | "layout": [{"x":0, "y":0, "w":6.25}] | ||
46 | }, | ||
47 | |||
48 | "LAYOUT_700u": { | ||
49 | "layout": [{"x":0, "y":0, "w":7.00}] | ||
50 | }, | ||
51 | |||
52 | "LAYOUT_iso": { | ||
53 | "layout": [{"x":0.25, "y":0, "w":1.25, "h":2}] | ||
54 | } | ||
55 | } | ||
56 | } | ||
diff --git a/keyboards/botanicalkeyboards/fm2u/keymaps/default/keymap.c b/keyboards/botanicalkeyboards/fm2u/keymaps/default/keymap.c new file mode 100644 index 000000000..afefa3533 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/keymaps/default/keymap.c | |||
@@ -0,0 +1,25 @@ | |||
1 | /* Copyright 2020 mechmerlin | ||
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 | |||
19 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
20 | /* Base */ | ||
21 | [0] = LAYOUT_100u( | ||
22 | KC_B | ||
23 | ) | ||
24 | }; | ||
25 | |||
diff --git a/keyboards/botanicalkeyboards/fm2u/keymaps/via/keymap.c b/keyboards/botanicalkeyboards/fm2u/keymaps/via/keymap.c new file mode 100644 index 000000000..01b00f187 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/keymaps/via/keymap.c | |||
@@ -0,0 +1,37 @@ | |||
1 | /* Copyright 2020 mechmerlin | ||
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 | |||
19 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
20 | /* Base */ | ||
21 | [0] = LAYOUT_100u( | ||
22 | KC_B | ||
23 | ), | ||
24 | |||
25 | [1] = LAYOUT_100u( | ||
26 | KC_TRNS | ||
27 | ), | ||
28 | |||
29 | [2] = LAYOUT_100u( | ||
30 | KC_TRNS | ||
31 | ), | ||
32 | |||
33 | [3] = LAYOUT_100u( | ||
34 | KC_TRNS | ||
35 | ), | ||
36 | }; | ||
37 | |||
diff --git a/keyboards/botanicalkeyboards/fm2u/keymaps/via/rules.mk b/keyboards/botanicalkeyboards/fm2u/keymaps/via/rules.mk new file mode 100644 index 000000000..7d47e6b72 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/keymaps/via/rules.mk | |||
@@ -0,0 +1,4 @@ | |||
1 | VIA_ENABLE = yes | ||
2 | LTO_ENABLE = yes | ||
3 | |||
4 | EXTRAKEY_ENABLE = no | ||
diff --git a/keyboards/botanicalkeyboards/fm2u/readme.md b/keyboards/botanicalkeyboards/fm2u/readme.md new file mode 100644 index 000000000..511c09214 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/readme.md | |||
@@ -0,0 +1,13 @@ | |||
1 | # fm2u | ||
2 | |||
3 | A 1 key macropad with USB C and atmega32u2 microcontroller. | ||
4 | |||
5 | * Keyboard Maintainer: [MechMerlin](https://github.com/mechmerlin) | ||
6 | * Hardware Supported: fm2u PCB | ||
7 | * Hardware Availability: TBD | ||
8 | |||
9 | Make example for this keyboard (after setting up your build environment): | ||
10 | |||
11 | make botanicalkeyboards/fm2u: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). | ||
diff --git a/keyboards/botanicalkeyboards/fm2u/rules.mk b/keyboards/botanicalkeyboards/fm2u/rules.mk new file mode 100644 index 000000000..4f7f9b286 --- /dev/null +++ b/keyboards/botanicalkeyboards/fm2u/rules.mk | |||
@@ -0,0 +1,32 @@ | |||
1 | # MCU name | ||
2 | MCU = atmega32u2 | ||
3 | |||
4 | # Bootloader selection | ||
5 | # Teensy halfkay | ||
6 | # Pro Micro caterina | ||
7 | # Atmel DFU atmel-dfu | ||
8 | # LUFA DFU lufa-dfu | ||
9 | # QMK DFU qmk-dfu | ||
10 | # ATmega32A bootloadHID | ||
11 | # ATmega328P USBasp | ||
12 | BOOTLOADER = atmel-dfu | ||
13 | |||
14 | # Build Options | ||
15 | # change yes to no to disable | ||
16 | # | ||
17 | BOOTMAGIC_ENABLE = lite # Virtual DIP switch configuration | ||
18 | MOUSEKEY_ENABLE = no # Mouse keys | ||
19 | EXTRAKEY_ENABLE = yes # Audio control and System control | ||
20 | CONSOLE_ENABLE = yes # Console for debug | ||
21 | COMMAND_ENABLE = yes # Commands for debug and configuration | ||
22 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | ||
23 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | ||
24 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | ||
25 | NKRO_ENABLE = no # USB Nkey Rollover | ||
26 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality | ||
27 | RGBLIGHT_ENABLE = no # Enable keyboard RGB underglow | ||
28 | MIDI_ENABLE = no # MIDI support | ||
29 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID | ||
30 | AUDIO_ENABLE = no # Audio output on port C6 | ||
31 | FAUXCLICKY_ENABLE = no # Use buzzer to emulate clicky switches | ||
32 | HD44780_ENABLE = no # Enable support for HD44780 based LCDs | ||