diff options
| author | Joe Wasson <jwasson+github@gmail.com> | 2018-03-11 17:58:23 -0700 |
|---|---|---|
| committer | Jack Humbert <jack.humb@gmail.com> | 2018-03-12 14:22:56 -0400 |
| commit | 2dacf25f284551fa423bfdb309b4ad99e4253095 (patch) | |
| tree | c7d9d89b46754d2b64f59531c63fa77aa97b6ea2 | |
| parent | bfa34d02b0d6f02c515774a8c566937fd1de9911 (diff) | |
| download | qmk_firmware-2dacf25f284551fa423bfdb309b4ad99e4253095.tar.gz qmk_firmware-2dacf25f284551fa423bfdb309b4ad99e4253095.zip | |
Add layout support for contra.
| -rwxr-xr-x | keyboards/contra/contra.h | 48 | ||||
| -rwxr-xr-x | keyboards/contra/rules.mk | 3 | ||||
| -rw-r--r-- | keyboards/planck/rules.mk | 5 | ||||
| -rw-r--r-- | layouts/community/ortho_4x12/bakingpy/rules.mk | 2 |
4 files changed, 45 insertions, 13 deletions
diff --git a/keyboards/contra/contra.h b/keyboards/contra/contra.h index e9f9c5418..873429b53 100755 --- a/keyboards/contra/contra.h +++ b/keyboards/contra/contra.h | |||
| @@ -3,16 +3,44 @@ | |||
| 3 | 3 | ||
| 4 | #include "quantum.h" | 4 | #include "quantum.h" |
| 5 | 5 | ||
| 6 | #define KEYMAP( \ | 6 | #define LAYOUT_grid( \ |
| 7 | K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, \ | 7 | K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, \ |
| 8 | K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, \ | 8 | K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, \ |
| 9 | K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, \ | 9 | K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, \ |
| 10 | K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311 \ | 10 | K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311 \ |
| 11 | ) { \ | 11 | ) { \ |
| 12 | { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011 }, \ | 12 | { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011 }, \ |
| 13 | { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111 }, \ | 13 | { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111 }, \ |
| 14 | { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211 }, \ | 14 | { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211 }, \ |
| 15 | { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311 } \ | 15 | { K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311 } \ |
| 16 | } | 16 | } |
| 17 | 17 | ||
| 18 | #endif \ No newline at end of file | 18 | #define LAYOUT_mit( \ |
| 19 | K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, \ | ||
| 20 | K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, \ | ||
| 21 | K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, \ | ||
| 22 | K300, K301, K302, K303, K304, K305, K307, K308, K309, K310, K311 \ | ||
| 23 | ) { \ | ||
| 24 | { K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011 }, \ | ||
| 25 | { K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111 }, \ | ||
| 26 | { K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211 }, \ | ||
| 27 | { K300, K301, K302, K303, K304, K305, K305, K307, K308, K309, K310, K311 } \ | ||
| 28 | } | ||
| 29 | |||
| 30 | #define KC_LAYOUT_grid( \ | ||
| 31 | K000, K001, K002, K003, K004, K005, K006, K007, K008, K009, K010, K011, \ | ||
| 32 | K100, K101, K102, K103, K104, K105, K106, K107, K108, K109, K110, K111, \ | ||
| 33 | K200, K201, K202, K203, K204, K205, K206, K207, K208, K209, K210, K211, \ | ||
| 34 | K300, K301, K302, K303, K304, K305, K306, K307, K308, K309, K310, K311 \ | ||
| 35 | ) \ | ||
| 36 | LAYOUT_grid( \ | ||
| 37 | KC_##K000, KC_##K001, KC_##K002, KC_##K003, KC_##K004, KC_##K005, KC_##K006, KC_##K007, KC_##K008, KC_##K009, KC_##K010, KC_##K011, \ | ||
| 38 | KC_##K100, KC_##K101, KC_##K102, KC_##K103, KC_##K104, KC_##K105, KC_##K106, KC_##K107, KC_##K108, KC_##K109, KC_##K110, KC_##K111, \ | ||
| 39 | KC_##K200, KC_##K201, KC_##K202, KC_##K203, KC_##K204, KC_##K205, KC_##K206, KC_##K207, KC_##K208, KC_##K209, KC_##K210, KC_##K211, \ | ||
| 40 | KC_##K300, KC_##K301, KC_##K302, KC_##K303, KC_##K304, KC_##K305, KC_##K306, KC_##K307, KC_##K308, KC_##K309, KC_##K310, KC_##K311 \ | ||
| 41 | ) | ||
| 42 | #define KEYMAP LAYOUT_grid | ||
| 43 | #define LAYOUT_ortho_4x12 LAYOUT_grid | ||
| 44 | #define KC_LAYOUT_ortho_4x12 KC_LAYOUT_grid | ||
| 45 | |||
| 46 | #endif | ||
diff --git a/keyboards/contra/rules.mk b/keyboards/contra/rules.mk index ca2945e63..a926dfc03 100755 --- a/keyboards/contra/rules.mk +++ b/keyboards/contra/rules.mk | |||
| @@ -56,3 +56,6 @@ MIDI_ENABLE = no # MIDI controls | |||
| 56 | UNICODE_ENABLE = no # Unicode | 56 | UNICODE_ENABLE = no # Unicode |
| 57 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID | 57 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID |
| 58 | AUDIO_ENABLE = no # Audio output on port C6 | 58 | AUDIO_ENABLE = no # Audio output on port C6 |
| 59 | |||
| 60 | LAYOUTS = ortho_4x12 planck_mit planck_grid | ||
| 61 | LAYOUTS_HAS_RGB = no | ||
diff --git a/keyboards/planck/rules.mk b/keyboards/planck/rules.mk index 4d882d0b0..511c06d70 100644 --- a/keyboards/planck/rules.mk +++ b/keyboards/planck/rules.mk | |||
| @@ -36,7 +36,7 @@ F_USB = $(F_CPU) | |||
| 36 | 36 | ||
| 37 | # Bootloader | 37 | # Bootloader |
| 38 | # This definition is optional, and if your keyboard supports multiple bootloaders of | 38 | # This definition is optional, and if your keyboard supports multiple bootloaders of |
| 39 | # different sizes, comment this out, and the correct address will be loaded | 39 | # different sizes, comment this out, and the correct address will be loaded |
| 40 | # automatically (+60). See bootloader.mk for all options. | 40 | # automatically (+60). See bootloader.mk for all options. |
| 41 | ifeq ($(strip $(KEYBOARD)), planck/rev3) | 41 | ifeq ($(strip $(KEYBOARD)), planck/rev3) |
| 42 | BOOTLOADER = atmel-dfu | 42 | BOOTLOADER = atmel-dfu |
| @@ -55,7 +55,7 @@ endif | |||
| 55 | OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT | 55 | OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT |
| 56 | 56 | ||
| 57 | # Build Options | 57 | # Build Options |
| 58 | # change to "no" to disable the options, or define them in the Makefile in | 58 | # change to "no" to disable the options, or define them in the Makefile in |
| 59 | # the appropriate keymap folder that will get included automatically | 59 | # the appropriate keymap folder that will get included automatically |
| 60 | # | 60 | # |
| 61 | BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000) | 61 | BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000) |
| @@ -76,5 +76,6 @@ API_SYSEX_ENABLE = no | |||
| 76 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | 76 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend |
| 77 | 77 | ||
| 78 | LAYOUTS = ortho_4x12 planck_mit planck_grid | 78 | LAYOUTS = ortho_4x12 planck_mit planck_grid |
| 79 | LAYOUTS_HAS_RGB = no | ||
| 79 | 80 | ||
| 80 | DEFAULT_FOLDER = planck/rev5 | 81 | DEFAULT_FOLDER = planck/rev5 |
diff --git a/layouts/community/ortho_4x12/bakingpy/rules.mk b/layouts/community/ortho_4x12/bakingpy/rules.mk index 45ad26239..02899eafe 100644 --- a/layouts/community/ortho_4x12/bakingpy/rules.mk +++ b/layouts/community/ortho_4x12/bakingpy/rules.mk | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | # Enable RGB if not a Planck | 1 | # Enable RGB if not a Planck |
| 2 | ifeq (,$(findstring planck,$(KEYBOARD))) | 2 | ifeq ($(LAYOUTS_HAS_RGB),yes) |
| 3 | RGBLIGHT_ENABLE = yes | 3 | RGBLIGHT_ENABLE = yes |
| 4 | endif | 4 | endif |
