From 65d3a03bd4da8f6e474759a7b8f9665ee9f45335 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 13:05:58 -0400 Subject: [PATCH 1/9] Add support for the WhirlwindFX ElementV2 keyboard. --- keyboards/whirlwind_fx_element/config.h | 14 + keyboards/whirlwind_fx_element/halconf.h | 5 + keyboards/whirlwind_fx_element/keyboard.json | 299 ++++++++++++++++++ .../keymaps/default/keymap.c | 41 +++ keyboards/whirlwind_fx_element/mcuconf.h | 6 + keyboards/whirlwind_fx_element/readme.md | 31 ++ keyboards/whirlwind_fx_element/rules.mk | 8 + .../whirlwind_fx_element.c | 132 ++++++++ 8 files changed, 536 insertions(+) create mode 100644 keyboards/whirlwind_fx_element/config.h create mode 100644 keyboards/whirlwind_fx_element/halconf.h create mode 100644 keyboards/whirlwind_fx_element/keyboard.json create mode 100644 keyboards/whirlwind_fx_element/keymaps/default/keymap.c create mode 100644 keyboards/whirlwind_fx_element/mcuconf.h create mode 100644 keyboards/whirlwind_fx_element/readme.md create mode 100644 keyboards/whirlwind_fx_element/rules.mk create mode 100644 keyboards/whirlwind_fx_element/whirlwind_fx_element.c diff --git a/keyboards/whirlwind_fx_element/config.h b/keyboards/whirlwind_fx_element/config.h new file mode 100644 index 00000000000..07d91c35570 --- /dev/null +++ b/keyboards/whirlwind_fx_element/config.h @@ -0,0 +1,14 @@ +#pragma once + +#define F_CPU 72000000 + +#define LED_NUM_LOCK_PIN B8 +#define LED_CAPS_LOCK_PIN B9 +#define LED_SCROLL_LOCK_PIN B10 + +#define IS31FL3741_I2C_ADDRESS_1 IS31FL3741_I2C_ADDRESS_GND + +#define RGB_MATRIX_DISABLE_SHARED_KEYCODES +#define RGB_MATRIX_DEFAULT_SPEED 0 + +#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_BREATHING diff --git a/keyboards/whirlwind_fx_element/halconf.h b/keyboards/whirlwind_fx_element/halconf.h new file mode 100644 index 00000000000..c4a7101379f --- /dev/null +++ b/keyboards/whirlwind_fx_element/halconf.h @@ -0,0 +1,5 @@ +#pragma once + +#define HAL_USE_I2C TRUE + +#include_next diff --git a/keyboards/whirlwind_fx_element/keyboard.json b/keyboards/whirlwind_fx_element/keyboard.json new file mode 100644 index 00000000000..8ed4cddfea6 --- /dev/null +++ b/keyboards/whirlwind_fx_element/keyboard.json @@ -0,0 +1,299 @@ +{ + "manufacturer": "WhirlwindFX", + "keyboard_name": "Element", + "maintainer": "aedanmills", + "bootloader": "stm32-dfu", + "diode_direction": "ROW2COL", + "features": { + "bootmagic": true, + "extrakey": true, + "nkro": true, + "rgb_matrix": true + }, + "build": { + "lto": true + }, + "matrix_pins": { + "rows": [ "B0", "B1", "B2", "B3", "B12", "B13", "B14", "B15" ], + "cols": [ "A0", "A1", "A2", "A3", "A4", "A5", "A6", "A7", "A8", "A9", "A10", "A13", "A14" ] + }, + "processor": "STM32F303", + "url": "https://www.whirlwindfx.com/products/element", + "usb": { + "vid": "0x0483", + "pid": "0xA33E", + "device_version": "1.0.6" + }, + "rgb_matrix": { + "driver": "is31fl3741", + "max_brightness": 200, + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0, "flags": 4}, + {"matrix": [0, 1], "x": 21, "y": 0, "flags": 4}, + {"matrix": [0, 2], "x": 31, "y": 0, "flags": 4}, + {"matrix": [0, 3], "x": 42, "y": 0, "flags": 4}, + {"matrix": [0, 4], "x": 52, "y": 0, "flags": 4}, + {"matrix": [0, 5], "x": 68, "y": 0, "flags": 4}, + {"matrix": [0, 6], "x": 78, "y": 0, "flags": 4}, + {"matrix": [0, 7], "x": 89, "y": 0, "flags": 4}, + {"matrix": [0, 8], "x": 99, "y": 0, "flags": 4}, + {"matrix": [0, 9], "x": 115, "y": 0, "flags": 4}, + {"matrix": [0, 10], "x": 125, "y": 0, "flags": 4}, + {"matrix": [0, 11], "x": 136, "y": 0, "flags": 4}, + {"matrix": [0, 12], "x": 146, "y": 0, "flags": 4}, + {"matrix": [1, 0], "x": 159, "y": 0, "flags": 4}, + {"matrix": [1, 1], "x": 169, "y": 0, "flags": 4}, + {"matrix": [1, 2], "x": 180, "y": 0, "flags": 4}, + + {"matrix": [1, 3], "x": 0, "y": 15, "flags": 4}, + {"matrix": [1, 4], "x": 10, "y": 15, "flags": 4}, + {"matrix": [1, 5], "x": 21, "y": 15, "flags": 4}, + {"matrix": [1, 6], "x": 31, "y": 15, "flags": 4}, + {"matrix": [1, 7], "x": 42, "y": 15, "flags": 4}, + {"matrix": [1, 8], "x": 52, "y": 15, "flags": 4}, + {"matrix": [1, 9], "x": 63, "y": 15, "flags": 4}, + {"matrix": [1, 10], "x": 73, "y": 15, "flags": 4}, + {"matrix": [1, 11], "x": 83, "y": 15, "flags": 4}, + {"matrix": [1, 12], "x": 94, "y": 15, "flags": 4}, + {"matrix": [2, 0], "x": 104, "y": 15, "flags": 4}, + {"matrix": [2, 1], "x": 115, "y": 15, "flags": 4}, + {"matrix": [2, 2], "x": 125, "y": 15, "flags": 4}, + {"matrix": [2, 3], "x": 141, "y": 15, "flags": 4}, + {"matrix": [2, 4], "x": 159, "y": 15, "flags": 4}, + {"matrix": [2, 5], "x": 169, "y": 15, "flags": 4}, + {"matrix": [2, 6], "x": 180, "y": 15, "flags": 4}, + {"matrix": [2, 7], "x": 193, "y": 15, "flags": 4}, + {"matrix": [2, 8], "x": 203, "y": 15, "flags": 4}, + {"matrix": [2, 9], "x": 214, "y": 15, "flags": 4}, + {"matrix": [2, 10], "x": 224, "y": 15, "flags": 4}, + + {"matrix": [2, 11], "x": 3, "y": 27, "flags": 4}, + {"matrix": [2, 12], "x": 16, "y": 27, "flags": 4}, + {"matrix": [3, 0], "x": 26, "y": 27, "flags": 4}, + {"matrix": [3, 1], "x": 36, "y": 27, "flags": 4}, + {"matrix": [3, 2], "x": 47, "y": 27, "flags": 4}, + {"matrix": [3, 3], "x": 57, "y": 27, "flags": 4}, + {"matrix": [3, 4], "x": 68, "y": 27, "flags": 4}, + {"matrix": [3, 5], "x": 78, "y": 27, "flags": 4}, + {"matrix": [3, 6], "x": 89, "y": 27, "flags": 4}, + {"matrix": [3, 7], "x": 99, "y": 27, "flags": 4}, + {"matrix": [3, 8], "x": 109, "y": 27, "flags": 4}, + {"matrix": [3, 9], "x": 120, "y": 27, "flags": 4}, + {"matrix": [3, 10], "x": 130, "y": 27, "flags": 4}, + {"matrix": [3, 11], "x": 143, "y": 27, "flags": 4}, + {"matrix": [3, 12], "x": 159, "y": 27, "flags": 4}, + {"matrix": [4, 0], "x": 169, "y": 27, "flags": 4}, + {"matrix": [4, 1], "x": 180, "y": 27, "flags": 4}, + {"matrix": [4, 2], "x": 193, "y": 27, "flags": 4}, + {"matrix": [4, 3], "x": 203, "y": 27, "flags": 4}, + {"matrix": [4, 4], "x": 214, "y": 27, "flags": 4}, + + {"matrix": [4, 5], "x": 4, "y": 40, "flags": 4}, + {"matrix": [4, 6], "x": 18, "y": 40, "flags": 4}, + {"matrix": [4, 7], "x": 29, "y": 40, "flags": 4}, + {"matrix": [4, 8], "x": 39, "y": 40, "flags": 4}, + {"matrix": [4, 9], "x": 50, "y": 40, "flags": 4}, + {"matrix": [4, 10], "x": 60, "y": 40, "flags": 4}, + {"matrix": [4, 11], "x": 70, "y": 40, "flags": 4}, + {"matrix": [4, 12], "x": 81, "y": 40, "flags": 4}, + {"matrix": [5, 0], "x": 91, "y": 40, "flags": 4}, + {"matrix": [5, 1], "x": 102, "y": 40, "flags": 4}, + {"matrix": [5, 2], "x": 112, "y": 40, "flags": 4}, + {"matrix": [5, 3], "x": 123, "y": 40, "flags": 4}, + {"matrix": [5, 4], "x": 139, "y": 40, "flags": 4}, + {"matrix": [5, 5], "x": 193, "y": 40, "flags": 4}, + {"matrix": [5, 6], "x": 203, "y": 40, "flags": 4}, + {"matrix": [5, 7], "x": 214, "y": 40, "flags": 4}, + {"matrix": [5, 8], "x": 224, "y": 34, "flags": 4}, + + {"matrix": [5, 9], "x": 7, "y": 52, "flags": 4}, + {"matrix": [5, 10], "x": 23, "y": 52, "flags": 4}, + {"matrix": [5, 11], "x": 34, "y": 52, "flags": 4}, + {"matrix": [5, 12], "x": 44, "y": 52, "flags": 4}, + {"matrix": [6, 0], "x": 55, "y": 52, "flags": 4}, + {"matrix": [6, 1], "x": 65, "y": 52, "flags": 4}, + {"matrix": [6, 2], "x": 76, "y": 52, "flags": 4}, + {"matrix": [6, 3], "x": 86, "y": 52, "flags": 4}, + {"matrix": [6, 4], "x": 96, "y": 52, "flags": 4}, + {"matrix": [6, 5], "x": 107, "y": 52, "flags": 4}, + {"matrix": [6, 6], "x": 117, "y": 52, "flags": 4}, + {"matrix": [6, 7], "x": 137, "y": 52, "flags": 4}, + {"matrix": [6, 8], "x": 169, "y": 52, "flags": 4}, + {"matrix": [6, 9], "x": 193, "y": 52, "flags": 4}, + {"matrix": [6, 10], "x": 203, "y": 52, "flags": 4}, + {"matrix": [6, 11], "x": 214, "y": 52, "flags": 4}, + {"matrix": [6, 12], "x": 224, "y": 58, "flags": 4}, + + {"matrix": [7, 0], "x": 1, "y": 64, "flags": 4}, + {"matrix": [7, 1], "x": 14, "y": 64, "flags": 4}, + {"matrix": [7, 2], "x": 27, "y": 64, "flags": 4}, + {"matrix": [7, 3], "x": 66, "y": 64, "flags": 4}, + {"matrix": [7, 4], "x": 105, "y": 64, "flags": 4}, + {"matrix": [7, 5], "x": 118, "y": 64, "flags": 4}, + {"matrix": [7, 6], "x": 131, "y": 64, "flags": 4}, + {"matrix": [7, 7], "x": 145, "y": 64, "flags": 4}, + {"matrix": [7, 8], "x": 159, "y": 64, "flags": 4}, + {"matrix": [7, 9], "x": 169, "y": 64, "flags": 4}, + {"matrix": [7, 10], "x": 180, "y": 64, "flags": 4}, + {"matrix": [7, 11], "x": 198, "y": 64, "flags": 4}, + {"matrix": [7, 12], "x": 214, "y": 64, "flags": 4} + ], + "animations": { + "solid_color": true, + "alphas_mods": true, + "gradient_up_down": true, + "gradient_left_right": true, + "breathing": true, + "band_sat": true, + "band_val": true, + "band_pinwheel_sat": true, + "band_pinwheel_val": true, + "band_spiral_sat": true, + "band_spiral_val": true, + "cycle_all": true, + "cycle_left_right": true, + "cycle_up_down": true, + "cycle_out_in": true, + "cycle_out_in_dual": true, + "rainbow_moving_chevron": true, + "cycle_pinwheel": true, + "cycle_spiral": true, + "dual_beacon": true, + "rainbow_beacon": true, + "rainbow_pinwheels": true, + "raindrops": true, + "jellybean_raindrops": true, + "hue_breathing": true, + "hue_pendulum": true, + "hue_wave": true, + "pixel_flow": true, + "pixel_rain": true, + "typing_heatmap": true, + "digital_rain": true, + "solid_reactive_simple": true, + "solid_reactive": true, + "solid_reactive_wide": true, + "solid_reactive_cross": true, + "solid_reactive_nexus": true, + "splash": true, + "multisplash": true, + "solid_splash": true + }, + "default": { + "val": 128 + }, + "led_process_limit": 4, + "led_flush_limit": 26, + "sleep": true + }, + "layouts": { + "LAYOUT_fullsize_ansi": { + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0}, + {"matrix": [0, 1], "x": 2, "y": 0}, + {"matrix": [0, 2], "x": 3, "y": 0}, + {"matrix": [0, 3], "x": 4, "y": 0}, + {"matrix": [0, 4], "x": 5, "y": 0}, + {"matrix": [0, 5], "x": 6.5, "y": 0}, + {"matrix": [0, 6], "x": 7.5, "y": 0}, + {"matrix": [0, 7], "x": 8.5, "y": 0}, + {"matrix": [0, 8], "x": 9.5, "y": 0}, + {"matrix": [0, 9], "x": 11, "y": 0}, + {"matrix": [0, 10], "x": 12, "y": 0}, + {"matrix": [0, 11], "x": 13, "y": 0}, + {"matrix": [0, 12], "x": 14, "y": 0}, + {"matrix": [1, 0], "x": 15.25, "y": 0}, + {"matrix": [1, 1], "x": 16.25, "y": 0}, + {"matrix": [1, 2], "x": 17.25, "y": 0}, + {"matrix": [1, 3], "x": 0, "y": 1.25}, + {"matrix": [1, 4], "x": 1, "y": 1.25}, + {"matrix": [1, 5], "x": 2, "y": 1.25}, + {"matrix": [1, 6], "x": 3, "y": 1.25}, + {"matrix": [1, 7], "x": 4, "y": 1.25}, + {"matrix": [1, 8], "x": 5, "y": 1.25}, + {"matrix": [1, 9], "x": 6, "y": 1.25}, + {"matrix": [1, 10], "x": 7, "y": 1.25}, + {"matrix": [1, 11], "x": 8, "y": 1.25}, + {"matrix": [1, 12], "x": 9, "y": 1.25}, + {"matrix": [2, 0], "x": 10, "y": 1.25}, + {"matrix": [2, 1], "x": 11, "y": 1.25}, + {"matrix": [2, 2], "x": 12, "y": 1.25}, + {"matrix": [2, 3], "x": 13, "y": 1.25, "w": 2}, + {"matrix": [2, 4], "x": 15.25, "y": 1.25}, + {"matrix": [2, 5], "x": 16.25, "y": 1.25}, + {"matrix": [2, 6], "x": 17.25, "y": 1.25}, + {"matrix": [2, 7], "x": 18.5, "y": 1.25}, + {"matrix": [2, 8], "x": 19.5, "y": 1.25}, + {"matrix": [2, 9], "x": 20.5, "y": 1.25}, + {"matrix": [2, 10], "x": 21.5, "y": 1.25}, + {"matrix": [2, 11], "x": 0, "y": 2.25, "w": 1.5}, + {"matrix": [2, 12], "x": 1.5, "y": 2.25}, + {"matrix": [3, 0], "x": 2.5, "y": 2.25}, + {"matrix": [3, 1], "x": 3.5, "y": 2.25}, + {"matrix": [3, 2], "x": 4.5, "y": 2.25}, + {"matrix": [3, 3], "x": 5.5, "y": 2.25}, + {"matrix": [3, 4], "x": 6.5, "y": 2.25}, + {"matrix": [3, 5], "x": 7.5, "y": 2.25}, + {"matrix": [3, 6], "x": 8.5, "y": 2.25}, + {"matrix": [3, 7], "x": 9.5, "y": 2.25}, + {"matrix": [3, 8], "x": 10.5, "y": 2.25}, + {"matrix": [3, 9], "x": 11.5, "y": 2.25}, + {"matrix": [3, 10], "x": 12.5, "y": 2.25}, + {"matrix": [3, 11], "x": 13.5, "y": 2.25, "w": 1.5}, + {"matrix": [3, 12], "x": 15.25, "y": 2.25}, + {"matrix": [4, 0], "x": 16.25, "y": 2.25}, + {"matrix": [4, 1], "x": 17.25, "y": 2.25}, + {"matrix": [4, 2], "x": 18.5, "y": 2.25}, + {"matrix": [4, 3], "x": 19.5, "y": 2.25}, + {"matrix": [4, 4], "x": 20.5, "y": 2.25}, + {"matrix": [5, 8], "x": 21.5, "y": 2.25, "h": 2}, + {"matrix": [4, 5], "x": 0, "y": 3.25, "w": 1.75}, + {"matrix": [4, 6], "x": 1.75, "y": 3.25}, + {"matrix": [4, 7], "x": 2.75, "y": 3.25}, + {"matrix": [4, 8], "x": 3.75, "y": 3.25}, + {"matrix": [4, 9], "x": 4.75, "y": 3.25}, + {"matrix": [4, 10], "x": 5.75, "y": 3.25}, + {"matrix": [4, 11], "x": 6.75, "y": 3.25}, + {"matrix": [4, 12], "x": 7.75, "y": 3.25}, + {"matrix": [5, 0], "x": 8.75, "y": 3.25}, + {"matrix": [5, 1], "x": 9.75, "y": 3.25}, + {"matrix": [5, 2], "x": 10.75, "y": 3.25}, + {"matrix": [5, 3], "x": 11.75, "y": 3.25}, + {"matrix": [5, 4], "x": 12.75, "y": 3.25, "w": 2.25}, + {"matrix": [5, 5], "x": 18.5, "y": 3.25}, + {"matrix": [5, 6], "x": 19.5, "y": 3.25}, + {"matrix": [5, 7], "x": 20.5, "y": 3.25}, + {"matrix": [5, 9], "x": 0, "y": 4.25, "w": 2.25}, + {"matrix": [5, 10], "x": 2.25, "y": 4.25}, + {"matrix": [5, 11], "x": 3.25, "y": 4.25}, + {"matrix": [5, 12], "x": 4.25, "y": 4.25}, + {"matrix": [6, 0], "x": 5.25, "y": 4.25}, + {"matrix": [6, 1], "x": 6.25, "y": 4.25}, + {"matrix": [6, 2], "x": 7.25, "y": 4.25}, + {"matrix": [6, 3], "x": 8.25, "y": 4.25}, + {"matrix": [6, 4], "x": 9.25, "y": 4.25}, + {"matrix": [6, 5], "x": 10.25, "y": 4.25}, + {"matrix": [6, 6], "x": 11.25, "y": 4.25}, + {"matrix": [6, 7], "x": 12.25, "y": 4.25, "w": 2.75}, + {"matrix": [6, 8], "x": 16.25, "y": 4.25}, + {"matrix": [6, 9], "x": 18.5, "y": 4.25}, + {"matrix": [6, 10], "x": 19.5, "y": 4.25}, + {"matrix": [6, 11], "x": 20.5, "y": 4.25}, + {"matrix": [6, 12], "x": 21.5, "y": 4.25, "h": 2}, + {"matrix": [7, 0], "x": 0, "y": 5.25, "w": 1.25}, + {"matrix": [7, 1], "x": 1.25, "y": 5.25, "w": 1.25}, + {"matrix": [7, 2], "x": 2.5, "y": 5.25, "w": 1.25}, + {"matrix": [7, 3], "x": 3.75, "y": 5.25, "w": 6.25}, + {"matrix": [7, 4], "x": 10, "y": 5.25, "w": 1.25}, + {"matrix": [7, 5], "x": 11.25, "y": 5.25, "w": 1.25}, + {"matrix": [7, 6], "x": 12.5, "y": 5.25, "w": 1.25}, + {"matrix": [7, 7], "x": 13.75, "y": 5.25, "w": 1.25}, + {"matrix": [7, 8], "x": 15.25, "y": 5.25}, + {"matrix": [7, 9], "x": 16.25, "y": 5.25}, + {"matrix": [7, 10], "x": 17.25, "y": 5.25}, + {"matrix": [7, 11], "x": 18.5, "y": 5.25, "w": 2}, + {"matrix": [7, 12], "x": 20.5, "y": 5.25} + ] + } + } +} diff --git a/keyboards/whirlwind_fx_element/keymaps/default/keymap.c b/keyboards/whirlwind_fx_element/keymaps/default/keymap.c new file mode 100644 index 00000000000..916ac01f053 --- /dev/null +++ b/keyboards/whirlwind_fx_element/keymaps/default/keymap.c @@ -0,0 +1,41 @@ +// Copyright 2023 QMK +// SPDX-License-Identifier: GPL-2.0-or-later + +#include QMK_KEYBOARD_H + +const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { + /* + * ┌───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┬───┐ ┌───┬───┬───┐ + * │Esc│ │F1 │F2 │F3 │F4 │ │F5 │F6 │F7 │F8 │ │F9 │F10│F11│F12│ │PSc│Scr│Pse│ + * └───┘ └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┴───┘ └───┴───┴───┘ + * ┌───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───┬───────┐ ┌───┬───┬───┐ ┌───┬───┬───┬───┐ + * │ ` │ 1 │ 2 │ 3 │ 4 │ 5 │ 6 │ 7 │ 8 │ 9 │ 0 │ - │ = │ Backsp│ │Ins│Hom│PgU│ │Num│ / │ * │ - │ + * ├───┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─────┤ ├───┼───┼───┤ ├───┼───┼───┼───┤ + * │ Tab │ Q │ W │ E │ R │ T │ Y │ U │ I │ O │ P │ [ │ ] │ \ │ │Del│End│PgD│ │ 7 │ 8 │ 9 │ │ + * ├─────┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴┬──┴─────┤ └───┴───┴───┘ ├───┼───┼───┤ + │ + * │ Caps │ A │ S │ D │ F │ G │ H │ J │ K │ L │ ; │ ' │ Enter │ │ 4 │ 5 │ 6 │ │ + * ├──────┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴─┬─┴────────┤ ┌───┐ ├───┼───┼───┼───┤ + * │ Shift │ Z │ X │ C │ V │ B │ N │ M │ , │ . │ / │ Shift │ │ ↑ │ │ 1 │ 2 │ 3 │ │ + * ├────┬───┴┬──┴─┬─┴───┴───┴───┴───┴───┴──┬┴───┼───┴┬────┬────┤ ┌───┼───┼───┐ ├───┴───┼───┤Ent│ + * │Ctrl│GUI │Alt │ │ Alt│ FN │Menu│Ctrl│ │ ← │ ↓ │ → │ │ 0 │ . │ │ + * └────┴────┴────┴────────────────────────┴────┴────┴────┴────┘ └───┴───┴───┘ └───────┴───┴───┘ + */ + [0] = LAYOUT_fullsize_ansi( + KC_ESC, 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_PSCR, KC_SCRL, KC_PAUS, + + 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, KC_INS, KC_HOME, KC_PGUP, KC_NUM, KC_PSLS, KC_PAST, KC_PMNS, + KC_TAB, 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, KC_DEL, KC_END, KC_PGDN, KC_P7, KC_P8, KC_P9, KC_PPLS, + KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT, KC_P4, KC_P5, KC_P6, + KC_LSFT, 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_P1, KC_P2, KC_P3, KC_PENT, + KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_RALT, MO(1), KC_APP, KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT, KC_P0, KC_PDOT + ), + [1] = LAYOUT_fullsize_ansi( + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_BRID, KC_BRIU, KC_MPRV, KC_MPLY, KC_MNXT, KC_MUTE, KC_VOLD, KC_VOLU, KC_TRNS, KC_TRNS, KC_CALC, + + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RM_VALD, RM_VALU, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RM_SPDU, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, + KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, RM_PREV, RM_SPDD, RM_NEXT, KC_TRNS, KC_TRNS + ) +}; diff --git a/keyboards/whirlwind_fx_element/mcuconf.h b/keyboards/whirlwind_fx_element/mcuconf.h new file mode 100644 index 00000000000..ca8bb00ec0b --- /dev/null +++ b/keyboards/whirlwind_fx_element/mcuconf.h @@ -0,0 +1,6 @@ +#pragma once + +#include_next + +#undef STM32_I2C_USE_I2C1 +#define STM32_I2C_USE_I2C1 TRUE diff --git a/keyboards/whirlwind_fx_element/readme.md b/keyboards/whirlwind_fx_element/readme.md new file mode 100644 index 00000000000..3df7e473356 --- /dev/null +++ b/keyboards/whirlwind_fx_element/readme.md @@ -0,0 +1,31 @@ +# WhirlwindFX ElementV2 + +![WhirlwindFX ElementV2](https://www.whirlwindfx.com/cdn/shop/products/TheONEALONE_1920x.png) + +A full-size (100%) mechanical keyboard with RGB lighting. + +* Keyboard Maintainer: [Aedan Mills](https://github.com/aedanmills) +* Hardware Supported: WhirlwindFX ElementV2 +* Hardware Availability: [WhirlwindFX](https://www.whirlwindfx.com/products/element) + +Make example for this keyboard (after setting up your build environment): + + make whirlwind_fx_element:default + +Flashing example for this keyboard: + + make whirlwind_fx_element:default:flash + +## Bootloader + +Enter the bootloader by pressing and holding the reset button on the back of the PCB while plugging in the keyboard. You will have to remove the key caps to access the screws to disassemble the keyboard and access the button. + +Don't forget to backup the original firmware before proceeding by using the following dfu-util command with the keyboard in bootloader mode: + + dfu-util --list # Check that the keyboard is listed in DFU mode + dfu-util -a 0 -U backup.bin -s 0x08000000 # Save backup as backup.bin + +After flashing with QMK, BootMagic can be used to enter the bootloader by holding ESC while plugging in the keyboard. + + +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/whirlwind_fx_element/rules.mk b/keyboards/whirlwind_fx_element/rules.mk new file mode 100644 index 00000000000..411d3aae9ab --- /dev/null +++ b/keyboards/whirlwind_fx_element/rules.mk @@ -0,0 +1,8 @@ +MCU = STM32F303 +F_CPU = 72000000 + +BOOTLOADER = stm32-dfu + +OPT_DEFS = -DSTM32F3 + +LED_INDICATORS = yes diff --git a/keyboards/whirlwind_fx_element/whirlwind_fx_element.c b/keyboards/whirlwind_fx_element/whirlwind_fx_element.c new file mode 100644 index 00000000000..8d38d4dabd8 --- /dev/null +++ b/keyboards/whirlwind_fx_element/whirlwind_fx_element.c @@ -0,0 +1,132 @@ +// Copyright 2023 QMK +// SPDX-License-Identifier: GPL-2.0-or-later + +#include "config.h" +#include QMK_KEYBOARD_H + +#ifdef RGB_MATRIX_ENABLE +const is31fl3741_led_t PROGMEM g_is31fl3741_leds[IS31FL3741_LED_COUNT] = { + {0, SW1_CS2, SW1_CS3, SW1_CS1}, + {0, SW1_CS5, SW1_CS6, SW1_CS4}, + {0, SW1_CS8, SW1_CS9, SW1_CS7}, + {0, SW1_CS11, SW1_CS12, SW1_CS10}, + {0, SW1_CS14, SW1_CS15, SW1_CS13}, + {0, SW1_CS17, SW1_CS18, SW1_CS16}, + {0, SW1_CS20, SW1_CS21, SW1_CS19}, + {0, SW1_CS23, SW1_CS24, SW1_CS22}, + {0, SW1_CS26, SW1_CS27, SW1_CS25}, + {0, SW1_CS29, SW1_CS30, SW1_CS28}, + {0, SW1_CS32, SW1_CS33, SW1_CS31}, + {0, SW1_CS35, SW1_CS36, SW1_CS34}, + {0, SW1_CS38, SW1_CS39, SW1_CS37}, + {0, SW2_CS2, SW2_CS3, SW2_CS1}, + {0, SW2_CS5, SW2_CS6, SW2_CS4}, + {0, SW2_CS8, SW2_CS9, SW2_CS7}, + {0, SW2_CS11, SW2_CS12, SW2_CS10}, + {0, SW2_CS14, SW2_CS15, SW2_CS13}, + {0, SW2_CS17, SW2_CS18, SW2_CS16}, + {0, SW2_CS20, SW2_CS21, SW2_CS19}, + {0, SW2_CS23, SW2_CS24, SW2_CS22}, + {0, SW2_CS26, SW2_CS27, SW2_CS25}, + {0, SW2_CS29, SW2_CS30, SW2_CS28}, + {0, SW2_CS32, SW2_CS33, SW2_CS31}, + {0, SW2_CS35, SW2_CS36, SW2_CS34}, + {0, SW2_CS38, SW2_CS39, SW2_CS37}, + {0, SW3_CS2, SW3_CS3, SW3_CS1}, + {0, SW3_CS5, SW3_CS6, SW3_CS4}, + {0, SW3_CS8, SW3_CS9, SW3_CS7}, + {0, SW3_CS11, SW3_CS12, SW3_CS10}, + {0, SW3_CS14, SW3_CS15, SW3_CS13}, + {0, SW3_CS17, SW3_CS18, SW3_CS16}, + {0, SW3_CS20, SW3_CS21, SW3_CS19}, + {0, SW3_CS23, SW3_CS24, SW3_CS22}, + {0, SW3_CS26, SW3_CS27, SW3_CS25}, + {0, SW3_CS29, SW3_CS30, SW3_CS28}, + {0, SW3_CS32, SW3_CS33, SW3_CS31}, + {0, SW3_CS35, SW3_CS36, SW3_CS34}, + {0, SW3_CS38, SW3_CS39, SW3_CS37}, + {0, SW4_CS2, SW4_CS3, SW4_CS1}, + {0, SW4_CS5, SW4_CS6, SW4_CS4}, + {0, SW4_CS8, SW4_CS9, SW4_CS7}, + {0, SW4_CS11, SW4_CS12, SW4_CS10}, + {0, SW4_CS14, SW4_CS15, SW4_CS13}, + {0, SW4_CS17, SW4_CS18, SW4_CS16}, + {0, SW4_CS20, SW4_CS21, SW4_CS19}, + {0, SW4_CS23, SW4_CS24, SW4_CS22}, + {0, SW4_CS26, SW4_CS27, SW4_CS25}, + {0, SW4_CS29, SW4_CS30, SW4_CS28}, + {0, SW4_CS32, SW4_CS33, SW4_CS31}, + {0, SW4_CS35, SW4_CS36, SW4_CS34}, + {0, SW4_CS38, SW4_CS39, SW4_CS37}, + {0, SW5_CS2, SW5_CS3, SW5_CS1}, + {0, SW5_CS5, SW5_CS6, SW5_CS4}, + {0, SW5_CS8, SW5_CS9, SW5_CS7}, + {0, SW5_CS11, SW5_CS12, SW5_CS10}, + {0, SW5_CS14, SW5_CS15, SW5_CS13}, + {0, SW5_CS17, SW5_CS18, SW5_CS16}, + {0, SW5_CS20, SW5_CS21, SW5_CS19}, + {0, SW5_CS23, SW5_CS24, SW5_CS22}, + {0, SW5_CS26, SW5_CS27, SW5_CS25}, + {0, SW5_CS29, SW5_CS30, SW5_CS28}, + {0, SW5_CS32, SW5_CS33, SW5_CS31}, + {0, SW5_CS35, SW5_CS36, SW5_CS34}, + {0, SW5_CS38, SW5_CS39, SW5_CS37}, + {0, SW6_CS2, SW6_CS3, SW6_CS1}, + {0, SW6_CS5, SW6_CS6, SW6_CS4}, + {0, SW6_CS8, SW6_CS9, SW6_CS7}, + {0, SW6_CS11, SW6_CS12, SW6_CS10}, + {0, SW6_CS14, SW6_CS15, SW6_CS13}, + {0, SW6_CS17, SW6_CS18, SW6_CS16}, + {0, SW6_CS20, SW6_CS21, SW6_CS19}, + {0, SW6_CS23, SW6_CS24, SW6_CS22}, + {0, SW6_CS26, SW6_CS27, SW6_CS25}, + {0, SW6_CS29, SW6_CS30, SW6_CS28}, + {0, SW6_CS32, SW6_CS33, SW6_CS31}, + {0, SW6_CS35, SW6_CS36, SW6_CS34}, + {0, SW6_CS38, SW6_CS39, SW6_CS37}, + {0, SW7_CS2, SW7_CS3, SW7_CS1}, + {0, SW7_CS5, SW7_CS6, SW7_CS4}, + {0, SW7_CS8, SW7_CS9, SW7_CS7}, + {0, SW7_CS11, SW7_CS12, SW7_CS10}, + {0, SW7_CS14, SW7_CS15, SW7_CS13}, + {0, SW7_CS17, SW7_CS18, SW7_CS16}, + {0, SW7_CS20, SW7_CS21, SW7_CS19}, + {0, SW7_CS23, SW7_CS24, SW7_CS22}, + {0, SW7_CS26, SW7_CS27, SW7_CS25}, + {0, SW7_CS29, SW7_CS30, SW7_CS28}, + {0, SW7_CS32, SW7_CS33, SW7_CS31}, + {0, SW7_CS35, SW7_CS36, SW7_CS34}, + {0, SW7_CS38, SW7_CS39, SW7_CS37}, + {0, SW8_CS2, SW8_CS3, SW8_CS1}, + {0, SW8_CS5, SW8_CS6, SW8_CS4}, + {0, SW8_CS8, SW8_CS9, SW8_CS7}, + {0, SW8_CS11, SW8_CS12, SW8_CS10}, + {0, SW8_CS14, SW8_CS15, SW8_CS13}, + {0, SW8_CS17, SW8_CS18, SW8_CS16}, + {0, SW8_CS20, SW8_CS21, SW8_CS19}, + {0, SW8_CS23, SW8_CS24, SW8_CS22}, + {0, SW8_CS26, SW8_CS27, SW8_CS25}, + {0, SW8_CS29, SW8_CS30, SW8_CS28}, + {0, SW8_CS32, SW8_CS33, SW8_CS31}, + {0, SW8_CS35, SW8_CS36, SW8_CS34}, + {0, SW8_CS38, SW8_CS39, SW8_CS37} +}; +#endif + +void keyboard_pre_init_kb(void) { + gpio_set_pin_output(LED_CAPS_LOCK_PIN); + gpio_set_pin_output(LED_NUM_LOCK_PIN); + gpio_set_pin_output(LED_SCROLL_LOCK_PIN); + + gpio_set_pin_output(B11); // Required for indicators to work correctly +} + +bool led_update_kb(led_t led_state) { + bool res = led_update_user(led_state); + if(res) { + gpio_write_pin(LED_NUM_LOCK_PIN, !led_state.num_lock); + gpio_write_pin(LED_CAPS_LOCK_PIN, !led_state.caps_lock); + gpio_write_pin(LED_SCROLL_LOCK_PIN, !led_state.scroll_lock); + } + return res; +} From 195d5e53fdab08c49a061a8c548ba89d77c4eee2 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 17:24:56 -0400 Subject: [PATCH 2/9] Cleanup to comply with conventions. --- keyboards/whirlwind_fx_element/config.h | 3 - keyboards/whirlwind_fx_element/keyboard.json | 221 +++++++++--------- .../keymaps/default/keymap.c | 3 +- keyboards/whirlwind_fx_element/rules.mk | 2 - .../whirlwind_fx_element.c | 13 +- 5 files changed, 120 insertions(+), 122 deletions(-) diff --git a/keyboards/whirlwind_fx_element/config.h b/keyboards/whirlwind_fx_element/config.h index 07d91c35570..949ec72b270 100644 --- a/keyboards/whirlwind_fx_element/config.h +++ b/keyboards/whirlwind_fx_element/config.h @@ -9,6 +9,3 @@ #define IS31FL3741_I2C_ADDRESS_1 IS31FL3741_I2C_ADDRESS_GND #define RGB_MATRIX_DISABLE_SHARED_KEYCODES -#define RGB_MATRIX_DEFAULT_SPEED 0 - -#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_BREATHING diff --git a/keyboards/whirlwind_fx_element/keyboard.json b/keyboards/whirlwind_fx_element/keyboard.json index 8ed4cddfea6..7a2c9674588 100644 --- a/keyboards/whirlwind_fx_element/keyboard.json +++ b/keyboards/whirlwind_fx_element/keyboard.json @@ -24,6 +24,117 @@ "pid": "0xA33E", "device_version": "1.0.6" }, + + "layouts": { + "LAYOUT_fullsize_ansi": { + "layout": [ + {"matrix": [0, 0], "x": 0, "y": 0}, + {"matrix": [0, 1], "x": 2, "y": 0}, + {"matrix": [0, 2], "x": 3, "y": 0}, + {"matrix": [0, 3], "x": 4, "y": 0}, + {"matrix": [0, 4], "x": 5, "y": 0}, + {"matrix": [0, 5], "x": 6.5, "y": 0}, + {"matrix": [0, 6], "x": 7.5, "y": 0}, + {"matrix": [0, 7], "x": 8.5, "y": 0}, + {"matrix": [0, 8], "x": 9.5, "y": 0}, + {"matrix": [0, 9], "x": 11, "y": 0}, + {"matrix": [0, 10], "x": 12, "y": 0}, + {"matrix": [0, 11], "x": 13, "y": 0}, + {"matrix": [0, 12], "x": 14, "y": 0}, + {"matrix": [1, 0], "x": 15.25, "y": 0}, + {"matrix": [1, 1], "x": 16.25, "y": 0}, + {"matrix": [1, 2], "x": 17.25, "y": 0}, + {"matrix": [1, 3], "x": 0, "y": 1.25}, + {"matrix": [1, 4], "x": 1, "y": 1.25}, + {"matrix": [1, 5], "x": 2, "y": 1.25}, + {"matrix": [1, 6], "x": 3, "y": 1.25}, + {"matrix": [1, 7], "x": 4, "y": 1.25}, + {"matrix": [1, 8], "x": 5, "y": 1.25}, + {"matrix": [1, 9], "x": 6, "y": 1.25}, + {"matrix": [1, 10], "x": 7, "y": 1.25}, + {"matrix": [1, 11], "x": 8, "y": 1.25}, + {"matrix": [1, 12], "x": 9, "y": 1.25}, + {"matrix": [2, 0], "x": 10, "y": 1.25}, + {"matrix": [2, 1], "x": 11, "y": 1.25}, + {"matrix": [2, 2], "x": 12, "y": 1.25}, + {"matrix": [2, 3], "x": 13, "y": 1.25, "w": 2}, + {"matrix": [2, 4], "x": 15.25, "y": 1.25}, + {"matrix": [2, 5], "x": 16.25, "y": 1.25}, + {"matrix": [2, 6], "x": 17.25, "y": 1.25}, + {"matrix": [2, 7], "x": 18.5, "y": 1.25}, + {"matrix": [2, 8], "x": 19.5, "y": 1.25}, + {"matrix": [2, 9], "x": 20.5, "y": 1.25}, + {"matrix": [2, 10], "x": 21.5, "y": 1.25}, + {"matrix": [2, 11], "x": 0, "y": 2.25, "w": 1.5}, + {"matrix": [2, 12], "x": 1.5, "y": 2.25}, + {"matrix": [3, 0], "x": 2.5, "y": 2.25}, + {"matrix": [3, 1], "x": 3.5, "y": 2.25}, + {"matrix": [3, 2], "x": 4.5, "y": 2.25}, + {"matrix": [3, 3], "x": 5.5, "y": 2.25}, + {"matrix": [3, 4], "x": 6.5, "y": 2.25}, + {"matrix": [3, 5], "x": 7.5, "y": 2.25}, + {"matrix": [3, 6], "x": 8.5, "y": 2.25}, + {"matrix": [3, 7], "x": 9.5, "y": 2.25}, + {"matrix": [3, 8], "x": 10.5, "y": 2.25}, + {"matrix": [3, 9], "x": 11.5, "y": 2.25}, + {"matrix": [3, 10], "x": 12.5, "y": 2.25}, + {"matrix": [3, 11], "x": 13.5, "y": 2.25, "w": 1.5}, + {"matrix": [3, 12], "x": 15.25, "y": 2.25}, + {"matrix": [4, 0], "x": 16.25, "y": 2.25}, + {"matrix": [4, 1], "x": 17.25, "y": 2.25}, + {"matrix": [4, 2], "x": 18.5, "y": 2.25}, + {"matrix": [4, 3], "x": 19.5, "y": 2.25}, + {"matrix": [4, 4], "x": 20.5, "y": 2.25}, + {"matrix": [5, 8], "x": 21.5, "y": 2.25, "h": 2}, + {"matrix": [4, 5], "x": 0, "y": 3.25, "w": 1.75}, + {"matrix": [4, 6], "x": 1.75, "y": 3.25}, + {"matrix": [4, 7], "x": 2.75, "y": 3.25}, + {"matrix": [4, 8], "x": 3.75, "y": 3.25}, + {"matrix": [4, 9], "x": 4.75, "y": 3.25}, + {"matrix": [4, 10], "x": 5.75, "y": 3.25}, + {"matrix": [4, 11], "x": 6.75, "y": 3.25}, + {"matrix": [4, 12], "x": 7.75, "y": 3.25}, + {"matrix": [5, 0], "x": 8.75, "y": 3.25}, + {"matrix": [5, 1], "x": 9.75, "y": 3.25}, + {"matrix": [5, 2], "x": 10.75, "y": 3.25}, + {"matrix": [5, 3], "x": 11.75, "y": 3.25}, + {"matrix": [5, 4], "x": 12.75, "y": 3.25, "w": 2.25}, + {"matrix": [5, 5], "x": 18.5, "y": 3.25}, + {"matrix": [5, 6], "x": 19.5, "y": 3.25}, + {"matrix": [5, 7], "x": 20.5, "y": 3.25}, + {"matrix": [5, 9], "x": 0, "y": 4.25, "w": 2.25}, + {"matrix": [5, 10], "x": 2.25, "y": 4.25}, + {"matrix": [5, 11], "x": 3.25, "y": 4.25}, + {"matrix": [5, 12], "x": 4.25, "y": 4.25}, + {"matrix": [6, 0], "x": 5.25, "y": 4.25}, + {"matrix": [6, 1], "x": 6.25, "y": 4.25}, + {"matrix": [6, 2], "x": 7.25, "y": 4.25}, + {"matrix": [6, 3], "x": 8.25, "y": 4.25}, + {"matrix": [6, 4], "x": 9.25, "y": 4.25}, + {"matrix": [6, 5], "x": 10.25, "y": 4.25}, + {"matrix": [6, 6], "x": 11.25, "y": 4.25}, + {"matrix": [6, 7], "x": 12.25, "y": 4.25, "w": 2.75}, + {"matrix": [6, 8], "x": 16.25, "y": 4.25}, + {"matrix": [6, 9], "x": 18.5, "y": 4.25}, + {"matrix": [6, 10], "x": 19.5, "y": 4.25}, + {"matrix": [6, 11], "x": 20.5, "y": 4.25}, + {"matrix": [6, 12], "x": 21.5, "y": 4.25, "h": 2}, + {"matrix": [7, 0], "x": 0, "y": 5.25, "w": 1.25}, + {"matrix": [7, 1], "x": 1.25, "y": 5.25, "w": 1.25}, + {"matrix": [7, 2], "x": 2.5, "y": 5.25, "w": 1.25}, + {"matrix": [7, 3], "x": 3.75, "y": 5.25, "w": 6.25}, + {"matrix": [7, 4], "x": 10, "y": 5.25, "w": 1.25}, + {"matrix": [7, 5], "x": 11.25, "y": 5.25, "w": 1.25}, + {"matrix": [7, 6], "x": 12.5, "y": 5.25, "w": 1.25}, + {"matrix": [7, 7], "x": 13.75, "y": 5.25, "w": 1.25}, + {"matrix": [7, 8], "x": 15.25, "y": 5.25}, + {"matrix": [7, 9], "x": 16.25, "y": 5.25}, + {"matrix": [7, 10], "x": 17.25, "y": 5.25}, + {"matrix": [7, 11], "x": 18.5, "y": 5.25, "w": 2}, + {"matrix": [7, 12], "x": 20.5, "y": 5.25} + ] + } + }, "rgb_matrix": { "driver": "is31fl3741", "max_brightness": 200, @@ -185,115 +296,5 @@ "led_process_limit": 4, "led_flush_limit": 26, "sleep": true - }, - "layouts": { - "LAYOUT_fullsize_ansi": { - "layout": [ - {"matrix": [0, 0], "x": 0, "y": 0}, - {"matrix": [0, 1], "x": 2, "y": 0}, - {"matrix": [0, 2], "x": 3, "y": 0}, - {"matrix": [0, 3], "x": 4, "y": 0}, - {"matrix": [0, 4], "x": 5, "y": 0}, - {"matrix": [0, 5], "x": 6.5, "y": 0}, - {"matrix": [0, 6], "x": 7.5, "y": 0}, - {"matrix": [0, 7], "x": 8.5, "y": 0}, - {"matrix": [0, 8], "x": 9.5, "y": 0}, - {"matrix": [0, 9], "x": 11, "y": 0}, - {"matrix": [0, 10], "x": 12, "y": 0}, - {"matrix": [0, 11], "x": 13, "y": 0}, - {"matrix": [0, 12], "x": 14, "y": 0}, - {"matrix": [1, 0], "x": 15.25, "y": 0}, - {"matrix": [1, 1], "x": 16.25, "y": 0}, - {"matrix": [1, 2], "x": 17.25, "y": 0}, - {"matrix": [1, 3], "x": 0, "y": 1.25}, - {"matrix": [1, 4], "x": 1, "y": 1.25}, - {"matrix": [1, 5], "x": 2, "y": 1.25}, - {"matrix": [1, 6], "x": 3, "y": 1.25}, - {"matrix": [1, 7], "x": 4, "y": 1.25}, - {"matrix": [1, 8], "x": 5, "y": 1.25}, - {"matrix": [1, 9], "x": 6, "y": 1.25}, - {"matrix": [1, 10], "x": 7, "y": 1.25}, - {"matrix": [1, 11], "x": 8, "y": 1.25}, - {"matrix": [1, 12], "x": 9, "y": 1.25}, - {"matrix": [2, 0], "x": 10, "y": 1.25}, - {"matrix": [2, 1], "x": 11, "y": 1.25}, - {"matrix": [2, 2], "x": 12, "y": 1.25}, - {"matrix": [2, 3], "x": 13, "y": 1.25, "w": 2}, - {"matrix": [2, 4], "x": 15.25, "y": 1.25}, - {"matrix": [2, 5], "x": 16.25, "y": 1.25}, - {"matrix": [2, 6], "x": 17.25, "y": 1.25}, - {"matrix": [2, 7], "x": 18.5, "y": 1.25}, - {"matrix": [2, 8], "x": 19.5, "y": 1.25}, - {"matrix": [2, 9], "x": 20.5, "y": 1.25}, - {"matrix": [2, 10], "x": 21.5, "y": 1.25}, - {"matrix": [2, 11], "x": 0, "y": 2.25, "w": 1.5}, - {"matrix": [2, 12], "x": 1.5, "y": 2.25}, - {"matrix": [3, 0], "x": 2.5, "y": 2.25}, - {"matrix": [3, 1], "x": 3.5, "y": 2.25}, - {"matrix": [3, 2], "x": 4.5, "y": 2.25}, - {"matrix": [3, 3], "x": 5.5, "y": 2.25}, - {"matrix": [3, 4], "x": 6.5, "y": 2.25}, - {"matrix": [3, 5], "x": 7.5, "y": 2.25}, - {"matrix": [3, 6], "x": 8.5, "y": 2.25}, - {"matrix": [3, 7], "x": 9.5, "y": 2.25}, - {"matrix": [3, 8], "x": 10.5, "y": 2.25}, - {"matrix": [3, 9], "x": 11.5, "y": 2.25}, - {"matrix": [3, 10], "x": 12.5, "y": 2.25}, - {"matrix": [3, 11], "x": 13.5, "y": 2.25, "w": 1.5}, - {"matrix": [3, 12], "x": 15.25, "y": 2.25}, - {"matrix": [4, 0], "x": 16.25, "y": 2.25}, - {"matrix": [4, 1], "x": 17.25, "y": 2.25}, - {"matrix": [4, 2], "x": 18.5, "y": 2.25}, - {"matrix": [4, 3], "x": 19.5, "y": 2.25}, - {"matrix": [4, 4], "x": 20.5, "y": 2.25}, - {"matrix": [5, 8], "x": 21.5, "y": 2.25, "h": 2}, - {"matrix": [4, 5], "x": 0, "y": 3.25, "w": 1.75}, - {"matrix": [4, 6], "x": 1.75, "y": 3.25}, - {"matrix": [4, 7], "x": 2.75, "y": 3.25}, - {"matrix": [4, 8], "x": 3.75, "y": 3.25}, - {"matrix": [4, 9], "x": 4.75, "y": 3.25}, - {"matrix": [4, 10], "x": 5.75, "y": 3.25}, - {"matrix": [4, 11], "x": 6.75, "y": 3.25}, - {"matrix": [4, 12], "x": 7.75, "y": 3.25}, - {"matrix": [5, 0], "x": 8.75, "y": 3.25}, - {"matrix": [5, 1], "x": 9.75, "y": 3.25}, - {"matrix": [5, 2], "x": 10.75, "y": 3.25}, - {"matrix": [5, 3], "x": 11.75, "y": 3.25}, - {"matrix": [5, 4], "x": 12.75, "y": 3.25, "w": 2.25}, - {"matrix": [5, 5], "x": 18.5, "y": 3.25}, - {"matrix": [5, 6], "x": 19.5, "y": 3.25}, - {"matrix": [5, 7], "x": 20.5, "y": 3.25}, - {"matrix": [5, 9], "x": 0, "y": 4.25, "w": 2.25}, - {"matrix": [5, 10], "x": 2.25, "y": 4.25}, - {"matrix": [5, 11], "x": 3.25, "y": 4.25}, - {"matrix": [5, 12], "x": 4.25, "y": 4.25}, - {"matrix": [6, 0], "x": 5.25, "y": 4.25}, - {"matrix": [6, 1], "x": 6.25, "y": 4.25}, - {"matrix": [6, 2], "x": 7.25, "y": 4.25}, - {"matrix": [6, 3], "x": 8.25, "y": 4.25}, - {"matrix": [6, 4], "x": 9.25, "y": 4.25}, - {"matrix": [6, 5], "x": 10.25, "y": 4.25}, - {"matrix": [6, 6], "x": 11.25, "y": 4.25}, - {"matrix": [6, 7], "x": 12.25, "y": 4.25, "w": 2.75}, - {"matrix": [6, 8], "x": 16.25, "y": 4.25}, - {"matrix": [6, 9], "x": 18.5, "y": 4.25}, - {"matrix": [6, 10], "x": 19.5, "y": 4.25}, - {"matrix": [6, 11], "x": 20.5, "y": 4.25}, - {"matrix": [6, 12], "x": 21.5, "y": 4.25, "h": 2}, - {"matrix": [7, 0], "x": 0, "y": 5.25, "w": 1.25}, - {"matrix": [7, 1], "x": 1.25, "y": 5.25, "w": 1.25}, - {"matrix": [7, 2], "x": 2.5, "y": 5.25, "w": 1.25}, - {"matrix": [7, 3], "x": 3.75, "y": 5.25, "w": 6.25}, - {"matrix": [7, 4], "x": 10, "y": 5.25, "w": 1.25}, - {"matrix": [7, 5], "x": 11.25, "y": 5.25, "w": 1.25}, - {"matrix": [7, 6], "x": 12.5, "y": 5.25, "w": 1.25}, - {"matrix": [7, 7], "x": 13.75, "y": 5.25, "w": 1.25}, - {"matrix": [7, 8], "x": 15.25, "y": 5.25}, - {"matrix": [7, 9], "x": 16.25, "y": 5.25}, - {"matrix": [7, 10], "x": 17.25, "y": 5.25}, - {"matrix": [7, 11], "x": 18.5, "y": 5.25, "w": 2}, - {"matrix": [7, 12], "x": 20.5, "y": 5.25} - ] - } } } diff --git a/keyboards/whirlwind_fx_element/keymaps/default/keymap.c b/keyboards/whirlwind_fx_element/keymaps/default/keymap.c index 916ac01f053..36690aca28d 100644 --- a/keyboards/whirlwind_fx_element/keymaps/default/keymap.c +++ b/keyboards/whirlwind_fx_element/keymaps/default/keymap.c @@ -1,4 +1,5 @@ -// Copyright 2023 QMK +// Copyright 2023 WhirlwindFX +// Copyright 2023 aedanmills // SPDX-License-Identifier: GPL-2.0-or-later #include QMK_KEYBOARD_H diff --git a/keyboards/whirlwind_fx_element/rules.mk b/keyboards/whirlwind_fx_element/rules.mk index 411d3aae9ab..b5c9d6520db 100644 --- a/keyboards/whirlwind_fx_element/rules.mk +++ b/keyboards/whirlwind_fx_element/rules.mk @@ -4,5 +4,3 @@ F_CPU = 72000000 BOOTLOADER = stm32-dfu OPT_DEFS = -DSTM32F3 - -LED_INDICATORS = yes diff --git a/keyboards/whirlwind_fx_element/whirlwind_fx_element.c b/keyboards/whirlwind_fx_element/whirlwind_fx_element.c index 8d38d4dabd8..7622412846a 100644 --- a/keyboards/whirlwind_fx_element/whirlwind_fx_element.c +++ b/keyboards/whirlwind_fx_element/whirlwind_fx_element.c @@ -1,8 +1,9 @@ -// Copyright 2023 QMK +// Copyright 2023 WhirlwindFX +// Copyright 2023 aedanmills // SPDX-License-Identifier: GPL-2.0-or-later -#include "config.h" #include QMK_KEYBOARD_H +#include "config.h" #ifdef RGB_MATRIX_ENABLE const is31fl3741_led_t PROGMEM g_is31fl3741_leds[IS31FL3741_LED_COUNT] = { @@ -114,11 +115,11 @@ const is31fl3741_led_t PROGMEM g_is31fl3741_leds[IS31FL3741_LED_COUNT] = { #endif void keyboard_pre_init_kb(void) { - gpio_set_pin_output(LED_CAPS_LOCK_PIN); - gpio_set_pin_output(LED_NUM_LOCK_PIN); - gpio_set_pin_output(LED_SCROLL_LOCK_PIN); + gpio_set_pin_output(LED_CAPS_LOCK_PIN); + gpio_set_pin_output(LED_NUM_LOCK_PIN); + gpio_set_pin_output(LED_SCROLL_LOCK_PIN); - gpio_set_pin_output(B11); // Required for indicators to work correctly + gpio_set_pin_output(B11); // Required for indicators to work correctly } bool led_update_kb(led_t led_state) { From 8f963c238e0d84e2810213ed70f220160a21d09c Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 17:56:59 -0400 Subject: [PATCH 3/9] Update config.h --- keyboards/whirlwind_fx_element/config.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/keyboards/whirlwind_fx_element/config.h b/keyboards/whirlwind_fx_element/config.h index 949ec72b270..7c7004ba6c9 100644 --- a/keyboards/whirlwind_fx_element/config.h +++ b/keyboards/whirlwind_fx_element/config.h @@ -1,3 +1,7 @@ +// Copyright 2023 WhirlwindFX +// Copyright 2023 aedanmills +// SPDX-License-Identifier: GPL-2.0-or-later + #pragma once #define F_CPU 72000000 From 681ef44e57a7f7a09eccea1cb83dfc4db6f674f7 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 17:57:17 -0400 Subject: [PATCH 4/9] Update halconf.h --- keyboards/whirlwind_fx_element/halconf.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/keyboards/whirlwind_fx_element/halconf.h b/keyboards/whirlwind_fx_element/halconf.h index c4a7101379f..75e92dea90e 100644 --- a/keyboards/whirlwind_fx_element/halconf.h +++ b/keyboards/whirlwind_fx_element/halconf.h @@ -1,3 +1,7 @@ +// Copyright 2023 WhirlwindFX +// Copyright 2023 aedanmills +// SPDX-License-Identifier: GPL-2.0-or-later + #pragma once #define HAL_USE_I2C TRUE From 4d7418e030eb2cb464470e8eb0546eb886e81a07 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 17:57:34 -0400 Subject: [PATCH 5/9] Update mcuconf.h --- keyboards/whirlwind_fx_element/mcuconf.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/keyboards/whirlwind_fx_element/mcuconf.h b/keyboards/whirlwind_fx_element/mcuconf.h index ca8bb00ec0b..c89f7275d4f 100644 --- a/keyboards/whirlwind_fx_element/mcuconf.h +++ b/keyboards/whirlwind_fx_element/mcuconf.h @@ -1,3 +1,7 @@ +// Copyright 2023 WhirlwindFX +// Copyright 2023 aedanmills +// SPDX-License-Identifier: GPL-2.0-or-later + #pragma once #include_next From d80119dfe4dbb24eda5d6951e11ad2b8d45ccef3 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 19:16:36 -0400 Subject: [PATCH 6/9] Apply suggestions from code review Co-authored-by: Joel Challis --- keyboards/whirlwind_fx_element/config.h | 8 -------- keyboards/whirlwind_fx_element/keyboard.json | 8 ++++++-- .../whirlwind_fx_element.c | 18 ++---------------- 3 files changed, 8 insertions(+), 26 deletions(-) diff --git a/keyboards/whirlwind_fx_element/config.h b/keyboards/whirlwind_fx_element/config.h index 7c7004ba6c9..606163cf102 100644 --- a/keyboards/whirlwind_fx_element/config.h +++ b/keyboards/whirlwind_fx_element/config.h @@ -4,12 +4,4 @@ #pragma once -#define F_CPU 72000000 - -#define LED_NUM_LOCK_PIN B8 -#define LED_CAPS_LOCK_PIN B9 -#define LED_SCROLL_LOCK_PIN B10 - #define IS31FL3741_I2C_ADDRESS_1 IS31FL3741_I2C_ADDRESS_GND - -#define RGB_MATRIX_DISABLE_SHARED_KEYCODES diff --git a/keyboards/whirlwind_fx_element/keyboard.json b/keyboards/whirlwind_fx_element/keyboard.json index 7a2c9674588..8c505f9d99f 100644 --- a/keyboards/whirlwind_fx_element/keyboard.json +++ b/keyboards/whirlwind_fx_element/keyboard.json @@ -24,7 +24,12 @@ "pid": "0xA33E", "device_version": "1.0.6" }, - + "indicators": { + "caps_lock": "B9", + "num_lock": "B8", + "scroll_lock": "B10", + "on_state": 0 + }, "layouts": { "LAYOUT_fullsize_ansi": { "layout": [ @@ -250,7 +255,6 @@ {"matrix": [7, 12], "x": 214, "y": 64, "flags": 4} ], "animations": { - "solid_color": true, "alphas_mods": true, "gradient_up_down": true, "gradient_left_right": true, diff --git a/keyboards/whirlwind_fx_element/whirlwind_fx_element.c b/keyboards/whirlwind_fx_element/whirlwind_fx_element.c index 7622412846a..6f17dbda2f7 100644 --- a/keyboards/whirlwind_fx_element/whirlwind_fx_element.c +++ b/keyboards/whirlwind_fx_element/whirlwind_fx_element.c @@ -3,7 +3,6 @@ // SPDX-License-Identifier: GPL-2.0-or-later #include QMK_KEYBOARD_H -#include "config.h" #ifdef RGB_MATRIX_ENABLE const is31fl3741_led_t PROGMEM g_is31fl3741_leds[IS31FL3741_LED_COUNT] = { @@ -113,21 +112,8 @@ const is31fl3741_led_t PROGMEM g_is31fl3741_leds[IS31FL3741_LED_COUNT] = { {0, SW8_CS38, SW8_CS39, SW8_CS37} }; #endif - void keyboard_pre_init_kb(void) { - gpio_set_pin_output(LED_CAPS_LOCK_PIN); - gpio_set_pin_output(LED_NUM_LOCK_PIN); - gpio_set_pin_output(LED_SCROLL_LOCK_PIN); - gpio_set_pin_output(B11); // Required for indicators to work correctly -} - -bool led_update_kb(led_t led_state) { - bool res = led_update_user(led_state); - if(res) { - gpio_write_pin(LED_NUM_LOCK_PIN, !led_state.num_lock); - gpio_write_pin(LED_CAPS_LOCK_PIN, !led_state.caps_lock); - gpio_write_pin(LED_SCROLL_LOCK_PIN, !led_state.scroll_lock); - } - return res; + + keyboard_pre_init_user(); } From a085e92beacb850eff5235d36a97ad0f2e6a40d4 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Wed, 11 Jun 2025 19:16:52 -0400 Subject: [PATCH 7/9] Delete keyboards/whirlwind_fx_element/rules.mk --- keyboards/whirlwind_fx_element/rules.mk | 6 ------ 1 file changed, 6 deletions(-) delete mode 100644 keyboards/whirlwind_fx_element/rules.mk diff --git a/keyboards/whirlwind_fx_element/rules.mk b/keyboards/whirlwind_fx_element/rules.mk deleted file mode 100644 index b5c9d6520db..00000000000 --- a/keyboards/whirlwind_fx_element/rules.mk +++ /dev/null @@ -1,6 +0,0 @@ -MCU = STM32F303 -F_CPU = 72000000 - -BOOTLOADER = stm32-dfu - -OPT_DEFS = -DSTM32F3 From dc3ef3744de12ef97b113f682be3d4b6ce73c00c Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Thu, 12 Jun 2025 16:57:42 -0400 Subject: [PATCH 8/9] Update keyboards/whirlwind_fx_element/keyboard.json Co-authored-by: Duncan Sutherland --- keyboards/whirlwind_fx_element/keyboard.json | 1 + 1 file changed, 1 insertion(+) diff --git a/keyboards/whirlwind_fx_element/keyboard.json b/keyboards/whirlwind_fx_element/keyboard.json index 8c505f9d99f..914563399d9 100644 --- a/keyboards/whirlwind_fx_element/keyboard.json +++ b/keyboards/whirlwind_fx_element/keyboard.json @@ -30,6 +30,7 @@ "scroll_lock": "B10", "on_state": 0 }, + "community_layouts": ["fullsize_ansi"], "layouts": { "LAYOUT_fullsize_ansi": { "layout": [ From b0290ab8ad20e83e0a36bfc6cd81fe725305cc51 Mon Sep 17 00:00:00 2001 From: aedanmills <40202903+aedanmills@users.noreply.github.com> Date: Sat, 14 Jun 2025 10:00:54 -0400 Subject: [PATCH 9/9] Rehost keyboard image. --- keyboards/whirlwind_fx_element/readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/keyboards/whirlwind_fx_element/readme.md b/keyboards/whirlwind_fx_element/readme.md index 3df7e473356..362b9847728 100644 --- a/keyboards/whirlwind_fx_element/readme.md +++ b/keyboards/whirlwind_fx_element/readme.md @@ -1,6 +1,6 @@ # WhirlwindFX ElementV2 -![WhirlwindFX ElementV2](https://www.whirlwindfx.com/cdn/shop/products/TheONEALONE_1920x.png) +![WhirlwindFX ElementV2](https://i.imgur.com/Etso6Ni.png) A full-size (100%) mechanical keyboard with RGB lighting.