diff options
| author | Maarten Dekkers <maartenn2001@gmail.com> | 2017-11-19 11:55:13 +0100 |
|---|---|---|
| committer | Jack Humbert <jack.humb@gmail.com> | 2017-11-22 11:19:05 -0500 |
| commit | b8217eeff44b03680046144b785ad8c2d93eb710 (patch) | |
| tree | 8fd41d03fb3c74c7920cbb14bca37fce4511a66a | |
| parent | dcc363390f47ec23fdbc04bb56bb03a3cbf310e6 (diff) | |
| download | qmk_firmware-b8217eeff44b03680046144b785ad8c2d93eb710.tar.gz qmk_firmware-b8217eeff44b03680046144b785ad8c2d93eb710.zip | |
Add maartenwut's handwire build
| -rwxr-xr-x | keyboards/handwired/maartenwut/config.h | 45 | ||||
| -rwxr-xr-x | keyboards/handwired/maartenwut/keymaps/default/keymap.c | 46 | ||||
| -rwxr-xr-x | keyboards/handwired/maartenwut/maartenwut.c | 13 | ||||
| -rwxr-xr-x | keyboards/handwired/maartenwut/maartenwut.h | 23 | ||||
| -rwxr-xr-x | keyboards/handwired/maartenwut/rules.mk | 67 |
5 files changed, 194 insertions, 0 deletions
diff --git a/keyboards/handwired/maartenwut/config.h b/keyboards/handwired/maartenwut/config.h new file mode 100755 index 000000000..066f13856 --- /dev/null +++ b/keyboards/handwired/maartenwut/config.h | |||
| @@ -0,0 +1,45 @@ | |||
| 1 | #ifndef CONFIG_H | ||
| 2 | #define CONFIG_H | ||
| 3 | |||
| 4 | #include "config_common.h" | ||
| 5 | |||
| 6 | /* USB Device descriptor parameter */ | ||
| 7 | #define VENDOR_ID 0xBB80 | ||
| 8 | #define PRODUCT_ID 0x050D | ||
| 9 | #define DEVICE_VER 0x0001 | ||
| 10 | #define MANUFACTURER Maartenwut | ||
| 11 | #define PRODUCT Ortho | ||
| 12 | #define DESCRIPTION Handwired ortholinear keyboard | ||
| 13 | |||
| 14 | /* key matrix size */ | ||
| 15 | #define MATRIX_ROWS 5 | ||
| 16 | #define MATRIX_COLS 14 | ||
| 17 | /* | ||
| 18 | * Keyboard Matrix Assignments | ||
| 19 | * | ||
| 20 | * Change this to how you wired your keyboard | ||
| 21 | * COLS: AVR pins used for columns, left to right | ||
| 22 | * ROWS: AVR pins used for rows, top to bottom | ||
| 23 | * DIODE_DIRECTION: COL2ROW = COL = Anode (+), ROW = Cathode (-, marked on diode) | ||
| 24 | * ROW2COL = ROW = Anode (+), COL = Cathode (-, marked on diode) | ||
| 25 | * | ||
| 26 | */ | ||
| 27 | #define MATRIX_ROW_PINS { D4, D0, D1, D2, D3 } | ||
| 28 | #define MATRIX_COL_PINS { C6, D7, E6, B4, B5, B6, B7, D6, F0, F1, F4, F5, F6, F7 } | ||
| 29 | #define UNUSED_PINS | ||
| 30 | |||
| 31 | /* COL2ROW or ROW2COL */ | ||
| 32 | #define DIODE_DIRECTION COL2ROW | ||
| 33 | |||
| 34 | /* Debounce reduces chatter (unintended double-presses) - set 0 if debouncing is not needed */ | ||
| 35 | #define DEBOUNCING_DELAY 5 | ||
| 36 | |||
| 37 | /* key combination for magic key command */ | ||
| 38 | #define IS_COMMAND() ( \ | ||
| 39 | keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT)) \ | ||
| 40 | ) | ||
| 41 | |||
| 42 | #define QMK_ESC_OUTPUT C6 // usually COL | ||
| 43 | #define QMK_ESC_INPUT D0 // usually ROW | ||
| 44 | |||
| 45 | #endif \ No newline at end of file | ||
diff --git a/keyboards/handwired/maartenwut/keymaps/default/keymap.c b/keyboards/handwired/maartenwut/keymaps/default/keymap.c new file mode 100755 index 000000000..1c9eff9d8 --- /dev/null +++ b/keyboards/handwired/maartenwut/keymaps/default/keymap.c | |||
| @@ -0,0 +1,46 @@ | |||
| 1 | #include "maartenwut.h" | ||
| 2 | |||
| 3 | #define _MA 0 | ||
| 4 | #define _NU 1 | ||
| 5 | #define _FL 2 | ||
| 6 | #define _GA 3 | ||
| 7 | #define _AR 4 | ||
| 8 | |||
| 9 | #define _______ KC_TRNS | ||
| 10 | #define XXXXXXX KC_NO | ||
| 11 | |||
| 12 | #define LSHIFT OSM(MOD_LSFT) | ||
| 13 | #define SPACE LT(_AR, KC_SPC) | ||
| 14 | |||
| 15 | const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { | ||
| 16 | [_MA] = KEYMAP( | ||
| 17 | KC_GRV, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, | ||
| 18 | KC_ESC, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS, | ||
| 19 | KC_TAB, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_DEL, KC_ENT, | ||
| 20 | LSHIFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_PSCR, | ||
| 21 | KC_LCTL, KC_LGUI, KC_LALT, MO(_NU), SPACE, KC_SPC, MO(_FL), KC_RALT, KC_LEFT, KC_DOWN, KC_RGHT), | ||
| 22 | [_NU] = KEYMAP( | ||
| 23 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 24 | _______, KC_7, KC_8, KC_9, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 25 | KC_CAPS, KC_4, KC_5, KC_6, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 26 | _______, KC_1, KC_2, KC_3, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 27 | _______, KC_0, _______, _______, _______, _______, _______, _______, _______, _______, _______), | ||
| 28 | [_FL] = KEYMAP( | ||
| 29 | _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_MPLY, | ||
| 30 | RESET, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 31 | _______, _______, _______, _______, _______, TG(_GA), _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 32 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 33 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______), | ||
| 34 | [_GA] = KEYMAP( | ||
| 35 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 36 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 37 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 38 | KC_LSFT, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 39 | _______, _______, _______, _______, KC_SPC, _______, _______, _______, _______, _______, _______), | ||
| 40 | [_AR] = KEYMAP( | ||
| 41 | _______, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, | ||
| 42 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 43 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 44 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, | ||
| 45 | _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______) | ||
| 46 | }; \ No newline at end of file | ||
diff --git a/keyboards/handwired/maartenwut/maartenwut.c b/keyboards/handwired/maartenwut/maartenwut.c new file mode 100755 index 000000000..6a7c5cee6 --- /dev/null +++ b/keyboards/handwired/maartenwut/maartenwut.c | |||
| @@ -0,0 +1,13 @@ | |||
| 1 | #include "maartenwut.h" | ||
| 2 | |||
| 3 | void matrix_init_kb(void) { | ||
| 4 | // put your keyboard start-up code here | ||
| 5 | // runs once when the firmware starts up | ||
| 6 | |||
| 7 | matrix_init_user(); | ||
| 8 | } | ||
| 9 | void matrix_scan_kb(void) { | ||
| 10 | // put your looping keyboard code here | ||
| 11 | // runs every cycle (a lot) | ||
| 12 | matrix_scan_user(); | ||
| 13 | }; \ No newline at end of file | ||
diff --git a/keyboards/handwired/maartenwut/maartenwut.h b/keyboards/handwired/maartenwut/maartenwut.h new file mode 100755 index 000000000..0e47d6386 --- /dev/null +++ b/keyboards/handwired/maartenwut/maartenwut.h | |||
| @@ -0,0 +1,23 @@ | |||
| 1 | #ifndef MAARTENWUT_H | ||
| 2 | #define MAARTENWUT_H | ||
| 3 | |||
| 4 | #include "quantum.h" | ||
| 5 | |||
| 6 | #define XXX KC_NO | ||
| 7 | |||
| 8 | #define KEYMAP( \ | ||
| 9 | k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d, \ | ||
| 10 | k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d, \ | ||
| 11 | k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2d, \ | ||
| 12 | k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d, \ | ||
| 13 | k40, k41, k42, k43, k45, k47, k49, k4a, k4b, k4c, k4d \ | ||
| 14 | ) \ | ||
| 15 | { \ | ||
| 16 | {k00, k01, k02, k03, k04, k05, k06, k07, k08, k09, k0a, k0b, k0c, k0d}, \ | ||
| 17 | {k10, k11, k12, k13, k14, k15, k16, k17, k18, k19, k1a, k1b, k1c, k1d}, \ | ||
| 18 | {k20, k21, k22, k23, k24, k25, k26, k27, k28, k29, k2a, k2b, k2c, k2d}, \ | ||
| 19 | {k30, k31, k32, k33, k34, k35, k36, k37, k38, k39, k3a, k3b, k3c, k3d}, \ | ||
| 20 | {k40, k41, k42, k43, XXX, k45, XXX, k47, XXX, k49, k4a, k4b, k4c, k4d} \ | ||
| 21 | } | ||
| 22 | |||
| 23 | #endif \ No newline at end of file | ||
diff --git a/keyboards/handwired/maartenwut/rules.mk b/keyboards/handwired/maartenwut/rules.mk new file mode 100755 index 000000000..7ed63c65e --- /dev/null +++ b/keyboards/handwired/maartenwut/rules.mk | |||
| @@ -0,0 +1,67 @@ | |||
| 1 | |||
| 2 | # MCU name | ||
| 3 | MCU = atmega32u4 | ||
| 4 | |||
| 5 | # Processor frequency. | ||
| 6 | # This will define a symbol, F_CPU, in all source code files equal to the | ||
| 7 | # processor frequency in Hz. You can then use this symbol in your source code to | ||
| 8 | # calculate timings. Do NOT tack on a 'UL' at the end, this will be done | ||
| 9 | # automatically to create a 32-bit value in your source code. | ||
| 10 | # | ||
| 11 | # This will be an integer division of F_USB below, as it is sourced by | ||
| 12 | # F_USB after it has run through any CPU prescalers. Note that this value | ||
| 13 | # does not *change* the processor frequency - it should merely be updated to | ||
| 14 | # reflect the processor speed set externally so that the code can use accurate | ||
| 15 | # software delays. | ||
| 16 | F_CPU = 16000000 | ||
| 17 | |||
| 18 | |||
| 19 | # | ||
| 20 | # LUFA specific | ||
| 21 | # | ||
| 22 | # Target architecture (see library "Board Types" documentation). | ||
| 23 | ARCH = AVR8 | ||
| 24 | |||
| 25 | # Input clock frequency. | ||
| 26 | # This will define a symbol, F_USB, in all source code files equal to the | ||
| 27 | # input clock frequency (before any prescaling is performed) in Hz. This value may | ||
| 28 | # differ from F_CPU if prescaling is used on the latter, and is required as the | ||
| 29 | # raw input clock is fed directly to the PLL sections of the AVR for high speed | ||
| 30 | # clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL' | ||
| 31 | # at the end, this will be done automatically to create a 32-bit value in your | ||
| 32 | # source code. | ||
| 33 | # | ||
| 34 | # If no clock division is performed on the input clock inside the AVR (via the | ||
| 35 | # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. | ||
| 36 | F_USB = $(F_CPU) | ||
| 37 | |||
| 38 | # Interrupt driven control endpoint task(+60) | ||
| 39 | OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT | ||
| 40 | |||
| 41 | |||
| 42 | # Boot Section Size in *bytes* | ||
| 43 | # Teensy halfKay 512 | ||
| 44 | # Teensy++ halfKay 1024 | ||
| 45 | # Atmel DFU loader 4096 | ||
| 46 | # LUFA bootloader 4096 | ||
| 47 | # USBaspLoader 2048 | ||
| 48 | OPT_DEFS += -DBOOTLOADER_SIZE=4096 | ||
| 49 | |||
| 50 | |||
| 51 | # Build Options | ||
| 52 | # change yes to no to disable | ||
| 53 | # | ||
| 54 | BOOTMAGIC_ENABLE = no # Virtual DIP switch configuration(+1000) | ||
| 55 | MOUSEKEY_ENABLE = yes # Mouse keys(+4700) | ||
| 56 | EXTRAKEY_ENABLE = yes # Audio control and System control(+450) | ||
| 57 | CONSOLE_ENABLE = no # Console for debug(+400) | ||
| 58 | COMMAND_ENABLE = no # Commands for debug and configuration | ||
| 59 | # Do not enable SLEEP_LED_ENABLE. it uses the same timer as BACKLIGHT_ENABLE | ||
| 60 | SLEEP_LED_ENABLE = no # Breathing sleep LED during USB suspend | ||
| 61 | # if this doesn't work, see here: https://github.com/tmk/tmk_keyboard/wiki/FAQ#nkro-doesnt-work | ||
| 62 | NKRO_ENABLE = no # USB Nkey Rollover | ||
| 63 | BACKLIGHT_ENABLE = no # Enable keyboard backlight functionality on B7 by default | ||
| 64 | MIDI_ENABLE = no # MIDI controls | ||
| 65 | UNICODE_ENABLE = no # Unicode | ||
| 66 | BLUETOOTH_ENABLE = no # Enable Bluetooth with the Adafruit EZ-Key HID | ||
| 67 | AUDIO_ENABLE = no # Audio output on port C6 | ||
